@agentskit/doc-bridge 1.2.1 → 1.2.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/CHANGELOG.md +11 -1
- package/CONTRIBUTING.md +1 -1
- package/README.md +3 -3
- package/action.yml +9 -2
- package/dist/cli/program.js +18 -5
- package/dist/cli/program.js.map +1 -1
- package/dist/index.d.ts +39 -2
- package/dist/index.js +46 -5
- package/dist/index.js.map +1 -1
- package/docs/MARKETPLACE.md +6 -0
- package/docs/POSITIONING.md +12 -1
- package/docs/chat-and-rag.md +1 -1
- package/docs/examples.md +9 -1
- package/docs/for-agents.md +12 -4
- package/docs/getting-started.md +10 -0
- package/docs/guides/cli-map.md +153 -0
- package/docs/guides/gate-ci.md +64 -0
- package/docs/guides/index-and-query.md +75 -0
- package/docs/guides/install-and-run.md +84 -0
- package/docs/guides/mcp-agents.md +63 -0
- package/docs/guides/memory-pipeline.md +105 -0
- package/docs/guides/meta.json +11 -0
- package/docs/index.md +48 -13
- package/docs/mcp.md +9 -0
- package/docs/meta.json +8 -2
- package/docs/playbook/doc-bridge-pattern.md +1 -1
- package/docs/query.md +47 -23
- package/ecosystem-upstream.json +1 -1
- package/ecosystem.json +108 -30
- package/package.json +7 -5
- package/src/conformance/ecosystem-contract.ts +22 -3
- package/src/federation/ecosystem-llms.ts +67 -0
- package/src/index.ts +6 -0
- package/src/playbook/doc-bridge-pattern.ts +1 -1
- package/src/version.ts +1 -1
package/docs/index.md
CHANGED
|
@@ -1,23 +1,58 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Documentation
|
|
3
|
-
description:
|
|
3
|
+
description: Practical Doc Bridge paths for humans, agents, PR gates, and MCP — one repository, two audiences.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Documentation
|
|
7
7
|
|
|
8
|
-
Doc Bridge keeps one repository useful to
|
|
8
|
+
Doc Bridge keeps **one repository** useful to people and coding agents. Pick the shortest path:
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
- **Route an agent:** [For agents](./for-agents.md)
|
|
12
|
-
- **Block stale context in PRs:** [GitHub Marketplace](./MARKETPLACE.md)
|
|
13
|
-
- **Connect an MCP client:** [MCP](./mcp.md)
|
|
10
|
+
## Start
|
|
14
11
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
12
|
+
| Goal | Page |
|
|
13
|
+
| --- | --- |
|
|
14
|
+
| Install + 60s proof | [Getting started](./getting-started.md) |
|
|
15
|
+
| Guided install | [Install and run](./guides/install-and-run.md) |
|
|
16
|
+
| Machine-first entry | [For agents](./for-agents.md) · site route `/for-agents` |
|
|
17
|
+
| PR freshness gate | [Gate and CI](./guides/gate-ci.md) · [Marketplace](./MARKETPLACE.md) |
|
|
18
|
+
|
|
19
|
+
## Build workflows
|
|
20
|
+
|
|
21
|
+
| Goal | Page |
|
|
22
|
+
| --- | --- |
|
|
23
|
+
| Index + resolve ownership | [Index and query](./guides/index-and-query.md) · [Query](./query.md) |
|
|
24
|
+
| MCP for Cursor / Claude | [MCP for agents](./guides/mcp-agents.md) · [MCP](./mcp.md) |
|
|
25
|
+
| Memory digest → draft docs | [Memory pipeline](./guides/memory-pipeline.md) |
|
|
26
|
+
| Every CLI command | [CLI map](./guides/cli-map.md) · [CLI reference](./spec/cli.md) |
|
|
27
|
+
| Config sketches | [Examples](./examples.md) |
|
|
28
|
+
| Optional chat / RAG | [Chat and RAG](./chat-and-rag.md) · [Ollama demo](./ollama-demo.md) |
|
|
29
|
+
|
|
30
|
+
## How it works
|
|
31
|
+
|
|
32
|
+
```text
|
|
33
|
+
Repository docs
|
|
34
|
+
│
|
|
35
|
+
▼
|
|
36
|
+
ak-docs index ──► .doc-bridge/index.json + llms.txt
|
|
37
|
+
│
|
|
38
|
+
├─► Human guides (Fumadocs / Docusaurus / md)
|
|
39
|
+
├─► Agent handoff (CLI / MCP)
|
|
40
|
+
└─► PR gate (Marketplace Action)
|
|
21
41
|
```
|
|
22
42
|
|
|
23
|
-
|
|
43
|
+
1. **Index** — map ownership from corpus + config
|
|
44
|
+
2. **Resolve** — deterministic handoffs (`startHere`, `editRoots`, `checks`)
|
|
45
|
+
3. **Gate** — fail stale context before agents run
|
|
46
|
+
4. **Promote** — optional memory → draft docs loop
|
|
47
|
+
|
|
48
|
+
## Product vs reference
|
|
49
|
+
|
|
50
|
+
- **Start / Guides** — get value in minutes
|
|
51
|
+
- **Product** — [Positioning](./POSITIONING.md), [Playbook pattern](./playbook/doc-bridge-pattern.md), [Recipes](./recipes/index-pipeline.md)
|
|
52
|
+
- **Reference** — [CLI](./spec/cli.md), [Config](./spec/config-v1.md), [Schemas](./schemas/agent-handoff-v1.md)
|
|
53
|
+
|
|
54
|
+
Machine surfaces: [llms.txt](/llms.txt) · [llms-full.txt](/llms-full.txt) · [raw Markdown](/raw/getting-started.md)
|
|
55
|
+
|
|
56
|
+
## Ecosystem
|
|
57
|
+
|
|
58
|
+
Part of AgentsKit — next to [AgentsKit](https://www.agentskit.io), [Registry](https://registry.agentskit.io), [Chat](https://chat.agentskit.io), [Playbook](https://playbook.agentskit.io), and [AKOS](https://akos.agentskit.io).
|
package/docs/mcp.md
CHANGED
|
@@ -62,3 +62,12 @@ Before editing a package:
|
|
|
62
62
|
2. Open `startHere`
|
|
63
63
|
3. Stay inside `editRoots`
|
|
64
64
|
4. Run `checks` before claiming done
|
|
65
|
+
|
|
66
|
+
## Related
|
|
67
|
+
|
|
68
|
+
- [MCP for agents guide](./guides/mcp-agents.md)
|
|
69
|
+
- [CLI map](./guides/cli-map.md)
|
|
70
|
+
- [Memory pipeline](./guides/memory-pipeline.md)
|
|
71
|
+
- [For agents](./for-agents.md)
|
|
72
|
+
- [Index and query](./guides/index-and-query.md)
|
|
73
|
+
- [Skill](./skills/doc-bridge.md)
|
package/docs/meta.json
CHANGED
|
@@ -2,19 +2,25 @@
|
|
|
2
2
|
"title": "Doc Bridge",
|
|
3
3
|
"pages": [
|
|
4
4
|
"index",
|
|
5
|
+
"---Start---",
|
|
5
6
|
"getting-started",
|
|
7
|
+
"guides",
|
|
6
8
|
"for-agents",
|
|
7
9
|
"MARKETPLACE",
|
|
8
|
-
"
|
|
10
|
+
"---Build---",
|
|
9
11
|
"mcp",
|
|
10
12
|
"query",
|
|
11
13
|
"examples",
|
|
12
14
|
"chat-and-rag",
|
|
13
15
|
"ollama-demo",
|
|
16
|
+
"---Product---",
|
|
17
|
+
"POSITIONING",
|
|
14
18
|
"playbook",
|
|
15
19
|
"recipes",
|
|
20
|
+
"---Reference---",
|
|
16
21
|
"schemas",
|
|
17
22
|
"skills",
|
|
18
|
-
"spec"
|
|
23
|
+
"spec",
|
|
24
|
+
"RELEASE"
|
|
19
25
|
]
|
|
20
26
|
}
|
|
@@ -113,4 +113,4 @@ Teams track handoff % and human-bridge % daily.
|
|
|
113
113
|
- npm: https://www.npmjs.com/package/@agentskit/doc-bridge
|
|
114
114
|
- repo: https://github.com/AgentsKit-io/doc-bridge
|
|
115
115
|
- skill: [doc-bridge skill](../skills/doc-bridge.md)
|
|
116
|
-
- landing: https://
|
|
116
|
+
- landing: https://doc-bridge.agentskit.io/
|
package/docs/query.md
CHANGED
|
@@ -1,34 +1,58 @@
|
|
|
1
1
|
---
|
|
2
|
-
title:
|
|
3
|
-
description:
|
|
2
|
+
title: Query
|
|
3
|
+
description: Deterministic ownership and documentation lookup — no model, no re-scan of the repo.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
#
|
|
6
|
+
# Query
|
|
7
7
|
|
|
8
|
-
The query layer reads
|
|
9
|
-
the repository again and does not call a model. Keep exact ownership resolution,
|
|
10
|
-
ranked document search, and handoff output deterministic.
|
|
8
|
+
The query layer reads `.doc-bridge/index.json` only. It does **not** re-scan the repository and does **not** call a model.
|
|
11
9
|
|
|
12
|
-
##
|
|
10
|
+
## Commands
|
|
13
11
|
|
|
14
|
-
|
|
15
|
-
-
|
|
16
|
-
-
|
|
17
|
-
-
|
|
18
|
-
- MCP consumers: `src/mcp/server.ts`
|
|
12
|
+
```bash
|
|
13
|
+
# Machine-readable handoff (for agents / MCP)
|
|
14
|
+
ak-docs query package auth --agent
|
|
15
|
+
ak-docs query ownership auth --agent
|
|
19
16
|
|
|
20
|
-
|
|
17
|
+
# Human-readable
|
|
18
|
+
ak-docs query package auth --text
|
|
21
19
|
|
|
22
|
-
|
|
20
|
+
# Discovery
|
|
21
|
+
ak-docs list packages --text
|
|
22
|
+
ak-docs ask "where do I change billing?"
|
|
23
|
+
```
|
|
23
24
|
|
|
24
|
-
##
|
|
25
|
+
## What you get
|
|
25
26
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
27
|
+
An **AgentHandoff** (v1) with stable fields:
|
|
28
|
+
|
|
29
|
+
| Field | Use |
|
|
30
|
+
| --- | --- |
|
|
31
|
+
| `startHere` | First file the agent should open |
|
|
32
|
+
| `editRoots` | Allowed write paths |
|
|
33
|
+
| `checks` | Verification commands |
|
|
34
|
+
| `humanDoc` | Parallel human documentation |
|
|
35
|
+
|
|
36
|
+
Schema: [AgentHandoff v1](./schemas/agent-handoff-v1.md) · Index: [DocBridgeIndex v1](./schemas/doc-bridge-index-v1.md)
|
|
37
|
+
|
|
38
|
+
## When to use which surface
|
|
39
|
+
|
|
40
|
+
| Need | Surface |
|
|
41
|
+
| --- | --- |
|
|
42
|
+
| Agent about to edit a module | `query … --agent` or MCP `handoff.resolve` |
|
|
43
|
+
| Human browsing ownership | `query … --text` / `list packages` |
|
|
44
|
+
| Free-form question with known docs | `ask "…"` (local first) |
|
|
45
|
+
| Unresolved semantic question | Optional [Chat and RAG](./chat-and-rag.md) backend |
|
|
46
|
+
|
|
47
|
+
## Guarantees
|
|
48
|
+
|
|
49
|
+
- Same inputs → same handoff JSON (deterministic)
|
|
50
|
+
- Breaking field meaning requires a **new schema version**, not silent reinterpretation of v1
|
|
51
|
+
- Gate/CI can require a fresh index so agents never see stale ownership
|
|
52
|
+
|
|
53
|
+
## Related
|
|
32
54
|
|
|
33
|
-
|
|
34
|
-
|
|
55
|
+
- [Guide: Index and query](./guides/index-and-query.md)
|
|
56
|
+
- [For agents](./for-agents.md)
|
|
57
|
+
- [CLI reference](./spec/cli.md)
|
|
58
|
+
- [MCP](./mcp.md)
|
package/ecosystem-upstream.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"repository": "AgentsKit-io/agentskit",
|
|
4
4
|
"ref": "main",
|
|
5
5
|
"files": {
|
|
6
|
-
"ecosystem.json": "
|
|
6
|
+
"ecosystem.json": "04995ca6863f744495b672d6e3a64162a415caf4cacb3ba8cdd3521bc90c4879",
|
|
7
7
|
"ecosystem-claims.json": "0100f7fbc18a3381bb943aaf8151dd5d107f82c02c470e3c586b7d694c6be42e"
|
|
8
8
|
}
|
|
9
9
|
}
|
package/ecosystem.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 2,
|
|
3
|
-
"$comment": "Canonical registry of AgentsKit ecosystem products. Stable identity lives
|
|
3
|
+
"$comment": "Canonical registry of AgentsKit ecosystem products. Stable identity lives in products[] (seven). Numeric values live in the generated ecosystem-claims ledger. The properties array is the full seven-product v1 projection of products[] (same order) for sibling consumers.",
|
|
4
4
|
"parentBrand": {
|
|
5
5
|
"id": "agentskit",
|
|
6
6
|
"name": "AgentsKit"
|
|
@@ -27,7 +27,14 @@
|
|
|
27
27
|
"navigation": {
|
|
28
28
|
"showInBar": true,
|
|
29
29
|
"order": 0,
|
|
30
|
-
"next": [
|
|
30
|
+
"next": [
|
|
31
|
+
"registry",
|
|
32
|
+
"agentskit-chat",
|
|
33
|
+
"playbook",
|
|
34
|
+
"doc-bridge",
|
|
35
|
+
"code-review",
|
|
36
|
+
"akos"
|
|
37
|
+
]
|
|
31
38
|
}
|
|
32
39
|
},
|
|
33
40
|
{
|
|
@@ -51,7 +58,14 @@
|
|
|
51
58
|
"navigation": {
|
|
52
59
|
"showInBar": true,
|
|
53
60
|
"order": 1,
|
|
54
|
-
"next": [
|
|
61
|
+
"next": [
|
|
62
|
+
"agentskit",
|
|
63
|
+
"agentskit-chat",
|
|
64
|
+
"playbook",
|
|
65
|
+
"doc-bridge",
|
|
66
|
+
"code-review",
|
|
67
|
+
"akos"
|
|
68
|
+
]
|
|
55
69
|
}
|
|
56
70
|
},
|
|
57
71
|
{
|
|
@@ -74,7 +88,14 @@
|
|
|
74
88
|
"navigation": {
|
|
75
89
|
"showInBar": true,
|
|
76
90
|
"order": 2,
|
|
77
|
-
"next": [
|
|
91
|
+
"next": [
|
|
92
|
+
"agentskit",
|
|
93
|
+
"registry",
|
|
94
|
+
"playbook",
|
|
95
|
+
"doc-bridge",
|
|
96
|
+
"code-review",
|
|
97
|
+
"akos"
|
|
98
|
+
]
|
|
78
99
|
}
|
|
79
100
|
},
|
|
80
101
|
{
|
|
@@ -98,7 +119,14 @@
|
|
|
98
119
|
"navigation": {
|
|
99
120
|
"showInBar": true,
|
|
100
121
|
"order": 3,
|
|
101
|
-
"next": [
|
|
122
|
+
"next": [
|
|
123
|
+
"agentskit",
|
|
124
|
+
"registry",
|
|
125
|
+
"agentskit-chat",
|
|
126
|
+
"doc-bridge",
|
|
127
|
+
"code-review",
|
|
128
|
+
"akos"
|
|
129
|
+
]
|
|
102
130
|
}
|
|
103
131
|
},
|
|
104
132
|
{
|
|
@@ -121,7 +149,14 @@
|
|
|
121
149
|
"navigation": {
|
|
122
150
|
"showInBar": true,
|
|
123
151
|
"order": 4,
|
|
124
|
-
"next": [
|
|
152
|
+
"next": [
|
|
153
|
+
"agentskit",
|
|
154
|
+
"registry",
|
|
155
|
+
"agentskit-chat",
|
|
156
|
+
"playbook",
|
|
157
|
+
"code-review",
|
|
158
|
+
"akos"
|
|
159
|
+
]
|
|
125
160
|
}
|
|
126
161
|
},
|
|
127
162
|
{
|
|
@@ -142,9 +177,16 @@
|
|
|
142
177
|
"chat": "none"
|
|
143
178
|
},
|
|
144
179
|
"navigation": {
|
|
145
|
-
"showInBar":
|
|
180
|
+
"showInBar": false,
|
|
146
181
|
"order": 5,
|
|
147
|
-
"next": [
|
|
182
|
+
"next": [
|
|
183
|
+
"agentskit",
|
|
184
|
+
"registry",
|
|
185
|
+
"agentskit-chat",
|
|
186
|
+
"playbook",
|
|
187
|
+
"doc-bridge",
|
|
188
|
+
"akos"
|
|
189
|
+
]
|
|
148
190
|
}
|
|
149
191
|
},
|
|
150
192
|
{
|
|
@@ -187,17 +229,29 @@
|
|
|
187
229
|
"stats": "https://www.agentskit.io/api/stats.json"
|
|
188
230
|
},
|
|
189
231
|
{
|
|
190
|
-
"id": "
|
|
191
|
-
"name": "AgentsKit
|
|
192
|
-
"barLabel": "
|
|
193
|
-
"domain": "
|
|
194
|
-
"url": "https://
|
|
195
|
-
"repo": "AgentsKit-io/agentskit-
|
|
196
|
-
"tagline": "
|
|
197
|
-
"kind": "
|
|
198
|
-
"accent": "#
|
|
199
|
-
"llms": "https://
|
|
200
|
-
"stats": "https://
|
|
232
|
+
"id": "registry",
|
|
233
|
+
"name": "AgentsKit Registry",
|
|
234
|
+
"barLabel": "Registry",
|
|
235
|
+
"domain": "registry.agentskit.io",
|
|
236
|
+
"url": "https://registry.agentskit.io",
|
|
237
|
+
"repo": "AgentsKit-io/agentskit-registry",
|
|
238
|
+
"tagline": "Copy ready-made agents and own the source.",
|
|
239
|
+
"kind": "registry",
|
|
240
|
+
"accent": "#58A6FF",
|
|
241
|
+
"llms": "https://registry.agentskit.io/llms.txt",
|
|
242
|
+
"stats": "https://registry.agentskit.io/r/index.json"
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
"id": "agentskit-chat",
|
|
246
|
+
"name": "AgentsKit Chat",
|
|
247
|
+
"barLabel": "Chat",
|
|
248
|
+
"domain": "chat.agentskit.io",
|
|
249
|
+
"url": "https://chat.agentskit.io",
|
|
250
|
+
"repo": "AgentsKit-io/agentskit-chat",
|
|
251
|
+
"tagline": "Define one agent experience and deliver it across interfaces.",
|
|
252
|
+
"kind": "framework",
|
|
253
|
+
"accent": "#F59E0B",
|
|
254
|
+
"llms": "https://chat.agentskit.io/llms.txt"
|
|
201
255
|
},
|
|
202
256
|
{
|
|
203
257
|
"id": "playbook",
|
|
@@ -213,17 +267,41 @@
|
|
|
213
267
|
"stats": "https://playbook.agentskit.io/api/stats.json"
|
|
214
268
|
},
|
|
215
269
|
{
|
|
216
|
-
"id": "
|
|
217
|
-
"name": "
|
|
218
|
-
"barLabel": "
|
|
219
|
-
"domain": "
|
|
220
|
-
"url": "https://
|
|
221
|
-
"repo": "AgentsKit-io/
|
|
222
|
-
"tagline": "
|
|
223
|
-
"kind": "
|
|
224
|
-
"accent": "#
|
|
225
|
-
"llms": "https://
|
|
226
|
-
|
|
270
|
+
"id": "doc-bridge",
|
|
271
|
+
"name": "Doc Bridge",
|
|
272
|
+
"barLabel": "Doc Bridge",
|
|
273
|
+
"domain": "agentskit-io.github.io",
|
|
274
|
+
"url": "https://agentskit-io.github.io/doc-bridge/",
|
|
275
|
+
"repo": "AgentsKit-io/doc-bridge",
|
|
276
|
+
"tagline": "Turn repository documentation into executable agent handoffs.",
|
|
277
|
+
"kind": "developer-tool",
|
|
278
|
+
"accent": "#06B6D4",
|
|
279
|
+
"llms": "https://agentskit-io.github.io/doc-bridge/llms.txt"
|
|
280
|
+
},
|
|
281
|
+
{
|
|
282
|
+
"id": "code-review",
|
|
283
|
+
"name": "AgentsKit Code Review",
|
|
284
|
+
"barLabel": "Code Review",
|
|
285
|
+
"domain": "github.com",
|
|
286
|
+
"url": "https://github.com/AgentsKit-io/code-review-cli",
|
|
287
|
+
"repo": "AgentsKit-io/code-review-cli",
|
|
288
|
+
"tagline": "Run deep, low-noise review with the model already in use.",
|
|
289
|
+
"kind": "developer-tool",
|
|
290
|
+
"accent": "#F97316",
|
|
291
|
+
"llms": "https://raw.githubusercontent.com/AgentsKit-io/code-review-cli/main/llms.txt"
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
"id": "akos",
|
|
295
|
+
"name": "AgentsKit OS",
|
|
296
|
+
"barLabel": "AKOS",
|
|
297
|
+
"domain": "akos.agentskit.io",
|
|
298
|
+
"url": "https://akos.agentskit.io",
|
|
299
|
+
"repo": "AgentsKit-io/agentskit-os",
|
|
300
|
+
"tagline": "Run and govern agents in production.",
|
|
301
|
+
"kind": "product",
|
|
302
|
+
"accent": "#34D399",
|
|
303
|
+
"llms": "https://akos.agentskit.io/llms.txt",
|
|
304
|
+
"stats": "https://akos.agentskit.io/api/stats.json"
|
|
227
305
|
}
|
|
228
306
|
],
|
|
229
307
|
"builder": {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agentskit/doc-bridge",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.3",
|
|
4
4
|
"description": "Human↔agent documentation bridge — deterministic handoffs, doc-site links, memory→docs, optional AgentsKit RAG/chat.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -95,6 +95,7 @@
|
|
|
95
95
|
"access": "public"
|
|
96
96
|
},
|
|
97
97
|
"dependencies": {
|
|
98
|
+
"mermaid": "^11.16.0",
|
|
98
99
|
"zod": "^3.24.2"
|
|
99
100
|
},
|
|
100
101
|
"peerDependencies": {
|
|
@@ -126,16 +127,17 @@
|
|
|
126
127
|
}
|
|
127
128
|
},
|
|
128
129
|
"devDependencies": {
|
|
129
|
-
"@agentskit/chat": "0.
|
|
130
|
+
"@agentskit/chat": "0.4.0",
|
|
130
131
|
"@agentskit/core": "1.12.3",
|
|
132
|
+
"@agentskit/ink": "0.10.4",
|
|
131
133
|
"@agentskit/react": "0.7.4",
|
|
132
134
|
"@changesets/cli": "^2.31.0",
|
|
133
135
|
"@lhci/cli": "^0.15.1",
|
|
134
136
|
"@playwright/test": "1.61.1",
|
|
135
137
|
"@tailwindcss/postcss": "4.3.2",
|
|
136
138
|
"@types/node": "^22.15.3",
|
|
137
|
-
"@types/react": "19.
|
|
138
|
-
"@types/react-dom": "19.
|
|
139
|
+
"@types/react": "19.2.17",
|
|
140
|
+
"@types/react-dom": "19.2.3",
|
|
139
141
|
"@vitest/coverage-v8": "4.1.10",
|
|
140
142
|
"fumadocs-core": "15.6.5",
|
|
141
143
|
"fumadocs-mdx": "11.6.4",
|
|
@@ -166,5 +168,5 @@
|
|
|
166
168
|
"bugs": {
|
|
167
169
|
"url": "https://github.com/AgentsKit-io/doc-bridge/issues"
|
|
168
170
|
},
|
|
169
|
-
"homepage": "https://
|
|
171
|
+
"homepage": "https://doc-bridge.agentskit.io/"
|
|
170
172
|
}
|
|
@@ -50,7 +50,12 @@ const ManifestSchema = z.object({
|
|
|
50
50
|
schemaVersion: z.literal(2),
|
|
51
51
|
parentBrand: z.object({ id: NonEmptyStringSchema, name: NonEmptyStringSchema }).passthrough(),
|
|
52
52
|
products: z.array(ProductSchema).min(1),
|
|
53
|
-
|
|
53
|
+
// Historical four-product shim or full seven-product projection of products[].
|
|
54
|
+
properties: z
|
|
55
|
+
.array(LegacyPropertySchema)
|
|
56
|
+
.refine((value) => value.length === 4 || value.length === 7, {
|
|
57
|
+
message: 'must project either the legacy four products or the full seven-product catalog',
|
|
58
|
+
}),
|
|
54
59
|
builder: z.object({ id: NonEmptyStringSchema, name: NonEmptyStringSchema, url: HttpsUrlSchema }).passthrough().optional(),
|
|
55
60
|
}).passthrough()
|
|
56
61
|
|
|
@@ -88,7 +93,18 @@ const ClaimsSchema = z.object({
|
|
|
88
93
|
products: z.array(ClaimProductSchema),
|
|
89
94
|
}).passthrough()
|
|
90
95
|
|
|
91
|
-
|
|
96
|
+
/** Historical four-product shim order. */
|
|
97
|
+
const LEGACY_FOUR_PRODUCT_IDS = ['agentskit', 'akos', 'playbook', 'registry'] as const
|
|
98
|
+
/** Full seven-product projection order (matches products[]). */
|
|
99
|
+
const FULL_SEVEN_PRODUCT_IDS = [
|
|
100
|
+
'agentskit',
|
|
101
|
+
'registry',
|
|
102
|
+
'agentskit-chat',
|
|
103
|
+
'playbook',
|
|
104
|
+
'doc-bridge',
|
|
105
|
+
'code-review',
|
|
106
|
+
'akos',
|
|
107
|
+
] as const
|
|
92
108
|
|
|
93
109
|
export const parseCanonicalEcosystemContract = (
|
|
94
110
|
manifestInput: unknown,
|
|
@@ -120,7 +136,10 @@ export const parseCanonicalEcosystemContract = (
|
|
|
120
136
|
}
|
|
121
137
|
}
|
|
122
138
|
|
|
123
|
-
|
|
139
|
+
const propertyIds =
|
|
140
|
+
manifest.properties.length === 7 ? FULL_SEVEN_PRODUCT_IDS : LEGACY_FOUR_PRODUCT_IDS
|
|
141
|
+
|
|
142
|
+
for (const [index, id] of propertyIds.entries()) {
|
|
124
143
|
const legacy = manifest.properties[index]
|
|
125
144
|
const product = products.get(id)
|
|
126
145
|
if (!legacy || !product || legacy.id !== id || !product.surfaces.home) {
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Canonical AgentsKit ecosystem section for llms.txt (and similar machine indexes).
|
|
3
|
+
*
|
|
4
|
+
* All products should render this block with the same heading and line shape so
|
|
5
|
+
* agents can parse the seven-product mesh without per-repo inventiveness.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
export type EcosystemLlmsProduct = {
|
|
9
|
+
readonly id: string
|
|
10
|
+
readonly name: string
|
|
11
|
+
readonly role?: string
|
|
12
|
+
readonly promise: string
|
|
13
|
+
readonly maturity?: string
|
|
14
|
+
readonly surfaces: {
|
|
15
|
+
readonly home?: string
|
|
16
|
+
readonly docs?: string
|
|
17
|
+
readonly llms?: string
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export type FormatEcosystemLlmsBlockOptions = {
|
|
22
|
+
readonly products: readonly EcosystemLlmsProduct[]
|
|
23
|
+
/** When set, marks this product with **(current)**. */
|
|
24
|
+
readonly currentProductId?: string
|
|
25
|
+
/** Heading line without leading hashes — default `AgentsKit ecosystem`. */
|
|
26
|
+
readonly heading?: string
|
|
27
|
+
/**
|
|
28
|
+
* Prefer docs URL when available; otherwise home.
|
|
29
|
+
* Default: home, falling back to docs.
|
|
30
|
+
*/
|
|
31
|
+
readonly prefer?: 'home' | 'docs'
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Returns markdown lines for the shared ecosystem block, including a trailing blank line.
|
|
36
|
+
*/
|
|
37
|
+
export function formatEcosystemLlmsBlock(options: FormatEcosystemLlmsBlockOptions): string[] {
|
|
38
|
+
const heading = options.heading ?? 'AgentsKit ecosystem'
|
|
39
|
+
const prefer = options.prefer ?? 'home'
|
|
40
|
+
const lines: string[] = [`## ${heading}`, '']
|
|
41
|
+
|
|
42
|
+
for (const product of options.products) {
|
|
43
|
+
const primary =
|
|
44
|
+
prefer === 'docs'
|
|
45
|
+
? product.surfaces.docs ?? product.surfaces.home
|
|
46
|
+
: product.surfaces.home ?? product.surfaces.docs
|
|
47
|
+
if (!primary) continue
|
|
48
|
+
|
|
49
|
+
const current = product.id === options.currentProductId ? ' **(current)**' : ''
|
|
50
|
+
const role = product.role ? ` Role: \`${product.role}\`.` : ''
|
|
51
|
+
const maturity = product.maturity ? ` Maturity: ${product.maturity}.` : ''
|
|
52
|
+
const machine = product.surfaces.llms ? ` Machine index: ${product.surfaces.llms}` : ''
|
|
53
|
+
const promise = product.promise.trim()
|
|
54
|
+
const promiseSentence = /[.!?]$/.test(promise) ? promise : `${promise}.`
|
|
55
|
+
lines.push(
|
|
56
|
+
`- [${product.name}](${primary})${current} — ${promiseSentence}${role}${maturity}${machine}`,
|
|
57
|
+
)
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
lines.push('')
|
|
61
|
+
return lines
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/** Join the block into a single string ending with a newline. */
|
|
65
|
+
export function formatEcosystemLlmsSection(options: FormatEcosystemLlmsBlockOptions): string {
|
|
66
|
+
return `${formatEcosystemLlmsBlock(options).join('\n')}\n`
|
|
67
|
+
}
|
package/src/index.ts
CHANGED
|
@@ -65,6 +65,12 @@ export {
|
|
|
65
65
|
} from './validate.js'
|
|
66
66
|
|
|
67
67
|
export { buildDocBridgeIndex, type BuildIndexOptions, type BuildIndexResult } from './index-builder/build-index.js'
|
|
68
|
+
export {
|
|
69
|
+
formatEcosystemLlmsBlock,
|
|
70
|
+
formatEcosystemLlmsSection,
|
|
71
|
+
type EcosystemLlmsProduct,
|
|
72
|
+
type FormatEcosystemLlmsBlockOptions,
|
|
73
|
+
} from './federation/ecosystem-llms.js'
|
|
68
74
|
export {
|
|
69
75
|
scanHumanDocRecords,
|
|
70
76
|
scanHumanDocs,
|
|
@@ -111,7 +111,7 @@ Teams track handoff % and human-bridge % daily.
|
|
|
111
111
|
- npm: https://www.npmjs.com/package/@agentskit/doc-bridge
|
|
112
112
|
- repo: https://github.com/AgentsKit-io/doc-bridge
|
|
113
113
|
- skill: https://github.com/AgentsKit-io/doc-bridge/blob/master/docs/skills/doc-bridge.md
|
|
114
|
-
- landing: https://
|
|
114
|
+
- landing: https://doc-bridge.agentskit.io/
|
|
115
115
|
`
|
|
116
116
|
|
|
117
117
|
export const docBridgePatternPayload = () => ({
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const PACKAGE_VERSION = '1.2.
|
|
1
|
+
export const PACKAGE_VERSION = '1.2.3'
|