Repository navigation
Description
Cross-promote the other Digital-Process-Tools plugins -- supertool and claude-jit-context -- to the human using Remember, occasionally, through a channel the model never sees, with a config bool to turn it off.
The channel is the whole design
Claude Code's hook docs separate three streams, and only one of them reaches a person:
| channel | who sees it |
|---|---|
hookSpecificOutput.additionalContext |
the model -- "context that Claude can see and act on" |
systemMessage |
the user -- "To surface a message to the user on any platform, return systemMessage in JSON output" |
| plain stdout on most events | neither -- written to the debug log, not shown in the transcript |
plain stdout on SessionStart / UserPromptSubmit |
the model, as context |
The promo is addressed to a human, so it goes in systemMessage and must never go in additionalContext or SessionStart stdout. Text in those streams costs tokens on every session, sits beside the user's real memory, can be acted on or echoed by the model, and -- on Antigravity, whose hook executor parses stdout as protojson -- breaks the hook outright rather than printing (the defect already fixed in #563 by discarding delegate stdout).
There is a live example of the wrong field in our own stack, which is worth citing because it shows the cost rather than predicting it: claude-jit-context 0.8.0's scripts/stop-hook.sh:477 emits its end-of-session notice as additionalContext, with body text that itself reads "not addressed to you -- informational only, no action needed". Its own comments record the consequence: line 88 calls that output "exactly the output that blocks a turn", and line 98 handles the harness re-invoking Stop because the hook's own additionalContext blocked the turn (jit #279). Model context is being spent, and turns blocked, to deliver a sentence written for a human. A separate issue belongs on that repo; it is named here only as evidence for the field choice.
What to build
- A single-line
systemMessage, naming one sibling plugin, from a hook Remember already registers. - Off switch: a documented boolean in
config.json, layered the usual way (per-project > user-global > plugin defaults). Proposedfeatures.plugin_promos, defaulttrue, matching the existingfeaturesgroup. - Throttle: not once per session. Once per N days per machine, persisted the way the delivery record already is. Proposed
cooldowns.promo_seconds. - Never on
SessionEnd. That path does the final flush and its budget is already the thing that gets cut short; a promo must not make it slower or noisier. - Prefer relevance where it is free: mention
supertoolandclaude-jit-contextgenerally, but if a repo-local signal is already at hand, name the one that fits.
Open question -- MEASURE, do not assume
The docs state the general rule and then do not keep it: "Some events discard it or deliver it elsewhere, and each event's section says so" -- but the per-event sections for SessionStart, PostToolUse, SessionEnd and Stop say nothing about systemMessage. Which of Remember's four registered events actually delivers a systemMessage to the screen is currently unknown, not "probably fine".
Settle it with a throwaway probe before writing the feature: a scratch project whose own .claude/settings.json wires a hook emitting {"systemMessage":"PROBE <event>"} on every event, then one real session (open, one prompt, one tool call, close), recording for each event whether the probe appeared on screen, appeared in the transcript, or vanished into the debug log. Not in the plugin, not shipped -- a scratch tree that gets deleted.
Prediction, written down so it can be proven wrong rather than quietly matched: SessionStart delivers; SessionEnd does not; PostToolUse unclear. If only SessionStart delivers, the promo rides there, which is also the least intrusive spot since the user is already reading the handoff block.
Shipping into a channel that silently drops the message is the worst outcome for this feature: identical cost, zero delivery, and nothing anywhere reports the absence -- this repo's own defect class.
Explicitly out of scope
Third-party or paid advertising, and anything that makes the plugin nag harder when disabled. This is cross-promotion of our own plugins in a stream the model cannot read, with a switch that turns it off.
[AI-generated]
Activity
fdaviddpt commentedon Sep 5, 2026
Promo text is data, not code
Added to the design: the messages live in a shipped JSON file, not in the hook script, so a promo can be added, reworded or dropped without touching shell. A GitHub URL is required on every entry -- a promo that names a plugin without saying where to get it is an interruption with no payoff.
Proposed
promos.jsonbesideconfig.example.json:{ "promos": [ { "id": "supertool", "text": "Token-heavy git and GitHub calls? supertool compresses them.", "url": "https://github.com/Digital-Process-Tools/claude-supertool" }, { "id": "jit-context", "text": "Rules your agent keeps forgetting? claude-jit-context injects them only when they match.", "url": "https://github.com/Digital-Process-Tools/claude-jit-context" } ] }Rules the loader should hold, each of which is a test:
urlis skipped, and the skip is visible -- not silently rendered without the link. Silent degradation to a link-less promo is this repo's own defect class.idis what the throttle records, so rotation shows a different plugin next time rather than the same one forever, and so removing an entry does not shift which one is "next".textis rendered as-is intosystemMessage, single line, no markdown assumptions -- the docs promise delivery "on any platform", and a platform that renders plain text will show whatever punctuation is in the field.promosarray is a legitimate "nothing to say", distinct from a missing file. Both produce no output; only one is a fault.This also settles who can change promo copy: anyone editing a JSON file in a release, rather than a shell edit inside a hook that runs on every session.
fdaviddpt commentedon Sep 5, 2026
Decided:
SessionStartonlyMaintainer decision. The promo is emitted from
SessionStartand from no other event.Why that one, rather than "wherever
systemMessagedelivers":SessionStartfired and delivered on screen at 19:25:19Z in the probe described above.UserPromptSubmitandStopalso deliver, and are deliberately not used: a per-turn channel turns "occasional" into "constant" without anyone editing a throttle.PostToolUseandSessionEndremain unmeasured and are out of scope regardless.SessionEndstays untouched on principle -- that path does the final flush, and its budget is already the thing that gets cut short.This narrows the design above: a single emit site, so the throttle has exactly one caller and the off switch has exactly one thing to gate.
Copy constraint, from the observed rendering
The harness prefixes the line with the event name: the probe rendered as
So
textinpromos.jsonmust be short enough to survive that prefix and still read as a tip rather than a diagnostic. A fragment with the URL --supertool -- fewer tokens on git/gh calls -- github.com/Digital-Process-Tools/claude-supertool-- survives it; a marketing sentence does not. Worth a test asserting a maximum length rather than leaving it to whoever edits the JSON next.Not building this yet
0.28.0 is mid-release. Starting a lane on top of a release in flight is what widened the audited-range gap twice already today, so this waits for the tag.
fdaviddpt commentedon Sep 5, 2026
Only promote what is not installed
Maintainer decision, and it is what makes this feature defensible: a user who already has all four plugins never sees a line, ever. The promo is not "occasional advertising", it is "you do not have this one".
Where the answer lives (Claude Code)
~/.claude/plugins/installed_plugins.json,version: 2, keyed<name>@<marketplace>:{ "version": 2, "plugins": { "remember@dpt-plugins": [ { "scope": "user", "installPath": ".../cache/dpt-plugins/remember/0.27.0", "version": "0.27.0", ... } ] } }Cheap to read, no process spawn, no network. Each
promos.jsonentry gains the key to look for, so the data file stays the only thing that changes when a plugin is added:{ "id": "supertool", "installed_key": "supertool@dpt-plugins", "text": "supertool -- fewer tokens on git/gh calls", "url": "https://github.com/Digital-Process-Tools/claude-supertool" }The failure direction is the whole design
Unknown must mean silence, not "not installed". Every one of these produces "no entry found", and only some of them mean the user lacks the plugin:
~/.gemini/, Codex elsewhere; neither has this file. Remember runs on all three.<name>@<marketplace>key does not match even though the plugin is present.versionis2today; a future shape change would read as an empty install list.If any of those renders as "not installed", we show an ad for a plugin the user already has -- the single most annoying outcome this feature can produce, and the one that gets it uninstalled. So:
installed,not-installed,cannot-tell.cannot-tellsuppresses the promo, exactly likeinstalleddoes. Only a positive, confidentnot-installedis allowed to speak.This also means the feature is silently a no-op on Antigravity and Codex until someone measures where those hosts record installs, which is the correct behaviour rather than a gap:
cannot-tellis honest there.What it costs
One small JSON read at
SessionStart, on the same path that already reads config. If the read fails for any reason, the answer iscannot-telland nothing is printed -- so the promo can never be the reason a session start gets slower or noisier than it is today.Add tests/test_plugin_promo_574.py to the Windows skip triage (#574)
Fix jq-hardcoding scan false-positive and use $JQ in the promo code (#…
Add cross-plugin promo via systemMessage at SessionStart (#588)
Add authoring-time reminder for a new blanket win32-skip test (#589) (#…
Carry the promo's off switch in the promo itself (#631)
Make the promo say who it is and how to switch it off (#631) (#632)
perf(#660): stop forking for work bash can do -- 49 -> 29 foreground …
perf(#660): take 20 subprocesses off the SessionStart foreground path (…
fix(#712): skip TestCtxBufferSkippedUnderTrace on win32, matching its…
fix(#712): skip session-start-hook.sh's stdout buffer under an active…
fix(#761,#762): fail closed on a symlinked .git; guard non-object .pl…
test(#898): give fake plugin roots the install manifest resolve-paths…
fix(#898): release tree scrub + 5 new guards (typed-heredoc shipped a…
fix(#900): compile hooks.json-registered hooks self-contained at buil…