archctx 0.7.0 → 0.7.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "archctx",
3
- "version": "0.7.0",
3
+ "version": "0.7.1",
4
4
  "description": "Local architecture context CLI for agentic coding workflows.",
5
5
  "private": false,
6
6
  "type": "module",
@@ -43,7 +43,7 @@
43
43
  "type": "string",
44
44
  "pattern": "^[a-z0-9]+(-[a-z0-9]+)*-v[0-9]+$",
45
45
  "description": "One feature flag: a lowercase kebab-case name that ends in a version suffix (-v1, -v2, ...). The pattern is open, so a validator built from this schema accepts flags that a later archctx adds. A consumer must ignore a flag it does not know. examples lists the flags this schema version knows.",
46
- "examples": ["architecture-change-capabilities-v1", "architecture-docs-renderer-v2", "architecture-refresh-signal-v1", "changeset-entity-operations-v1", "code-facts-unavailable-error-v1", "module-statistics-v1", "projection-apply-readback-v1", "projection-apply-receipt-v1", "projection-apply-recovery-v1", "projection-apply-replay-v1", "projection-check-freshness-v1", "projection-manifest-contract-v2", "projection-observed-major-change-acceptance-v1", "projection-orphan-review-v1", "projection-preview-v1", "projection-prior-committed-applies-v1", "projection-protocol-v2", "recommendation-scan-decision-v1", "recommendation-v3", "refactor-assessment-v1", "refactor-observation-evidence-v1", "refactor-resolution-v1", "refactor-scan-limits-v1"]
46
+ "examples": ["architecture-change-capabilities-v1", "architecture-docs-renderer-v2", "architecture-refresh-signal-v1", "capability-dependencies-v1", "changeset-entity-operations-v1", "changeset-ownership-delta-v1", "code-facts-unavailable-error-v1", "docs-anchors-v1", "flow-selector-check-v1", "module-statistics-v1", "projection-apply-readback-v1", "projection-apply-receipt-v1", "projection-apply-recovery-v1", "projection-apply-replay-v1", "projection-check-freshness-v1", "projection-manifest-contract-v2", "projection-observed-major-change-acceptance-v1", "projection-orphan-review-v1", "projection-preview-v1", "projection-prior-committed-applies-v1", "projection-protocol-v2", "recommendation-scan-decision-v1", "recommendation-v3", "refactor-assessment-v1", "refactor-observation-evidence-v1", "refactor-resolution-v1", "refactor-scan-limits-v1", "refactor-scan-untracked-count-v1"]
47
47
  }
48
48
  }
49
49
  }
@@ -0,0 +1,116 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://archcontext.dev/schemas/runtime/capability-dependencies.schema.json",
4
+ "title": "CapabilityDependenciesV1",
5
+ "description": "The data of `archctx deps`: a read-only capability x capability import matrix. Owners come from the parent-chain rule `refactor scan` uses, rolled up to the nearest capability. Call counts are not available in v1.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": ["schemaVersion", "ownershipRule", "filter", "capabilities", "matrix", "imports", "calls", "edges", "worktree", "privacy"],
9
+ "properties": {
10
+ "schemaVersion": { "const": "archcontext.capability-dependencies/v1" },
11
+ "ownershipRule": { "const": "parent-chain" },
12
+ "filter": {
13
+ "type": "object",
14
+ "additionalProperties": false,
15
+ "required": ["from", "into"],
16
+ "properties": {
17
+ "from": { "type": ["string", "null"] },
18
+ "into": { "type": ["string", "null"] }
19
+ }
20
+ },
21
+ "capabilities": { "type": "array", "uniqueItems": true, "items": { "type": "string", "minLength": 1 } },
22
+ "matrix": {
23
+ "type": "array",
24
+ "items": {
25
+ "type": "object",
26
+ "additionalProperties": false,
27
+ "required": ["from", "to", "imports", "calls"],
28
+ "properties": {
29
+ "from": { "type": "string", "minLength": 1 },
30
+ "to": { "type": "string", "minLength": 1 },
31
+ "imports": { "type": "integer", "minimum": 1 },
32
+ "calls": { "type": "null" }
33
+ }
34
+ }
35
+ },
36
+ "imports": {
37
+ "type": "object",
38
+ "additionalProperties": false,
39
+ "required": ["coverage", "reasonCodes", "truncated", "importNodeCount", "importNodeLimit", "importNodeLimitExceeded", "edgeCount", "unresolvedCount", "unattributed"],
40
+ "properties": {
41
+ "coverage": { "enum": ["complete", "partial", "unknown"] },
42
+ "reasonCodes": {
43
+ "type": "array",
44
+ "uniqueItems": true,
45
+ "items": { "enum": ["code-facts-import-limit", "code-facts-stale", "code-facts-truncated", "code-facts-unavailable"] }
46
+ },
47
+ "truncated": { "type": "boolean" },
48
+ "importNodeCount": { "type": ["integer", "null"], "minimum": 0 },
49
+ "importNodeLimit": { "type": "integer", "minimum": 1 },
50
+ "importNodeLimitExceeded": { "type": "boolean" },
51
+ "edgeCount": { "type": "integer", "minimum": 0 },
52
+ "unresolvedCount": { "type": "integer", "minimum": 0 },
53
+ "unattributed": {
54
+ "type": "object",
55
+ "additionalProperties": false,
56
+ "required": ["unownedEndpoint", "contestedEndpoint", "noCapabilityEndpoint"],
57
+ "properties": {
58
+ "unownedEndpoint": { "type": "integer", "minimum": 0 },
59
+ "contestedEndpoint": { "type": "integer", "minimum": 0 },
60
+ "noCapabilityEndpoint": { "type": "integer", "minimum": 0 }
61
+ }
62
+ }
63
+ }
64
+ },
65
+ "calls": {
66
+ "type": "object",
67
+ "additionalProperties": false,
68
+ "required": ["coverage", "reasonCodes"],
69
+ "properties": {
70
+ "coverage": { "const": "unknown" },
71
+ "reasonCodes": { "type": "array", "minItems": 1, "maxItems": 1, "items": { "const": "call-edges-not-exposed" } }
72
+ }
73
+ },
74
+ "edges": {
75
+ "type": "object",
76
+ "additionalProperties": false,
77
+ "required": ["limit", "count", "omittedCount", "items"],
78
+ "properties": {
79
+ "limit": { "type": "integer", "minimum": 0 },
80
+ "count": { "type": "integer", "minimum": 0 },
81
+ "omittedCount": { "type": "integer", "minimum": 0 },
82
+ "items": {
83
+ "type": "array",
84
+ "items": {
85
+ "type": "object",
86
+ "additionalProperties": false,
87
+ "required": ["fromPath", "toPath", "fromCapability", "toCapability"],
88
+ "properties": {
89
+ "fromPath": { "type": "string", "minLength": 1 },
90
+ "toPath": { "type": "string", "minLength": 1 },
91
+ "fromCapability": { "type": "string", "minLength": 1 },
92
+ "toCapability": { "type": "string", "minLength": 1 }
93
+ }
94
+ }
95
+ }
96
+ }
97
+ },
98
+ "worktree": {
99
+ "type": "object",
100
+ "additionalProperties": false,
101
+ "required": ["headSha", "worktreeDigest"],
102
+ "properties": {
103
+ "headSha": { "type": "string", "pattern": "^[a-f0-9]{40}$" },
104
+ "worktreeDigest": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" }
105
+ }
106
+ },
107
+ "privacy": {
108
+ "type": "object",
109
+ "additionalProperties": false,
110
+ "required": ["writes"],
111
+ "properties": {
112
+ "writes": { "const": "none" }
113
+ }
114
+ }
115
+ }
116
+ }
@@ -0,0 +1,143 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://archcontext.dev/schemas/runtime/docs-anchors.schema.json",
4
+ "title": "DocsAnchorsReportV1",
5
+ "description": "Read-only result of `archctx docs anchors`: stale citations in human-owned module document regions and node prose. A signal, not a gate.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": ["schemaVersion", "profile", "codeGraph", "summary", "nodes"],
9
+ "properties": {
10
+ "schemaVersion": { "const": "archcontext.docs-anchors/v1" },
11
+ "profile": { "enum": ["default", "repo-harness/v1"] },
12
+ "codeGraph": {
13
+ "oneOf": [
14
+ {
15
+ "type": "object",
16
+ "additionalProperties": false,
17
+ "required": ["availability"],
18
+ "properties": { "availability": { "const": "ready" } }
19
+ },
20
+ {
21
+ "type": "object",
22
+ "additionalProperties": false,
23
+ "required": ["availability", "reasonCode"],
24
+ "properties": {
25
+ "availability": { "const": "unavailable" },
26
+ "reasonCode": { "enum": ["index-missing", "index-open-failed"] }
27
+ }
28
+ }
29
+ ]
30
+ },
31
+ "summary": {
32
+ "type": "object",
33
+ "additionalProperties": false,
34
+ "required": ["nodes", "documents", "citations", "findings", "unchecked", "byKind"],
35
+ "properties": {
36
+ "nodes": { "$ref": "#/$defs/count" },
37
+ "documents": { "$ref": "#/$defs/count" },
38
+ "citations": { "$ref": "#/$defs/count" },
39
+ "findings": { "$ref": "#/$defs/count" },
40
+ "unchecked": { "$ref": "#/$defs/count" },
41
+ "byKind": {
42
+ "type": "object",
43
+ "additionalProperties": false,
44
+ "required": ["line-moved", "line-out-of-range", "missing-path", "missing-symbol"],
45
+ "properties": {
46
+ "line-moved": { "$ref": "#/$defs/count" },
47
+ "line-out-of-range": { "$ref": "#/$defs/count" },
48
+ "missing-path": { "$ref": "#/$defs/count" },
49
+ "missing-symbol": { "$ref": "#/$defs/count" }
50
+ }
51
+ }
52
+ }
53
+ },
54
+ "nodes": {
55
+ "type": "array",
56
+ "items": {
57
+ "type": "object",
58
+ "additionalProperties": false,
59
+ "required": ["nodeId", "citationCount", "findings", "unchecked"],
60
+ "properties": {
61
+ "nodeId": { "type": "string", "minLength": 1 },
62
+ "documentPath": { "$ref": "#/$defs/repoPath" },
63
+ "citationCount": { "type": "integer", "minimum": 1 },
64
+ "findings": { "type": "array", "items": { "$ref": "#/$defs/finding" } },
65
+ "unchecked": { "type": "array", "items": { "$ref": "#/$defs/unchecked" } }
66
+ }
67
+ }
68
+ }
69
+ },
70
+ "$defs": {
71
+ "count": { "type": "integer", "minimum": 0 },
72
+ "line": { "type": "integer", "minimum": 1 },
73
+ "repoPath": {
74
+ "type": "string",
75
+ "minLength": 1,
76
+ "not": { "anyOf": [{ "pattern": "^/" }, { "pattern": "\\\\" }, { "pattern": "(^|/)\\.\\.(/|$)" }] }
77
+ },
78
+ "origin": {
79
+ "oneOf": [
80
+ {
81
+ "type": "object",
82
+ "additionalProperties": false,
83
+ "required": ["kind", "path", "line"],
84
+ "properties": {
85
+ "kind": { "const": "document" },
86
+ "path": { "$ref": "#/$defs/repoPath" },
87
+ "line": { "$ref": "#/$defs/line" }
88
+ }
89
+ },
90
+ {
91
+ "type": "object",
92
+ "additionalProperties": false,
93
+ "required": ["kind"],
94
+ "properties": { "kind": { "const": "node-summary" } }
95
+ },
96
+ {
97
+ "type": "object",
98
+ "additionalProperties": false,
99
+ "required": ["kind", "index"],
100
+ "properties": {
101
+ "kind": { "const": "node-responsibility" },
102
+ "index": { "type": "integer", "minimum": 0 }
103
+ }
104
+ }
105
+ ]
106
+ },
107
+ "citation": {
108
+ "type": "object",
109
+ "additionalProperties": false,
110
+ "required": ["text"],
111
+ "properties": {
112
+ "text": { "type": "string", "minLength": 1 },
113
+ "path": { "type": "string", "minLength": 1 },
114
+ "resolvedPath": { "$ref": "#/$defs/repoPath" },
115
+ "line": { "$ref": "#/$defs/line" },
116
+ "endLine": { "$ref": "#/$defs/line" },
117
+ "symbol": { "type": "string", "minLength": 1 }
118
+ }
119
+ },
120
+ "finding": {
121
+ "type": "object",
122
+ "additionalProperties": false,
123
+ "required": ["kind", "origin", "citation"],
124
+ "properties": {
125
+ "kind": { "enum": ["line-moved", "line-out-of-range", "missing-path", "missing-symbol"] },
126
+ "origin": { "$ref": "#/$defs/origin" },
127
+ "citation": { "$ref": "#/$defs/citation" },
128
+ "lineCount": { "$ref": "#/$defs/count" },
129
+ "currentLines": { "type": "array", "minItems": 1, "uniqueItems": true, "items": { "$ref": "#/$defs/line" } }
130
+ }
131
+ },
132
+ "unchecked": {
133
+ "type": "object",
134
+ "additionalProperties": false,
135
+ "required": ["reasonCode", "origin", "citation"],
136
+ "properties": {
137
+ "reasonCode": { "enum": ["codegraph-unavailable", "language-unsupported", "path-ambiguous"] },
138
+ "origin": { "$ref": "#/$defs/origin" },
139
+ "citation": { "$ref": "#/$defs/citation" }
140
+ }
141
+ }
142
+ }
143
+ }
@@ -0,0 +1,109 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://archcontext.dev/schemas/runtime/flow-selector-check.schema.json",
4
+ "title": "ArchitectureFlowSelectorCheckV1",
5
+ "description": "The data of `archctx flows check`: the P2 flow proof of every capability that declares a flow, and the proof status of every declared entrypoint-to-sink selector, computed without rendering. Consumers detect it through the flow-selector-check-v1 capability.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": ["schemaVersion", "ok", "codeGraph", "summary", "selectors", "capabilities"],
9
+ "properties": {
10
+ "schemaVersion": { "const": "archcontext.flow-selector-check/v1" },
11
+ "ok": { "type": "boolean", "description": "True when no capability that declares a flow has an unprovable P2 proof." },
12
+ "codeGraph": {
13
+ "type": "object",
14
+ "additionalProperties": false,
15
+ "required": ["availability", "version"],
16
+ "properties": {
17
+ "availability": { "enum": ["ready", "unavailable"] },
18
+ "version": { "type": "string", "minLength": 1 }
19
+ }
20
+ },
21
+ "summary": {
22
+ "type": "object",
23
+ "additionalProperties": false,
24
+ "required": ["selectors", "proven", "unproven", "usedUnproven"],
25
+ "properties": {
26
+ "selectors": { "type": "integer", "minimum": 0 },
27
+ "proven": { "type": "integer", "minimum": 0 },
28
+ "unproven": { "type": "integer", "minimum": 0 },
29
+ "usedUnproven": { "type": "integer", "minimum": 0, "description": "Unproven selectors that a required-flow step names." }
30
+ }
31
+ },
32
+ "selectors": {
33
+ "type": "array",
34
+ "items": {
35
+ "type": "object",
36
+ "additionalProperties": false,
37
+ "required": ["nodeId", "entrypointId", "sourcePath", "sourceSymbol", "sinkId", "sinkPath", "sinkSymbol", "status", "callSites", "referenceSites", "rejectedBuiltinCallSites", "flowSteps"],
38
+ "properties": {
39
+ "nodeId": { "type": "string", "minLength": 1 },
40
+ "entrypointId": { "type": "string", "minLength": 1 },
41
+ "sourcePath": { "type": "string", "minLength": 1 },
42
+ "sourceSymbol": { "type": "string", "minLength": 1 },
43
+ "sinkId": { "type": "string", "minLength": 1 },
44
+ "sinkPath": { "type": "string", "minLength": 1 },
45
+ "sinkSymbol": { "type": "string", "minLength": 1 },
46
+ "status": {
47
+ "enum": ["ambiguous-symbol", "evidence-missing", "evidence-truncated", "false-builtin-call", "no-direct-call", "only-references", "proven"],
48
+ "description": "Only proven binds a flow step."
49
+ },
50
+ "callSites": { "$ref": "#/$defs/sites" },
51
+ "referenceSites": { "$ref": "#/$defs/sites" },
52
+ "rejectedBuiltinCallSites": { "$ref": "#/$defs/sites" },
53
+ "flowSteps": {
54
+ "type": "array",
55
+ "items": {
56
+ "type": "object",
57
+ "additionalProperties": false,
58
+ "required": ["flowId", "stepId"],
59
+ "properties": {
60
+ "flowId": { "type": "string", "minLength": 1 },
61
+ "stepId": { "type": "string", "minLength": 1 }
62
+ }
63
+ }
64
+ }
65
+ }
66
+ }
67
+ },
68
+ "capabilities": {
69
+ "type": "array",
70
+ "items": {
71
+ "type": "object",
72
+ "additionalProperties": false,
73
+ "required": ["capabilityId", "p2Status", "diagnostics"],
74
+ "properties": {
75
+ "capabilityId": { "type": "string", "minLength": 1 },
76
+ "p2Status": { "enum": ["not-applicable", "proven", "unprovable"] },
77
+ "diagnostics": {
78
+ "type": "array",
79
+ "items": {
80
+ "type": "object",
81
+ "additionalProperties": false,
82
+ "required": ["code", "detail"],
83
+ "properties": {
84
+ "code": { "type": "string", "minLength": 1 },
85
+ "flowId": { "type": "string", "minLength": 1 },
86
+ "stepId": { "type": "string", "minLength": 1 },
87
+ "detail": { "type": "string" }
88
+ }
89
+ }
90
+ }
91
+ }
92
+ }
93
+ }
94
+ },
95
+ "$defs": {
96
+ "sites": {
97
+ "type": "array",
98
+ "items": {
99
+ "type": "object",
100
+ "additionalProperties": false,
101
+ "required": ["path"],
102
+ "properties": {
103
+ "path": { "type": "string", "minLength": 1 },
104
+ "line": { "type": "integer", "minimum": 1 }
105
+ }
106
+ }
107
+ }
108
+ }
109
+ }
@@ -578,6 +578,7 @@
578
578
  "items": {
579
579
  "enum": [
580
580
  "caller-coverage-unknown",
581
+ "code-facts-import-limit",
581
582
  "code-facts-missing",
582
583
  "code-facts-truncated",
583
584
  "major-change-detected",
@@ -470,6 +470,7 @@
470
470
  "items": {
471
471
  "enum": [
472
472
  "caller-coverage-unknown",
473
+ "code-facts-import-limit",
473
474
  "code-facts-missing",
474
475
  "code-facts-truncated",
475
476
  "major-change-detected",
@@ -1740,12 +1741,20 @@
1740
1741
  ],
1741
1742
  "minimum": 0
1742
1743
  },
1744
+ "importNodeCount": {
1745
+ "type": [
1746
+ "integer",
1747
+ "null"
1748
+ ],
1749
+ "minimum": 0
1750
+ },
1743
1751
  "reasonCodes": {
1744
1752
  "type": "array",
1745
1753
  "uniqueItems": true,
1746
1754
  "items": {
1747
1755
  "enum": [
1748
1756
  "caller-coverage-unknown",
1757
+ "code-facts-import-limit",
1749
1758
  "code-facts-missing",
1750
1759
  "code-facts-truncated",
1751
1760
  "major-change-detected",
@@ -2028,6 +2037,10 @@
2028
2037
  },
2029
2038
  "task": {
2030
2039
  "type": "string"
2040
+ },
2041
+ "importNodeLimit": {
2042
+ "type": "integer",
2043
+ "minimum": 1
2031
2044
  }
2032
2045
  }
2033
2046
  },
@@ -2272,6 +2285,7 @@
2272
2285
  "items": {
2273
2286
  "enum": [
2274
2287
  "caller-coverage-unknown",
2288
+ "code-facts-import-limit",
2275
2289
  "code-facts-missing",
2276
2290
  "code-facts-truncated",
2277
2291
  "major-change-detected",
@@ -42,6 +42,11 @@
42
42
  "type": "integer",
43
43
  "minimum": 0
44
44
  },
45
+ "untrackedExcludedCount": {
46
+ "type": "integer",
47
+ "minimum": 0,
48
+ "description": "Worktree files that Git does not ignore and that the HEAD tree does not carry (untracked and newly staged files). The scan measures HEAD only, so it excludes them. Optional: a scan from an older archctx does not report it."
49
+ },
45
50
  "snapshot": {
46
51
  "$ref": "#/$defs/moduleStatisticsSnapshot"
47
52
  },
@@ -510,6 +515,7 @@
510
515
  "items": {
511
516
  "enum": [
512
517
  "caller-coverage-unknown",
518
+ "code-facts-import-limit",
513
519
  "code-facts-missing",
514
520
  "code-facts-truncated",
515
521
  "major-change-detected",
@@ -1780,12 +1786,20 @@
1780
1786
  ],
1781
1787
  "minimum": 0
1782
1788
  },
1789
+ "importNodeCount": {
1790
+ "type": [
1791
+ "integer",
1792
+ "null"
1793
+ ],
1794
+ "minimum": 0
1795
+ },
1783
1796
  "reasonCodes": {
1784
1797
  "type": "array",
1785
1798
  "uniqueItems": true,
1786
1799
  "items": {
1787
1800
  "enum": [
1788
1801
  "caller-coverage-unknown",
1802
+ "code-facts-import-limit",
1789
1803
  "code-facts-missing",
1790
1804
  "code-facts-truncated",
1791
1805
  "major-change-detected",
@@ -2068,6 +2082,10 @@
2068
2082
  },
2069
2083
  "task": {
2070
2084
  "type": "string"
2085
+ },
2086
+ "importNodeLimit": {
2087
+ "type": "integer",
2088
+ "minimum": 1
2071
2089
  }
2072
2090
  }
2073
2091
  },
@@ -2312,6 +2330,7 @@
2312
2330
  "items": {
2313
2331
  "enum": [
2314
2332
  "caller-coverage-unknown",
2333
+ "code-facts-import-limit",
2315
2334
  "code-facts-missing",
2316
2335
  "code-facts-truncated",
2317
2336
  "major-change-detected",
@@ -470,6 +470,7 @@
470
470
  "items": {
471
471
  "enum": [
472
472
  "caller-coverage-unknown",
473
+ "code-facts-import-limit",
473
474
  "code-facts-missing",
474
475
  "code-facts-truncated",
475
476
  "major-change-detected",