page-agent-sdk 3.10.0 → 3.10.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "page-agent-sdk",
3
- "version": "3.10.0",
3
+ "version": "3.10.2",
4
4
  "type": "module",
5
5
  "description": "AI agent SDK for web pages — embed a chat assistant that edits page data via schema-validated tools. A lighter, framework-agnostic alternative to CopilotKit/LangChain for in-page JSON-editing agents. Vue-bundled; works with DeepSeek, OpenAI, MCP.",
6
6
  "main": "./dist/page-agent-sdk.umd.cjs",
package/types/index.d.ts CHANGED
@@ -15,6 +15,10 @@ export interface ProxyLlmOptions {
15
15
  headers?: Record<string, string>;
16
16
  }
17
17
  export declare function createProxyLlm(opts: ProxyLlmOptions): import('@langchain/core/language_models/chat_models').BaseChatModel;
18
+ /** 检测 garbled 工具调用文本(DeepSeek DSML/伪 XML 泄漏到正文) */
19
+ export declare function detectGarbledToolCall(content: string): boolean;
20
+ /** 检测过程性收口(短文本 + 过渡模式如「我先看看…稍后委派」+ 无完成动词)—— createAgent 据此有界回灌(≤2) */
21
+ export declare function detectTransitionalReply(content: string): boolean;
18
22
  export interface ConstructOpts {
19
23
  temperature?: number;
20
24
  maxTokens?: number;