swarmvault consolidate
Roll working-tier insight pages up into episodic, semantic, and procedural tiers.
Usage
swarmvault consolidate [--dry-run] [--json]Options
--dry-run- Return the consolidation decisions without writing any files--json- Emit structured JSON output
What It Does
consolidate reads the insight pages under wiki/insights/ and promotes them through four tiers. A page with no tier is treated as working, and pages that have been superseded are skipped.
- Working to episodic - groups working pages written within the same session window that share enough graph nodes, sources, and related nodes
- Episodic to semantic - promotes graph nodes that recur across enough episodic pages
- Semantic to procedural - promotes workflows that have enough recorded steps
New pages are written under wiki/insights/<tier>/. Each run returns a list of decisions, including the ones it skipped and why, so --dry-run shows exactly what a real run would change.
A normal swarmvault compile also runs this pass after it writes pages, unless the compile is staged for approval with --approve. Run consolidate directly when you want to see the decisions or apply them without a full compile.
Configuration
Thresholds live under consolidation in swarmvault.config.json. Every key is optional; these are the defaults:
{
"consolidation": {
"enabled": true,
"workingToEpisodic": {
"minPages": 3,
"sessionWindowHours": 24,
"minSharedNodeRatio": 0.3
},
"episodicToSemantic": {
"minOccurrences": 3
},
"semanticToProcedural": {
"minWorkflowSteps": 3
}
}
}Set "enabled": false to turn the pass off for both compile and consolidate.
Examples
swarmvault consolidate --dry-run
swarmvault consolidate
swarmvault lint --tiersRelated Commands
lint --tiersfilters lint output to consolidation-tier findings.schedulecan run aconsolidatetask on a timer.