44d0bdc032
Adds internal/provider/subprocess — a provider.Provider that spawns CLI agents (claude, gemini, vibe) as subprocesses and streams their output. - FormatParser interface + three parsers for claude-stream-json, gemini-stream-json, and vibe-streaming formats; fixtures captured from real binaries - subprocessStream: pull-based stream.Stream over subprocess stdout with bounded stderr capture (8KB) and guarded reap() to prevent double-Wait - DiscoverCLIAgents: parallel PATH scan with 10s timeout, stable ordering - Provider: only the last user message is passed as --prompt; all other request fields (history, tools, system prompt) are intentionally ignored (see package doc) - main.go: discover and register CLI arms at startup; TODO(P0c) for tier-based routing to enforce preference order explicitly
5 lines
657 B
JSON
5 lines
657 B
JSON
{"type":"init","timestamp":"2026-05-07T12:18:49.605Z","session_id":"c2d08136","model":"auto-gemini-3"}
|
|
{"type":"message","timestamp":"2026-05-07T12:18:49.606Z","role":"user","content":"say the word hi and nothing else"}
|
|
{"type":"message","timestamp":"2026-05-07T12:18:52.063Z","role":"assistant","content":"hi","delta":true}
|
|
{"type":"result","timestamp":"2026-05-07T12:18:52.111Z","status":"success","stats":{"total_tokens":10843,"input_tokens":10747,"output_tokens":1,"cached":7862,"input":2885,"duration_ms":2506,"tool_calls":0,"models":{"gemini-3-flash-preview":{"total_tokens":10843,"input_tokens":10747,"output_tokens":1,"cached":7862,"input":2885}}}}
|