Skip to content

Commit b3c9af4

Browse files
committed
docs: 补充 OpenAI MCP 工具列表注释
1 parent 23e1257 commit b3c9af4

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

src/services/api/openai/index.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,14 @@ import {
4747
TOOL_SEARCH_TOOL_NAME,
4848
} from '@claude-code-best/builtin-tools/tools/ToolSearchTool/prompt.js'
4949

50+
/**
51+
* Mirrors the Anthropic request path's deferred-tool announcement for OpenAI.
52+
*
53+
* OpenAI-compatible endpoints cannot consume Anthropic's `defer_loading` or
54+
* `tool_reference` beta payloads directly, so the model needs the same textual
55+
* list of deferred MCP tool names that Anthropic receives before it can ask
56+
* ToolSearchTool to load their full schemas.
57+
*/
5058
function prependDeferredToolListIfNeeded(
5159
messages: Message[],
5260
tools: Tools,

0 commit comments

Comments
 (0)