plugins/compound-engineering/skills/session-history/SKILL.md
Recover prior attempts safely by searching repo artifacts first and only then using a bounded recent-session fallback when the harness exposes searchable history
npx skillsauth add the-rabak/compound-engineering-plugin session-historyInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Use this skill when you need to answer "what did we already try?" without blindly dumping prior transcripts into the current context.
This skill exists to prevent repeated dead ends, especially when:
Search repo-owned artifacts first. Only if those artifacts do not answer the question clearly enough should you fall back to a bounded recent-session search.
The goal is recovery of useful decisions and evidence, not transcript archaeology for its own sake.
Search the smallest set of repo artifacts that could answer the question:
docs/solutions/docs/execution-sessions/docs/plans/ (.md or .html)docs/architecture/ (.md or .html)docs/tickets/docs/brainstorms/ (.md or .html)README, CHANGELOG, constitution, or workflow-reference docs when they explain intent or constraintsPrefer artifacts that already encode structured learning, decisions, or execution evidence.
Dual-read by artifact extension. A matched plan, brainstorm, or architecture artifact may be legacy .md or the .html-artifact output (plan since the html-artifacts pilot, brainstorm since T03, architecture since T04). Never scrape a rendered .html artifact for its content. Detect the reader from the artifact's own extension: .md -- parse frontmatter and sections as today (legacy path, unchanged). .html -- load commands/workflows/references/html-artifacts/island-extraction-helper.md, quote its first non-empty line, and read the artifact's #artifact-data JSON island for that kind's fixed-core facts instead. If extraction fails for any reason, stop immediately and report the artifact path and the exact failure per the helper's fail-loud branch -- do not proceed on partial data, scrape the rendered HTML, or fall back to a .md mirror. Solutions, execution sessions, and tickets stay .md-only.
Only search prior interactive sessions when:
Use a bounded window. Default to the last 8 relevant sessions unless the user asks for a different range.
If the harness exposes searchable session history, use that tool. For example:
session_storeIf the harness does not expose searchable session history, say so plainly and continue from repo artifacts only.
Before searching, state what you are trying to recover:
Search for the task topic plus close variants:
brainstorm_ref, architecture_ref, tickets_ref, plan_ref)Prefer exact matches first, then broaden.
Use recent-session lookup only if Tier 1 leaves a material gap.
Good reasons to fall back:
Bad reasons to fall back:
Never dump raw transcripts into the main thread unless the user explicitly asks for that.
Extract only the minimum useful structure:
When possible, summarize from structured snippets, checkpoint summaries, or short excerpts instead of full transcripts.
Return a concise, decision-ready summary:
## Prior Context
- **Best artifact matches:** [paths]
- **What was already tried:** [1-3 bullets]
- **What failed:** [1-3 bullets]
- **What worked or partially worked:** [1-3 bullets]
- **Relevant files / modules:** [paths]
- **Remaining uncertainty:** [what still is not known]
If session fallback was used, add:
- **Recent session window used:** [count and scope]
development
Mutates a single field or content region of an existing self-contained HTML artifact in place (island-first, no-added-facts, injection-safe) without regenerating the document from scratch. Invoked by a workflow command whenever it needs to back-write into an artifact it already composed -- e.g. a ref/status update, or a content rewrite that must re-project the affected view -- never by the user directly.
development
Composes a self-contained, interactive HTML artifact (island-first, single file, token-layer themed, injection-safe) from a workflow command's structured plan payload. Invoked by a workflow command at its artifact-write step -- currently `/workflows:plan` -- never by the user directly.
development
Mutates a single field or content region of an existing self-contained HTML artifact in place (island-first, no-added-facts, injection-safe) without regenerating the document from scratch. Invoked by a workflow command whenever it needs to back-write into an artifact it already composed -- e.g. a ref/status update, or a content rewrite that must re-project the affected view -- never by the user directly.
development
Composes a self-contained, interactive HTML artifact (island-first, single file, token-layer themed, injection-safe) from a workflow command's structured plan payload. Invoked by a workflow command at its artifact-write step -- currently `/workflows:plan` -- never by the user directly.