Commit 3b83949
feat: implement YOLO classifier and MCP unified pipeline
Phase 3.4 YOLO Classifier (jcode-only):
- Create src/yolo_classifier.rs with 2-stage LLM approach
- Stage 1 (fast, 64 tokens): BLOCK/ALLOW decision
- Stage 2 (thinking, 4096 tokens): CoT evidence gathering when blocked
- Fail closed on errors/timeouts → falls back to interactive prompt
- Circuit breaker: 3 consecutive denials → bypass YOLO until reset
- Integrated into dcg_bridge::classify_with_mode() for Mode::Auto
Phase 3.6 MCP Unified Pipeline:
- Extend action_to_tool_call() to handle mcp__* actions
- MCP tools mapped to ToolCall::read with [Read, Write, Spawn] effects
- Three matching levels: mcp__server, mcp__server__tool, mcp__server__*
Also updated src/lib.rs to export the yolo_classifier module.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>1 parent 5a062eb commit 3b83949
3 files changed
Lines changed: 436 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
| 40 | + | |
| 41 | + | |
40 | 42 | | |
41 | 43 | | |
42 | 44 | | |
| |||
141 | 143 | | |
142 | 144 | | |
143 | 145 | | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
149 | 173 | | |
150 | 174 | | |
151 | 175 | | |
| |||
242 | 266 | | |
243 | 267 | | |
244 | 268 | | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
245 | 287 | | |
246 | 288 | | |
247 | 289 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
| |||
0 commit comments