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
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.
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.
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.
Synthesize. Tier 1 first (always shown), Tier 2 second (always
shown), Tier 3 collapsed (12 routine entries). End with one trailing
line:
Powered by memory-diff - window: <resolved>, sources: <names>.
Empty window. If nothing in any tier, return one line:
No changes in <window> - last entry: <date> from <source>.
Don't fabricate filler entries.
Cache the rendering. Write to
~/.openclaw/workspace/.memory-diff-cache/<YYYY-MM-DD>.md. The next
run can diff-of-diff if asked ("what's new since I last asked you this").
Examples
See references/examples.md for since-last-week,
since-a-med-change, post-visit, and empty-window outputs.
Privacy
- All reads are workspace-local; nothing outbound, ever.
- Output stays in the chat. Don't auto-forward, auto-summarize externally,
or include in any outbound notification unless explicitly configured.
- Cache stays under
~/.openclaw/workspace/.memory-diff-cache/. Don't
copy out.
Troubleshooting
- Ambiguous anchor -> ask one clarifying question, then proceed. Don't
guess.
- Conflicting facts across sources -> surface both with source
attribution. Don't silently pick a winner.
- Cache directory missing on first run -> create it, no error.
- Tuning the tiers -> in v1, thresholds live in
references/clinical-significance.md.
A forthcoming user dashboard app will let the user tune these through a
profile mechanism (same shape as
myhealth-pulse/references/profile-schema.md). Until then, edit the
references file directly.
1---2name: memory-diff3description: Surfaces what changed in the user's health since a reference point (date, named event, 'since last X'). Reads workspace memory from med-pdf, health-records, myhealth-pulse, and dated notes; tiers changes by clinical significance. USE FOR: 'what changed', post-visit summaries, longitudinal questions, weekly check-ins. DO NOT USE FOR: news/social (myhealth-pulse), PDFs (med-pdf), chart data (health-records), drafting (epic-note).4---56# memory-diff78## When to Use910✅ Use when:1112- User asks "what's changed in my health since <last week / last month / since X>"13- Post-visit or post-lab summaries - "what's new since my last appointment"14- Scheduled weekly or monthly longitudinal check-ins15- "Since I started <med>" or "since my referral to <provider>" recaps16- Another skill needs a "what's new" sub-step (e.g., after `health-records` refresh)1718## When NOT to Use1920❌ Don't use when:2122- User wants news or social signal -> use `myhealth-pulse`23- User shares a PDF, screenshot, or image -> use `med-pdf`24- User asks for raw chart data -> use `health-records`25- User wants to draft a clinician message -> use `epic-note`26- User asks for medical advice - decline politely; this reads memory, not clinical judgment2728## Setup2930No external tools, no API keys. The skill reads from the local workspace only.3132Memory sources, in precedence order (full contract in33[`references/memory-paths.md`](references/memory-paths.md)):3435- `~/.openclaw/workspace/.health-records-cache/<date>/` - structured FHIR JSON36- `~/.openclaw/workspace/.med-pdf-cache/<slug>/` - extracted JSON from PDFs37- `~/.openclaw/workspace/memory/*.md` - dated agent notes38- `~/.openclaw/workspace/MEMORY.md` - persistent agent memory39- `~/.openclaw/workspace/.myhealth-pulse-cache/<date>.json` - pulse digests4041## Workflow42431. **Resolve the reference point.** Default: 7 days ago. Parse named anchors44 from the prompt:45 - Calendar phrases: "last week" (7d), "last month" (30d), "last 90 days"46 - Event anchors: "since I started <med>", "since my <provider> visit" -47 scan memory for the matching event date48 - Absolute dates: "since 2026-04-01"49 - If ambiguous, ask one clarifying question, then proceed.50512. **Enumerate within the window.** For each source above, list files52 modified or dated within the window. Don't load everything into context -53 stream-scan headers and key sections.54553. **Classify each change.** Apply the rubric in56 [`references/clinical-significance.md`](references/clinical-significance.md):57 - **Tier 1 - signal.** New abnormal lab, med change, new diagnosis,58 >20% trend change in a tracked marker, new imaging finding,59 abnormal-to-normal resolution.60 - **Tier 2 - notable.** Stable abnormality continuing, mild trend, new61 appointment scheduled, new pulse mentions of relevant topics.62 - **Tier 3 - noise.** Routine entries, unchanged trends, low-relevance63 pulse items. Collapsed to a one-line count.64654. **Synthesize.** Tier 1 first (always shown), Tier 2 second (always66 shown), Tier 3 collapsed (`12 routine entries`). End with one trailing67 line:68 `Powered by memory-diff - window: <resolved>, sources: <names>`.69705. **Empty window.** If nothing in any tier, return one line:71 `No changes in <window> - last entry: <date> from <source>.`72 Don't fabricate filler entries.73746. **Cache the rendering.** Write to75 `~/.openclaw/workspace/.memory-diff-cache/<YYYY-MM-DD>.md`. The next76 run can diff-of-diff if asked ("what's new since I last asked you this").7778## Examples7980See [`references/examples.md`](references/examples.md) for since-last-week,81since-a-med-change, post-visit, and empty-window outputs.8283## Privacy8485- All reads are workspace-local; nothing outbound, ever.86- Output stays in the chat. Don't auto-forward, auto-summarize externally,87 or include in any outbound notification unless explicitly configured.88- Cache stays under `~/.openclaw/workspace/.memory-diff-cache/`. Don't89 copy out.9091## Troubleshooting9293- **Ambiguous anchor** -> ask one clarifying question, then proceed. Don't94 guess.95- **Conflicting facts across sources** -> surface both with source96 attribution. Don't silently pick a winner.97- **Cache directory missing on first run** -> create it, no error.98- **Tuning the tiers** -> in v1, thresholds live in99 [`references/clinical-significance.md`](references/clinical-significance.md).100 A forthcoming user dashboard app will let the user tune these through a101 profile mechanism (same shape as102 `myhealth-pulse/references/profile-schema.md`). Until then, edit the103 references file directly.