-
fix(responses): tolerate non-function tool types from Codex CLI (#187)
发布于
2026-06-03 13:02:01 +00:00 The /v1/responses shim validated tools with a strict z.literal('function'),
so requests from the Codex CLI (which sends built-in tools like web_search /
local_shell alongside its function tools) failed with
"tools.N.type: Invalid literal value, expected function" and the whole run
errored.Relax the tool schema to accept any
type, and forward only function tools to
the chat-completions upstream (dropping web_search/local_shell, which providers
reject anyway). The function tools that do the work (shell/exec, apply_patch)
are preserved. Lets Codex-driven agents route through the gateway.下载附件