docs: add llms

This commit is contained in:
Carl-Gerhard Lindesvärd
2026-02-09 21:46:09 +00:00
parent 40a3178b57
commit 9f441fd9fa
11 changed files with 330 additions and 10 deletions

View File

@@ -10,6 +10,7 @@ import {
import { type InferPageType, loader } from 'fumadocs-core/source';
import { lucideIconsPlugin } from 'fumadocs-core/source/lucide-icons';
import { toFumadocsSource } from 'fumadocs-mdx/runtime/server';
import { OPENPANEL_BASE_URL } from './openpanel-brand';
import type { CompareData } from './compare';
import type { FeatureData } from './features';
import { loadFeatureSourceSync } from './features';
@@ -49,8 +50,11 @@ export function getPageImage(page: InferPageType<typeof source>) {
export async function getLLMText(page: InferPageType<typeof source>) {
const processed = await page.data.getText('processed');
const canonical = `${OPENPANEL_BASE_URL}${page.url}`;
return `# ${page.data.title}
return `---
## ${page.data.title}
URL: ${canonical}
${processed}`;
}