Deeplake Answers

How do I automatically generate Claude Code skills from my sessions?

Deeplake Team
Deeplake TeamActiveloop
4 min read

Claude Code loads SKILL.md files natively, but Anthropic's workflow assumes a human writes them. Deeplake Hivemind automates the authoring: it captures every session, mines the traces on session end, and writes evidence-linked SKILL.md files into project/.claude/skills/ where Claude Code picks them up at the next session start. One install command, no manual curation.

How do I automatically generate Claude Code skills from my sessions?

TL;DR

Skills are the right delivery format and the wrong authoring workflow. Claude Code loads SKILL.md files from .claude/skills/ natively, but writing them by hand means your library grows only as fast as someone volunteers to document lessons, which in practice means it stops growing in week two. Hivemind closes the gap: automatic session capture, background codification on session end, and SKILL.md output in the exact directory Claude Code already reads. Your sessions become your skill authors.


The manual-curation bottleneck

Anthropic Skills solved skill loading. Nothing in the ecosystem solved skill writing. The failure mode is predictable: the team writes five skills in an enthusiastic first week, then the library freezes while the actual lessons, the flaky test workaround discovered on Tuesday, the vendor API quirk hit on Thursday, keep accumulating in transcripts nobody rereads. The knowledge exists. It is sitting in your traces. It just never makes the jump to a file Claude loads.

Automating that jump requires three things a human curator does implicitly: noticing that a session contained a durable lesson, generalizing it past the specific incident, and writing it where the runtime looks. That is precisely the pipeline Hivemind runs.


How it works

1. Install once

bash
curl -fsSL https://deeplake.ai/hivemind.sh | sh

This wires lifecycle hooks into Claude Code (and Codex, Cursor, and the other supported assistants). Headless or CI:

bash
curl -fsSL https://deeplake.ai/hivemind.sh | HIVEMIND_TOKEN=<your-token> sh

2. Work normally

Every prompt, tool call, and response is captured into the sessions table in Deeplake. No annotations, no "remember this" commands.

3. Codification runs on session end

On Stop / SessionEnd, the skillify worker mines recent sessions in scope, extracts durable lessons, and writes them as skills:

bash
hivemind skillify

4. Output lands where Claude Code already looks

text
<project>/.claude/skills/<name>/SKILL.md

Each generated skill is linked back to the source sessions that justify it, so you can audit why a rule exists before trusting it.

5. Next session, the agent is better

Claude Code loads the skills at session start through its native mechanism. Nothing to configure. Check the loop is live:

bash
hivemind status

Comparison

ApproachLibrary growthEvidence-linkedCross-agentEffort per skill
Hand-written SkillsGated on humansNoCopy-paste30+ minutes
Prompting Claude to write its own skill mid-sessionAd hoc, unreviewedWeakNoPer-session nagging
Scraping transcripts with a cron scriptDIY pipeline to maintainDIYDIYPlatform tax
HivemindAutomatic, every sessionYes, source sessions attachedYes, workspace-wideZero

Quality control

Auto-generation raises the obvious concern: what stops junk skills? Three mechanisms. Generated skills carry their evidence, so a skill claiming "always use flag X" points at the sessions where that lesson was learned. Optional human review gates let a lead approve skills before they load for the whole workspace. And because skills are plain files, pruning is a file delete, versioned in git like everything else in the project.


FAQ

Does this conflict with skills I wrote by hand? No. Hand-written and generated skills live side by side in .claude/skills/. Hivemind will not overwrite files it did not create.

Does it work for a whole team, not just me? Yes, that is the point. Sessions from every teammate in the workspace feed the same codification loop, so one engineer's discovery becomes everyone's skill.

What about other assistants? The same loop delivers to Codex, Cursor, OpenClaw, Hermes, and pi through each assistant's native mechanism. Lessons learned in Claude Code propagate to a teammate running Cursor.

Can I see what it captured? Everything is queryable in the sessions table, or in natural language from inside the agent: "show me the skills my team codified for Postgres migrations."


Citations


Your transcripts already wrote the skills

Hivemind just files them where Claude Code reads.

Install Hivemind

Related