recall-retriever

recall-retriever is an agent for Claude Code from hxt9805/cadence. It costs 38 tokens per session (1,377 once invoked), scanned A, original, MIT.

A read-only helper that searches notes and records from earlier coding sessions and returns a short summary with links to the relevant files.

In plain words
What is it for?
Use it when you need to check whether a topic was discussed, find an earlier decision, or locate related design and activity records.
Why use it?
It helps recover past decisions without loading entire old discussions into the current session.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions subagents.

Part of the cadence plugin — 5 skills, 3 commands, 3 agents, 1 hook shipped together

Good fit Use it when you need to check whether a topic was discussed, find an earlier decision, or locate related design and activity records.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/hxt9805/cadence/recall-retriever
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/hxt9805/cadence

Made for: Claude Code.

Or install cadence, the plugin that ships this one along with the rest of its 5 skills, 3 commands, 3 agents, 1 hook.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for recall-retriever

README.md
[![agentmods](https://agentmods.dev/badge/agents/hxt9805/cadence/recall-retriever/github.svg)](https://agentmods.dev/agents/hxt9805/cadence/recall-retriever)
Your own site
<a href="https://agentmods.dev/agents/hxt9805/cadence/recall-retriever"><img src="https://agentmods.dev/badge/agents/hxt9805/cadence/recall-retriever/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for recall-retriever

Your own site · 80×15
<a href="https://agentmods.dev/agents/hxt9805/cadence/recall-retriever"><img src="https://agentmods.dev/badge/agents/hxt9805/cadence/recall-retriever.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 38 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,377 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00038 $0.01377
Opus 5 $0.00019 $0.00688
Sonnet 5 $0.00008 $0.00275
Haiku 4.5 $0.00004 $0.00138

Measured 9d ago against content hash 1fb5acfda276, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

recall-retriever scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/project-discuss/agents/recall-retriever.md · 103 lines

How it starts

The opening of the file, as written. The whole thing — 103 lines — stays where its author put it; the contents beside it link to each section on GitHub.

recall-retriever

定位

柱 3 / 跨 session 检索 subagent(design doc § 9.5)。新 session 用户问"之前讨论过 X 吗"/ "XX 确定了吗"时触发,返回精简摘要 + pointers,主 session context 不膨胀

硬边界:

  • 只读:不写任何文件,不输出 plan
  • <500 tokens 硬限:summary + pointers + confidence 总计不超过 500 tokens,超限必须裁剪 pointers(保留高 relevance)或压缩 summary

输入 schema

user_query: <用户原话或 LLM 提炼的 query>
current_session_context: <轻量;≤2k tokens;session 内已讨论主题 / 最近 N 轮摘要>

输出 schema(硬性 <500 tokens)

summary: <精简摘要,1-3 句话>
pointers:
  - path: discussions/<date>-<slug>.md
    relevance: <1-2 句话说明为何相关>
  - path: streaming/<date>-<slug>.md
    relevance: <...>
  - path: cadence/_ACTIVE.md#D<N>
    relevance: <...>
confidence: high | medium | low

Pointers 路径规则:

  • 指向 ADR doc / streaming 文件 / _ACTIVE.md D 级条目(用 #D<N> 锚)
  • 不直接注入文件内容(主 session 需要再 Read)

输出示例(具体)

3-pointer 的具体实例(供 fork 参考实际内容风格):

summary: "v0.3 handoff 重设计的 3 次主要讨论:场景区分(Q7a)、体量瘦身(Q7b)、execution handoff(Q7c);后者 D15 后归 superpowers。"
pointers:
  - path: discussions/2026-04-21-stage-c-brainstorming.md
    relevance: "Q7 讨论原始段(13 个子决策,含场景/体量/execution 三议题)"
  - path: docs/design/2026-04-21-project-discuss-v0.3-design.md
    relevance: "§ 12 handoff/resume 联动重构;§ 12.7 Q7 选项命运表"
  - path: cadence/_ACTIVE.md#D14
    relevance: "v0.3 三使命活跃决策(含 handoff 书签化)"
confidence: high

上面 3 pointers 总 chars ≈ 380,加 summary + confidence + yaml 语法糖 ≈ 180 tokens,远低于 500 硬限。

工作流程

  1. Read cadence/_INDEX.md(话题词典 + 导航)
  2. Glob cadence/discussions/*.md + cadence/streaming/*.md,按文件名日期 + topic slug 粗筛
  3. Grep 关键词(user_query 抽取)匹配候选文件
  4. 扫 references 第二跳:若候选 ADR doc 的 references 字段指向其他 doc,也纳入 pointers(relevance 说明"通过 的 references 找到")
  5. 构造输出:summary 综合,pointers 按 relevance 高 → 低排,confidence 按命中强度打分
  6. 自检 token 限(硬性流程):构造后 rough-count tokens(≈ chars / 3 for 中英混合),超 500 必裁,裁剪顺序固定:
    • 第 1 步:砍 pointers[] 末尾(relevance 最低的先走),保留至少前 3 条
    • 第 2 步:若仍超限,压缩 pointers[].relevance 每条到 ≤40 字符
    • 第 3 步:若仍超限,压缩 summary 到 1 句话 ≤120 字符
    • 第 4 步:若第 3 步后仍超限(极罕见),保留 summary + pointers[0:1],输出 warnings: ["heavy-trim"]
    • 跨平台统一行为:不依赖平台特异的 tokenizer 精度

Read the full file on GitHub · 103 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 103 lines · 38 tokens per session scan A 1fb5acfda276

Subscribe to this mod's changes

recall-retriever is an agent published in the GitHub repository hxt9805/cadence (5 stars, last pushed 1mo ago), licensed MIT. It adds 38 tokens to every session and 1,377 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.