page-agent-sdk 2.10.2 → 2.10.3
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/README.md +11 -11
- package/README.zh-CN.md +11 -11
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
# page-agent-sdk
|
|
2
2
|
|
|
3
|
-
> **[English](
|
|
3
|
+
> **[English](https://github.com/whyymj/chat-sdk/blob/master/README.md)** · **[中文](https://github.com/whyymj/chat-sdk/blob/master/README.zh-CN.md)**
|
|
4
4
|
|
|
5
5
|
> Give your web page an **AI assistant that edits the page itself**. Mount a chat dialog in one line; the AI reads/writes page data safely via schema-validated tools — "conversational" building/editing/ops.
|
|
6
6
|
|
|
7
|
-
> **AI agent integration**: see [Agent Integration Cheat Sheet](#agent-integration-cheat-sheet-for-ai-agents) below (exports / options / extension points / built-in tools / file structure). Architecture & gotchas in [`CLAUDE.md`](
|
|
7
|
+
> **AI agent integration**: see [Agent Integration Cheat Sheet](#agent-integration-cheat-sheet-for-ai-agents) below (exports / options / extension points / built-in tools / file structure). Architecture & gotchas in [`CLAUDE.md`](https://github.com/whyymj/chat-sdk/blob/master/CLAUDE.md).
|
|
8
8
|
|
|
9
9
|
[](https://www.npmjs.com/package/page-agent-sdk)
|
|
10
|
-
[](
|
|
10
|
+
[](https://github.com/whyymj/chat-sdk/blob/master/LICENSE)
|
|
11
11
|
[](#self-tests)
|
|
12
12
|
|
|
13
13
|
---
|
|
@@ -446,12 +446,12 @@ function switchTo(i: number) {
|
|
|
446
446
|
|
|
447
447
|
| Doc | Contents |
|
|
448
448
|
|---|---|
|
|
449
|
-
| [Doc Index](
|
|
450
|
-
| [Usage Guide](
|
|
451
|
-
| [Architecture](
|
|
452
|
-
| [Context & Compression](
|
|
453
|
-
| [File Overview](
|
|
454
|
-
| [CLAUDE.md](
|
|
449
|
+
| [Doc Index](https://github.com/whyymj/chat-sdk/blob/master/doc/README.en.md) | Navigation + other info sources (specs/changes/tests) |
|
|
450
|
+
| [Usage Guide](https://github.com/whyymj/chat-sdk/blob/master/doc/usage-guide.en.md) | Install / options / capability deep-dive / custom middleware / FAQ |
|
|
451
|
+
| [Architecture](https://github.com/whyymj/chat-sdk/blob/master/doc/architecture.md) *(Chinese)* | Layering / control flow / window-op safety flow |
|
|
452
|
+
| [Context & Compression](https://github.com/whyymj/chat-sdk/blob/master/doc/context-management.md) *(Chinese)* | Context composition / 4-layer compression / flow diagrams |
|
|
453
|
+
| [File Overview](https://github.com/whyymj/chat-sdk/blob/master/doc/architecture-files.md) *(Chinese)* | Per-file responsibilities / deps / data flow |
|
|
454
|
+
| [CLAUDE.md](https://github.com/whyymj/chat-sdk/blob/master/CLAUDE.md) | **agent must-read** · architecture / gotchas / coding conventions |
|
|
455
455
|
|
|
456
456
|
## Self-tests
|
|
457
457
|
|
|
@@ -532,8 +532,8 @@ npm test
|
|
|
532
532
|
|
|
533
533
|
## Relationship to Deep Agents
|
|
534
534
|
|
|
535
|
-
Borrows the harness idea from [Deep Agents](https://github.com/langchain-ai/deepagents) (ReAct + middleware + planning + skills + memory + context management), but implemented in-house: no LangGraph/langchain full bundle; browser-oriented (persistence via IndexedDB, not server-side DB); context via input compression + memory trim + large-result offload, rather than per-step checkpointer archival. See [Context & Compression - Differences from Deep Agents](
|
|
535
|
+
Borrows the harness idea from [Deep Agents](https://github.com/langchain-ai/deepagents) (ReAct + middleware + planning + skills + memory + context management), but implemented in-house: no LangGraph/langchain full bundle; browser-oriented (persistence via IndexedDB, not server-side DB); context via input compression + memory trim + large-result offload, rather than per-step checkpointer archival. See [Context & Compression - Differences from Deep Agents](https://github.com/whyymj/chat-sdk/blob/master/doc/context-management.md#七与-deep-agents-的差异).
|
|
536
536
|
|
|
537
537
|
## License
|
|
538
538
|
|
|
539
|
-
[ISC](
|
|
539
|
+
[ISC](https://github.com/whyymj/chat-sdk/blob/master/LICENSE)
|
package/README.zh-CN.md
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
# page-agent-sdk
|
|
2
2
|
|
|
3
|
-
> **[English](
|
|
3
|
+
> **[English](https://github.com/whyymj/chat-sdk/blob/master/README.md)** · **[中文](https://github.com/whyymj/chat-sdk/blob/master/README.zh-CN.md)**
|
|
4
4
|
|
|
5
5
|
> 给网页一个**会改页面的 AI 助手**。一行代码挂载对话框,AI 通过工具按 schema 安全读写页面数据,实现「对话式」搭建/编辑/运维。
|
|
6
6
|
|
|
7
|
-
> **AI agent 接入**:直接看下方「[Agent 接入速查](#agent-接入速查给-ai-agent-读)」(导出 / 选项表 / 扩展点 / 内置工具 / 文件结构),架构与约定坑见 [`CLAUDE.md`](
|
|
7
|
+
> **AI agent 接入**:直接看下方「[Agent 接入速查](#agent-接入速查给-ai-agent-读)」(导出 / 选项表 / 扩展点 / 内置工具 / 文件结构),架构与约定坑见 [`CLAUDE.md`](https://github.com/whyymj/chat-sdk/blob/master/CLAUDE.md)。
|
|
8
8
|
|
|
9
9
|
[](https://www.npmjs.com/package/page-agent-sdk)
|
|
10
|
-
[](
|
|
10
|
+
[](https://github.com/whyymj/chat-sdk/blob/master/LICENSE)
|
|
11
11
|
[](#自测)
|
|
12
12
|
|
|
13
13
|
---
|
|
@@ -391,12 +391,12 @@ function switchTo(i: number) {
|
|
|
391
391
|
|
|
392
392
|
| 文档 | 内容 |
|
|
393
393
|
|---|---|
|
|
394
|
-
| [文档索引](
|
|
395
|
-
| [使用手册](
|
|
396
|
-
| [功能架构](
|
|
397
|
-
| [上下文与压缩](
|
|
398
|
-
| [文件全览](
|
|
399
|
-
| [CLAUDE.md](
|
|
394
|
+
| [文档索引](https://github.com/whyymj/chat-sdk/blob/master/doc/README.md) | 各文档导航 + 其他信息源(规范/变更/自测) |
|
|
395
|
+
| [使用手册](https://github.com/whyymj/chat-sdk/blob/master/doc/usage-guide.md) | 安装 / 配置项 / 能力详解 / 自定义中间件 / FAQ |
|
|
396
|
+
| [功能架构](https://github.com/whyymj/chat-sdk/blob/master/doc/architecture.md) | 分层 / 控制流 / 数据操作安全流 |
|
|
397
|
+
| [上下文与压缩](https://github.com/whyymj/chat-sdk/blob/master/doc/context-management.md) | 上下文组成 / 4 层压缩 / 流程图 |
|
|
398
|
+
| [文件全览](https://github.com/whyymj/chat-sdk/blob/master/doc/architecture-files.md) | 逐文件职责 / 依赖 / 数据流 |
|
|
399
|
+
| [CLAUDE.md](https://github.com/whyymj/chat-sdk/blob/master/CLAUDE.md) | **agent 必读** · 架构要点 / 约定坑 / 编码规范 |
|
|
400
400
|
|
|
401
401
|
## 自测
|
|
402
402
|
|
|
@@ -477,8 +477,8 @@ npm test
|
|
|
477
477
|
|
|
478
478
|
## 与 Deep Agents 的关系
|
|
479
479
|
|
|
480
|
-
借鉴 [Deep Agents](https://github.com/langchain-ai/deepagents) 的 harness 思路(ReAct + 中间件 + planning + skills + memory + context 管理),但自研实现:不引 LangGraph/langchain 整包;面向浏览器端(持久化用 IndexedDB 而非服务端 DB);上下文用输入压缩 + 内存裁剪 + 大结果 offload,而非每步 checkpointer 存档。详见 [上下文与压缩 - 与 Deep Agents 的差异](
|
|
480
|
+
借鉴 [Deep Agents](https://github.com/langchain-ai/deepagents) 的 harness 思路(ReAct + 中间件 + planning + skills + memory + context 管理),但自研实现:不引 LangGraph/langchain 整包;面向浏览器端(持久化用 IndexedDB 而非服务端 DB);上下文用输入压缩 + 内存裁剪 + 大结果 offload,而非每步 checkpointer 存档。详见 [上下文与压缩 - 与 Deep Agents 的差异](https://github.com/whyymj/chat-sdk/blob/master/doc/context-management.md#七与-deep-agents-的差异)。
|
|
481
481
|
|
|
482
482
|
## License
|
|
483
483
|
|
|
484
|
-
[ISC](
|
|
484
|
+
[ISC](https://github.com/whyymj/chat-sdk/blob/master/LICENSE)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "page-agent-sdk",
|
|
3
|
-
"version": "2.10.
|
|
3
|
+
"version": "2.10.3",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "框架无关的页面内 Agent JS SDK —— 以对话框形态挂载到任意网页,通过自定义 tool 读写宿主预注册的数据槽(经 schema 校验 + jsonPath 增量 patch + 快照回退;GET 抓文档),具备 planning/skills/虚拟工作区/context 管理能力。Vue 打包进库,使用者无需安装 Vue。",
|
|
6
6
|
"main": "./dist/page-agent-sdk.umd.cjs",
|