Skip to content
Back to skills

123 Fn 12 9d5e2075

ASecurity

Extend ralph-guard.py PostToolUse handler to capture learnings from NEEDS_WORK reviews. When chat-send returns NEEDS_WORK/MAJOR_RETHINK, parse feedback and append to pitfalls.md.

  • 9 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added October 11, 2026
testingpythongoapi

Works with

  • api

Security analysis

A100/100

Scanned October 11, 2026

npx -y skills add tools-only/X-Skills --skill 123-fn-12_9d5e2075 --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of 123 Fn 12 9d5e2075?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for 123 Fn 12 9d5e2075
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/tools-only-123-fn-12-9d5e2075/badge)](https://www.skillsdirectory.com/skills/tools-only-123-fn-12-9d5e2075)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

SKILL.md
# fn-1.2 Capture hook

## Description
Extend ralph-guard.py PostToolUse handler to capture learnings from NEEDS_WORK reviews. When chat-send returns NEEDS_WORK/MAJOR_RETHINK, parse feedback and append to pitfalls.md.

Key implementation:
- Check `memory.enabled` config before processing
- `extract_feedback(response)` parses review into structured format
- `is_learnable(feedback)` filters to actionable patterns only
- Append to `.flow/memory/pitfalls.md` with date, task, issue, fix, category

Filter criteria (`is_learnable`):
- Has specific actionable fix (not vague)
- References code pattern, API, or convention
- Not a one-off typo or obvious bug

## Acceptance
- [ ] PostToolUse handler detects chat-send with NEEDS_WORK
- [ ] Checks `memory.enabled` before processing
- [ ] Parses feedback into structured format (issue, fix, category)
- [ ] `is_learnable()` filters out non-actionable items
- [ ] Appends to pitfalls.md with correct format
- [ ] Handles missing memory dir gracefully

## Done summary
- Added memory capture in ralph-guard.py PostToolUse handler
- extract_feedback() parses NEEDS_WORK reviews into structured issues
- is_learnable() filters to actionable patterns (framework, API, convention)
- classify_issue() categorizes entries for memory format
- append_to_pitfalls() writes entries to .flow/memory/pitfalls.md

Why:
- Captures high-signal learnings from reviewer feedback
- Only activates when memory.enabled is true

Verification:
- Python syntax check passed
- Unit test of extract_feedback and is_learnable passed
- flowctl validate --all passes
## Evidence
- Commits: 1471f8ca7bb4373bd576e057a8aefc1283e22ff3
- Tests: python3 -m py_compile, unit test of memory functions
- PRs:

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.