@agentskit/doc-bridge 0.1.0-alpha.1

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.
@@ -0,0 +1,932 @@
1
+ import { z } from 'zod';
2
+
3
+ declare const AgentCorpusConfigSchema: z.ZodObject<{
4
+ root: z.ZodString;
5
+ index: z.ZodOptional<z.ZodString>;
6
+ include: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
7
+ exclude: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
8
+ okf: z.ZodOptional<z.ZodObject<{
9
+ requireType: z.ZodOptional<z.ZodBoolean>;
10
+ allowedTypes: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
11
+ }, "strict", z.ZodTypeAny, {
12
+ requireType?: boolean | undefined;
13
+ allowedTypes?: string[] | undefined;
14
+ }, {
15
+ requireType?: boolean | undefined;
16
+ allowedTypes?: string[] | undefined;
17
+ }>>;
18
+ }, "strict", z.ZodTypeAny, {
19
+ root: string;
20
+ index?: string | undefined;
21
+ include?: string[] | undefined;
22
+ exclude?: string[] | undefined;
23
+ okf?: {
24
+ requireType?: boolean | undefined;
25
+ allowedTypes?: string[] | undefined;
26
+ } | undefined;
27
+ }, {
28
+ root: string;
29
+ index?: string | undefined;
30
+ include?: string[] | undefined;
31
+ exclude?: string[] | undefined;
32
+ okf?: {
33
+ requireType?: boolean | undefined;
34
+ allowedTypes?: string[] | undefined;
35
+ } | undefined;
36
+ }>;
37
+ declare const HumanCorpusConfigSchema: z.ZodObject<{
38
+ plugin: z.ZodEnum<["plain-markdown", "fumadocs", "docusaurus", "mkdocs", "vitepress", "custom"]>;
39
+ options: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
40
+ }, "strict", z.ZodTypeAny, {
41
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
42
+ options?: Record<string, unknown> | undefined;
43
+ }, {
44
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
45
+ options?: Record<string, unknown> | undefined;
46
+ }>;
47
+ declare const DocBridgeConfigV1Schema: z.ZodObject<{
48
+ schemaVersion: z.ZodLiteral<1>;
49
+ project: z.ZodOptional<z.ZodObject<{
50
+ name: z.ZodOptional<z.ZodString>;
51
+ root: z.ZodOptional<z.ZodString>;
52
+ }, "strict", z.ZodTypeAny, {
53
+ root?: string | undefined;
54
+ name?: string | undefined;
55
+ }, {
56
+ root?: string | undefined;
57
+ name?: string | undefined;
58
+ }>>;
59
+ corpus: z.ZodObject<{
60
+ agent: z.ZodObject<{
61
+ root: z.ZodString;
62
+ index: z.ZodOptional<z.ZodString>;
63
+ include: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
64
+ exclude: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
65
+ okf: z.ZodOptional<z.ZodObject<{
66
+ requireType: z.ZodOptional<z.ZodBoolean>;
67
+ allowedTypes: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
68
+ }, "strict", z.ZodTypeAny, {
69
+ requireType?: boolean | undefined;
70
+ allowedTypes?: string[] | undefined;
71
+ }, {
72
+ requireType?: boolean | undefined;
73
+ allowedTypes?: string[] | undefined;
74
+ }>>;
75
+ }, "strict", z.ZodTypeAny, {
76
+ root: string;
77
+ index?: string | undefined;
78
+ include?: string[] | undefined;
79
+ exclude?: string[] | undefined;
80
+ okf?: {
81
+ requireType?: boolean | undefined;
82
+ allowedTypes?: string[] | undefined;
83
+ } | undefined;
84
+ }, {
85
+ root: string;
86
+ index?: string | undefined;
87
+ include?: string[] | undefined;
88
+ exclude?: string[] | undefined;
89
+ okf?: {
90
+ requireType?: boolean | undefined;
91
+ allowedTypes?: string[] | undefined;
92
+ } | undefined;
93
+ }>;
94
+ human: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
95
+ plugin: z.ZodEnum<["plain-markdown", "fumadocs", "docusaurus", "mkdocs", "vitepress", "custom"]>;
96
+ options: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
97
+ }, "strict", z.ZodTypeAny, {
98
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
99
+ options?: Record<string, unknown> | undefined;
100
+ }, {
101
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
102
+ options?: Record<string, unknown> | undefined;
103
+ }>, z.ZodArray<z.ZodObject<{
104
+ plugin: z.ZodEnum<["plain-markdown", "fumadocs", "docusaurus", "mkdocs", "vitepress", "custom"]>;
105
+ options: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
106
+ }, "strict", z.ZodTypeAny, {
107
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
108
+ options?: Record<string, unknown> | undefined;
109
+ }, {
110
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
111
+ options?: Record<string, unknown> | undefined;
112
+ }>, "many">]>>;
113
+ }, "strict", z.ZodTypeAny, {
114
+ agent: {
115
+ root: string;
116
+ index?: string | undefined;
117
+ include?: string[] | undefined;
118
+ exclude?: string[] | undefined;
119
+ okf?: {
120
+ requireType?: boolean | undefined;
121
+ allowedTypes?: string[] | undefined;
122
+ } | undefined;
123
+ };
124
+ human?: {
125
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
126
+ options?: Record<string, unknown> | undefined;
127
+ } | {
128
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
129
+ options?: Record<string, unknown> | undefined;
130
+ }[] | undefined;
131
+ }, {
132
+ agent: {
133
+ root: string;
134
+ index?: string | undefined;
135
+ include?: string[] | undefined;
136
+ exclude?: string[] | undefined;
137
+ okf?: {
138
+ requireType?: boolean | undefined;
139
+ allowedTypes?: string[] | undefined;
140
+ } | undefined;
141
+ };
142
+ human?: {
143
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
144
+ options?: Record<string, unknown> | undefined;
145
+ } | {
146
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
147
+ options?: Record<string, unknown> | undefined;
148
+ }[] | undefined;
149
+ }>;
150
+ index: z.ZodOptional<z.ZodObject<{
151
+ outFile: z.ZodOptional<z.ZodString>;
152
+ llmsTxt: z.ZodOptional<z.ZodObject<{
153
+ enabled: z.ZodOptional<z.ZodBoolean>;
154
+ outFile: z.ZodOptional<z.ZodString>;
155
+ preamble: z.ZodOptional<z.ZodString>;
156
+ }, "strict", z.ZodTypeAny, {
157
+ outFile?: string | undefined;
158
+ enabled?: boolean | undefined;
159
+ preamble?: string | undefined;
160
+ }, {
161
+ outFile?: string | undefined;
162
+ enabled?: boolean | undefined;
163
+ preamble?: string | undefined;
164
+ }>>;
165
+ capabilities: z.ZodOptional<z.ZodObject<{
166
+ enabled: z.ZodOptional<z.ZodBoolean>;
167
+ outFile: z.ZodOptional<z.ZodString>;
168
+ }, "strict", z.ZodTypeAny, {
169
+ outFile?: string | undefined;
170
+ enabled?: boolean | undefined;
171
+ }, {
172
+ outFile?: string | undefined;
173
+ enabled?: boolean | undefined;
174
+ }>>;
175
+ contentHash: z.ZodOptional<z.ZodLiteral<"sha256-normalized-v1">>;
176
+ }, "strict", z.ZodTypeAny, {
177
+ outFile?: string | undefined;
178
+ llmsTxt?: {
179
+ outFile?: string | undefined;
180
+ enabled?: boolean | undefined;
181
+ preamble?: string | undefined;
182
+ } | undefined;
183
+ capabilities?: {
184
+ outFile?: string | undefined;
185
+ enabled?: boolean | undefined;
186
+ } | undefined;
187
+ contentHash?: "sha256-normalized-v1" | undefined;
188
+ }, {
189
+ outFile?: string | undefined;
190
+ llmsTxt?: {
191
+ outFile?: string | undefined;
192
+ enabled?: boolean | undefined;
193
+ preamble?: string | undefined;
194
+ } | undefined;
195
+ capabilities?: {
196
+ outFile?: string | undefined;
197
+ enabled?: boolean | undefined;
198
+ } | undefined;
199
+ contentHash?: "sha256-normalized-v1" | undefined;
200
+ }>>;
201
+ routing: z.ZodOptional<z.ZodObject<{
202
+ plugin: z.ZodOptional<z.ZodEnum<["pnpm-monorepo", "npm-workspaces", "yarn-workspaces", "custom"]>>;
203
+ options: z.ZodOptional<z.ZodObject<{
204
+ packages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
205
+ ownership: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
206
+ path: z.ZodString;
207
+ group: z.ZodOptional<z.ZodString>;
208
+ layer: z.ZodOptional<z.ZodString>;
209
+ purpose: z.ZodOptional<z.ZodString>;
210
+ checks: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
211
+ agentDoc: z.ZodOptional<z.ZodString>;
212
+ humanDoc: z.ZodOptional<z.ZodString>;
213
+ }, "strict", z.ZodTypeAny, {
214
+ path: string;
215
+ group?: string | undefined;
216
+ layer?: string | undefined;
217
+ purpose?: string | undefined;
218
+ checks?: string[] | undefined;
219
+ agentDoc?: string | undefined;
220
+ humanDoc?: string | undefined;
221
+ }, {
222
+ path: string;
223
+ group?: string | undefined;
224
+ layer?: string | undefined;
225
+ purpose?: string | undefined;
226
+ checks?: string[] | undefined;
227
+ agentDoc?: string | undefined;
228
+ humanDoc?: string | undefined;
229
+ }>>>;
230
+ intents: z.ZodOptional<z.ZodArray<z.ZodObject<{
231
+ id: z.ZodString;
232
+ title: z.ZodString;
233
+ paths: z.ZodArray<z.ZodString, "many">;
234
+ }, "strict", z.ZodTypeAny, {
235
+ id: string;
236
+ title: string;
237
+ paths: string[];
238
+ }, {
239
+ id: string;
240
+ title: string;
241
+ paths: string[];
242
+ }>, "many">>;
243
+ changes: z.ZodOptional<z.ZodArray<z.ZodObject<{
244
+ id: z.ZodString;
245
+ title: z.ZodString;
246
+ startHere: z.ZodString;
247
+ relatedPackages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
248
+ }, "strict", z.ZodTypeAny, {
249
+ id: string;
250
+ title: string;
251
+ startHere: string;
252
+ relatedPackages?: string[] | undefined;
253
+ }, {
254
+ id: string;
255
+ title: string;
256
+ startHere: string;
257
+ relatedPackages?: string[] | undefined;
258
+ }>, "many">>;
259
+ }, "strict", z.ZodTypeAny, {
260
+ packages?: string[] | undefined;
261
+ ownership?: Record<string, {
262
+ path: string;
263
+ group?: string | undefined;
264
+ layer?: string | undefined;
265
+ purpose?: string | undefined;
266
+ checks?: string[] | undefined;
267
+ agentDoc?: string | undefined;
268
+ humanDoc?: string | undefined;
269
+ }> | undefined;
270
+ intents?: {
271
+ id: string;
272
+ title: string;
273
+ paths: string[];
274
+ }[] | undefined;
275
+ changes?: {
276
+ id: string;
277
+ title: string;
278
+ startHere: string;
279
+ relatedPackages?: string[] | undefined;
280
+ }[] | undefined;
281
+ }, {
282
+ packages?: string[] | undefined;
283
+ ownership?: Record<string, {
284
+ path: string;
285
+ group?: string | undefined;
286
+ layer?: string | undefined;
287
+ purpose?: string | undefined;
288
+ checks?: string[] | undefined;
289
+ agentDoc?: string | undefined;
290
+ humanDoc?: string | undefined;
291
+ }> | undefined;
292
+ intents?: {
293
+ id: string;
294
+ title: string;
295
+ paths: string[];
296
+ }[] | undefined;
297
+ changes?: {
298
+ id: string;
299
+ title: string;
300
+ startHere: string;
301
+ relatedPackages?: string[] | undefined;
302
+ }[] | undefined;
303
+ }>>;
304
+ }, "strict", z.ZodTypeAny, {
305
+ options?: {
306
+ packages?: string[] | undefined;
307
+ ownership?: Record<string, {
308
+ path: string;
309
+ group?: string | undefined;
310
+ layer?: string | undefined;
311
+ purpose?: string | undefined;
312
+ checks?: string[] | undefined;
313
+ agentDoc?: string | undefined;
314
+ humanDoc?: string | undefined;
315
+ }> | undefined;
316
+ intents?: {
317
+ id: string;
318
+ title: string;
319
+ paths: string[];
320
+ }[] | undefined;
321
+ changes?: {
322
+ id: string;
323
+ title: string;
324
+ startHere: string;
325
+ relatedPackages?: string[] | undefined;
326
+ }[] | undefined;
327
+ } | undefined;
328
+ plugin?: "custom" | "pnpm-monorepo" | "npm-workspaces" | "yarn-workspaces" | undefined;
329
+ }, {
330
+ options?: {
331
+ packages?: string[] | undefined;
332
+ ownership?: Record<string, {
333
+ path: string;
334
+ group?: string | undefined;
335
+ layer?: string | undefined;
336
+ purpose?: string | undefined;
337
+ checks?: string[] | undefined;
338
+ agentDoc?: string | undefined;
339
+ humanDoc?: string | undefined;
340
+ }> | undefined;
341
+ intents?: {
342
+ id: string;
343
+ title: string;
344
+ paths: string[];
345
+ }[] | undefined;
346
+ changes?: {
347
+ id: string;
348
+ title: string;
349
+ startHere: string;
350
+ relatedPackages?: string[] | undefined;
351
+ }[] | undefined;
352
+ } | undefined;
353
+ plugin?: "custom" | "pnpm-monorepo" | "npm-workspaces" | "yarn-workspaces" | undefined;
354
+ }>>;
355
+ gates: z.ZodOptional<z.ZodObject<{
356
+ preset: z.ZodOptional<z.ZodEnum<["minimal", "standard", "strict"]>>;
357
+ include: z.ZodOptional<z.ZodArray<z.ZodEnum<["index-freshness", "human-guide-links", "link-rot", "okf-type", "docs-style", "routing-currency", "bootstrap-size"]>, "many">>;
358
+ exclude: z.ZodOptional<z.ZodArray<z.ZodEnum<["index-freshness", "human-guide-links", "link-rot", "okf-type", "docs-style", "routing-currency", "bootstrap-size"]>, "many">>;
359
+ options: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
360
+ }, "strict", z.ZodTypeAny, {
361
+ options?: Record<string, unknown> | undefined;
362
+ include?: ("index-freshness" | "human-guide-links" | "link-rot" | "okf-type" | "docs-style" | "routing-currency" | "bootstrap-size")[] | undefined;
363
+ exclude?: ("index-freshness" | "human-guide-links" | "link-rot" | "okf-type" | "docs-style" | "routing-currency" | "bootstrap-size")[] | undefined;
364
+ preset?: "strict" | "minimal" | "standard" | undefined;
365
+ }, {
366
+ options?: Record<string, unknown> | undefined;
367
+ include?: ("index-freshness" | "human-guide-links" | "link-rot" | "okf-type" | "docs-style" | "routing-currency" | "bootstrap-size")[] | undefined;
368
+ exclude?: ("index-freshness" | "human-guide-links" | "link-rot" | "okf-type" | "docs-style" | "routing-currency" | "bootstrap-size")[] | undefined;
369
+ preset?: "strict" | "minimal" | "standard" | undefined;
370
+ }>>;
371
+ surfaces: z.ZodOptional<z.ZodObject<{
372
+ cli: z.ZodOptional<z.ZodObject<{
373
+ bin: z.ZodOptional<z.ZodString>;
374
+ defaultFormat: z.ZodOptional<z.ZodEnum<["json", "text"]>>;
375
+ }, "strict", z.ZodTypeAny, {
376
+ bin?: string | undefined;
377
+ defaultFormat?: "json" | "text" | undefined;
378
+ }, {
379
+ bin?: string | undefined;
380
+ defaultFormat?: "json" | "text" | undefined;
381
+ }>>;
382
+ mcp: z.ZodOptional<z.ZodObject<{
383
+ enabled: z.ZodOptional<z.ZodBoolean>;
384
+ tools: z.ZodOptional<z.ZodArray<z.ZodEnum<["handoff.resolve", "doc.search", "doc.get", "gate.status", "playbook.pattern.get", "retriever.query", "memory.classify", "memory.promoteDraft", "registry.topology"]>, "many">>;
385
+ transport: z.ZodOptional<z.ZodEnum<["stdio", "http"]>>;
386
+ http: z.ZodOptional<z.ZodObject<{
387
+ port: z.ZodOptional<z.ZodNumber>;
388
+ path: z.ZodOptional<z.ZodString>;
389
+ }, "strict", z.ZodTypeAny, {
390
+ path?: string | undefined;
391
+ port?: number | undefined;
392
+ }, {
393
+ path?: string | undefined;
394
+ port?: number | undefined;
395
+ }>>;
396
+ }, "strict", z.ZodTypeAny, {
397
+ enabled?: boolean | undefined;
398
+ tools?: ("handoff.resolve" | "doc.search" | "doc.get" | "gate.status" | "playbook.pattern.get" | "retriever.query" | "memory.classify" | "memory.promoteDraft" | "registry.topology")[] | undefined;
399
+ http?: {
400
+ path?: string | undefined;
401
+ port?: number | undefined;
402
+ } | undefined;
403
+ transport?: "stdio" | "http" | undefined;
404
+ }, {
405
+ enabled?: boolean | undefined;
406
+ tools?: ("handoff.resolve" | "doc.search" | "doc.get" | "gate.status" | "playbook.pattern.get" | "retriever.query" | "memory.classify" | "memory.promoteDraft" | "registry.topology")[] | undefined;
407
+ http?: {
408
+ path?: string | undefined;
409
+ port?: number | undefined;
410
+ } | undefined;
411
+ transport?: "stdio" | "http" | undefined;
412
+ }>>;
413
+ }, "strict", z.ZodTypeAny, {
414
+ cli?: {
415
+ bin?: string | undefined;
416
+ defaultFormat?: "json" | "text" | undefined;
417
+ } | undefined;
418
+ mcp?: {
419
+ enabled?: boolean | undefined;
420
+ tools?: ("handoff.resolve" | "doc.search" | "doc.get" | "gate.status" | "playbook.pattern.get" | "retriever.query" | "memory.classify" | "memory.promoteDraft" | "registry.topology")[] | undefined;
421
+ http?: {
422
+ path?: string | undefined;
423
+ port?: number | undefined;
424
+ } | undefined;
425
+ transport?: "stdio" | "http" | undefined;
426
+ } | undefined;
427
+ }, {
428
+ cli?: {
429
+ bin?: string | undefined;
430
+ defaultFormat?: "json" | "text" | undefined;
431
+ } | undefined;
432
+ mcp?: {
433
+ enabled?: boolean | undefined;
434
+ tools?: ("handoff.resolve" | "doc.search" | "doc.get" | "gate.status" | "playbook.pattern.get" | "retriever.query" | "memory.classify" | "memory.promoteDraft" | "registry.topology")[] | undefined;
435
+ http?: {
436
+ path?: string | undefined;
437
+ port?: number | undefined;
438
+ } | undefined;
439
+ transport?: "stdio" | "http" | undefined;
440
+ } | undefined;
441
+ }>>;
442
+ intelligence: z.ZodOptional<z.ZodObject<{
443
+ enabled: z.ZodOptional<z.ZodBoolean>;
444
+ adapter: z.ZodOptional<z.ZodObject<{
445
+ provider: z.ZodEnum<["openai", "anthropic", "ollama", "openrouter", "custom"]>;
446
+ model: z.ZodOptional<z.ZodString>;
447
+ apiKeyEnv: z.ZodOptional<z.ZodString>;
448
+ baseUrl: z.ZodOptional<z.ZodString>;
449
+ options: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
450
+ }, "strict", z.ZodTypeAny, {
451
+ provider: "custom" | "openai" | "anthropic" | "ollama" | "openrouter";
452
+ options?: Record<string, unknown> | undefined;
453
+ model?: string | undefined;
454
+ apiKeyEnv?: string | undefined;
455
+ baseUrl?: string | undefined;
456
+ }, {
457
+ provider: "custom" | "openai" | "anthropic" | "ollama" | "openrouter";
458
+ options?: Record<string, unknown> | undefined;
459
+ model?: string | undefined;
460
+ apiKeyEnv?: string | undefined;
461
+ baseUrl?: string | undefined;
462
+ }>>;
463
+ chat: z.ZodOptional<z.ZodObject<{
464
+ enabled: z.ZodOptional<z.ZodBoolean>;
465
+ sources: z.ZodOptional<z.ZodArray<z.ZodEnum<["agent", "human", "federation"]>, "many">>;
466
+ handoffFirst: z.ZodOptional<z.ZodBoolean>;
467
+ }, "strict", z.ZodTypeAny, {
468
+ enabled?: boolean | undefined;
469
+ sources?: ("agent" | "human" | "federation")[] | undefined;
470
+ handoffFirst?: boolean | undefined;
471
+ }, {
472
+ enabled?: boolean | undefined;
473
+ sources?: ("agent" | "human" | "federation")[] | undefined;
474
+ handoffFirst?: boolean | undefined;
475
+ }>>;
476
+ retriever: z.ZodOptional<z.ZodObject<{
477
+ enabled: z.ZodOptional<z.ZodBoolean>;
478
+ mode: z.ZodOptional<z.ZodEnum<["local", "remote", "bm25", "agentskit-rag"]>>;
479
+ embedModel: z.ZodOptional<z.ZodString>;
480
+ chunkSize: z.ZodOptional<z.ZodNumber>;
481
+ options: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
482
+ }, "strict", z.ZodTypeAny, {
483
+ options?: Record<string, unknown> | undefined;
484
+ enabled?: boolean | undefined;
485
+ mode?: "local" | "remote" | "bm25" | "agentskit-rag" | undefined;
486
+ embedModel?: string | undefined;
487
+ chunkSize?: number | undefined;
488
+ }, {
489
+ options?: Record<string, unknown> | undefined;
490
+ enabled?: boolean | undefined;
491
+ mode?: "local" | "remote" | "bm25" | "agentskit-rag" | undefined;
492
+ embedModel?: string | undefined;
493
+ chunkSize?: number | undefined;
494
+ }>>;
495
+ memory: z.ZodOptional<z.ZodObject<{
496
+ enabled: z.ZodOptional<z.ZodBoolean>;
497
+ adapters: z.ZodOptional<z.ZodArray<z.ZodEnum<["playbook-memory", "cursor-rules", "session-export", "bootstrap-delta"]>, "many">>;
498
+ ingestDir: z.ZodOptional<z.ZodString>;
499
+ classify: z.ZodOptional<z.ZodBoolean>;
500
+ promote: z.ZodOptional<z.ZodObject<{
501
+ enabled: z.ZodOptional<z.ZodBoolean>;
502
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<["agent", "human", "agents-md"]>, "many">>;
503
+ requireApproval: z.ZodOptional<z.ZodBoolean>;
504
+ }, "strict", z.ZodTypeAny, {
505
+ enabled?: boolean | undefined;
506
+ targets?: ("agent" | "human" | "agents-md")[] | undefined;
507
+ requireApproval?: boolean | undefined;
508
+ }, {
509
+ enabled?: boolean | undefined;
510
+ targets?: ("agent" | "human" | "agents-md")[] | undefined;
511
+ requireApproval?: boolean | undefined;
512
+ }>>;
513
+ }, "strict", z.ZodTypeAny, {
514
+ enabled?: boolean | undefined;
515
+ adapters?: ("playbook-memory" | "cursor-rules" | "session-export" | "bootstrap-delta")[] | undefined;
516
+ ingestDir?: string | undefined;
517
+ classify?: boolean | undefined;
518
+ promote?: {
519
+ enabled?: boolean | undefined;
520
+ targets?: ("agent" | "human" | "agents-md")[] | undefined;
521
+ requireApproval?: boolean | undefined;
522
+ } | undefined;
523
+ }, {
524
+ enabled?: boolean | undefined;
525
+ adapters?: ("playbook-memory" | "cursor-rules" | "session-export" | "bootstrap-delta")[] | undefined;
526
+ ingestDir?: string | undefined;
527
+ classify?: boolean | undefined;
528
+ promote?: {
529
+ enabled?: boolean | undefined;
530
+ targets?: ("agent" | "human" | "agents-md")[] | undefined;
531
+ requireApproval?: boolean | undefined;
532
+ } | undefined;
533
+ }>>;
534
+ runtime: z.ZodOptional<z.ZodEnum<["agentskit", "custom"]>>;
535
+ runtimeModule: z.ZodOptional<z.ZodString>;
536
+ }, "strict", z.ZodTypeAny, {
537
+ enabled?: boolean | undefined;
538
+ adapter?: {
539
+ provider: "custom" | "openai" | "anthropic" | "ollama" | "openrouter";
540
+ options?: Record<string, unknown> | undefined;
541
+ model?: string | undefined;
542
+ apiKeyEnv?: string | undefined;
543
+ baseUrl?: string | undefined;
544
+ } | undefined;
545
+ chat?: {
546
+ enabled?: boolean | undefined;
547
+ sources?: ("agent" | "human" | "federation")[] | undefined;
548
+ handoffFirst?: boolean | undefined;
549
+ } | undefined;
550
+ retriever?: {
551
+ options?: Record<string, unknown> | undefined;
552
+ enabled?: boolean | undefined;
553
+ mode?: "local" | "remote" | "bm25" | "agentskit-rag" | undefined;
554
+ embedModel?: string | undefined;
555
+ chunkSize?: number | undefined;
556
+ } | undefined;
557
+ memory?: {
558
+ enabled?: boolean | undefined;
559
+ adapters?: ("playbook-memory" | "cursor-rules" | "session-export" | "bootstrap-delta")[] | undefined;
560
+ ingestDir?: string | undefined;
561
+ classify?: boolean | undefined;
562
+ promote?: {
563
+ enabled?: boolean | undefined;
564
+ targets?: ("agent" | "human" | "agents-md")[] | undefined;
565
+ requireApproval?: boolean | undefined;
566
+ } | undefined;
567
+ } | undefined;
568
+ runtime?: "custom" | "agentskit" | undefined;
569
+ runtimeModule?: string | undefined;
570
+ }, {
571
+ enabled?: boolean | undefined;
572
+ adapter?: {
573
+ provider: "custom" | "openai" | "anthropic" | "ollama" | "openrouter";
574
+ options?: Record<string, unknown> | undefined;
575
+ model?: string | undefined;
576
+ apiKeyEnv?: string | undefined;
577
+ baseUrl?: string | undefined;
578
+ } | undefined;
579
+ chat?: {
580
+ enabled?: boolean | undefined;
581
+ sources?: ("agent" | "human" | "federation")[] | undefined;
582
+ handoffFirst?: boolean | undefined;
583
+ } | undefined;
584
+ retriever?: {
585
+ options?: Record<string, unknown> | undefined;
586
+ enabled?: boolean | undefined;
587
+ mode?: "local" | "remote" | "bm25" | "agentskit-rag" | undefined;
588
+ embedModel?: string | undefined;
589
+ chunkSize?: number | undefined;
590
+ } | undefined;
591
+ memory?: {
592
+ enabled?: boolean | undefined;
593
+ adapters?: ("playbook-memory" | "cursor-rules" | "session-export" | "bootstrap-delta")[] | undefined;
594
+ ingestDir?: string | undefined;
595
+ classify?: boolean | undefined;
596
+ promote?: {
597
+ enabled?: boolean | undefined;
598
+ targets?: ("agent" | "human" | "agents-md")[] | undefined;
599
+ requireApproval?: boolean | undefined;
600
+ } | undefined;
601
+ } | undefined;
602
+ runtime?: "custom" | "agentskit" | undefined;
603
+ runtimeModule?: string | undefined;
604
+ }>>;
605
+ federation: z.ZodOptional<z.ZodObject<{
606
+ enabled: z.ZodOptional<z.ZodBoolean>;
607
+ sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
608
+ id: z.ZodString;
609
+ llmsTxt: z.ZodOptional<z.ZodString>;
610
+ rawBaseUrl: z.ZodOptional<z.ZodString>;
611
+ includeInRetriever: z.ZodOptional<z.ZodBoolean>;
612
+ includeInChat: z.ZodOptional<z.ZodBoolean>;
613
+ }, "strict", z.ZodTypeAny, {
614
+ id: string;
615
+ llmsTxt?: string | undefined;
616
+ rawBaseUrl?: string | undefined;
617
+ includeInRetriever?: boolean | undefined;
618
+ includeInChat?: boolean | undefined;
619
+ }, {
620
+ id: string;
621
+ llmsTxt?: string | undefined;
622
+ rawBaseUrl?: string | undefined;
623
+ includeInRetriever?: boolean | undefined;
624
+ includeInChat?: boolean | undefined;
625
+ }>, "many">>;
626
+ }, "strict", z.ZodTypeAny, {
627
+ enabled?: boolean | undefined;
628
+ sources?: {
629
+ id: string;
630
+ llmsTxt?: string | undefined;
631
+ rawBaseUrl?: string | undefined;
632
+ includeInRetriever?: boolean | undefined;
633
+ includeInChat?: boolean | undefined;
634
+ }[] | undefined;
635
+ }, {
636
+ enabled?: boolean | undefined;
637
+ sources?: {
638
+ id: string;
639
+ llmsTxt?: string | undefined;
640
+ rawBaseUrl?: string | undefined;
641
+ includeInRetriever?: boolean | undefined;
642
+ includeInChat?: boolean | undefined;
643
+ }[] | undefined;
644
+ }>>;
645
+ }, "strict", z.ZodTypeAny, {
646
+ schemaVersion: 1;
647
+ corpus: {
648
+ agent: {
649
+ root: string;
650
+ index?: string | undefined;
651
+ include?: string[] | undefined;
652
+ exclude?: string[] | undefined;
653
+ okf?: {
654
+ requireType?: boolean | undefined;
655
+ allowedTypes?: string[] | undefined;
656
+ } | undefined;
657
+ };
658
+ human?: {
659
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
660
+ options?: Record<string, unknown> | undefined;
661
+ } | {
662
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
663
+ options?: Record<string, unknown> | undefined;
664
+ }[] | undefined;
665
+ };
666
+ index?: {
667
+ outFile?: string | undefined;
668
+ llmsTxt?: {
669
+ outFile?: string | undefined;
670
+ enabled?: boolean | undefined;
671
+ preamble?: string | undefined;
672
+ } | undefined;
673
+ capabilities?: {
674
+ outFile?: string | undefined;
675
+ enabled?: boolean | undefined;
676
+ } | undefined;
677
+ contentHash?: "sha256-normalized-v1" | undefined;
678
+ } | undefined;
679
+ federation?: {
680
+ enabled?: boolean | undefined;
681
+ sources?: {
682
+ id: string;
683
+ llmsTxt?: string | undefined;
684
+ rawBaseUrl?: string | undefined;
685
+ includeInRetriever?: boolean | undefined;
686
+ includeInChat?: boolean | undefined;
687
+ }[] | undefined;
688
+ } | undefined;
689
+ project?: {
690
+ root?: string | undefined;
691
+ name?: string | undefined;
692
+ } | undefined;
693
+ routing?: {
694
+ options?: {
695
+ packages?: string[] | undefined;
696
+ ownership?: Record<string, {
697
+ path: string;
698
+ group?: string | undefined;
699
+ layer?: string | undefined;
700
+ purpose?: string | undefined;
701
+ checks?: string[] | undefined;
702
+ agentDoc?: string | undefined;
703
+ humanDoc?: string | undefined;
704
+ }> | undefined;
705
+ intents?: {
706
+ id: string;
707
+ title: string;
708
+ paths: string[];
709
+ }[] | undefined;
710
+ changes?: {
711
+ id: string;
712
+ title: string;
713
+ startHere: string;
714
+ relatedPackages?: string[] | undefined;
715
+ }[] | undefined;
716
+ } | undefined;
717
+ plugin?: "custom" | "pnpm-monorepo" | "npm-workspaces" | "yarn-workspaces" | undefined;
718
+ } | undefined;
719
+ gates?: {
720
+ options?: Record<string, unknown> | undefined;
721
+ include?: ("index-freshness" | "human-guide-links" | "link-rot" | "okf-type" | "docs-style" | "routing-currency" | "bootstrap-size")[] | undefined;
722
+ exclude?: ("index-freshness" | "human-guide-links" | "link-rot" | "okf-type" | "docs-style" | "routing-currency" | "bootstrap-size")[] | undefined;
723
+ preset?: "strict" | "minimal" | "standard" | undefined;
724
+ } | undefined;
725
+ surfaces?: {
726
+ cli?: {
727
+ bin?: string | undefined;
728
+ defaultFormat?: "json" | "text" | undefined;
729
+ } | undefined;
730
+ mcp?: {
731
+ enabled?: boolean | undefined;
732
+ tools?: ("handoff.resolve" | "doc.search" | "doc.get" | "gate.status" | "playbook.pattern.get" | "retriever.query" | "memory.classify" | "memory.promoteDraft" | "registry.topology")[] | undefined;
733
+ http?: {
734
+ path?: string | undefined;
735
+ port?: number | undefined;
736
+ } | undefined;
737
+ transport?: "stdio" | "http" | undefined;
738
+ } | undefined;
739
+ } | undefined;
740
+ intelligence?: {
741
+ enabled?: boolean | undefined;
742
+ adapter?: {
743
+ provider: "custom" | "openai" | "anthropic" | "ollama" | "openrouter";
744
+ options?: Record<string, unknown> | undefined;
745
+ model?: string | undefined;
746
+ apiKeyEnv?: string | undefined;
747
+ baseUrl?: string | undefined;
748
+ } | undefined;
749
+ chat?: {
750
+ enabled?: boolean | undefined;
751
+ sources?: ("agent" | "human" | "federation")[] | undefined;
752
+ handoffFirst?: boolean | undefined;
753
+ } | undefined;
754
+ retriever?: {
755
+ options?: Record<string, unknown> | undefined;
756
+ enabled?: boolean | undefined;
757
+ mode?: "local" | "remote" | "bm25" | "agentskit-rag" | undefined;
758
+ embedModel?: string | undefined;
759
+ chunkSize?: number | undefined;
760
+ } | undefined;
761
+ memory?: {
762
+ enabled?: boolean | undefined;
763
+ adapters?: ("playbook-memory" | "cursor-rules" | "session-export" | "bootstrap-delta")[] | undefined;
764
+ ingestDir?: string | undefined;
765
+ classify?: boolean | undefined;
766
+ promote?: {
767
+ enabled?: boolean | undefined;
768
+ targets?: ("agent" | "human" | "agents-md")[] | undefined;
769
+ requireApproval?: boolean | undefined;
770
+ } | undefined;
771
+ } | undefined;
772
+ runtime?: "custom" | "agentskit" | undefined;
773
+ runtimeModule?: string | undefined;
774
+ } | undefined;
775
+ }, {
776
+ schemaVersion: 1;
777
+ corpus: {
778
+ agent: {
779
+ root: string;
780
+ index?: string | undefined;
781
+ include?: string[] | undefined;
782
+ exclude?: string[] | undefined;
783
+ okf?: {
784
+ requireType?: boolean | undefined;
785
+ allowedTypes?: string[] | undefined;
786
+ } | undefined;
787
+ };
788
+ human?: {
789
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
790
+ options?: Record<string, unknown> | undefined;
791
+ } | {
792
+ plugin: "plain-markdown" | "fumadocs" | "docusaurus" | "mkdocs" | "vitepress" | "custom";
793
+ options?: Record<string, unknown> | undefined;
794
+ }[] | undefined;
795
+ };
796
+ index?: {
797
+ outFile?: string | undefined;
798
+ llmsTxt?: {
799
+ outFile?: string | undefined;
800
+ enabled?: boolean | undefined;
801
+ preamble?: string | undefined;
802
+ } | undefined;
803
+ capabilities?: {
804
+ outFile?: string | undefined;
805
+ enabled?: boolean | undefined;
806
+ } | undefined;
807
+ contentHash?: "sha256-normalized-v1" | undefined;
808
+ } | undefined;
809
+ federation?: {
810
+ enabled?: boolean | undefined;
811
+ sources?: {
812
+ id: string;
813
+ llmsTxt?: string | undefined;
814
+ rawBaseUrl?: string | undefined;
815
+ includeInRetriever?: boolean | undefined;
816
+ includeInChat?: boolean | undefined;
817
+ }[] | undefined;
818
+ } | undefined;
819
+ project?: {
820
+ root?: string | undefined;
821
+ name?: string | undefined;
822
+ } | undefined;
823
+ routing?: {
824
+ options?: {
825
+ packages?: string[] | undefined;
826
+ ownership?: Record<string, {
827
+ path: string;
828
+ group?: string | undefined;
829
+ layer?: string | undefined;
830
+ purpose?: string | undefined;
831
+ checks?: string[] | undefined;
832
+ agentDoc?: string | undefined;
833
+ humanDoc?: string | undefined;
834
+ }> | undefined;
835
+ intents?: {
836
+ id: string;
837
+ title: string;
838
+ paths: string[];
839
+ }[] | undefined;
840
+ changes?: {
841
+ id: string;
842
+ title: string;
843
+ startHere: string;
844
+ relatedPackages?: string[] | undefined;
845
+ }[] | undefined;
846
+ } | undefined;
847
+ plugin?: "custom" | "pnpm-monorepo" | "npm-workspaces" | "yarn-workspaces" | undefined;
848
+ } | undefined;
849
+ gates?: {
850
+ options?: Record<string, unknown> | undefined;
851
+ include?: ("index-freshness" | "human-guide-links" | "link-rot" | "okf-type" | "docs-style" | "routing-currency" | "bootstrap-size")[] | undefined;
852
+ exclude?: ("index-freshness" | "human-guide-links" | "link-rot" | "okf-type" | "docs-style" | "routing-currency" | "bootstrap-size")[] | undefined;
853
+ preset?: "strict" | "minimal" | "standard" | undefined;
854
+ } | undefined;
855
+ surfaces?: {
856
+ cli?: {
857
+ bin?: string | undefined;
858
+ defaultFormat?: "json" | "text" | undefined;
859
+ } | undefined;
860
+ mcp?: {
861
+ enabled?: boolean | undefined;
862
+ tools?: ("handoff.resolve" | "doc.search" | "doc.get" | "gate.status" | "playbook.pattern.get" | "retriever.query" | "memory.classify" | "memory.promoteDraft" | "registry.topology")[] | undefined;
863
+ http?: {
864
+ path?: string | undefined;
865
+ port?: number | undefined;
866
+ } | undefined;
867
+ transport?: "stdio" | "http" | undefined;
868
+ } | undefined;
869
+ } | undefined;
870
+ intelligence?: {
871
+ enabled?: boolean | undefined;
872
+ adapter?: {
873
+ provider: "custom" | "openai" | "anthropic" | "ollama" | "openrouter";
874
+ options?: Record<string, unknown> | undefined;
875
+ model?: string | undefined;
876
+ apiKeyEnv?: string | undefined;
877
+ baseUrl?: string | undefined;
878
+ } | undefined;
879
+ chat?: {
880
+ enabled?: boolean | undefined;
881
+ sources?: ("agent" | "human" | "federation")[] | undefined;
882
+ handoffFirst?: boolean | undefined;
883
+ } | undefined;
884
+ retriever?: {
885
+ options?: Record<string, unknown> | undefined;
886
+ enabled?: boolean | undefined;
887
+ mode?: "local" | "remote" | "bm25" | "agentskit-rag" | undefined;
888
+ embedModel?: string | undefined;
889
+ chunkSize?: number | undefined;
890
+ } | undefined;
891
+ memory?: {
892
+ enabled?: boolean | undefined;
893
+ adapters?: ("playbook-memory" | "cursor-rules" | "session-export" | "bootstrap-delta")[] | undefined;
894
+ ingestDir?: string | undefined;
895
+ classify?: boolean | undefined;
896
+ promote?: {
897
+ enabled?: boolean | undefined;
898
+ targets?: ("agent" | "human" | "agents-md")[] | undefined;
899
+ requireApproval?: boolean | undefined;
900
+ } | undefined;
901
+ } | undefined;
902
+ runtime?: "custom" | "agentskit" | undefined;
903
+ runtimeModule?: string | undefined;
904
+ } | undefined;
905
+ }>;
906
+ type DocBridgeConfigV1 = z.infer<typeof DocBridgeConfigV1Schema>;
907
+ type AgentCorpusConfig = z.infer<typeof AgentCorpusConfigSchema>;
908
+
909
+ /** Type-safe config helper for `doc-bridge.config.ts`. */
910
+ declare const defineConfig: (config: DocBridgeConfigV1) => DocBridgeConfigV1;
911
+
912
+ declare const applyConfigDefaults: (config: DocBridgeConfigV1) => DocBridgeConfigV1;
913
+
914
+ type LoadConfigOptions = {
915
+ readonly cwd?: string;
916
+ readonly explicitPath?: string;
917
+ };
918
+ type LoadConfigResult = {
919
+ readonly config: DocBridgeConfigV1;
920
+ readonly path: string;
921
+ };
922
+ declare class ConfigNotFoundError extends Error {
923
+ readonly cwd: string;
924
+ constructor(cwd: string);
925
+ }
926
+ /** v0.1 — static JS/TS config, JSON config files, and package.json#docBridge. */
927
+ declare const loadConfig: (opts?: LoadConfigOptions) => LoadConfigResult;
928
+ declare const resolveProjectRoot: (start?: string) => string;
929
+ /** Project root for a loaded config file path (directory of the config). */
930
+ declare const projectRootFromConfigPath: (configFilePath: string, projectRootField?: string) => string;
931
+
932
+ export { type AgentCorpusConfig as A, ConfigNotFoundError as C, type DocBridgeConfigV1 as D, HumanCorpusConfigSchema as H, type LoadConfigOptions as L, DocBridgeConfigV1Schema as a, type LoadConfigResult as b, applyConfigDefaults as c, defineConfig as d, AgentCorpusConfigSchema as e, loadConfig as l, projectRootFromConfigPath as p, resolveProjectRoot as r };