hoi4-agent-tools 0.1.7 → 0.2.0
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/CHANGELOG.md +24 -0
- package/README.md +31 -25
- package/SECURITY.md +4 -2
- package/dist/bin/setup.js +11 -4
- package/dist/bin/setup.js.map +1 -1
- package/dist/hoi4_agent_tools/core/configuration.d.ts +1 -0
- package/dist/hoi4_agent_tools/core/configuration.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/core/configuration.js +3 -3
- package/dist/hoi4_agent_tools/core/configuration.js.map +1 -1
- package/dist/hoi4_agent_tools/core/engine.d.ts +1 -0
- package/dist/hoi4_agent_tools/core/engine.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/core/engine.js +1 -0
- package/dist/hoi4_agent_tools/core/engine.js.map +1 -1
- package/dist/hoi4_agent_tools/core/transactions.d.ts +2 -0
- package/dist/hoi4_agent_tools/core/transactions.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/core/transactions.js +49 -6
- package/dist/hoi4_agent_tools/core/transactions.js.map +1 -1
- package/dist/hoi4_agent_tools/core/workspace.js +1 -1
- package/dist/hoi4_agent_tools/core/workspace.js.map +1 -1
- package/dist/hoi4_agent_tools/focus/service.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/focus/service.js +4 -18
- package/dist/hoi4_agent_tools/focus/service.js.map +1 -1
- package/dist/hoi4_agent_tools/gui/studio.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/gui/studio.js +3 -2
- package/dist/hoi4_agent_tools/gui/studio.js.map +1 -1
- package/dist/hoi4_agent_tools/map/service.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/map/service.js +11 -5
- package/dist/hoi4_agent_tools/map/service.js.map +1 -1
- package/dist/hoi4_agent_tools/mcp/prompts/register.d.ts +2 -1
- package/dist/hoi4_agent_tools/mcp/prompts/register.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/mcp/prompts/register.js +35 -13
- package/dist/hoi4_agent_tools/mcp/prompts/register.js.map +1 -1
- package/dist/hoi4_agent_tools/mcp/registry/metadata.d.ts +1 -1
- package/dist/hoi4_agent_tools/mcp/security/auth.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/mcp/security/auth.js +1 -4
- package/dist/hoi4_agent_tools/mcp/security/auth.js.map +1 -1
- package/dist/hoi4_agent_tools/mcp/server/base-tools.d.ts +12 -0
- package/dist/hoi4_agent_tools/mcp/server/base-tools.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/mcp/server/base-tools.js +239 -220
- package/dist/hoi4_agent_tools/mcp/server/base-tools.js.map +1 -1
- package/dist/hoi4_agent_tools/mcp/server/create.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/mcp/server/create.js +8 -2
- package/dist/hoi4_agent_tools/mcp/server/create.js.map +1 -1
- package/dist/hoi4_agent_tools/mcp/server/output-schemas.d.ts +5 -0
- package/dist/hoi4_agent_tools/mcp/server/output-schemas.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/mcp/server/output-schemas.js +1 -0
- package/dist/hoi4_agent_tools/mcp/server/output-schemas.js.map +1 -1
- package/dist/hoi4_agent_tools/mcp/server/result.js +1 -1
- package/dist/hoi4_agent_tools/mcp/server/result.js.map +1 -1
- package/dist/hoi4_agent_tools/mcp/server/transaction-execution.d.ts +31 -0
- package/dist/hoi4_agent_tools/mcp/server/transaction-execution.d.ts.map +1 -0
- package/dist/hoi4_agent_tools/mcp/server/transaction-execution.js +127 -0
- package/dist/hoi4_agent_tools/mcp/server/transaction-execution.js.map +1 -0
- package/dist/hoi4_agent_tools/mcp/tools/focus.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/mcp/tools/focus.js +69 -23
- package/dist/hoi4_agent_tools/mcp/tools/focus.js.map +1 -1
- package/dist/hoi4_agent_tools/mcp/tools/gui.d.ts +6 -0
- package/dist/hoi4_agent_tools/mcp/tools/gui.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/mcp/tools/gui.js +40 -12
- package/dist/hoi4_agent_tools/mcp/tools/gui.js.map +1 -1
- package/dist/hoi4_agent_tools/mcp/tools/map.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/mcp/tools/map.js +39 -12
- package/dist/hoi4_agent_tools/mcp/tools/map.js.map +1 -1
- package/dist/hoi4_agent_tools/mcp/transports/http.d.ts.map +1 -1
- package/dist/hoi4_agent_tools/mcp/transports/http.js +3 -0
- package/dist/hoi4_agent_tools/mcp/transports/http.js.map +1 -1
- package/dist/hoi4_agent_tools/version.d.ts +1 -1
- package/dist/hoi4_agent_tools/version.js +1 -1
- package/docs/README.md +2 -2
- package/docs/adr/0012-autonomous-rewrites.md +55 -0
- package/docs/adr/README.md +1 -0
- package/docs/agent-integration.md +33 -23
- package/docs/architecture.md +20 -4
- package/docs/artifacts.md +8 -5
- package/docs/completion-report.md +85 -125
- package/docs/configuration.md +24 -8
- package/docs/focus-workflow.md +16 -14
- package/docs/gui-workflow.md +7 -3
- package/docs/limitations.md +3 -2
- package/docs/map-workflow.md +15 -9
- package/docs/performance.md +1 -1
- package/docs/release.md +11 -9
- package/docs/research/mcp-2026-07-10.md +9 -3
- package/docs/security.md +12 -6
- package/docs/self-hosting.md +8 -6
- package/docs/transactions.md +45 -33
- package/docs/troubleshooting.md +12 -4
- package/package.json +2 -2
- package/schemas/configuration.schema.json +3 -2
- package/schemas/continuous-focus-palette.schema.json +1 -1
- package/schemas/focus-plan.schema.json +1 -1
- package/schemas/focus-planning-sidecar.schema.json +1 -1
- package/schemas/gui-animation-source.schema.json +1 -1
- package/schemas/gui-helper.schema.json +1 -1
- package/schemas/gui-scenario.schema.json +1 -1
- package/schemas/map-operation.schema.json +1 -1
- package/schemas/operation-result.schema.json +1 -1
- package/schemas/transaction-manifest.schema.json +1 -1
- package/server.json +3 -3
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
# ADR 0012: Autonomous one-call rewrites over internal durable journals
|
|
2
|
+
|
|
3
|
+
- Status: accepted
|
|
4
|
+
- Date: 2026-07-12
|
|
5
|
+
|
|
6
|
+
## Context
|
|
7
|
+
|
|
8
|
+
The original public write protocol exposed planning as a dry-run transaction and required a coding agent to carry a transaction ID and plan hash through separate diff, apply, status, and rollback calls. Those checks protected source integrity, but the caller choreography conflicted with the product's agent-first model: an operator had already selected the allowed roots and principals, yet an authorized agent still had to perform a second transaction-approval protocol before completing one supported edit.
|
|
9
|
+
|
|
10
|
+
The integrity properties supplied by the shared transaction engine remain necessary. A multi-file HOI4 rewrite must still validate the complete proposal, reject stale input, journal exact original bytes, prevent cross-workspace access, recover from interrupted replacement, validate the written result, and restore the original state on failure.
|
|
11
|
+
|
|
12
|
+
## Decision
|
|
13
|
+
|
|
14
|
+
The server remains read-only by default. An operator may explicitly opt a canonical mod workspace into effective `writePolicy: "autonomous"`. That policy authorizes the supported domain rewrite tools for the already allowlisted workspace; it does not make game, dependency, fixture, artifact, cache, state, or unrelated roots writable.
|
|
15
|
+
|
|
16
|
+
The primary mutating MCP surface is one call per domain:
|
|
17
|
+
|
|
18
|
+
- `focus_rewrite`
|
|
19
|
+
- `gui_rewrite`
|
|
20
|
+
- `map_rewrite`
|
|
21
|
+
|
|
22
|
+
Each rewrite call performs one server-owned sequence:
|
|
23
|
+
|
|
24
|
+
1. authenticate and authorize the principal, workspace grant, and transport write scope;
|
|
25
|
+
2. resolve every target beneath the canonical writable mod root;
|
|
26
|
+
3. calculate the complete affected-file set and proposed bytes;
|
|
27
|
+
4. run mandatory in-memory validation and produce relevant source and visual evidence;
|
|
28
|
+
5. acquire the workspace lock and recheck roots, ownership, and all source hashes;
|
|
29
|
+
6. persist an authenticated internal journal containing exact before bytes and intended replacements;
|
|
30
|
+
7. stage and replace the affected files with recoverable logical atomicity;
|
|
31
|
+
8. rebuild the affected index and run mandatory post-write validation;
|
|
32
|
+
9. restore exact original bytes automatically if a write or required validation check fails; and
|
|
33
|
+
10. return the completed rewrite outcome, diagnostics, changed files, and evidence resources.
|
|
34
|
+
|
|
35
|
+
A blocker detected before mutation returns without changing source. A caller does not receive or resubmit a transaction ID or expected plan hash, page through a transaction diff as an authorization step, make a separate apply call, or invoke rollback. Internal plan hashes, manifests, protected revision heads, before blobs, and recovery states remain server implementation details and audit evidence where safe to expose in sanitized form; they are not bearer capabilities or caller approval tokens.
|
|
36
|
+
|
|
37
|
+
An explicitly enabled `writePolicy: "transactions"` mode may remain as a compatibility surface for existing clients. It is not the primary documentation, prompt, example, discovery, or acceptance path, and autonomous acceptance cannot depend on its manual tools.
|
|
38
|
+
|
|
39
|
+
Remote deployment retains the HTTP decision in ADR 0011: every request is authenticated, present Origin and Host values are checked, non-loopback access requires the configured HTTPS OAuth/OIDC policy, write calls require write scope, sessions are credential-bound routing state, and principal-to-workspace grants remain authoritative. Runtime registration cannot elevate itself to autonomous write authority; that authority must come from operator-controlled configuration or an equally explicit operator capability for the canonical root.
|
|
40
|
+
|
|
41
|
+
ADR 0007 remains authoritative for per-workspace storage, authenticated journals, locking, exact-byte recovery, and crash reconciliation. This decision supersedes only the interpretation that ADR 0007's transaction ID and plan hash must form the primary caller workflow.
|
|
42
|
+
|
|
43
|
+
## Rationale
|
|
44
|
+
|
|
45
|
+
The operator's explicit workspace policy is the durable authorization decision. Repeating that decision through a server-specific multi-call confirmation protocol adds agent steps without expanding the filesystem or principal boundary. Keeping the complete safety sequence inside the mutating call gives an authorized coding agent a reliable one-call capability while retaining the protections that matter at the write boundary.
|
|
46
|
+
|
|
47
|
+
Read-only scan, lint, layout, render, compare, and validation tools remain available for analysis and evidence. They are useful inputs to agent reasoning, but an autonomous rewrite does not depend on a mandatory preview transaction. A coding-agent host may still apply its own generic tool-use policy; the server protocol does not require a host-specific confirmation interface.
|
|
48
|
+
|
|
49
|
+
## Consequences
|
|
50
|
+
|
|
51
|
+
Public schemas, tool descriptions, prompts, examples, and acceptance tests use the domain rewrite tools and must not require transaction IDs, expected plan hashes, manual diff/apply sequences, or explicit rollback. Successful rewrites return review and validation evidence after the server has completed its protected sequence.
|
|
52
|
+
|
|
53
|
+
Recovery is automatic for failed or interrupted rewrites. Intentional reversal of a successful accepted change is a new source edit through version control or another authorized rewrite, not a caller-invoked journal rollback capability.
|
|
54
|
+
|
|
55
|
+
The server still provides recoverable logical atomicity rather than an operating-system transaction. Another process may briefly observe replacement steps, while stale-source checks and final validation prevent the server from reporting success for an unverified mixed state. Shared-filesystem deployments still require single-writer coordination as specified by ADR 0007.
|
package/docs/adr/README.md
CHANGED
|
@@ -12,18 +12,24 @@ Suggested durable configuration locations:
|
|
|
12
12
|
- macOS: `~/.config/hoi4-agent-tools/config.json`
|
|
13
13
|
- Linux: `~/.config/hoi4-agent-tools/config.json`
|
|
14
14
|
|
|
15
|
-
Keep
|
|
15
|
+
Keep rewrite state outside every game, mod, dependency, artifact, and cache root. Generated artifact/cache storage may also be placed outside the mod by using `storageRoots`, `artifactRoot`, and `cacheRoot`. See [configuration](configuration.md).
|
|
16
16
|
|
|
17
17
|
Create and validate a configuration:
|
|
18
18
|
|
|
19
19
|
```bash
|
|
20
|
-
npm install --global hoi4-agent-tools@0.
|
|
20
|
+
npm install --global hoi4-agent-tools@0.2.0
|
|
21
21
|
hoi4-agent-tools-setup --init-config /absolute/path/config.json --workspace /absolute/path/mod --workspace-id my_mod --workspace-name "My Mod" --game /absolute/path/game
|
|
22
22
|
hoi4-agent-tools-setup --diagnose --config /absolute/path/config.json
|
|
23
23
|
hoi4-agent-tools-setup --print-client-config --config /absolute/path/config.json
|
|
24
24
|
```
|
|
25
25
|
|
|
26
|
-
The
|
|
26
|
+
The initialization command above creates a read-only configuration. To choose the recommended autonomous mode instead, replace that initialization command with:
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
hoi4-agent-tools-setup --init-config /absolute/path/config.json --workspace /absolute/path/mod --workspace-id my_mod --workspace-name "My Mod" --game /absolute/path/game --autonomous-writes --server-state /separate/operator/state
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
`--autonomous-writes` writes `"writePolicy": "autonomous"` and enables the named mod workspace. Use `--reviewed-writes --server-state /separate/operator/state` only when compatibility with the separate transaction review/apply sequence is required; `--enable-writes` remains a compatibility alias for reviewed mode. The flags are mutually exclusive. `--print-client-config` prints both a pinned `npx` registration and an optional global-install registration; it does not edit an MCP host's settings.
|
|
27
33
|
|
|
28
34
|
Generic host registration:
|
|
29
35
|
|
|
@@ -32,7 +38,7 @@ Generic host registration:
|
|
|
32
38
|
"mcpServers": {
|
|
33
39
|
"hoi4_agent_tools": {
|
|
34
40
|
"command": "npx",
|
|
35
|
-
"args": ["-y", "hoi4-agent-tools@0.
|
|
41
|
+
"args": ["-y", "hoi4-agent-tools@0.2.0"],
|
|
36
42
|
"env": {
|
|
37
43
|
"HOI4_AGENT_CONFIG": "/absolute/path/config.json"
|
|
38
44
|
}
|
|
@@ -46,7 +52,7 @@ Codex registration:
|
|
|
46
52
|
```toml
|
|
47
53
|
[mcp_servers.hoi4_agent_tools]
|
|
48
54
|
command = "npx"
|
|
49
|
-
args = ["-y", "hoi4-agent-tools@0.
|
|
55
|
+
args = ["-y", "hoi4-agent-tools@0.2.0"]
|
|
50
56
|
startup_timeout_sec = 120
|
|
51
57
|
|
|
52
58
|
[mcp_servers.hoi4_agent_tools.env]
|
|
@@ -63,16 +69,16 @@ A coding agent should select this server when a registered HOI4 workspace task i
|
|
|
63
69
|
- Clausewitz prerequisite, route-lock, mutual-exclusion, localisation, icon, AI, or linked-content validation;
|
|
64
70
|
- scripted GUI, interface, GFX, sprites, fonts, animation states, deterministic previews, or visual comparisons;
|
|
65
71
|
- states, provinces, province geometry, strategic regions, adjacency, supply nodes, or railways;
|
|
66
|
-
- source-preserving
|
|
72
|
+
- source-preserving rewrites, visual diffs, and recoverable multi-file changes for those surfaces.
|
|
67
73
|
|
|
68
74
|
Do not use the server for arbitrary shell commands, general repository edits, game automation, or in-game screenshots. It exposes typed HOI4 services, not a command runner.
|
|
69
75
|
|
|
70
76
|
The normal first calls are:
|
|
71
77
|
|
|
72
|
-
1. `hoi4.project_status` to discover the configured workspace ID and write status.
|
|
78
|
+
1. `hoi4.project_status` to discover the configured workspace ID, effective `writePolicy`, and write status.
|
|
73
79
|
2. `hoi4.project_scan` when a complete shared symbol/reference revision is useful.
|
|
74
80
|
3. The relevant domain scan and lint tools.
|
|
75
|
-
4. Deterministic layout/render/compare tools before a source
|
|
81
|
+
4. Deterministic layout/render/compare tools before a source rewrite.
|
|
76
82
|
|
|
77
83
|
Large artifacts are returned as opaque `hoi4-agent://` resources. Read the linked resource instead of asking the tool to inline it. Artifact reads are range-bounded; use `?offset=N&length=1048576` until the complete advertised size has been retrieved.
|
|
78
84
|
|
|
@@ -80,9 +86,9 @@ Large artifacts are returned as opaque `hoi4-agent://` resources. Read the linke
|
|
|
80
86
|
|
|
81
87
|
Use the Focus Tree Workbench for large or badly structured trees: broken or ambiguous prerequisites, duplicate coordinates, avoidable connector crossings, unstable route layout, missing references, weak convergence, or a tree whose visual structure no longer matches its route architecture.
|
|
82
88
|
|
|
83
|
-
The
|
|
89
|
+
The autonomous repair sequence is:
|
|
84
90
|
|
|
85
|
-
1. Call `hoi4.focus_scan`, `hoi4.focus_lint`, and `hoi4.focus_render` for the existing source. A very wide or deep national tree can pass `reviewScale` from `0.25` through `1.0`; retain that scale for
|
|
91
|
+
1. Call `hoi4.focus_scan`, `hoi4.focus_lint`, and `hoi4.focus_render` for the existing source. A very wide or deep national tree can pass `reviewScale` from `0.25` through `1.0`; retain that scale for proposed and final evidence.
|
|
86
92
|
2. Read the complete imported plan resource and baseline HTML/SVG/PNG/JSON/source-map artifacts.
|
|
87
93
|
3. Preserve prerequisites, exclusions, route locks, rewards, comments, raw passthrough, source locations, and provenance.
|
|
88
94
|
4. Assign explicit `branchGroups`, `laneGroups`, `branchId`, and `laneId` metadata that reflect the intended route architecture.
|
|
@@ -98,10 +104,9 @@ The safe repair sequence is:
|
|
|
98
104
|
}
|
|
99
105
|
```
|
|
100
106
|
|
|
101
|
-
7. Submit the complete plan to `hoi4.
|
|
102
|
-
8.
|
|
103
|
-
9.
|
|
104
|
-
10. Rescan, lint, and render the applied source. Use `hoi4.transaction_rollback` with the same hash if validation fails or the reviewed result is not acceptable.
|
|
107
|
+
7. Submit the complete plan once to `hoi4.focus_rewrite`. This performs deterministic proposed layout, source-preserving compilation, lint, before/proposed rendering, bitmap comparison, journal admission, application, index rebuild, and post-write validation. For a national tree whose default review canvas would exceed the bounded renderer, pass a uniform `reviewScale` from `0.25` through `1.0` (for example, `0.4` for a very large tree). It scales the complete visual rather than crowding node geometry, is applied identically to before and proposed artifacts, and does not change compiled focus coordinates. Optional `horizontalSpacing`, `verticalSpacing`, and `padding` controls remain available for intentional review-presentation changes.
|
|
108
|
+
8. Check `execution`, `changedFiles`, diagnostics, validation, source-map links, and visual evidence in the result. A blocked proposal has `execution: "planned"` and changes no source. A successful rewrite has `execution: "applied"`.
|
|
109
|
+
9. Rescan, lint, and render when additional final evidence is useful. The rewrite call already rescans and post-validates; if any application or post-validation step fails, the journal restores every affected file automatically before failure is returned.
|
|
105
110
|
|
|
106
111
|
`hoi4.focus_layout` by itself is deliberately conservative. It preserves fixed, relative, pinned, and prior-stable nodes. Full-tree cleanup is an explicit plan decision because silently rearranging authored coordinates would be unsafe.
|
|
107
112
|
|
|
@@ -120,17 +125,22 @@ A serious large-tree plan should define:
|
|
|
120
125
|
- localisation keys, icon sprites, AI weights/strategies, filters, and links to decisions, events, ideas, leaders, helpers, and formables;
|
|
121
126
|
- raw passthrough for unsupported or not-yet-modelled Clausewitz content.
|
|
122
127
|
|
|
123
|
-
For a new source beneath `common/national_focus`, call `hoi4.
|
|
128
|
+
For a new source beneath `common/national_focus`, call `hoi4.focus_rewrite` with `createIfMissing: true`. Use `plan:<tree-id>` as creation `provenance.sourcePath` and 64 zeroes for both initial provenance hashes only when the target is missing. Existing targets normally use imported, hash-bound provenance; resolving intentional plan/source drift additionally requires explicit `authority: "plan"`. Creation refuses to append a different tree to an existing source file. The one-call rewrite retains transparent before evidence, complete proposed artifacts, and exact recovery bytes for the newly created source and sidecar.
|
|
124
129
|
|
|
125
130
|
## Write autonomy and safety boundary
|
|
126
131
|
|
|
127
|
-
|
|
132
|
+
Read-only remains the default. With global `writePolicy: "autonomous"` and `writeEnabled: true` on a canonical mod workspace, the server exposes only the one-call source tools:
|
|
133
|
+
|
|
134
|
+
- `hoi4.focus_rewrite`;
|
|
135
|
+
- `hoi4.gui_rewrite`;
|
|
136
|
+
- `hoi4.map_rewrite`.
|
|
137
|
+
|
|
138
|
+
Each rewrite internally creates a complete hash-bound plan, validates it, persists an authenticated journal and exact before-bytes, applies it under the workspace lock, rebuilds the shared index, and post-validates. Invalid proposals never apply. Stale source, wrong principal/workspace bindings, write-scope failure, application errors, final hash mismatch, and post-validation failures fail closed; failures after replacement begins trigger automatic restoration. Transaction status, diff, apply, and rollback tools are intentionally not registered in autonomous mode.
|
|
139
|
+
|
|
140
|
+
MCP itself does not mandate a confirmation dialog for each mutating tool. The rewrite tools advertise `readOnlyHint: false` and `destructiveHint: true`, but those annotations are hints to the client. The server cannot override a coding-agent host policy that prompts for, blocks, or otherwise constrains the call. Operators grant server-side authority through configuration and, for HTTP, the `hoi4:write` scope; clients independently decide how that authority is presented to users.
|
|
141
|
+
|
|
142
|
+
Git remains the project-history, collaboration, and intentional-revert layer. The authenticated journal is separate operational recovery: it prevents an interrupted or invalid multi-file rewrite from being reported as success or left partially applied.
|
|
128
143
|
|
|
129
|
-
|
|
130
|
-
- the canonical mod workspace must be allowlisted and `writeEnabled`;
|
|
131
|
-
- the dry run must be complete and unexpired;
|
|
132
|
-
- every source hash and principal/workspace binding is rechecked;
|
|
133
|
-
- the separate apply call must carry the exact expected plan hash;
|
|
134
|
-
- the coding-agent host's configured write/approval policy must authorize the apply.
|
|
144
|
+
## Reviewed transaction compatibility
|
|
135
145
|
|
|
136
|
-
|
|
146
|
+
Set `writePolicy: "transactions"` (or initialize with `--reviewed-writes`) only when a client or workflow still depends on the older review boundary. In that mode, the server exposes `hoi4.focus_plan_changes`, `hoi4.gui_plan_changes`, and `hoi4.map_plan`; callers page through `hoi4.transaction_diff`, then call `hoi4.transaction_apply` with the exact transaction ID and plan hash. `hoi4.transaction_status` and explicit `hoi4.transaction_rollback` are also available. The same planning, hash checks, journal, post-validation, and failure-recovery engine is used in both write modes.
|
package/docs/architecture.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Architecture
|
|
2
2
|
|
|
3
|
-
All external behavior enters through MCP and calls typed domain services. Transport code validates protocol and authorization; it does not parse source, lay out graphs, render images, or write files.
|
|
3
|
+
All external behavior enters through MCP and calls typed domain services. Transport code validates protocol and authorization; it does not parse source, lay out graphs, render images, or write files. The configured write policy selects the public MCP surface without changing the shared core implementation.
|
|
4
4
|
|
|
5
5
|
In this documentation, “read-only” scan, lint, layout, and render operations mean that registered HOI4 source bytes are never changed. MCP `readOnlyHint` follows the protocol's broader environmental-mutation meaning: an operation that creates content-addressed evidence under an allowlisted generated-artifact root advertises `readOnlyHint: false`, even though it cannot edit game or mod source.
|
|
6
6
|
|
|
@@ -42,19 +42,35 @@ Large binary rasters and translation catalogs are selected lazily rather than re
|
|
|
42
42
|
|
|
43
43
|
Canonical JSON sorts keys with a locale-independent total UTF-16 code-unit order, traversal uses stable path ordering, layout tie-breaking is fixed, and artifact names are content hashes. Render profiles include source/asset/font hashes and all scenario geometry. Timestamps, host paths, locale collation, random IDs, and time zones are excluded from hashed artifacts.
|
|
44
44
|
|
|
45
|
-
## Artifacts and
|
|
45
|
+
## Artifacts and write execution
|
|
46
46
|
|
|
47
47
|
Generated evidence is content-addressed below `.hoi4-agent/artifacts`. Artifact manifests bind their
|
|
48
48
|
immutable provenance address to a hash-only canonical workspace and configured/runtime owner
|
|
49
49
|
identity. Runtime-generated stores also carry an atomic persistent owner claim, while statically
|
|
50
50
|
configured workspaces retain one shared operator identity for their explicit grants.
|
|
51
51
|
|
|
52
|
-
|
|
52
|
+
The server has three configured source policies. `read-only` authorizes no source mutation.
|
|
53
|
+
`autonomous` registers `hoi4.focus_rewrite`, `hoi4.gui_rewrite`, and `hoi4.map_rewrite`, but not
|
|
54
|
+
transaction status, diff, apply, or rollback tools. `transactions` is a compatibility surface that
|
|
55
|
+
registers domain planning plus the separate transaction tools. MCP annotations remain truthful:
|
|
56
|
+
the autonomous rewrite tools advertise `readOnlyHint: false` and `destructiveHint: true`. Those
|
|
57
|
+
annotations do not mandate a client prompt, and the server cannot override its host's approval
|
|
58
|
+
policy.
|
|
59
|
+
|
|
60
|
+
Internally, both write policies call the same transaction core. A journal includes the complete affected-file set, before/after hashes and blobs, operation
|
|
53
61
|
provenance, validation, source/binary/visual diffs, expiry, principal, workspace/root fingerprint,
|
|
54
62
|
and plan hash. Its complete mutable journal is HMAC-authenticated by a random key beneath the
|
|
55
63
|
isolated `serverStateRoot`; a protected latest-revision head prevents replay and bounds state to one
|
|
56
64
|
head per admitted cache journal.
|
|
57
65
|
|
|
58
|
-
|
|
66
|
+
In autonomous mode, the domain tool plans and validates, admits the journal, applies, rebuilds the
|
|
67
|
+
index, and post-validates inside one call. Apply acquires one workspace write lock, rechecks
|
|
68
|
+
preconditions, stages files on the same volume, and journals deterministic replacements. Failure
|
|
69
|
+
and startup recovery restore original blobs automatically. This is recoverable logical atomicity;
|
|
70
|
+
another process can briefly observe a replacement sequence, but the server never reports success
|
|
71
|
+
for a partial result.
|
|
72
|
+
|
|
73
|
+
Git provides durable project history and collaboration. The internal journal is deliberately
|
|
74
|
+
independent of Git so failed multi-file writes recover even in an unversioned workspace.
|
|
59
75
|
|
|
60
76
|
Detailed decisions are recorded in [ADRs](adr/README.md).
|
package/docs/artifacts.md
CHANGED
|
@@ -6,6 +6,8 @@ Tools return compact summaries and links. Content is stored by SHA-256 under the
|
|
|
6
6
|
hoi4-agent://workspace/{workspaceId}/artifact/{sha256}/{provenanceHash}/{name}
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
+
An applied autonomous rewrite returns a source-linked `*.execution-validation.json` resource with the complete pre-write and post-write checks, final target hashes, diagnostics, and any overflow-validation resource links. This public evidence omits the engine's internal transaction ID and plan hash.
|
|
10
|
+
|
|
9
11
|
Each version-2 manifest records name, MIME type, byte size, content hash, artifact kind,
|
|
10
12
|
tool/schema version, SHA-256 source hashes, render profile, domain metadata, and hash-only bindings
|
|
11
13
|
for the resolved workspace and its configured or runtime owner. Filesystem paths and raw principals
|
|
@@ -83,7 +85,8 @@ artifact root beneath `storageRoots`, separate from its explicit cache root. Art
|
|
|
83
85
|
roots cannot overlap each other or a source root.
|
|
84
86
|
|
|
85
87
|
Generated artifact writes never make the game, dependency, or fixture source writable. Source
|
|
86
|
-
changes
|
|
88
|
+
changes use a separate autonomous-rewrite or reviewed-transaction surface and are confined to the
|
|
89
|
+
mod root.
|
|
87
90
|
|
|
88
91
|
## Retention quotas
|
|
89
92
|
|
|
@@ -100,8 +103,8 @@ provenance manifest still counts as an entry and consumes its serialized bytes.
|
|
|
100
103
|
process, the store measures current usage under an in-process per-root write queue before adding
|
|
101
104
|
immutable files. Multi-artifact operations preflight all logical writes and their projected
|
|
102
105
|
normal/chunk/index entries as one batch before payload copying or hashing, then retain newly created
|
|
103
|
-
content and manifests only if their owning operation commits. A failed
|
|
104
|
-
|
|
106
|
+
content and manifests only if their owning operation commits. A failed rewrite-journal admission
|
|
107
|
+
removes the diff files created by that batch without deleting pre-existing shared
|
|
105
108
|
content or provenance. If the complete content and manifest would exceed a count, aggregate-byte,
|
|
106
109
|
or per-object ceiling, the store refuses the write with `ARTIFACT_STORAGE_LIMIT`,
|
|
107
110
|
`ARTIFACT_LOGICAL_BATCH_LIMIT`, `ARTIFACT_SINGLE_LIMIT`, `ARTIFACT_CHUNK_INDEX_LIMIT`, or
|
|
@@ -110,7 +113,7 @@ also refuses when an externally modified store is already over its configured re
|
|
|
110
113
|
|
|
111
114
|
Artifact retention has no automatic garbage collector. Operator deletion is explicit and should
|
|
112
115
|
be coordinated with active requests; deleting an artifact invalidates its URI. In contrast,
|
|
113
|
-
|
|
116
|
+
internal journal cleanup follows the separate rules in [autonomous rewrites and transactions](transactions.md). Do not
|
|
114
117
|
share one writable artifact root between uncoordinated server processes; an operating-system
|
|
115
118
|
storage service or operator must provide that coordination.
|
|
116
119
|
|
|
@@ -120,7 +123,7 @@ Typical artifacts:
|
|
|
120
123
|
- focus HTML/SVG/PNG/JSON, generated-source maps, and hash-bound planning sidecars;
|
|
121
124
|
- GUI renders, galleries, hierarchy/click maps, comparisons, and fidelity reports;
|
|
122
125
|
- map layers, changed-pixel reports, and before/after previews;
|
|
123
|
-
-
|
|
126
|
+
- rewrite journals, source diffs, binary diffs, and validation reports.
|
|
124
127
|
|
|
125
128
|
Structured JSON evidence records source paths, hashes, frame numbers, dimensions, formats, and
|
|
126
129
|
fidelity metadata, but strips embedded `data:` payloads and glyph bitmap bytes. Composite SVG and
|
|
@@ -1,162 +1,122 @@
|
|
|
1
|
-
# Completion report: 0.1.
|
|
1
|
+
# Completion report: 0.1.7 public release
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
- Report date: 2026-07-11
|
|
5
|
-
- Status: complete; public delivery and installation independently verified
|
|
6
|
-
- Release commit: `a7eeb31532c067fa2fe4e297f1710615b49a1273`
|
|
7
|
-
- Annotated tag object: `4933d5bc28cc7941304d8573fcc1fea65ad74328`
|
|
8
|
-
- Exact-source CI: [run 29161368937](https://github.com/klimPaskov/hoi4-agent-tools/actions/runs/29161368937)
|
|
9
|
-
- Release workflow: [run 29161750887](https://github.com/klimPaskov/hoi4-agent-tools/actions/runs/29161750887)
|
|
3
|
+
> Historical release record. Version 0.2.0 supersedes the agent-facing write workflow described here; see [ADR 0012](adr/0012-autonomous-rewrites.md) and the current workflow documentation.
|
|
10
4
|
|
|
11
|
-
|
|
5
|
+
- Released version: `0.1.7`
|
|
6
|
+
- Report date: 2026-07-12
|
|
7
|
+
- Status: complete; public delivery, installation, and a real external-workspace transaction are verified
|
|
8
|
+
- Release commit: `9718388626a29dc4b584ae235bdbe325689e44b0`
|
|
9
|
+
- Annotated tag object: `d06a18d106a53007e12a202468cd85356ca91ef7`
|
|
10
|
+
- Exact-source CI: [run 29183088020](https://github.com/klimPaskov/hoi4-agent-tools/actions/runs/29183088020)
|
|
11
|
+
- Release workflow: [run 29183455724](https://github.com/klimPaskov/hoi4-agent-tools/actions/runs/29183455724)
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
## Outcome
|
|
14
14
|
|
|
15
|
-
The
|
|
15
|
+
The release provides one source-preserving engine for the Focus Tree Workbench, Scripted GUI Studio, Agent Nudger map workflow, MCP handlers, workspace resolution, Clausewitz parsing, symbol indexing, diagnostics, configuration, transactions, artifacts, diffs, and rollback data. It starts read-only, supports local stdio and secured Streamable HTTP, and is published as an installable package, a dual-platform container, an immutable GitHub Release, and an active/latest MCP Registry server.
|
|
16
|
+
|
|
17
|
+
The coding agent selects the server from repository and task context once its MCP host has a persistent registration. No special activation phrase or background daemon is required. The public documentation covers pinned `npx`, optional global installation, durable configuration, Codex and generic client registration, self-hosted HTTP, safe transactions, and large focus-tree repair and creation.
|
|
18
|
+
|
|
19
|
+
Version `0.1.7` additionally qualifies:
|
|
20
|
+
|
|
21
|
+
- uniform `reviewScale` output for large national-tree baseline, transaction, and final artifacts without changing logical geometry or compiled coordinates;
|
|
22
|
+
- exact import, schema, compilation, and targeted-update support for safe symbolic focus-cost constants;
|
|
23
|
+
- complete proposed and post-write focus diagnostics as MCP resources while the bounded inline/manifest limits remain enforced;
|
|
24
|
+
- sidecar-aware post-write focus validation without treating adjacent JSON planning metadata as Clausewitz focus source;
|
|
25
|
+
- agent-first discovery and setup wording, with no human-request activation framing.
|
|
26
|
+
|
|
27
|
+
No installed-game data, external-mod data, local configuration, runtime artifacts, test fixtures, source files, or tests are included in the npm payload.
|
|
16
28
|
|
|
17
29
|
## Qualification evidence
|
|
18
30
|
|
|
19
|
-
|
|
31
|
+
All 46 portable test files passed: 503 tests passed and one POSIX-only case was intentionally skipped on Windows. Enforced coverage is 88.58% statements, 78.34% branches, 91.38% functions, and 90.03% lines.
|
|
20
32
|
|
|
21
|
-
|
|
33
|
+
The release gate and exact-source CI also verified:
|
|
22
34
|
|
|
23
|
-
-
|
|
24
|
-
-
|
|
25
|
-
-
|
|
26
|
-
-
|
|
27
|
-
-
|
|
28
|
-
- official MCP
|
|
29
|
-
-
|
|
30
|
-
-
|
|
31
|
-
-
|
|
32
|
-
- read-only production-container checks proving OAuth metadata discovery, unauthenticated `401`, invalid-Origin `403`, protocol-only stdio initialization/discovery of all 26 tools, and a real read-only `hoi4.project_status` call from the non-root Node 22.23.1 runtime;
|
|
33
|
-
- reusable bounded GUI helper templates, source-valid typed helper output, explicit state variants, deterministic scrolling and static meter handoffs, and refusal tests for unsafe or ambiguous helper compilation;
|
|
34
|
-
- explicit even-odd province polygons with raster-boundary bounds checking before rasterization, pixel-center sampling, and refusal rather than clipping;
|
|
35
|
-
- interrupted GitHub release recovery through a uniquely selected, byte-verified draft without asset overwrite or deletion, followed by exact immutable-release verification;
|
|
36
|
-
- three installed-data qualifications covering a large vanilla/external focus workflow, a real GUI/GFX/font graph with deterministic full/annotated renders, and full province-map scan/render/storage without launching the game; the 302,497,021-byte canonical GUI graph was stored exactly as three bounded resources plus its one-read index while the default 128 MiB per-object ceiling remained enabled;
|
|
37
|
-
- deterministic cold/warm benchmark output for the 255-focus, 203-visible-element GUI, and all-layer map workloads, including same-size/same-mtime content-hash invalidation.
|
|
35
|
+
- deterministic project-owned focus, GUI, and map fixtures and generated schemas;
|
|
36
|
+
- a 417-file package allowlist and clean installed entry points;
|
|
37
|
+
- official MCP Inspector discovery against the production stdio server;
|
|
38
|
+
- Node 22 and 24 on Windows and Linux plus the production container build;
|
|
39
|
+
- zero dependency vulnerabilities, 448 dependency registry signatures, and 128 dependency attestations in the pinned release checkout;
|
|
40
|
+
- live official MCP Registry schema/API validation;
|
|
41
|
+
- strict tag, main ancestry, release ordering, immutable-release settings, and exact artifact identity;
|
|
42
|
+
- stdio stdout isolation, authenticated/Origin-validated Streamable HTTP, limits, isolation, progress, cancellation, sessions, and resource reads;
|
|
43
|
+
- source preservation, deterministic rendering, bitmap diffs, stale-plan rejection, atomic multi-file apply, post-write validation, exact rollback, symlink/path/cross-workspace security, and end-to-end coding-agent workflows.
|
|
38
44
|
|
|
39
|
-
|
|
45
|
+
Independent final code and documentation reviews found no actionable defects. The code review covered symbolic cost preservation, uniform review scaling, complete diagnostic resources, capacity accounting, rollback behavior, sidecar filtering, and security boundaries.
|
|
40
46
|
|
|
41
47
|
## Public delivery status
|
|
42
48
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
the exact two-platform GHCR image with SPDX SBOM and SLSA v0.2 provenance attached to each runtime
|
|
52
|
-
manifest. BuildKit correctly resolved its Git context URI to the immutable commit while recording
|
|
53
|
-
the exact release tag and workflow identity in the provenance environment; the verifier had
|
|
54
|
-
incorrectly required the URI itself to retain the tag. GitHub Release, MCP Registry, and final
|
|
55
|
-
public verification were skipped. The npm `0.1.3` bytes, GHCR `0.1.3` digest, and tag are retained
|
|
56
|
-
as immutable audit evidence.
|
|
57
|
-
|
|
58
|
-
The immutable `v0.1.4` release attempt published and independently verified npm and the exact
|
|
59
|
-
two-platform GHCR image, then staged a four-asset GitHub draft with the expected names, sizes,
|
|
60
|
-
SHA-256 digests, upload states, and GitHub Actions bot ownership. The live Releases API represented
|
|
61
|
-
the omitted optional asset label as an empty string while the verifier accepted only `null`, so the
|
|
62
|
-
draft remained unpublished. MCP Registry and final public verification were skipped. The npm
|
|
63
|
-
`0.1.4` bytes, GHCR `0.1.4` digest, tag, draft, and draft assets are retained as immutable or
|
|
64
|
-
unchanged audit evidence.
|
|
65
|
-
|
|
66
|
-
The immutable `v0.1.5` release attempt published and independently verified npm, the exact
|
|
67
|
-
two-platform GHCR image with attestations, an immutable four-asset GitHub Release, and an
|
|
68
|
-
active/latest official MCP Registry record. Its final cross-surface verifier stopped because the
|
|
69
|
-
Registry canonically omitted explicit `isSecret: false`; the pinned official schema defines false
|
|
70
|
-
as that field's default. Every public object had already passed its dedicated publication gate and
|
|
71
|
-
remains unchanged as audit evidence.
|
|
72
|
-
|
|
73
|
-
The `v0.1.6` workflow completed every validation, writer, and final verification job. Independent
|
|
74
|
-
post-release audits then downloaded the public bytes again without changing release state.
|
|
75
|
-
|
|
76
|
-
| Surface | Verified public evidence | Status |
|
|
77
|
-
| -------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- |
|
|
78
|
-
| GitHub source | Public repository, annotated tag object `4933d5bc...`, and peeled commit `a7eeb315...` | Verified |
|
|
79
|
-
| npm | `hoi4-agent-tools@0.1.6`, exact tarball bytes, Registry signature, npm publish attestation, and SLSA provenance v1 | Verified |
|
|
80
|
-
| GitHub release | Immutable [Release v0.1.6](https://github.com/klimPaskov/hoi4-agent-tools/releases/tag/v0.1.6), ID `352573210`, with exactly four byte-verified assets | Verified |
|
|
81
|
-
| GHCR | Anonymous `ghcr.io/klimpaskov/hoi4-agent-tools:0.1.6` index with exact amd64/arm64 runtimes and per-runtime SPDX/SLSA attestations | Verified |
|
|
82
|
-
| MCP Registry | Exact `io.github.klimPaskov/hoi4-agent-tools@0.1.6` record, strict-equal to `server.json`, with official `active` and `isLatest: true` state | Verified |
|
|
83
|
-
| Public install | Clean npm install, signature/attestation audit, setup diagnostics, stdio initialization/discovery, and authenticated Streamable HTTP session/resource/progress/cancellation checks | Verified |
|
|
49
|
+
| Surface | Verified public evidence | Status |
|
|
50
|
+
| -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------ | -------- |
|
|
51
|
+
| GitHub source | Public repository, annotated tag object `d06a18d...`, peeled commit `97183886...`, and green exact-source CI | Verified |
|
|
52
|
+
| npm | `hoi4-agent-tools@0.1.7`, Registry signature, npm publish attestation, and SLSA provenance v1 | Verified |
|
|
53
|
+
| GitHub Release | Immutable [Release v0.1.7](https://github.com/klimPaskov/hoi4-agent-tools/releases/tag/v0.1.7), ID `352694363`, with exactly four byte-verified assets | Verified |
|
|
54
|
+
| GHCR | Anonymous `ghcr.io/klimpaskov/hoi4-agent-tools:0.1.7` OCI index with exact amd64/arm64 runtimes and attached attestations | Verified |
|
|
55
|
+
| MCP Registry | Exact `io.github.klimPaskov/hoi4-agent-tools@0.1.7` record with official `active` and `isLatest: true` state | Verified |
|
|
56
|
+
| Public install | Clean install, signature/attestation audit, stdio discovery, and authenticated Streamable HTTP qualification | Verified |
|
|
84
57
|
|
|
85
58
|
### npm and provenance
|
|
86
59
|
|
|
87
|
-
- Published at `2026-07-
|
|
88
|
-
- Tarball: `
|
|
89
|
-
- SHA-1: `
|
|
90
|
-
- SHA-256: `
|
|
91
|
-
- SRI: `sha512-
|
|
92
|
-
- The npm and GitHub Release tarballs are byte-identical.
|
|
93
|
-
Registry signature, npm publish attestation, and SLSA provenance v1 with Rekor log index
|
|
94
|
-
`2145861311`. The provenance binds `release.yml`, `refs/tags/v0.1.6`, release commit
|
|
95
|
-
`a7eeb31532c067fa2fe4e297f1710615b49a1273`, and workflow run `29161750887`.
|
|
60
|
+
- Published at `2026-07-12T07:09:58.926Z`; `latest` resolves to `0.1.7`.
|
|
61
|
+
- Tarball: `688,684` bytes at `https://registry.npmjs.org/hoi4-agent-tools/-/hoi4-agent-tools-0.1.7.tgz`.
|
|
62
|
+
- SHA-1: `6c34d998f664b846de4a9b60a6dbadd39898a6cc`.
|
|
63
|
+
- SHA-256: `e0c08ca4db2347dfadc767eea230d4c24071b6f54b1927c7e2a9aa2eec524b0e`.
|
|
64
|
+
- SRI: `sha512-PmCgPyh/qA5dj6jgCpMKsKqFcQCVk0PdMa2PwATfcJ4EETbKgknJEKuaxHLb+UoPaFiDkHSQEJu2fF/UV8EGfQ==`.
|
|
65
|
+
- The npm and GitHub Release tarballs are byte-identical. The npm publish attestation is recorded at Rekor log index `2148574615`; SLSA provenance v1 is recorded at index `2148573874` and binds `release.yml`, `refs/tags/v0.1.7`, release commit `9718388626a29dc4b584ae235bdbe325689e44b0`, and release run `29183455724`.
|
|
96
66
|
|
|
97
67
|
### Immutable GitHub Release
|
|
98
68
|
|
|
99
|
-
The GitHub Actions bot published Release ID `
|
|
100
|
-
draft nor a prerelease and reports `immutable: true`. Its body exactly matches tagged
|
|
101
|
-
`CHANGELOG.md`. All assets have canonical empty labels, uploaded state, the canonical bot uploader,
|
|
102
|
-
and API digest/size values matching independently downloaded bytes:
|
|
69
|
+
The GitHub Actions bot published Release ID `352694363` at `2026-07-12T07:15:14Z`. It is neither a draft nor a prerelease and reports `immutable: true`.
|
|
103
70
|
|
|
104
71
|
| Asset | Bytes | SHA-256 |
|
|
105
72
|
| ---------------------------- | ------: | ------------------------------------------------------------------ |
|
|
106
|
-
| `container-image.json` | 361 | `
|
|
107
|
-
| `hoi4-agent-tools-0.1.
|
|
108
|
-
| `npm-pack.json` |
|
|
109
|
-
| `release-identity.json` | 431 | `
|
|
73
|
+
| `container-image.json` | 361 | `06695fa817a1ac9bc2fbb94840c817732875fec0988fe6caa23d46fec75983cb` |
|
|
74
|
+
| `hoi4-agent-tools-0.1.7.tgz` | 688,684 | `e0c08ca4db2347dfadc767eea230d4c24071b6f54b1927c7e2a9aa2eec524b0e` |
|
|
75
|
+
| `npm-pack.json` | 50,050 | `9417225028ae5f516c5f727785eedf8764842d96e98a9674caab0c671dea3312` |
|
|
76
|
+
| `release-identity.json` | 431 | `49318a7d830e410520e61c6d7f9e67af2be8f072ecde50645f2d19cb962c5a79` |
|
|
110
77
|
|
|
111
78
|
### GHCR image and attestations
|
|
112
79
|
|
|
113
|
-
- OCI index: `sha256:
|
|
114
|
-
- `linux/amd64`: `sha256:
|
|
115
|
-
- `linux/arm64`: `sha256:
|
|
116
|
-
- The index
|
|
117
|
-
runtime has one SPDX 2.3 and one SLSA v0.2 statement whose sole SHA-256 subject is that runtime
|
|
118
|
-
digest. Provenance binds `Dockerfile`, `publish_image`, `refs/tags/v0.1.6`, the release workflow,
|
|
119
|
-
and the exact commit.
|
|
120
|
-
- A fresh pull with an empty Docker configuration succeeded anonymously. A non-root, read-only,
|
|
121
|
-
network-disabled stdio smoke negotiated MCP `2025-11-25`, reported version `0.1.6`, and listed 26
|
|
122
|
-
tools. The default HTTP entry point also returned an authenticated Streamable HTTP initialization.
|
|
80
|
+
- OCI index: `sha256:b9651c3647d6f0efe563f82a7973ab4dcde7165546507a7fe6e4e429b0c31f0c`.
|
|
81
|
+
- `linux/amd64`: `sha256:c4927b19b736ced1e528694e8f53bffd8f28066463ab806eacce1ee064715741`.
|
|
82
|
+
- `linux/arm64`: `sha256:372c9ac76ced1cd7afb03e985cbb17855f9e44500257ca816c5f376ad233db7b`.
|
|
83
|
+
- The index exposes exactly two runtime manifests and one attached attestation manifest per runtime. The checked-in release workflow verifies SPDX SBOM and SLSA statements, anonymous access, exact source identity, non-root execution, read-only container behavior, and both supported architectures.
|
|
123
84
|
|
|
124
85
|
### MCP Registry and public installation
|
|
125
86
|
|
|
126
|
-
The
|
|
127
|
-
|
|
128
|
-
|
|
87
|
+
The official Registry returned `io.github.klimPaskov/hoi4-agent-tools@0.1.7` with `status: active` and `isLatest: true`. `publishedAt`, `updatedAt`, and `statusChangedAt` are all `2026-07-12T07:15:29.426439Z`.
|
|
88
|
+
|
|
89
|
+
A fresh independent public install fetched 132 packages. Its signature audit verified 131 installed-package signatures and 17 attestations with no invalid or missing records. Installed stdio and authenticated, Origin-validated Streamable HTTP initialization/discovery and protocol workflows passed.
|
|
90
|
+
|
|
91
|
+
## Real large-focus transaction proof
|
|
92
|
+
|
|
93
|
+
The published `0.1.7` stdio server was exercised against a 238-focus external mod workspace without copying that workspace into this repository or package.
|
|
129
94
|
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
95
|
+
- Baseline import preserved all 238 focus IDs and symbolic costs and reported 15 avoidable connector crossings.
|
|
96
|
+
- The structured plan used 14 branch groups, 12 ordered lanes, 16 fixed anchors, and 222 automatically placed nodes.
|
|
97
|
+
- The proposed layout has 238 unique coordinates, zero parent-order violations, zero connector-crossing findings, and zero errors or blockers.
|
|
98
|
+
- Source and semantic projections are byte-identical after normalising only focus `x`/`y` and `continuous_focus_position`; prerequisites, exclusions, rewards, triggers, comments, unknown fields, raw blocks, ordering, encoding, and symbolic costs are preserved.
|
|
99
|
+
- The dry run emitted one complete transaction-diff page with 14 artifacts. A second fresh dry run reproduced every non-manifest artifact byte-for-byte.
|
|
100
|
+
- A public-package apply passed all eight validation checks. Explicit rollback restored the exact baseline source hash and removed the newly created planning sidecar. A fresh transaction was then applied and retained.
|
|
101
|
+
- Final scan/lint/render recovered all planning metadata and reproduced the reviewed 6317 by 1997 PNG exactly at `reviewScale: 0.4`.
|
|
102
|
+
- Complete proposed and post-write diagnostic resources retained 116 content-specific repeated-reward warnings with zero hard findings. The fixed transaction diagnostic ceiling was not raised or bypassed.
|
|
137
103
|
|
|
138
104
|
## Acceptance coverage
|
|
139
105
|
|
|
140
|
-
| Acceptance source | Completion evidence
|
|
141
|
-
| ------------------------------------------------- |
|
|
142
|
-
| `00_standalone_project_bootstrap.md` | Independent public Git repository, Apache-2.0 licensing, project-owned instructions/docs/tests/workflows, installable npm package, immutable Release, and Registry metadata
|
|
143
|
-
| `01_shared_architecture.md` | One engine and shared workspace/source/index/diagnostic/configuration/transaction/artifact services
|
|
144
|
-
| `02_focus_tree_workbench.md` |
|
|
145
|
-
| `03_scripted_gui_studio.md` | Deterministic full/crop/annotation/state/resolution/click-region/hierarchy/comparison rendering, source
|
|
146
|
-
| `04_agent_nudger.md` | Declarative state/province/geometry/region/adjacency/supply/railway transactions, global ID/color scans, split-data blockers, map artifacts, and rollback tests
|
|
147
|
-
| `05_validation_delivery_and_agent_integration.md` |
|
|
148
|
-
| `06_public_mcp_server.md` | Read-only-default stdio and secured Streamable HTTP, OAuth/origin/isolation/limit checks, typed handlers, resource-backed
|
|
106
|
+
| Acceptance source | Completion evidence |
|
|
107
|
+
| ------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
108
|
+
| `00_standalone_project_bootstrap.md` | Independent public Git repository, Apache-2.0 licensing, project-owned instructions/docs/tests/workflows, installable npm package, immutable Release, and Registry metadata |
|
|
109
|
+
| `01_shared_architecture.md` | One engine and shared workspace/source/index/diagnostic/configuration/transaction/artifact services across Focus, GUI, map, and MCP tests |
|
|
110
|
+
| `02_focus_tree_workbench.md` | Source-preserving import/layout/lint/render/create/update workflows, complex route metadata, deterministic HTML/SVG/PNG/JSON, and source-linked diagnostics |
|
|
111
|
+
| `03_scripted_gui_studio.md` | Deterministic full/crop/annotation/state/resolution/click-region/hierarchy/comparison rendering, integrated source graphs, bitmap diffs, and mandatory fidelity reports |
|
|
112
|
+
| `04_agent_nudger.md` | Declarative state/province/geometry/region/adjacency/supply/railway transactions, global ID/color scans, split-data blockers, map artifacts, and rollback tests |
|
|
113
|
+
| `05_validation_delivery_and_agent_integration.md` | 503 portable tests, enforced coverage, synthetic CI fixtures, installed-data qualification, official Inspector, package/install checks, and coding-agent workflows |
|
|
114
|
+
| `06_public_mcp_server.md` | Read-only-default stdio and secured Streamable HTTP, OAuth/origin/isolation/limit checks, typed handlers, resource-backed artifacts, package/Release/GHCR/Registry publication, and client examples |
|
|
149
115
|
|
|
150
116
|
## Simplifications, omissions, and blockers
|
|
151
117
|
|
|
152
|
-
No required feature was replaced by a mock tool, static placeholder diagram, manual editor,
|
|
153
|
-
interactive dashboard, game automation, or unpublished package. No required acceptance item or
|
|
154
|
-
release blocker remains. Engine-unknown syntax and renderer fields are preserved and explicitly
|
|
155
|
-
reported through refusal diagnostics and fidelity reports; the supported boundaries are listed in
|
|
156
|
-
[Known limitations](limitations.md), not hidden behind fallback rewrites.
|
|
118
|
+
No required feature was replaced by a mock tool, static placeholder diagram, manual editor, interactive dashboard, game automation, or unpublished package. No required acceptance item or release blocker remains.
|
|
157
119
|
|
|
158
|
-
|
|
159
|
-
audit evidence. One independent post-release Registry read timed out and succeeded on retry; it did
|
|
160
|
-
not affect the green release workflow or repeated successful verification.
|
|
120
|
+
Engine-unknown syntax and renderer fields are preserved and explicitly reported through refusal diagnostics and fidelity reports. Supported boundaries remain listed in [Known limitations](limitations.md), not hidden behind fallback rewrites. The real external focus workflow deliberately preserved 116 gameplay-design warnings because it was a layout-only transaction; those warnings are reported above and are not suppressed by the server.
|
|
161
121
|
|
|
162
|
-
Detailed commands
|
|
122
|
+
Detailed release commands, ordering, recovery behavior, and the immutable earlier release-attempt history remain in [Release and MCP Registry publication](release.md).
|