Sleep Repair (Graph Maintenance)
2 steps
Graph maintenance specialist for the Cognitive Sleep Cycle. Identifies concept fragmentation and repairs WikiLink inconsistencies while preserving decay integrity by using observation-only tools for replay.
Triggers
Steps
- 1.
Memory Replay (Concept Usage Focus)
Identify high-frequency concept families that may have fragmentation.
- Load your maenifold skill and run recent_activity to retrieve events from the last 24-48 hours
- Focus on [[WikiLinks]] that appear frequently across recent activity
- Note potential concept variants: plurals vs singulars, case variations, abbreviations
- Identify concept families worth analyzing (e.g., [[tool]]/[[tools]], [[auth]]/[[authentication]])
- Create prioritized list of concept families for repair analysis
Output: Prioritized list of concept families to analyze Include: High-frequency concepts, suspected variants, fragmentation indicators
CRITICAL: Do NOT use read_memory - this phase is observation-only to preserve decay integrity.
Tools:recent_activity*Effort:lowGuardrails- no_read_memory: NEVER use read_memory - graph tools do not need file content
- observation_only: This phase identifies patterns, does not modify anything
- frequency_threshold: Focus on concepts appearing 5+ times in recent activity
- 2.
Concept Repair (Graph Maintenance)
Analyze and repair concept corruption in high-frequency families.
- For each prioritized concept family, run analyze_concept_corruption to diagnose variants
- Identify TRUE duplicates safe to merge: plurals, case variations, typos
- Identify entities that MUST NOT merge: class names, specific types, compound terms
- Use repair_concepts with dryRun=true first to preview all changes
- Apply repairs only for clear cases where semantic similarity is high
- Flag ambiguous cases for human review in the report
- Run sync to rebuild graph after repairs
Output: Return repair report as workflow output - DO NOT write to memory:// Include: Repairs made, items flagged for review, graph health metrics
CRITICAL: Do NOT use read_memory - repair_concepts modifies source files directly.
Enhanced ThinkingTools:analyze_concept_corruption*repair_concepts*sync*Effort:mediumGuardrails- no_read_memory: NEVER use read_memory - graph tools do not need file content
- no_write_memory: NEVER use write_memory - repair reports are ephemeral, return as output
- dry_run_first: Always preview repairs with dryRun=true before applying
- human_review: Flag ambiguous merges for human decision
- semantic_validation: Only merge concepts with similarity >= 0.7
- no_class_names: NEVER merge class names (GraphTools.cs) with generic concepts ([[tool]])
- no_specific_types: NEVER merge specific types (test-agent) with generic concepts ([[agent]])