@cleocode/core 2026.4.5 → 2026.4.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/discovery.d.ts +69 -0
- package/dist/discovery.d.ts.map +1 -0
- package/dist/index.d.ts +3 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1643 -2349
- package/dist/index.js.map +4 -4
- package/dist/init.d.ts +51 -0
- package/dist/init.d.ts.map +1 -1
- package/dist/internal.d.ts +9 -1
- package/dist/internal.d.ts.map +1 -1
- package/dist/lifecycle/default-chain.d.ts +8 -2
- package/dist/lifecycle/default-chain.d.ts.map +1 -1
- package/dist/lifecycle/index.d.ts +1 -0
- package/dist/lifecycle/index.d.ts.map +1 -1
- package/dist/lifecycle/stage-guidance.d.ts +140 -0
- package/dist/lifecycle/stage-guidance.d.ts.map +1 -0
- package/dist/orchestration/protocol-validators.d.ts +122 -3
- package/dist/orchestration/protocol-validators.d.ts.map +1 -1
- package/dist/paths.d.ts +91 -0
- package/dist/paths.d.ts.map +1 -1
- package/dist/scaffold.d.ts +31 -1
- package/dist/scaffold.d.ts.map +1 -1
- package/dist/skills/dispatch.d.ts +1 -1
- package/dist/skills/skill-paths.d.ts +9 -6
- package/dist/skills/skill-paths.d.ts.map +1 -1
- package/dist/validation/protocols/_shared.d.ts +40 -0
- package/dist/validation/protocols/_shared.d.ts.map +1 -0
- package/dist/validation/protocols/architecture-decision.d.ts +23 -0
- package/dist/validation/protocols/architecture-decision.d.ts.map +1 -0
- package/dist/validation/protocols/artifact-publish.d.ts +22 -0
- package/dist/validation/protocols/artifact-publish.d.ts.map +1 -0
- package/dist/validation/protocols/consensus.d.ts +11 -17
- package/dist/validation/protocols/consensus.d.ts.map +1 -1
- package/dist/validation/protocols/contribution.d.ts +12 -17
- package/dist/validation/protocols/contribution.d.ts.map +1 -1
- package/dist/validation/protocols/decomposition.d.ts +18 -21
- package/dist/validation/protocols/decomposition.d.ts.map +1 -1
- package/dist/validation/protocols/implementation.d.ts +9 -17
- package/dist/validation/protocols/implementation.d.ts.map +1 -1
- package/dist/validation/protocols/provenance.d.ts +23 -0
- package/dist/validation/protocols/provenance.d.ts.map +1 -0
- package/dist/validation/protocols/release.d.ts +25 -0
- package/dist/validation/protocols/release.d.ts.map +1 -0
- package/dist/validation/protocols/research.d.ts +9 -17
- package/dist/validation/protocols/research.d.ts.map +1 -1
- package/dist/validation/protocols/specification.d.ts +7 -17
- package/dist/validation/protocols/specification.d.ts.map +1 -1
- package/dist/validation/protocols/testing.d.ts +22 -0
- package/dist/validation/protocols/testing.d.ts.map +1 -0
- package/dist/validation/protocols/validation.d.ts +22 -0
- package/dist/validation/protocols/validation.d.ts.map +1 -0
- package/package.json +7 -7
- package/src/__tests__/injection-mvi-tiers.test.js +54 -90
- package/src/__tests__/injection-mvi-tiers.test.js.map +1 -1
- package/src/discovery.ts +235 -0
- package/src/hooks/handlers/__tests__/hook-automation-e2e.test.js +3 -1
- package/src/hooks/handlers/__tests__/hook-automation-e2e.test.js.map +1 -1
- package/src/index.ts +16 -0
- package/src/init.ts +196 -0
- package/src/internal.ts +31 -1
- package/src/lifecycle/default-chain.ts +11 -2
- package/src/lifecycle/index.ts +10 -0
- package/src/lifecycle/stage-guidance.ts +282 -0
- package/src/metrics/__tests__/provider-detection.test.js +19 -7
- package/src/metrics/__tests__/provider-detection.test.js.map +1 -1
- package/src/orchestration/__tests__/protocol-validators.test.js +228 -8
- package/src/orchestration/__tests__/protocol-validators.test.js.map +1 -1
- package/src/orchestration/__tests__/protocol-validators.test.ts +259 -7
- package/src/orchestration/protocol-validators.ts +419 -4
- package/src/paths.ts +110 -0
- package/src/scaffold.ts +240 -4
- package/src/skills/dispatch.ts +6 -6
- package/src/skills/skill-paths.ts +27 -23
- package/src/validation/protocols/_shared.ts +88 -0
- package/src/validation/protocols/architecture-decision.ts +52 -0
- package/src/validation/protocols/artifact-publish.ts +49 -0
- package/src/validation/protocols/consensus.ts +44 -74
- package/src/validation/protocols/contribution.ts +28 -65
- package/src/validation/protocols/decomposition.ts +37 -64
- package/src/validation/protocols/implementation.ts +25 -65
- package/src/validation/protocols/protocols-markdown/architecture-decision.md +303 -0
- package/src/validation/protocols/protocols-markdown/artifact-publish.md +600 -0
- package/src/validation/protocols/protocols-markdown/consensus.md +322 -0
- package/src/validation/protocols/protocols-markdown/contribution.md +388 -0
- package/src/validation/protocols/protocols-markdown/decomposition.md +421 -0
- package/src/validation/protocols/protocols-markdown/implementation.md +357 -0
- package/src/validation/protocols/protocols-markdown/provenance.md +613 -0
- package/src/validation/protocols/protocols-markdown/release.md +783 -0
- package/src/validation/protocols/protocols-markdown/research.md +261 -0
- package/src/validation/protocols/protocols-markdown/specification.md +300 -0
- package/src/validation/protocols/protocols-markdown/testing.md +287 -0
- package/src/validation/protocols/protocols-markdown/validation.md +242 -0
- package/src/validation/protocols/provenance.ts +50 -0
- package/src/validation/protocols/release.ts +44 -0
- package/src/validation/protocols/research.ts +25 -87
- package/src/validation/protocols/specification.ts +27 -89
- package/src/validation/protocols/testing.ts +46 -0
- package/src/validation/protocols/validation.ts +46 -0
- package/dist/validation/protocols/release-protocol.d.ts +0 -27
- package/dist/validation/protocols/release-protocol.d.ts.map +0 -1
- package/dist/validation/protocols/testing-protocol.d.ts +0 -27
- package/dist/validation/protocols/testing-protocol.d.ts.map +0 -1
- package/dist/validation/protocols/validation-protocol.d.ts +0 -27
- package/dist/validation/protocols/validation-protocol.d.ts.map +0 -1
- package/schemas/agent-configs.schema.json +0 -120
- package/schemas/agent-registry.schema.json +0 -132
- package/schemas/archive.schema.json +0 -450
- package/schemas/brain-decision.schema.json +0 -69
- package/schemas/brain-learning.schema.json +0 -57
- package/schemas/brain-pattern.schema.json +0 -72
- package/schemas/critical-path.schema.json +0 -246
- package/schemas/deps-cache.schema.json +0 -97
- package/schemas/doctor-output.schema.json +0 -283
- package/schemas/error.schema.json +0 -161
- package/schemas/global-config.schema.json +0 -219
- package/schemas/grade.schema.json +0 -49
- package/schemas/log.schema.json +0 -250
- package/schemas/metrics.schema.json +0 -328
- package/schemas/migrations.schema.json +0 -150
- package/schemas/nexus-registry.schema.json +0 -90
- package/schemas/operation-constitution.schema.json +0 -438
- package/schemas/output.schema.json +0 -164
- package/schemas/projects-registry.schema.json +0 -107
- package/schemas/protocol-frontmatter.schema.json +0 -72
- package/schemas/rcasd-consensus-report.schema.json +0 -10
- package/schemas/rcasd-evidence.schema.json +0 -42
- package/schemas/rcasd-gate-result.schema.json +0 -46
- package/schemas/rcasd-hitl-resolution.schema.json +0 -10
- package/schemas/rcasd-index.schema.json +0 -10
- package/schemas/rcasd-manifest.schema.json +0 -10
- package/schemas/rcasd-research-output.schema.json +0 -10
- package/schemas/rcasd-spec-frontmatter.schema.json +0 -10
- package/schemas/rcasd-stage-transition.schema.json +0 -38
- package/schemas/releases.schema.json +0 -267
- package/schemas/skills-manifest.schema.json +0 -91
- package/schemas/spec-index.schema.json +0 -196
- package/schemas/system-flow-atlas.schema.json +0 -125
- package/src/conduit/__tests__/dual-api-e2e.test.d.ts.map +0 -1
- package/src/conduit/__tests__/dual-api-e2e.test.js +0 -178
- package/src/conduit/__tests__/dual-api-e2e.test.js.map +0 -1
- package/src/conduit/__tests__/dual-api-e2e.test.ts +0 -212
- package/src/validation/protocols/release-protocol.ts +0 -80
- package/src/validation/protocols/testing-protocol.ts +0 -93
- package/src/validation/protocols/validation-protocol.ts +0 -93
|
@@ -1,150 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
-
"$id": "https://cleo-dev.com/schemas/v1/migrations.schema.json",
|
|
4
|
-
"schemaVersion": "1.0.0",
|
|
5
|
-
"title": "CLEO Migration Journal Schema",
|
|
6
|
-
"description": "Audit trail of schema migration operations. Tracks applied migrations with checksums and execution metadata for data integrity verification.",
|
|
7
|
-
"type": "object",
|
|
8
|
-
"required": [
|
|
9
|
-
"_meta",
|
|
10
|
-
"appliedMigrations"
|
|
11
|
-
],
|
|
12
|
-
"additionalProperties": false,
|
|
13
|
-
"properties": {
|
|
14
|
-
"_meta": {
|
|
15
|
-
"type": "object",
|
|
16
|
-
"required": [
|
|
17
|
-
"schemaVersion"
|
|
18
|
-
],
|
|
19
|
-
"additionalProperties": false,
|
|
20
|
-
"properties": {
|
|
21
|
-
"schemaVersion": {
|
|
22
|
-
"type": "string",
|
|
23
|
-
"pattern": "^\\d+\\.\\d+\\.\\d+$",
|
|
24
|
-
"description": "Schema version for this migrations journal (semver)."
|
|
25
|
-
},
|
|
26
|
-
"lastChecked": {
|
|
27
|
-
"type": [
|
|
28
|
-
"string",
|
|
29
|
-
"null"
|
|
30
|
-
],
|
|
31
|
-
"format": "date-time",
|
|
32
|
-
"description": "Last time migration status was checked."
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
},
|
|
36
|
-
"appliedMigrations": {
|
|
37
|
-
"type": "array",
|
|
38
|
-
"description": "Chronologically ordered list of applied migrations. Append-only for audit trail.",
|
|
39
|
-
"items": {
|
|
40
|
-
"$ref": "#/definitions/migrationEntry"
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
},
|
|
44
|
-
"definitions": {
|
|
45
|
-
"migrationEntry": {
|
|
46
|
-
"type": "object",
|
|
47
|
-
"required": [
|
|
48
|
-
"version",
|
|
49
|
-
"fileType",
|
|
50
|
-
"checksum",
|
|
51
|
-
"appliedAt",
|
|
52
|
-
"status"
|
|
53
|
-
],
|
|
54
|
-
"additionalProperties": false,
|
|
55
|
-
"properties": {
|
|
56
|
-
"version": {
|
|
57
|
-
"type": "string",
|
|
58
|
-
"pattern": "^\\d+\\.\\d+\\.\\d+$",
|
|
59
|
-
"description": "Target schema version of this migration (semver)."
|
|
60
|
-
},
|
|
61
|
-
"fileType": {
|
|
62
|
-
"type": "string",
|
|
63
|
-
"enum": [
|
|
64
|
-
"todo",
|
|
65
|
-
"config",
|
|
66
|
-
"archive",
|
|
67
|
-
"log",
|
|
68
|
-
"sessions",
|
|
69
|
-
"migrations"
|
|
70
|
-
],
|
|
71
|
-
"description": "Type of file that was migrated."
|
|
72
|
-
},
|
|
73
|
-
"functionName": {
|
|
74
|
-
"type": [
|
|
75
|
-
"string",
|
|
76
|
-
"null"
|
|
77
|
-
],
|
|
78
|
-
"description": "Migration function name that was executed (e.g., 'migrate_todo_to_2_3_0'). Null for version-bump-only migrations."
|
|
79
|
-
},
|
|
80
|
-
"checksum": {
|
|
81
|
-
"type": "string",
|
|
82
|
-
"pattern": "^[a-f0-9]{64}$",
|
|
83
|
-
"description": "SHA256 checksum of the migration function source code (for verification)."
|
|
84
|
-
},
|
|
85
|
-
"appliedAt": {
|
|
86
|
-
"type": "string",
|
|
87
|
-
"format": "date-time",
|
|
88
|
-
"description": "When this migration was executed (UTC)."
|
|
89
|
-
},
|
|
90
|
-
"status": {
|
|
91
|
-
"type": "string",
|
|
92
|
-
"enum": [
|
|
93
|
-
"success",
|
|
94
|
-
"failed",
|
|
95
|
-
"skipped"
|
|
96
|
-
],
|
|
97
|
-
"description": "Outcome of the migration operation."
|
|
98
|
-
},
|
|
99
|
-
"executionTimeMs": {
|
|
100
|
-
"type": [
|
|
101
|
-
"integer",
|
|
102
|
-
"null"
|
|
103
|
-
],
|
|
104
|
-
"minimum": 0,
|
|
105
|
-
"description": "Time taken to execute migration in milliseconds."
|
|
106
|
-
},
|
|
107
|
-
"previousVersion": {
|
|
108
|
-
"type": [
|
|
109
|
-
"string",
|
|
110
|
-
"null"
|
|
111
|
-
],
|
|
112
|
-
"pattern": "^\\d+\\.\\d+\\.\\d+$",
|
|
113
|
-
"description": "Schema version before this migration was applied."
|
|
114
|
-
},
|
|
115
|
-
"logs": {
|
|
116
|
-
"type": "array",
|
|
117
|
-
"description": "Log messages generated during migration execution.",
|
|
118
|
-
"items": {
|
|
119
|
-
"type": "string"
|
|
120
|
-
}
|
|
121
|
-
},
|
|
122
|
-
"backupPath": {
|
|
123
|
-
"type": [
|
|
124
|
-
"string",
|
|
125
|
-
"null"
|
|
126
|
-
],
|
|
127
|
-
"description": "Path to backup created before migration (for rollback)."
|
|
128
|
-
},
|
|
129
|
-
"error": {
|
|
130
|
-
"type": [
|
|
131
|
-
"object",
|
|
132
|
-
"null"
|
|
133
|
-
],
|
|
134
|
-
"description": "Error details if migration failed.",
|
|
135
|
-
"properties": {
|
|
136
|
-
"code": {
|
|
137
|
-
"type": "string"
|
|
138
|
-
},
|
|
139
|
-
"message": {
|
|
140
|
-
"type": "string"
|
|
141
|
-
},
|
|
142
|
-
"recoverable": {
|
|
143
|
-
"type": "boolean"
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
|
-
}
|
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
-
"$id": "https://cleo-dev.com/schemas/v1/nexus-registry.schema.json",
|
|
4
|
-
"title": "CLEO Nexus Registry Schema (DEPRECATED)",
|
|
5
|
-
"description": "DEPRECATED: This schema is no longer used. nexus.db (SQLite) is the live backend as of 2026.3. Legacy JSON (projects-registry.json) is auto-migrated on first nexus init. Retained for historical reference only.",
|
|
6
|
-
"type": "object",
|
|
7
|
-
"required": ["version", "lastUpdated", "projects"],
|
|
8
|
-
"additionalProperties": false,
|
|
9
|
-
"properties": {
|
|
10
|
-
"$schema": {
|
|
11
|
-
"type": "string",
|
|
12
|
-
"description": "JSON Schema reference for validation."
|
|
13
|
-
},
|
|
14
|
-
"version": {
|
|
15
|
-
"type": "string",
|
|
16
|
-
"pattern": "^\\d+\\.\\d+\\.\\d+$",
|
|
17
|
-
"description": "Schema version (semver). MUST match semantic versioning."
|
|
18
|
-
},
|
|
19
|
-
"lastUpdated": {
|
|
20
|
-
"type": "string",
|
|
21
|
-
"format": "date-time",
|
|
22
|
-
"description": "ISO 8601 timestamp of last registry modification."
|
|
23
|
-
},
|
|
24
|
-
"projects": {
|
|
25
|
-
"type": "object",
|
|
26
|
-
"description": "Map of project_hash → project metadata. Keyed by 12-character hexadecimal hash.",
|
|
27
|
-
"patternProperties": {
|
|
28
|
-
"^[a-f0-9]{12}$": {
|
|
29
|
-
"$ref": "#/definitions/project"
|
|
30
|
-
}
|
|
31
|
-
},
|
|
32
|
-
"additionalProperties": false
|
|
33
|
-
}
|
|
34
|
-
},
|
|
35
|
-
"definitions": {
|
|
36
|
-
"project": {
|
|
37
|
-
"type": "object",
|
|
38
|
-
"description": "A registered CLEO project with metadata and access timestamps.",
|
|
39
|
-
"required": ["hash", "path", "name", "lastAccess"],
|
|
40
|
-
"additionalProperties": false,
|
|
41
|
-
"properties": {
|
|
42
|
-
"hash": {
|
|
43
|
-
"type": "string",
|
|
44
|
-
"pattern": "^[a-f0-9]{12}$",
|
|
45
|
-
"description": "12-character hexadecimal identifier. MUST match object key. Generated via generate_project_hash() (stable SHA256 of path)."
|
|
46
|
-
},
|
|
47
|
-
"path": {
|
|
48
|
-
"type": "string",
|
|
49
|
-
"minLength": 1,
|
|
50
|
-
"description": "Absolute filesystem path to project root. MUST contain .cleo/todo.json to be valid."
|
|
51
|
-
},
|
|
52
|
-
"name": {
|
|
53
|
-
"type": "string",
|
|
54
|
-
"pattern": "^[a-z0-9][a-z0-9-]*[a-z0-9]$|^[a-z0-9]$",
|
|
55
|
-
"minLength": 1,
|
|
56
|
-
"maxLength": 64,
|
|
57
|
-
"description": "Human-readable project identifier. MUST be unique across all registered projects. Lowercase with hyphens allowed."
|
|
58
|
-
},
|
|
59
|
-
"aliases": {
|
|
60
|
-
"type": "array",
|
|
61
|
-
"items": {
|
|
62
|
-
"type": "string",
|
|
63
|
-
"pattern": "^[a-z0-9][a-z0-9-]*[a-z0-9]$|^[a-z0-9]$",
|
|
64
|
-
"minLength": 1,
|
|
65
|
-
"maxLength": 32
|
|
66
|
-
},
|
|
67
|
-
"uniqueItems": true,
|
|
68
|
-
"default": [],
|
|
69
|
-
"description": "Alternative names for project resolution. MUST NOT conflict with any project names."
|
|
70
|
-
},
|
|
71
|
-
"lastAccess": {
|
|
72
|
-
"type": "string",
|
|
73
|
-
"format": "date-time",
|
|
74
|
-
"description": "ISO 8601 timestamp of last read operation. Used for pruning inactive projects."
|
|
75
|
-
},
|
|
76
|
-
"taskCount": {
|
|
77
|
-
"type": "integer",
|
|
78
|
-
"minimum": 0,
|
|
79
|
-
"default": 0,
|
|
80
|
-
"description": "Number of tasks in project. Cached for quick reference."
|
|
81
|
-
},
|
|
82
|
-
"checksum": {
|
|
83
|
-
"type": "string",
|
|
84
|
-
"pattern": "^[a-f0-9]{16}$",
|
|
85
|
-
"description": "SHA-256 truncated hash of project's todo.json tasks array. Used for cache invalidation."
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
}
|
|
@@ -1,438 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
-
"title": "CLEO Operation Constitution",
|
|
4
|
-
"description": "Validates the complete CLEO Operation Constitution document including the full registry, gateway matrices, and domain tables",
|
|
5
|
-
"type": "object",
|
|
6
|
-
"required": ["schemaVersion", "metadata", "registry", "gateways", "domains"],
|
|
7
|
-
"additionalProperties": false,
|
|
8
|
-
"definitions": {
|
|
9
|
-
"Gateway": {
|
|
10
|
-
"type": "string",
|
|
11
|
-
"enum": ["query", "mutate"],
|
|
12
|
-
"description": "CQRS gateway: read-only queries or state-changing mutations"
|
|
13
|
-
},
|
|
14
|
-
"CanonicalDomain": {
|
|
15
|
-
"type": "string",
|
|
16
|
-
"enum": ["tasks", "session", "memory", "check", "pipeline", "orchestrate", "tools", "admin", "nexus", "sticky"],
|
|
17
|
-
"description": "One of 10 canonical CLEO domains"
|
|
18
|
-
},
|
|
19
|
-
"Tier": {
|
|
20
|
-
"type": "integer",
|
|
21
|
-
"enum": [0, 1, 2],
|
|
22
|
-
"description": "Progressive disclosure tier: 0=basic, 1=extended, 2=full"
|
|
23
|
-
},
|
|
24
|
-
"ParamDef": {
|
|
25
|
-
"type": "object",
|
|
26
|
-
"required": ["name", "type", "required", "description"],
|
|
27
|
-
"properties": {
|
|
28
|
-
"name": {
|
|
29
|
-
"type": "string",
|
|
30
|
-
"pattern": "^[a-zA-Z][a-zA-Z0-9]*$",
|
|
31
|
-
"description": "Canonical camelCase parameter name"
|
|
32
|
-
},
|
|
33
|
-
"type": {
|
|
34
|
-
"type": "string",
|
|
35
|
-
"enum": ["string", "number", "boolean", "array"],
|
|
36
|
-
"description": "Runtime value type"
|
|
37
|
-
},
|
|
38
|
-
"required": {
|
|
39
|
-
"type": "boolean",
|
|
40
|
-
"description": "Whether parameter is required"
|
|
41
|
-
},
|
|
42
|
-
"description": {
|
|
43
|
-
"type": "string",
|
|
44
|
-
"minLength": 1,
|
|
45
|
-
"description": "Human-readable description"
|
|
46
|
-
},
|
|
47
|
-
"cli": {
|
|
48
|
-
"type": "object",
|
|
49
|
-
"properties": {
|
|
50
|
-
"positional": { "type": "boolean" },
|
|
51
|
-
"short": { "type": "string", "pattern": "^-[a-zA-Z]$" },
|
|
52
|
-
"flag": { "type": "string" },
|
|
53
|
-
"variadic": { "type": "boolean" }
|
|
54
|
-
},
|
|
55
|
-
"additionalProperties": false
|
|
56
|
-
},
|
|
57
|
-
"mcp": {
|
|
58
|
-
"type": "object",
|
|
59
|
-
"properties": {
|
|
60
|
-
"hidden": { "type": "boolean" },
|
|
61
|
-
"enum": {
|
|
62
|
-
"type": "array",
|
|
63
|
-
"items": { "type": "string" }
|
|
64
|
-
}
|
|
65
|
-
},
|
|
66
|
-
"additionalProperties": false
|
|
67
|
-
}
|
|
68
|
-
},
|
|
69
|
-
"additionalProperties": false
|
|
70
|
-
},
|
|
71
|
-
"OperationDef": {
|
|
72
|
-
"type": "object",
|
|
73
|
-
"required": ["gateway", "domain", "operation", "description", "tier", "idempotent", "sessionRequired", "requiredParams"],
|
|
74
|
-
"properties": {
|
|
75
|
-
"gateway": { "$ref": "#/definitions/Gateway" },
|
|
76
|
-
"domain": { "$ref": "#/definitions/CanonicalDomain" },
|
|
77
|
-
"operation": {
|
|
78
|
-
"type": "string",
|
|
79
|
-
"pattern": "^[a-z][a-z0-9]*(\\.[a-z][a-z0-9]*)*$",
|
|
80
|
-
"description": "Dot-notation operation name (e.g. 'show', 'stage.validate')"
|
|
81
|
-
},
|
|
82
|
-
"description": {
|
|
83
|
-
"type": "string",
|
|
84
|
-
"minLength": 1,
|
|
85
|
-
"description": "Brief human-readable description of the operation"
|
|
86
|
-
},
|
|
87
|
-
"tier": { "$ref": "#/definitions/Tier" },
|
|
88
|
-
"idempotent": {
|
|
89
|
-
"type": "boolean",
|
|
90
|
-
"description": "Whether the operation is safe to retry without side effects"
|
|
91
|
-
},
|
|
92
|
-
"sessionRequired": {
|
|
93
|
-
"type": "boolean",
|
|
94
|
-
"description": "Whether the operation requires an active session"
|
|
95
|
-
},
|
|
96
|
-
"requiredParams": {
|
|
97
|
-
"type": "array",
|
|
98
|
-
"items": {
|
|
99
|
-
"type": "string",
|
|
100
|
-
"pattern": "^[a-zA-Z][a-zA-Z0-9]*$"
|
|
101
|
-
},
|
|
102
|
-
"description": "Parameter keys that MUST be present in the request"
|
|
103
|
-
},
|
|
104
|
-
"params": {
|
|
105
|
-
"type": "array",
|
|
106
|
-
"items": { "$ref": "#/definitions/ParamDef" },
|
|
107
|
-
"description": "Full parameter descriptors (optional, replaces requiredParams when populated)"
|
|
108
|
-
},
|
|
109
|
-
"aliases": {
|
|
110
|
-
"type": "array",
|
|
111
|
-
"items": {
|
|
112
|
-
"type": "string",
|
|
113
|
-
"pattern": "^[a-z][a-z0-9]*(\\.[a-z][a-z0-9]*)*$"
|
|
114
|
-
},
|
|
115
|
-
"description": "Backward-compatible operation name aliases"
|
|
116
|
-
}
|
|
117
|
-
},
|
|
118
|
-
"additionalProperties": false
|
|
119
|
-
}
|
|
120
|
-
},
|
|
121
|
-
"properties": {
|
|
122
|
-
"schemaVersion": {
|
|
123
|
-
"type": "string",
|
|
124
|
-
"pattern": "^\\d{4}\\.\\d+\\.\\d+$",
|
|
125
|
-
"description": "Constitution schema version (e.g. '2026.3.3')"
|
|
126
|
-
},
|
|
127
|
-
"metadata": {
|
|
128
|
-
"type": "object",
|
|
129
|
-
"required": ["version", "status", "date", "totalOperations", "gateways", "domains"],
|
|
130
|
-
"additionalProperties": false,
|
|
131
|
-
"properties": {
|
|
132
|
-
"version": {
|
|
133
|
-
"type": "string",
|
|
134
|
-
"description": "Constitution document version"
|
|
135
|
-
},
|
|
136
|
-
"status": {
|
|
137
|
-
"type": "string",
|
|
138
|
-
"enum": ["DRAFT", "APPROVED", "DEPRECATED"],
|
|
139
|
-
"description": "Constitution approval status"
|
|
140
|
-
},
|
|
141
|
-
"date": {
|
|
142
|
-
"type": "string",
|
|
143
|
-
"format": "date",
|
|
144
|
-
"description": "Constitution approval date (ISO 8601)"
|
|
145
|
-
},
|
|
146
|
-
"task": {
|
|
147
|
-
"type": "string",
|
|
148
|
-
"pattern": "^T\\d+$",
|
|
149
|
-
"description": "Associated task ID (e.g. 'T5241')"
|
|
150
|
-
},
|
|
151
|
-
"supersedes": {
|
|
152
|
-
"type": "string",
|
|
153
|
-
"description": "Document this constitution supersedes"
|
|
154
|
-
},
|
|
155
|
-
"totalOperations": {
|
|
156
|
-
"type": "integer",
|
|
157
|
-
"minimum": 1,
|
|
158
|
-
"description": "Total number of operations in registry"
|
|
159
|
-
},
|
|
160
|
-
"gateways": {
|
|
161
|
-
"type": "object",
|
|
162
|
-
"required": ["query", "mutate"],
|
|
163
|
-
"additionalProperties": false,
|
|
164
|
-
"properties": {
|
|
165
|
-
"query": {
|
|
166
|
-
"type": "integer",
|
|
167
|
-
"minimum": 0,
|
|
168
|
-
"description": "Number of query operations"
|
|
169
|
-
},
|
|
170
|
-
"mutate": {
|
|
171
|
-
"type": "integer",
|
|
172
|
-
"minimum": 0,
|
|
173
|
-
"description": "Number of mutate operations"
|
|
174
|
-
}
|
|
175
|
-
}
|
|
176
|
-
},
|
|
177
|
-
"domains": {
|
|
178
|
-
"type": "object",
|
|
179
|
-
"required": ["count", "names"],
|
|
180
|
-
"additionalProperties": false,
|
|
181
|
-
"properties": {
|
|
182
|
-
"count": {
|
|
183
|
-
"type": "integer",
|
|
184
|
-
"minimum": 1,
|
|
185
|
-
"maximum": 10,
|
|
186
|
-
"description": "Number of canonical domains"
|
|
187
|
-
},
|
|
188
|
-
"names": {
|
|
189
|
-
"type": "array",
|
|
190
|
-
"items": { "$ref": "#/definitions/CanonicalDomain" },
|
|
191
|
-
"minItems": 10,
|
|
192
|
-
"maxItems": 10,
|
|
193
|
-
"description": "List of all canonical domain names"
|
|
194
|
-
}
|
|
195
|
-
}
|
|
196
|
-
}
|
|
197
|
-
}
|
|
198
|
-
},
|
|
199
|
-
"registry": {
|
|
200
|
-
"type": "object",
|
|
201
|
-
"required": ["operations"],
|
|
202
|
-
"additionalProperties": false,
|
|
203
|
-
"properties": {
|
|
204
|
-
"operations": {
|
|
205
|
-
"type": "array",
|
|
206
|
-
"items": { "$ref": "#/definitions/OperationDef" },
|
|
207
|
-
"minItems": 1,
|
|
208
|
-
"description": "All 207 operations in the registry"
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
},
|
|
212
|
-
"gateways": {
|
|
213
|
-
"type": "object",
|
|
214
|
-
"required": ["query", "mutate"],
|
|
215
|
-
"additionalProperties": false,
|
|
216
|
-
"properties": {
|
|
217
|
-
"query": {
|
|
218
|
-
"type": "object",
|
|
219
|
-
"required": ["matrix", "operations"],
|
|
220
|
-
"additionalProperties": false,
|
|
221
|
-
"properties": {
|
|
222
|
-
"matrix": {
|
|
223
|
-
"type": "object",
|
|
224
|
-
"description": "Query gateway matrix: domain -> operations[]",
|
|
225
|
-
"patternProperties": {
|
|
226
|
-
"^(tasks|session|memory|check|pipeline|orchestrate|tools|admin|nexus|sticky)$": {
|
|
227
|
-
"type": "array",
|
|
228
|
-
"items": {
|
|
229
|
-
"type": "string",
|
|
230
|
-
"pattern": "^[a-z][a-z0-9]*(\\.[a-z][a-z0-9]*)*$"
|
|
231
|
-
}
|
|
232
|
-
}
|
|
233
|
-
},
|
|
234
|
-
"additionalProperties": false
|
|
235
|
-
},
|
|
236
|
-
"operations": {
|
|
237
|
-
"type": "array",
|
|
238
|
-
"items": { "$ref": "#/definitions/OperationDef" },
|
|
239
|
-
"description": "All query operations"
|
|
240
|
-
}
|
|
241
|
-
}
|
|
242
|
-
},
|
|
243
|
-
"mutate": {
|
|
244
|
-
"type": "object",
|
|
245
|
-
"required": ["matrix", "operations"],
|
|
246
|
-
"additionalProperties": false,
|
|
247
|
-
"properties": {
|
|
248
|
-
"matrix": {
|
|
249
|
-
"type": "object",
|
|
250
|
-
"description": "Mutate gateway matrix: domain -> operations[]",
|
|
251
|
-
"patternProperties": {
|
|
252
|
-
"^(tasks|session|memory|check|pipeline|orchestrate|tools|admin|nexus|sticky)$": {
|
|
253
|
-
"type": "array",
|
|
254
|
-
"items": {
|
|
255
|
-
"type": "string",
|
|
256
|
-
"pattern": "^[a-z][a-z0-9]*(\\.[a-z][a-z0-9]*)*$"
|
|
257
|
-
}
|
|
258
|
-
}
|
|
259
|
-
},
|
|
260
|
-
"additionalProperties": false
|
|
261
|
-
},
|
|
262
|
-
"operations": {
|
|
263
|
-
"type": "array",
|
|
264
|
-
"items": { "$ref": "#/definitions/OperationDef" },
|
|
265
|
-
"description": "All mutate operations"
|
|
266
|
-
}
|
|
267
|
-
}
|
|
268
|
-
}
|
|
269
|
-
}
|
|
270
|
-
},
|
|
271
|
-
"domains": {
|
|
272
|
-
"type": "object",
|
|
273
|
-
"description": "Domain tables: operations grouped by domain",
|
|
274
|
-
"required": ["tasks", "session", "memory", "check", "pipeline", "orchestrate", "tools", "admin", "nexus", "sticky"],
|
|
275
|
-
"additionalProperties": false,
|
|
276
|
-
"properties": {
|
|
277
|
-
"tasks": {
|
|
278
|
-
"type": "object",
|
|
279
|
-
"required": ["name", "purpose", "operations"],
|
|
280
|
-
"properties": {
|
|
281
|
-
"name": { "const": "tasks" },
|
|
282
|
-
"purpose": { "type": "string" },
|
|
283
|
-
"primaryStore": { "type": "string" },
|
|
284
|
-
"operations": {
|
|
285
|
-
"type": "array",
|
|
286
|
-
"items": { "$ref": "#/definitions/OperationDef" }
|
|
287
|
-
}
|
|
288
|
-
}
|
|
289
|
-
},
|
|
290
|
-
"session": {
|
|
291
|
-
"type": "object",
|
|
292
|
-
"required": ["name", "purpose", "operations"],
|
|
293
|
-
"properties": {
|
|
294
|
-
"name": { "const": "session" },
|
|
295
|
-
"purpose": { "type": "string" },
|
|
296
|
-
"primaryStore": { "type": "string" },
|
|
297
|
-
"operations": {
|
|
298
|
-
"type": "array",
|
|
299
|
-
"items": { "$ref": "#/definitions/OperationDef" }
|
|
300
|
-
}
|
|
301
|
-
}
|
|
302
|
-
},
|
|
303
|
-
"memory": {
|
|
304
|
-
"type": "object",
|
|
305
|
-
"required": ["name", "purpose", "operations"],
|
|
306
|
-
"properties": {
|
|
307
|
-
"name": { "const": "memory" },
|
|
308
|
-
"purpose": { "type": "string" },
|
|
309
|
-
"primaryStore": { "type": "string" },
|
|
310
|
-
"operations": {
|
|
311
|
-
"type": "array",
|
|
312
|
-
"items": { "$ref": "#/definitions/OperationDef" }
|
|
313
|
-
}
|
|
314
|
-
}
|
|
315
|
-
},
|
|
316
|
-
"check": {
|
|
317
|
-
"type": "object",
|
|
318
|
-
"required": ["name", "purpose", "operations"],
|
|
319
|
-
"properties": {
|
|
320
|
-
"name": { "const": "check" },
|
|
321
|
-
"purpose": { "type": "string" },
|
|
322
|
-
"primaryStore": { "type": "string" },
|
|
323
|
-
"operations": {
|
|
324
|
-
"type": "array",
|
|
325
|
-
"items": { "$ref": "#/definitions/OperationDef" }
|
|
326
|
-
}
|
|
327
|
-
}
|
|
328
|
-
},
|
|
329
|
-
"pipeline": {
|
|
330
|
-
"type": "object",
|
|
331
|
-
"required": ["name", "purpose", "operations"],
|
|
332
|
-
"properties": {
|
|
333
|
-
"name": { "const": "pipeline" },
|
|
334
|
-
"purpose": { "type": "string" },
|
|
335
|
-
"primaryStore": { "type": "string" },
|
|
336
|
-
"operations": {
|
|
337
|
-
"type": "array",
|
|
338
|
-
"items": { "$ref": "#/definitions/OperationDef" }
|
|
339
|
-
}
|
|
340
|
-
}
|
|
341
|
-
},
|
|
342
|
-
"orchestrate": {
|
|
343
|
-
"type": "object",
|
|
344
|
-
"required": ["name", "purpose", "operations"],
|
|
345
|
-
"properties": {
|
|
346
|
-
"name": { "const": "orchestrate" },
|
|
347
|
-
"purpose": { "type": "string" },
|
|
348
|
-
"primaryStore": { "type": "string" },
|
|
349
|
-
"operations": {
|
|
350
|
-
"type": "array",
|
|
351
|
-
"items": { "$ref": "#/definitions/OperationDef" }
|
|
352
|
-
}
|
|
353
|
-
}
|
|
354
|
-
},
|
|
355
|
-
"tools": {
|
|
356
|
-
"type": "object",
|
|
357
|
-
"required": ["name", "purpose", "operations"],
|
|
358
|
-
"properties": {
|
|
359
|
-
"name": { "const": "tools" },
|
|
360
|
-
"purpose": { "type": "string" },
|
|
361
|
-
"primaryStore": { "type": "string" },
|
|
362
|
-
"operations": {
|
|
363
|
-
"type": "array",
|
|
364
|
-
"items": { "$ref": "#/definitions/OperationDef" }
|
|
365
|
-
}
|
|
366
|
-
}
|
|
367
|
-
},
|
|
368
|
-
"admin": {
|
|
369
|
-
"type": "object",
|
|
370
|
-
"required": ["name", "purpose", "operations"],
|
|
371
|
-
"properties": {
|
|
372
|
-
"name": { "const": "admin" },
|
|
373
|
-
"purpose": { "type": "string" },
|
|
374
|
-
"primaryStore": { "type": "string" },
|
|
375
|
-
"operations": {
|
|
376
|
-
"type": "array",
|
|
377
|
-
"items": { "$ref": "#/definitions/OperationDef" }
|
|
378
|
-
}
|
|
379
|
-
}
|
|
380
|
-
},
|
|
381
|
-
"nexus": {
|
|
382
|
-
"type": "object",
|
|
383
|
-
"required": ["name", "purpose", "operations"],
|
|
384
|
-
"properties": {
|
|
385
|
-
"name": { "const": "nexus" },
|
|
386
|
-
"purpose": { "type": "string" },
|
|
387
|
-
"primaryStore": { "type": "string" },
|
|
388
|
-
"operations": {
|
|
389
|
-
"type": "array",
|
|
390
|
-
"items": { "$ref": "#/definitions/OperationDef" }
|
|
391
|
-
}
|
|
392
|
-
}
|
|
393
|
-
},
|
|
394
|
-
"sticky": {
|
|
395
|
-
"type": "object",
|
|
396
|
-
"required": ["name", "purpose", "operations"],
|
|
397
|
-
"properties": {
|
|
398
|
-
"name": { "const": "sticky" },
|
|
399
|
-
"purpose": { "type": "string" },
|
|
400
|
-
"primaryStore": { "type": "string" },
|
|
401
|
-
"operations": {
|
|
402
|
-
"type": "array",
|
|
403
|
-
"items": { "$ref": "#/definitions/OperationDef" }
|
|
404
|
-
}
|
|
405
|
-
}
|
|
406
|
-
}
|
|
407
|
-
}
|
|
408
|
-
},
|
|
409
|
-
"progressiveDisclosure": {
|
|
410
|
-
"type": "object",
|
|
411
|
-
"description": "Progressive disclosure contract by tier",
|
|
412
|
-
"properties": {
|
|
413
|
-
"tiers": {
|
|
414
|
-
"type": "array",
|
|
415
|
-
"minItems": 3,
|
|
416
|
-
"maxItems": 3,
|
|
417
|
-
"items": {
|
|
418
|
-
"type": "object",
|
|
419
|
-
"required": ["tier", "name", "description", "operationCount", "domains"],
|
|
420
|
-
"properties": {
|
|
421
|
-
"tier": { "$ref": "#/definitions/Tier" },
|
|
422
|
-
"name": {
|
|
423
|
-
"type": "string",
|
|
424
|
-
"enum": ["Core", "Extended", "Full System"]
|
|
425
|
-
},
|
|
426
|
-
"description": { "type": "string" },
|
|
427
|
-
"operationCount": { "type": "integer", "minimum": 0 },
|
|
428
|
-
"domains": {
|
|
429
|
-
"type": "array",
|
|
430
|
-
"items": { "$ref": "#/definitions/CanonicalDomain" }
|
|
431
|
-
}
|
|
432
|
-
}
|
|
433
|
-
}
|
|
434
|
-
}
|
|
435
|
-
}
|
|
436
|
-
}
|
|
437
|
-
}
|
|
438
|
-
}
|