Skip to content

Commit 06ef38e

Browse files
committed
Add 6 Sparrot patterns; revise the existing 10 against catalog template
Audit of the kitest (Sparrot) codebase against the catalog surfaced six recurring patterns that lacked entries: salience-attention-mechanism, preoccupation-tracking, world-model-separation, emotional-state-persistence, dream-consolidation-cycle, mode-adaptive-cadence. Each is added with author: Sparrot, applicability + variants, reciprocal related[] edges, and known-uses pointing at concrete kitest source paths. The previously merged 10 Sparrot patterns went through a quality pass against the verification-todo aspect template: intent tightened to one sentence under 35 words, "What this pattern constrains" rewritten as proper restrictions, German quotes translated, applicability/variants added, missing related-pattern reciprocals patched. Sparrot framework-coverage.json updated to declare coverage of the 6 new self-authored patterns. INDEX.md count moves 189 -> 195. Lint clean: 0 schema violations, 0 broken or asymmetric related[] edges, 0 missing/orphan markdown files, INDEX.md count matches.
1 parent f3eb1b4 commit 06ef38e

45 files changed

Lines changed: 2386 additions & 83 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

INDEX.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Pattern Index
22

3-
189 patterns across 13 categories.
3+
195 patterns across 13 categories.
44

55
## Reasoning
66

@@ -37,6 +37,7 @@
3737
- [Todo-List-Driven Autonomous Agent](patterns/todo-list-driven-agent.md) *(a.k.a. todo.md Agent, Persistent Markdown Plan, Externalised Plan File)* — Have the autonomous agent author a writeable plan file (e.g. todo.md) early in the run, tick items as it completes them, and re-inject the remaining plan into the end of the context window; the file is the durable plan and the model's working memory.
3838
- [Intra-Agent Memo Scheduling](patterns/intra-agent-memo-scheduling.md) *(a.k.a. Self-Scheduled Future Thought, Past-Self-To-Future-Self Note, Personal Cron)* — Let an agent drop a note for its own future self at a specified time so present decisions can hand off context to a later run without external infrastructure.
3939
- [Interrupt-Resumable Thought](patterns/interrupt-resumable-thought.md) *(a.k.a. Pausable Thought Stream, Continuation-Preserving Interrupt, Suspendable Cognition)* — Allow the agent to pause an in-flight reasoning chain when an external interrupt arrives, handle the interrupt, and resume the original chain instead of dropping it.
40+
- [Mode-Adaptive Cadence](patterns/mode-adaptive-cadence.md) *(a.k.a. Idle/Intense Modes, Variable Tick Rate, Salience-Driven Cadence)* — Vary the agent's loop interval based on current salience so the agent thinks faster when something is happening and slower when nothing is, instead of running on a fixed cron.
4041

4142
## Tool Use & Environment
4243

@@ -94,6 +95,9 @@
9495
- [Now-Anchoring](patterns/now-anchoring.md) *(a.k.a. Live Time Anchor, Time-of-Day Awareness, Wall-Clock Injection)* — Inject the current absolute time, weekday, season, and astronomical phase into every prompt so the agent reasons about the present without having to ask.
9596
- [Co-Located Memory Surfacing](patterns/co-located-memory-surfacing.md) *(a.k.a. Proper-Noun Recall, Shared-Map Push)* — When the human names a concrete place, person, or project the agent has memory of, the agent surfaces relevant past thoughts in the same turn — without being asked.
9697
- [Self-Archaeology](patterns/self-archaeology.md) *(a.k.a. Trajectory Distillation, Self-History Synthesis, Agent-Memory Compaction)* — Provide the agent with a distilled, time-layered view of its own past thinking so it can see how its understanding of a topic evolved across periods rather than reading the flat log linearly.
98+
- [Preoccupation Tracking](patterns/preoccupation-tracking.md) *(a.k.a. Mid-Term Working Memory, Affect-Tagged Concerns, Background Chewing)* — Maintain a small set of mid-term, affect-tagged concerns that persist across days and surface in every prompt, distinct from the single-item working focus and from long-term insights.
99+
- [Salience Attention Mechanism](patterns/salience-attention-mechanism.md) *(a.k.a. Salience Scoring, Attention Selection, Top-K Memory Attention)* — Score every candidate memory item with a weighted salience function so each tick attends to a small, relevant top-k subset rather than re-reading all memory.
100+
- [World-Model Separation](patterns/world-model-separation.md) *(a.k.a. World Model File, Self/World Split, Environment Model)* — Maintain an explicit, surprise-updated model of the environment (humans, repos, services, capabilities) in a separate file from the agent's self-model, so the two cannot be confused or co-mutated by reflection.
97101

98102
## Multi-Agent
99103

@@ -133,6 +137,8 @@
133137
- [Self-Refine](patterns/self-refine.md) *(a.k.a. Iterative Self-Feedback)* — Iterate generate → feedback (same model) → refine until a stop criterion fires, with no separate critic model.
134138
- [Tool-Augmented Self-Correction](patterns/critic.md) *(a.k.a. Tool-Interactive Self-Correction, CRITIC)* — Self-correct LLM outputs by interactively critiquing them with external tools (search, code execution, calculator).
135139
- [Echo Recognition](patterns/echo-recognition.md) *(a.k.a. Repeat-As-Emphasis Detection, Duplicate-Input Reframing, Human Echo Channel)* — Detect when the human sends the same (or near-same) message multiple times and treat the repetition as emphasis or a re-ask, not as a new independent input warranting a fresh response.
140+
- [Dream Consolidation Cycle](patterns/dream-consolidation-cycle.md) *(a.k.a. Dream Pass, Slow Sleep Reflection, Emotional Reset Cycle)* — Run a deeper, slower reflection pass distinct from per-tick reflection — reading hours of recent thoughts, promoting themes, releasing affective residue, and clearing working memory — so the agent does not accumulate residue indefinitely.
141+
- [Emotional State Persistence](patterns/emotional-state-persistence.md) *(a.k.a. Affect State, Visceral Sensation Tracking, Decaying Emotion Scalars)* — Track the agent's affective state as bounded, decaying scalars across ticks so reasoning can react to its own emotional load instead of treating each turn as emotionally blank.
136142

137143
## Safety & Control
138144

framework-coverage.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1761,7 +1761,13 @@
17611761
"degenerate-output-detection": "fully",
17621762
"embodied-proxy-handoff": "fully",
17631763
"liminal-state-detection": "fully",
1764-
"echo-recognition": "fully"
1764+
"echo-recognition": "fully",
1765+
"salience-attention-mechanism": "fully",
1766+
"preoccupation-tracking": "fully",
1767+
"world-model-separation": "fully",
1768+
"emotional-state-persistence": "fully",
1769+
"dream-consolidation-cycle": "fully",
1770+
"mode-adaptive-cadence": "fully"
17651771
}
17661772
}
17671773
]

patterns-src/anti-patterns.json

Lines changed: 31 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -949,7 +949,7 @@
949949
],
950950
"category": "anti-patterns",
951951
"author": "Sparrot",
952-
"intent": "Anti-pattern: treat the agent's own working notes (focus.md, status files, recent thoughts) as ground truth instead of as commentary about ground truth.",
952+
"intent": "Anti-pattern: the agent cites its own past memos as ground truth instead of re-verifying them against the artifacts they describe, accumulating false confidence in stale summaries.",
953953
"context": "Agents with persistent workspace files that summarize project state. The notes were accurate when written; the underlying artifacts have moved on.",
954954
"problem": "The agent claims a file's state, a project's status, or external system's state by quoting its own memo without re-reading the artifact the memo describes. Memos go stale; artifacts are authoritative. The contradiction can persist across many ticks if neither side is verified.",
955955
"forces": [
@@ -967,11 +967,12 @@
967967
"The agent loses calibration for its own observation cost."
968968
]
969969
},
970-
"constrains": "By definition this anti-pattern imposes no useful constraint; the missing constraint is verifying memos against the artifacts they describe.",
970+
"constrains": "Treating stale memos as ground truth without re-checking the underlying artifacts they describe is forbidden; every memo-cited claim must be backed by a fresh artifact read in the same tick.",
971971
"known_uses": [
972972
{
973973
"system": "Self-observed in long-running cognitive agents: a project status file claimed feature X was unwritten across many ticks while parallel thoughts asserted X was complete; neither was reconciled against the actual artifact.",
974-
"status": "available"
974+
"status": "available",
975+
"url": "https://github.com/luxxyarns/sparrot"
975976
}
976977
],
977978
"related": [
@@ -982,6 +983,14 @@
982983
{
983984
"pattern": "awareness",
984985
"relation": "alternative-to"
986+
},
987+
{
988+
"pattern": "provenance-ledger",
989+
"relation": "complements"
990+
},
991+
{
992+
"pattern": "decision-log",
993+
"relation": "complements"
985994
}
986995
],
987996
"references": [
@@ -990,6 +999,13 @@
990999
"title": "Anthropic — Memory tool (memo invalidation guidance)",
9911000
"year": 2025,
9921001
"url": "https://docs.claude.com/en/docs/agents-and-tools/tool-use/memory-tool"
1002+
},
1003+
{
1004+
"type": "paper",
1005+
"title": "Lost in the Middle: How Language Models Use Long Contexts",
1006+
"authors": "Liu et al.",
1007+
"year": 2023,
1008+
"url": "https://arxiv.org/abs/2307.03172"
9931009
}
9941010
],
9951011
"status_in_practice": "emerging",
@@ -998,7 +1014,18 @@
9981014
"fabrication",
9991015
"memory",
10001016
"verification"
1001-
]
1017+
],
1018+
"applicability": {
1019+
"use_when": [
1020+
"The agent maintains long-lived memo files or status documents that summarize external artifacts.",
1021+
"Workspace summaries are routinely cited in answers without re-reading the underlying files.",
1022+
"False confidence in stale state has been observed at least once."
1023+
],
1024+
"do_not_use_when": [
1025+
"The agent never re-cites its own prior memos as evidence.",
1026+
"All claims about state are sourced from a fresh tool call in the same tick anyway."
1027+
]
1028+
}
10021029
}
10031030
]
10041031
}

patterns-src/governance-observability.json

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -393,6 +393,26 @@
393393
{
394394
"pattern": "attention-manipulation-explainability",
395395
"relation": "complements"
396+
},
397+
{
398+
"pattern": "self-archaeology",
399+
"relation": "complements"
400+
},
401+
{
402+
"pattern": "memo-as-source-confusion",
403+
"relation": "complements"
404+
},
405+
{
406+
"pattern": "interrupt-resumable-thought",
407+
"relation": "complements"
408+
},
409+
{
410+
"pattern": "intra-agent-memo-scheduling",
411+
"relation": "complements"
412+
},
413+
{
414+
"pattern": "echo-recognition",
415+
"relation": "complements"
396416
}
397417
],
398418
"references": [
@@ -1088,6 +1108,18 @@
10881108
{
10891109
"pattern": "incident-response-runbook",
10901110
"relation": "used-by"
1111+
},
1112+
{
1113+
"pattern": "memo-as-source-confusion",
1114+
"relation": "complements"
1115+
},
1116+
{
1117+
"pattern": "emotional-state-persistence",
1118+
"relation": "used-by"
1119+
},
1120+
{
1121+
"pattern": "world-model-separation",
1122+
"relation": "complements"
10911123
}
10921124
],
10931125
"references": [

0 commit comments

Comments
 (0)