{isZh - ? 'PageAgentCore 提供两种不同性质的事件流,服务于不同的 UI 需求:' - : 'PageAgentCore provides two distinct event streams for different UI needs:'} + ? 'PageAgentCore 提供两种不同性质的事件流,方便 UI 渲染:' + : 'PageAgentCore provides two distinct event streams for UI rendering:'}
{/* Comparison Table */} @@ -59,9 +59,7 @@ export default function CustomUIDocs() {| - {isZh ? '特性' : 'Feature'} - | +Historical Events | @@ -90,7 +88,7 @@ export default function CustomUIDocs() { {isZh ? '持久化到 agent.history' : 'Persisted in agent.history'}- {isZh ? '瞬态,无存储' : 'Transient, not stored'} + {isZh ? '瞬态' : 'Transient'} | |||
|---|---|---|---|---|---|
| - {isZh ? '特性' : 'Feature'} - | +PageAgent | diff --git a/packages/website/src/pages/docs/features/custom-tools/page.tsx b/packages/website/src/pages/docs/features/custom-tools/page.tsx index 0a8194e..04e5590 100644 --- a/packages/website/src/pages/docs/features/custom-tools/page.tsx +++ b/packages/website/src/pages/docs/features/custom-tools/page.tsx @@ -32,22 +32,22 @@ import { PageAgent, tool } from 'page-agent' // override internal tool const customTools = { - ask_user: tool({ - description: - 'Ask the user or parent model a question and wait for their answer. Use this if you need more information or clarification.', - inputSchema: zod.object({ - question: zod.string(), - }), - execute: async function (this: PageAgent, input) { - const answer = await do_some_thing(input.question) - return "✅ Received user answer: " + answer - }, - }) + ask_user: tool({ + description: + 'Ask the user or parent model a question and wait for their answer. Use this if you need more information or clarification.', + inputSchema: zod.object({ + question: zod.string(), + }), + execute: async function (this: PageAgent, input) { + const answer = await do_some_thing(input.question) + return "✅ Received user answer: " + answer + }, + }) } // remove internal tool const customTools = { - ask_user: null // never ask user questions + scroll: null, // never scroll } const pageAgent = new PageAgent({customTools}) diff --git a/packages/website/src/pages/docs/integration/cdn-setup/page.tsx b/packages/website/src/pages/docs/integration/cdn-setup/page.tsx index f4a4a10..d09425d 100644 --- a/packages/website/src/pages/docs/integration/cdn-setup/page.tsx +++ b/packages/website/src/pages/docs/integration/cdn-setup/page.tsx @@ -30,7 +30,7 @@ export default function CdnSetup() {
|---|
| - {isZh ? '特性' : 'Feature'} - | +page-agent | diff --git a/packages/website/src/pages/docs/introduction/quick-start/page.tsx b/packages/website/src/pages/docs/introduction/quick-start/page.tsx index aefa1ac..e82e683 100644 --- a/packages/website/src/pages/docs/introduction/quick-start/page.tsx +++ b/packages/website/src/pages/docs/introduction/quick-start/page.tsx @@ -29,7 +29,7 @@ export default function QuickStart() {
|---|