HCT Patterns Library
Diagnostic and Functional Patterns for Multi-Agent Systems
Diagnose why your agent swarm is failing and get drop-in solutions.
The Patterns Library translates the "Musical Ontology" of Harmonic Coordination Theory into practical, enterprise-ready diagnostic patterns.
Diagnostic Patterns
⏱️ Timing & Synchronization
| Symptom | Diagnosis | Pattern | Solution |
|---|---|---|---|
| Deadlock / Hanging | Stuck Fermata | Escalation Pattern | Add timeout with caesura fallback |
| Hallucination / Skipping | Rushing | Tempo Control | Chain-of-Verification gates |
| Analysis Paralysis | Dragging | Urgency Injection | Explicit urgency signals |
| Premature Action | False Entry | Upbeat Pattern | Barrier synchronization |
| Out-of-Order Results | Ensemble Tearing | Syncopation Pattern | A2A async handling |
🎼 Coherence & Quality
| Symptom | Diagnosis | Pattern | Solution |
|---|---|---|---|
| Agents contradict each other | Harmonic Clash | Shared Progressions | Define voice hierarchy |
| Same error repeats | Deaf Agent | Feedback Injection | Wire SVRL loop |
| Context mismatch | Dissonance | Tuning Pattern | Shared reference frame |
| Scope creep | Improvisation Drift | Score Compliance | Explicit constraints |
| Echo chamber | Sycophancy | Consensus Pattern | Multi-verifier debate |
🔊 Resource & Dynamics
| Symptom | Diagnosis | Pattern | Solution |
|---|---|---|---|
| Silent output | Ghost Notes | Pulse Pattern | Heartbeat monitoring |
| Budget explosion | Runaway Dynamic | Fade Out Pattern | Token budgets |
| Context overflow | Sectional Balance | Mixing Pattern | Context pruning |
| Inconsistent format | Uneven Phrasing | Legato Pattern | Style prompting |
| Wrong tool selection | Instrument Confusion | Orchestration Pattern | Tool filtering |
Functional Patterns
Human-in-the-Loop (Fermata)
Use Case: Pausing execution for human approval or input.
from hct_mcp_signals import fermata
# Pause for human review before publishing
hold = fermata(
source="report_agent",
reason="Ready for compliance review",
hold_type="human"
)
Status Streaming (Ostinato)
Use Case: Long-running task updates with repeating status signals.
# Stream progress during lengthy operations
for chunk in process_document(doc):
signal = ostinato("processor", progress=chunk.percent)
yield signal
How to Use
Each pattern includes:
- Symptom: How it looks in your logs
- Diagnosis: The HCT concept explaining the failure
- Solution: Python/pseudocode to fix it