← All work
● Private beta / 2025–present / Founder & engineer

CiteAgent

Be the brand AI search engines recommend.

Visit live site
Next.js 16 React 19 Turborepo tRPC Drizzle Postgres / Neon Inngest Better Auth Vercel AI SDK Anthropic OpenAI Tailwind v4
Apps in monorepo
8
Domain packages
20+
Discovery algorithms
42
Beta waitlist
200+

The problem

When a customer asks ChatGPT, Gemini, or Perplexity “what’s the best tool for X?” — the model’s answer is now your top-of-funnel. If you’re not cited, you’re invisible.

Most teams discover this the hard way: traffic from AI assistants is growing fast, but their existing SEO stack tells them nothing about why AI engines recommend competitors. Hiring an “AEO consultant” runs ~$3,700/month. Most can’t even tell you their methodology.

What CiteAgent does

CiteAgent is the consultant in software form:

  • Monitors citations across 5 AI engines for your brand and competitors
  • Audits each page against AI-readability heuristics — schema, structure, content gaps
  • Discovers competitors the AI engines actually rank for, not the ones you think you compete with
  • Generates fixes — AI-written articles, schema patches, rewritten meta — gated behind your approval
  • Tracks lift on rankings so you can see what worked

Pricing is four tiers from free to $99/month. We’re in private beta with 200+ on the waitlist.

Architecture

CiteAgent is a serious monorepo — 8 apps, 20+ packages — because a real AEO platform isn’t a ChatGPT wrapper. Each piece has a real reason to exist.

flowchart LR
subgraph Apps
  Web["apps/web<br/>Next.js dashboard"]
  Marketing["apps/marketing"]
  Audit["apps/audit-api<br/>public scoring"]
  CLI["apps/cli"]
end
subgraph Domain
  API["packages/api<br/>tRPC routers"]
  Core["packages/core<br/>42 algorithms"]
  Jobs["packages/jobs<br/>Inngest functions"]
  AI["packages/ai-assistant<br/>tools + cache"]
  DB["packages/db<br/>Drizzle schema"]
end
Web --> API
Audit --> Core
CLI --> API
API --> Core
API --> DB
Jobs --> Core
Jobs --> AI
Core --> AI
AI --> Providers["Anthropic / OpenAI"]
DB --> PG[("Postgres / Neon")]

Apps

  • apps/web — Next.js 16 dashboard (App Router, RSC, generative UI for reports)
  • apps/admin — internal admin for support and ops
  • apps/audit-api — public scoring API for embeddable audits and lead-gen widgets
  • apps/cliciteagent CLI for engineers to apply fixes from their terminal
  • apps/cms — Payload-driven content for marketing
  • apps/marketing — separate Next app for the public site
  • apps/video — automated video-explainer pipeline for content marketing
  • apps/e2e — Playwright tests across the stack

Domain packages

  • packages/core — pure domain logic (analyzers, discovery, crawlers) — no I/O, fully testable
  • packages/agent-core — shared agent abstractions and the 42-algorithm scoring pipeline
  • packages/ai-assistant — generic AI SDK infra: tool registry, rate limiter, prompt cache
  • packages/jobs — Inngest functions for crawls, scoring, content gen, billing reconciliation
  • packages/db — Drizzle schema + migrations (Postgres on Neon)
  • packages/auth — Better Auth, multi-tenant org model
  • packages/api — tRPC routers, the only edge between web and core
  • packages/api-keys — credential storage with keychain / env / file backends

Why this shape

A few non-obvious choices that made the system actually shippable:

  • Pure core package, no I/O. Every algorithm is a function from input → output. Tested with Vitest, not mocked databases. This made the 42-algorithm pipeline tractable.
  • tRPC, not REST. End-to-end types from Drizzle through to the React component. When the schema changes, the build breaks in the right places.
  • Inngest over a homegrown queue. Crawls, scoring, and content gen all need retries, cancellation, and observability. Inngest gave me all three on day one.
  • Per-feature agent module. Each “fix-generator” (article, meta, schema) is a small agent with a tool registry. The shared ai-assistant package handles rate limiting, caching, and provider switching globally.

A small slice of the code

Prompt caching is the difference between a $19/mo plan and a $99/mo plan. Every audit shares the same rubric — cached once, reused across thousands of pages:

// packages/ai-assistant/src/audit.ts
import { Anthropic } from '@anthropic-ai/sdk';

const client = new Anthropic();

export async function auditPage(page: PageContent) {
  return client.messages.create({
    model: 'claude-sonnet-4-5',
    system: [
      // The 4KB rubric — cached, reused across the batch
      { type: 'text', text: AUDIT_RUBRIC, cache_control: { type: 'ephemeral' } },
    ],
    messages: [{ role: 'user', content: page.html }],
    max_tokens: 1024,
  });
}

What I learned

  • Prompt cost dominates everything. A naïve audit pipeline cost ~$0.40/page; with prompt caching, model routing, and per-step truncation, it’s ~$0.04. That delta is the difference between a $19/mo plan and a $99/mo plan.
  • Determinism > cleverness in agents. The 42 algorithms are mostly deterministic scoring functions. The LLM only writes text and decides between three or four pre-built strategies. That’s why the system is reliable enough to charge for.
  • The hard part is not the AI. Auth, billing, multi-tenant data isolation, observability, and “what happens when the crawler blocks us” are 80% of the work. The AI part is the demo.

What’s next

Public launch this quarter, an enterprise tier with white-labeling for agencies, and an open-source citeagent CLI that runs the audit pipeline locally.

Want this for your business?

Let's discuss your AI build.

I do strategy calls, architecture audits, and full pilot builds. Same depth you just read about — for your product.