Skip to main content

Archive and browse agentic coding sessions

Project description

Agent Archive

Archive and browse agentic coding sessions. Parses session logs from multiple agents and generates a searchable MkDocs static site.

Agent Archive screenshot

Supported agents: Claude Code, Gemini CLI, Pi, OpenCode, GitHub Copilot

Requirements

  • Python 3.10+

Installation

Install as a standalone CLI with uv:

uv tool install agent-archive

Or with pip:

pip install agent-archive

For development (from a local clone):

uv sync

Usage

Sync

Parse agent logs and build the site:

agent-archive sync --output ~/archive

Agent log directories are auto-discovered at their default locations. Override any of them:

agent-archive sync --output ~/archive \
  --claude-path ~/.claude \
  --pi-path ~/.pi/agent \
  --opencode-db ~/.local/share/opencode/opencode.db \
  --gemini-path ~/.gemini/tmp \
  --copilot-path ~/.copilot

Only sessions that have changed since the last sync are re-parsed (incremental).

Secret redaction is on by default — API keys, tokens, and env var values are replaced with REDACTED in the rendered output. To disable:

agent-archive sync --output ~/archive --no-redact

Serve

Open the archive in a browser:

agent-archive serve --output ~/archive

This starts a local HTTP server (default port 8000) and opens a browser tab. A server is required because the site uses JavaScript for search.

agent-archive serve --output ~/archive --port 9000 --no-browser

Sharing across multiple machines

You can point all your machines at the same output directory synced via Dropbox, Syncthing, or similar. Each machine maintains its own .sync_state.<hostname>.json file in the output directory so they never interfere with each other.

On each machine, run sync independently:

agent-archive sync --output ~/Dropbox/archive

Sessions from all machines accumulate in the shared archive. Run serve on whichever machine you want to browse from:

agent-archive serve --output ~/Dropbox/archive

Development

Run tests:

uv run pytest

Project Structure

src/agent_archive/
  cli.py              # Typer CLI (sync, serve)
  models.py           # Pydantic models (Session, Message)
  redactor.py         # Secret redaction
  renderer.py         # Markdown + MkDocs site generation
  site_builder.py     # mkdocs.yml config and build
  state.py            # Incremental sync state (per-machine)
  parsers/
    base.py           # Abstract BaseParser
    claude_code.py
    gemini.py
    pi.py
    opencode.py
    copilot.py

Adding a Parser

Subclass BaseParser to support a new agent log format:

from pathlib import Path
from agent_archive.parsers.base import BaseParser
from agent_archive.models import Session

class MyAgentParser(BaseParser):
    def discover(self) -> list[Path]:
        # Return all log file paths for this agent
        ...

    def parse(self, filepath: Path) -> list[Session]:
        # Parse the log file and return Session objects
        ...

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

agent_archive-0.1.2.tar.gz (196.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

agent_archive-0.1.2-py3-none-any.whl (20.6 kB view details)

Uploaded Python 3

File details

Details for the file agent_archive-0.1.2.tar.gz.

File metadata

  • Download URL: agent_archive-0.1.2.tar.gz
  • Upload date:
  • Size: 196.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for agent_archive-0.1.2.tar.gz
Algorithm Hash digest
SHA256 0d57dd2507399d651a2947c55454b8c6da99fff23a3602f00eaf6ff54af56572
MD5 6081fde839eec60c212bdb680218841b
BLAKE2b-256 ec8f8594fffcea298b812cd13c8bc215d9bf19ef3531d79162195ad7581c7e73

See more details on using hashes here.

File details

Details for the file agent_archive-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: agent_archive-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 20.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for agent_archive-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 ce3e618d32cb75ec0dc369d355509d315a0e36176ea1c12542dbceb8eb66ae07
MD5 a6b96acdbcef8beff6af2b98de63b880
BLAKE2b-256 9877f78d04a6ad4f4be863c5375d4d718ce4f8199660b129d9c7a3a6ca9fbbd0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page