Skip to content
All projects
DistiLL: Mine Your Claude Code History for Reusable Skills
Developer Toolscompleted

DistiLL: Mine Your Claude Code History for Reusable Skills

Jul 2026solo build
local by defaultTranscripts never leave your machine. Only cluster representatives (at most 15 short messages per cluster) plus aggregate stats are ever sent to the API, and only in a full run — --dry-run and --local-only never make a network call.

Overview

If you use Claude Code every day, you repeat yourself: the same background re-explained across sessions, the same multi-step procedure requested again and again, the same failures happening the same way. DistiLL mines that history and turns the repetition into reusable artifacts — repeated context becomes a draft SKILL.md, a repeated workflow becomes a draft slash command, and a repeated failure becomes a findings note. Everything lands in ./output/ for review; DistiLL never installs anything.

Tech Stack

pipeline
Transcript ingestEmbeddingsClustering
synthesis
Anthropic API (cluster classification)
tooling
Python 3.11+TOML configcached embeddings
tests
pytest (fully offline, mocked client)

Challenges

  • Finding genuine repetition across hundreds of conversations without drowning in noise like greetings and pasted logs.
  • Doing pattern discovery without shipping private transcripts to an API.
  • Keeping re-runs cheap as history grows.
  • Turning a fuzzy cluster of similar messages into a clean, usable draft artifact.

Solution

Messages are filtered by length (dropping "yes"-sized noise and pasted files), embedded, and clustered; each cluster is classified — repeated context, workflow, or failure — and the largest clusters are drafted first, up to a configurable per-run cap. Privacy is structural: --dry-run and --local-only never make a network call, and a full run sends only a handful of short cluster representatives plus aggregate stats. Re-runs are incremental — embeddings are cached per text hash, so only new messages get embedded — and the report shows every cluster, its classification, confidence, and a cost estimate before anything is drafted.

Outcome

distill scan ingests transcripts and prints stats; distill run --dry-run embeds, clusters and writes output/report.md with zero API calls; distill run drafts the artifacts. Output is human-in-the-loop by design — SKILL.md and command drafts land in ./output/ and you move the ones you approve into ~/.claude/skills/ yourself. Tests run fully offline with an injectable embedding model and a mocked Anthropic client.

What I'd do differently

The discipline was making privacy a property of the architecture rather than a promise: local-only and dry-run paths that literally cannot reach the network. The MVP deliberately mines only human-typed messages; mining assistant messages and tool_use sequences for workflow patterns is noted as v2, not smuggled in.

Built with

Python 3.11+Sentence EmbeddingsClusteringAnthropic APIpytest