Skip to content

feat(scorecard): session log, memory handles, settings and the card renderer - #27

Merged
e1daru merged 6 commits into
pre-mainfrom
feat/scorecard-foundation
Sep 28, 2026
Merged

e1daru merged 6 commits into
pre-mainfrom
feat/scorecard-foundation

Conversation

@e1daru

@e1daru e1daru commented Sep 28, 2026

Copy link
Copy Markdown
Contributor

Summary

First of five PRs that add the session memory scorecard. Nothing calls this code yet, so behaviour does not change.

  • An append-only log per session, <dataDir>/scorecard/<session_id>.jsonl, that the hooks will write to.
  • Short handles such as [m7k2q] for memory entries, derived from the entry id, so the model can name an entry cheaply.
  • Two settings with their docs: sessionScore (off | compact | full) and outcomeReview (off | nudge | stop).
  • The fold that turns the log into a summary and the renderer that prints the card, with golden fixtures.

What to review

That the counts always add up: shown = used + not used + unknown, and used = worked + failed + waiting.

Merge order

Merge after #26. This PR targets pre-main directly, so until #26 merges its diff also shows the earlier PRs in the series.

Test plan

  • integrations/claude-code: npm run lint, npm test, npm run test:dist, node scripts/verify-manifests.mjs
  • integrations/codex: npm test, npm run test:dist
  • Rebuilding both plugins leaves the tree unchanged
  • node .github/scripts/leakcheck.mjs --strict, and the pre-push scan over every commit in this PR

🤖 Generated with Claude Code

e1daru and others added 6 commits September 28, 2026 20:57
A push publishes every commit it carries, and a blob stays fetchable by SHA after a later
commit deletes it, so the pre-push gate now scans each new commit, not only the tip. The tip
gets the whole-tree scan; earlier commits are scanned on the files they touched. Extensionless
dotfiles such as .gitignore are text too. The self-test plants both cases.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
One append-only log per host session (scorecard/<session_id>.jsonl) that every
hook appends to and the scorecard folds at render time, plus short hashed
handles ([mxxxx]) so injected memory lines can be credited by id.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
sessionScore (off|compact|full) controls the per-turn memory scorecard;
outcomeReview (off|nudge|stop) controls how hard Claude is asked to credit
memory by id. Codex defaults to off and nudge. Documents both, the scorecard's
definitions and the review's cost in the user guides and option tables.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A pure fold over the session log gives per-lesson shown/used/unknown and the
worked/failed/waiting verdict (explicit verdict, correction, last failed
non-read-only tool call, next prompt), and a renderer prints the exact card.
Golden fixtures pin the summaries and the text.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI lite review requested due to automatic review settings September 28, 2026 20:51

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@e1daru
e1daru merged commit a08dd8d into pre-main Sep 28, 2026
14 of 16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants