hoi4-agent-tools 0.1.6 → 0.1.7

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.
Files changed (78) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/README.md +21 -10
  3. package/dist/bin/setup.js +33 -3
  4. package/dist/bin/setup.js.map +1 -1
  5. package/dist/hoi4_agent_tools/core/index.d.ts.map +1 -1
  6. package/dist/hoi4_agent_tools/core/index.js +10 -2
  7. package/dist/hoi4_agent_tools/core/index.js.map +1 -1
  8. package/dist/hoi4_agent_tools/focus/compiler.d.ts +2 -1
  9. package/dist/hoi4_agent_tools/focus/compiler.d.ts.map +1 -1
  10. package/dist/hoi4_agent_tools/focus/compiler.js +12 -2
  11. package/dist/hoi4_agent_tools/focus/compiler.js.map +1 -1
  12. package/dist/hoi4_agent_tools/focus/importer.d.ts.map +1 -1
  13. package/dist/hoi4_agent_tools/focus/importer.js +13 -2
  14. package/dist/hoi4_agent_tools/focus/importer.js.map +1 -1
  15. package/dist/hoi4_agent_tools/focus/layout.d.ts.map +1 -1
  16. package/dist/hoi4_agent_tools/focus/layout.js +165 -42
  17. package/dist/hoi4_agent_tools/focus/layout.js.map +1 -1
  18. package/dist/hoi4_agent_tools/focus/lint.d.ts.map +1 -1
  19. package/dist/hoi4_agent_tools/focus/lint.js +37 -8
  20. package/dist/hoi4_agent_tools/focus/lint.js.map +1 -1
  21. package/dist/hoi4_agent_tools/focus/model.d.ts +5 -1
  22. package/dist/hoi4_agent_tools/focus/model.d.ts.map +1 -1
  23. package/dist/hoi4_agent_tools/focus/model.js +2 -0
  24. package/dist/hoi4_agent_tools/focus/model.js.map +1 -1
  25. package/dist/hoi4_agent_tools/focus/presentation.d.ts.map +1 -1
  26. package/dist/hoi4_agent_tools/focus/presentation.js +13 -5
  27. package/dist/hoi4_agent_tools/focus/presentation.js.map +1 -1
  28. package/dist/hoi4_agent_tools/focus/render.d.ts +4 -0
  29. package/dist/hoi4_agent_tools/focus/render.d.ts.map +1 -1
  30. package/dist/hoi4_agent_tools/focus/render.js +17 -3
  31. package/dist/hoi4_agent_tools/focus/render.js.map +1 -1
  32. package/dist/hoi4_agent_tools/focus/service.d.ts.map +1 -1
  33. package/dist/hoi4_agent_tools/focus/service.js +138 -79
  34. package/dist/hoi4_agent_tools/focus/service.js.map +1 -1
  35. package/dist/hoi4_agent_tools/focus/source-update.d.ts.map +1 -1
  36. package/dist/hoi4_agent_tools/focus/source-update.js +9 -4
  37. package/dist/hoi4_agent_tools/focus/source-update.js.map +1 -1
  38. package/dist/hoi4_agent_tools/mcp/prompts/register.js +3 -3
  39. package/dist/hoi4_agent_tools/mcp/prompts/register.js.map +1 -1
  40. package/dist/hoi4_agent_tools/mcp/registry/metadata.d.ts +1 -1
  41. package/dist/hoi4_agent_tools/mcp/resources/register.d.ts.map +1 -1
  42. package/dist/hoi4_agent_tools/mcp/resources/register.js +1 -0
  43. package/dist/hoi4_agent_tools/mcp/resources/register.js.map +1 -1
  44. package/dist/hoi4_agent_tools/mcp/server/base-tools.d.ts.map +1 -1
  45. package/dist/hoi4_agent_tools/mcp/server/base-tools.js +63 -3
  46. package/dist/hoi4_agent_tools/mcp/server/base-tools.js.map +1 -1
  47. package/dist/hoi4_agent_tools/mcp/server/create.js +1 -1
  48. package/dist/hoi4_agent_tools/mcp/server/create.js.map +1 -1
  49. package/dist/hoi4_agent_tools/mcp/tools/focus.d.ts.map +1 -1
  50. package/dist/hoi4_agent_tools/mcp/tools/focus.js +63 -8
  51. package/dist/hoi4_agent_tools/mcp/tools/focus.js.map +1 -1
  52. package/dist/hoi4_agent_tools/schemas/focus.d.ts +1 -1
  53. package/dist/hoi4_agent_tools/schemas/focus.d.ts.map +1 -1
  54. package/dist/hoi4_agent_tools/schemas/focus.js +16 -2
  55. package/dist/hoi4_agent_tools/schemas/focus.js.map +1 -1
  56. package/dist/hoi4_agent_tools/version.d.ts +1 -1
  57. package/dist/hoi4_agent_tools/version.js +1 -1
  58. package/docs/README.md +2 -1
  59. package/docs/agent-integration.md +136 -0
  60. package/docs/completion-report.md +97 -27
  61. package/docs/configuration.md +6 -2
  62. package/docs/focus-workflow.md +130 -3
  63. package/docs/limitations.md +1 -0
  64. package/docs/release.md +10 -7
  65. package/docs/self-hosting.md +2 -2
  66. package/docs/transactions.md +6 -0
  67. package/package.json +6 -2
  68. package/schemas/configuration.schema.json +1 -1
  69. package/schemas/continuous-focus-palette.schema.json +1 -1
  70. package/schemas/focus-plan.schema.json +74 -49
  71. package/schemas/focus-planning-sidecar.schema.json +33 -18
  72. package/schemas/gui-animation-source.schema.json +1 -1
  73. package/schemas/gui-helper.schema.json +1 -1
  74. package/schemas/gui-scenario.schema.json +1 -1
  75. package/schemas/map-operation.schema.json +1 -1
  76. package/schemas/operation-result.schema.json +1 -1
  77. package/schemas/transaction-manifest.schema.json +1 -1
  78. package/server.json +4 -4
@@ -0,0 +1,136 @@
1
+ # Agent integration and autonomous tool selection
2
+
3
+ HOI4 Agent Tools is a capability server for coding agents. Once an MCP-compatible host has a persistent server registration, the coding agent should decide when to invoke it from the task and repository context. The server does not need a special activation phrase and does not replace the agent's planning, research, or source-control workflow.
4
+
5
+ ## Persistent local availability
6
+
7
+ Use a durable server configuration and a pinned package version. The MCP host launches the stdio process when needed, so no background daemon or manual server window is required.
8
+
9
+ Suggested durable configuration locations:
10
+
11
+ - Windows: `%APPDATA%\hoi4-agent-tools\config.json`
12
+ - macOS: `~/.config/hoi4-agent-tools/config.json`
13
+ - Linux: `~/.config/hoi4-agent-tools/config.json`
14
+
15
+ Keep transaction 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
+
17
+ Create and validate a configuration:
18
+
19
+ ```bash
20
+ npm install --global hoi4-agent-tools@0.1.7
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
+ hoi4-agent-tools-setup --diagnose --config /absolute/path/config.json
23
+ hoi4-agent-tools-setup --print-client-config --config /absolute/path/config.json
24
+ ```
25
+
26
+ The setup utility creates a read-only configuration unless `--enable-writes` and a separate `--server-state` root are supplied. `--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
+
28
+ Generic host registration:
29
+
30
+ ```json
31
+ {
32
+ "mcpServers": {
33
+ "hoi4_agent_tools": {
34
+ "command": "npx",
35
+ "args": ["-y", "hoi4-agent-tools@0.1.7"],
36
+ "env": {
37
+ "HOI4_AGENT_CONFIG": "/absolute/path/config.json"
38
+ }
39
+ }
40
+ }
41
+ }
42
+ ```
43
+
44
+ Codex registration:
45
+
46
+ ```toml
47
+ [mcp_servers.hoi4_agent_tools]
48
+ command = "npx"
49
+ args = ["-y", "hoi4-agent-tools@0.1.7"]
50
+ startup_timeout_sec = 120
51
+
52
+ [mcp_servers.hoi4_agent_tools.env]
53
+ HOI4_AGENT_CONFIG = "/absolute/path/config.json"
54
+ ```
55
+
56
+ Use `npx.cmd` on Windows. Restart the coding-agent host after adding or changing the registration. Statically configured workspaces remain available across every server process; runtime `hoi4.project_register` registrations intentionally last only for the current process.
57
+
58
+ ## Autonomous selection rules
59
+
60
+ A coding agent should select this server when a registered HOI4 workspace task involves any of these surfaces:
61
+
62
+ - national focus trees or continuous focus palettes;
63
+ - Clausewitz prerequisite, route-lock, mutual-exclusion, localisation, icon, AI, or linked-content validation;
64
+ - scripted GUI, interface, GFX, sprites, fonts, animation states, deterministic previews, or visual comparisons;
65
+ - states, provinces, province geometry, strategic regions, adjacency, supply nodes, or railways;
66
+ - source-preserving dry runs, visual diffs, atomic multi-file apply, or rollback for those surfaces.
67
+
68
+ 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
+
70
+ The normal first calls are:
71
+
72
+ 1. `hoi4.project_status` to discover the configured workspace ID and write status.
73
+ 2. `hoi4.project_scan` when a complete shared symbol/reference revision is useful.
74
+ 3. The relevant domain scan and lint tools.
75
+ 4. Deterministic layout/render/compare tools before a source plan.
76
+
77
+ 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
+
79
+ ## Large focus-tree repair
80
+
81
+ 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
+
83
+ The safe repair sequence is:
84
+
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 transaction and final review artifacts.
86
+ 2. Read the complete imported plan resource and baseline HTML/SVG/PNG/JSON/source-map artifacts.
87
+ 3. Preserve prerequisites, exclusions, route locks, rewards, comments, raw passthrough, source locations, and provenance.
88
+ 4. Assign explicit `branchGroups`, `laneGroups`, `branchId`, and `laneId` metadata that reflect the intended route architecture.
89
+ 5. Keep only deliberate anchors fixed or pinned. Imported authored `x`/`y` values are intentionally treated as fixed; nodes do not become movable merely because `hoi4.focus_layout` was called.
90
+ 6. Change movable nodes to automatic positions, optionally retaining route intent with preferred coordinates:
91
+
92
+ ```json
93
+ {
94
+ "mode": "auto",
95
+ "pinned": false,
96
+ "preferredX": 8,
97
+ "preferredY": 12
98
+ }
99
+ ```
100
+
101
+ 7. Submit the complete plan to `hoi4.focus_plan_changes`. This performs the deterministic proposed layout, source-preserving compilation, lint, before/proposed render, bitmap comparison, and dry-run transaction. 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.
102
+ 8. Follow every `hoi4.transaction_diff` cursor. Review the source map, changed fields, diagnostics, and visual artifacts.
103
+ 9. Apply only when the coding-agent host's write policy authorizes it, using the exact transaction ID and expected plan hash.
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.
105
+
106
+ `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
+
108
+ ## Creating a large focus tree
109
+
110
+ The coding agent translates repository requirements and route descriptions into the public `FocusTreePlan` schema at `hoi4-agent://schema/focus-plan`. The MCP server validates and compiles that typed plan; it is not an unbounded natural-language generator.
111
+
112
+ A serious large-tree plan should define:
113
+
114
+ - a small number of intentional fixed anchors and automatic branch nodes;
115
+ - lane and branch groups with stable order and horizontal bounds;
116
+ - exact AND/OR prerequisite grouping;
117
+ - reciprocal route exclusions where the UI should show them;
118
+ - shared support lanes that stay available to compatible political routes;
119
+ - convergence points, capstones, failure states, hidden/reveal metadata, and late-game payoffs;
120
+ - localisation keys, icon sprites, AI weights/strategies, filters, and links to decisions, events, ideas, leaders, helpers, and formables;
121
+ - raw passthrough for unsupported or not-yet-modelled Clausewitz content.
122
+
123
+ For a new source beneath `common/national_focus`, call `hoi4.focus_plan_changes` 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 first write is still a dry-run transaction with transparent before evidence and complete proposed artifacts.
124
+
125
+ ## Write autonomy and safety boundary
126
+
127
+ Agents may autonomously discover workspaces, scan, lint, lay out, render, compare, inspect artifacts, and prepare dry-run transactions. Source apply remains a distinct capability boundary:
128
+
129
+ - global `writePolicy` must be `transactions`;
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.
135
+
136
+ This division lets agents decide when the MCP is useful and do the analysis autonomously without turning discovery into implicit source mutation.
@@ -1,18 +1,22 @@
1
- # Completion report: 0.1.6 release candidate
1
+ # Completion report: 0.1.6 public release
2
2
 
3
- - Candidate version: `0.1.6`
3
+ - Released version: `0.1.6`
4
4
  - Report date: 2026-07-11
5
- - Status: fix-forward implementation in qualification; public delivery incomplete
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)
6
10
 
7
11
  ## Implemented scope
8
12
 
9
- The release candidate provides the shared source-preserving core, Focus Tree Workbench, Scripted GUI Studio, Agent Nudger map workflow, read-only-by-default transaction controls, stdio and authenticated Streamable HTTP transports, package entry points, schemas, synthetic portable fixtures, and public deployment documentation described by this repository.
13
+ The release provides the shared source-preserving core, Focus Tree Workbench, Scripted GUI Studio, Agent Nudger map workflow, read-only-by-default transaction controls, stdio and authenticated Streamable HTTP transports, package entry points, schemas, synthetic portable fixtures, and public deployment documentation described by this repository.
10
14
 
11
15
  The npm payload is explicitly limited to compiled entry points, documentation, schemas, `server.json`, and the project license, security policy, README, and changelog. Installed-game data, third-party mod data, fixtures, tests, source files, local configuration, and workspace artifacts are excluded.
12
16
 
13
17
  ## Qualification evidence
14
18
 
15
- The candidate has passed all 46 portable test files: 495 tests passed and one POSIX case was intentionally skipped on Windows. The latest enforced coverage is 88.44% statements, 78.25% branches, 91.28% functions, and 89.90% lines.
19
+ The release passed all 46 portable test files: 495 tests passed and one POSIX case was intentionally skipped on Windows. Enforced coverage is 88.44% statements, 78.25% branches, 91.28% functions, and 89.90% lines.
16
20
 
17
21
  Release-specific qualification also covers:
18
22
 
@@ -66,27 +70,93 @@ Registry canonically omitted explicit `isSecret: false`; the pinned official sch
66
70
  as that field's default. Every public object had already passed its dedicated publication gate and
67
71
  remains unchanged as audit evidence.
68
72
 
69
- No end-to-end workflow-complete multi-surface public release is claimed in this report. The
70
- following evidence remains pending until the `0.1.6` fix-forward workflow finishes:
71
-
72
- | Surface | Required completion evidence | Status |
73
- | -------------- | --------------------------------------------------------------------------------------------------------- | ------------ |
74
- | GitHub source | Public canonical repository containing the tested commit and immutable `v0.1.6` tag | Pending |
75
- | npm | Public `hoi4-agent-tools@0.1.6` with exact tarball integrity and SLSA provenance | `0.1.5` only |
76
- | GitHub release | Immutable `v0.1.6` release containing the exact npm and container digest manifests | `0.1.5` only |
77
- | GHCR | Public anonymous `0.1.6` digest with two runtime platforms and source-bound SBOM/provenance subjects | `0.1.5` only |
78
- | MCP Registry | Exact `io.github.klimPaskov/hoi4-agent-tools@0.1.6` metadata with official `active` and `isLatest` status | `0.1.5` only |
79
- | Public install | Clean registry installation, signature audit, MCP initialization, and tool discovery | Pending |
80
-
81
- ## First-release completion sequence
82
-
83
- 1. Commit the tested candidate on `main` and push it to the canonical public repository.
84
- 2. Run the manual GHCR bootstrap workflow, make the new package public in GitHub, and verify the bootstrap index without saved credentials.
85
- 3. Create `npm-bootstrap-v0.0.0-bootstrap.1`, store a shortest-lived npm granular token only as `NPM_BOOTSTRAP_TOKEN`, and run the manual non-OIDC npm bootstrap workflow from that tag. The earlier immutable `.0` attempt stopped before publication; it is retained as audit evidence rather than rewritten.
86
- 4. Revoke and delete `NPM_BOOTSTRAP_TOKEN`, then configure npm trusted publishing for `klimPaskov/hoi4-agent-tools`, `release.yml`, and the explicit `npm publish` allowed action.
87
- 5. Preserve `v0.1.0` through `v0.1.4` as documented above, plus the immutable complete `v0.1.5` public objects whose final verifier stopped on schema-default serialization. Do not create `NPM_TOKEN`; the OIDC workflow rejects it.
88
- 6. Qualify the synchronized `0.1.6` fix-forward commit with canonical default omission and unchanged strict Registry equality, then create `v0.1.6` only from an exact green commit.
89
- 7. Allow the release workflow to publish and verify npm, digest-immutable GHCR, the immutable GitHub release, and MCP Registry in its enforced order.
90
- 8. Update this report with the commit, workflow run, public URLs, npm and image digests, and Registry status. Only then is public delivery complete.
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 |
84
+
85
+ ### npm and provenance
86
+
87
+ - Published at `2026-07-11T17:41:29.169Z`; `latest` resolves to `0.1.6`.
88
+ - Tarball: `669,550` bytes at `https://registry.npmjs.org/hoi4-agent-tools/-/hoi4-agent-tools-0.1.6.tgz`.
89
+ - SHA-1: `0b240508a9dab4bc31a84ba1733ded3eb6983390`.
90
+ - SHA-256: `b3925c8600fbb8eda44b7aaf36edb7d7bd056b84766e2b0cd6b4fa8fdbc385ce`.
91
+ - SRI: `sha512-OaWY67zCEuwNj4AQZHlGBg59BoAQlgBoJ7soV5cOD2DiVClcjdz+8z0gBB02I1UXkoxFQgCcWw8YMVkBl0iLhg==`.
92
+ - The npm and GitHub Release tarballs are byte-identical. Pinned npm `11.16.0` verified the
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`.
96
+
97
+ ### Immutable GitHub Release
98
+
99
+ The GitHub Actions bot published Release ID `352573210` at `2026-07-11T17:46:42Z`; it is neither a
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:
103
+
104
+ | Asset | Bytes | SHA-256 |
105
+ | ---------------------------- | ------: | ------------------------------------------------------------------ |
106
+ | `container-image.json` | 361 | `0830611b33f26cb24baf05a8e997512db962ad4297966aa3b7db0bd1a37da179` |
107
+ | `hoi4-agent-tools-0.1.6.tgz` | 669,550 | `b3925c8600fbb8eda44b7aaf36edb7d7bd056b84766e2b0cd6b4fa8fdbc385ce` |
108
+ | `npm-pack.json` | 49,941 | `a359bc1e0e64d119606a9c6bfb3f1a77725089e7cd5ada82c7efef839594543f` |
109
+ | `release-identity.json` | 431 | `d289937579f1e6e272264b09b4d9286a62e2c05c01a921d56dbc3d678fb5f576` |
110
+
111
+ ### GHCR image and attestations
112
+
113
+ - OCI index: `sha256:9593b77b50938a76341d293dd4ef97bb42224661a6a25dc28a1378e0109e0e5b`.
114
+ - `linux/amd64`: `sha256:bda20a48cff5d5597467e22bb53b142bcb698420b637fe5cdc1f05107e7bce0f`.
115
+ - `linux/arm64`: `sha256:52ed0aa7bf35de90f49364a94bb41fbd0136895a155af624fc26b4275631d735`.
116
+ - The index has exactly two runtime and two attached attestation manifests, without orphans. Each
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.
123
+
124
+ ### MCP Registry and public installation
125
+
126
+ The exact official Registry endpoint returned a server object strict-equal to checked-in
127
+ `server.json`, plus `status: active` and `isLatest: true`. `publishedAt`, `updatedAt`, and
128
+ `statusChangedAt` are all `2026-07-11T17:46:54.873191Z`.
129
+
130
+ A clean public installation fetched 132 packages only from `https://registry.npmjs.org`; its
131
+ lockfile had no `file:`, `workspace:`, `link:`, repository-path, or other local resolution. The
132
+ signature audit verified 131 installed package signatures and 17 attestations with no invalid or
133
+ missing records. The installed setup entry point passed help, read-only config initialization,
134
+ diagnostics, rendering probe, and client-config output. Installed stdio and authenticated,
135
+ Origin-validated Streamable HTTP passed initialization, discovery, resources, prompts, progress,
136
+ cancellation, and session deletion.
137
+
138
+ ## Acceptance coverage
139
+
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 exercised across Focus, GUI, map, and MCP acceptance tests |
144
+ | `02_focus_tree_workbench.md` | Synthetic and installed-data import/layout/lint/render workflows with deterministic HTML/SVG/PNG/JSON artifacts and source-linked diagnostics |
145
+ | `03_scripted_gui_studio.md` | Deterministic full/crop/annotation/state/resolution/click-region/hierarchy/comparison rendering, source graph integration, bitmap diffs, and mandatory fidelity reports |
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` | 495 portable tests, enforced coverage, synthetic CI fixtures, installed-data qualification, official MCP Inspector discovery, package/install tests, and end-to-end coding-agent workflows |
148
+ | `06_public_mcp_server.md` | Read-only-default stdio and secured Streamable HTTP, OAuth/origin/isolation/limit checks, typed handlers, resource-backed large artifacts, package/Release/GHCR/Registry publication, and examples |
149
+
150
+ ## Simplifications, omissions, and blockers
151
+
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.
157
+
158
+ The immutable earlier release attempts and the exact unpublished `v0.1.4` draft remain unchanged as
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.
91
161
 
92
162
  Detailed commands and failure behavior are documented in [Release and MCP Registry publication](release.md).
@@ -1,6 +1,10 @@
1
1
  # Configuration and workspaces
2
2
 
3
- Pass a config with `--config PATH` or `HOI4_AGENT_CONFIG`. Unknown fields are rejected.
3
+ Pass a config with `--config PATH` or `HOI4_AGENT_CONFIG`. Without either override, the server uses
4
+ `~/.config/hoi4-agent-tools/config.json` on every platform (for example,
5
+ `C:\\Users\\name\\.config\\hoi4-agent-tools\\config.json` on Windows). A different durable absolute
6
+ path is equally valid when the client registration sets `HOI4_AGENT_CONFIG`. Unknown fields are
7
+ rejected.
4
8
  The read-only setup discovery command also checks `HOI4_GAME_ROOT` and the path-delimited `HOI4_MOD_ROOTS`; it reports candidates without registering or modifying them.
5
9
 
6
10
  The stdio executable accepts newline-delimited JSON-RPC frames up to a fixed 16,777,216-byte
@@ -97,7 +101,7 @@ protocol when those primitives are unavailable.
97
101
  | Field | Default | Validation and behavior |
98
102
  | ----------------- | ------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
99
103
  | `id` | required | Lowercase identifier matching `[a-z][a-z0-9_-]{0,63}`; unique in the configuration. |
100
- | `name` | required | Human-readable name, 1 through 200 characters. |
104
+ | `name` | required | Display name, 1 through 200 characters. |
101
105
  | `root` | required | Primary source root. Its root kind is selected by `kind`. |
102
106
  | `kind` | `"mod"` | `"mod"`, `"game"`, or `"dependency"`. Only a mod primary root can ever be writable. |
103
107
  | `gameRoot` | omitted | Optional additional read-only base-game source; it must not overlap another source in the workspace. |
@@ -15,6 +15,11 @@ Decision categories are additive database fragments: the category definition und
15
15
  The shared index retains those fragments without reporting a duplicate-definition collision while
16
16
  still honoring same-relative-file shadowing and load-order source ownership.
17
17
 
18
+ National focus `cost` values support finite numbers and safe file-scoped constants such as
19
+ `@focus_cost_standard`. Targeted layout updates preserve the exact existing cost lexeme, including
20
+ numeric formatting and comments. A cost token outside the typed model is retained unchanged when
21
+ the plan does not explicitly replace it; the compiler refuses to generate an arbitrary scalar.
22
+
18
23
  National focuses and continuous focuses use their actual HOI4 source models. National trees come from the workspace registration's configured `roots.focus` paths. Continuous focuses come from `common/continuous_focus/*.txt` as `continuous_focus_palette = { ... focus = { ... } }`; matching country palettes take precedence over the default palette, and the compiler never emits a `continuous` field inside a national `focus = { ... }` block.
19
24
 
20
25
  ## Agent workflow
@@ -23,10 +28,125 @@ National focuses and continuous focuses use their actual HOI4 source models. Nat
23
28
  2. `hoi4.focus_scan` imports active national trees, matching continuous-focus palettes, active localisation, sprite definitions, and only the exact texture paths referenced by those sprites.
24
29
  3. `hoi4.focus_lint` separates syntax, reference, layout, and design diagnostics. Omit `mode` for national-tree compatibility, or pass `mode: "continuous"` with an optional `paletteId` to lint a palette directly.
25
30
  4. `hoi4.focus_layout` calculates stable integer coordinates. Pinned positions and existing coordinates anchor incremental changes.
26
- 5. `hoi4.focus_render` returns deterministic HTML, SVG, PNG, JSON, and generated-source-map resources. National mode also returns the graph layout and hash-bound planning sidecar; continuous mode accepts palette columns and renders the actual continuous-focus source model.
27
- 6. `hoi4.focus_plan_changes` accepts either a national plan (the backward-compatible default) or `mode: "continuous"` with a continuous-palette plan. Both make source-preserving range edits where possible and produce before/proposed/bitmap-diff review artifacts before creating the dry-run transaction. National plans also maintain the adjacent planning sidecar. To create a first tree or palette in a new mod source file, the coding agent must set `createIfMissing: true`; without that explicit flag, missing sources and IDs refuse. Creation never appends a different target to an existing source file, because doing so could repurpose unrelated source or its adjacent planning sidecar. It uses a transparent source-linked before render, never copies a read-only game/dependency file into a shadowing mod path, and rolls back newly created source and sidecar files atomically.
31
+ 5. `hoi4.focus_render` returns deterministic HTML, SVG, PNG, JSON, and generated-source-map resources. National mode also returns the graph layout and hash-bound planning sidecar; a uniform `reviewScale` from `0.25` through `1.0` keeps unusually wide or deep trees within bounded raster limits without changing logical geometry or source coordinates. Continuous mode accepts palette columns and renders the actual continuous-focus source model.
32
+ 6. `hoi4.focus_plan_changes` accepts either a national plan (the backward-compatible default) or `mode: "continuous"` with a continuous-palette plan. Both make source-preserving range edits where possible and produce before/proposed/bitmap-diff review artifacts before creating the dry-run transaction. National plans may set `horizontalSpacing`, `verticalSpacing`, `padding`, and a uniform `reviewScale` for both review renders; those pixel-space settings do not alter focus coordinates or compiled HOI4 source. National plans also maintain the adjacent planning sidecar. To create a first tree or palette in a new mod source file, the coding agent must set `createIfMissing: true`; without that explicit flag, missing sources and IDs refuse. Creation never appends a different target to an existing source file, because doing so could repurpose unrelated source or its adjacent planning sidecar. It uses a transparent source-linked before render, never copies a read-only game/dependency file into a shadowing mod path, and rolls back newly created source and sidecar files atomically.
28
33
  7. Review drift, diagnostics, source maps, diff artifacts, and plan hash before apply.
29
34
 
35
+ ## Repairing an existing large tree
36
+
37
+ Imported authored coordinates are fixed by design. A plain `hoi4.focus_layout` call therefore
38
+ audits an existing layout without silently rearranging it. To opt a badly structured tree into a
39
+ full cleanup, the coding agent must make the movement policy explicit:
40
+
41
+ 1. Scan, lint, and render the baseline, then read the complete imported plan resource. Use the same
42
+ national `reviewScale` for baseline, transaction, and final renders when the default canvas is too
43
+ large.
44
+ 2. Preserve every prerequisite group, exclusion, route lock, reward, raw passthrough entry, source
45
+ location, and provenance value.
46
+ 3. Model the intended route architecture with `branchGroups`, `laneGroups`, `branchId`, and
47
+ `laneId`. Give lanes stable order and, where appropriate, horizontal bounds.
48
+ 4. Keep only deliberate trunk or convergence anchors fixed/pinned. Change every movable focus to
49
+ `{ "mode": "auto", "pinned": false }`; `preferredX` and `preferredY` may retain the authored
50
+ route intent without making those coordinates mandatory.
51
+ 5. Submit the complete plan to `hoi4.focus_plan_changes`. The dry run performs layout, compilation,
52
+ lint, source-preserving range edits, deterministic before/proposed rendering, and bitmap diffing.
53
+ For an unusually wide or deep tree, set a uniform national `reviewScale` between `0.25` and
54
+ `1.0`; `0.4` is appropriate for a very large comparison. It scales nodes, text, connectors, and
55
+ the viewport together, avoiding artificial overlap. The same scale governs both sides of the
56
+ comparison and affects only artifact pixels, never source-grid coordinates. Explicit spacing and
57
+ padding remain available when the artifact's logical presentation itself needs adjustment.
58
+ 6. Read every `hoi4.transaction_diff` page and all linked review resources. Apply the exact
59
+ hash-bound transaction only under the coding-agent host's configured write policy.
60
+ 7. Rescan, lint, and render the applied tree. A rejected result can be restored exactly with
61
+ `hoi4.transaction_rollback` and the same transaction ID and plan hash.
62
+
63
+ This workflow is suitable for hundreds of focuses. The solver keeps parents above children,
64
+ rejects visible overlap and duplicate coordinates, separates bounded lanes, validates relative
65
+ chains, and minimizes avoidable connector crossings. It never changes gameplay relationships to
66
+ make a picture look cleaner.
67
+
68
+ ## Authoring a large tree
69
+
70
+ For a new tree, translate route requirements into the strict public schema at
71
+ `hoi4-agent://schema/focus-plan`. A robust plan uses a centered entry/trunk, bounded political or
72
+ strategic lanes, separately modelled shared-support lanes, exact AND/OR prerequisite groups,
73
+ reciprocal route exclusions, explicit convergence and capstones, automatic positions, and complete
74
+ localisation/icon/AI/link metadata. Unsupported Clausewitz blocks belong in `rawPassthrough` so they
75
+ round-trip instead of being approximated.
76
+
77
+ This minimal national plan is schema-valid. It intentionally omits an icon and reward; a production
78
+ tree should add complete presentation and gameplay data before apply:
79
+
80
+ ```json
81
+ {
82
+ "schemaVersion": 1,
83
+ "id": "example_tree",
84
+ "default": false,
85
+ "branchGroups": [
86
+ {
87
+ "id": "constitutional",
88
+ "label": "Constitutional route",
89
+ "family": "politics",
90
+ "focusIds": ["example_entry"],
91
+ "laneId": "centre",
92
+ "major": true,
93
+ "hidden": false,
94
+ "crisis": false,
95
+ "conditional": false,
96
+ "aiStrategyIds": []
97
+ }
98
+ ],
99
+ "laneGroups": [
100
+ { "id": "left", "label": "Left route", "order": 0, "minimumX": -12, "maximumX": -5 },
101
+ { "id": "centre", "label": "Constitutional trunk", "order": 1, "minimumX": -2, "maximumX": 2 },
102
+ { "id": "right", "label": "Right route", "order": 2, "minimumX": 5, "maximumX": 12 }
103
+ ],
104
+ "entryFocusIds": ["example_entry"],
105
+ "focuses": [
106
+ {
107
+ "id": "example_entry",
108
+ "label": "Example entry",
109
+ "branchId": "constitutional",
110
+ "laneId": "centre",
111
+ "prerequisites": { "operator": "and", "groups": [] },
112
+ "mutuallyExclusive": [],
113
+ "routeLocks": [],
114
+ "position": { "mode": "auto", "pinned": false, "preferredX": 0, "preferredY": 0 },
115
+ "visibility": "normal",
116
+ "convergence": false,
117
+ "sharedSupport": false,
118
+ "icons": [],
119
+ "localisation": {
120
+ "titleKey": "example_entry",
121
+ "descriptionKey": "example_entry_desc",
122
+ "workingLabel": "Example entry"
123
+ },
124
+ "ai": { "majorRoute": true, "strategyIds": [] },
125
+ "filters": ["FOCUS_FILTER_POLITICAL"],
126
+ "links": [],
127
+ "rawPassthrough": []
128
+ }
129
+ ],
130
+ "sharedFocusIds": [],
131
+ "continuousFocusPaletteIds": [],
132
+ "continuousFocusIds": [],
133
+ "rawPassthrough": [],
134
+ "provenance": {
135
+ "sourcePath": "plan:example_tree",
136
+ "sourceHash": "0000000000000000000000000000000000000000000000000000000000000000",
137
+ "importedPlanHash": "0000000000000000000000000000000000000000000000000000000000000000"
138
+ }
139
+ }
140
+ ```
141
+
142
+ Within each focus, one `prerequisites.groups` entry represents one Clausewitz `prerequisite` block
143
+ whose listed focuses are OR alternatives. Multiple group entries are AND requirements. For a new
144
+ target, use `sourcePath: "plan:<tree-id>"` and 64 zeroes for both initial hashes, then call
145
+ `hoi4.focus_plan_changes` with `createIfMissing: true`. Use that convention only for a missing
146
+ target. Existing sources normally use imported, hash-bound provenance; resolving intentional
147
+ plan/source drift additionally requires explicit `authority: "plan"`. The server refuses to append
148
+ a different tree to an occupied source file and still requires the normal dry-run/apply boundary.
149
+
30
150
  ## Prerequisite and route semantics
31
151
 
32
152
  One `prerequisite` block containing several `focus` entries is an OR group. Several prerequisite blocks are ANDed. The importer preserves that grouping exactly. It never flattens prerequisites into a graph that changes meaning.
@@ -47,7 +167,7 @@ Raster discovery is deliberately exact: the shared workspace scan does not walk
47
167
 
48
168
  ## Layout contract
49
169
 
50
- Hard constraints keep parents above children, coordinates unique, visible nodes non-overlapping, pinned nodes fixed, route lanes separated, and relative-position chains valid. The solver records every move and unsatisfied constraint. It never changes a prerequisite, silently stacks nodes, or invents a route.
170
+ Hard constraints keep parents above children, coordinates unique, visible nodes non-overlapping, automatic nodes inside configured lane bounds, pinned nodes fixed, and relative-position chains valid. Automatic preferred coordinates are clamped to their lane; a full lane raises `FOCUS_LAYOUT_LANE_CAPACITY_BLOCKED`. Fixed, relative, or prior-stable coordinates outside their declared lane are preserved as evidence but produce a blocking `FOCUS_LAYOUT_LANE_BOUNDS_VIOLATION`. The solver records every move and unsatisfied constraint. It never changes a prerequisite, silently stacks nodes, or invents a route.
51
171
 
52
172
  Mutual-exclusion relationships are also layout constraints: newly placed automatic endpoints must retain at least the configured `nodeSpacing` in horizontal focus-grid columns. Fixed, relative, pinned, and prior-layout coordinates are stability anchors. The solver does not move those anchors to improve mutual-exclusion spacing or connector routing; it emits `FOCUS_LAYOUT_MUTUAL_EXCLUSION_SPACING_UNSATISFIED` with the movable and preserved endpoints when authored constraints make the gap impossible.
53
173
 
@@ -66,3 +186,10 @@ Every compiled or proposed focus block receives a source-map entry containing th
66
186
  Each rendered node includes its ID, resolved title/working label, resolved icon frame or diagnostic, coordinates, prerequisite type, exclusions, branch family, planner visibility/convergence/terminal state, AI metadata, and source-linked diagnostics. HTML search and filters inspect evidence only; they cannot write source.
67
187
 
68
188
  National-tree renders store `<tree>.focus.html`, `.svg`, `.png`, `.json`, `.source-map.json`, and `.plan.json`. Continuous-palette renders use the same core artifact store and produce `<palette>.continuous.html`, `.svg`, `.png`, `.json`, and `.source-map.json`. The JSON embeds the same complete generated-source map that is also stored separately, and all formats carry content hashes plus source/render provenance.
189
+
190
+ A national focus transaction also stores `<tree>.focus.proposed-validation.json`. It contains every
191
+ diagnostic and validation check from re-importing, laying out, and linting the compiled proposal.
192
+ When that complete set is larger than the fixed transaction-manifest allowance, the manifest keeps
193
+ a blocker-first bounded summary and an explicit resource diagnostic; it never drops findings from
194
+ the validation decision. The generic apply boundary uses the same pattern for oversized post-write
195
+ diagnostics.
@@ -6,6 +6,7 @@ These are precise safety boundaries, not silent fallbacks.
6
6
  - Workspace scans default to 20,000 enumerated files, 134,217,728 aggregate content bytes, and 67,108,864 bytes for one file. Operators may lower these values per request but cannot raise them above server policy. Exceeding any ceiling refuses the complete scan with `SCAN_FILE_LIMIT` or `SCAN_BYTE_LIMIT`; a partial index is not returned. The configuration additionally requires aggregate scan bytes multiplied by HTTP request concurrency to remain at or below 512 MiB.
7
7
  - Stdio uses strictly decoded UTF-8 newline-delimited JSON-RPC with a fixed 16,777,216-byte frame ceiling, excluding the line-feed delimiter. A malformed UTF-8 frame is refused without replacement decoding; an oversized frame is refused as soon as it crosses the ceiling, even without a newline or end-of-input. Either condition closes the local transport without emitting protocol output. Use workspace files and MCP resources instead of oversized inline payloads.
8
8
  - Clausewitz/localisation parsing is bounded to 8,388,608 source bytes and 250,000 lines per file; Clausewitz tokenization is bounded to 250,000 tokens, block nesting to 256 levels, and localisation parsing to 100,000 entries. Broad project and GUI inventories skip the entire active source when one of these bounds is crossed, return `complete: false` with a bounded skipped-source list, and do not walk or publish symbols from the partial parse. An unresolved reference is downgraded only when the skipped source's path family could define that reference kind. Targeted reads and writes still refuse the affected source with an explicit blocker; content beyond a limit is never treated as a complete parse.
9
+ - The aggregate shared index is bounded to 500,000 symbol records and 500,000 reference records. Reaching either ceiling returns an explicitly incomplete inventory. A symbol-ceiling drop records the affected symbol kind so unresolved definitions are reported as partial only where dropped symbols could contain them; the reference ceiling reports incomplete outbound-reference coverage without implying that a missing definition might exist. The server never presents a capped inventory as complete.
9
10
  - Source diagnostics are capped at 100 per file. When additional findings exist, 99 findings are retained and the final slot becomes `SOURCE_DIAGNOSTICS_TRUNCATED`, a blocker rather than a silent truncation.
10
11
  - Renderer coverage is field-by-field. Parsed engine-only GUI properties are retained raw and reported as ignored or unsupported; source changes crossing an unknown field or parsed block are blocked rather than normalized away. Special `textSpriteType`, `corneredTileSpriteType`, GFX `progressbarType`, and `maskedShieldType` semantics, secondary textures, and effect files currently produce only a partial primary-texture appearance with explicit fidelity items and a warning.
11
12
  - Offline GUI output is not guaranteed pixel-identical to the game engine and is never called a screenshot. Modelled geometry and asset composition are deterministic for the recorded render profile.
package/docs/release.md CHANGED
@@ -59,7 +59,7 @@ stable package is published, the normal strict stable-version monotonic and exac
59
59
  ## Immutable fix-forward history
60
60
 
61
61
  Stable tags and public package versions are never moved, deleted, or overwritten after a failed
62
- release attempt. The retained history before `0.1.6` is:
62
+ release attempt. The retained history before the `0.1.7` candidate is:
63
63
 
64
64
  - `v0.1.0` stopped during prepublication validation, before any public writer ran;
65
65
  - `v0.1.1` stopped before npm accepted bytes because npm interpreted a slash-containing relative
@@ -85,12 +85,15 @@ release attempt. The retained history before `0.1.6` is:
85
85
  cross-surface verifier rejected the Registry's omission of explicit `isSecret: false`, although
86
86
  the pinned official schema defines false as that field's default and every public object passed
87
87
  its preceding publication gate. All public objects remain unchanged as audit evidence.
88
-
89
- `0.1.6` omits the redundant false default from checked-in Registry metadata so the strict verifier
90
- can continue comparing the complete published server record without normalization. The normal
91
- stable-version monotonic gate treats the public `0.1.5` package as immutable history and permits
92
- only a strictly newer version. Rerunning or fixing a release never authorizes rewriting a tag,
93
- package version, image tag, release asset, or Registry version.
88
+ - `v0.1.6` completed the ordered workflow and independent verification across npm, GHCR, the
89
+ immutable GitHub Release, and the official MCP Registry. Its exact public evidence is retained in
90
+ [the 0.1.6 completion report](completion-report.md).
91
+
92
+ `0.1.7` is the next strictly monotonic candidate. It adds agent-first discovery/setup guidance and
93
+ corrects shared event indexing and partial-inventory focus diagnostics. The normal stable-version
94
+ gate treats the public `0.1.6` package as immutable history and permits only a strictly newer
95
+ version. Rerunning or fixing a release never authorizes rewriting a tag, package version, image
96
+ tag, release asset, or Registry version.
94
97
 
95
98
  ## Required pre-tag immutability check
96
99
 
@@ -128,7 +128,7 @@ place it beneath any source, capability, artifact, cache, fixture, or `storageRo
128
128
  ## Container
129
129
 
130
130
  ```bash
131
- docker build -t hoi4-agent-tools:0.1.6 .
131
+ docker build -t hoi4-agent-tools:0.1.7 .
132
132
  docker run --read-only --rm -p 127.0.0.1:3210:3210 \
133
133
  -e HOI4_AGENT_CONFIG=/config/config.json \
134
134
  -v /srv/hoi4/config:/config:ro \
@@ -136,7 +136,7 @@ docker run --read-only --rm -p 127.0.0.1:3210:3210 \
136
136
  -v /srv/hoi4/workspaces:/srv/hoi4/workspaces \
137
137
  -v /var/lib/hoi4-agent-tools:/var/lib/hoi4-agent-tools \
138
138
  -v /var/lib/hoi4-agent-tools-state:/var/lib/hoi4-agent-tools-state \
139
- hoi4-agent-tools:0.1.6
139
+ hoi4-agent-tools:0.1.7
140
140
  ```
141
141
 
142
142
  Port publishing reaches the container through a non-loopback interface. The mounted configuration
@@ -30,6 +30,12 @@ validation record.
30
30
 
31
31
  Focus plans include both the edited Clausewitz source and its adjacent `.focus-plan.json` design sidecar in one transaction. The manifest also retains the proposed generated-source map and sidecar artifacts through apply and rollback so each generated focus range remains traceable to its planning/source node.
32
32
 
33
+ Complete focus proposal validation is a linked JSON resource. If proposed or post-write diagnostics
34
+ exceed the fixed manifest allowance, validation still evaluates the complete set, stores it as a
35
+ source-linked MCP resource, and retains a blocker-first bounded manifest summary. The plan phase
36
+ reserves diagnostic capacity for the independent post-write phase, so a warning-heavy large tree
37
+ does not weaken limits or make a valid reviewed transaction impossible to apply.
38
+
33
39
  ## Apply
34
40
 
35
41
  Call `hoi4.transaction_apply` separately with `workspaceId`, `transactionId`, and the exact 64-character `expectedPlanHash`. The server rejects a different principal/workspace, changed roots, failed dry run, expiry, reused state, or any changed before-hash.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "hoi4-agent-tools",
3
3
  "mcpName": "io.github.klimPaskov/hoi4-agent-tools",
4
- "version": "0.1.6",
4
+ "version": "0.1.7",
5
5
  "description": "Source-preserving HOI4 workbench exposed as a safe Model Context Protocol server for coding agents",
6
6
  "type": "module",
7
7
  "license": "Apache-2.0",
@@ -18,7 +18,11 @@
18
18
  "hearts-of-iron-iv",
19
19
  "hoi4",
20
20
  "modding",
21
- "coding-agents"
21
+ "coding-agents",
22
+ "clausewitz",
23
+ "focus-trees",
24
+ "scripted-gui",
25
+ "hoi4-map"
22
26
  ],
23
27
  "engines": {
24
28
  "node": "^22.0.0 || ^24.0.0"
@@ -1,5 +1,5 @@
1
1
  {
2
- "$id": "https://github.com/klimPaskov/hoi4-agent-tools/blob/v0.1.6/schemas/configuration.schema.json",
2
+ "$id": "https://github.com/klimPaskov/hoi4-agent-tools/blob/v0.1.7/schemas/configuration.schema.json",
3
3
  "$schema": "https://json-schema.org/draft/2020-12/schema",
4
4
  "type": "object",
5
5
  "properties": {
@@ -1,5 +1,5 @@
1
1
  {
2
- "$id": "https://github.com/klimPaskov/hoi4-agent-tools/blob/v0.1.6/schemas/continuous-focus-palette.schema.json",
2
+ "$id": "https://github.com/klimPaskov/hoi4-agent-tools/blob/v0.1.7/schemas/continuous-focus-palette.schema.json",
3
3
  "$schema": "https://json-schema.org/draft/2020-12/schema",
4
4
  "type": "object",
5
5
  "properties": {