Understand how your engineers use AI — and how to make them better at it.
Get Started · Docs · Roadmap · Contributing
Your team adopted AI coding tools. Now what?
Primer is an open-source intelligence platform for agentic engineering. It captures session data from Claude Code, Codex CLI, Gemini CLI, and Cursor, then turns that telemetry into coaching, project enablement, quality attribution, and operational decisions. Self-hosted. Privacy-first. Your data never leaves your network.
- Is our AI investment paying off? — Cost per successful outcome, ROI ratio, time saved vs. dollars spent
- Which teams have figured it out and which are struggling? — Team-level adoption, success rates, and leverage scores with cross-team comparison
- What systemic issues tank AI effectiveness across the org? — Friction impact scoring: not just "errors happen" but "this error type costs us 40% lower success rates"
- Are we spending efficiently? — Per-engineer plan modeling (API vs. Pro vs. Max), cache hit optimization, budget burn-rate tracking
- Who needs help and what specific help? — Personalized tips, skill gaps, tool diversity analysis, and peer benchmarking
- How fast are new hires ramping up? — Cohort analysis comparing onboarding curves against team baselines
- Are AI-assisted PRs actually better? — Side-by-side comparison: merge time, review comments, merge rate for Claude vs. non-Claude PRs
- Where should I invest in training? — Tool proficiency scoring (novice → expert) per engineer, per tool category
- How am I trending? — Weekly trajectory with success rate, cost, and session patterns
- What keeps tripping me up? — Personal friction breakdown: permission blocks, context limits, tool errors
- Am I using the right tools? — Config optimization suggestions based on team benchmarks and entropy-based diversity scoring
- What should I try next? — Learning paths generated from high-performer patterns in your org
Friction analysis, not just usage tracking. Primer doesn't just count sessions — it classifies why sessions fail. LLM-powered facet extraction identifies goals, satisfaction, and friction types from every transcript, then scores their impact on outcomes. You learn that permission_denied errors cause 40% lower success rates, not just that they happen sometimes.
Individual intelligence, not just org dashboards. Every engineer gets a trajectory view, strengths profile, friction breakdown, and AI-generated narrative about their patterns. The MCP sidecar brings stats, friction reports, recommendations, and coaching into the session without forcing context switching.
Cost optimization, not just cost tracking. Primer models whether each engineer should be on API billing, Pro ($20/mo), or Max ($100/mo) based on actual usage. It measures cache hit rates per engineer and surfaces how much money is being left on the table. Budget burn-rate alerts catch overruns before they happen.
AI maturity scoring. A composite leverage score (0-100) per engineer based on tool category diversity, orchestration adoption, and cache efficiency. Track your org's maturity curve over time. Detect which projects have CLAUDE.md, AGENTS.md, and proper AI configuration — and which don't.
| Area | What You Get |
|---|---|
| Organization Overview | Session volume, success rates, health scores, activity heatmaps, outcome distribution, anomaly alerts |
| FinOps & Cost Management | Per-model spend, cache savings analysis, API vs. subscription modeling, 30-day linear regression forecasting, budget burn-rate tracking |
| Engineer Profiles | Weekly trajectory sparklines, strengths/friction breakdown, peer benchmarking, AI-generated narrative insights |
| AI Maturity | Leverage scores (tool mastery, orchestration depth, efficiency), Effectiveness scores (success rate, cost efficiency), model diversity, agent team detection, project AI-readiness |
| Friction Intelligence | Categorized friction types with impact scoring, bottleneck detection, root cause patterns, cluster analysis |
| Quality & Code Impact | PR merge rates, workflow-based quality attribution, Claude-assisted vs. non-Claude comparison, code volume per session, review comment analysis |
| AI Synthesis | LLM-generated narrative reports at org, team, and engineer scope — turns metrics into stories |
| Conversational Explorer | Natural language queries over your data via SSE-streamed tool-use chat |
| Session Browser | Full-text search, outcome/model/type filters, transcript viewer, message-level detail |
| MCP Sidecar | Engineers query their own stats mid-session: trends, friction reports, recommendations, coaching |
| Multi-Agent Support | Claude Code, Codex CLI, Gemini CLI, and Cursor sessions in one platform |
| GitHub Integration | OAuth SSO, PR sync, commit correlation, repository AI-readiness scoring |
One-liner install:
curl -fsSL https://useprimer.dev/install.sh | shOr install manually:
pip install primer # Install
primer init # Initialize database and config
primer server start # Start API + dashboard
primer hook install # Register the SessionEnd hookDocker:
cp .env.docker.example .env && make upSee the Installation guide for full setup, GitHub integration, and production configuration.
AI agents + local capture ──POST──┐
GitHub App / webhooks ────────────┼──▶ Primer API ◀──MCP Sidecar
│ │
│ ▼
└── PostgreSQL / SQLite
│
▼
React Dashboard
- Capture Layer — Hooks, sync, and import flows discover sessions across Claude Code, Codex CLI, Gemini CLI, and Cursor. Derived evidence includes facets, execution evidence, change shape, recovery paths, and workflow profiles.
- REST API — FastAPI service with routers covering analytics, alerting, FinOps, quality, maturity, interventions, explorer, and admin workflows. Role-based access is enforced across the platform.
- Dashboard — React frontend with organization, project, growth, quality, and individual views. Date-range filtering, CSV/PDF export, and role-based navigation are built in.
- MCP Sidecar — Engineers query their own data during sessions for stats, friction, recommendations, and coaching.
| Guide | Description | |
|---|---|---|
| Getting Started | Installation | Install, configure, first insights |
| Configuration | Environment variables and options | |
| CLI Reference | All primer commands |
|
| Architecture | Server & API | System design, data model, auth, endpoints |
| Hook System | Multi-agent extractor registry | |
| MCP Sidecar | Mid-session stats, friction reports, recommendations | |
| Guides | GitHub Integration | OAuth login, GitHub App for PR sync |
| FinOps & Cost Management | Cache analytics, cost modeling, forecasting, budgets | |
| Alert Thresholds | Anomaly detection and Slack notifications | |
| Deployment | Docker Compose, Helm, PostgreSQL, scaling |
Named after the Young Lady's Illustrated Primer in Neal Stephenson's The Diamond Age — an adaptive, AI-driven book that observes its reader, understands context, and transforms complexity into personalized guidance. Primer brings that same principle to engineering organizations: observe how your team uses AI, understand the patterns, and guide each engineer toward mastery.
We welcome contributions. See CONTRIBUTING.md for guidelines.
- Open issues — bugs and feature requests
- Roadmap — what's planned and complete

