From 5778f73fac02a804b6a2ac3a90be33f0a051419c Mon Sep 17 00:00:00 2001 From: t8y2 <1156263951@qq.com> Date: Wed, 10 Jun 2026 12:50:43 +0800 Subject: [PATCH] feat(docs): add SoftwareApplication schema, llms.txt, and AI crawler rules --- docs/app/layout.tsx | 85 +++++++++++++++++++++++++++++++++--------- docs/lib/metadata.ts | 28 ++++++++++++-- docs/public/llms.txt | 50 +++++++++++++++++++++++++ docs/public/robots.txt | 28 ++++++++++++++ 4 files changed, 171 insertions(+), 20 deletions(-) create mode 100644 docs/public/llms.txt diff --git a/docs/app/layout.tsx b/docs/app/layout.tsx index 22ecdf2a4..c8bf31ec2 100644 --- a/docs/app/layout.tsx +++ b/docs/app/layout.tsx @@ -24,29 +24,80 @@ export const metadata: Metadata = { }, }; +const WEBSITE_SCHEMA = { + "@context": "https://schema.org", + "@type": "WebSite", + name: SITE_NAME, + url: SITE_URL, + description: DEFAULT_DESCRIPTION, + potentialAction: { + "@type": "SearchAction", + target: { + "@type": "EntryPoint", + urlTemplate: `${SITE_URL}/search?q={search_term_string}`, + }, + "query-input": "required name=search_term_string", + }, +} as const; + +const SOFTWARE_APP_SCHEMA = { + "@context": "https://schema.org", + "@type": "SoftwareApplication", + name: SITE_NAME, + url: SITE_URL, + description: DEFAULT_DESCRIPTION, + applicationCategory: "Database Management", + operatingSystem: ["Windows", "macOS", "Linux", "Docker"], + offers: { + "@type": "Offer", + price: "0", + priceCurrency: "USD", + }, + author: { + "@type": "Organization", + name: SITE_NAME, + url: SITE_URL, + }, + releaseNotes: `${SITE_URL}/en/changelog`, + screenshot: `${SITE_URL}/screenshot-dark.png`, + featureList: [ + "Multiple database support (MySQL, PostgreSQL, SQLite, Redis, MongoDB, DuckDB, ClickHouse, SQL Server, Oracle)", + "AI-powered SQL generation and explanation", + "MCP Server integration for AI coding agents", + "Schema browser and diff tools", + "Data grid with inline editing", + "SSH tunnel support", + "Docker self-hosting", + ], +} as const; + +const ORG_SCHEMA = { + "@context": "https://schema.org", + "@type": "Organization", + name: SITE_NAME, + url: SITE_URL, + description: DEFAULT_DESCRIPTION, + sameAs: [ + "https://github.com/t8y2/dbx", + "https://www.npmjs.com/package/@dbx-app/mcp-server", + ], +} as const; + export default function RootLayout({ children }: { children: ReactNode }) { return (
+ + {children} diff --git a/docs/lib/metadata.ts b/docs/lib/metadata.ts index 9477b6763..aac9a3f94 100644 --- a/docs/lib/metadata.ts +++ b/docs/lib/metadata.ts @@ -33,11 +33,24 @@ interface BuildMetadataParams { lastModified?: Date; } -export function buildMetadata({ title, description, path, lang, ogType = "website", images }: BuildMetadataParams): Metadata { +export function buildMetadata({ + title, + description, + path, + lang, + ogType = "website", + images, + lastModified, +}: BuildMetadataParams): Metadata { const canonical = `${SITE_URL}${path}`; const locale = LOCALE_MAP[lang] ?? "en_US"; + const ogImages = images?.map((url) => ({ + url, + width: url === DEFAULT_OG_IMAGE ? 512 : 1200, + height: url === DEFAULT_OG_IMAGE ? 512 : 630, + })) ?? [{ url: DEFAULT_OG_IMAGE, width: 512, height: 512 }]; - return { + const base: Metadata = { title, description, alternates: { @@ -55,7 +68,7 @@ export function buildMetadata({ title, description, path, lang, ogType = "websit siteName: SITE_NAME, type: ogType, locale, - images: images?.map((url) => ({ url })) ?? [{ url: DEFAULT_OG_IMAGE }], + images: ogImages, }, twitter: { card: "summary_large_image", @@ -63,5 +76,14 @@ export function buildMetadata({ title, description, path, lang, ogType = "websit description, images: images ?? [DEFAULT_OG_IMAGE], }, + other: { + "og:image:alt": title, + }, }; + + if (lastModified) { + base.other = { ...base.other, "article:modified_time": lastModified.toISOString() }; + } + + return base; } diff --git a/docs/public/llms.txt b/docs/public/llms.txt new file mode 100644 index 000000000..6fe6726a1 --- /dev/null +++ b/docs/public/llms.txt @@ -0,0 +1,50 @@ +# DBX - Database Workspace +# https://dbxio.com + +## What is DBX? +DBX is an open-source database workspace that supports 25+ database engines in a 15 MB package, available as both desktop and Docker deployment. It includes AI-powered SQL generation, MCP server integration for coding agents, schema tools, and self-hosted browser access. + +## Core Features +- **SQL Editor**: CodeMirror 6-based editor with syntax highlighting, auto-completion, formatting, and query history. +- **AI SQL Assistant**: Generate, explain, optimize, and fix SQL using Claude or OpenAI models. +- **MCP Integration**: Expose database connections to AI coding agents (Claude Code, Cursor, Windsurf) via Model Context Protocol. +- **Data Grid**: Virtual scrolling, inline editing, filtering, sorting, and export to CSV/JSON/Markdown. +- **Schema Browser**: Browse databases, schemas, tables, columns, indexes, foreign keys, and triggers. +- **Schema Diff**: Compare schemas across environments and generate migration SQL. +- **Redis Browser**: Pattern-based key search with support for all Redis data types. +- **MongoDB Browser**: Document CRUD with paginated browsing. +- **SSH Tunnels**: Connect to databases behind firewalls with key/password authentication. + +## Supported Databases +MySQL, PostgreSQL, SQLite, Redis, MongoDB, DuckDB, ClickHouse, SQL Server, Oracle, MariaDB, TiDB, and more. + +## MCP Server +```bash +npm install -g @dbx-app/mcp-server +``` +Configure `.mcp.json` to let AI agents query databases through DBX connections: +```json +{ + "mcpServers": { + "dbx": { + "command": "npx", + "args": ["-y", "@dbx-app/mcp-server"] + } + } +} +``` + +## Key Links +- Documentation: https://dbxio.com/en/docs/what-is-dbx +- Changelog: https://dbxio.com/en/changelog +- Community: https://dbxio.com/en/community +- GitHub: https://github.com/t8y2/dbx +- Drivers: https://dbxio.com/en/drivers + +## Platform Support +- Desktop: Windows, macOS (Intel + Apple Silicon), Linux +- Docker: Self-hosted browser-based access +- MCP: npm package for AI agent integration + +## Pricing +DBX is free and open-source (AGPL-3.0). diff --git a/docs/public/robots.txt b/docs/public/robots.txt index db1bc9ceb..89add4345 100644 --- a/docs/public/robots.txt +++ b/docs/public/robots.txt @@ -1,4 +1,32 @@ User-agent: * Allow: / +# AI crawlers — explicitly allowed +User-agent: GPTBot +Allow: / + +User-agent: ChatGPT-User +Allow: / + +User-agent: Claude-Web +Allow: / + +User-agent: ClaudeBot +Allow: / + +User-agent: anthropic-ai +Allow: / + +User-agent: PerplexityBot +Allow: / + +User-agent: Google-Extended +Allow: / + +User-agent: GoogleOther +Allow: / + +User-agent: CCBot +Allow: / + Sitemap: https://dbxio.com/sitemap.xml