agentleFS
Guz007Guz007/claude-code-os-plugin/skills/memory-bootstrap/SKILL.md

memory-bootstrap

Skill0 starsChanged 4 months agoMITView on GitHub

Seed a project's memory/ directory from scratch using a scan-propose-approve-write pipeline. Use when starting work on a new or unfamiliar repo, when memory/ is empty, or when the user asks to initialize agent memory.

1 other project uses a version of this.

Adopted by

Most recently taken up by

  • Other versions1 project uses a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 1

    1. NITISH-R-G/agent-memory-protocol★ 1same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repository5 other files it gives its agents.

The file

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 4 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If memory/MEMORY.md already exists, stop and use memory-hygiene instead — bootstrap overwrites.

    line 12
  2. Distinctive:

    Do not write anything. Report findings only.

    line 22
  3. Distinctive:

    Read in this order:

    line 24
  4. Distinctive:

    Write nothing beyond what was approved.

    line 94
  5. Distinctive:

    If the scan returns nothing usable (truly empty repo), still create:

    line 98

≈ “Common” is an estimate: at least 1 in 5 of the 383,637 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Memory Bootstrap

Takes a project the agent has never worked on and produces a populated memory/ directory with the four canonical types: user, project, feedback, reference.

The failure mode this prevents: agents that only write memory reactively (after a correction) end up with sparse, incident-driven memory. Bootstrap front-loads the durable signal that already exists in the codebase, the docs, and recent commit messages.

If memory/MEMORY.md already exists, stop and use memory-hygiene instead — bootstrap overwrites.

Architecture

Phase 1: SCAN → Phase 2: PROPOSE → Phase 3: APPROVE → Phase 4: WRITE

Phase 1 — Scan

Do not write anything. Report findings only.

Read in this order:

  1. README.md, CONTRIBUTING.md, ARCHITECTURE.md (any top-level docs)
  2. package.json / pyproject.toml / Cargo.toml — declared scripts, deps, version
  3. CLAUDE.md / AGENTS.md / .cursorrules — existing agent instructions
  4. Last 20 commit messages — recurring keywords, contributors, themes
  5. Top-level directory structure, three levels deep, file counts per dir

Output four sections:

  • USER SIGNAL — what does the codebase imply about the user/team's expertise, role, and priorities?
  • PROJECT SIGNAL — what is being built, for whom, by when, with what constraints?
  • WORKFLOW SIGNAL — how do they build, test, deploy, review?
  • REFERENCE SIGNAL — what external systems, dashboards, or services are referenced?

Phase 2 — Propose

Propose memory entries typed as:

  • user — role, expertise, preferences, knowledge gaps
  • project — what's being built, why, deadlines, stakeholders
  • feedback — coding/review patterns observed (only if implied by docs/commits, never invented)
  • reference — external systems and where to look for information

Apply this filter:

  • Would this change how I respond to a future prompt in this project? (must be yes)
  • Is it inferrable from the code/git/docs alone? (if yes, don't save — re-derive at use time)
  • Is it durable for weeks, not days? (if no, don't save)

Output per candidate:

[TYPE] | [PROPOSED FILENAME] | [ONE-LINE DESCRIPTION] | [BODY 2-5 LINES]

Aim for 3–6 entries total. Sparse is correct.

Phase 3 — Approval Gate

The user reviews each candidate. Reject any that:

  • Restate code that can be re-read ("uses React + TypeScript" is not memory-worthy)
  • Are specific to a single in-flight task (belongs in a task list, not memory)
  • Speculate beyond what the scan actually showed

Phase 4 — Write

For each APPROVED candidate only:

  1. Create memory/<filename>.md:
---
name: <memory name>
description: <one-line description>
type: <user|project|feedback|reference>
---

<body — for feedback/project, structure as: rule/fact, then **Why:** and **How to apply:** lines>
  1. Append one line to memory/MEMORY.md under the matching ## section:
- [Title](filename.md) — short hook under 150 chars
  1. Output a confirmation table: FILE | TYPE | LINES | INDEX UPDATED?

Write nothing beyond what was approved.

Skeleton Fallback

If the scan returns nothing usable (truly empty repo), still create:

memory/
  MEMORY.md            # index, four ## sections, empty
  user_profile.md      # "No user profile captured yet"
  project_overview.md  # "Bootstrap incomplete — re-run after first work session"

A skeleton beats an empty directory because it tells future-you the system is initialized.

Design Decisions

DecisionRationale
Scan-then-proposeMost agents over-write at bootstrap; the split forces filter discipline
Cap at 3–6 entriesSparse memory has higher signal-to-noise; hygiene handles growth
Human gate before writeOne bad entry persists across every future session — cost asymmetry justifies friction

Known Gaps

  1. Multi-language repos — Phase 1 reads top-level only; polyglot repos hide signal in subdir docs.
  2. Private context — cannot read Slack, Linear, or internal wikis. Seed those manually as reference.
  3. No re-bootstrap guard beyond the MEMORY.md check — verify before running on an active project.

See Also

  • memory-hygiene — maintenance after bootstrap
  • claude-md-bootstrap — instruction file, same philosophy

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.