SatisfactionCapture persists <private> spans verbatim into MEMORY/LEARNING on a low rating
Maintainers usually reply within 5 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 72/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- typescript
Research direction
Read hooks/SatisfactionCapture.hook.ts, especially captureLowRatingLearning and the explicit and implicit call paths, then check how stripPrivateContent is used in LIFEOS/TOOLS/CaptureEnvelope.ts and the memory writers. Trace captureFailure and the Errata row as the issue suggests. Done when private spans from feedback and response context are not persisted in low-rating learning files, with related writers checked for the same gap.
Written by the indexing model from the issue text.
Description
What happens
On a low rating (< 5), captureLowRatingLearning in hooks/SatisfactionCapture.hook.ts writes the rating comment and the last assistant response straight into MEMORY/LEARNING/<category>/<YYYY-MM>/…_LEARNING_low-rating-N.md. Neither string passes through stripPrivateContent, so any <private>…</private> span in either one is persisted verbatim.
In 8.761.0 (b7efec97):
hooks/SatisfactionCapture.hook.ts:427-482:summaryOrCommentgoes into the**Feedback:**line anddetailedContextgoes into## Context, thenwriteFileSync(filepath, content, 'utf-8').hooks/SatisfactionCapture.hook.ts:530(explicit) and the implicit path passexplicitResult.commentandgetSessionLastResponse(...)unchanged.
Why it matters
LIFEOS/DOCUMENTATION/Memory/CortexContract.md:154 says that private spans are "never persist or export", and stripPrivateContent (LIFEOS/TOOLS/CaptureEnvelope.ts:20) already exists for this. MemoryReviewer.ts and MemorySystem.ts call it before they persist anything. The low-rating learning file is persisted memory as well, but it skips that boundary.
Repro (traced in the code; I did not run it)
- Rate a turn low, with a comment that holds a private span, e.g.
3 - <private>secret detail</private> wrong file. - Open the newest
MEMORY/LEARNING/*/*/…_LEARNING_low-rating-3.md. The span is there verbatim.
Suggested fix
Inside captureLowRatingLearning, wrap both strings before they are used, which also covers getLearningCategory:
summaryOrComment = stripPrivateContent(summaryOrComment);
detailedContext = stripPrivateContent(detailedContext);
I have not checked the other writers on the same path, captureFailure and the Errata row. They may need the same treatment.
- Dominant language
- TypeScript
- Stars
- 19.9k
- Forks
- 2.5k
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from danielmiessler/LifeOS
-
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
danielmiessler/LifeOS#2894 ·
Maintainers usually reply within 5 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
danielmiessler/LifeOS#2891 ·
Maintainers usually reply within 5 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
danielmiessler/LifeOS#2888 ·
Maintainers usually reply within 5 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
danielmiessler/LifeOS#2886 ·
Maintainers usually reply within 5 days
-
Difficulty 1/5 Under an hour Newbie friendliness 68/100
danielmiessler/LifeOS#2848 ·
Maintainers usually reply within 5 days
All issues in danielmiessler/LifeOS
Similar issues
-
ready-for-agent
Difficulty 1/5 Under an hour Newbie friendliness 86/100
LucasSantana-Dev/Lucky#3257 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
XiaomiMiMo/MiMo-Code#2849 · 1 comment ·
Maintainers usually reply within 1 day
-
enhancement frontend good first issue help wanted testing-infrastructure
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 2 days
-
enhancement follow-up
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
obsidian-tasks-group/obsidian-tasks#4155 ·
Maintainers usually reply within 1 day