Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions packages/website/src/pages/docs/features/models/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,39 @@ const pageAgent = new PageAgent({
/>
</section>

<section className="mb-10">
<Heading id="orcarouter" className="text-2xl font-semibold mb-3">
OrcaRouter
</Heading>
<p className="text-sm text-gray-600 dark:text-gray-400 mb-4">
{isZh
? 'OrcaRouter 是一个 OpenAI 兼容网关,可将请求路由到多家上游模型(OpenAI、Anthropic、Google 等)。将 baseURL 指向 OrcaRouter 端点,并使用带命名空间的模型 ID。'
: 'OrcaRouter is an OpenAI-compatible gateway that routes requests to upstream models from multiple providers (OpenAI, Anthropic, Google, and more). Point baseURL at the OrcaRouter endpoint and use a namespaced model ID.'}
</p>
<CodeEditor
code={`// OpenAI-compatible gateway
const pageAgent = new PageAgent({
baseURL: 'https://api.orcarouter.ai/v1',
apiKey: 'sk-orca-...',
model: 'openai/gpt-5.5' // or 'anthropic/claude-sonnet-4.6', 'orcarouter/auto'

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Do not recommend Claude through OrcaRouter without a patch

When users choose the documented anthropic/claude-sonnet-4.6 alternative, PageAgentCore always invokes the LLM with toolChoiceName: 'AgentOutput' (packages/core/src/PageAgentCore.ts:285-287), and modelPatch treats the OrcaRouter URL as a non-OpenRouter Claude provider, rewriting OpenAI tool_choice into Anthropic-native { type: 'tool', name: ... } (packages/llms/src/utils.ts:88-104). OrcaRouter's /v1/chat/completions docs describe OpenAI-compatible tools/tool_choice for this endpoint, so the copied configuration sends the wrong tool-choice shape for Claude and can fail before PageAgent gets a tool call; either omit this Claude alternative or document/fix the required request-body transform.

Useful? React with 👍 / 👎.

});`}
/>
<div className="mt-4 p-4 bg-blue-50 dark:bg-blue-950/20 rounded-lg border border-blue-200 dark:border-blue-800">
<ul className="text-sm text-gray-700 dark:text-gray-300 space-y-2 list-disc pl-5">
<li>
{isZh
? 'OrcaRouter 使用带命名空间的模型 ID(如 openai/gpt-5.5、anthropic/claude-sonnet-4.6)。'
: 'OrcaRouter uses namespaced model IDs such as openai/gpt-5.5 and anthropic/claude-sonnet-4.6.'}
</li>
<li>
{isZh
? 'orcarouter/auto 是自适应路由,会按请求选择上游模型;如需稳定的 tool call,建议固定一个支持 tool call 的模型(如 openai/gpt-5.5 或 anthropic/claude-sonnet-4.6)。'
: 'orcarouter/auto is an adaptive router that picks an upstream model per request; for reliable tool calls, pin a tool-call-capable model such as openai/gpt-5.5 or anthropic/claude-sonnet-4.6.'}
</li>
</ul>
</div>
</section>

<section className="mb-10">
<Heading id="free-testing-api">{isZh ? '免费测试接口' : 'Free Testing API'}</Heading>
<p className="text-sm text-gray-600 dark:text-gray-400 mb-4">
Expand Down