openspec-journal
Skill20 starsChanged 20 days agoApache-2.0View on GitHub
Owns the append-only interaction journal for an OpenSpec change — `openspec/changes/<change>/journal.jsonl` — and the fixed event vocabulary written to it (change.created, artifact.added/revised, mode.chosen, task.start/complete/blocked, verifier.result, decision, handoff, archive, skill.invoked, agent.spawned, context.compacted, turn.start/end). Invoked by name from the openspec-* skills whenever one of those events happens; not a user-facing entry point on its own. Use for "log this to the journal", "emit a journal event", "what fields does task.complete need", or "why did the journal helper reject my write".
In this repository73 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- rhdh-base-imagesSkill
- rhdh-konflux-rpaSkill
- rhdh-konflux-tasksSkill
- rhdh-plugin-catalog-index-status-and-update-flowSkill
- rhdh-pr-mrSkill
- rhdh-prow-jobsSkill
- rhdh-prow-release-branchSkill
- rhdh-prow-triggerSkill
- rhdh-yarn-bumpSkill
- rhdh-feature-docsSkill
- rhdh-jira-createSkill
- rhdh-jira-linkSkill
- rhdh-jira-refineSkill
- rhdh-jira-sprint-planSkill
- rhdh-jira-sprint-reportSkill
- rhdh-jira-updateSkill
- rhdh-prepare-refinementSkill
- agent-readinessSkill
- ask-rhdhSkill
- clean-proseSkill
- setup-rhdh-skillsSkill
- skill-authoringSkill
- rhdh-backportSkill
- rhdh-backstage-upgradeSkill
- rhdh-localSkill
- rhdh-operator-pr-testSkill
- rhdh-overlaySkill
- rhdh-playwrightSkill
- rhdh-plugin-authoringSkill
- rhdh-plugin-bug-fixSkill
- rhdh-plugin-exportSkill
- rhdh-plugin-midstream-propagateSkill
- rhdh-plugin-nfs-migrationSkill
- rhdh-plugin-wiringSkill
- rhdh-pr-createSkill
- rhdh-pr-reviewSkill
- rhdh-test-placementSkill
- backstage-api-changesSkill
- mutation-gateSkill
- prose-editingSkill
- rhdh-contextSkill
- rhdh-forgeSkill
- rhdh-jira-apiSkill
- rhdh-jira-authoringSkill
- rhdh-spec-driven-schemaSkill
- openspec-apply-changeSkill
- openspec-archive-changeSkill
- openspec-audit-changeSkill
- openspec-bulk-archive-changeSkill
- openspec-continue-changeSkill
- openspec-exploreSkill
- openspec-ff-changeSkill
- openspec-new-changeSkill
- openspec-onboardSkill
- openspec-sync-specsSkill
- openspec-verify-changeSkill
- rhdh-overlay-cve-exportSkill
- rhdh-platform-lifecycleSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 0 are distinctive, and 3 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 18
Write one line of structured, append-only history per load-bearing interaction inside an OpenSpec change, so a change's journal.jsonl …
- Very specific: line 25
Run the bundled helper that ships with this skill.
- Very specific: line 38
Run with no arguments for the full usage contract, and --schema for the authoritative event-name -> required-field table.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 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.
Files
OpenSpec journal
Write one line of structured, append-only history per load-bearing interaction
inside an OpenSpec change, so a change's journal.jsonl becomes a session log
that survives context compaction and long-running work — not a full
transcript, and not optional narration.
Route
Run the bundled helper that ships with this skill. Resolve
scripts/openspec-journal.py next to this skill's SKILL.md (the host skill
install path). Do not look for it under the product repo's scripts/ —
that path is never installed. Keep the product repo as the working directory
so the helper can find openspec/changes/:
python3 <skill-dir>/scripts/openspec-journal.py <change> <event> [k=v ...]
python3 <skill-dir>/scripts/openspec-journal.py <change> show [--limit N]
python3 <skill-dir>/scripts/openspec-journal.py <change> doctor
python3 <skill-dir>/scripts/openspec-journal.py --schemaRun with no arguments for the full usage contract, and --schema for the
authoritative event-name -> required-field table. Read those outputs instead
of memorizing the vocabulary — the script is the single source of truth for
it, so a caller who invents its own field name or event name gets a rejection,
not a silent write.
Turn bookending is the default discipline
Whenever the active working directory is inside an OpenSpec change, bookend every user turn with two writes, independent of whether any file changed:
- Before starting work, log
turn.start input="<paraphrase of the ask, <=200 chars>". - After finishing, log
turn.end output="<what changed, was decided, or was answered>".
Writing the input before doing the work is a commitment device against post-hoc rationalization. This applies to every prompt, including pure Q&A turns with no file changes.
Ordering and length
Events describe things that already happened — log change.created after
openspec new change <name> succeeds, not before. input/output are
rejected (exit 2) above 200 characters so the caller rewrites shorter rather
than truncating silently; move long content into design.md or an ADR and
point at it (output="See design.md §3 for full rationale.").
--input-file / --output-file paths must resolve under the change
directory. Change names . and archive are rejected. Reserved fields
ts, event, and phase cannot be forged via k=v.
Precompact hook
scripts/openspec-journal-precompact-hook.sh emits context.compacted for
the most recently active change when an agent host fires a pre-compaction
lifecycle hook (for example Claude Code's PreCompact). It is self-contained,
silent on any failure, and never blocks compaction. Wire it once per host;
skills never call it directly.
Completion
Complete when the event was accepted (exit 0) and, for show/doctor, the
requested output was returned. A rejected write (exit 1 usage error, exit 2
validation error) is not silently swallowed — surface the helper's exact error
to the caller so it can fix the event name, field, or length and retry.
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
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.

