@farming-labs/docs 0.1.38 → 0.1.40
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/dist/cli/index.mjs +1 -1
- package/dist/index.d.mts +30 -1
- package/dist/index.mjs +62 -2
- package/dist/{init-i5ySLGa2.mjs → init-DHlRFytW.mjs} +2 -2
- package/package.json +1 -1
package/dist/cli/index.mjs
CHANGED
|
@@ -69,7 +69,7 @@ async function main() {
|
|
|
69
69
|
searchApiKey: typeof flags["search-api-key"] === "string" ? flags["search-api-key"] : void 0
|
|
70
70
|
};
|
|
71
71
|
if (!parsedCommand.command || parsedCommand.command === "init") {
|
|
72
|
-
const { init } = await import("../init-
|
|
72
|
+
const { init } = await import("../init-DHlRFytW.mjs");
|
|
73
73
|
await init(initOptions);
|
|
74
74
|
} else if (parsedCommand.command === "mcp") {
|
|
75
75
|
const { runMcp } = await import("../mcp-DLP94P1H.mjs");
|
package/dist/index.d.mts
CHANGED
|
@@ -132,6 +132,8 @@ declare const DEFAULT_LLMS_TXT_ROUTE = "/llms.txt";
|
|
|
132
132
|
declare const DEFAULT_LLMS_FULL_TXT_ROUTE = "/llms-full.txt";
|
|
133
133
|
declare const DEFAULT_LLMS_TXT_WELL_KNOWN_ROUTE = "/.well-known/llms.txt";
|
|
134
134
|
declare const DEFAULT_LLMS_FULL_TXT_WELL_KNOWN_ROUTE = "/.well-known/llms-full.txt";
|
|
135
|
+
declare const DEFAULT_SKILL_MD_ROUTE = "/skill.md";
|
|
136
|
+
declare const DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE = "/.well-known/skill.md";
|
|
135
137
|
declare const DEFAULT_AGENT_FEEDBACK_ROUTE = "/api/docs/agent/feedback";
|
|
136
138
|
interface DocsAgentFeedbackDiscoveryConfig {
|
|
137
139
|
enabled?: boolean;
|
|
@@ -156,6 +158,17 @@ interface DocsAgentDiscoverySpecOptions {
|
|
|
156
158
|
acceptHeader?: boolean;
|
|
157
159
|
};
|
|
158
160
|
}
|
|
161
|
+
interface DocsSkillDocumentOptions {
|
|
162
|
+
origin: string;
|
|
163
|
+
entry?: string;
|
|
164
|
+
search?: boolean | DocsSearchConfig;
|
|
165
|
+
mcp: DocsMcpResolvedConfig;
|
|
166
|
+
feedback?: DocsAgentFeedbackDiscoveryConfig;
|
|
167
|
+
llms?: DocsLlmsDiscoveryConfig;
|
|
168
|
+
markdown?: {
|
|
169
|
+
acceptHeader?: boolean;
|
|
170
|
+
};
|
|
171
|
+
}
|
|
159
172
|
interface DocsMarkdownPage {
|
|
160
173
|
slug?: string;
|
|
161
174
|
url: string;
|
|
@@ -173,6 +186,8 @@ declare function normalizeDocsPathSegment(value: string): string;
|
|
|
173
186
|
declare function normalizeDocsUrlPath(value: string): string;
|
|
174
187
|
declare function isDocsAgentDiscoveryRequest(url: URL): boolean;
|
|
175
188
|
declare function isDocsMcpRequest(url: URL): boolean;
|
|
189
|
+
declare function isDocsSkillRequest(url: URL): boolean;
|
|
190
|
+
declare function resolveDocsSkillFormat(url: URL): "skill" | null;
|
|
176
191
|
declare function isDocsPublicGetRequest(entry: string, url: URL, request: Request): boolean;
|
|
177
192
|
declare function resolveDocsLlmsTxtFormat(url: URL): "llms" | "llms-full" | null;
|
|
178
193
|
declare function resolveDocsMarkdownRequest(entry: string, url: URL, request: Request): {
|
|
@@ -181,6 +196,15 @@ declare function resolveDocsMarkdownRequest(entry: string, url: URL, request: Re
|
|
|
181
196
|
declare function findDocsMarkdownPage<T extends DocsMarkdownPage>(entry: string, pages: T[], requestedPath: string): T | null;
|
|
182
197
|
declare function renderDocsMarkdownDocument(page: DocsMcpPage | DocsSearchSourcePage): string;
|
|
183
198
|
declare function renderDocsMarkdownDocument(page: DocsMarkdownPage): string;
|
|
199
|
+
declare function renderDocsSkillDocument({
|
|
200
|
+
origin,
|
|
201
|
+
entry,
|
|
202
|
+
search,
|
|
203
|
+
mcp,
|
|
204
|
+
feedback,
|
|
205
|
+
llms,
|
|
206
|
+
markdown
|
|
207
|
+
}: DocsSkillDocumentOptions): string;
|
|
184
208
|
declare function resolveDocsAgentMdxContent(content: string, audience: "human" | "agent"): string;
|
|
185
209
|
declare function buildDocsAgentDiscoverySpec({
|
|
186
210
|
origin,
|
|
@@ -256,6 +280,11 @@ declare function buildDocsAgentDiscoverySpec({
|
|
|
256
280
|
};
|
|
257
281
|
skills: {
|
|
258
282
|
enabled: boolean;
|
|
283
|
+
file: string;
|
|
284
|
+
route: string;
|
|
285
|
+
wellKnown: string;
|
|
286
|
+
api: string;
|
|
287
|
+
generatedFallback: boolean;
|
|
259
288
|
registry: string;
|
|
260
289
|
install: string;
|
|
261
290
|
recommended: {
|
|
@@ -295,4 +324,4 @@ declare function buildDocsAgentDiscoverySpec({
|
|
|
295
324
|
};
|
|
296
325
|
};
|
|
297
326
|
//#endregion
|
|
298
|
-
export { type AIConfig, type AgentFeedbackConfig, type AlgoliaDocsSearchConfig, type ApiReferenceConfig, type ApiReferenceRenderer, type BreadcrumbConfig, type ChangelogConfig, type ChangelogEntrySummary, type ChangelogFrontmatter, type CodeBlockCopyData, type CopyMarkdownConfig, type CustomDocsSearchConfig, DEFAULT_AGENT_FEEDBACK_ROUTE, DEFAULT_AGENT_SPEC_ROUTE, DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE, DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE, DEFAULT_DOCS_API_ROUTE, DEFAULT_LLMS_FULL_TXT_ROUTE, DEFAULT_LLMS_FULL_TXT_WELL_KNOWN_ROUTE, DEFAULT_LLMS_TXT_ROUTE, DEFAULT_LLMS_TXT_WELL_KNOWN_ROUTE, DEFAULT_MCP_PUBLIC_ROUTE, DEFAULT_MCP_ROUTE, DEFAULT_MCP_WELL_KNOWN_ROUTE, type DocsAgentDiscoverySpecOptions, type DocsAgentFeedbackContext, type DocsAgentFeedbackData, type DocsAgentFeedbackDiscoveryConfig, type DocsConfig, type DocsFeedbackData, type DocsFeedbackValue, type DocsI18nConfig, type DocsLlmsDiscoveryConfig, type DocsMarkdownPage, type DocsMcpConfig, type DocsMcpToolsConfig, type DocsMetadata, type DocsNav, type DocsPathMatch, type DocsRelatedItem, type DocsSearchAdapter, type DocsSearchAdapterContext, type DocsSearchAdapterFactory, type DocsSearchChunkingConfig, type DocsSearchConfig, type DocsSearchDocument, type DocsSearchEmbeddingsConfig, type DocsSearchQuery, type DocsSearchResult, type DocsSearchResultType, type DocsSearchSourcePage, type DocsTheme, type FeedbackConfig, type FontStyle, type GithubConfig, type LastUpdatedConfig, type LlmsTxtConfig, type McpDocsSearchConfig, type OGConfig, type OpenDocsConfig, type OpenDocsProvider, type OpenGraphImage, type OrderingItem, type PageActionsConfig, type PageFrontmatter, type PageOpenGraph, type PageTwitter, type ResolvedChangelogConfig, type ResolvedDocsI18n, type ResolvedDocsRelatedLink, type SidebarComponentProps, type SidebarConfig, type SidebarFolderNode, type SidebarNode, type SidebarPageNode, type SidebarTree, type SimpleDocsSearchConfig, type ThemeToggleConfig, type TypesenseDocsSearchConfig, type TypographyConfig, type UIConfig, buildDocsAgentDiscoverySpec, buildDocsSearchDocuments, buildPageOpenGraph, buildPageTwitter, createAlgoliaSearchAdapter, createCustomSearchAdapter, createMcpSearchAdapter, createSimpleSearchAdapter, createTheme, createTypesenseSearchAdapter, deepMerge, defineDocs, extendTheme, findDocsMarkdownPage, isDocsAgentDiscoveryRequest, isDocsMcpRequest, isDocsPublicGetRequest, normalizeDocsPathSegment, normalizeDocsRelated, normalizeDocsUrlPath, performDocsSearch, renderDocsMarkdownDocument, renderDocsRelatedMarkdownLines, resolveChangelogConfig, resolveDocsAgentMdxContent, resolveDocsI18n, resolveDocsLlmsTxtFormat, resolveDocsLocale, resolveDocsMarkdownRequest, resolveDocsPath, resolveOGImage, resolveSearchRequestConfig, resolveTitle };
|
|
327
|
+
export { type AIConfig, type AgentFeedbackConfig, type AlgoliaDocsSearchConfig, type ApiReferenceConfig, type ApiReferenceRenderer, type BreadcrumbConfig, type ChangelogConfig, type ChangelogEntrySummary, type ChangelogFrontmatter, type CodeBlockCopyData, type CopyMarkdownConfig, type CustomDocsSearchConfig, DEFAULT_AGENT_FEEDBACK_ROUTE, DEFAULT_AGENT_SPEC_ROUTE, DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE, DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE, DEFAULT_DOCS_API_ROUTE, DEFAULT_LLMS_FULL_TXT_ROUTE, DEFAULT_LLMS_FULL_TXT_WELL_KNOWN_ROUTE, DEFAULT_LLMS_TXT_ROUTE, DEFAULT_LLMS_TXT_WELL_KNOWN_ROUTE, DEFAULT_MCP_PUBLIC_ROUTE, DEFAULT_MCP_ROUTE, DEFAULT_MCP_WELL_KNOWN_ROUTE, DEFAULT_SKILL_MD_ROUTE, DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE, type DocsAgentDiscoverySpecOptions, type DocsAgentFeedbackContext, type DocsAgentFeedbackData, type DocsAgentFeedbackDiscoveryConfig, type DocsConfig, type DocsFeedbackData, type DocsFeedbackValue, type DocsI18nConfig, type DocsLlmsDiscoveryConfig, type DocsMarkdownPage, type DocsMcpConfig, type DocsMcpToolsConfig, type DocsMetadata, type DocsNav, type DocsPathMatch, type DocsRelatedItem, type DocsSearchAdapter, type DocsSearchAdapterContext, type DocsSearchAdapterFactory, type DocsSearchChunkingConfig, type DocsSearchConfig, type DocsSearchDocument, type DocsSearchEmbeddingsConfig, type DocsSearchQuery, type DocsSearchResult, type DocsSearchResultType, type DocsSearchSourcePage, type DocsSkillDocumentOptions, type DocsTheme, type FeedbackConfig, type FontStyle, type GithubConfig, type LastUpdatedConfig, type LlmsTxtConfig, type McpDocsSearchConfig, type OGConfig, type OpenDocsConfig, type OpenDocsProvider, type OpenGraphImage, type OrderingItem, type PageActionsConfig, type PageFrontmatter, type PageOpenGraph, type PageTwitter, type ResolvedChangelogConfig, type ResolvedDocsI18n, type ResolvedDocsRelatedLink, type SidebarComponentProps, type SidebarConfig, type SidebarFolderNode, type SidebarNode, type SidebarPageNode, type SidebarTree, type SimpleDocsSearchConfig, type ThemeToggleConfig, type TypesenseDocsSearchConfig, type TypographyConfig, type UIConfig, buildDocsAgentDiscoverySpec, buildDocsSearchDocuments, buildPageOpenGraph, buildPageTwitter, createAlgoliaSearchAdapter, createCustomSearchAdapter, createMcpSearchAdapter, createSimpleSearchAdapter, createTheme, createTypesenseSearchAdapter, deepMerge, defineDocs, extendTheme, findDocsMarkdownPage, isDocsAgentDiscoveryRequest, isDocsMcpRequest, isDocsPublicGetRequest, isDocsSkillRequest, normalizeDocsPathSegment, normalizeDocsRelated, normalizeDocsUrlPath, performDocsSearch, renderDocsMarkdownDocument, renderDocsRelatedMarkdownLines, renderDocsSkillDocument, resolveChangelogConfig, resolveDocsAgentMdxContent, resolveDocsI18n, resolveDocsLlmsTxtFormat, resolveDocsLocale, resolveDocsMarkdownRequest, resolveDocsPath, resolveDocsSkillFormat, resolveOGImage, resolveSearchRequestConfig, resolveTitle };
|
package/dist/index.mjs
CHANGED
|
@@ -278,6 +278,8 @@ const DEFAULT_LLMS_TXT_ROUTE = "/llms.txt";
|
|
|
278
278
|
const DEFAULT_LLMS_FULL_TXT_ROUTE = "/llms-full.txt";
|
|
279
279
|
const DEFAULT_LLMS_TXT_WELL_KNOWN_ROUTE = "/.well-known/llms.txt";
|
|
280
280
|
const DEFAULT_LLMS_FULL_TXT_WELL_KNOWN_ROUTE = "/.well-known/llms-full.txt";
|
|
281
|
+
const DEFAULT_SKILL_MD_ROUTE = "/skill.md";
|
|
282
|
+
const DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE = "/.well-known/skill.md";
|
|
281
283
|
const DEFAULT_AGENT_FEEDBACK_ROUTE = "/api/docs/agent/feedback";
|
|
282
284
|
function normalizeDocsPathSegment(value) {
|
|
283
285
|
return value.replace(/^\/+|\/+$/g, "");
|
|
@@ -296,10 +298,18 @@ function isDocsMcpRequest(url) {
|
|
|
296
298
|
const pathname = normalizeDocsUrlPath(url.pathname);
|
|
297
299
|
return pathname === DEFAULT_MCP_ROUTE || pathname === DEFAULT_MCP_PUBLIC_ROUTE || pathname === DEFAULT_MCP_WELL_KNOWN_ROUTE;
|
|
298
300
|
}
|
|
301
|
+
function isDocsSkillRequest(url) {
|
|
302
|
+
const pathname = normalizeDocsUrlPath(url.pathname);
|
|
303
|
+
if (pathname === DEFAULT_SKILL_MD_ROUTE || pathname === DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE) return true;
|
|
304
|
+
return pathname === DEFAULT_DOCS_API_ROUTE && resolveDocsSkillFormat(url) === "skill";
|
|
305
|
+
}
|
|
306
|
+
function resolveDocsSkillFormat(url) {
|
|
307
|
+
return url.searchParams.get("format")?.trim() === "skill" ? "skill" : null;
|
|
308
|
+
}
|
|
299
309
|
function isDocsPublicGetRequest(entry, url, request) {
|
|
300
310
|
const pathname = normalizeDocsUrlPath(url.pathname);
|
|
301
311
|
if (pathname === DEFAULT_DOCS_API_ROUTE || pathname === DEFAULT_MCP_ROUTE) return false;
|
|
302
|
-
return isDocsAgentDiscoveryRequest(url) || resolveDocsLlmsTxtFormat(url) !== null || resolveDocsMarkdownRequest(entry, url, request) !== null;
|
|
312
|
+
return isDocsAgentDiscoveryRequest(url) || isDocsSkillRequest(url) || resolveDocsLlmsTxtFormat(url) !== null || resolveDocsMarkdownRequest(entry, url, request) !== null;
|
|
303
313
|
}
|
|
304
314
|
function resolveDocsLlmsTxtFormat(url) {
|
|
305
315
|
const pathname = normalizeDocsUrlPath(url.pathname);
|
|
@@ -338,6 +348,40 @@ function renderDocsMarkdownDocument(page) {
|
|
|
338
348
|
lines.push("", page.agentFallbackRawContent ?? page.rawContent ?? page.content);
|
|
339
349
|
return lines.join("\n");
|
|
340
350
|
}
|
|
351
|
+
function renderDocsSkillDocument({ origin, entry = "docs", search, mcp, feedback, llms, markdown }) {
|
|
352
|
+
const normalizedEntry = normalizeDocsPathSegment(entry) || "docs";
|
|
353
|
+
const siteTitle = compactSkillText(llms?.siteTitle ?? "Documentation");
|
|
354
|
+
const siteDescription = llms?.siteDescription ? compactSkillText(llms.siteDescription) : void 0;
|
|
355
|
+
const llmsEnabled = llms?.enabled ?? true;
|
|
356
|
+
const searchEnabled = isSearchEnabled(search);
|
|
357
|
+
const feedbackEnabled = feedback?.enabled ?? false;
|
|
358
|
+
const feedbackRoute = feedback?.route ?? DEFAULT_AGENT_FEEDBACK_ROUTE;
|
|
359
|
+
const feedbackSchemaRoute = feedback?.schemaRoute ?? `${feedbackRoute}/schema`;
|
|
360
|
+
const description = truncateSkillDescription(`Use ${siteTitle} through markdown routes, llms.txt, agent discovery, search, and MCP when available.`);
|
|
361
|
+
const markdownAcceptHeader = markdown?.acceptHeader === false ? null : "text/markdown";
|
|
362
|
+
const lines = [
|
|
363
|
+
"---",
|
|
364
|
+
"name: docs",
|
|
365
|
+
`description: ${toYamlString(description)}`,
|
|
366
|
+
"---",
|
|
367
|
+
"",
|
|
368
|
+
`# ${siteTitle} Skill`,
|
|
369
|
+
"",
|
|
370
|
+
`Base URL: ${origin}`
|
|
371
|
+
];
|
|
372
|
+
if (siteDescription) lines.push(`Description: ${siteDescription}`);
|
|
373
|
+
lines.push("", "## When To Use", "Use this skill when you need to read or implement against this documentation site.", "", "## Start Here", `- Fetch ${DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE}; fall back to ${DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE} or ${DEFAULT_AGENT_SPEC_ROUTE}.`, `- Fetch /${normalizedEntry}.md for the root docs page.`, `- Fetch /${normalizedEntry}/{slug}.md for page-specific context.`);
|
|
374
|
+
if (markdownAcceptHeader) lines.push(`- You can also request ${markdownAcceptHeader} from normal page URLs.`);
|
|
375
|
+
if (searchEnabled) lines.push(`- Search with ${DEFAULT_DOCS_API_ROUTE}?query={query} when you do not know the page.`);
|
|
376
|
+
if (llmsEnabled) lines.push(`- Use ${DEFAULT_LLMS_TXT_ROUTE} for a compact docs index.`, `- Use ${DEFAULT_LLMS_FULL_TXT_ROUTE} for full markdown context.`);
|
|
377
|
+
if (mcp.enabled) lines.push(`- Use ${DEFAULT_MCP_WELL_KNOWN_ROUTE} or ${DEFAULT_MCP_PUBLIC_ROUTE} for MCP tools when your environment supports MCP.`);
|
|
378
|
+
if (feedbackEnabled) lines.push(`- Read ${feedbackSchemaRoute} before posting agent feedback to ${feedbackRoute}.`);
|
|
379
|
+
lines.push("", "## Routes", `- Skill document: ${DEFAULT_SKILL_MD_ROUTE}`, `- Skill well-known alias: ${DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE}`, `- Skill API format: ${DEFAULT_DOCS_API_ROUTE}?format=skill`, `- Agent discovery: ${DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE}`, `- Agent discovery fallback: ${DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE}`, `- Markdown root: /${normalizedEntry}.md`, `- Markdown pages: /${normalizedEntry}/{slug}.md`);
|
|
380
|
+
if (llmsEnabled) lines.push(`- llms.txt: ${DEFAULT_LLMS_TXT_ROUTE}`, `- llms-full.txt: ${DEFAULT_LLMS_FULL_TXT_ROUTE}`, `- llms well-known aliases: ${DEFAULT_LLMS_TXT_WELL_KNOWN_ROUTE}, ${DEFAULT_LLMS_FULL_TXT_WELL_KNOWN_ROUTE}`);
|
|
381
|
+
if (mcp.enabled) lines.push(`- MCP: ${DEFAULT_MCP_PUBLIC_ROUTE}, ${DEFAULT_MCP_WELL_KNOWN_ROUTE}`);
|
|
382
|
+
lines.push("", "## Reusable Framework Skills", "For framework setup, CLI, page actions, Ask AI, or configuration work, install the reusable Farming Labs skills:", "", "```sh", "npx skills add farming-labs/docs", "```");
|
|
383
|
+
return lines.join("\n");
|
|
384
|
+
}
|
|
341
385
|
function resolveDocsAgentMdxContent(content, audience) {
|
|
342
386
|
const lines = content.split("\n");
|
|
343
387
|
const output = [];
|
|
@@ -461,6 +505,11 @@ function buildDocsAgentDiscoverySpec({ origin, entry = "docs", i18n = null, sear
|
|
|
461
505
|
},
|
|
462
506
|
skills: {
|
|
463
507
|
enabled: true,
|
|
508
|
+
file: "skill.md",
|
|
509
|
+
route: DEFAULT_SKILL_MD_ROUTE,
|
|
510
|
+
wellKnown: DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE,
|
|
511
|
+
api: `${DEFAULT_DOCS_API_ROUTE}?format=skill`,
|
|
512
|
+
generatedFallback: true,
|
|
464
513
|
registry: "skills.sh",
|
|
465
514
|
install: "npx skills add farming-labs/docs",
|
|
466
515
|
recommended: [{
|
|
@@ -522,6 +571,17 @@ function isSearchEnabled(search) {
|
|
|
522
571
|
if (search && typeof search === "object" && search.enabled === false) return false;
|
|
523
572
|
return true;
|
|
524
573
|
}
|
|
574
|
+
function compactSkillText(value) {
|
|
575
|
+
return value.replace(/\s+/g, " ").trim();
|
|
576
|
+
}
|
|
577
|
+
function truncateSkillDescription(value) {
|
|
578
|
+
const normalized = compactSkillText(value);
|
|
579
|
+
if (normalized.length <= 1024) return normalized;
|
|
580
|
+
return `${normalized.slice(0, 1021).trimEnd()}...`;
|
|
581
|
+
}
|
|
582
|
+
function toYamlString(value) {
|
|
583
|
+
return JSON.stringify(value);
|
|
584
|
+
}
|
|
525
585
|
|
|
526
586
|
//#endregion
|
|
527
|
-
export { DEFAULT_AGENT_FEEDBACK_ROUTE, DEFAULT_AGENT_SPEC_ROUTE, DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE, DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE, DEFAULT_DOCS_API_ROUTE, DEFAULT_LLMS_FULL_TXT_ROUTE, DEFAULT_LLMS_FULL_TXT_WELL_KNOWN_ROUTE, DEFAULT_LLMS_TXT_ROUTE, DEFAULT_LLMS_TXT_WELL_KNOWN_ROUTE, DEFAULT_MCP_PUBLIC_ROUTE, DEFAULT_MCP_ROUTE, DEFAULT_MCP_WELL_KNOWN_ROUTE, buildDocsAgentDiscoverySpec, buildDocsSearchDocuments, buildPageOpenGraph, buildPageTwitter, createAlgoliaSearchAdapter, createCustomSearchAdapter, createMcpSearchAdapter, createSimpleSearchAdapter, createTheme, createTypesenseSearchAdapter, deepMerge, defineDocs, extendTheme, findDocsMarkdownPage, isDocsAgentDiscoveryRequest, isDocsMcpRequest, isDocsPublicGetRequest, normalizeDocsPathSegment, normalizeDocsRelated, normalizeDocsUrlPath, performDocsSearch, renderDocsMarkdownDocument, renderDocsRelatedMarkdownLines, resolveChangelogConfig, resolveDocsAgentMdxContent, resolveDocsI18n, resolveDocsLlmsTxtFormat, resolveDocsLocale, resolveDocsMarkdownRequest, resolveDocsPath, resolveOGImage, resolveSearchRequestConfig, resolveTitle };
|
|
587
|
+
export { DEFAULT_AGENT_FEEDBACK_ROUTE, DEFAULT_AGENT_SPEC_ROUTE, DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE, DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE, DEFAULT_DOCS_API_ROUTE, DEFAULT_LLMS_FULL_TXT_ROUTE, DEFAULT_LLMS_FULL_TXT_WELL_KNOWN_ROUTE, DEFAULT_LLMS_TXT_ROUTE, DEFAULT_LLMS_TXT_WELL_KNOWN_ROUTE, DEFAULT_MCP_PUBLIC_ROUTE, DEFAULT_MCP_ROUTE, DEFAULT_MCP_WELL_KNOWN_ROUTE, DEFAULT_SKILL_MD_ROUTE, DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE, buildDocsAgentDiscoverySpec, buildDocsSearchDocuments, buildPageOpenGraph, buildPageTwitter, createAlgoliaSearchAdapter, createCustomSearchAdapter, createMcpSearchAdapter, createSimpleSearchAdapter, createTheme, createTypesenseSearchAdapter, deepMerge, defineDocs, extendTheme, findDocsMarkdownPage, isDocsAgentDiscoveryRequest, isDocsMcpRequest, isDocsPublicGetRequest, isDocsSkillRequest, normalizeDocsPathSegment, normalizeDocsRelated, normalizeDocsUrlPath, performDocsSearch, renderDocsMarkdownDocument, renderDocsRelatedMarkdownLines, renderDocsSkillDocument, resolveChangelogConfig, resolveDocsAgentMdxContent, resolveDocsI18n, resolveDocsLlmsTxtFormat, resolveDocsLocale, resolveDocsMarkdownRequest, resolveDocsPath, resolveDocsSkillFormat, resolveOGImage, resolveSearchRequestConfig, resolveTitle };
|
|
@@ -1257,7 +1257,7 @@ import { createDocsServer } from "@farming-labs/svelte/server";
|
|
|
1257
1257
|
import config from "${svelteServerConfigImport(cfg.useAlias)}";
|
|
1258
1258
|
|
|
1259
1259
|
// preload for production
|
|
1260
|
-
const contentFiles = import.meta.glob("/${cfg.entry ?? "docs"}/**/*.{md,mdx,svx}", {
|
|
1260
|
+
const contentFiles = import.meta.glob(["/${cfg.entry ?? "docs"}/**/*.{md,mdx,svx}", "/skill.md"], {
|
|
1261
1261
|
query: "?raw",
|
|
1262
1262
|
import: "default",
|
|
1263
1263
|
eager: true,
|
|
@@ -1661,7 +1661,7 @@ function astroDocsServerTemplate(cfg) {
|
|
|
1661
1661
|
import { createDocsServer } from "@farming-labs/astro/server";
|
|
1662
1662
|
import config from "${astroServerConfigImport(cfg.useAlias)}";
|
|
1663
1663
|
|
|
1664
|
-
const contentFiles = import.meta.glob("/${cfg.entry ?? "docs"}/**/*.{md,mdx}", {
|
|
1664
|
+
const contentFiles = import.meta.glob(["/${cfg.entry ?? "docs"}/**/*.{md,mdx}", "/skill.md"], {
|
|
1665
1665
|
query: "?raw",
|
|
1666
1666
|
import: "default",
|
|
1667
1667
|
eager: true,
|