From 3658c9c93cd8825e155c67d306a919b1482a4fab Mon Sep 17 00:00:00 2001 From: Wayne Sutton Date: Sat, 10 Jan 2026 11:55:43 -0800 Subject: [PATCH] update: dashbaord siteconfig and Ask AI documentation alignment --- FORK_CONFIG.md | 50 +++++++++++++++++++ TASK.md | 9 +++- changelog.md | 15 ++++++ content/blog/fork-configuration-guide.md | 15 ++++++ .../how-to-use-the-markdown-sync-dashboard.md | 33 ++++++++++++ content/pages/changelog-page.md | 24 +++++++++ content/pages/docs-configuration.md | 36 +++++++++++++ content/pages/docs-dashboard.md | 34 +++++++++++++ fork-config.json.example | 8 +++ public/raw/changelog.md | 24 +++++++++ public/raw/docs-configuration.md | 38 +++++++++++++- public/raw/docs-dashboard.md | 34 +++++++++++++ public/raw/fork-configuration-guide.md | 15 ++++++ .../how-to-use-the-markdown-sync-dashboard.md | 33 ++++++++++++ src/config/siteConfig.ts | 4 +- src/styles/global.css | 2 +- 16 files changed, 369 insertions(+), 5 deletions(-) diff --git a/FORK_CONFIG.md b/FORK_CONFIG.md index 151a72a..985ab90 100644 --- a/FORK_CONFIG.md +++ b/FORK_CONFIG.md @@ -1232,6 +1232,56 @@ Requires `rightSidebar: true` and `siteConfig.aiChat.enabledOnContent: true`. --- +## Ask AI Configuration + +Enable an Ask AI header chat button that opens a modal for asking questions about site content. Uses RAG (Retrieval Augmented Generation) with streaming responses. + +### In fork-config.json + +```json +{ + "askAI": { + "enabled": true, + "defaultModel": "claude-sonnet-4-20250514", + "models": [ + { "id": "claude-sonnet-4-20250514", "name": "Claude Sonnet 4", "provider": "anthropic" }, + { "id": "gpt-4o", "name": "GPT-4o", "provider": "openai" } + ] + } +} +``` + +### Manual Configuration + +In `src/config/siteConfig.ts`: + +```typescript +askAI: { + enabled: true, // Enable Ask AI header button + defaultModel: "claude-sonnet-4-20250514", + models: [ + { id: "claude-sonnet-4-20250514", name: "Claude Sonnet 4", provider: "anthropic" }, + { id: "gpt-4o", name: "GPT-4o", provider: "openai" }, + ], +}, +``` + +**Requirements:** + +- `semanticSearch.enabled: true` for content retrieval +- `OPENAI_API_KEY` in Convex for embeddings +- `ANTHROPIC_API_KEY` or `OPENAI_API_KEY` for the LLM (depending on selected model) + +**Features:** + +- Header button opens a chat modal +- Retrieves relevant content using semantic search +- Streaming responses with markdown rendering +- Multi-model selector (Claude Sonnet 4, GPT-4o) +- Conversation history within session + +--- + ## Posts Display Configuration Control where posts appear and limit homepage display. diff --git a/TASK.md b/TASK.md index de77ff9..34a9295 100644 --- a/TASK.md +++ b/TASK.md @@ -4,10 +4,17 @@ ## Current Status -v2.16.1 ready. Docs layout scrollbar hiding for cleaner UI. +v2.16.2 ready. Ask AI configuration documentation alignment. ## Completed +- [x] Ask AI documentation alignment (v2.16.2) + - [x] Added `askAI` config to `fork-config.json.example` + - [x] Added Ask AI Configuration section to `FORK_CONFIG.md` + - [x] Added Ask AI (header chat) section to `docs-dashboard.md` + - [x] Added Ask AI (header chat) section to `how-to-use-the-markdown-sync-dashboard.md` + - [x] Updated changelog.md, task.md, changelog-page.md + - [x] Docs layout scrollbar hiding (v2.16.1) - [x] Hidden scrollbars on left sidebar, right sidebar, and main docs content - [x] Added body:has(.docs-layout) to prevent page-level scrolling diff --git a/changelog.md b/changelog.md index 9fa635d..d2d6d79 100644 --- a/changelog.md +++ b/changelog.md @@ -4,6 +4,21 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). +## [2.16.2] - 2026-01-10 + +### Added + +- Ask AI configuration documentation alignment + - Added `askAI` config to `fork-config.json.example` with enabled, defaultModel, and models fields + - Added Ask AI Configuration section to `FORK_CONFIG.md` with fork-config.json and manual configuration examples + - Added Ask AI (header chat) section to `docs-dashboard.md` with configuration and requirements + - Added Ask AI (header chat) section to `how-to-use-the-markdown-sync-dashboard.md` with step-by-step setup + +### Technical + +- `fork-config.json.example` now includes askAI config matching siteConfig.ts structure +- All dashboard documentation now includes Ask AI feature alongside AI Agent and AI Dashboard sections + ## [2.16.1] - 2026-01-10 ### Fixed diff --git a/content/blog/fork-configuration-guide.md b/content/blog/fork-configuration-guide.md index ef0ec2d..28693db 100644 --- a/content/blog/fork-configuration-guide.md +++ b/content/blog/fork-configuration-guide.md @@ -276,6 +276,17 @@ The JSON config file supports additional options: }, "imageLightbox": { "enabled": true + }, + "semanticSearch": { + "enabled": false + }, + "askAI": { + "enabled": false, + "defaultModel": "claude-sonnet-4-20250514", + "models": [ + { "id": "claude-sonnet-4-20250514", "name": "Claude Sonnet 4", "provider": "anthropic" }, + { "id": "gpt-4o", "name": "GPT-4o", "provider": "openai" } + ] } } ``` @@ -306,6 +317,10 @@ These are optional. If you omit them, the script uses sensible defaults. See `fo **Image Lightbox**: Click-to-magnify functionality for images in blog posts and pages. Images open in full-screen overlay when clicked. +**Semantic Search**: AI-powered search using OpenAI embeddings. Requires `OPENAI_API_KEY` in Convex. When disabled, only keyword search is available. + +**Ask AI**: Header chat button for RAG-based Q&A about your site content. Requires `semanticSearch.enabled: true` and `OPENAI_API_KEY` for embeddings, plus `ANTHROPIC_API_KEY` or `OPENAI_API_KEY` for the LLM. + For detailed configuration instructions, see `FORK_CONFIG.md`. ## After configuring diff --git a/content/blog/how-to-use-the-markdown-sync-dashboard.md b/content/blog/how-to-use-the-markdown-sync-dashboard.md index f7f7bb5..90fed03 100644 --- a/content/blog/how-to-use-the-markdown-sync-dashboard.md +++ b/content/blog/how-to-use-the-markdown-sync-dashboard.md @@ -97,6 +97,39 @@ The dashboard includes a dedicated AI chat section separate from the Write page. The AI Agent uses Anthropic Claude API and requires `ANTHROPIC_API_KEY` in your Convex environment variables. Chat history is stored per-session in Convex. +## Ask AI (header chat) + +The Ask AI feature adds a chat button to your site header that lets visitors ask questions about your content. It uses RAG (Retrieval Augmented Generation) to find relevant content and provide AI-powered answers. + +**To enable Ask AI:** + +1. Enable semantic search in `siteConfig.ts`: + +```typescript +semanticSearch: { + enabled: true, +}, +``` + +2. Configure Ask AI: + +```typescript +askAI: { + enabled: true, + defaultModel: "claude-sonnet-4-20250514", + models: [ + { id: "claude-sonnet-4-20250514", name: "Claude Sonnet 4", provider: "anthropic" }, + { id: "gpt-4o", name: "GPT-4o", provider: "openai" }, + ], +}, +``` + +3. Set required environment variables in Convex: + - `OPENAI_API_KEY` for embeddings + - `ANTHROPIC_API_KEY` or `OPENAI_API_KEY` for the LLM + +When enabled, a chat button appears in the header. Clicking it opens a modal where visitors can ask questions. The AI retrieves relevant content from your posts and pages, then generates answers with source citations. + ## Newsletter management ![Newsletter management](/images/dashboard5.png) diff --git a/content/pages/changelog-page.md b/content/pages/changelog-page.md index bec702d..af15bc1 100644 --- a/content/pages/changelog-page.md +++ b/content/pages/changelog-page.md @@ -11,6 +11,30 @@ docsSectionOrder: 4 All notable changes to this project. +## v2.16.2 + +Released January 10, 2026 + +**Ask AI documentation alignment** + +Aligned Ask AI configuration across all config and documentation files. The Ask AI feature (header chat with RAG) is now properly documented alongside AI Agent and AI Dashboard features. + +**Changes:** + +- Added `askAI` config to `fork-config.json.example` +- Added Ask AI Configuration section to `FORK_CONFIG.md` +- Added Ask AI (header chat) section to `docs-dashboard.md` +- Added Ask AI (header chat) section to `how-to-use-the-markdown-sync-dashboard.md` + +**Files changed:** + +- `fork-config.json.example` - Added askAI config block +- `FORK_CONFIG.md` - Added Ask AI Configuration section +- `content/pages/docs-dashboard.md` - Added Ask AI documentation +- `content/blog/how-to-use-the-markdown-sync-dashboard.md` - Added Ask AI setup guide + +--- + ## v2.16.1 Released January 10, 2026 diff --git a/content/pages/docs-configuration.md b/content/pages/docs-configuration.md index 1eb5102..9a473a9 100644 --- a/content/pages/docs-configuration.md +++ b/content/pages/docs-configuration.md @@ -442,3 +442,39 @@ The `npm run sync` command only syncs markdown text content. Images are deployed - **Homepage logo:** Configured via `logo` in `siteConfig.ts`. Set to `null` to hide. - **Inner page logo:** Configured via `innerPageLogo` in `siteConfig.ts`. Shows on blog page, posts, and static pages. Desktop: top left corner. Mobile: top right corner (smaller). Set `enabled: false` to hide on inner pages while keeping homepage logo. + +### AI features + +Configure AI-powered features in `src/config/siteConfig.ts`: + +**Semantic Search:** + +```typescript +semanticSearch: { + enabled: true, // Requires OPENAI_API_KEY in Convex +}, +``` + +When enabled, users can toggle between keyword and semantic search in the search modal (Cmd+K). Semantic search finds content by meaning using OpenAI embeddings. + +**Ask AI (header chat):** + +```typescript +askAI: { + enabled: true, + defaultModel: "claude-sonnet-4-20250514", + models: [ + { id: "claude-sonnet-4-20250514", name: "Claude Sonnet 4", provider: "anthropic" }, + { id: "gpt-4o", name: "GPT-4o", provider: "openai" }, + ], +}, +``` + +Adds a chat button to the header for RAG-based Q&A about your content. Requirements: +- `semanticSearch.enabled: true` +- `OPENAI_API_KEY` in Convex (for embeddings) +- `ANTHROPIC_API_KEY` or `OPENAI_API_KEY` (for the LLM) + +**AI Dashboard:** + +The Dashboard includes a multi-model AI Agent with chat and image generation. See [Dashboard](/docs-dashboard) for configuration details. diff --git a/content/pages/docs-dashboard.md b/content/pages/docs-dashboard.md index 331b1a6..463d01d 100644 --- a/content/pages/docs-dashboard.md +++ b/content/pages/docs-dashboard.md @@ -165,6 +165,40 @@ The Dashboard includes a dedicated AI Agent section with tab-based UI for Chat a **Note:** Only configure the API keys for models you want to use. If a key is not set, users see a helpful setup message when they try to use that model. +### Ask AI (header chat) + +The Ask AI feature adds a chat button to the site header. Visitors can ask questions about your content and get AI-powered answers with source citations. + +**Configuration:** + +In `src/config/siteConfig.ts`: + +```typescript +askAI: { + enabled: true, // Enable Ask AI header button + defaultModel: "claude-sonnet-4-20250514", + models: [ + { id: "claude-sonnet-4-20250514", name: "Claude Sonnet 4", provider: "anthropic" }, + { id: "gpt-4o", name: "GPT-4o", provider: "openai" }, + ], +}, +``` + +**Requirements:** + +- `semanticSearch.enabled: true` for content retrieval +- `OPENAI_API_KEY` in Convex for embeddings +- `ANTHROPIC_API_KEY` or `OPENAI_API_KEY` for the LLM + +**Features:** + +- Header button opens a chat modal +- Uses RAG (Retrieval Augmented Generation) to find relevant content +- Streaming responses with markdown rendering +- Multi-model selector +- Source citations linking to relevant posts/pages +- Conversation history within session + ### Newsletter management All Newsletter Admin features integrated into the Dashboard: diff --git a/fork-config.json.example b/fork-config.json.example index 48d58ac..ea1015f 100644 --- a/fork-config.json.example +++ b/fork-config.json.example @@ -186,6 +186,14 @@ "twitter": { "site": "@yourhandle", "creator": "@yourhandle" + }, + "askAI": { + "enabled": false, + "defaultModel": "claude-sonnet-4-20250514", + "models": [ + { "id": "claude-sonnet-4-20250514", "name": "Claude Sonnet 4", "provider": "anthropic" }, + { "id": "gpt-4o", "name": "GPT-4o", "provider": "openai" } + ] } } diff --git a/public/raw/changelog.md b/public/raw/changelog.md index f2970cd..c3fb723 100644 --- a/public/raw/changelog.md +++ b/public/raw/changelog.md @@ -7,6 +7,30 @@ Date: 2026-01-10 All notable changes to this project. +## v2.16.2 + +Released January 10, 2026 + +**Ask AI documentation alignment** + +Aligned Ask AI configuration across all config and documentation files. The Ask AI feature (header chat with RAG) is now properly documented alongside AI Agent and AI Dashboard features. + +**Changes:** + +- Added `askAI` config to `fork-config.json.example` +- Added Ask AI Configuration section to `FORK_CONFIG.md` +- Added Ask AI (header chat) section to `docs-dashboard.md` +- Added Ask AI (header chat) section to `how-to-use-the-markdown-sync-dashboard.md` + +**Files changed:** + +- `fork-config.json.example` - Added askAI config block +- `FORK_CONFIG.md` - Added Ask AI Configuration section +- `content/pages/docs-dashboard.md` - Added Ask AI documentation +- `content/blog/how-to-use-the-markdown-sync-dashboard.md` - Added Ask AI setup guide + +--- + ## v2.16.1 Released January 10, 2026 diff --git a/public/raw/docs-configuration.md b/public/raw/docs-configuration.md index b4f5b1e..55d72cb 100644 --- a/public/raw/docs-configuration.md +++ b/public/raw/docs-configuration.md @@ -433,4 +433,40 @@ The `npm run sync` command only syncs markdown text content. Images are deployed **Logo options:** - **Homepage logo:** Configured via `logo` in `siteConfig.ts`. Set to `null` to hide. -- **Inner page logo:** Configured via `innerPageLogo` in `siteConfig.ts`. Shows on blog page, posts, and static pages. Desktop: top left corner. Mobile: top right corner (smaller). Set `enabled: false` to hide on inner pages while keeping homepage logo. \ No newline at end of file +- **Inner page logo:** Configured via `innerPageLogo` in `siteConfig.ts`. Shows on blog page, posts, and static pages. Desktop: top left corner. Mobile: top right corner (smaller). Set `enabled: false` to hide on inner pages while keeping homepage logo. + +### AI features + +Configure AI-powered features in `src/config/siteConfig.ts`: + +**Semantic Search:** + +```typescript +semanticSearch: { + enabled: true, // Requires OPENAI_API_KEY in Convex +}, +``` + +When enabled, users can toggle between keyword and semantic search in the search modal (Cmd+K). Semantic search finds content by meaning using OpenAI embeddings. + +**Ask AI (header chat):** + +```typescript +askAI: { + enabled: true, + defaultModel: "claude-sonnet-4-20250514", + models: [ + { id: "claude-sonnet-4-20250514", name: "Claude Sonnet 4", provider: "anthropic" }, + { id: "gpt-4o", name: "GPT-4o", provider: "openai" }, + ], +}, +``` + +Adds a chat button to the header for RAG-based Q&A about your content. Requirements: +- `semanticSearch.enabled: true` +- `OPENAI_API_KEY` in Convex (for embeddings) +- `ANTHROPIC_API_KEY` or `OPENAI_API_KEY` (for the LLM) + +**AI Dashboard:** + +The Dashboard includes a multi-model AI Agent with chat and image generation. See [Dashboard](/docs-dashboard) for configuration details. \ No newline at end of file diff --git a/public/raw/docs-dashboard.md b/public/raw/docs-dashboard.md index e40da1a..4802cd6 100644 --- a/public/raw/docs-dashboard.md +++ b/public/raw/docs-dashboard.md @@ -157,6 +157,40 @@ The Dashboard includes a dedicated AI Agent section with tab-based UI for Chat a **Note:** Only configure the API keys for models you want to use. If a key is not set, users see a helpful setup message when they try to use that model. +### Ask AI (header chat) + +The Ask AI feature adds a chat button to the site header. Visitors can ask questions about your content and get AI-powered answers with source citations. + +**Configuration:** + +In `src/config/siteConfig.ts`: + +```typescript +askAI: { + enabled: true, // Enable Ask AI header button + defaultModel: "claude-sonnet-4-20250514", + models: [ + { id: "claude-sonnet-4-20250514", name: "Claude Sonnet 4", provider: "anthropic" }, + { id: "gpt-4o", name: "GPT-4o", provider: "openai" }, + ], +}, +``` + +**Requirements:** + +- `semanticSearch.enabled: true` for content retrieval +- `OPENAI_API_KEY` in Convex for embeddings +- `ANTHROPIC_API_KEY` or `OPENAI_API_KEY` for the LLM + +**Features:** + +- Header button opens a chat modal +- Uses RAG (Retrieval Augmented Generation) to find relevant content +- Streaming responses with markdown rendering +- Multi-model selector +- Source citations linking to relevant posts/pages +- Conversation history within session + ### Newsletter management All Newsletter Admin features integrated into the Dashboard: diff --git a/public/raw/fork-configuration-guide.md b/public/raw/fork-configuration-guide.md index a33938b..a017b0a 100644 --- a/public/raw/fork-configuration-guide.md +++ b/public/raw/fork-configuration-guide.md @@ -266,6 +266,17 @@ The JSON config file supports additional options: }, "imageLightbox": { "enabled": true + }, + "semanticSearch": { + "enabled": false + }, + "askAI": { + "enabled": false, + "defaultModel": "claude-sonnet-4-20250514", + "models": [ + { "id": "claude-sonnet-4-20250514", "name": "Claude Sonnet 4", "provider": "anthropic" }, + { "id": "gpt-4o", "name": "GPT-4o", "provider": "openai" } + ] } } ``` @@ -296,6 +307,10 @@ These are optional. If you omit them, the script uses sensible defaults. See `fo **Image Lightbox**: Click-to-magnify functionality for images in blog posts and pages. Images open in full-screen overlay when clicked. +**Semantic Search**: AI-powered search using OpenAI embeddings. Requires `OPENAI_API_KEY` in Convex. When disabled, only keyword search is available. + +**Ask AI**: Header chat button for RAG-based Q&A about your site content. Requires `semanticSearch.enabled: true` and `OPENAI_API_KEY` for embeddings, plus `ANTHROPIC_API_KEY` or `OPENAI_API_KEY` for the LLM. + For detailed configuration instructions, see `FORK_CONFIG.md`. ## After configuring diff --git a/public/raw/how-to-use-the-markdown-sync-dashboard.md b/public/raw/how-to-use-the-markdown-sync-dashboard.md index 2daec7a..207ac44 100644 --- a/public/raw/how-to-use-the-markdown-sync-dashboard.md +++ b/public/raw/how-to-use-the-markdown-sync-dashboard.md @@ -88,6 +88,39 @@ The dashboard includes a dedicated AI chat section separate from the Write page. The AI Agent uses Anthropic Claude API and requires `ANTHROPIC_API_KEY` in your Convex environment variables. Chat history is stored per-session in Convex. +## Ask AI (header chat) + +The Ask AI feature adds a chat button to your site header that lets visitors ask questions about your content. It uses RAG (Retrieval Augmented Generation) to find relevant content and provide AI-powered answers. + +**To enable Ask AI:** + +1. Enable semantic search in `siteConfig.ts`: + +```typescript +semanticSearch: { + enabled: true, +}, +``` + +2. Configure Ask AI: + +```typescript +askAI: { + enabled: true, + defaultModel: "claude-sonnet-4-20250514", + models: [ + { id: "claude-sonnet-4-20250514", name: "Claude Sonnet 4", provider: "anthropic" }, + { id: "gpt-4o", name: "GPT-4o", provider: "openai" }, + ], +}, +``` + +3. Set required environment variables in Convex: + - `OPENAI_API_KEY` for embeddings + - `ANTHROPIC_API_KEY` or `OPENAI_API_KEY` for the LLM + +When enabled, a chat button appears in the header. Clicking it opens a modal where visitors can ask questions. The AI retrieves relevant content from your posts and pages, then generates answers with source citations. + ## Newsletter management ![Newsletter management](/images/dashboard5.png) diff --git a/src/config/siteConfig.ts b/src/config/siteConfig.ts index 252a0bb..0760199 100644 --- a/src/config/siteConfig.ts +++ b/src/config/siteConfig.ts @@ -250,7 +250,7 @@ export interface TwitterConfig { creator?: string; // @username for default content creator } -// Ask AI configuration (Kapa-style header chat) +// Ask AI configuration (header chat for RAG-based Q&A) // Enables a header button that opens a chat modal for asking questions about site content // Uses RAG (Retrieval Augmented Generation) with streaming responses export interface AskAIConfig { @@ -792,7 +792,7 @@ export const siteConfig: SiteConfig = { enabled: true, // Set to true to enable semantic search (requires OPENAI_API_KEY) }, - // Ask AI configuration (Kapa-style header chat) + // Ask AI configuration (header chat for RAG-based Q&A) // Requires semanticSearch.enabled: true for content retrieval // Requires OPENAI_API_KEY (for embeddings) and ANTHROPIC_API_KEY or OPENAI_API_KEY (for LLM) askAI: { diff --git a/src/styles/global.css b/src/styles/global.css index fec00e8..f89e6c8 100644 --- a/src/styles/global.css +++ b/src/styles/global.css @@ -13602,7 +13602,7 @@ body:has(.docs-layout) { /* =========================================== Ask AI Modal Styles - Kapa-style header chat for RAG-based Q&A + Header chat for RAG-based Q&A =========================================== */ /* Ask AI Button in header */