Skip to content

tomjnsn/agentlogs

 
 

Repository files navigation

AgentLogs

AgentLogs

Coding agents, visible to your team.
Open-source and self-hostable. Track sessions, share prompts, and link every conversation to the commit it produced.

Website · Docs · Discord · Changelog


AgentLogs session detail view

AgentLogs captures and analyzes transcripts from AI coding agents (like Claude Code, Codex, OpenCode, and Pi) to give your team visibility into how AI tools are used in their codebases.

See it in action → Example transcript

Why AgentLogs?

AI coding agents are becoming core to how teams write software. But right now, every session is a black box stored on the machine of the user. You can't see the context put into each session and there is no knowledge sharing between teammates.

AgentLogs fixes that:

  • Team observability — Dashboard with activity metrics, agent & model usage, and per-member breakdowns
  • Git integration — Links sessions to the commits they produced. See which transcript wrote which code
  • Shared learning — Browse and share your team's sessions to discover effective prompts and workflows
Team Dashboard Git Integration Session Browser
Dashboard Git List

Supported Agents

Agent Transcripts Auto-sync Commit Tracking
Claude Code
Cline (experimental)
Codex (experimental)
OpenCode
Pi

Quick Start (using AgentLogs Cloud)

1. Log in

npx agentlogs login agentlogs.ai

2. Install the plugin for your agent

Claude Code — inside Claude Code:

/plugin marketplace add agentlogs/claude-code
/plugin install agentlogs

Cline:

npx agentlogs cline install

Codex:

codex mcp add agentlogs -- npx -y agentlogs mcp

OpenCode — add to opencode.json:

{ "plugin": ["@agentlogs/opencode"] }

Pi — run inside Pi or from the terminal:

pi install npm:@agentlogs/pi

3. Use your agent as usual

Transcripts are captured and uploaded automatically. View them at agentlogs.ai.

CLI

The CLI can also be used standalone for manual uploads:

# Interactive picker, browse transcripts from all agents
npx agentlogs upload

# Upload most recent transcript
npx agentlogs upload --latest

# Sync all Claude Code transcripts
npx agentlogs claudecode sync

# Check auth status
npx agentlogs status

See the full CLI reference.

Self-Hosting

AgentLogs is fully open-source and can be self-hosted.

Prerequisites

  • Bun v1.3.0+
  • GitHub OAuth App (create one)
    • Homepage: http://localhost:8787
    • Callback: http://localhost:8787/api/auth/callback/github

Setup

git clone https://github.com/agentlogs/agentlogs.git
cd agentlogs
bun install

# Configure environment
cp packages/web/.env.example packages/web/.env
# Edit .dev.vars with your GitHub OAuth credentials and a secret:
#   GITHUB_CLIENT_ID=...
#   GITHUB_CLIENT_SECRET=...
#   BETTER_AUTH_SECRET=...  (openssl rand -base64 32)
#   BETTER_AUTH_URL=http://localhost:8787
#   WEB_URL=http://localhost:8787

# Initialize database
bun db:migrate

# Start
bun dev

Open http://localhost:8787

Point the CLI at your instance:

npx agentlogs login localhost:8787

Deploy to Cloudflare

cd packages/web

# Create D1 database
wrangler d1 create agentlogs

# Run remote migrations
bun db:migrate:remote

# Set secrets
wrangler secret put GITHUB_CLIENT_ID
wrangler secret put GITHUB_CLIENT_SECRET
wrangler secret put BETTER_AUTH_SECRET

# Deploy
bun run deploy

Project Structure

packages/
├── cli/       — CLI tool (npx agentlogs)
├── web/       — Web app (TanStack Start + Cloudflare Workers + D1)
├── shared/    — Shared types, schemas, transcript parsing, secret redaction
├── pi/        — Pi extension (@agentlogs/pi)
├── opencode/  — OpenCode plugin (@agentlogs/opencode)
└── e2e/       — End-to-end tests
docs/          — Documentation (Mintlify)

Development

# Start the web app
bun dev

# Run CLI
bun agentlogs

# Type check, lint, format
bun run check

# Format code
bun run format

# Run e2e tests
bun run test:e2e

# Database commands
bun db:migrate       # Run migrations
bun db:generate      # Generate migrations from schema changes
bun db:studio        # Open Drizzle Studio
bun db:reset         # Reset local database

Tech Stack

Contributing

We welcome contributions! Please:

  1. Fork the repo and create a branch
  2. Make your changes
  3. Run bun run format and bun run check
  4. Open a PR

Acknowledgments

AgentLogs was inspired by and builds on ideas from:

License

MIT

About

Collaboration in the age of agentic engineering

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages

  • TypeScript 95.7%
  • JavaScript 2.5%
  • Other 1.8%