memory-diff

A local health-history comparison that finds what changed since a chosen date, event, or previous check-in by reading saved records and notes.

In plain words
What is it for?
Use it for questions such as what changed since last week, a post-visit summary, a lab follow-up, or a weekly or monthly health recap. It reads local workspace data and does not provide medical advice.
Why use it?
It brings together changes from medical records, processed documents, health-feed summaries, and dated notes instead of requiring a manual review of each source. Changes are grouped by clinical significance.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/realactivity/tula/memory-diff
Any agent
npx skills add realactivity/tula --skill memory-diff
Clone the repo
git clone --depth 1 https://github.com/realactivity/tula

Made for: Claude Code, Codex.

Per session 105 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,183 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00105 $0.01183
Opus 5 $0.00053 $0.00592
Sonnet 5 $0.00021 $0.00237
Haiku 4.5 $0.00011 $0.00118

Measured yesterday against content hash cdb646a45e98, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

memory-diff 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 yesterday.

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/memory-diff/SKILL.md · 111 lines

How it starts

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

memory-diff

When to Use

✅ Use when:

  • User asks "what's changed in my health since <last week / last month / since X>"
  • Post-visit or post-lab summaries - "what's new since my last appointment"
  • Scheduled weekly or monthly longitudinal check-ins
  • "Since I started " or "since my referral to " recaps
  • Another skill needs a "what's new" sub-step (e.g., after health-records refresh)

When NOT to Use

❌ Don't use when:

  • User wants news or social signal -> use myhealth-pulse
  • User shares a PDF, screenshot, or image -> use med-pdf
  • User asks for raw chart data -> use health-records
  • User wants to draft a clinician message -> use epic-note
  • User asks for medical advice - decline politely; this reads memory, not clinical judgment

Setup

No external tools, no API keys. The skill reads from the local workspace only.

Memory sources, in precedence order (full contract in references/memory-paths.md):

  • ~/.openclaw/workspace/.health-records-cache/<date>/ - structured FHIR JSON
  • ~/.openclaw/workspace/.med-pdf-cache/<slug>/ - extracted JSON from PDFs
  • ~/.openclaw/workspace/memory/*.md - dated agent notes
  • ~/.openclaw/workspace/MEMORY.md - persistent agent memory
  • ~/.openclaw/workspace/.myhealth-pulse-cache/<date>.json - pulse digests

Workflow

  1. Resolve the reference point. Default: 7 days ago. Parse named anchors from the prompt:

    • Calendar phrases: "last week" (7d), "last month" (30d), "last 90 days"
    • Event anchors: "since I started ", "since my visit" - scan memory for the matching event date
    • Absolute dates: "since 2026-04-01"
    • If ambiguous, ask one clarifying question, then proceed.
  2. Enumerate within the window. For each source above, list files modified or dated within the window. Don't load everything into context - stream-scan headers and key sections.

  3. Classify each change. Apply the rubric in references/clinical-significance.md:

    • Tier 1 - signal. New abnormal lab, med change, new diagnosis,

      20% trend change in a tracked marker, new imaging finding, abnormal-to-normal resolution.

    • Tier 2 - notable. Stable abnormality continuing, mild trend, new appointment scheduled, new pulse mentions of relevant topics.
    • Tier 3 - noise. Routine entries, unchanged trends, low-relevance pulse items. Collapsed to a one-line count.

Read the full file on GitHub · 111 lines

Files

What ships with it

4 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. yesterday First seen · 111 lines · 105 tokens per session scan A cdb646a45e98

Subscribe to this mod's changes

memory-diff is a skill published in the GitHub repository realactivity/tula (45 stars, last pushed 2mo ago), licensed Apache-2.0. It adds 105 tokens to every session and 1,183 once invoked, about $0.0005 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-30.

Related

Other skills, from other repositories

lab-report-walkthrough

Walk a person through their lab report — read the original document, organize results by panel, flag out-of-range values against the printed reference ranges, compare with their history, and explain in plain language. Use when the user uploads a lab report (PDF/image) or asks what their blood test results mean.

thetahealth/mirobody · 67 tokens

comment-compactor

Delete the comments a diff adds unless they earn their place, and condense the few that do. Use as the final step before pushing, submitting, or finalizing a PR — after tests and lint pass, before git push / gh pr create. Also use when asked to "clean up the comments", "check the comments", or when a review flags a…

medplum/medplum · 89 tokens

ehr-data-parsing

Parse and extract clinical data from HL7v2 messages and FHIR R4 resources using Python. Use when the user mentions HL7v2, HL7, FHIR, PID segment, OBX segment, MSH segment, Patient resource, Observation resource, Condition resource, MedicationRequest, EHR data extraction, clinical message parsing, FHIR bundle, HL7 to…

awslabs/hcls-agent-skills · 165 tokens

biomcp-research

Do biomedical literature and variant research with the BioMCP CLI, and file what you learn about the tool itself as issues in the biomcp repo.

genomoncology/biomcp · 36 tokens

system_status

Check system health -- disk usage, memory, running processes, uptime.

AIOSAI/AIPass · 16 tokens

branch_health

Quick health check -- test counts and file stats for AIPass branches.

AIOSAI/AIPass · 17 tokens