feat(agent): bring-your-own-MODEL - any AI drives the frozen MCP surface - #232
Merged
Conversation
The BYO-key agent (#231) was Claude-only. The frozen MCP surface (ADR-0020) was built for ANY external consumer, so the agent now is too: - scripts/qos_agent.py — provider-agnostic entrypoint. --provider anthropic (default, Claude via tool_runner + MCP helpers, unchanged behavior) or --provider openai: ANY OpenAI-compatible /chat/completions endpoint (OpenAI, OpenRouter, Groq, DeepSeek, LM Studio, llama.cpp, keyless local Ollama via --base-url). The openai path converts the same 22 frozen MCP tools to function-calling schemas directly — still zero tool duplication — and feeds tool errors back to the model instead of dying. Credentials are resolved BEFORE any VM spawns; the guaranteed-shutdown finally and the --max-turns key-burn guard cover both providers. - scripts/qos_claude_agent.py — compat shim; old CLI works verbatim. - requirements-agent.txt (anthropic[mcp] + openai + mcp); the old requirements-claude-agent.txt now -r-includes it. - Makefile: qos-agent / qos-agent-list (PROVIDER/MODEL/BASE_URL knobs); qos-claude / qos-claude-list kept as aliases. - README post-launch refresh: the roadmap still listed ADR-0019/0020/0021 as planned — all three shipped in v0.5; new Done block + honest Next (N=5, audit actor attribution). MCP tool count corrected 21 -> 22 and the BYO agent surfaced in "What runs today". Verified (WSL): py_compile both entrypoints; --list-tools enumerates all 22 tools through qos_agent.py AND the shim; missing-key/missing-model guards exit cleanly before any VM boot; MCP->OpenAI schema conversion of the real 22-tool list is well-formed and JSON-serializable. Live loops remain BYO-key. Co-Authored-By: Claude Fable 5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Opens the BYO-key agent (#231) to any model, not just Claude — the frozen MCP surface (ADR-0020) was built for any external consumer, and now the agent honors that:
scripts/qos_agent.py— the provider-agnostic entrypoint.--provider anthropic(default): Claude via the Anthropic SDK'stool_runner+ MCP conversion helpers — behavior unchanged from feat(agent): Claude drives QuantumOS via the frozen MCP tools (BYO key) #231.--provider openai: any OpenAI-compatible/chat/completionsendpoint — OpenAI, OpenRouter, Groq, DeepSeek, LM Studio, llama.cpp server, or a keyless local Ollama (--base-url http://localhost:11434/v1). A plain function-calling loop converts the same 22 frozen MCP tools to function schemas directly (still zero tool duplication) and feeds tool errors back to the model instead of dying.finallyand the--max-turnskey-burn guard cover both providers.scripts/qos_claude_agent.py→ compat shim; the old CLI works verbatim.requirements-agent.txt(anthropic[mcp] + openai + mcp);requirements-claude-agent.txtnow-r-includes it.qos-agent/qos-agent-listwithPROVIDER=/MODEL=/BASE_URL=knobs;qos-claude/qos-claude-listkept as aliases.Post-launch README refresh
contracts/mcp/v1-tools.json), BYO-model agent surfaced in "What runs today", Contributing pointers updated.Verified (WSL, no key spent)
py_compileboth entrypoints.--list-toolsenumerates all 22 tools end-to-end through bothqos_agent.pyand the shim.🤖 Generated with Claude Code