Skip to content

[qoder] Vendor CLI agent scaffolding leaks into routed output (MCP lazy-loading reminder + tool-call markup) #4190

Description

@gaterking

Client or integration

Codex App

Area

Provider adapter

Summary

Routing turns through the Qoder (Global) adapter intermittently streams vendor-CLI agent-layer content into the assistant text instead of model output:

  1. An MCP "lazy-loading" <system-reminder> block that lists the local machine's MCP servers (with the mcp_list / mcp_get / mcp_call meta-tool description), including server names from both ~/.qoder/mcp.json and plugin-provided ones.
  2. Qoder-runtime tool-call markup — three parallel invocations of the shape:
<functions.exec>
<parameter name="cmd">cd <local-repo> && git status</parameter>
</invoke>

Note the mismatched </invoke> closer, consistent with model-emitted text rather than a vendor serializer.

Expected instead: the qoder route is documented as a text/reasoning-only surface (tools disabled, Codex owns tool control); none of this scaffold should reach the client.

Reproduction

  1. Configure the provider: adapter qoder, baseUrl https://qoder.com, authMode key (official PAT).
  2. Route an agent-style Codex turn through it — e.g. ask Codex to check git status of a few local repos.
  3. Observe the assistant text in Codex containing the vendor <system-reminder> ("MCP lazy-loading is active", "## Connected MCP servers") and <functions.exec> markup.

Intermittent — not every turn. Turns that are plain Q&A are less likely to trigger it than agent-style prompts.

Version

2.49.0

Operating system

macOS (Darwin 25.6.0, arm64), Node v24.18.0

Provider and model

qoder

Logs or error output

Screenshots and supporting files

  • src/adapters/qoder/adapter.ts spawns the vendor CLI with --tools "" --strict-mcp-config --setting-sources "" --max-turns 1 --no-session-persistence, and src/adapters/coding-agent/protocol.ts documents "Codex retains tool control; vendor tools are never invoked". The route is contractually a pure text/reasoning surface.
  • The installed @qoder-ai/qodercli@1.1.48 bundle still contains the MCP reminder builder (## Connected MCP servers, ## Available tools, mcp_list), and the leaked reminder listed the local machine's MCP servers — i.e. the spawned CLI appears to initialize its MCP/agent layer despite those flags.
  • The parser maps only text_delta / thinking_delta / tool_use frames and forwards text deltas verbatim, so vendor scaffold content inside a text frame reaches the client unfiltered.
  • Suggested direction: either make the CLI truly run with MCP/tools disabled, or have the adapter detect and sanitize (or fail closed on) vendor scaffold content — system-reminder blocks and framework tool-call markup — in the text channel.

Redacted configuration

{
  "providers": {
    "qoder": {
      "adapter": "qoder",
      "baseUrl": "https://qoder.com",
      "authMode": "key",
      "apiKey": "***"
    }
  }
}

Checks

  • I searched existing issues and documentation.
  • I removed secrets, tokens, account details, request credentials, and personal data.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinglanded-via-maintainerOriginal PR closed after landing via a maintainer merge trainproviderProvider adapters, OpenAI-compat presets, upstream API quirkstoolstool_calls, MCP, web-search / sidecar tools

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions