Thread tracking, decision extraction, boot context generation, pre-compaction snapshots, structured narratives. - 10 source files, 1983 LOC TypeScript - 9 test files, 270 tests passing - Zero runtime dependencies - Cerberus approved + all findings fixed - EN/DE pattern matching, atomic file writes - Graceful degradation (read-only workspace, corrupt JSON)
154 lines
4.4 KiB
JSON
154 lines
4.4 KiB
JSON
{
|
|
"id": "openclaw-cortex",
|
|
"configSchema": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"enabled": {
|
|
"type": "boolean",
|
|
"default": true,
|
|
"description": "Enable/disable the cortex plugin entirely"
|
|
},
|
|
"workspace": {
|
|
"type": "string",
|
|
"default": "",
|
|
"description": "Workspace directory override. Empty = auto-detect from OpenClaw context."
|
|
},
|
|
"threadTracker": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"enabled": {
|
|
"type": "boolean",
|
|
"default": true,
|
|
"description": "Enable thread detection and tracking"
|
|
},
|
|
"pruneDays": {
|
|
"type": "integer",
|
|
"minimum": 1,
|
|
"maximum": 90,
|
|
"default": 7,
|
|
"description": "Auto-prune closed threads older than N days"
|
|
},
|
|
"maxThreads": {
|
|
"type": "integer",
|
|
"minimum": 5,
|
|
"maximum": 200,
|
|
"default": 50,
|
|
"description": "Maximum number of threads to retain"
|
|
}
|
|
}
|
|
},
|
|
"decisionTracker": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"enabled": {
|
|
"type": "boolean",
|
|
"default": true,
|
|
"description": "Enable decision extraction from messages"
|
|
},
|
|
"maxDecisions": {
|
|
"type": "integer",
|
|
"minimum": 10,
|
|
"maximum": 500,
|
|
"default": 100,
|
|
"description": "Maximum number of decisions to retain"
|
|
},
|
|
"dedupeWindowHours": {
|
|
"type": "integer",
|
|
"minimum": 1,
|
|
"maximum": 168,
|
|
"default": 24,
|
|
"description": "Skip decisions with identical 'what' within this window"
|
|
}
|
|
}
|
|
},
|
|
"bootContext": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"enabled": {
|
|
"type": "boolean",
|
|
"default": true,
|
|
"description": "Enable BOOTSTRAP.md generation"
|
|
},
|
|
"maxChars": {
|
|
"type": "integer",
|
|
"minimum": 2000,
|
|
"maximum": 64000,
|
|
"default": 16000,
|
|
"description": "Maximum character budget for BOOTSTRAP.md (~4 chars per token)"
|
|
},
|
|
"onSessionStart": {
|
|
"type": "boolean",
|
|
"default": true,
|
|
"description": "Generate BOOTSTRAP.md on session_start hook"
|
|
},
|
|
"maxThreadsInBoot": {
|
|
"type": "integer",
|
|
"minimum": 1,
|
|
"maximum": 20,
|
|
"default": 7,
|
|
"description": "Maximum number of threads to include in boot context"
|
|
},
|
|
"maxDecisionsInBoot": {
|
|
"type": "integer",
|
|
"minimum": 1,
|
|
"maximum": 30,
|
|
"default": 10,
|
|
"description": "Maximum number of recent decisions in boot context"
|
|
},
|
|
"decisionRecencyDays": {
|
|
"type": "integer",
|
|
"minimum": 1,
|
|
"maximum": 90,
|
|
"default": 14,
|
|
"description": "Include decisions from the last N days"
|
|
}
|
|
}
|
|
},
|
|
"preCompaction": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"enabled": {
|
|
"type": "boolean",
|
|
"default": true,
|
|
"description": "Enable pre-compaction snapshot pipeline"
|
|
},
|
|
"maxSnapshotMessages": {
|
|
"type": "integer",
|
|
"minimum": 5,
|
|
"maximum": 50,
|
|
"default": 15,
|
|
"description": "Maximum messages to include in hot snapshot"
|
|
}
|
|
}
|
|
},
|
|
"narrative": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"enabled": {
|
|
"type": "boolean",
|
|
"default": true,
|
|
"description": "Enable structured narrative generation"
|
|
}
|
|
}
|
|
},
|
|
"patterns": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"language": {
|
|
"type": "string",
|
|
"enum": ["en", "de", "both"],
|
|
"default": "both",
|
|
"description": "Language for regex pattern matching: English, German, or both"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|