Problem
The learning journal currently lives at .claude/learning-journal.md inside each project. This has caused real data loss and excludes non-Claude agents:
- It gets destroyed.
.claude/ is commonly untracked or gitignored. A git clean, a session rewind, or a branch switch can wipe the journal with no recovery. This has already happened to at least one user (an opencode session rewind nuked an untracked .claude/ journal).
- It's Claude-specific. Hardcoding
.claude/ quietly excludes the opencode / Cursor / other-agent users that the multi-agent npx skills installer otherwise reaches.
- It's siloed per-repo. Personal learning progress is scattered across N project directories, with no way to ever see it in aggregate (blocks any future dashboard / cross-repo review queue).
Proposed direction
Move the default journal to a global per-user store, keyed by repo identity, at an XDG path:
~/.local/share/learn-codebase/<repo-key>/journal.md
<repo-key> derives from the git remote URL when present (stable across machines/clones), falling back to the repository toplevel path for repos with no remote.
- Honors
$XDG_DATA_HOME when set; falls back to ~/.local/share (and the platform equivalent on macOS/Windows).
This mirrors how spaced-repetition tools (e.g. Anki) store personal learning state — centrally, not scattered per-project.
Why this location
- Durable — survives
git clean, session rewinds, branch switches, and .gitignore. The data loss can't recur.
- Agent-neutral — drops the
.claude/ coupling so opencode/Cursor/etc. users get a real home. Lets us market true multi-agent support.
- Aggregatable — one store across all repos is the natural substrate for a future
status / dashboard command and a cross-repo spaced-review queue (see follow-up issues).
Opt-in: keep it in the repo
For people who want the journal to travel with a fork or be shared, support an --in-repo (or config) mode that writes to a tracked, neutral path in the project. Global store remains the default.
Open questions
Scope of change
SKILL.md — the existence-check / creation logic (currently checks and writes .claude/learning-journal.md).
README.md — update the journal-location description and the data-durability story.
.gitignore — the learning-journal.md ignore entry becomes mostly moot for the default path.
Feedback welcome on the repo-key scheme and migration UX before implementation.
Problem
The learning journal currently lives at
.claude/learning-journal.mdinside each project. This has caused real data loss and excludes non-Claude agents:.claude/is commonly untracked or gitignored. Agit clean, a session rewind, or a branch switch can wipe the journal with no recovery. This has already happened to at least one user (an opencode session rewind nuked an untracked.claude/journal)..claude/quietly excludes the opencode / Cursor / other-agent users that the multi-agentnpx skillsinstaller otherwise reaches.Proposed direction
Move the default journal to a global per-user store, keyed by repo identity, at an XDG path:
<repo-key>derives from the git remote URL when present (stable across machines/clones), falling back to the repository toplevel path for repos with no remote.$XDG_DATA_HOMEwhen set; falls back to~/.local/share(and the platform equivalent on macOS/Windows).This mirrors how spaced-repetition tools (e.g. Anki) store personal learning state — centrally, not scattered per-project.
Why this location
git clean, session rewinds, branch switches, and.gitignore. The data loss can't recur..claude/coupling so opencode/Cursor/etc. users get a real home. Lets us market true multi-agent support.status/ dashboard command and a cross-repo spaced-review queue (see follow-up issues).Opt-in: keep it in the repo
For people who want the journal to travel with a fork or be shared, support an
--in-repo(or config) mode that writes to a tracked, neutral path in the project. Global store remains the default.Open questions
.git, ssh-vs-https, casing)? What about monorepos or multiple worktrees of the same remote?.claude/learning-journal.mdon first run and offer to move/copy it to the global store, so current users don't lose history.Scope of change
SKILL.md— the existence-check / creation logic (currently checks and writes.claude/learning-journal.md).README.md— update the journal-location description and the data-durability story..gitignore— thelearning-journal.mdignore entry becomes mostly moot for the default path.Feedback welcome on the repo-key scheme and migration UX before implementation.