claude-dev-env 2.36.0 → 4.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/.agents/skills/_shared/advisor/scripts/README.md +1 -1
  2. package/.agents/skills/team-advisor/SKILL.md +11 -11
  3. package/_shared/advisor/advisor-protocol.md +51 -51
  4. package/_shared/advisor/reference/advisor-block.md +9 -9
  5. package/_shared/advisor/reference/astra-rung.md +39 -0
  6. package/_shared/advisor/reference/identity.md +4 -4
  7. package/_shared/advisor/reference/lifecycle.md +6 -6
  8. package/_shared/advisor/reference/spawn-walk-log.md +9 -9
  9. package/_shared/advisor/reference/third-party-bind.md +11 -11
  10. package/_shared/advisor/reference/warm-up.md +13 -13
  11. package/_shared/advisor/scripts/codex_astra_advisor.py +308 -0
  12. package/_shared/advisor/scripts/codex_astra_preflight.py +115 -0
  13. package/_shared/advisor/scripts/codex_astra_reply.py +159 -0
  14. package/_shared/advisor/scripts/config/advisor_scripts_constants/advisor_route_constants.py +3 -3
  15. package/_shared/advisor/scripts/config/advisor_scripts_constants/astra_advisor_constants.py +38 -0
  16. package/_shared/advisor/scripts/model_tier_run_validator.py +17 -18
  17. package/_shared/advisor/scripts/tests/test_codex_astra_advisor.py +271 -0
  18. package/_shared/advisor/scripts/tests/test_codex_astra_preflight.py +24 -0
  19. package/_shared/advisor/scripts/tests/test_codex_astra_reply.py +42 -0
  20. package/_shared/advisor/scripts/tests/test_model_tier_run_validator.py +55 -30
  21. package/_shared/advisor/scripts/tests/test_tier_model_ids.py +14 -4
  22. package/_shared/pr-loop/scripts/pr_loop_shared_constants/terminology_sweep_constants.py +14 -0
  23. package/_shared/pr-loop/scripts/terminology_sweep.py +138 -50
  24. package/_shared/pr-loop/scripts/tests/test_terminology_sweep.py +13 -1
  25. package/docs/references/team-advisor-skill.md +3 -3
  26. package/hooks/validators/README.md +35 -1
  27. package/package.json +1 -1
  28. package/scripts/check.ps1 +18 -6
  29. package/scripts/policy_lint/adapter_detectors.py +42 -2
  30. package/scripts/policy_lint/adapters.py +24 -0
  31. package/scripts/policy_lint/config/constants.py +11 -0
  32. package/scripts/policy_lint/engine.py +1 -1
  33. package/scripts/policy_lint/model.py +1 -0
  34. package/scripts/policy_lint/registry.py +10 -1
  35. package/scripts/repository_checks/__init__.py +1 -0
  36. package/scripts/repository_checks/claude_md.py +108 -0
  37. package/scripts/repository_checks/config/__init__.py +1 -0
  38. package/scripts/repository_checks/config/constants.py +150 -0
  39. package/scripts/repository_checks/env_var_documentation.py +243 -0
  40. package/scripts/repository_checks/hook_modules.py +34 -0
  41. package/scripts/repository_checks/models.py +37 -0
  42. package/scripts/repository_checks/package_inventory.py +118 -0
  43. package/scripts/repository_checks/pytest_testpaths.py +84 -0
  44. package/scripts/repository_checks/reporting.py +39 -0
  45. package/scripts/repository_checks/runner.py +93 -0
  46. package/scripts/repository_checks/tracked_secrets.py +147 -0
  47. package/scripts/repository_checks/tracked_tree.py +28 -0
  48. package/scripts/repository_policy.py +120 -0
  49. package/scripts/tests/repository_policy_test_support.py +89 -0
  50. package/scripts/tests/test_cde_lint.py +25 -1
  51. package/scripts/tests/test_claude_md.py +68 -0
  52. package/scripts/tests/test_env_var_documentation.py +133 -0
  53. package/scripts/tests/test_hook_modules.py +17 -0
  54. package/scripts/tests/test_models.py +26 -0
  55. package/scripts/tests/test_package_inventory.py +96 -0
  56. package/scripts/tests/test_policy_lint_rules_registry.py +117 -0
  57. package/scripts/tests/test_pytest_testpaths.py +66 -0
  58. package/scripts/tests/test_reporting.py +54 -0
  59. package/scripts/tests/test_repository_policy.py +71 -0
  60. package/scripts/tests/test_runner.py +59 -0
  61. package/scripts/tests/test_tracked_secrets.py +175 -0
  62. package/scripts/tests/test_tracked_tree.py +28 -0
  63. package/_shared/advisor/reference/sol-rung.md +0 -39
  64. package/_shared/advisor/scripts/codex_sol_advisor.py +0 -581
  65. package/_shared/advisor/scripts/config/advisor_scripts_constants/sol_advisor_constants.py +0 -38
  66. package/_shared/advisor/scripts/tests/test_codex_sol_advisor.py +0 -740
@@ -4,7 +4,7 @@
4
4
 
5
5
  @~/.claude/_shared/advisor/scripts/model_tier_run_validator.py
6
6
 
7
- @~/.claude/_shared/advisor/scripts/codex_sol_advisor.py
7
+ @~/.claude/_shared/advisor/scripts/codex_astra_advisor.py
8
8
 
9
9
  @~/.claude/_shared/advisor/scripts/tier_model_ids.py
10
10
 
@@ -16,23 +16,23 @@ One warm advisor at the strongest tier this session can reach. This session is t
16
16
 
17
17
  | Doc | Holds |
18
18
  |---|---|
19
- | [`docs/references/advisor-tool.md`](../../docs/references/advisor-tool.md) | **Consult cadence and weight** — when to call, hard rule before first write, how to treat advice. Read this for every consult. |
20
- | [`~/.claude/_shared/advisor/advisor-protocol.md`](../../_shared/advisor/advisor-protocol.md) | **Bind and lifecycle** — session identity, host detect, model floor, warm-up, CLI fallback; its read map routes each moment to a `reference/` detail file. |
21
- | [`agents/session-advisor.md`](../../agents/session-advisor.md) | **Reply contract** — ENDORSE / CORRECTION / PLAN / STOP; SendMessage only. |
22
- | [`reference/advisor-docs-review.md`](reference/advisor-docs-review.md) | Anthropic advisor-tool source facts: measured effects, Sonnet steering, cost levers, failure modes. Background — read it when tuning the bind, not on every consult. |
19
+ | [`docs/references/advisor-tool.md`](../../docs/references/advisor-tool.md) | **Consult cadence and weight.** When to call, the hard rule before first write, and how to treat advice. Read this for every consult. |
20
+ | [`~/.claude/_shared/advisor/advisor-protocol.md`](../../_shared/advisor/advisor-protocol.md) | **Bind and lifecycle.** Session identity, host detect, model floor, warm-up, CLI fallback. Its read map routes each moment to a `reference/` detail file. |
21
+ | [`agents/session-advisor.md`](../../agents/session-advisor.md) | **Reply contract.** ENDORSE / CORRECTION / PLAN / STOP. SendMessage only. |
22
+ | [`reference/advisor-docs-review.md`](reference/advisor-docs-review.md) | Anthropic advisor-tool source facts: measured effects, Sonnet steering, cost levers, failure modes. Background. Read it when tuning the bind, not on every consult. |
23
23
 
24
24
  ## Bind
25
25
 
26
26
  1. Name the session identity first (protocol **Host profiles**), then walk the model floor.
27
- 2. Claude: Fable first in-session at `ADVISOR_EFFORT` (default low). When Fable is out of usage, bind Sol at the same effort. Codex: Sol in-session. Third-party: headless Fable then Sol. When the host's walk fails, fail closed.
28
- 3. Name: `team-advisor-agent` on Claude (Agent spawn of `session-advisor`); a native Sol subagent on Codex; one CLI `session_id` on a third-party host via the protocol Claude-chain.
27
+ 2. Claude: Fable first in-session at `ADVISOR_EFFORT` (default low). When Fable is out of usage, bind Astra at the same effort. Codex: Astra in-session. Third-party: headless Fable then Astra. When the host's walk fails, fail closed.
28
+ 3. Name: `team-advisor-agent` on Claude (Agent spawn of `session-advisor`); a native Astra subagent on Codex; one CLI `session_id` on a third-party host via the protocol Claude-chain or Astra helper.
29
29
  4. A Fable-tier spawn or re-spawn carries the exact token `FABLE-SPAWN-AUTHORIZED` in its prompt (protocol warm-up; `fable_spawn_gate` requires it).
30
- 5. Skip the multi-consumer "who you are" opener — sole consumer.
31
- 6. When the bind or reply path fails, fail closed and report to the user. On a third-party host, only the bound Claude advisor issues ENDORSE / CORRECTION / PLAN / STOP.
30
+ 5. Skip the multi-consumer "who you are" opener. This session is the sole consumer.
31
+ 6. When the bind or reply path fails, fail closed and report to the user. On a third-party host, only the bound advisor issues ENDORSE / CORRECTION / PLAN / STOP.
32
32
 
33
- **GOTCHA (Cursor / ThirdParty + Sol):** when the walk reaches Sol or the user asks for Sol, first tool call is `python ~/.claude/_shared/advisor/scripts/codex_sol_advisor.py --bind --enable-sol --cwd <repo-root>` with the charter on stdin — not Agent/Task, not a probe-path search. Details: [`third-party-bind.md`](../../_shared/advisor/reference/third-party-bind.md) GOTCHA and [`sol-rung.md`](../../_shared/advisor/reference/sol-rung.md).
33
+ **GOTCHA (Cursor / ThirdParty + Astra):** when the walk reaches Astra or the user asks for Astra, first tool call is `python ~/.claude/_shared/advisor/scripts/codex_astra_advisor.py --bind --enable-astra --cwd <repo-root>` with the charter on stdin. Do not use Agent or Task. Do not search for a probe path. Details: [`third-party-bind.md`](../../_shared/advisor/reference/third-party-bind.md) GOTCHA and [`astra-rung.md`](../../_shared/advisor/reference/astra-rung.md).
34
34
 
35
- Full walk, charter, consult packet, Sol routing, and drift re-bind live in the protocol read map and its authoritative `reference/` leaves.
35
+ Full walk, charter, consult packet, Astra routing, and drift re-bind live in the protocol read map and its `reference/` files.
36
36
 
37
37
  ## Consult
38
38
 
@@ -44,6 +44,6 @@ Aim for two consults on a normal task: one after orientation and one after write
44
44
 
45
45
  ## Constraints
46
46
 
47
- - One bind per session; this session owns spawn, in-session Sol spawn, or CLI bind, drift re-bind, and shutdown.
47
+ - One bind per session; this session owns spawn, in-session Astra spawn, or CLI bind, drift re-bind, and shutdown.
48
48
  - Bind at or above the protocol floor for this host.
49
49
  - The advisor only answers (messaging); the session runs tools and posts.
@@ -13,20 +13,20 @@ On Claude, continue with **Model floor** and the rest of this document.
13
13
 
14
14
  ## Read map
15
15
 
16
- The sections below hold the standing rules; open a reference file at the moment its row names.
16
+ The sections below hold the standing rules. Open a reference file at the moment its row names.
17
17
 
18
18
  | Moment | Open |
19
19
  |---|---|
20
- | Naming the session identity | [`reference/identity.md`](reference/identity.md) — Claude, Codex, or neither |
21
- | Binding on a Claude host | [`reference/warm-up.md`](reference/warm-up.md) — spawn fields, Fable token, charter |
22
- | Binding on a Codex host | [`reference/identity.md`](reference/identity.md) — in-session Sol spawn |
23
- | Binding from a third-party host | [`reference/third-party-bind.md`](reference/third-party-bind.md) — CLI bind steps, fail-closed rule |
24
- | Fable is out of usage | [`reference/sol-rung.md`](reference/sol-rung.md) — Sol fallback at shared effort |
25
- | Composing a consult | [`reference/consult-format.md`](reference/consult-format.md) — packet, new-evidence and report-back rules |
26
- | Assembling an executor spawn prompt | [`reference/advisor-block.md`](reference/advisor-block.md) — the paste parts |
27
- | Advisor drifts, dies, or the task pivots | [`reference/lifecycle.md`](reference/lifecycle.md) — re-spawn and re-bind steps |
28
- | Logging or checking a bind walk | [`reference/spawn-walk-log.md`](reference/spawn-walk-log.md) — record shape, validator |
29
- | Any CLI call to a Claude advisor | [`reference/cli-chain.md`](reference/cli-chain.md) — runner modes, alias table, resume |
20
+ | Naming the session identity | [`reference/identity.md`](reference/identity.md): Claude, Codex, or neither |
21
+ | Binding on a Claude host | [`reference/warm-up.md`](reference/warm-up.md): spawn fields, Fable token, charter |
22
+ | Binding on a Codex host | [`reference/identity.md`](reference/identity.md): in-session Astra spawn |
23
+ | Binding from a third-party host | [`reference/third-party-bind.md`](reference/third-party-bind.md): CLI bind steps, fail-closed rule |
24
+ | Fable is out of usage | [`reference/astra-rung.md`](reference/astra-rung.md): Astra fallback at shared effort |
25
+ | Composing a consult | [`reference/consult-format.md`](reference/consult-format.md): packet, new-evidence and report-back rules |
26
+ | Assembling an executor spawn prompt | [`reference/advisor-block.md`](reference/advisor-block.md): the paste parts |
27
+ | Advisor drifts, dies, or the task pivots | [`reference/lifecycle.md`](reference/lifecycle.md): re-spawn and re-bind steps |
28
+ | Logging or checking a bind walk | [`reference/spawn-walk-log.md`](reference/spawn-walk-log.md): record shape, validator |
29
+ | Any CLI call to a Claude advisor | [`reference/cli-chain.md`](reference/cli-chain.md): runner modes, alias table, resume |
30
30
 
31
31
  ## Host profiles
32
32
 
@@ -42,95 +42,95 @@ Session identity:
42
42
  Mechanical override for scripts:
43
43
 
44
44
  1. `ADVISOR_HOST_PROFILE=ThirdParty` or `=Claude` or `=Codex` (explicit override; any letter case).
45
- 2. `THIRD_PARTY=1` (or `true` / `yes` / `on`) — a third-party (non-Claude) harness.
45
+ 2. `THIRD_PARTY=1` (or `true` / `yes` / `on`) selects a third-party (non-Claude) harness.
46
46
  3. Default: Claude.
47
47
 
48
- ### Shared effort — any host
48
+ ### Shared effort, any host
49
49
 
50
- Fable and Sol both read `ADVISOR_EFFORT` (`low`, `medium`, `high`, `xhigh`, `max`). The default is `low`.
51
- Pass `--effort <level>` on the Sol helper to set effort for that Sol run.
50
+ Fable and Astra both read `ADVISOR_EFFORT` (`low`, `medium`, `high`, `xhigh`, `max`). The default is `low`.
51
+ Pass `--effort <level>` on the Astra helper to set effort for that Astra run.
52
52
  Pass `--effort <level>` on the Claude CLI bind for Fable. An unset or unrecognized value uses `low`.
53
53
 
54
- ### Sol rung
54
+ ### Astra rung
55
55
 
56
- On Claude and ThirdParty: when Fable is out of usage, bind Sol through the Codex helper.
57
- Open that attempt with `ADVISOR_SOL=1` (or `true` / `yes` / `on`) in the environment, or pass `--enable-sol` on the helper invocation.
56
+ On Claude and ThirdParty: when Fable is out of usage, bind Astra through the Codex helper.
57
+ Open that attempt with `ADVISOR_ASTRA=1` (or `true` / `yes` / `on`) in the environment, or pass `--enable-astra` on the helper invocation.
58
58
  Flag off both ways: fail closed when Fable did not bind.
59
- Flag on: run the Codex preflight and bind per [`reference/sol-rung.md`](reference/sol-rung.md); a failed preflight fails closed when Fable did not bind.
59
+ Flag on: run the Codex preflight and bind per [`reference/astra-rung.md`](reference/astra-rung.md); a failed preflight fails closed when Fable did not bind.
60
60
 
61
- On Codex: Sol is the in-session default. The `ADVISOR_SOL` flag is not required. Fail closed when that spawn does not bind.
61
+ On Codex: Astra is the in-session default. The `ADVISOR_ASTRA` flag is not required. Fail closed when that spawn does not bind.
62
62
 
63
63
  ### Claude host
64
64
 
65
- Use the **Model floor** ladder below (Fable first, then Sol when Fable is out of usage).
66
- Warm-up spawns `subagent_type: session-advisor` via the Agent tool; consults go through `SendMessage` to that warm agent.
65
+ Use the **Model floor** ladder below (Fable first, then Astra when Fable is out of usage).
66
+ Warm-up spawns `subagent_type: session-advisor` via the Agent tool for Fable; consults go through `SendMessage` to that warm agent. Astra uses the Codex helper.
67
67
  Assemble and paste each executor's Advisor block per the **Advisor block** section.
68
68
 
69
69
  ### Codex host
70
70
 
71
- Spawn a native in-session Sol subagent at `resolve_codex_model_id("Sol")`.
72
- Walk `candidate_tiers = ["Sol"]`. Record `{tier: "Sol", result: "spawned"}` on success.
73
- **Fail closed:** when Sol does not bind, set `selected_tier = null` and a `fallback_reason`, report that the advisor is unreachable, and **stop**.
74
- Do not walk Fable on a Codex host. Consults stay in-session with that Sol subagent.
71
+ Spawn a native in-session Astra subagent at `resolve_codex_model_id("Astra")`.
72
+ Walk `candidate_tiers = ["Astra"]`. Record `{tier: "Astra", result: "spawned"}` on success.
73
+ **Fail closed:** when Astra does not bind, set `selected_tier = null` and a `fallback_reason`, report that the advisor is unreachable, and **stop**.
74
+ Do not walk Fable on a Codex host. Consults stay in-session with that Astra subagent.
75
75
  Assemble and paste each executor's Advisor block per the **Advisor block** section.
76
76
 
77
77
  ### Third-party host
78
78
 
79
79
  On a third-party (non-Claude, non-Codex) harness, the shared CLI Claude-chain is the one path to a Claude advisor: bind Fable through it, per [`reference/third-party-bind.md`](reference/third-party-bind.md).
80
80
  The bound Claude session is the advisor; this third-party session stays the executor.
81
- Walk `candidate_tiers = ["Fable"]`. When Fable is out of usage, the sol rung binds after Fable (`candidate_tiers = ["Fable", "Sol"]`).
82
- **Cursor Sol first shot:** when the walk reaches Sol (or the user asks for Sol), bind through `codex_sol_advisor.py --bind --enable-sol` on the first tool call (see the GOTCHA in [`reference/third-party-bind.md`](reference/third-party-bind.md)) — not the Agent tool, and not a probe-path hunt.
83
- **Fail closed:** when every candidate fails, set `selected_tier = null` and a `fallback_reason`, report that the advisor is unreachable, and **stop** — ENDORSE / CORRECTION / PLAN / STOP come only from a bound advisor.
81
+ Walk `candidate_tiers = ["Fable"]`. When Fable is out of usage, the Astra rung binds after Fable (`candidate_tiers = ["Fable", "Astra"]`).
82
+ **Cursor Astra first shot:** when the walk reaches Astra (or the user asks for Astra), bind through `codex_astra_advisor.py --bind --enable-astra` on the first tool call (see the GOTCHA in [`reference/third-party-bind.md`](reference/third-party-bind.md)). Do not use the Agent tool, and do not hunt a probe path.
83
+ **Fail closed:** when every candidate fails, set `selected_tier = null` and a `fallback_reason`, report that the advisor is unreachable, and **stop**. ENDORSE / CORRECTION / PLAN / STOP come only from a bound advisor.
84
84
  Executors report to the orchestrating session; that session consults the bound advisor and relays the four-signal reply.
85
85
 
86
86
  ## Model floor
87
87
 
88
- On Claude and ThirdParty the advisor ladder is `Fable` first, then sol (flag-gated, Codex CLI) when Fable is out of usage.
89
- On Codex the walk is Sol only, in-session.
88
+ On Claude and ThirdParty the advisor ladder is `Fable` first, then Astra (flag-gated, Codex CLI) when Fable is out of usage.
89
+ On Codex the walk is Astra only, in-session.
90
90
  Opus is not an advisor candidate. `Sonnet` and `Haiku` are executor tiers only.
91
91
  Consumer `own_tier` is recorded on the spawn-walk log; it does not add Opus to the advisor walk.
92
92
  Tier names are canonical Title Case; the validator accepts any letter case and normalizes to Title Case.
93
- Try binds top-down. Each try resolves its candidate tier to the short model alias via the tier-to-alias map in [`reference/cli-chain.md`](reference/cli-chain.md).
94
- The advisor is created at `selected_tier` — the first ladder tier that binds.
95
- When Fable fails on a Claude host, try Sol if the flag is on, else fail closed. The CLI chain is the Fable bind path on a third-party host and the Claude-host fallback for Fable; it does not bind Opus as advisor.
96
- On a Codex host a failed Sol spawn fails closed per **Host profiles → Codex host**.
97
- On a third-party host the CLI chain is already the primary path, so a failed Fable (and Sol, when enabled) walk fails closed per **Host profiles → Third-party host**.
93
+ Try binds top-down. Fable resolves to the short model alias in [`reference/cli-chain.md`](reference/cli-chain.md); Astra resolves through `resolve_codex_model_id("Astra")` to `gpt-6-astra`.
94
+ The advisor is created at `selected_tier`, the first ladder tier that binds.
95
+ When Fable fails on a Claude host, try Astra if the flag is on, else fail closed. The CLI chain is the Fable bind path on a third-party host and the Claude-host fallback for Fable; it does not bind Opus as advisor.
96
+ On a Codex host a failed Astra spawn fails closed per **Host profiles → Codex host**.
97
+ On a third-party host the CLI chain is already the primary path, so a failed Fable (and Astra, when enabled) walk fails closed per **Host profiles → Third-party host**.
98
98
 
99
99
  Emit a structured spawn-walk log so the walk can be checked mechanically: [`reference/spawn-walk-log.md`](reference/spawn-walk-log.md).
100
100
  The validator checks ladder shape only; host policy sits on top.
101
101
 
102
- **Equal-tier pairings.** Bind Fable for an independent second pass on irreversible or security-sensitive work. The advisor is Fable or Sol.
102
+ **Equal-tier pairings.** Bind Fable for an independent second pass on irreversible or security-sensitive work. The advisor is Fable or Astra.
103
103
 
104
104
  ## Warm-up (once per session)
105
105
 
106
- On a **Claude host**, walk the candidate tiers top-down, spawning `session-advisor` in the background at each candidate's alias with the charter as its prompt, stopping at the first successful spawn.
107
- A **Fable**-tier try carries the exact token `FABLE-SPAWN-AUTHORIZED` in its prompt — `hooks/blocking/fable_spawn_gate.py` denies a Fable-tier spawn without it.
106
+ On a **Claude host**, spawn `session-advisor` at the Fable alias with the charter as its prompt. When Fable is out of usage and the Astra rung is open, bind Astra through the Codex helper instead.
107
+ A **Fable**-tier try carries the exact token `FABLE-SPAWN-AUTHORIZED` in its prompt. `hooks/blocking/fable_spawn_gate.py` denies a Fable-tier spawn without it.
108
108
  Full spawn fields and the charter template: [`reference/warm-up.md`](reference/warm-up.md).
109
109
 
110
- On a **Codex host**, spawn a native in-session Sol subagent with the same charter. Bind fields: [`reference/identity.md`](reference/identity.md) and [`reference/warm-up.md`](reference/warm-up.md).
110
+ On a **Codex host**, spawn a native in-session Astra subagent with the same charter. Bind fields: [`reference/identity.md`](reference/identity.md) and [`reference/warm-up.md`](reference/warm-up.md).
111
111
 
112
- On a **third-party host**, bind per [`reference/third-party-bind.md`](reference/third-party-bind.md) and charter the CLI session with the same charter — the reply contract is the same, and consults travel through the CLI runner.
112
+ On a **third-party host**, bind per [`reference/third-party-bind.md`](reference/third-party-bind.md) and charter the CLI session with the same charter. The reply contract is the same, and consults travel through the CLI runner.
113
113
 
114
114
  ## Consulting the warm agent
115
115
 
116
- Send a consult at the trigger points `docs/references/advisor-tool.md` **When to call** defines — plan lock-in, believed completion, hard-to-reverse actions, repeated failure or stalled progress, and reconsidered approach.
116
+ Send a consult at the trigger points `docs/references/advisor-tool.md` **When to call** defines: plan lock-in, believed completion, hard-to-reverse actions, repeated failure or stalled progress, and reconsidered approach.
117
117
  The paste parts in [`reference/advisor-block.md`](reference/advisor-block.md) restate them for executors.
118
118
 
119
- Each consult carries the sender's identity and assignment, the delta since the last consult, the live decision or blocker, and the paths or excerpts needed to answer well — full packet shape plus the new-evidence and report-back rules: [`reference/consult-format.md`](reference/consult-format.md).
119
+ Each consult carries the sender's identity and assignment, the delta since the last consult, the live decision or blocker, and the paths or excerpts needed to answer well. Full packet shape plus the new-evidence and report-back rules: [`reference/consult-format.md`](reference/consult-format.md).
120
120
  Consult briefs embed the `docs/references/advisor-tool.md` **Brevity cue** line, sized per that section.
121
121
 
122
- Treat the reply as a serious second opinion: a CORRECTION — whether it names a wrong step or a risk worth closing — is something to address before treating the plan or the work as done.
122
+ A CORRECTION names a wrong step or a risk worth closing. Address it before treating the plan or the work as done.
123
123
  Route a STOP, or an unreachable advisor, upward per [`reference/consult-format.md`](reference/consult-format.md).
124
124
 
125
- ## Advisor block — assemble and paste into every executor spawn prompt
125
+ ## Advisor block
126
126
 
127
- Assemble each executor's block from the parts in [`reference/advisor-block.md`](reference/advisor-block.md), in order: one transport preamble picked by host profile, then the shared core, then — for an executor at Sonnet or below — the weak-executor add-on.
127
+ Assemble each executor's block from the parts in [`reference/advisor-block.md`](reference/advisor-block.md), in order: one transport preamble picked by host profile, then the shared core, then the weak-executor add-on for an executor at Sonnet or below.
128
128
  Paste the assembled block at the **top** of the spawn prompt, ahead of any other sentence that mentions the advisor.
129
- The assembled block is self-contained — the executor receives this text alone.
129
+ The assembled block is self-contained. The executor receives this text alone.
130
130
 
131
131
  ## Lifecycle ownership
132
132
 
133
- The session that binds the advisor owns its whole lifecycle — first bind, drift re-spawn or re-bind, and shutdown; every other consumer reaches the advisor by message alone.
133
+ The session that binds the advisor owns its whole lifecycle: first bind, drift re-spawn or re-bind, and shutdown. Every other consumer reaches the advisor by message alone.
134
134
  Drift signals and the per-host re-spawn / re-bind steps: [`reference/lifecycle.md`](reference/lifecycle.md).
135
135
 
136
136
  ## CLI chain
@@ -140,14 +140,14 @@ Modes and failover, the tier-to-alias table, brief piping, and `--resume` sessio
140
140
 
141
141
  **Third-party host:** the primary bind and consult path; the walk order and fail-closed rule live in [`reference/third-party-bind.md`](reference/third-party-bind.md).
142
142
 
143
- **Codex host:** do not use this runner as the primary path. Sol binds in-session.
143
+ **Codex host:** do not use this runner as the primary path. Astra binds in-session.
144
144
 
145
145
  **Claude host:** fall back to this runner exactly when one of these holds:
146
- - The Agent-tool spawn errors at every candidate tier down to the floor — the tool itself is unavailable.
146
+ - The Agent-tool spawn errors at every candidate tier down to the floor. The tool itself is unavailable.
147
147
  - `SendMessage` to the shared advisor errors, or draws no reply within the bound in `ADVISOR_SENDMESSAGE_REPLY_WAIT_SECONDS` (120) in `$HOME/.claude/_shared/advisor/scripts/config/advisor_scripts_constants/model_tier_run_validator_constants.py`, and a re-spawn also fails.
148
148
  - The running session is itself a subagent barred from spawning further agents.
149
149
 
150
150
  ## State the mechanism
151
151
 
152
- One warm agent, addressed by name, whose transcript accumulates across consults — each consult sends only the delta since the last one.
152
+ One warm agent, addressed by name, whose transcript accumulates across consults. Each consult sends only the delta since the last one.
153
153
  A consuming skill's own text states this mechanism; a token or cost saving becomes a claim only after a measured comparison against cold spawns.
@@ -3,26 +3,26 @@
3
3
  Detail behind the **Advisor block** section of [`advisor-protocol.md`](../advisor-protocol.md).
4
4
  Open this when assembling the block for an executor spawn prompt.
5
5
 
6
- Assembly order: one transport preamble picked by host profile, then the shared core, then — for an executor at Sonnet or below — the weak-executor add-on.
6
+ Assembly order: one transport preamble picked by host profile, then the shared core, then the weak-executor add-on for an executor at Sonnet or below.
7
7
  Paste the assembled block at the **top** of the spawn prompt, ahead of any other sentence that mentions the advisor.
8
- The assembled block is self-contained — the executor receives this text alone, so every path it names is absolute.
8
+ The assembled block is self-contained. The executor receives this text alone, so every path it names is absolute.
9
9
  The consult rules it restates are owned by [`consult-format.md`](consult-format.md); edit that file first and carry the change here.
10
10
 
11
- ## Transport preamble — Claude host
11
+ ## Transport preamble for a Claude host
12
12
 
13
13
  > A shared session advisor named `<name>` is reachable via SendMessage; send each consult to it directly by that name.
14
14
 
15
- ## Transport preamble — Codex host
15
+ ## Transport preamble for a Codex host
16
16
 
17
- > A shared session advisor named `<name>` is reachable as a native Codex Sol subagent; send each consult to it in-session by that name.
17
+ > A shared session advisor named `<name>` is reachable as a native Codex Astra subagent; send each consult to it in-session by that name.
18
18
 
19
- ## Transport preamble — third-party host
19
+ ## Transport preamble for a third-party host
20
20
 
21
21
  > The orchestrating session owns a standing advisor for this run.
22
- > The advisor chain: Claude Fable, then Sol through the Codex CLI when Fable is out of usage and the sol flag and its preflight open that rung. Both rungs use `ADVISOR_EFFORT` (default low). When neither binds, there is no advisor.
22
+ > The advisor chain: Claude Fable, then Astra through the Codex CLI when Fable is out of usage and the Astra flag and its preflight open that rung. Both rungs use `ADVISOR_EFFORT` (default low). When neither binds, there is no advisor.
23
23
  > The orchestrating session is your one path to it: send each consult as a report to the session that assigned you, and it relays the advisor's reply.
24
24
 
25
- ## Shared core — every host
25
+ ## Shared core for every host
26
26
 
27
27
  > Consult before locking in a nontrivial approach, once you believe your assignment is done, before any hard-to-reverse action, when the same failure repeats or progress has stalled, and when the chosen approach is being reconsidered.
28
28
  > Build the first consult with the complete format in `$HOME/.claude/_shared/advisor/reference/consult-format.md`: assignment, desired outcome, constraints and exclusions, actions taken in order, real output and current state, live decision or blocker, validation evidence, unresolved risks, and load-bearing paths or excerpts. Later consults carry only changed evidence.
@@ -31,7 +31,7 @@ The consult rules it restates are owned by [`consult-format.md`](consult-format.
31
31
  > Replies open with one of ENDORSE, CORRECTION, PLAN, or STOP — treat CORRECTION and PLAN as actions to take.
32
32
  > On STOP, or when the advisor is unreachable, stop and report that back to whoever assigned you; advisor binding and the four signals stay with the session that owns the advisor.
33
33
 
34
- ## Weak-executor add-on — Sonnet or below, either host
34
+ ## Weak-executor add-on for Sonnet or below, either host
35
35
 
36
36
  > Send your first consult right after orientation and before your first write.
37
37
  > Send a completion consult once your writes and test output exist — that consult asks the advisor to hunt for missing requirements, untested behavior, wrong assumptions, unhandled edge cases, evidence gaps, and early completion claims.
@@ -0,0 +1,39 @@
1
+ # Astra rung
2
+
3
+ Detail behind the **Host profiles → Astra rung** section of [`advisor-protocol.md`](../advisor-protocol.md).
4
+ Open this when Fable is out of usage on a Claude or ThirdParty host and an Astra fallback bind is starting.
5
+ On a Codex host, Astra is the in-session default. See [`identity.md`](identity.md).
6
+
7
+ ## Flag
8
+
9
+ `ADVISOR_ASTRA=1` (or `true` / `yes` / `on`) opens the Astra fallback after Fable is out of usage. Set the variable in the helper's process environment, or pass `--enable-astra` on the helper invocation. The CLI flag opens the rung for that run without touching the environment.
10
+ Flag off both ways: fail closed when Fable did not bind.
11
+ A Windows `setx` write only updates the persisted user environment; only a process started after that write inherits the new value, so an already-running session either sets the flag in its own invoking process environment or passes `--enable-astra`.
12
+
13
+ ## Effort
14
+
15
+ `ADVISOR_EFFORT` selects Codex `model_reasoning_effort` for Astra and `--effort` for Fable: `low`, `medium`, `high`, `xhigh`, or `max`. The default is `low`, which sends `model_reasoning_effort="low"`. Pass `--effort <level>` on the helper to set effort for that Astra run without changing the environment. An unset or unrecognized value uses `low`.
16
+
17
+ Every fallback reply carries a `fallback_kind` field. `declined` means policy closed the rung (flag off, usage meter at or below the gate). `broken` means the Astra path itself failed (missing executable, spawn error, timeout, malformed reply). A `broken` fallback is a defect to report.
18
+
19
+ ## Preflight
20
+
21
+ Flag on: run the Codex preflight first.
22
+
23
+ ```
24
+ python ~/.claude/_shared/pr-loop/scripts/codex_usage_probe.py
25
+ ```
26
+
27
+ **GOTCHA. Probe path.** That installed path is the only one. `codex_astra_advisor.resolve_usage_probe_path` builds `~/.claude/_shared/pr-loop/scripts/codex_usage_probe.py` and stops. Do not hunt `skills/codex-review/`, Codex worktrees under `C:\dev\.codex\worktrees\`, or other copies. Repo home: `packages/claude-dev-env/_shared/pr-loop/scripts/`.
28
+
29
+ The shared entry point is `~/.claude/_shared/advisor/scripts/codex_astra_advisor.py`. It calls the installed probe and owns Astra bind or resume parsing. Bind with `python ~/.claude/_shared/advisor/scripts/codex_astra_advisor.py --bind --enable-astra --cwd <repo-root>` and pipe the charter on stdin. Resume with `--resume <session_id>` and pipe the delta consult on stdin.
30
+
31
+ The gate passes only when the probe exits 0, `percent_left` is finite numeric data, and `percent_left` is strictly greater than `WEEKLY_USAGE_GATE_THRESHOLD_PERCENT` from the existing probe. The exact-threshold case fails closed when Fable did not bind.
32
+
33
+ ## Branches
34
+
35
+ **Preflight pass.** Bind one Codex CLI session at `gpt-6-astra` with `model_reasoning_effort` set from `ADVISOR_EFFORT` (default `low`), `--sandbox read-only`, and JSON output. The helper receives the standing-reviewer charter on stdin and returns only parsed ENDORSE / CORRECTION / PLAN / STOP guidance with a session ID.
36
+
37
+ **Preflight fail.** Probe failure, non-zero exit, timeout, missing or malformed usage, `null`, non-finite usage, or usage at or below the threshold fails closed when Fable did not bind.
38
+
39
+ The helper owns the Astra attempt and returns an explicit fallback result. The consuming advisor path owns the Fable bind. Apply the same gate to every Astra attempt, including resume.
@@ -9,7 +9,7 @@ Call `resolve_session_identity` from `$HOME/.claude/_shared/advisor/scripts/tier
9
9
 
10
10
  | Identity text | Host profile | Bind path |
11
11
  |---|---|---|
12
- | a `codex` token | Codex | In-session Sol spawn |
12
+ | a `codex` token | Codex | In-session Astra spawn |
13
13
  | a `claude` token | Claude | In-session Fable spawn of `session-advisor` |
14
14
  | any other identity | ThirdParty | Headless CLI chain |
15
15
 
@@ -17,11 +17,11 @@ When both `codex` and `claude` tokens appear, Codex wins. Empty text is ThirdPar
17
17
 
18
18
  ## Bind path
19
19
 
20
- **Claude.** Spawn `subagent_type: session-advisor` at Fable through the Agent tool. When Fable is out of usage, bind Sol through the Codex helper if `ADVISOR_SOL` is on. Fail closed when neither binds.
20
+ **Claude.** Spawn `subagent_type: session-advisor` at Fable through the Agent tool. When Fable is out of usage, bind Astra through the Codex helper if `ADVISOR_ASTRA` is on. Fail closed when neither binds.
21
21
 
22
- **Codex.** Spawn a native in-session Sol subagent at `resolve_codex_model_id("Sol")` (`gpt-5.6-sol`). Walk `candidate_tiers = ["Sol"]`. Record `{tier: "Sol", result: "spawned"}` on success. The `ADVISOR_SOL` flag is not required. Fail closed when Sol does not bind. Do not walk Fable on a Codex host.
22
+ **Codex.** Spawn a native in-session Astra subagent at `resolve_codex_model_id("Astra")` (`gpt-6-astra`). Walk `candidate_tiers = ["Astra"]`. Record `{tier: "Astra", result: "spawned"}` on success. The `ADVISOR_ASTRA` flag is not required. Fail closed when Astra does not bind. Do not walk Fable on a Codex host.
23
23
 
24
- **ThirdParty.** Bind Fable through the CLI Claude-chain. When Fable is out of usage, bind Sol through the Codex helper if `ADVISOR_SOL` is on. Fail closed when neither binds.
24
+ **ThirdParty.** Bind Fable through the CLI Claude-chain. When Fable is out of usage, bind Astra through the Codex helper if `ADVISOR_ASTRA` is on. Fail closed when neither binds.
25
25
 
26
26
  ## Mechanical override
27
27
 
@@ -5,7 +5,7 @@ Open this when the advisor drifts, dies, or the task pivots.
5
5
 
6
6
  ## Claude host
7
7
 
8
- The session that spawns the shared advisor owns its whole lifecycle — spawn, drift-respawn, and shutdown.
8
+ The session that spawns the shared advisor owns its whole lifecycle: spawn, drift-respawn, and shutdown.
9
9
  Every other consumer (executors, or any other consulting session) reaches it by message alone; spawn, respawn, and shutdown belong to the owning session.
10
10
  One shared advisor exists per orchestrated session, owned by the session that spawned it.
11
11
 
@@ -14,15 +14,15 @@ A **Fable**-tier re-spawn carries the exact token `FABLE-SPAWN-AUTHORIZED` in th
14
14
 
15
15
  ## Codex host
16
16
 
17
- The session that spawns the shared Sol subagent owns its whole lifecycle — spawn, drift-respawn, and shutdown.
17
+ The session that spawns the shared Astra subagent owns its whole lifecycle: spawn, drift-respawn, and shutdown.
18
18
  Every other consumer reaches it by message alone; spawn, respawn, and shutdown belong to the owning session.
19
19
 
20
- **Re-spawn on drift.** If a reply shows the agent working from a stale picture, or the session pivots to an unrelated task, the owning session ends that agent and spawns a fresh native Sol subagent with a new charter.
20
+ **Re-spawn on drift.** If a reply shows the agent working from a stale picture, or the session pivots to an unrelated task, the owning session ends that agent and spawns a fresh native Astra subagent with a new charter.
21
21
 
22
22
  ## Third-party host
23
23
 
24
- The orchestrating session owns the Claude CLI advisor bind for the whole run — first bind, re-bind on drift or lost `session_id`, and fail-closed report when the chain cannot serve.
24
+ The orchestrating session owns the CLI advisor bind for the whole run: first bind, re-bind on drift or lost `session_id`, and fail-closed report when the bound path cannot serve.
25
25
 
26
- **Re-bind on drift.** If a reply shows a stale picture, the task pivots, or `--resume` fails after a usage-limit failover (session stores are per binary/account), re-bind through `claude_chain_runner.py` with the charter plus a compact recap of consults so far.
27
- Capture the new `session_id`, and log a fresh Fable walk with `result: "cli"` on success, then Sol when that rung is open.
26
+ **Re-bind on drift.** If a reply shows a stale picture, the task pivots, or `--resume` fails after a usage-limit failover (session stores are per binary/account), re-bind Fable through `claude_chain_runner.py` with the charter plus a compact recap of consults so far.
27
+ Capture the new `session_id`, and log a fresh Fable walk with `result: "cli"` on success, then Astra when that rung is open. An Astra re-bind uses `codex_astra_advisor.py --bind --enable-astra` with the same charter and recap, and records `result: "codex"` on success.
28
28
  Executors keep reporting to the orchestrating session; advisor binding stays with that session alone.
@@ -6,16 +6,16 @@ Detail behind the **Model floor** section of [`advisor-protocol.md`](../advisor-
6
6
 
7
7
  Write the log as JSON with these field names:
8
8
 
9
- - `own_tier` — the consuming session's tier (recorded; it does not add Opus to the advisor walk).
10
- - `host_profile` — `Claude`, `Codex`, or `ThirdParty`. Omit to default to `Claude`.
11
- - `candidate_tiers` — on Claude and ThirdParty, Fable, plus Sol when `sol_enabled` is true. On Codex, Sol only.
12
- - `sol_enabled` — a boolean recorded before candidate selection; on Claude and ThirdParty, `true` adds Sol after Fable and `false` walks Fable alone. On Codex this flag does not change the walk.
13
- - `attempts` — one `{tier, result}` entry appended as each bind try happens; `result` is `codex` for a Sol helper bind, `spawned` for an in-session spawn (Claude Agent or Codex native Sol), `cli` for a CLI Claude-chain bind, or a failure reason such as `unavailable`.
14
- - `selected_tier` — the tier of the first successful bind (first `codex`, `spawned`, or `cli` entry), or `null` paired with a `fallback_reason` string when none bound.
9
+ - `own_tier`: the consuming session's tier (recorded; it does not add Opus to the advisor walk).
10
+ - `host_profile`: `Claude`, `Codex`, or `ThirdParty`. Omit to default to `Claude`.
11
+ - `candidate_tiers`: on Claude and ThirdParty, Fable, plus Astra when `astra_enabled` is true. On Codex, Astra only.
12
+ - `astra_enabled`: a boolean recorded before candidate selection. On Claude and ThirdParty, `true` adds Astra after Fable and `false` walks Fable alone. On Codex this flag does not change the walk.
13
+ - `attempts`: one `{tier, result}` entry appended as each bind try happens. `result` is `codex` for an Astra helper bind, `spawned` for an in-session spawn (Claude Agent or Codex native Astra), `cli` for a CLI Claude-chain bind, or a failure reason such as `unavailable`.
14
+ - `selected_tier`: the tier of the first successful bind (first `codex`, `spawned`, or `cli` entry), or `null` paired with a `fallback_reason` string when none bound.
15
15
 
16
16
  ## Log path
17
17
 
18
- Write to a path the session controls — typically `<job-temp-dir>/model-tier-run.json`, or the OS temp directory when no job directory exists.
18
+ Write to a path the session controls, typically `<job-temp-dir>/model-tier-run.json`, or the OS temp directory when no job directory exists.
19
19
 
20
20
  ## Validator
21
21
 
@@ -28,5 +28,5 @@ Exit code `1` means a ladder invariant failed.
28
28
  Exit code `2` means the path or JSON was unusable.
29
29
  The same checks are available in-process via `validate_model_tier_run(run)`.
30
30
 
31
- The validator checks ladder shape only: the candidate slice, the order of bind tries, and the success-token rules per tier and host. On Claude and ThirdParty, Sol is attempted after Fable when `sol_enabled` is true, and `selected_tier: "Sol"` requires `result: "codex"`. On Codex, the walk is Sol only, and `result: "spawned"` or `result: "codex"` counts as success.
32
- Host policy sits on top of it — see the Model floor section of the protocol.
31
+ The validator checks ladder shape only: the candidate slice, the order of bind tries, and the success-token rules per tier and host. On Claude and ThirdParty, Astra is attempted after Fable when `astra_enabled` is true, and `selected_tier: "Astra"` requires `result: "codex"`. On Codex, the walk is Astra only, and `result: "spawned"` or `result: "codex"` counts as success.
32
+ Host policy sits on top of it. See the Model floor section of the protocol.
@@ -3,23 +3,23 @@
3
3
  Detail behind the **Host profiles → Third-party host** section of [`advisor-protocol.md`](../advisor-protocol.md).
4
4
  Open this when binding or re-binding the advisor from a third-party (non-Claude, non-Codex) harness.
5
5
 
6
- ## GOTCHA — Cursor Sol first shot
6
+ ## GOTCHA: Cursor Astra first shot
7
7
 
8
- Cursor is a third-party host. When the walk reaches Sol (`ADVISOR_SOL=1` / `--enable-sol` after Fable is out of usage, or the user asks for Sol), bind Sol on the **first** tool call through the headless Codex helper. Do not use the Agent or Task tool, do not spawn Grok as a substitute, and do not search the filesystem for `codex_usage_probe.py`.
8
+ Cursor is a third-party host. When the walk reaches Astra (`ADVISOR_ASTRA=1` / `--enable-astra` after Fable is out of usage, or the user asks for Astra), bind Astra on the **first** tool call through the headless Codex helper. Do not use the Agent or Task tool, do not spawn Grok as a substitute, and do not search the filesystem for `codex_usage_probe.py`.
9
9
 
10
10
  ```
11
- python "$HOME/.claude/_shared/advisor/scripts/codex_sol_advisor.py" --bind --enable-sol --cwd <repo-root>
11
+ python "$HOME/.claude/_shared/advisor/scripts/codex_astra_advisor.py" --bind --enable-astra --cwd <repo-root>
12
12
  ```
13
13
 
14
- Pipe the standing-reviewer charter on stdin. Persist `session_id` from the JSON reply. Later consults: `--resume <session_id>` with the delta on stdin. Capture helper / `codex` stdout as UTF-8 on Windows (`encoding="utf-8"`, `errors="replace"`). Probe path and preflight: [`sol-rung.md`](sol-rung.md).
14
+ Pipe the standing-reviewer charter on stdin. Persist `session_id` from the JSON reply. Later consults: `--resume <session_id>` with the delta on stdin. Capture helper / `codex` stdout as UTF-8 on Windows (`encoding="utf-8"`, `errors="replace"`). Probe path and preflight: [`astra-rung.md`](astra-rung.md).
15
15
 
16
- When the Sol flag is off, follow the Claude-chain steps below.
16
+ When the Astra flag is off, follow the Claude-chain steps below.
17
17
 
18
18
  ## Bind steps
19
19
 
20
20
  1. Name the session identity first (protocol **Host profiles**). This path is for a ThirdParty profile.
21
- 2. Walk `candidate_tiers = ["Fable"]`. When Fable is out of usage, the sol rung ([`sol-rung.md`](sol-rung.md)) binds Sol after Fable (`candidate_tiers = ["Fable", "Sol"]`).
22
- 3. **CLI bind (primary path):** for each candidate top-down, pipe a charter file into:
21
+ 2. Walk `candidate_tiers = ["Fable"]`. When Fable is out of usage, the Astra rung ([`astra-rung.md`](astra-rung.md)) binds Astra after Fable (`candidate_tiers = ["Fable", "Astra"]`).
22
+ 3. **CLI bind (primary path):** for Fable, pipe a charter file into:
23
23
 
24
24
  ```
25
25
  python "$HOME/.claude/scripts/claude_chain_runner.py" --routing-mode ordered_account -- -p --model <alias> --effort <effort> --output-format json
@@ -27,15 +27,15 @@ When the Sol flag is off, follow the Claude-chain steps below.
27
27
 
28
28
  Use `--model fable --effort` with the value of `ADVISOR_EFFORT` (default `low`) on Fable.
29
29
  User-facing wording follows [`rules/asd-ste100-language.md`](../../../rules/asd-ste100-language.md).
30
- A root advisor bind uses `--routing-mode ordered_account` — walk order, failover, and the `advisor_blocked` terminal status are in [`cli-chain.md`](cli-chain.md).
30
+ A root advisor bind uses `--routing-mode ordered_account`. Walk order, failover, and the `advisor_blocked` terminal status are in [`cli-chain.md`](cli-chain.md).
31
31
  4. Stop at the first successful bind.
32
- Record `{tier, result: "cli"}` and set `selected_tier` to that tier.
32
+ Record `{tier, result: "cli"}` for Fable or `{tier: "Astra", result: "codex"}` for the Astra helper, and set `selected_tier` to that tier.
33
33
  Persist `session_id` from the JSON events (any event carries it; the runner also surfaces it on `ChainInvocationOutcome.session_id`; reply text is the `type == "result"` event's `.result` field).
34
- Run every bind and every later consult with cwd set to the repo root the work is for — Claude sessions are project-scoped by working directory.
34
+ Run every bind and every later consult with cwd set to the repo root the work is for. Claude sessions are project-scoped by working directory.
35
35
  5. **Fail closed:** when every candidate fails (chain exhausted, `advisor_blocked`, or model unavailable), set `selected_tier = null` and a `fallback_reason`, report that the advisor is unreachable, and **stop**. ENDORSE / CORRECTION / PLAN / STOP come only from a bound advisor.
36
36
  6. Assemble and paste each executor's Advisor block from [`advisor-block.md`](advisor-block.md). Executors report to the orchestrating session; that session consults the bound advisor and relays the four-signal reply.
37
37
 
38
38
  ## Session model field
39
39
 
40
40
  Resolve a third-party session's own model field with `resolve_cli_model_id("ThirdParty")` → `third-party` when a host model alias is required.
41
- The **advisor** bind uses the Fable alias. Sol binds through the Codex helper.
41
+ The **advisor** bind uses the Fable alias. Astra binds through the Codex helper.
@@ -3,39 +3,39 @@
3
3
  Detail behind the **Warm-up** section of [`advisor-protocol.md`](../advisor-protocol.md).
4
4
  Open this when binding the warm advisor on a Claude host or a Codex host, and for the charter text on every host.
5
5
 
6
- ## Spawn fields — Claude host
6
+ ## Spawn fields for a Claude host
7
7
 
8
- The consuming skill's session walks the candidate tiers top-down. For each try, spawn with:
8
+ The consuming skill's session tries Fable first. Spawn with:
9
9
 
10
10
  - `subagent_type: session-advisor` (see [`agents/session-advisor.md`](../../../agents/session-advisor.md) for the full signal contract).
11
- - `model`: the short alias for that try's candidate tier via `resolve_cli_model_id` (alias table: [`cli-chain.md`](cli-chain.md)) — for example `fable`. The walk tries Fable first, then Sol when that rung is open.
11
+ - `model`: the short alias via `resolve_cli_model_id("Fable")` (alias table: [`cli-chain.md`](cli-chain.md)): `fable`. When Fable is out of usage and the Astra rung is open, continue with the Codex helper in [`astra-rung.md`](astra-rung.md) as the Astra fallback.
12
12
  - `name`: a name the session and every consumer will use to reach it (e.g. `team-advisor-agent`).
13
13
  - `run_in_background: true`.
14
- - `prompt`: the charter below. A **Fable**-tier try carries the exact token `FABLE-SPAWN-AUTHORIZED` in that prompt — `hooks/blocking/fable_spawn_gate.py` denies every `Agent` or `Task` spawn at `model: fable` whose prompt lacks that token. A try at any other tier needs no token.
14
+ - `prompt`: the charter below. A **Fable**-tier try carries the exact token `FABLE-SPAWN-AUTHORIZED` in that prompt. `hooks/blocking/fable_spawn_gate.py` denies every `Agent` or `Task` spawn at `model: fable` whose prompt lacks that token. A try at any other tier needs no token.
15
15
 
16
- Stop at the first successful spawn. That try's tier is `selected_tier`; the warm agent lives at that tier for the rest of the session.
16
+ Stop at the first successful bind. That try's tier is `selected_tier`; the warm advisor lives at that tier for the rest of the session.
17
17
 
18
18
  ## Charter (the spawn prompt)
19
19
 
20
- The charter states: the agent's role — standing reviewer, answers only via SendMessage, with file edits and commands out of its scope — the repo path, and the session's current goal in two or three sentences.
20
+ The charter states the agent's role, the repo path, and the session's current goal in two or three sentences. The agent is a standing reviewer. It answers only via SendMessage. File edits and commands are out of its scope.
21
21
  On a Fable-tier try, include the exact token `FABLE-SPAWN-AUTHORIZED` as plain text in this prompt (substring match; the gate reads the token alone, wherever it came from).
22
22
  State plainly:
23
23
 
24
24
  - Every consult carries: who is asking (name and assignment), what changed since their last consult, the live decision or question, and any load-bearing paths or excerpts.
25
- - Reply via SendMessage to whoever sent the consult, by name — each reply goes back to its own sender, and many different consumers may reach this one agent.
26
- - Treat each consult on its own terms, keyed to the sender's stated assignment. Different consumers' consults will interleave in this one transcript — keep each consumer's context separate, and blend only when a consult explicitly asks for that.
25
+ - Reply via SendMessage to whoever sent the consult, by name. Each reply goes back to its own sender, and many different consumers may reach this one agent.
26
+ - Treat each consult on its own terms, keyed to the sender's stated assignment. Different consumers' consults will interleave in this one transcript. Keep each consumer's context separate, and blend only when a consult explicitly asks for that.
27
27
  - If a consult re-raises a question already answered, with nothing new attached, reply by restating the prior answer and naming it as a restatement.
28
- - Every reply, including this first bind turn, opens its first line with exactly one of the four uppercase signal words — `ENDORSE`, `CORRECTION`, `PLAN`, `STOP` — and nothing else on that line. Standing by after the bind is itself an `ENDORSE` of the charter, stated as that first line.
28
+ - Every reply, including this first bind turn, opens its first line with exactly one of the four uppercase signal words: `ENDORSE`, `CORRECTION`, `PLAN`, `STOP`. Nothing else on that line. Standing by after the bind is itself an `ENDORSE` of the charter, stated as that first line.
29
29
 
30
30
  The agent finishes its first turn standing by. `SendMessage` alone resumes it; between consults it waits quietly.
31
31
 
32
32
  ## Codex host
33
33
 
34
- Spawn a native in-session Sol subagent at `resolve_codex_model_id("Sol")` (`gpt-5.6-sol`) with the charter as its prompt.
35
- Record `{tier: "Sol", result: "spawned"}` on success. Fail closed when that spawn does not bind.
36
- The `ADVISOR_SOL` flag is not required. Do not walk Fable. Consults stay in-session with that Sol subagent.
34
+ Spawn a native in-session Astra subagent at `resolve_codex_model_id("Astra")` (`gpt-6-astra`) with the charter as its prompt.
35
+ Record `{tier: "Astra", result: "spawned"}` on success. Fail closed when that spawn does not bind.
36
+ The `ADVISOR_ASTRA` flag is not required. Do not walk Fable. Consults stay in-session with that Astra subagent.
37
37
  Identity routing: [`identity.md`](identity.md).
38
38
 
39
39
  ## Third-party host
40
40
 
41
- Bind per [`third-party-bind.md`](third-party-bind.md) and charter the CLI session with the same charter — the reply contract is the same, and consults travel through the CLI runner.
41
+ Bind per [`third-party-bind.md`](third-party-bind.md) and charter the CLI session with the same charter. The reply contract is the same, and consults travel through the CLI runner.