Skip to content

docs: BYOK messaging across marketing site and docs (BYOK 4/4)#409

Open
edspencer wants to merge 2 commits into
byok/3-per-user-modelsfrom
byok/4-marketing-docs
Open

docs: BYOK messaging across marketing site and docs (BYOK 4/4)#409
edspencer wants to merge 2 commits into
byok/3-per-user-modelsfrom
byok/4-marketing-docs

Conversation

@edspencer

Copy link
Copy Markdown
Owner

Part 4 of 4 of the BYOK stack (#405). Base: byok/3-per-user-models (#408) — merge #406, #407, #408 first. Copy only; no behavior changes.

Marketing site

  • How it works / Get started: the LLM-configuration step now covers both paths — web Settings → AI Provider and CLI bragdoc llm set; the get-started flow gains an "Add Your AI API Key" step (HowTo JSON-LD updated to match).
  • FAQ: new "Where do I put my API key?" entry (feeds the schema.org FAQ markup automatically).
  • Privacy surfaces: privacy cards/diagrams and the privacy policy now state keys are AES-256-GCM encrypted at rest and used server-side only to call the provider you chose; OpenAI listed separately as the platform-key consumer for embeddings + demo.
  • Self-hosting page: BYOK_ENCRYPTION_KEY required; OPENAI_API_KEY demoted to optional (demo + embeddings only).
  • Copy sweep for "our AI does X" phrasing → "your own AI provider". Blog posts deliberately untouched (dated historical content; none egregiously wrong).

Docs

  • .claude/docs/tech/ai-integration.md: new BYOK Architecture section (resolution flow, 409 contract, crypto, verify-on-save, embeddings v1 decision, @bragdoc/ai); stale getLLM/llm-router content removed.
  • database.md: user_llm_config table + llm_provider enum documented from the actual schema.
  • deployment.md, architecture.md, SELF_HOSTING.md, README.md, CLAUDE.md: BYOK_ENCRYPTION_KEY in env listings; OPENAI_API_KEY annotated demo/embeddings-only; README onboarding + AI-integration sections rewritten; stale /api/cli/commits data-flow corrected.

Verification

  • Marketing build passes; full pnpm build 6/6 green.

🤖 Generated with Claude Code

Update the marketing site for the bring-your-own-key model: the
how-it-works and get-started flows now cover both key paths (web
Settings -> AI Provider for chat/document generation, and bragdoc llm
set for CLI extraction), the FAQ gains a "Where do I put my API key?"
entry, the CLI docs note that its key config only affects local
extraction, and privacy pages/diagrams state that stored keys are
AES-256-GCM encrypted at rest and only ever used server-side to call
the provider the user chose. Stale copy implying BragDoc supplies the
AI (privacy policy AI services list, "Our AI analyzes...", self-hosting
env instructions) is corrected.

Technical docs get a full BYOK architecture section in
ai-integration.md (resolveModelForUser flow, NoLLMConfigError -> 409
no_llm_configured, the shared @bragdoc/ai package, verify-on-save,
HKDF/AES-256-GCM crypto via BYOK_ENCRYPTION_KEY, and the
embeddings-stay-on-platform-key v1 decision), and database.md documents
the user_llm_config table and llm_provider enum. Remaining references
to the removed model singletons (routerModel, documentWritingModel,
getLLM) in api-conventions.md, FEATURES.md, and reports.md are updated.

BYOK_ENCRYPTION_KEY is now listed alongside the other secrets in
deployment.md, architecture.md, SELF_HOSTING.md, README.md, and
CLAUDE.md, with OPENAI_API_KEY clarified as demo-mode/embeddings only.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@vercel

vercel Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
bragdoc-ai Ready Ready Preview, Comment Jul 7, 2026 4:14am

Request Review

@github-actions

github-actions Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Braintrust eval report

No experiments to report

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant