@farming-labs/docs 0.2.103 → 0.2.105

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.
Files changed (77) hide show
  1. package/dist/{agent-BLHMoVId.mjs → agent-CaCWThBY.mjs} +4 -4
  2. package/dist/{agent-CFqECAG0.mjs → agent-DCTGj6J7.mjs} +212 -19
  3. package/dist/{agent-evals-GpcaCbRb.mjs → agent-evals-D-sPJfXz.mjs} +5 -5
  4. package/dist/{agent-export-oiWxB5aX.mjs → agent-export-GcTZPLfB.mjs} +30 -17
  5. package/dist/agent-feedback-evaluations-DQCTFegz.mjs +240 -0
  6. package/dist/agent-feedback-loop-vaC-M1sx.mjs +196 -0
  7. package/dist/agent-maintenance-CuZ7iAKq.mjs +289 -0
  8. package/dist/agent-skills-bundle.d.mts +1 -1
  9. package/dist/{agent-skills-progressive-disclosure-Da9LKEKv.mjs → agent-skills-progressive-disclosure-DL-q4JZo.mjs} +1 -1
  10. package/dist/{agent-skills-server-CICMh0zv.d.mts → agent-skills-server-D34054x5.d.mts} +2 -2
  11. package/dist/{agent-skills-server-DFqQyO_V.mjs → agent-skills-server-Ddbf15pY.mjs} +1 -1
  12. package/dist/agent-skills-vite.d.mts +3 -3
  13. package/dist/agent-skills-vite.mjs +2 -2
  14. package/dist/{agents-CtqIUW5I.mjs → agents-e1SYT64z.mjs} +11 -10
  15. package/dist/{analytics-Bx44lg6d.mjs → analytics-CqfcIBdg.mjs} +1 -1
  16. package/dist/{analytics-C75BnTEW.d.mts → analytics-aeXwEvQX.d.mts} +1 -1
  17. package/dist/authoring-Do87QzBd.mjs +41 -0
  18. package/dist/authoring-mcp-Be7quE5R.mjs +380 -0
  19. package/dist/browser.d.mts +3 -3
  20. package/dist/browser.mjs +2 -2
  21. package/dist/cli/index.mjs +103 -35
  22. package/dist/client/react.d.mts +1 -1
  23. package/dist/client/react.mjs +1 -1
  24. package/dist/{cloud-FNfcbfli.mjs → cloud-Bvof6mET.mjs} +3 -3
  25. package/dist/{cloud-ask-ai-BmbZVAT5.d.mts → cloud-ask-ai-BqfiQaNZ.d.mts} +1 -1
  26. package/dist/{cloud-ask-ai-CkCYjf2N.mjs → cloud-ask-ai-CK2qlNns.mjs} +1 -1
  27. package/dist/{code-blocks-Bel6vDqI.mjs → code-blocks-D90CCJFs.mjs} +1 -1
  28. package/dist/{codeblocks-jbWuvtJQ.mjs → codeblocks-C911CdyJ.mjs} +2 -2
  29. package/dist/{agent-lWTq6pgr.d.mts → content-change-hydration-CoYRs3pC.d.mts} +707 -675
  30. package/dist/{dev-BvbYmTLz.mjs → dev-Bx0JNglW.mjs} +3 -3
  31. package/dist/docs-cloud-server.d.mts +2 -2
  32. package/dist/docs-cloud-server.mjs +2 -2
  33. package/dist/{doctor-Bmm0uY98.mjs → doctor-CtK1CRPj.mjs} +20 -16
  34. package/dist/{downgrade-Dqm0rJMy.mjs → downgrade-BXmQMkMy.mjs} +2 -2
  35. package/dist/feedback-DWVUMrxy.mjs +72 -0
  36. package/dist/feedback-evals-k0sFDdms.mjs +146 -0
  37. package/dist/{golden-evaluations-K45fcWGW.mjs → golden-evaluations-De4KwoYr.mjs} +3 -3
  38. package/dist/index.d.mts +236 -9
  39. package/dist/index.mjs +14 -11
  40. package/dist/{init-jDQSo-Or.mjs → init-CCV2eRNB.mjs} +3 -3
  41. package/dist/markdown-rendering.mjs +1 -1
  42. package/dist/{markdown-sections-7OoA7ylx.mjs → markdown-sections-BKy4labo.mjs} +110 -2
  43. package/dist/{mcp-CwgKlbIz.mjs → mcp-DsjWxF7g.mjs} +11 -10
  44. package/dist/mcp.d.mts +20 -5
  45. package/dist/mcp.mjs +538 -56
  46. package/dist/{metadata-D4v_R1t5.mjs → metadata-7htr-Xj_.mjs} +1 -1
  47. package/dist/{content-change-hydration-BsbBXAUi.mjs → openapi-mcp-DQ3xptKo.mjs} +182 -4
  48. package/dist/openapi-mcp-node-vO3IXVGI.mjs +43 -0
  49. package/dist/{package-version--oQiHwZj.mjs → package-version-Ci99L0yo.mjs} +1 -1
  50. package/dist/{prompt-references-DW5vG5zs.mjs → prompt-references-1Wce71c7.mjs} +3 -3
  51. package/dist/propose-DJOiHu9Y.mjs +73 -0
  52. package/dist/retrieval-digest-B-SgtXKK.mjs +177 -0
  53. package/dist/retrieval-digest-DyNRD-mt.d.mts +467 -0
  54. package/dist/{review-C_5wB0rR.mjs → review-XI9FXeos.mjs} +12 -12
  55. package/dist/{robots-NQesPX5L.mjs → robots-BOjWB1ky.mjs} +2 -2
  56. package/dist/{robots-BQ42Y84a.mjs → robots-CzKesbdX.mjs} +6 -6
  57. package/dist/{search-B5etKU-v.mjs → search-DwAoC9X7.mjs} +12 -11
  58. package/dist/server.d.mts +47 -264
  59. package/dist/server.mjs +14 -11
  60. package/dist/{sidebar-CwZlgyAz.d.mts → sidebar-CJze8SBi.d.mts} +1 -1
  61. package/dist/{sitemap-DjhxvQP1.mjs → sitemap-DOaJIKJf.mjs} +11 -10
  62. package/dist/{sitemap-server-B0SiREN0.mjs → sitemap-server-NeVu8W38.mjs} +11 -1
  63. package/dist/{skills-BFang8vF.mjs → skills-BILSESek.mjs} +11 -10
  64. package/dist/{standards-discovery-Ckx0tN7B.mjs → standards-discovery-Bpz90VYq.mjs} +2 -177
  65. package/dist/{standards-discovery-D1Ys4J3h.d.mts → standards-discovery-Xm84bS4M.d.mts} +1 -1
  66. package/dist/{types-DLLefoU5.d.mts → types-QhYMnKvb.d.mts} +148 -2
  67. package/dist/{upgrade-kj2crJSk.mjs → upgrade-B92U83xo.mjs} +2 -2
  68. package/package.json +1 -1
  69. package/dist/retrieval-digest-DYEsIeCE.d.mts +0 -164
  70. /package/dist/{audience-exposure-Cw3SA4WE.d.mts → audience-exposure-CkNZNeVX.d.mts} +0 -0
  71. /package/dist/{cloud-analytics-CSyFE6SS.mjs → cloud-analytics-Ci1yiwD8.mjs} +0 -0
  72. /package/dist/{config-BaTmjDqD.mjs → config-DrZ3fXgf.mjs} +0 -0
  73. /package/dist/{errors-DZiNXv5c.mjs → errors-BDmra6mz.mjs} +0 -0
  74. /package/dist/{i18n-B3BIxShC.mjs → i18n-B1gJ9EW0.mjs} +0 -0
  75. /package/dist/{sidebar-IcpElOVH.mjs → sidebar-3W51s2sF.mjs} +0 -0
  76. /package/dist/{templates-kc7jxspR.mjs → templates-DdB4BBGq.mjs} +0 -0
  77. /package/dist/{utils-DOMeZW9V.mjs → utils-Cc1SrVza.mjs} +0 -0
@@ -1,181 +1,6 @@
1
+ import { i as sha256DocsContent } from "./retrieval-digest-B-SgtXKK.mjs";
1
2
  import { parseDocsAgentSkillFrontmatter, validateDocsAgentSkillFrontmatter } from "./agent-skills-spec.mjs";
2
3
 
3
- //#region src/retrieval-digest.ts
4
- const SHA256_INITIAL_STATE = [
5
- 1779033703,
6
- 3144134277,
7
- 1013904242,
8
- 2773480762,
9
- 1359893119,
10
- 2600822924,
11
- 528734635,
12
- 1541459225
13
- ];
14
- const SHA256_ROUND_CONSTANTS = [
15
- 1116352408,
16
- 1899447441,
17
- 3049323471,
18
- 3921009573,
19
- 961987163,
20
- 1508970993,
21
- 2453635748,
22
- 2870763221,
23
- 3624381080,
24
- 310598401,
25
- 607225278,
26
- 1426881987,
27
- 1925078388,
28
- 2162078206,
29
- 2614888103,
30
- 3248222580,
31
- 3835390401,
32
- 4022224774,
33
- 264347078,
34
- 604807628,
35
- 770255983,
36
- 1249150122,
37
- 1555081692,
38
- 1996064986,
39
- 2554220882,
40
- 2821834349,
41
- 2952996808,
42
- 3210313671,
43
- 3336571891,
44
- 3584528711,
45
- 113926993,
46
- 338241895,
47
- 666307205,
48
- 773529912,
49
- 1294757372,
50
- 1396182291,
51
- 1695183700,
52
- 1986661051,
53
- 2177026350,
54
- 2456956037,
55
- 2730485921,
56
- 2820302411,
57
- 3259730800,
58
- 3345764771,
59
- 3516065817,
60
- 3600352804,
61
- 4094571909,
62
- 275423344,
63
- 430227734,
64
- 506948616,
65
- 659060556,
66
- 883997877,
67
- 958139571,
68
- 1322822218,
69
- 1537002063,
70
- 1747873779,
71
- 1955562222,
72
- 2024104815,
73
- 2227730452,
74
- 2361852424,
75
- 2428436474,
76
- 2756734187,
77
- 3204031479,
78
- 3329325298
79
- ];
80
- function rotateRight(value, bits) {
81
- return value >>> bits | value << 32 - bits;
82
- }
83
- function normalizeDigestContent(value) {
84
- return value.replace(/\r\n?/gu, "\n").replace(/^\uFEFF/u, "").trimEnd();
85
- }
86
- function toSha256Bytes(value) {
87
- return typeof value === "string" ? new TextEncoder().encode(value) : value;
88
- }
89
- /** Validate the bounded HTTP(S) URL or root-relative URI reference used by provenance. */
90
- function isDocsRetrievalCanonicalUrl(value) {
91
- const hasUnsafeCharacter = value.includes("\\") || Array.from(value).some((character) => {
92
- const codePoint = character.codePointAt(0) ?? 0;
93
- return codePoint <= 31 || codePoint === 127;
94
- });
95
- if (!value || value !== value.trim() || value.length > 4096 || hasUnsafeCharacter) return false;
96
- if (/^\/(?!\/)/u.test(value)) try {
97
- new URL(value, "https://docs.local");
98
- return true;
99
- } catch {
100
- return false;
101
- }
102
- try {
103
- const url = new URL(value);
104
- return (url.protocol === "http:" || url.protocol === "https:") && !url.username && !url.password;
105
- } catch {
106
- return false;
107
- }
108
- }
109
- /** Hash exact bytes with portable SHA-256 in Node, edge, and browser runtimes. */
110
- function sha256DocsContent(value) {
111
- const input = toSha256Bytes(value);
112
- const paddedLength = Math.ceil((input.length + 9) / 64) * 64;
113
- const padded = new Uint8Array(paddedLength);
114
- padded.set(input);
115
- padded[input.length] = 128;
116
- const bitLength = input.length * 8;
117
- const dataView = new DataView(padded.buffer);
118
- dataView.setUint32(paddedLength - 8, Math.floor(bitLength / 4294967296), false);
119
- dataView.setUint32(paddedLength - 4, bitLength >>> 0, false);
120
- const state = Uint32Array.from(SHA256_INITIAL_STATE);
121
- const words = new Uint32Array(64);
122
- for (let offset = 0; offset < padded.length; offset += 64) {
123
- for (let index = 0; index < 16; index += 1) words[index] = dataView.getUint32(offset + index * 4, false);
124
- for (let index = 16; index < 64; index += 1) {
125
- const previous15 = words[index - 15];
126
- const previous2 = words[index - 2];
127
- const sigma0 = rotateRight(previous15, 7) ^ rotateRight(previous15, 18) ^ previous15 >>> 3;
128
- const sigma1 = rotateRight(previous2, 17) ^ rotateRight(previous2, 19) ^ previous2 >>> 10;
129
- words[index] = words[index - 16] + sigma0 + words[index - 7] + sigma1 >>> 0;
130
- }
131
- let a = state[0];
132
- let b = state[1];
133
- let c = state[2];
134
- let d = state[3];
135
- let e = state[4];
136
- let f = state[5];
137
- let g = state[6];
138
- let h = state[7];
139
- for (let index = 0; index < 64; index += 1) {
140
- const sum1 = rotateRight(e, 6) ^ rotateRight(e, 11) ^ rotateRight(e, 25);
141
- const choice = e & f ^ ~e & g;
142
- const temporary1 = h + sum1 + choice + SHA256_ROUND_CONSTANTS[index] + words[index] >>> 0;
143
- const temporary2 = (rotateRight(a, 2) ^ rotateRight(a, 13) ^ rotateRight(a, 22)) + (a & b ^ a & c ^ b & c) >>> 0;
144
- h = g;
145
- g = f;
146
- f = e;
147
- e = d + temporary1 >>> 0;
148
- d = c;
149
- c = b;
150
- b = a;
151
- a = temporary1 + temporary2 >>> 0;
152
- }
153
- state[0] = state[0] + a >>> 0;
154
- state[1] = state[1] + b >>> 0;
155
- state[2] = state[2] + c >>> 0;
156
- state[3] = state[3] + d >>> 0;
157
- state[4] = state[4] + e >>> 0;
158
- state[5] = state[5] + f >>> 0;
159
- state[6] = state[6] + g >>> 0;
160
- state[7] = state[7] + h >>> 0;
161
- }
162
- return Array.from(state, (word) => word.toString(16).padStart(8, "0")).join("");
163
- }
164
- /** Hash exact message-content bytes with portable SHA-256. */
165
- function digestDocsContent(value) {
166
- return `sha256:${sha256DocsContent(value)}`;
167
- }
168
- /**
169
- * Hash the normalized retrieval projection used by search provenance.
170
- *
171
- * The projection removes one leading BOM, normalizes line endings to LF, and trims
172
- * trailing whitespace. This deliberately differs from HTTP digests over exact bytes.
173
- */
174
- function digestDocsRetrievalContent(value) {
175
- return digestDocsContent(normalizeDigestContent(value));
176
- }
177
-
178
- //#endregion
179
4
  //#region src/http-cache.ts
180
5
  const BASE64_ALPHABET = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
181
6
  const MAX_CACHED_TEXT_REPRESENTATIONS = 64;
@@ -1115,4 +940,4 @@ async function createDocsStandardsResponse({ request, apiCatalog, apiCatalogEnab
1115
940
  }
1116
941
 
1117
942
  //#endregion
1118
- export { buildDocsLegacySkillsIndex as A, createDocsCacheableResponse as B, DOCS_AGENT_MANIFEST_SCHEMA_MEDIA_TYPE as C, buildDocsA2AAgentCard as D, appendDocsDiscoveryLinkHeader as E, isDocsStandardsDiscoveryRequest as F, digestDocsContent as G, requestHasFreshDocsDate as H, resolveDocsDiscoveryApiRoute as I, sha256DocsContent as J, digestDocsRetrievalContent as K, resolveDocsPublishedAgentSkill as L, createDocsStandardsResponse as M, getDocsAgentManifestLinkHeader as N, buildDocsAgentSkillsIndex as O, getDocsDiscoveryLinkHeader as P, resolveDocsStandardsDiscoveryRequest as R, DOCS_AGENT_MANIFEST_FORMAT as S, DOCS_AGENT_MANIFEST_VERSION as T, requestMatchesDocsEtag as U, formatDocsContentDigest as V, resolveDocsHttpDate as W, DEFAULT_API_CATALOG_FORMAT as _, DEFAULT_A2A_AGENT_CARD_ROUTE as a, DEFAULT_LEGACY_SKILLS_INDEX_ROUTE as b, DEFAULT_AGENT_SKILLS_ARCHIVE_ROUTE_PATTERN as c, DEFAULT_AGENT_SKILLS_ROUTE_PATTERN as d, DEFAULT_AGENT_SKILLS_ROUTE_PREFIX as f, DEFAULT_AGENT_SKILL_RESOURCE_FORMAT as g, DEFAULT_AGENT_SKILL_FORMAT as h, DEFAULT_A2A_AGENT_CARD_FORMAT as i, buildDocsPublishedAgentSkill as j, buildDocsApiCatalog as k, DEFAULT_AGENT_SKILLS_INDEX_FORMAT as l, DEFAULT_AGENT_SKILL_FILE_FORMAT as m, API_CATALOG_MEDIA_TYPE as n, DEFAULT_A2A_PROTOCOL_BINDING as o, DEFAULT_AGENT_SKILL_ARCHIVE_FORMAT as p, isDocsRetrievalCanonicalUrl as q, API_CATALOG_PROFILE_URI as r, DEFAULT_A2A_PROTOCOL_VERSION as s, AGENT_SKILLS_DISCOVERY_SCHEMA_URI as t, DEFAULT_AGENT_SKILLS_INDEX_ROUTE as u, DEFAULT_API_CATALOG_ROUTE as v, DOCS_AGENT_MANIFEST_SCHEMA_URI as w, DEFAULT_LEGACY_SKILLS_ROUTE_PREFIX as x, DEFAULT_LEGACY_SKILLS_INDEX_FORMAT as y, sha256DocsDiscoveryContent as z };
943
+ export { buildDocsLegacySkillsIndex as A, createDocsCacheableResponse as B, DOCS_AGENT_MANIFEST_SCHEMA_MEDIA_TYPE as C, buildDocsA2AAgentCard as D, appendDocsDiscoveryLinkHeader as E, isDocsStandardsDiscoveryRequest as F, requestHasFreshDocsDate as H, resolveDocsDiscoveryApiRoute as I, resolveDocsPublishedAgentSkill as L, createDocsStandardsResponse as M, getDocsAgentManifestLinkHeader as N, buildDocsAgentSkillsIndex as O, getDocsDiscoveryLinkHeader as P, resolveDocsStandardsDiscoveryRequest as R, DOCS_AGENT_MANIFEST_FORMAT as S, DOCS_AGENT_MANIFEST_VERSION as T, requestMatchesDocsEtag as U, formatDocsContentDigest as V, resolveDocsHttpDate as W, DEFAULT_API_CATALOG_FORMAT as _, DEFAULT_A2A_AGENT_CARD_ROUTE as a, DEFAULT_LEGACY_SKILLS_INDEX_ROUTE as b, DEFAULT_AGENT_SKILLS_ARCHIVE_ROUTE_PATTERN as c, DEFAULT_AGENT_SKILLS_ROUTE_PATTERN as d, DEFAULT_AGENT_SKILLS_ROUTE_PREFIX as f, DEFAULT_AGENT_SKILL_RESOURCE_FORMAT as g, DEFAULT_AGENT_SKILL_FORMAT as h, DEFAULT_A2A_AGENT_CARD_FORMAT as i, buildDocsPublishedAgentSkill as j, buildDocsApiCatalog as k, DEFAULT_AGENT_SKILLS_INDEX_FORMAT as l, DEFAULT_AGENT_SKILL_FILE_FORMAT as m, API_CATALOG_MEDIA_TYPE as n, DEFAULT_A2A_PROTOCOL_BINDING as o, DEFAULT_AGENT_SKILL_ARCHIVE_FORMAT as p, API_CATALOG_PROFILE_URI as r, DEFAULT_A2A_PROTOCOL_VERSION as s, AGENT_SKILLS_DISCOVERY_SCHEMA_URI as t, DEFAULT_AGENT_SKILLS_INDEX_ROUTE as u, DEFAULT_API_CATALOG_ROUTE as v, DOCS_AGENT_MANIFEST_SCHEMA_URI as w, DEFAULT_LEGACY_SKILLS_ROUTE_PREFIX as x, DEFAULT_LEGACY_SKILLS_INDEX_FORMAT as y, sha256DocsDiscoveryContent as z };
@@ -1,4 +1,4 @@
1
- import { A as DocsAgentA2ASecurityScheme, M as DocsAgentA2ASkill, O as DocsAgentA2AProtocolBinding, h as DocsAgentA2AConfig, k as DocsAgentA2ASecurityRequirement, m as DocsAgentA2ACapabilities } from "./types-DLLefoU5.mjs";
1
+ import { A as DocsAgentA2AProtocolBinding, M as DocsAgentA2ASecurityScheme, P as DocsAgentA2ASkill, _ as DocsAgentA2AConfig, g as DocsAgentA2ACapabilities, j as DocsAgentA2ASecurityRequirement } from "./types-QhYMnKvb.mjs";
2
2
 
3
3
  //#region src/standards-discovery.d.ts
4
4
  declare const DEFAULT_API_CATALOG_ROUTE = "/.well-known/api-catalog";
@@ -276,12 +276,30 @@ interface PageAgentFailureMode {
276
276
  /** Recovery guidance for the symptom. */
277
277
  resolution?: string;
278
278
  }
279
+ type DocsAccessClaimValue = string | number | boolean | readonly string[];
280
+ /** Declarative, deny-by-default authorization requirements for agent-facing page surfaces. */
281
+ interface DocsPageAccessPolicy {
282
+ /** Require an authenticated principal even when no scopes or claims are listed. */
283
+ visibility?: "public" | "authenticated";
284
+ /** Every listed scope must be present on the principal. */
285
+ scopes?: readonly string[];
286
+ /** Every listed claim must match; arrays match when at least one value overlaps. */
287
+ claims?: Readonly<Record<string, DocsAccessClaimValue>>;
288
+ }
289
+ /** Identity used when evaluating page access outside the MCP transport. */
290
+ interface DocsAccessPrincipal {
291
+ id: string;
292
+ scopes?: readonly string[];
293
+ claims?: Readonly<Record<string, unknown>>;
294
+ }
279
295
  interface PageAgentFrontmatter {
280
296
  /**
281
297
  * Approximate output token target for machine-readable compaction on this page.
282
298
  * Used by `docs agent compact` as a per-page override.
283
299
  */
284
300
  tokenBudget?: number;
301
+ /** Authorization requirements shared by Markdown, search, llms.txt, sync, export, and MCP. */
302
+ access?: DocsPageAccessPolicy;
285
303
  /** Concrete task the page helps an agent complete. */
286
304
  task?: string;
287
305
  /** Observable end state the agent should reach. */
@@ -311,6 +329,41 @@ interface PageSidebarFrontmatter {
311
329
  */
312
330
  folderIndexBehavior?: SidebarFolderIndexBehavior;
313
331
  }
332
+ type DocsOkfStatus = "draft" | "stable" | "deprecated";
333
+ interface DocsOkfSource {
334
+ resource: string;
335
+ id?: string;
336
+ title?: string;
337
+ author?: string;
338
+ usage_count?: number;
339
+ last_modified?: string;
340
+ usage_window?: {
341
+ start?: string;
342
+ end?: string;
343
+ };
344
+ }
345
+ interface DocsOkfActorTimestamp {
346
+ by: string;
347
+ at: string;
348
+ }
349
+ /** Authored OKF v0.2 trust metadata. Missing fields are derived conservatively at runtime. */
350
+ interface DocsOkfTrustMetadataInput {
351
+ sources?: readonly DocsOkfSource[];
352
+ generated?: DocsOkfActorTimestamp;
353
+ verified?: readonly DocsOkfActorTimestamp[];
354
+ status?: DocsOkfStatus;
355
+ stale_after?: string;
356
+ }
357
+ type DocsOkfTrustTier = "unverified" | "machine-confirmed" | "human-reviewed";
358
+ interface DocsOkfTrustMetadata {
359
+ sources: DocsOkfSource[];
360
+ generated: DocsOkfActorTimestamp;
361
+ verified: DocsOkfActorTimestamp[];
362
+ status: DocsOkfStatus;
363
+ stale_after?: string;
364
+ trust_tier: DocsOkfTrustTier;
365
+ stale: boolean;
366
+ }
314
367
  interface PageFrontmatter {
315
368
  title: string;
316
369
  description?: string;
@@ -318,6 +371,8 @@ interface PageFrontmatter {
318
371
  related?: DocsRelatedItem[];
319
372
  /** Per-page agent-oriented metadata used by machine-readable docs features. */
320
373
  agent?: PageAgentFrontmatter;
374
+ /** OKF v0.2 source, generation, verification, lifecycle, and staleness metadata. */
375
+ okf?: DocsOkfTrustMetadataInput;
321
376
  /** Per-page sidebar metadata used when building the docs navigation tree. */
322
377
  sidebar?: PageSidebarFrontmatter;
323
378
  /** Override or disable the estimated reading time for this page. */
@@ -722,6 +777,10 @@ interface PageActionsConfig {
722
777
  copyMarkdown?: boolean | CopyMarkdownConfig;
723
778
  /** "Open in …" dropdown with LLM / tool providers */
724
779
  openDocs?: boolean | OpenDocsConfig;
780
+ /** One-click MCP connection instructions for supported coding agents. */
781
+ connectMcp?: boolean | PageActionConnectMcpConfig;
782
+ /** Agent Skills discovery and install dialog backed by the published skills index. */
783
+ installSkills?: boolean | PageActionInstallSkillsConfig;
725
784
  /**
726
785
  * Where to render the page action buttons relative to the page title.
727
786
  *
@@ -742,6 +801,27 @@ interface PageActionsConfig {
742
801
  */
743
802
  alignment?: "left" | "right";
744
803
  }
804
+ type PageActionMcpProvider = "copy" | "claude-code" | "cursor" | "vscode" | "codex";
805
+ interface PageActionConnectMcpConfig {
806
+ /** Show the connection menu. @default true */
807
+ enabled?: boolean;
808
+ /** Public MCP route or absolute URL. @default "/mcp" */
809
+ endpoint?: string;
810
+ /** Connection targets shown in the menu. */
811
+ providers?: readonly PageActionMcpProvider[];
812
+ /** Trigger label. @default "Connect MCP" */
813
+ label?: string;
814
+ }
815
+ interface PageActionInstallSkillsConfig {
816
+ /** Show the skills install dialog. @default true */
817
+ enabled?: boolean;
818
+ /** Agent Skills index route or absolute URL. */
819
+ index?: string;
820
+ /** Override the install command copied by the dialog. */
821
+ command?: string;
822
+ /** Trigger label. @default "Install skills" */
823
+ label?: string;
824
+ }
745
825
  type DocsAnalyticsSource = "client" | "server" | "mcp";
746
826
  type DocsAgentTraceStatus = "started" | "success" | "error" | "retry" | "timeout";
747
827
  type DocsAgentTraceEventType = "run.start" | "run.end" | "run.error" | "user.input" | "prompt.build" | "retrieval.query" | "retrieval.result" | "retrieval.error" | "model.call" | "model.response" | "model.stream" | "model.error" | "tool.call" | "tool.result" | "tool.error" | "retry" | "timeout" | "error" | "agent.final";
@@ -1196,6 +1276,13 @@ interface DocsMcpToolsConfig {
1196
1276
  listPageSections?: boolean;
1197
1277
  /** Expose a `read_page` tool that returns a page by slug or URL path. */
1198
1278
  readPage?: boolean;
1279
+ /** Expose a budget-aware `read_pages` tool for fetching several pages in one round trip. */
1280
+ readPages?: boolean;
1281
+ /**
1282
+ * Expose `submit_feedback` when machine feedback is enabled. The tool validates
1283
+ * payloads against `feedback.agent.schema` before invoking the configured callback.
1284
+ */
1285
+ submitFeedback?: boolean;
1199
1286
  /** Expose a `list_tasks` tool for pages with actionable agent contracts. */
1200
1287
  listTasks?: boolean;
1201
1288
  /** Expose a `read_task` tool that returns a page's full agent contract. */
@@ -1222,6 +1309,8 @@ interface DocsMcpToolsConfig {
1222
1309
  getConfigSchema?: boolean;
1223
1310
  /** Expose deterministic `get_context` retrieval with a conservative UTF-8 byte ceiling. */
1224
1311
  getContext?: boolean;
1312
+ /** Expose OKF v0.2 source, verification, lifecycle, and staleness metadata. */
1313
+ getTrustMetadata?: boolean;
1225
1314
  }
1226
1315
  /** Built-in MCP prompt templates projected from documentation contracts and golden tasks. */
1227
1316
  interface DocsMcpPromptsConfig {
@@ -1241,7 +1330,7 @@ interface DocsMcpPromptsConfig {
1241
1330
  goldenTasks?: readonly string[];
1242
1331
  }
1243
1332
  /** Authenticated identity returned by an MCP authentication callback. */
1244
- interface DocsMcpAuthPrincipal {
1333
+ interface DocsMcpAuthPrincipal extends DocsAccessPrincipal {
1245
1334
  /** Stable identifier for the authenticated user, service, or agent. */
1246
1335
  id: string;
1247
1336
  /** Optional authorization scopes that source adapters can inspect. */
@@ -1365,6 +1454,7 @@ interface DocsSearchSourcePage {
1365
1454
  description?: string;
1366
1455
  related?: ResolvedDocsRelatedLink[];
1367
1456
  agent?: PageAgentFrontmatter;
1457
+ okf?: DocsOkfTrustMetadataInput;
1368
1458
  sourcePath?: string;
1369
1459
  lastModified?: string;
1370
1460
  lastmod?: string;
@@ -1558,6 +1648,8 @@ interface DocsSearchResult {
1558
1648
  section?: string;
1559
1649
  /** Canonical, scope-aware provenance when supplied or recoverable locally. */
1560
1650
  source?: DocsRetrievalSourceProvenance;
1651
+ /** OKF v0.2 trust metadata for the selected source. */
1652
+ trust?: DocsOkfTrustMetadata;
1561
1653
  /** Present only when the caller opts into retrieval explanations. */
1562
1654
  explanation?: DocsSearchExplanation;
1563
1655
  }
@@ -2647,6 +2739,43 @@ interface ChangelogConfig {
2647
2739
  actionsComponent?: unknown;
2648
2740
  }
2649
2741
  type ApiReferenceRenderer = "fumadocs" | "scalar";
2742
+ interface DocsOpenApiMcpCredentialContext {
2743
+ operationId: string;
2744
+ method: string;
2745
+ path: string;
2746
+ security: readonly Record<string, readonly string[]>[];
2747
+ }
2748
+ type DocsOpenApiMcpHeaders = Readonly<Record<string, string>> | ((context: DocsOpenApiMcpCredentialContext) => Readonly<Record<string, string>> | Promise<Readonly<Record<string, string>>>);
2749
+ type DocsOpenApiMcpHostResolver = (hostname: string) => readonly string[] | Promise<readonly string[]>;
2750
+ /** Explicit, deny-by-default projection of OpenAPI operations into MCP tools. */
2751
+ interface DocsOpenApiMcpConfig {
2752
+ /** Enable operation projection. No tools are exposed until an operation is explicitly allowed. */
2753
+ enabled?: boolean;
2754
+ /** Allowed operationIds or `METHOD /path` selectors. */
2755
+ operations?: readonly string[];
2756
+ /** Override the first OpenAPI server URL used for requests. */
2757
+ baseUrl?: string;
2758
+ /** Allow POST, PUT, PATCH, or DELETE operations. Defaults to false. */
2759
+ allowMutations?: boolean;
2760
+ /** Server-owned credentials added after user input is parsed. */
2761
+ headers?: DocsOpenApiMcpHeaders;
2762
+ /** Per-operation request timeout. @default 10000 */
2763
+ timeoutMs?: number;
2764
+ /** Permit plain HTTP destinations. Disabled by default. */
2765
+ allowInsecureHttp?: boolean;
2766
+ /** Permit loopback, private, link-local, and reserved network destinations. Disabled by default. */
2767
+ allowPrivateNetwork?: boolean;
2768
+ /** Server-owned DNS resolver used before every request and redirect. */
2769
+ resolveHost?: DocsOpenApiMcpHostResolver;
2770
+ /** Number of validated redirects to follow. @default 0 */
2771
+ maxRedirects?: number;
2772
+ /** Maximum downstream response bytes buffered into an MCP result. @default 1000000 */
2773
+ maxResponseBytes?: number;
2774
+ /** Per-principal operation calls allowed in a rolling minute. @default 60 */
2775
+ requestsPerMinute?: number;
2776
+ /** Concurrent downstream operation calls allowed per principal. @default 4 */
2777
+ maxConcurrentRequests?: number;
2778
+ }
2650
2779
  interface ApiReferenceConfig {
2651
2780
  /**
2652
2781
  * Whether to enable generated API reference pages.
@@ -2705,6 +2834,11 @@ interface ApiReferenceConfig {
2705
2834
  * - TanStack Start / SvelteKit / Astro / Nuxt: `"scalar"`
2706
2835
  */
2707
2836
  renderer?: ApiReferenceRenderer;
2837
+ /**
2838
+ * Explicitly expose selected OpenAPI operations as MCP tools. This is deny-by-default:
2839
+ * set `operations`, or mark an operation with `x-farming-labs-mcp.enabled: true`.
2840
+ */
2841
+ mcp?: boolean | DocsOpenApiMcpConfig;
2708
2842
  /**
2709
2843
  * Filesystem route root to scan for API handlers.
2710
2844
  *
@@ -3227,6 +3361,8 @@ interface DocsAgentA2AInterfacesConfig {
3227
3361
  /** Explicit A2A service metadata. Configure this only when the URL implements A2A. */
3228
3362
  type DocsAgentA2AConfig = DocsAgentA2ABaseConfig & (DocsAgentA2ASingleInterfaceConfig | DocsAgentA2AInterfacesConfig);
3229
3363
  interface DocsAgentConfig {
3364
+ /** Publish OKF v0.2 trust metadata and a machine-readable knowledge bundle. */
3365
+ okf?: boolean | DocsOkfConfig;
3230
3366
  /**
3231
3367
  * Defaults for `docs agent compact`.
3232
3368
  */
@@ -3247,6 +3383,16 @@ interface DocsAgentConfig {
3247
3383
  /** Opt in to an A2A Agent Card for a separately implemented A2A service. */
3248
3384
  a2a?: DocsAgentA2AConfig;
3249
3385
  }
3386
+ interface DocsOkfConfig extends DocsOkfTrustMetadataInput {
3387
+ /** Enable OKF projection. @default true when configured */
3388
+ enabled?: boolean;
3389
+ /** Public bundle route. @default "/.well-known/okf.json" */
3390
+ route?: string;
3391
+ /** Generator actor used when a page has no authored `okf.generated`. */
3392
+ generatedBy?: string;
3393
+ /** Derive `stale_after` this many days after the best page timestamp. */
3394
+ staleAfterDays?: number;
3395
+ }
3250
3396
  interface DocsAgentContentChangesConfig {
3251
3397
  /** Disable the runtime content-change endpoint. @default true */
3252
3398
  enabled?: boolean;
@@ -3987,4 +4133,4 @@ interface DocsConfig {
3987
4133
  og?: OGConfig;
3988
4134
  }
3989
4135
  //#endregion
3990
- export { DocsAgentGoldenQueryVariant as $, DocsSearchResult as $n, TypographyConfig as $r, DocsMcpAuthenticateContext as $t, DocsAgentA2ASecurityScheme as A, DocsSearchAmbiguityDecisionStatus as An, PageActionsConfig as Ar, DocsCodeBlocksConfig as At, DocsAgentEvaluationAnswerRunner as B, DocsSearchFilterDecision as Bn, ReadingTimeConfig as Br, DocsContentChangeSnapshotContext as Bt, DocsAgentA2AOAuthDeviceCodeFlow as C, DocsRobotsConfig as Cn, OpenDocsConfig as Cr, DocsAskAIFeedbackValue as Ct, DocsAgentA2AOpenIdConnectSecurityScheme as D, DocsSearchAdapterFactory as Dn, OpenDocsTarget as Dr, DocsCloudFeatureConfig as Dt, DocsAgentA2AOAuthPasswordFlow as E, DocsSearchAdapterContext as En, OpenDocsProviderId as Er, DocsCloudConfig as Et, DocsAgentContentChangesConfig as F, DocsSearchEmbeddingsConfig as Fn, PageAgentVerification as Fr, DocsCodeBlocksValidateConfig as Ft, DocsAgentFeedbackContext as G, DocsSearchMatchField as Gn, SidebarFolderIndexBehavior as Gr, DocsContentSnapshot as Gt, DocsAgentEvaluationSurface as H, DocsSearchFilterField as Hn, ResolvedDocsRelatedLink as Hr, DocsContentChangeSnapshotSaver as Ht, DocsAgentEvaluationAnswerInput as I, DocsSearchExplanation as In, PageFrontmatter as Ir, DocsCodeBlocksValidationMode as It, DocsAgentGoldenAuthenticatedContentExpectation as J, DocsSearchRankingReason as Jn, SidebarPageNode as Jr, DocsFeedbackValue as Jt, DocsAgentFeedbackData as K, DocsSearchMatchedTerm as Kn, SidebarFolderNode as Kr, DocsContentSnapshotDocument as Kt, DocsAgentEvaluationAnswerProvider as L, DocsSearchFacet as Ln, PageOpenGraph as Lr, DocsCodeBlocksValidationPolicy as Lt, DocsAgentA2ASkill as M, DocsSearchChunkingConfig as Mn, PageAgentCommand as Mr, DocsCodeBlocksPlannerProvider as Mt, DocsAgentCompactConfig as N, DocsSearchConfig as Nn, PageAgentFailureMode as Nr, DocsCodeBlocksRunnerConfig as Nt, DocsAgentA2AProtocolBinding as O, DocsSearchAdapterPage as On, OpenGraphImage as Or, DocsCloudPreviewConfig as Ot, DocsAgentConfig as P, DocsSearchDocument as Pn, PageAgentFrontmatter as Pr, DocsCodeBlocksRunnerProvider as Pt, DocsAgentGoldenPromptInjectionExpectation as Q, DocsSearchResponse as Qn, TypesenseDocsSearchConfig as Qr, DocsMcpAuthenticate as Qt, DocsAgentEvaluationAnswerRequest as R, DocsSearchFacetValue as Rn, PageSidebarFrontmatter as Rr, DocsConfig as Rt, DocsAgentA2AOAuthClientCredentialsFlow as S, DocsReviewSeverity as Sn, OGConfig as Sr, DocsAskAIFeedbackMessage as St, DocsAgentA2AOAuthImplicitFlow as T, DocsSearchAdapter as Tn, OpenDocsProviderConfig as Tr, DocsCloudApiKeyConfig as Tt, DocsAgentEvaluationTaskInput as U, DocsSearchFilterInput as Un, SidebarComponentProps as Ur, DocsContentChangedDocument as Ut, DocsAgentEvaluationSourceReference as V, DocsSearchFilterDecisionOutcome as Vn, ReadingTimeFormat as Vr, DocsContentChangeSnapshotLoader as Vt, DocsAgentEvaluationsConfig as W, DocsSearchFilters as Wn, SidebarConfig as Wr, DocsContentChangesResponse as Wt, DocsAgentGoldenExpectedExample as X, DocsSearchRankingStrategy as Xn, SimpleDocsSearchConfig as Xr, DocsMcpAllowedOrigins as Xt, DocsAgentGoldenExampleVerification as Y, DocsSearchRankingReasonCode as Yn, SidebarTree as Yr, DocsI18nConfig as Yt, DocsAgentGoldenFreshnessExpectation as Z, DocsSearchRequest as Zn, ThemeToggleConfig as Zr, DocsMcpAuthPrincipal as Zt, DocsAgentA2AHttpAuthSecurityScheme as _, DocsReviewCiConfig as _n, LlmsTxtConfig as _r, DocsAnalyticsSource as _t, ApiReferenceRenderer as a, DocsMcpProtectedResourceConfig as an, DocsTelemetryAgentSurface as ar, DocsAgentSkillsCompatibilityPolicy as at, DocsAgentA2AOAuth2SecurityScheme as b, DocsReviewRulesConfig as bn, LlmsTxtSectionConfig as br, DocsAskAIFeedbackConfig as bt, ChangelogFrontmatter as c, DocsMetadata as cn, DocsTelemetryEventInput as cr, DocsAgentSkillsProgressiveDisclosureConfig as ct, CopyMarkdownFormat as d, DocsObservabilityEvent as dn, DocsTelemetryFramework as dr, DocsAgentTraceStatus as dt, UIConfig as ei, DocsMcpAuthenticateResult as en, DocsSearchResultType as er, DocsAgentGoldenQueryVariantKind as et, CustomDocsSearchConfig as f, DocsObservabilityEventInput as fn, DocsTheme as fr, DocsAnalyticsConfig as ft, DocsAgentA2AExtension as g, DocsRetrievalSourceScope as gn, LastUpdatedConfig as gr, DocsAnalyticsInput as gt, DocsAgentA2AConfig as h, DocsRetrievalSourceProvenance as hn, GithubConfig as hr, DocsAnalyticsEventType as ht, ApiReferenceConfig as i, DocsMcpPromptsConfig as in, DocsSitemapConfig as ir, DocsAgentGoldenTaskFilters as it, DocsAgentA2ASecurityScopeList as j, DocsSearchAmbiguityResolution as jn, PageAgentAppliesTo as jr, DocsCodeBlocksPlannerConfig as jt, DocsAgentA2ASecurityRequirement as k, DocsSearchAmbiguityDecision as kn, OrderingItem as kr, DocsCloudPublishConfig as kt, CodeBlockCopyData as l, DocsNav as ln, DocsTelemetryEventType as lr, DocsAgentTraceEventInput as lt, DocsAgentA2ACapabilities as m, DocsRelatedItem as mn, FontStyle as mr, DocsAnalyticsEventInput as mt, AgentFeedbackConfig as n, DocsMcpCorsConfig as nn, DocsSearchWarning as nr, DocsAgentGoldenTask as nt, BreadcrumbConfig as o, DocsMcpSecurityConfig as on, DocsTelemetryConfig as or, DocsAgentSkillsConfig as ot, DocsAgentA2AApiKeySecurityScheme as p, DocsPaginatedSearchResponse as pn, FeedbackConfig as pr, DocsAnalyticsEvent as pt, DocsAgentGoldenAnswerExpectation as q, DocsSearchQuery as qn, SidebarNode as qr, DocsFeedbackData as qt, AlgoliaDocsSearchConfig as r, DocsMcpOriginContext as rn, DocsSearchWarningCode as rr, DocsAgentGoldenTaskExpectation as rt, ChangelogConfig as s, DocsMcpToolsConfig as sn, DocsTelemetryEvent as sr, DocsAgentSkillsInput as st, AIConfig as t, DocsMcpConfig as tn, DocsSearchSourcePage as tr, DocsAgentGoldenSafetyExpectation as tt, CopyMarkdownConfig as u, DocsObservabilityConfig as un, DocsTelemetryFeatures as ur, DocsAgentTraceEventType as ut, DocsAgentA2AInterfaceConfig as v, DocsReviewCiMode as vn, LlmsTxtMaxCharsConfig as vr, DocsAskAIActionData as vt, DocsAgentA2AOAuthFlows as w, DocsRobotsRule as wn, OpenDocsProvider as wr, DocsAskAIMcpConfig as wt, DocsAgentA2AOAuthAuthorizationCodeFlow as x, DocsReviewScoreConfig as xn, McpDocsSearchConfig as xr, DocsAskAIFeedbackData as xt, DocsAgentA2AMutualTlsSecurityScheme as y, DocsReviewConfig as yn, LlmsTxtMaxCharsMode as yr, DocsAskAIActionType as yt, DocsAgentEvaluationAnswerResult as z, DocsSearchFacetsResponse as zn, PageTwitter as zr, DocsContentChangeDocument as zt };
4136
+ export { DocsAgentGoldenFreshnessExpectation as $, DocsSearchFilterDecision as $n, PageOpenGraph as $r, DocsMcpAuthPrincipal as $t, DocsAgentA2AProtocolBinding as A, DocsReviewCiConfig as An, LlmsTxtConfig as Ar, DocsCloudPreviewConfig as At, DocsAgentEvaluationAnswerRequest as B, DocsSearchAdapterFactory as Bn, OpenDocsTarget as Br, DocsConfig as Bt, DocsAgentA2AOAuthAuthorizationCodeFlow as C, DocsOpenApiMcpCredentialContext as Cn, DocsTelemetryFeatures as Cr, DocsAskAIFeedbackData as Ct, DocsAgentA2AOAuthImplicitFlow as D, DocsRelatedItem as Dn, FontStyle as Dr, DocsCloudApiKeyConfig as Dt, DocsAgentA2AOAuthFlows as E, DocsPaginatedSearchResponse as En, FeedbackConfig as Er, DocsAskAIMcpConfig as Et, DocsAgentCompactConfig as F, DocsReviewSeverity as Fn, OGConfig as Fr, DocsCodeBlocksRunnerConfig as Ft, DocsAgentEvaluationTaskInput as G, DocsSearchChunkingConfig as Gn, PageActionMcpProvider as Gr, DocsContentChangedDocument as Gt, DocsAgentEvaluationAnswerRunner as H, DocsSearchAmbiguityDecision as Hn, OrderingItem as Hr, DocsContentChangeSnapshotContext as Ht, DocsAgentConfig as I, DocsRobotsConfig as In, OpenDocsConfig as Ir, DocsCodeBlocksRunnerProvider as It, DocsAgentFeedbackData as J, DocsSearchEmbeddingsConfig as Jn, PageAgentCommand as Jr, DocsContentSnapshotDocument as Jt, DocsAgentEvaluationsConfig as K, DocsSearchConfig as Kn, PageActionsConfig as Kr, DocsContentChangesResponse as Kt, DocsAgentContentChangesConfig as L, DocsRobotsRule as Ln, OpenDocsProvider as Lr, DocsCodeBlocksValidateConfig as Lt, DocsAgentA2ASecurityScheme as M, DocsReviewConfig as Mn, LlmsTxtMaxCharsMode as Mr, DocsCodeBlocksConfig as Mt, DocsAgentA2ASecurityScopeList as N, DocsReviewRulesConfig as Nn, LlmsTxtSectionConfig as Nr, DocsCodeBlocksPlannerConfig as Nt, DocsAgentA2AOAuthPasswordFlow as O, DocsRetrievalSourceProvenance as On, GithubConfig as Or, DocsCloudConfig as Ot, DocsAgentA2ASkill as P, DocsReviewScoreConfig as Pn, McpDocsSearchConfig as Pr, DocsCodeBlocksPlannerProvider as Pt, DocsAgentGoldenExpectedExample as Q, DocsSearchFacetsResponse as Qn, PageFrontmatter as Qr, DocsMcpAllowedOrigins as Qt, DocsAgentEvaluationAnswerInput as R, DocsSearchAdapter as Rn, OpenDocsProviderConfig as Rr, DocsCodeBlocksValidationMode as Rt, DocsAgentA2AOAuth2SecurityScheme as S, DocsOpenApiMcpConfig as Sn, DocsTelemetryEventType as Sr, DocsAskAIFeedbackConfig as St, DocsAgentA2AOAuthDeviceCodeFlow as T, DocsPageAccessPolicy as Tn, DocsTheme as Tr, DocsAskAIFeedbackValue as Tt, DocsAgentEvaluationSourceReference as U, DocsSearchAmbiguityDecisionStatus as Un, PageActionConnectMcpConfig as Ur, DocsContentChangeSnapshotLoader as Ut, DocsAgentEvaluationAnswerResult as V, DocsSearchAdapterPage as Vn, OpenGraphImage as Vr, DocsContentChangeDocument as Vt, DocsAgentEvaluationSurface as W, DocsSearchAmbiguityResolution as Wn, PageActionInstallSkillsConfig as Wr, DocsContentChangeSnapshotSaver as Wt, DocsAgentGoldenAuthenticatedContentExpectation as X, DocsSearchFacet as Xn, PageAgentFrontmatter as Xr, DocsFeedbackValue as Xt, DocsAgentGoldenAnswerExpectation as Y, DocsSearchExplanation as Yn, PageAgentFailureMode as Yr, DocsFeedbackData as Yt, DocsAgentGoldenExampleVerification as Z, DocsSearchFacetValue as Zn, PageAgentVerification as Zr, DocsI18nConfig as Zt, DocsAgentA2AConfig as _, DocsOkfSource as _n, DocsSitemapConfig as _r, DocsAnalyticsEventType as _t, ApiReferenceRenderer as a, SidebarComponentProps as ai, DocsMcpOriginContext as an, DocsSearchMatchedTerm as ar, DocsAgentGoldenTaskExpectation as at, DocsAgentA2AInterfaceConfig as b, DocsOkfTrustMetadataInput as bn, DocsTelemetryEvent as br, DocsAskAIActionData as bt, ChangelogFrontmatter as c, SidebarFolderNode as ci, DocsMcpSecurityConfig as cn, DocsSearchRankingReasonCode as cr, DocsAgentSkillsConfig as ct, CopyMarkdownFormat as d, SidebarTree as di, DocsNav as dn, DocsSearchResponse as dr, DocsAgentTraceEventInput as dt, PageSidebarFrontmatter as ei, DocsMcpAuthenticate as en, DocsSearchFilterDecisionOutcome as er, DocsAgentGoldenPromptInjectionExpectation as et, CustomDocsSearchConfig as f, SimpleDocsSearchConfig as fi, DocsObservabilityConfig as fn, DocsSearchResult as fr, DocsAgentTraceEventType as ft, DocsAgentA2ACapabilities as g, UIConfig as gi, DocsOkfConfig as gn, DocsSearchWarningCode as gr, DocsAnalyticsEventInput as gt, DocsAgentA2AApiKeySecurityScheme as h, TypographyConfig as hi, DocsOkfActorTimestamp as hn, DocsSearchWarning as hr, DocsAnalyticsEvent as ht, ApiReferenceConfig as i, ResolvedDocsRelatedLink as ii, DocsMcpCorsConfig as in, DocsSearchMatchField as ir, DocsAgentGoldenTask as it, DocsAgentA2ASecurityRequirement as j, DocsReviewCiMode as jn, LlmsTxtMaxCharsConfig as jr, DocsCloudPublishConfig as jt, DocsAgentA2AOpenIdConnectSecurityScheme as k, DocsRetrievalSourceScope as kn, LastUpdatedConfig as kr, DocsCloudFeatureConfig as kt, CodeBlockCopyData as l, SidebarNode as li, DocsMcpToolsConfig as ln, DocsSearchRankingStrategy as lr, DocsAgentSkillsInput as lt, DocsAccessPrincipal as m, TypesenseDocsSearchConfig as mi, DocsObservabilityEventInput as mn, DocsSearchSourcePage as mr, DocsAnalyticsConfig as mt, AgentFeedbackConfig as n, ReadingTimeConfig as ni, DocsMcpAuthenticateResult as nn, DocsSearchFilterInput as nr, DocsAgentGoldenQueryVariantKind as nt, BreadcrumbConfig as o, SidebarConfig as oi, DocsMcpPromptsConfig as on, DocsSearchQuery as or, DocsAgentGoldenTaskFilters as ot, DocsAccessClaimValue as p, ThemeToggleConfig as pi, DocsObservabilityEvent as pn, DocsSearchResultType as pr, DocsAgentTraceStatus as pt, DocsAgentFeedbackContext as q, DocsSearchDocument as qn, PageAgentAppliesTo as qr, DocsContentSnapshot as qt, AlgoliaDocsSearchConfig as r, ReadingTimeFormat as ri, DocsMcpConfig as rn, DocsSearchFilters as rr, DocsAgentGoldenSafetyExpectation as rt, ChangelogConfig as s, SidebarFolderIndexBehavior as si, DocsMcpProtectedResourceConfig as sn, DocsSearchRankingReason as sr, DocsAgentSkillsCompatibilityPolicy as st, AIConfig as t, PageTwitter as ti, DocsMcpAuthenticateContext as tn, DocsSearchFilterField as tr, DocsAgentGoldenQueryVariant as tt, CopyMarkdownConfig as u, SidebarPageNode as ui, DocsMetadata as un, DocsSearchRequest as ur, DocsAgentSkillsProgressiveDisclosureConfig as ut, DocsAgentA2AExtension as v, DocsOkfStatus as vn, DocsTelemetryAgentSurface as vr, DocsAnalyticsInput as vt, DocsAgentA2AOAuthClientCredentialsFlow as w, DocsOpenApiMcpHeaders as wn, DocsTelemetryFramework as wr, DocsAskAIFeedbackMessage as wt, DocsAgentA2AMutualTlsSecurityScheme as x, DocsOkfTrustTier as xn, DocsTelemetryEventInput as xr, DocsAskAIActionType as xt, DocsAgentA2AHttpAuthSecurityScheme as y, DocsOkfTrustMetadata as yn, DocsTelemetryConfig as yr, DocsAnalyticsSource as yt, DocsAgentEvaluationAnswerProvider as z, DocsSearchAdapterContext as zn, OpenDocsProviderId as zr, DocsCodeBlocksValidationPolicy as zt };
@@ -1,5 +1,5 @@
1
- import { c as fileExists, o as exec } from "./utils-DOMeZW9V.mjs";
2
- import { a as getPackagesForFramework, c as resolveDocsPackageManager, i as frameworkFromPreset, l as validateUpgradeVersion, n as PRESETS, o as presetFromFramework, r as buildDocsPackageInstallCommand, s as resolveDocsPackageFramework, t as PACKAGES_BY_FRAMEWORK } from "./package-version--oQiHwZj.mjs";
1
+ import { c as fileExists, o as exec } from "./utils-Cc1SrVza.mjs";
2
+ import { a as getPackagesForFramework, c as resolveDocsPackageManager, i as frameworkFromPreset, l as validateUpgradeVersion, n as PRESETS, o as presetFromFramework, r as buildDocsPackageInstallCommand, s as resolveDocsPackageFramework, t as PACKAGES_BY_FRAMEWORK } from "./package-version-Ci99L0yo.mjs";
3
3
  import path from "node:path";
4
4
  import pc from "picocolors";
5
5
  import * as p from "@clack/prompts";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@farming-labs/docs",
3
- "version": "0.2.103",
3
+ "version": "0.2.105",
4
4
  "description": "Modern, flexible MDX-based docs framework — core types, config, and CLI",
5
5
  "keywords": [
6
6
  "docs",
@@ -1,164 +0,0 @@
1
- import { Dr as OpenDocsTarget, Hr as ResolvedDocsRelatedLink, ir as DocsSitemapConfig, wr as OpenDocsProvider } from "./types-DLLefoU5.mjs";
2
- import { R as DocsDiscoveryApiRouteOptions } from "./standards-discovery-D1Ys4J3h.mjs";
3
-
4
- //#region src/prompt-utils.d.ts
5
- type PromptAction = "copy" | "open";
6
- interface SerializedOpenDocsProvider {
7
- name: string;
8
- iconHtml?: string;
9
- urlTemplate: string;
10
- promptUrlTemplate?: string;
11
- target?: OpenDocsTarget;
12
- prompt?: string;
13
- }
14
- interface PromptProviderChoice {
15
- name: string;
16
- iconHtml?: string;
17
- urlTemplate: string;
18
- }
19
- type PromptProviderInput = Pick<SerializedOpenDocsProvider, "name" | "iconHtml"> & Partial<Pick<SerializedOpenDocsProvider, "promptUrlTemplate" | "urlTemplate">>;
20
- interface SerializeOpenDocsProviderOptions {
21
- target?: OpenDocsTarget;
22
- prompt?: string;
23
- }
24
- declare const DEFAULT_PROMPT_PROVIDER_TEMPLATES: Record<string, string>;
25
- declare const DEFAULT_OPEN_DOCS_TARGET: OpenDocsTarget;
26
- declare const DEFAULT_OPEN_DOCS_PROMPT = "Read this documentation: {url}";
27
- declare const DEFAULT_OPEN_DOCS_PROVIDER_IDS: readonly ["chatgpt", "claude"];
28
- declare function normalizePromptProviderName(name: string): string;
29
- declare function serializeDocsIcon(icon: unknown): string | undefined;
30
- declare function serializeDocsIconRegistry(icons?: Record<string, unknown>): Record<string, string> | undefined;
31
- declare function serializeOpenDocsProviders(providers?: OpenDocsProvider[], options?: SerializeOpenDocsProviderOptions): SerializedOpenDocsProvider[] | undefined;
32
- declare function serializeOpenDocsProvider(provider: OpenDocsProvider, options?: SerializeOpenDocsProviderOptions): SerializedOpenDocsProvider | undefined;
33
- declare function parsePromptStringArray(value: unknown): string[] | undefined;
34
- declare function resolvePromptProviderChoices(availableProviders?: PromptProviderInput[], preferredNames?: string[]): PromptProviderChoice[];
35
- declare function sanitizePromptText(text: string): string;
36
- //#endregion
37
- //#region src/sitemap.d.ts
38
- declare const DEFAULT_SITEMAP_XML_ROUTE = "/sitemap.xml";
39
- declare const DEFAULT_SITEMAP_MD_ROUTE = "/sitemap.md";
40
- declare const DEFAULT_SITEMAP_MD_DOCS_ROUTE = "/docs/sitemap.md";
41
- declare const DEFAULT_SITEMAP_MD_WELL_KNOWN_ROUTE = "/.well-known/sitemap.md";
42
- declare const DEFAULT_SITEMAP_MANIFEST_PATH = ".farming-labs/sitemap-manifest.json";
43
- type DocsSitemapFormat = "xml" | "markdown";
44
- interface DocsSitemapPageInput {
45
- slug?: string;
46
- url: string;
47
- /** Override the public Markdown representation URL when it differs from `${url}.md`. */
48
- markdownUrl?: string;
49
- title: string;
50
- description?: string;
51
- related?: ResolvedDocsRelatedLink[];
52
- sourcePath?: string;
53
- lastmod?: string;
54
- lastModified?: string;
55
- }
56
- interface DocsSitemapManifestPage {
57
- url: string;
58
- absoluteUrl?: string;
59
- markdownUrl: string;
60
- title: string;
61
- description?: string;
62
- sourcePath?: string;
63
- lastmod?: string;
64
- lastmodSource?: "git" | "filesystem" | "frontmatter" | "manifest" | "unknown";
65
- related?: string[];
66
- }
67
- interface DocsSitemapManifest {
68
- version: 1;
69
- generatedAt: string;
70
- baseUrl?: string;
71
- entry: string;
72
- siteTitle?: string;
73
- pages: DocsSitemapManifestPage[];
74
- }
75
- interface DocsSitemapResolvedConfig {
76
- enabled: boolean;
77
- routePrefix: string;
78
- baseUrl?: string;
79
- manifestPath: string;
80
- xml: {
81
- enabled: boolean;
82
- includeLastmod: boolean;
83
- route: string;
84
- };
85
- markdown: {
86
- enabled: boolean;
87
- includeDescriptions: boolean;
88
- includeLastmod: boolean;
89
- linkTarget: "html" | "markdown" | "both";
90
- route: string;
91
- docsRoute?: string;
92
- wellKnownRoute: string;
93
- };
94
- }
95
- interface CreateDocsSitemapResponseOptions extends DocsDiscoveryApiRouteOptions {
96
- request: Request;
97
- sitemap?: boolean | DocsSitemapConfig;
98
- entry?: string;
99
- siteTitle?: string;
100
- baseUrl?: string;
101
- pages: DocsSitemapPageInput[];
102
- manifest?: DocsSitemapManifest | null;
103
- }
104
- declare function resolveDocsSitemapConfig(sitemap?: boolean | DocsSitemapConfig, defaults?: {
105
- baseUrl?: string;
106
- }): DocsSitemapResolvedConfig;
107
- declare function resolveDocsSitemapRequest(url: URL, sitemap?: boolean | DocsSitemapConfig, options?: DocsDiscoveryApiRouteOptions): DocsSitemapFormat | null;
108
- declare function toDocsSitemapMarkdownUrl(url: string): string;
109
- declare function buildDocsSitemapManifest(options: {
110
- pages: DocsSitemapPageInput[];
111
- entry?: string;
112
- siteTitle?: string;
113
- baseUrl?: string;
114
- generatedAt?: string;
115
- resolveLastmod?: (page: DocsSitemapPageInput) => {
116
- lastmod?: string;
117
- lastmodSource?: DocsSitemapManifestPage["lastmodSource"];
118
- } | undefined;
119
- }): DocsSitemapManifest;
120
- declare function renderDocsSitemapXml(manifest: DocsSitemapManifest, options?: {
121
- baseUrl?: string;
122
- includeLastmod?: boolean;
123
- }): string;
124
- declare function renderDocsSitemapMarkdown(manifest: DocsSitemapManifest, options?: {
125
- baseUrl?: string;
126
- includeDescriptions?: boolean;
127
- includeLastmod?: boolean;
128
- linkTarget?: "html" | "markdown" | "both";
129
- }): string;
130
- declare function readDocsSitemapManifestFromContentMap(contentMap?: Record<string, string> | null): DocsSitemapManifest | null;
131
- declare function resolveDocsSitemapPageLastmod(manifest: DocsSitemapManifest | null | undefined, url: string): string | undefined;
132
- declare function createDocsSitemapResponse({
133
- request,
134
- apiRoute,
135
- sitemap,
136
- entry,
137
- siteTitle,
138
- baseUrl,
139
- pages,
140
- manifest
141
- }: CreateDocsSitemapResponseOptions): Response | null;
142
- //#endregion
143
- //#region src/pagination.d.ts
144
- declare class DocsPaginationCursorError extends Error {
145
- readonly code = "invalid_cursor";
146
- constructor();
147
- }
148
- //#endregion
149
- //#region src/retrieval-digest.d.ts
150
- /** Validate the bounded HTTP(S) URL or root-relative URI reference used by provenance. */
151
- declare function isDocsRetrievalCanonicalUrl(value: string): boolean;
152
- /** Hash exact bytes with portable SHA-256 in Node, edge, and browser runtimes. */
153
- declare function sha256DocsContent(value: string | Uint8Array): string;
154
- /** Hash exact message-content bytes with portable SHA-256. */
155
- declare function digestDocsContent(value: string | Uint8Array): `sha256:${string}`;
156
- /**
157
- * Hash the normalized retrieval projection used by search provenance.
158
- *
159
- * The projection removes one leading BOM, normalizes line endings to LF, and trims
160
- * trailing whitespace. This deliberately differs from HTTP digests over exact bytes.
161
- */
162
- declare function digestDocsRetrievalContent(value: string): `sha256:${string}`;
163
- //#endregion
164
- export { PromptProviderChoice as A, serializeOpenDocsProviders as B, resolveDocsSitemapRequest as C, DEFAULT_OPEN_DOCS_TARGET as D, DEFAULT_OPEN_DOCS_PROVIDER_IDS as E, resolvePromptProviderChoices as F, sanitizePromptText as I, serializeDocsIcon as L, SerializedOpenDocsProvider as M, normalizePromptProviderName as N, DEFAULT_PROMPT_PROVIDER_TEMPLATES as O, parsePromptStringArray as P, serializeDocsIconRegistry as R, resolveDocsSitemapPageLastmod as S, DEFAULT_OPEN_DOCS_PROMPT as T, createDocsSitemapResponse as _, DocsPaginationCursorError as a, renderDocsSitemapXml as b, DEFAULT_SITEMAP_MD_ROUTE as c, DocsSitemapFormat as d, DocsSitemapManifest as f, buildDocsSitemapManifest as g, DocsSitemapResolvedConfig as h, sha256DocsContent as i, SerializeOpenDocsProviderOptions as j, PromptAction as k, DEFAULT_SITEMAP_MD_WELL_KNOWN_ROUTE as l, DocsSitemapPageInput as m, digestDocsRetrievalContent as n, DEFAULT_SITEMAP_MANIFEST_PATH as o, DocsSitemapManifestPage as p, isDocsRetrievalCanonicalUrl as r, DEFAULT_SITEMAP_MD_DOCS_ROUTE as s, digestDocsContent as t, DEFAULT_SITEMAP_XML_ROUTE as u, readDocsSitemapManifestFromContentMap as v, toDocsSitemapMarkdownUrl as w, resolveDocsSitemapConfig as x, renderDocsSitemapMarkdown as y, serializeOpenDocsProvider as z };