aptly 0.1.15 → 0.1.17

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.
@@ -145,6 +145,8 @@ Cache reuse requires a completed first result. An unknown outcome remains `outco
145
145
 
146
146
  `context_retry_allowed: false` ends further context supplementation. For a compatible recommendation, `caller_review_required` means the parent reviews arguments; it does not request new user approval. Existing delegation authorization and host permission checks still apply.
147
147
 
148
+ The shared output validation below is available starting with 0.1.17. Retry/fresh application metadata uses a shared Zod contract. Retry `required_fields` lists only missing fields and `next_action` is `apply_returned_defaults` (fresh: `submit_prepared_call`). Stop if application is forbidden or unclear; existing-agent reuse is not evidence of applying advice. Internal inconsistency returns `recovery_metadata_invalid` without raw data or repeating a completed classification. Strict consumers must allow additive fields. Validation does not establish caller compliance or permission.
149
+
148
150
  <a id="guide-fresh-delegation"></a>
149
151
 
150
152
  ## Prepare a separate independent delegation (0.1.6+)
@@ -153,6 +155,8 @@ After a defaults Hook blocks inherited application, the caller may use `prepare_
153
155
 
154
156
  The original inherited invocation stays blocked. Review the separate `next_call.arguments` and submit it under existing delegation authorization and normal host permission checks. It includes `fork_turns: "none"` and preserves model/effort choices. This is caller-declared intent, not verified user intent or execution evidence. Do not use it for required/unknown history, fixed roles, resume or unverified additional execution arguments. A reference binds one task; five-minute expiry, cancellation, policy/catalog changes and changes to the original invocation block preparation. It is not offered for nonblocking advisory paths. See the [contract and limits](../../SPAWN_CONTEXT.md#intentional-fresh-delegation).
155
157
 
158
+ The required-argument guidance below is available starting with 0.1.16. Pass every returned `next_call.arguments` field, including `model` and `reasoning_effort`; omitting them can send an opaque new call back into context recovery. `spawn_application.required_fields` guides caller checks and grants no permission. If user choices or higher-priority host rules require parent-model inheritance or prohibit either field, stop and report that the profile cannot be applied. Do not bypass the restriction with a new recovery ID. If a constraint’s applicability is unclear, stop and report the uncertainty. The Hook preserves explicit fields but does not verify that a new call matches a preparation.
159
+
156
160
  Use this only after the host reports the original call blocked. `original_call_outcome` values `executed` and `unknown` reject preparation. This is caller-declared, not server execution observation. Repeated identical preparation does not guarantee single child execution. The profile was selected from the original classification summary and must not be reused for a different task.
157
161
 
158
162
  <a id="guide-model-info-cache"></a>
@@ -1,43 +1,33 @@
1
1
  # Configuration and model candidates
2
2
 
3
- [한국어](../ko/configuration.md) · [English](../en/configuration.md) · [简体中文](../zh-CN/configuration.md) · [日本語](../ja/configuration.md)
3
+ [한국어](../ko/configuration.md) · **English** · [简体中文](../zh-CN/configuration.md) · [日本語](../ja/configuration.md)
4
4
 
5
- [Guide home](../en.md)
5
+ [Guide contents](../en.md)
6
6
 
7
- Before configuring, identify `CODEX_HOME` in the environment that launches Codex, or `CLAUDE_CONFIG_DIR` for Claude Code. Pass the same environment to installation, setup and statistics commands to select that account home.
8
-
9
- The default home may differ from the account home used by the host. Do not copy policies, ledgers, keys or trust records across homes. Preserve conflicting registrations and `existing_hook_not_owned` cases for review; see [Troubleshooting](troubleshooting.md).
10
-
11
- For manual MCP configuration, see [Advanced integration](advanced.md#guide-manual-mcp-setup).
12
-
13
- ## On this page
7
+ ## Contents
14
8
 
15
9
  - [Configuration file locations](#guide-host-config-locations)
16
- - [Configure with the CLI](#guide-cli-configuration)
10
+ - [CLI configuration](#guide-cli-configuration)
17
11
  - [Keys and restarting](#guide-keys-and-restart)
18
- - [Models and environment variables](#guide-models-and-environment)
19
- - [Node-version-independent launcher](#guide-stable-launcher)
12
+ - [Stable launcher](#guide-stable-launcher)
13
+ - [Model candidates](#guide-models-and-environment)
20
14
 
21
15
  <a id="guide-host-config-locations"></a>
22
16
 
23
17
  ## Configuration file locations
24
18
 
25
- | Host | User registration used by Aptly |
26
- |---|---|
27
- | Codex | `$CODEX_HOME/config.toml`; `~/.codex/config.toml` when `CODEX_HOME` is unset |
28
- | Claude Code | `mcpServers.aptly` in `~/.claude.json`; `.claude.json` inside `CLAUDE_CONFIG_DIR` when that directory is configured |
19
+ | Host | Default location | Alternate account home |
20
+ |---|---|---|
21
+ | Codex | `~/.codex/config.toml` | `$CODEX_HOME/config.toml` |
22
+ | Claude Code | `mcpServers.aptly` in `~/.claude.json` | `$CLAUDE_CONFIG_DIR/.claude.json` |
29
23
 
30
- Starting with 0.1.15, the fix lets MCP using the `@codex-home` policy select `~/.codex` under the OS user home when `CODEX_HOME` is absent. An explicit absolute path takes precedence; explicitly empty, relative or control-character-containing values remain rejected. Published 0.1.14 still requires the variable to be forwarded even for the default home. Custom account homes are not discovered automatically, so account managers must forward the correct `CODEX_HOME`. If a custom host omits this value, the default home’s policy and transmission scope apply; forward it to preserve account-specific policy.
24
+ Claude Hooks are in `~/.claude/settings.json` by default, or `$CLAUDE_CONFIG_DIR/settings.json` for another account. Pass the host's account environment to installation, setup, and statistics commands too. Do not copy policies, ledgers, keys, or trust records from another home.
31
25
 
32
- Claude Code stores Hooks in `~/.claude/settings.json` by default, or `$CLAUDE_CONFIG_DIR/settings.json` when `CLAUDE_CONFIG_DIR` is set. This is separate from MCP registration. If project `.mcp.json`, managed settings, or account-specific directories are in use, check the active entry in `/mcp` before editing or adding a registration.
26
+ Since 0.1.15, the Codex MCP `@codex-home` policy selects `~/.codex` when `CODEX_HOME` is absent. An explicit absolute path takes precedence; empty or relative paths and control characters are rejected. Custom homes are not discovered, so the default home's policy and transmission scope apply unless the administrator passes the value. See [advanced setup](advanced.md#guide-manual-mcp-setup) for manual, project, and managed registrations.
33
27
 
34
28
  <a id="guide-cli-configuration"></a>
35
29
 
36
- ## Configure with the CLI
37
-
38
- From 0.1.11, the first normal interactive `aptly set default` groups pending transmission reviews by client home. The recommendation is `excerpt`; Enter preserves an existing scope or selects `none` if unselected. See [transmission review](transmission.md#guide-transmission-scope). This review flow is not supported in 0.1.10, so update first.
39
-
40
- The `set` commands require 0.1.1 or later. Commands do not automatically switch existing launch paths. API-key setup accepts only the current package’s standard Node/server registration with a verified OS-source-compatible runtime. Custom wrappers, older versions, and other installation prefixes are rejected with `credential_launcher_unverified`; explicitly switch the registration or upgrade it before trying again.
30
+ ## CLI configuration
41
31
 
42
32
  ```sh
43
33
  aptly set default
@@ -45,72 +35,71 @@ aptly set env APTLY_CODEX_MODELS
45
35
  aptly set env OPENAI_API_KEY
46
36
  ```
47
37
 
48
- The first command registers Claude Code and Codex and adds missing default environment settings. It preserves existing launch commands, environment whitelists, providers, custom candidates, and advisory policies. The second prompts for a value with hidden input and changes only the named variable. The third stores the API key in the OS credential store and connects it to the selected host at startup. Do not pass values as command arguments.
49
-
50
- Both hosts are selected by default. Use `--client codex`, `--client claude`, or `--client all` to select targets. For example, enter a JSON string such as `["haiku","sonnet","opus"]` for Claude candidates.
38
+ `set default` adds missing registrations and defaults and reviews the [transmission scope](transmission.md). It preserves existing commands, environment, provider, candidates, and advisory policy. `set env` accepts hidden input and changes only the named variable. Both hosts are targeted by default; select with `--client codex|claude|all`.
51
39
 
52
40
  ```sh
53
41
  aptly set env APTLY_CLAUDE_MODELS --client claude
54
42
  ```
55
43
 
56
- Use explicit `--stdin` for automation. This is a public-variable example; never put a real key in a `printf` command or shell history.
44
+ Enter candidates as a JSON array string such as `["haiku","sonnet","opus"]`. For automation use `--stdin`. Do not put real keys in `printf` or shell history.
57
45
 
58
46
  ```sh
59
47
  printf '%s\n' '["gpt-6.1-terra"]' | aptly set env APTLY_CODEX_MODELS --stdin
60
48
  ```
61
49
 
62
- Allowed public keys are `ROUTER_PROVIDER` (`fixture` or `decisions`), `APTLY_CLAUDE_MODELS`, `APTLY_CODEX_MODELS`, `CLAUDE_MODELS`, `CODEX_MODELS`, and `APTLY_MODEL_INFO_PATH`. Candidates must be JSON array strings of supported models. Invalid values, duplicates, and primary-name/alias conflicts are rejected. `[]` disables that host; a model-cache path must be absolute and inside a private directory. Managed ledger and Hook-policy paths cannot be changed through this command.
50
+ Generally allowed keys are `ROUTER_PROVIDER` (`fixture`/`decisions`), `APTLY_CLAUDE_MODELS`, `APTLY_CODEX_MODELS`, aliases `CLAUDE_MODELS` and `CODEX_MODELS`, and `APTLY_MODEL_INFO_PATH`. The model cache path must be absolute and inside a private directory. This command does not change administrative ledger or policy paths.
51
+
52
+ <a id="guide-keys-and-restart"></a>
53
+
54
+ ## Keys and restarting
63
55
 
64
- API keys are stored through macOS Keychain, an installed Linux `secret-tool`, or Windows Credential Manager. The Windows backend uses PowerShell and Win32 Generic credentials in the current-user scope, with a limit of 2,560 UTF-8 bytes. Windows CI verified synthetic key storage, lookup, update and deletion, Unicode paths, isolated host configuration, key references, and ACL preservation. It did not run actual Claude Code or Codex sessions on Windows. Unavailable credential stores return an error; there is no plaintext-file fallback. Keys use separate host accounts, while MCP files contain only `APTLY_SECRET_BACKEND=os` and `APTLY_SECRET_CLIENT` references. Once the OS source is selected, a missing or unreadable key does not silently fall back to another environment key. `set default` preserves existing wrapper/environment authentication; running `set env OPENAI_API_KEY` explicitly selects OS-store authentication.
56
+ `aptly set env OPENAI_API_KEY` stores each host's key in macOS Keychain, Linux `secret-tool`, or Windows Credential Manager and registers only a store reference with MCP. An unavailable or locked store produces an error; Aptly does not fall back to a plaintext file or another environment key. See [credential store errors](troubleshooting.md).
65
57
 
66
- Results contain host statuses and fixed error codes, never key values. Inspect each host when the result is `partial`. `credential_store_failed` requires checking store access/support; `credential_rollback_failed` requires checking whether the previous key was restored. A failed host restores its old key where possible. Do not interpret success on another host as an atomic success across all hosts.
58
+ Host subscription login and the API key are separate. Do not record keys in command arguments, configuration JSON, requests, or repositories. For direct delivery through a secure MCP execution environment, see [manual setup](advanced.md#guide-key-environment).
67
59
 
68
- A store timeout or malformed acknowledgement may occur after the OS has written the new value. On failure, Aptly attempts to restore the previous value (or remove the new entry if none existed), then reads it back. `credential_rollback_failed` is added to the original failure codes when recovery cannot be confirmed; do not assume either key is active. Check the OS credential store before retrying. This is best-effort recovery, not an atomic transaction across processes or hosts.
60
+ Key storage is allowed only for standard launchers verified as compatible. Custom wrappers are preserved but may be rejected with `credential_launcher_unverified`. For `partial`, check each host's error. On a storage failure Aptly attempts to restore the previous key; if `credential_rollback_failed` occurs, check the active key in the OS store before retrying. Changes across multiple hosts are not atomic.
69
61
 
70
- Restart MCP, then inspect `provider`, candidates, and `credential_status` with `get_routing_capabilities`. `os_store` means a key was loaded, not that the API authenticated it. Default and public-variable setup continue to preserve custom wrappers. API-key setup does not change host settings for an unverified launch path and restores that host's previous key where possible if storage was already attempted. Do not assume a new key automatically takes effect through an existing wrapper. These commands do not bypass Codex `/hooks` trust or host permissions.
62
+ Restart MCP after changes and check candidates, provider, and `credential_status` with `get_routing_capabilities`. `os_store` means the key was read, not that its API validity was verified. Codex `/hooks` approval is also required.
71
63
 
72
64
  <a id="guide-stable-launcher"></a>
73
65
 
74
- ## Node-version-independent launcher
66
+ ## Launcher resilient to Node version changes
75
67
 
76
- This option is available starting with 0.1.14. Explicit `--launcher stable` on POSIX (macOS/Linux) preserves an executable and Aptly runtime dependencies in private storage outside versioned Node directories. It does not copy Node: an installed supported Node.js 24+ is still required. After the original Node and npm package directory disappear, the preserved launcher can locate another supported installation. Bare `node` cannot offer that guarantee when a GUI host lacks it in PATH.
68
+ Default registrations use an absolute Node path. On macOS and Linux, `stable` is available for frequent Node version changes (since 0.1.14). It preserves Aptly and dependencies outside the Node directory and searches for another supported Node.js 24+. It does not include Node and does not support Windows.
77
69
 
78
- Default/automatic and existing registrations keep direct Node paths. Use `aptly setup --client all --launcher stable` only for new registrations. For existing ones, inspect then migrate explicitly as below. Use `--client claude` for Claude and select the intended `CODEX_HOME` for each Codex account.
70
+ For a new registration, use `aptly setup --client all --launcher stable`. For an existing one, review the dry run before migration. Pass the appropriate home environment for other accounts and use `--client claude` for Claude.
79
71
 
80
72
  ```sh
81
73
  aptly setup --client codex --migrate-launcher --launcher stable --dry-run
82
74
  aptly setup --client codex --migrate-launcher --launcher stable
83
75
  ```
84
76
 
85
- Add `--include-existing` only after reviewing an eligible preserved standard launcher. Modified/custom launchers and statistics Hooks are never adopted automatically. Migration updates owned MCP and observer targets together, preserving collection state, native metadata consent, keys, policies, ledgers and statistics history. Review new Codex Hooks with `/hooks`; trust is never approved automatically.
86
-
87
- Resolution tries the installer Node, standard locations, numeric release directories in the default `~/.nvm/versions/node`, then safe absolute PATH entries. It does not promise the newest Node; symlink/shim-based managers may be rejected even with PATH; only qualified real executable paths are supported. No shell profile, npm or network download runs at startup. Stable mode deliberately removes `NODE_OPTIONS`, `NODE_PATH` and `NODE_REPL_EXTERNAL_MODULE` to avoid inheriting common Node startup overrides; use separate certificate settings such as `NODE_EXTRA_CA_CERTS` when needed. Runtime closures requiring native addons are refused. Missing runtime or failed integrity stops MCP with a fixed error; observers stay silent and best-effort.
88
-
89
- Normal global npm installations are the primary supported source. Redirected/writable ancestors and dependencies hoisted outside a local package cannot be verified and are refused. Windows retains direct mode and rejects the stable option. Stable mode remains sticky across later setup/migration without the flag. Run `aptly update` from the actual global npm CLI; explicitly migrate to select a new Aptly snapshot. Remove retains old/shared snapshots because other homes or running processes may still use them. Doctor observes snapshot metadata, not full execution, authentication or reload readiness.
77
+ After updating global Aptly, run the same command to update the preserved copy. Ordinary `setup` does not replace it; an old copy reports `stable_snapshot_outdated`. Migration updates owned MCP and statistics observers together. Modified launchers and Hooks are not adopted. To target a preserved standard registration, review it and add `--include-existing`. Approve changed Codex Hooks again in `/hooks`.
90
78
 
91
- Plain setup does not silently replace an existing snapshot. Older selected versions report `stable_snapshot_outdated` and explicit migration guidance. An exact-owned stable reference can explicitly migrate from a missing, damaged or older-format snapshot to verified source from the current CLI. A corrupt same-generation directory or incomplete lock is never overwritten/deleted automatically: inspect only that state after checking writers and other homes. Modified/custom registration is not adopted as product-owned.
79
+ <details>
80
+ <summary>Launcher limits and recovery</summary>
92
81
 
93
- Stable migration updates owned observers together; legacy direct-to-direct migration may still need separate observer refresh (`statistics_observer_migration_required`). Full snapshot checks during setup and startup add I/O overhead. Bounded runtime probes do not provide a hard wall-clock bound for all filesystem operations. This is not a sandbox against same-user programs or worker threads.
82
+ The search order is installation Node, standard paths, default `~/.nvm/versions/node`, then safe absolute PATH entries. Selection of the newest version and support for custom NVM_DIR, shims, or symlink-based managers are not guaranteed. Shell profiles, npm, and downloads are not executed. `NODE_OPTIONS`, `NODE_PATH`, and `NODE_REPL_EXTERNAL_MODULE` are removed; review `NODE_EXTRA_CA_CERTS` and similar settings for additional CAs.
94
83
 
95
- <a id="guide-keys-and-restart"></a>
84
+ Unverifiable sources such as writable ancestor paths, externally hoisted dependencies, and native add-ons are rejected. Integrity checks add I/O cost, and the search budget is not a hard timeout for all file I/O. This is not sandboxing or publisher signature verification. On failure MCP stops with an error and the statistics observer exits quietly.
96
85
 
97
- ## Keys and restarting
86
+ If ownership matches, a missing, damaged, or older-format copy can be explicitly migrated from a new CLI source. Damaged same-generation copies and incomplete locks are not automatically overwritten or deleted. Old copies are not automatically deleted because other homes or processes may reference them. Check writers and references before reviewing the state. Migration between direct Node launchers may require a separate statistics update (`statistics_observer_migration_required`).
98
87
 
99
- Pass the classification key, `OPENAI_API_KEY`, through a secure environment or credential launcher to the MCP process. It is separate from host subscription login. Never write key values into command arguments, requests, configuration files, source, logs, or temporary files.
88
+ </details>
100
89
 
101
90
  <a id="guide-models-and-environment"></a>
102
91
 
103
92
  ## Models and environment variables
104
93
 
105
- There are six default profiles. Tiers are Aptly operational presets, not statements that the two providers' models have equivalent capabilities.
94
+ Tiers are task presets and do not imply equivalent model performance across providers.
106
95
 
107
- | Tier | Claude Code | Codex | Typical tasks |
96
+ | Tier | Claude Code | Codex | Example tasks |
108
97
  |---|---|---|---|
109
- | simple | `haiku` | `gpt-6-luna` / `max` | Extraction, format conversion, or small mechanical edits |
110
- | routine | `sonnet` | `gpt-6.1-terra` / `high` | Context-aware writing or translation, or clearly scoped implementation |
111
- | deep | `opus` | `gpt-6.1-sol` / `medium` | Cross-component debugging, architectural judgment, or in-depth review |
98
+ | simple | `haiku` | `gpt-6-luna` / `max` | Extraction, format conversion, small mechanical edits |
99
+ | routine | `sonnet` | `gpt-6.1-terra` / `high` | Context-aware writing, translation, scoped implementation |
100
+ | deep | `opus` | `gpt-6.1-sol` / `medium` | Complex debugging, design decisions, deep review |
112
101
 
113
- MCP `env` values are strings, so candidate arrays must also be passed as JSON strings.
102
+ MCP `env` values are strings, so pass candidate arrays as JSON strings.
114
103
 
115
104
  ```json
116
105
  {
@@ -121,12 +110,8 @@ MCP `env` values are strings, so candidate arrays must also be passed as JSON st
121
110
  }
122
111
  ```
123
112
 
124
- When unset, the defaults above apply; `[]` disables recommendations for that client. Empty strings, duplicates, unsupported models, and malformed JSON are errors. `CLAUDE_MODELS` and `CODEX_MODELS` are supported aliases, but setting both the primary name and its alias for the same provider is an error. Candidate configuration does not override existing choices or certify model access for an account.
125
-
126
- `aptly set default` preserves candidates and aliases already in MCP `env`, Codex `env_vars` declarations, and inherited candidates visible to the current CLI for Claude. It adds default candidates only for a model family with neither name configured. A Codex passthrough is preserved even when its value is unavailable in the current terminal; inherited values are not copied into configuration files. The CLI gives a static `env` value precedence over an inherited value with the same name when validating effective settings. Catalog validation remains in place, so conflicting aliases or malformed values reject the configuration change. Check the final candidates in the restarted MCP separately.
127
-
128
- ## Related topics
113
+ When omitted, the defaults above apply; `[]` disables recommendations for that host. Empty strings, duplicates, unsupported models, and invalid JSON are errors. `CLAUDE_MODELS` and `CODEX_MODELS` are aliases, but setting both the primary name and alias for one provider is an error. Candidate settings do not overwrite existing selections or verify account access to models.
129
114
 
130
- [Installation and updates](installation.md) · [Automatic recommendations](routing.md) · [Decisions API transmission](transmission.md) · [Advanced MCP integration and development](advanced.md) · [Troubleshooting](troubleshooting.md)
115
+ `set default` preserves existing candidates, aliases, and pass-through declarations and adds defaults only for missing model families. It does not overwrite inherited Codex candidates even if the current CLI cannot see them. Check final candidates after restarting MCP.
131
116
 
132
- [Guide home](../en.md)
117
+ [Installation](installation.md) · [Troubleshooting](troubleshooting.md) · [Guide contents](../en.md)
@@ -1,66 +1,55 @@
1
1
  # Installation and updates
2
2
 
3
- [한국어](../ko/installation.md) · [English](../en/installation.md) · [简体中文](../zh-CN/installation.md) · [日本語](../ja/installation.md)
3
+ [한국어](../ko/installation.md) · **English** · [简体中文](../zh-CN/installation.md) · [日本語](../ja/installation.md)
4
4
 
5
- [Guide home](../en.md)
5
+ [Guide contents](../en.md)
6
6
 
7
- ## On this page
7
+ ## Contents
8
8
 
9
9
  - [Installation](#guide-installation)
10
- - [npm install-script approval](#guide-npm-install-scripts)
10
+ - [Allow npm install scripts](#guide-npm-install-scripts)
11
11
  - [Package updates](#guide-package-updates)
12
12
  - [New-version notifications](#guide-version-notifications)
13
13
  - [Command help (0.1.8+)](#guide-command-help)
14
- - [Skipping registration and removing it](#guide-skip-and-remove)
14
+ - [Skip registration or remove](#guide-skip-and-remove)
15
15
 
16
16
  <a id="guide-installation"></a>
17
17
 
18
18
  ## Installation
19
19
 
20
- Requires Node.js 24 or later and Claude Code or Codex. Install the latest stable npm release globally:
21
-
22
- **Before upgrading an existing persistent ledger to 0.1.2 or later**, stop every host, MCP server, standalone CLI, and older process that can access it. The persistent gate cannot coexist with older writers. Fresh installations need no legacy-lock quarantine. If an old empty lock remains, follow the [ledger transition procedure](troubleshooting.md#guide-ledger-lock-recovery): quarantine only a confirmed legacy lock while offline and preserve the JSON ledger, `unknown` records, costs, and completed cache.
20
+ You need Node.js 24 or later, Claude Code or Codex, and an OpenAI API key.
23
21
 
24
22
  ```sh
25
23
  npm install -g aptly@latest --allow-scripts=aptly
26
24
  aptly set default
25
+ aptly set env OPENAI_API_KEY
27
26
  aptly --version
28
27
  ```
29
28
 
30
- Use `aptly --version` to check the installed version. Switching Node.js environments may require reinstalling.
31
-
32
- `postinstall` registers the MCP server and a `PreToolUse` Hook in the current user's existing host configuration directories. If you use `CODEX_HOME` or `CLAUDE_CONFIG_DIR`, pass the same environment to installation. Automatic registration skips host directories that do not exist; explicit `setup` can create them. To register only one host, use `--client codex` or `--client claude`.
29
+ `set default` registers hosts and asks what information to send to the Decisions API. Enter the key through the hidden prompt; it is stored in the OS credential store. Restart the host and approve the new Hook in Codex `/hooks`.
33
30
 
34
- New registrations set `ROUTER_PROVIDER=decisions`, the Hook's `defaults` policy, and a private ledger for each host. Other settings and Hooks, and existing Aptly commands, environments, providers, and ledger paths, are preserved. Existing fixture settings are not automatically switched to paid mode.
31
+ The install script registers MCP and Hooks in existing host directories. If a directory does not exist, register with `aptly setup --client all`. Accounts using `CODEX_HOME` or `CLAUDE_CONFIG_DIR` must pass the same environment during installation and setup. Existing settings and launcher wrappers are preserved. See [account homes and keys](configuration.md).
35
32
 
36
33
  <a id="guide-npm-install-scripts"></a>
37
34
 
38
- ## npm install-script approval
39
-
40
- The installation command above uses `--allow-scripts=aptly` to explicitly allow Aptly's `postinstall` for that installation. Support was checked with npm 11.19.1; the command does not change user-wide npm approval settings. See the [official npm guidance](https://docs.npmjs.com/cli/v11/commands/npm-rebuild/#allow-scripts).
41
-
42
- `npm warn install-scripts ... not yet covered by allowScripts` reports an unreviewed policy entry. In npm 11.19.1, this warning alone does not mean scripts were blocked. Behavior depends on npm version, strict policy, and `ignore-scripts`; installation success alone does not verify MCP or Hook registration. npm may hide postinstall output.
35
+ ## Allow npm install scripts
43
36
 
44
- For npm versions without this option, or to configure explicitly instead of automatic registration, run:
37
+ `--allow-scripts=aptly` allows only this installation's `postinstall` and does not change npm's global configuration (verified with npm 11.19.1). If the option is unsupported or you do not want automatic registration, run:
45
38
 
46
39
  ```sh
47
40
  npm install -g aptly@latest --ignore-scripts
48
41
  aptly setup --client all
49
42
  ```
50
43
 
51
- Transmission review is available from 0.1.11 and does not prompt during npm lifecycle installation. When upgrading from 0.1.10, update the package first, then run interactive `aptly setup`, `aptly set default`, or `aptly set transmission --review` with the same account environment. The update process does not perform the new review or imply consent; see [transmission review](transmission.md#guide-transmission-scope).
44
+ Do not infer Hook registration from installation success or `npm warn install-scripts` alone. npm versions or policies may skip the install script. See [npm documentation](https://docs.npmjs.com/cli/v11/commands/npm-rebuild/#allow-scripts).
52
45
 
53
- Explicit `setup` works regardless of lifecycle execution. It preserves existing launchers; use the [launcher recovery steps](troubleshooting.md#guide-launcher-recovery) for stale paths. Key setup, MCP restart, and Codex `/hooks` trust review remain separate steps.
54
-
55
- The 0.1.11 or later installer writes only a stderr instruction to run `aptly set transmission --review` when setup completes successfully and registered clients have reviews pending; it does not ask a question or record a choice.
46
+ The install script does not obtain transmission consent. Choose the [transmission scope](transmission.md) later in interactive `aptly setup`, `aptly set default`, or `aptly set transmission --review`.
56
47
 
57
48
  <a id="guide-package-updates"></a>
58
49
 
59
50
  ## Package updates
60
51
 
61
- `aptly update` requires **Aptly 0.1.3 or later**. It requires a verified global npm installation and installs `aptly@latest` into the same verified prefix as the running package. Local installations, source checkouts, and unverified paths are rejected. If the effective npm configuration has `dry-run=true`, the command refuses with `update_dry_run_enabled` before starting installation. If configuration cannot be verified, it stops with `update_configuration_unverified`. A dry-run is never reported as a successful update.
62
-
63
- Stop other host, MCP, and CLI processes using the ledger before updating, following the transition steps above. The command skips lifecycle scripts; explicitly configure afterward and restart hosts:
52
+ Stop the relevant hosts, MCP servers, and CLI processes, then run from a verified global npm installation:
64
53
 
65
54
  ```sh
66
55
  aptly update
@@ -68,36 +57,39 @@ aptly setup --client all
68
57
  aptly --version
69
58
  ```
70
59
 
71
- Existing MCP launchers and user wrappers are not automatically migrated. Follow the [launcher recovery instructions](troubleshooting.md#guide-launcher-recovery) if old paths remain. Key setup and Codex `/hooks` trust review remain separate. For npm authentication, network, or permission failures, use the manual installation instructions. Updates are never installed automatically.
60
+ `update` installs the latest version in the same npm prefix and preserves settings and keys. It does not run install scripts. Restart the host after setup. On npm errors or local/source installations, use the manual installation command above. npm configuration with `dry-run=true` is rejected.
61
+
62
+ A stable launcher's preserved copy is separate from the global package. Update it with an [explicit migration](configuration.md#guide-stable-launcher). If the old Node path has disappeared, follow [launcher recovery](troubleshooting.md#guide-launcher-recovery).
63
+
64
+ <details>
65
+ <summary>Upgrade from a pre-0.1.2 ledger</summary>
66
+
67
+ Stop all older host, MCP, and CLI writers using the same ledger. The new persistent lock cannot be used with older writers. Quarantine old empty locks offline as described in [ledger lock migration](troubleshooting.md#guide-ledger-lock-recovery), and preserve the JSON ledger, unknown entries, costs, and completion cache.
68
+
69
+ </details>
72
70
 
73
71
  <a id="guide-version-notifications"></a>
74
72
 
75
73
  ## New-version notifications
76
74
 
77
- **Aptly 0.1.3 or later** checks the latest stable version during interactive human-facing CLI commands and suggests `aptly update` on stderr when a newer version exists. All three standard streams must be terminals. MCP serving, automatic setup, recommendation/classification paths, pipes, and CI skip checks. JSON stdout and MCP/Hook payloads stay unchanged.
78
-
79
- Only public Aptly version metadata is requested from the npm registry; no key, task summary, or host configuration is sent. Network and body reads are limited to 800ms and 16KiB. Results are cached at `~/.cache/aptly/update-check.json` for 24 hours, with a one-hour cooldown after failure. Network/cache errors cannot fail the requested command. Set `APTLY_NO_UPDATE_NOTIFIER=1` in the CLI environment to disable checks; it is not a supported key for `aptly set env`. Notifications never install updates.
75
+ The interactive CLI checks for the latest version and reports it on stderr; it does not update automatically. MCP, Hooks, pipes, and CI do not check. Only public npm version information is queried; tasks, keys, and settings are not sent. Results are cached for 24 hours and errors do not fail the original command. To disable this, set `APTLY_NO_UPDATE_NOTIFIER=1` in the execution environment (not through `set env`).
80
76
 
81
77
  <a id="guide-command-help"></a>
82
78
 
83
- ## Command help (0.1.8+)
84
-
85
- Consistent per-command and nested help is supported from Aptly 0.1.8. Use these forms:
79
+ ## Command help
86
80
 
87
81
  ```sh
88
82
  aptly --help
89
83
  aptly setup -h
90
- aptly set default --help
91
84
  aptly set env OPENAI_API_KEY --help
92
- aptly budget status --help
93
85
  aptly help catalog refresh
94
86
  ```
95
87
 
96
- `--help`, `-h` and `aptly help <command path>` only show usage. They do not read settings, supplied files, stdin or credential stores; prompt; change settings; call APIs or model metadata endpoints; install/update; or run update notifications. Help can follow valid options, but unknown paths/options, invalid supplied values and contradictory option combinations remain errors. Required positional arguments may be omitted to discover usage. A form such as `--output --help` is a missing option value, not a help request that supplies an output path.
88
+ `--help`, `-h`, and `aptly help <command path>` display usage without reading settings or keys or calling the API. Invalid options and missing option values are errors.
97
89
 
98
90
  <a id="guide-skip-and-remove"></a>
99
91
 
100
- ## Skipping registration and removing it
92
+ ## Skip registration or remove
101
93
 
102
94
  ```sh
103
95
  APTLY_SKIP_SETUP=1 npm install -g aptly@latest
@@ -105,10 +97,6 @@ aptly setup --client codex --mode defaults
105
97
  aptly remove --client all
106
98
  ```
107
99
 
108
- `CI` or npm `--ignore-scripts` also skips registration. Use `setup` to register later. To change mode, remove the registration and run setup with the desired `--mode`; `advisory` only supplies advice. For `partial`, check each host’s error codes. Removal preserves user-modified entries and reports conflicts.
109
-
110
- ## Related topics
111
-
112
- [Configuration and model candidates](configuration.md) · [Troubleshooting](troubleshooting.md)
100
+ `CI` and `--ignore-scripts` also skip automatic registration. `remove` removes only unchanged Aptly-owned entries and preserves user changes. If the result is `partial`, check each host's error. To change modes, remove the registration and register with the desired `--mode`. `advisory` also sends task information when the transmission scope permits it.
113
101
 
114
- [Guide home](../en.md)
102
+ [Configuration](configuration.md) · [Troubleshooting](troubleshooting.md) · [Guide contents](../en.md)
@@ -1,37 +1,35 @@
1
- # Decisions API transmission
1
+ # Decisions API transmission scope
2
2
 
3
- [한국어](../ko/transmission.md) · [English](../en/transmission.md) · [简体中文](../zh-CN/transmission.md) · [日本語](../ja/transmission.md)
3
+ [한국어](../ko/transmission.md) · **English** · [简体中文](../zh-CN/transmission.md) · [日本語](../ja/transmission.md)
4
4
 
5
- [Guide home](../en.md)
5
+ [Guide contents](../en.md)
6
6
 
7
- The transmission review and `--review` command described below are **available from Aptly 0.1.11**. If you use 0.1.10, update the package first.
7
+ ## Contents
8
8
 
9
- ## On this page
10
-
11
- - [Decisions API transmission scope](#guide-transmission-scope)
12
- - [Outbound content and filtering limits](#guide-transmission-limits)
9
+ - [Choose a transmission scope](#guide-transmission-scope)
10
+ - [Content and limits](#guide-transmission-limits)
13
11
 
14
12
  <a id="guide-transmission-scope"></a>
15
13
 
16
- ## Decisions API transmission scope
17
-
18
- The transmission commands in this section are supported from Aptly 0.1.7.
14
+ ## Choose a transmission scope
19
15
 
20
- Transmission means **sending local task information to the OpenAI Decisions API**, not providing tasks to Aptly developers. Application mode `defaults/advisory` and transmission scope are independent. New registrations use v2 policy with `unselected` scope and make no automatic transmission.
16
+ The recipient is the **OpenAI Decisions API**, not the Aptly developer. New registrations start `unselected` and do not transmit automatically.
21
17
 
22
- For upgrades from 0.1.10: in that version, interactive `aptly set default` asks only for unselected hosts; Enter selects `none`. Noninteractive runs and postinstall do not prompt or imply consent.
18
+ | Scope | Information available for automatic recommendations |
19
+ |---|---|
20
+ | `none` | No automatic transmission; preserve the original call |
21
+ | `description` | Send only the caller-provided description; request more context if absent |
22
+ | `excerpt` | Allow explicit descriptions and supported native task excerpts |
23
23
 
24
- From 0.1.11, the first normal interactive `aptly setup` or `aptly set default` presents one grouped review for clients awaiting review, showing each current value, provenance, and default or overridden home. `excerpt` is recommended as option 3. Enter or keep preserves an existing explicit or legacy scope, including `none`; an unselected scope becomes `none`. Explicit `setup --transmission` or `set transmission <scope>` records the actual choice as reviewed. A private revision 1 marker is stored per client home, independent of package version, mode, and statistics, so ordinary patch updates and restarts do not repeat the review.
24
+ The first interactive `setup` or `set default` asks for the scope of homes awaiting review. The recommended option is `excerpt`; Enter preserves an existing choice or selects `none` if unselected. Automatic installation, CI, and nonterminal execution are not treated as consent. Cancellation leaves the transmission choice unchanged, though earlier default registration may have completed.
25
25
 
26
- The command below is supported from 0.1.11 and always asks again by explicit request. If you use 0.1.10, update first:
26
+ To review again, run (since 0.1.11):
27
27
 
28
28
  ```sh
29
29
  aptly set transmission --review
30
30
  ```
31
31
 
32
- Canceling leaves scopes and review markers unchanged; normal setup or default configuration may already have applied non-transmission defaults. Automatic setup, check, migrate, explicit-transmission setup, CI, non-TTY execution, skipped setup, npm lifecycle scripts, MCP, Hooks, help, show, and statistics reads do not prompt. Prompts use stderr and leave JSON stdout clean. Existing disabled policies, modes, launchers, keys, ledgers, statistics, and trust settings are preserved.
33
-
34
- The 0.1.10 update process cannot immediately load the updated CLI’s new question. After updating to 0.1.11 or later, run interactive `aptly setup`, `aptly set default`, or `aptly set transmission --review` with the same account environment. `aptly update` in 0.1.11 or later also prints the next setup command without spawning a new process.
32
+ You can also show the current value or select a scope directly. Run only one of the change commands below. Choose targets with `--client codex|claude|all`.
35
33
 
36
34
  ```sh
37
35
  aptly set transmission --show
@@ -40,34 +38,31 @@ aptly set transmission description
40
38
  aptly set transmission excerpt
41
39
  ```
42
40
 
43
- The top-level `status` in `--show` is `complete` (exit 0) when the query completes and `partial` (exit 1) for incomplete expected setup or corrupt or unreadable state. `none`, `unselected`, and genuinely unconfigured clients, including manual direct-only MCP without an expected automatic policy, are completed queries. Successful client results remain available when another client fails. Existing client JSON fields and values are retained; strict full-object consumers must accept the additive `status`. Some legacy client statuses conflate unconfigured and error states, so the aggregate also reflects checked query health. `complete` does not certify host routing, model, or trust readiness. Reads do not repair setup, obtain consent, or call a provider, and do not print raw paths, input, keys, or stacks.
41
+ Restart MCP after changes. Existing v1 policies remain legacy `excerpt` until changed. Operator changes and other wrappers are not automatically adopted. In-flight transmissions cannot be recalled, and results, retries, or fresh delegations from before the change are not applied to the new policy. Do not bypass conflicts with a new paid ID.
44
42
 
45
- The change commands above show alternatives; run only the one you want. Use `--client codex|claude|all` to select hosts. `none` disables automatic transmission and preserves the original call. `description` permits only a parent-supplied description. Without one, it requests context before calling the API and never falls back to native body or label. `defaults` denies the unresolved spawn; `advisory` supplies feedback only. `excerpt` permits existing native excerpts and explicit descriptions. Source, size and known-secret checks establish neither non-sensitive content nor user consent.
43
+ `--show` returning `complete`/exit code 0 means the query completed, including when the value is unset or `none`. Damaged, missing, or conflicting expected settings yield `partial`/exit code 1. This command does not verify host readiness or consent.
46
44
 
47
- Existing v1 policies remain byte-identical and report `excerpt` with `legacy` provenance. An explicit change migrates the policy to v2 and updates its ownership receipt together. Modified policies and custom launchers are not silently adopted; conflicts preserve them. Keys, ledgers and unknown records are not deleted. Restart MCP after changes. Already-started transmission cannot be recalled; changed policy prevents in-flight results, retry and fresh preparation from applying. Do not bypass an old call-binding conflict with a new paid identity. Explicit `recommend_agent` and `aptly recommend` requests remain separate and are not prohibited by this automatic-transmission setting.
45
+ `advisory` limits application; it does not prohibit transmission. If a `description` is insufficient, `defaults` blocks the spawn and `advisory` reports guidance. `recommend_agent` and `aptly recommend` are separate explicit requests and are not prohibited by the automatic transmission setting.
48
46
 
49
- Manually setting `enabled: false` remains an emergency stop, but can conflict with ownership records. Use the commands above for normal changes and never edit ownership receipts to bypass checks.
47
+ <details>
48
+ <summary>Emergency stop by editing the policy</summary>
50
49
 
51
- <a id="guide-transmission-limits"></a>
50
+ Changing only `enabled` to `false` in the existing private policy at `APTLY_HOOK_POLICY_PATH` preserves the original call before automatic classification and binding. Do not edit other fields or ownership records. Use the CLI above for ordinary changes because ownership conflicts can result. Do not clear the policy path as a stop method: it may switch to the strict path. Already started transmissions and explicit direct recommendations cannot be canceled this way.
52
51
 
53
- ## Outbound content and filtering limits
52
+ </details>
54
53
 
55
- Under `excerpt` scope, Without prepared context, automatic classification `summary` is an **excerpt assembled from an accepted task label and the clipped first paragraph** of the body. It is not a semantic rewrite or anonymization. Its UTF-8 size is at most `min(4000, max_summary_bytes)`; this is not a limit on the whole HTTP request. The opaque-message fallback in Codex uses only a sufficiently descriptive `task_name`, without decoding or transmitting that body. Labels can also contain sensitive information.
56
-
57
- A valid `prepare_spawn_context` description and fixed prefix replace the native excerpt for classification; registration itself makes no API call. After a needs-context response, `retry_spawn_recommendation` can classify one new supplement with a fixed prefix, without appending the earlier body. Both paths limit the raw description to `min(3800, max_summary_bytes - 96)` bytes and the prefixed summary to `min(4000, max_summary_bytes)` bytes. `prepare_fresh_delegation` itself reuses completed advice without another classification and returns standalone instructions as local next-call arguments. A Codex call submitted with the returned explicit model and effort is currently preserved by the Hook as `explicit_model`, without classification. Checking a later call does not imply another classification. None of these paths establishes that descriptions are non-sensitive or automatically anonymized.
58
-
59
- Decisions receives `client`, `task.summary`, `task.operation`, `task.context_sufficient`, candidate profile IDs, model/effort descriptions, and configured model facts. The classification API key is sent in `Authorization`; the request ID is sent in `X-Client-Request-Id`. Automatic IDs are hashes; direct recommendation IDs are caller-supplied. Do not put secrets in IDs or candidate descriptions.
54
+ <a id="guide-transmission-limits"></a>
60
55
 
61
- To disable automatic sharing, change **only `enabled` to `false`** in the existing private policy file referenced by `APTLY_HOOK_POLICY_PATH`. Preserve the other fields and ownership record. Subsequent automatic Hook calls preserve the original call before classification or creation of a call-binding file. This cannot undo a transmission already started or recall information received by the server. Editing a generated policy can cause ownership conflicts in setup, configuration, or removal commands; those commands do not overwrite the disabled policy. Do not edit ownership records to bypass the checks.
56
+ ## Content and limits
62
57
 
63
- When the transmission scope permits it, `mode: advisory` still transmits classification data; it is not a privacy opt-out. Removing `APTLY_HOOK_POLICY_PATH` can activate the older strict path, so do not use removal as an alternative. `enabled: false` does not block explicit `recommend_agent` or `aptly recommend` requests.
58
+ In `excerpt` scope, when no description was registered in advance, the automatic classification `summary` consists of an allowed task label and a **truncated excerpt of the first paragraph** of the body. It is not newly summarized or anonymized. Its UTF-8 size is at most `min(4000, max_summary_bytes)`; this is not a limit on the entire HTTP request. The Codex opaque-message fallback uses only a sufficiently specific `task_name`, without decrypting or sending the body. Labels can also contain sensitive information.
64
59
 
65
- For control over the shared summary, disable automatic sharing and write only the information needed for a direct recommendation. Aptly does not automatically fetch documents at URLs or attach source files mentioned in the summary. Checks for known key and Bearer patterns do not provide complete secret detection or establish that text is safe to transmit.
60
+ When a valid description is registered with `prepare_spawn_context`, a fixed prefix and that description replace the native excerpt for classification. Registration itself does not call the API. After an insufficient-context response, `retry_spawn_recommendation` retries once with a fixed prefix and a new supplemental description, without appending the previous body. In both paths, the raw description is limited to `min(3800, max_summary_bytes - 96)` bytes and the prefixed description to `min(4000, max_summary_bytes)` bytes. `prepare_fresh_delegation` itself reuses a completed recommendation without another classification call and returns independent instructions as local arguments for the next call. A Codex call explicitly specifying the returned model and effort is preserved by the current Hook as `explicit_model` without classification. A routing check on a subsequent call does not itself imply another classification. Neither path guarantees descriptions are non-sensitive or automatically anonymized.
66
61
 
67
- The ledger and Hook bindings store request metadata, hashes, and cached results, not task excerpts. Aptly diagnostics also exclude raw task text. The local Hook's `updatedInput` retains the original task so the host can continue execution. Aptly does not control the host's own transcript or log retention.
62
+ Decisions receives `client`, `task.summary`, `task.operation`, `task.context_sufficient`, candidate profile IDs, model and effort descriptions, and configured model characteristics. The classification API key is sent in the `Authorization` header and the request ID in `X-Client-Request-Id`. Automatic-path IDs are hashes; direct recommendation IDs are caller-specified. Do not put secrets in IDs or candidate descriptions.
68
63
 
69
- ## Related topics
64
+ To choose a summary yourself, turn off automatic sharing and write only the information needed for a direct recommendation. Aptly does not automatically read and attach documents or source files at URLs in a summary. Checks for known key and Bearer patterns are not complete secret detection or a guarantee of transmission safety.
70
65
 
71
- [Automatic recommendations](routing.md) · [Budget limits](budget.md) · [Execution statistics](statistics.md)
66
+ The ledger and Hook bindings store request metadata, hashes, and cached results, not task excerpts. Aptly diagnostics also omit the original text. However, the Hook's `updatedInput` retains the original task so the local host can continue execution. Aptly does not control the host's own conversation or log storage.
72
67
 
73
- [Guide home](../en.md)
68
+ [Automatic recommendations](routing.md) · [Budget](budget.md) · [Guide contents](../en.md)
package/docs/guide/en.md CHANGED
@@ -1,30 +1,25 @@
1
1
  # Aptly user guide
2
2
 
3
- This guide targets Aptly 0.1.13. Each topic preserves feature-specific minimum versions and recovery instructions for older releases.
4
-
5
3
  [한국어](ko.md) · **English** · [简体中文](zh-CN.md) · [日本語](ja.md)
6
4
 
7
- [Back to README](../../README.en.md)
8
-
9
- Korean is the canonical documentation. This guide covers general Aptly installation and usage. Package availability does not establish model access for every account. Claude Code or Codex controls native subagent execution, approvals, sandboxing, and MCP permissions.
10
-
11
- For a first setup, read **Installation → Configuration → Automatic recommendations**.
5
+ [README](../../README.en.md)
12
6
 
13
- ## Topics
7
+ Korean is the canonical documentation. For your first setup, read Installation → Configuration → Automatic recommendations.
14
8
 
15
- - [Installation and updates](en/installation.md)
16
- - [Configuration and model candidates](en/configuration.md)
17
- - [Automatic recommendations](en/routing.md)
18
- - [Decisions API transmission](en/transmission.md)
19
- - [Budget limits](en/budget.md)
20
- - [Execution statistics](en/statistics.md)
21
- - [Troubleshooting](en/troubleshooting.md)
22
- - [Advanced MCP integration and development](en/advanced.md)
23
- - [Measured costs](en/benchmarks.md)
9
+ | Task | Guide |
10
+ |---|---|
11
+ | Install, update, or remove | [Installation](en/installation.md) |
12
+ | API keys, account homes, models, stable launcher | [Configuration](en/configuration.md) |
13
+ | Hook behavior, abstention, and application conditions | [Automatic recommendations](en/routing.md) |
14
+ | Choose what to send to the OpenAI Decisions API | [Transmission scope](en/transmission.md) |
15
+ | Call and cost limits | [Budget](en/budget.md) |
16
+ | Compare recommendations with actual execution | [Statistics](en/statistics.md) |
17
+ | Registration, credential store, and ledger errors | [Troubleshooting](en/troubleshooting.md) |
18
+ | Manual MCP setup, direct recommendations, and development | [Advanced integration](en/advanced.md) |
19
+ | Measurement and cost conversion | [Measured costs](en/benchmarks.md) |
24
20
 
25
- ## Previous links
26
-
27
- Existing bookmark anchors remain available. Select an entry to open its section in the new topic page. This documentation move does not require setup or key re-entry.
21
+ <details>
22
+ <summary>Previous links</summary>
28
23
 
29
24
  <a id="installation"></a>
30
25
  - [Installation](en/installation.md#guide-installation)
@@ -88,3 +83,5 @@ Existing bookmark anchors remain available. Select an entry to open its section
88
83
  - [Interrupted processes and ledger locks](en/troubleshooting.md#guide-ledger-lock-recovery)
89
84
  <a id="diagnostics-and-development"></a>
90
85
  - [Diagnostics and development](en/advanced.md#guide-diagnostics-and-development)
86
+
87
+ </details>
@@ -145,6 +145,8 @@ fixture は、キー・ネットワーク・子エージェントの実行なし
145
145
 
146
146
  `context_retry_allowed: false` は追加の文脈補足を終了する意味です。互換性のある推薦の `caller_review_required` は親が引数を確認する意味であり、新しいユーザー承認の要求ではありません。既存の委任権限とホストの権限確認は引き続き適用されます。
147
147
 
148
+ 次の共通応答検証は 0.1.17 以降で利用できます。retry・fresh の適用メタデータは共通の Zod スキーマで検証します。retry の `required_fields` は未指定フィールドのみで、`next_action` は `apply_returned_defaults`(fresh は `submit_prepared_call`)です。禁止・不明な場合は停止し、既存エージェントの再利用を推薦適用の証拠にしないでください。内部不整合は原文なしで `recovery_metadata_invalid` を返し、完了した分類は再実行しません。厳密な応答検証では追加フィールドを許容してください。呼び出し元の遵守や権限を証明する検証ではありません。
149
+
148
150
  <a id="guide-fresh-delegation"></a>
149
151
 
150
152
  ## 別の独立した委任を準備する(0.1.6 以降)
@@ -153,6 +155,8 @@ defaults Hook が継承呼び出しへの適用を拒否した後、呼び出し
153
155
 
154
156
  元の継承呼び出しは拒否されたままです。別の `next_call.arguments` を確認し、既存の委任権限と通常のホスト権限確認の下で新しい呼び出しを送ってください。`fork_turns: "none"` と、元の選択を保つモデル・effort を含みます。呼び出し元の宣言であり、ユーザー意図や実行を検証するものではありません。履歴が必要・不明、固定役割、resume、未検証の追加実行引数がある場合は使わないでください。参照は一つのタスクだけに結び付き、5分の期限・取消・ポリシー/候補/元の呼び出しの変更で準備を止めます。元の実行を許す advisory 経路には提供しません。[契約と制限](../../SPAWN_CONTEXT.md#intentional-fresh-delegation)を確認してください。
155
157
 
158
+ 次の必須引数の案内は 0.1.16 以降で利用できます。`model`・`reasoning_effort` を含む `next_call.arguments` の全引数を渡してください。省略すると、不透明な新規呼び出しが再び文脈補足に進む場合があります。`spawn_application.required_fields` は呼び出し元の確認用で、権限の承認ではありません。ユーザーの選択や上位のホスト指示が親モデルの継承を要求する、またはいずれかのフィールドを禁止する場合は、適用できない旨を報告して停止してください。新しい復旧 ID で制限を回避しないでください。 制約の適用が不明な場合も停止し、不確実性を報告してください。Hook による明示フィールドの保持は、新しい呼び出しと準備結果の一致を検証するものではありません。
159
+
156
160
  ホストが元の呼び出しの拒否を報告した後だけ使ってください。`original_call_outcome` が `executed` または `unknown` なら準備を拒否します。これは呼び出し元の宣言で、サーバーの実行観測ではありません。同じ準備の反復は子の一回実行を保証しません。プロファイルは元の分類要約に基づくため別タスクに再利用しないでください。
157
161
 
158
162
  <a id="guide-model-info-cache"></a>