refactor: hard-fork GSD -> MSD (Make Software Done)

Mechanical rename produced by scripts/msd-rename.cjs: gsd/Gsd/GSD -> msd/Msd/MSD
across contents and paths, upstream package/repo coordinates -> @golem15/msd-core
and golem15com/msd-core. Deep links into upstream history, sibling upstream
packages, the GSD-2 import feature, CHANGELOG.md and .changeset/ are kept as-is.

Hand edits on top: MSD block-letter banner and logos, LICENSE copyright line,
package/plugin identity, regenerated lockfile, install-tree fixtures, derived
registries and benchmark baseline; migration checksum baseline re-locked
(MSD keeps its own install state, so no install had applied the old sums);
sort-order and regex-escaped expectations in tests adjusted.
This commit is contained in:
Jakub Zych
2026-10-06 01:47:40 +02:00
parent fe069b2a56
commit a9a7a328e6
2763 changed files with 78465 additions and 78434 deletions

View File

@@ -4,7 +4,7 @@
- **Date:** 2026-08-09
- **Issue:** [#2313](https://github.com/open-gsd/gsd-core/issues/2313) — epic (`enhancement` + `approved-enhancement`). This Phase-0 sub-issue: [#3240](https://github.com/open-gsd/gsd-core/issues/3240)
- **Supersedes:** [#2517](https://github.com/open-gsd/gsd-core/issues/2517)'s Codex per-tier `model` embedding **on the default path only**. Explicit `model_overrides` pins are unaffected; other runtimes are untouched.
- **Builds on:** [ADR-1239](1239-gsd-embeddable-orchestration-engine.md) (**EoS**), which classifies Codex `modelMode: passive`. This ADR is the install-time half its `:137` boundary note names as "not yet written".
- **Builds on:** [ADR-1239](1239-msd-embeddable-orchestration-engine.md) (**EoS**), which classifies Codex `modelMode: passive`. This ADR is the install-time half its `:137` boundary note names as "not yet written".
- **Relationship to prior work:** completes [#2310](https://github.com/open-gsd/gsd-core/issues/2310) / PR [#2312](https://github.com/open-gsd/gsd-core/pull/2312), which shipped the emission *guard*. Related model defaults: [#2122](https://github.com/open-gsd/gsd-core/issues/2122) (GPT-5.6 family), [#838](https://github.com/open-gsd/gsd-core/issues/838) (model ⇄ effort coupling), [#774](https://github.com/open-gsd/gsd-core/issues/774) (light-tier `service_tier`/`model_verbosity`).
## Context
@@ -41,7 +41,7 @@ account does not carry fails the request outright:
That is [#2310](https://github.com/open-gsd/gsd-core/issues/2310) / #2311 (closed duplicate). The
blast is not confined to one agent: a typed agent spawn that 400s degrades the whole plan/execute
flow to the non-equivalent generic-agent workaround, so the user loses the routing GSD was trying
flow to the non-equivalent generic-agent workaround, so the user loses the routing MSD was trying
to give them *and* the agent specialization, in exchange for a pin that never worked.
PR #2312 fixed the *alias* half — never write an Anthropic-flavored value (`opus`/`sonnet`/
@@ -82,7 +82,7 @@ because the `model_overrides` route to it remains live.
### D4 — `model_reasoning_effort` stays coupled to a pinned model
No pin ⇒ no effort line (#838). A `.toml` with no `model` but a static `model_reasoning_effort`
is partial routing: the model follows the Codex UI while the effort follows GSD. The knobs move
is partial routing: the model follows the Codex UI while the effort follows MSD. The knobs move
together or not at all.
### D5 — Supersede #2517 on the default path
@@ -114,7 +114,7 @@ postures differ, deliberately, and conflating them is the trap:
rejected.
**The health-check is liberal in parsing, strict in judging.** It tolerates comments, key ordering,
CRLF, and **extra keys GSD does not emit** — a user who hand-added `approval_policy` has not
CRLF, and **extra keys MSD does not emit** — a user who hand-added `approval_policy` has not
violated the posture. The check is a predicate on the two fields the posture owns (`model`,
`model_reasoning_effort`), never a whitelist over the document. When it does find a violation it
names the agent and the offending value rather than reporting a bare count.
@@ -127,7 +127,7 @@ names the agent and the offending value rather than reporting a bare count.
- **an unparseable document is skipped and reported, never partially rewritten.** A duplicate
`[table]` or trailing garbage is a refusal, not a best-effort edit;
- the literal text `model = ` occurring **inside** the `'''`-quoted `developer_instructions` block
is not a pin and must not be rewritten. The emitter writes agent prompts into that block and GSD's
is not a pin and must not be rewritten. The emitter writes agent prompts into that block and MSD's
agent prompts discuss models constantly, so a line-oriented `/^model\s*=/m` strip corrupts the
agent. This is the most likely way the sync ships a data-loss bug, and it is called out here so
it is a design constraint rather than a review finding.
@@ -140,7 +140,7 @@ Codex agents installed with a `runtime` set in config and a non-`inherit` `model
receiving per-tier GPT-5.6 pins by default — they omit, and inherit the session model.
**Who this actually reaches, stated precisely, because "non-`inherit`" understates it.**
`readGsdRuntimeProfileResolver` (`bin/install.js`) returns `null` — no resolver, therefore no
`readMsdRuntimeProfileResolver` (`bin/install.js`) returns `null` — no resolver, therefore no
embedded model even today — in exactly two cases: no `runtime` in project or home config, or
`model_profile === 'inherit'`. Everyone else gets a resolver, and **`model_profile` defaults to
`'balanced'`**. So the affected population is *every* Codex user who set a `runtime` and did not
@@ -151,7 +151,7 @@ The users who lose something real are on an **API-key** Codex account whose acco
`gpt-5.6-sol`/`terra`/`luna`. For them the fix is one line per agent:
```json
{ "model_overrides": { "gsd-planner": "gpt-5.6-sol" } }
{ "model_overrides": { "msd-planner": "gpt-5.6-sol" } }
```
`model_overrides` with a real Codex model id is the retained pin mechanism (D2). It is unaffected
@@ -167,13 +167,13 @@ line for that reason.
## Consequences
**Positive.** Codex agents launch reliably, because the session model is always available. GSD's
**Positive.** Codex agents launch reliably, because the session model is always available. MSD's
Codex behavior matches ADR-1239's own classification of it instead of contradicting it. Stale
installs become detectable (D6) and repairable (D7) rather than requiring a reinstall. The
`.toml` GSD emits gets smaller and has fewer ways to be wrong.
`.toml` MSD emits gets smaller and has fewer ways to be wrong.
**Negative.** Per-tier routing on Codex is gone by default, including for the API-key users who
could use it — recovered only by an explicit pin. GSD now owns a posture *validator* and a
could use it — recovered only by an explicit pin. MSD now owns a posture *validator* and a
*repairer* as permanent surface, both of which must track any future change to the emitted `.toml`
shape. Three surfaces (emitter, checker, syncer) now read one rule, which is a
generative-fix-divergence risk; it is mitigated by extracting the predicate into a single module in
@@ -201,7 +201,7 @@ same phase.
Rejected: it still 400s on a ChatGPT-account Codex that lacks the pinned model — the resolution
path was never the defect — and it entrenches the contradiction with ADR-1239's `passive`
classification.
2. **Persist `runtime:"codex"` into the shared `~/.gsd/defaults.json`.** Rejected: that is exactly
2. **Persist `runtime:"codex"` into the shared `~/.msd/defaults.json`.** Rejected: that is exactly
the cross-runtime poisoning open bug [#2297](https://github.com/open-gsd/gsd-core/issues/2297)
flags. Recorded here as a standing constraint: no phase of this epic writes shared defaults.
3. **Hybrid — pin when the model is available, omit when it is not.** *Deferred, not rejected on
@@ -209,7 +209,7 @@ same phase.
exposes one, this is the design to revisit, and D1 becomes its fallback rung rather than its
replacement.
4. **An allowlist of legal Codex model ids** instead of the Anthropic-flavored predicate. Rejected:
an allowlist goes stale the moment OpenAI ships a model, which reintroduces "GSD pins a model
an allowlist goes stale the moment OpenAI ships a model, which reintroduces "MSD pins a model
the account cannot use" one layer up — the same defect with a different cause.
5. **Fold this into ADR-1239 as an amendment.** Rejected: ADR-1239:137 scopes itself to the
*invocation-time* effort channel and names this as a separate ADR owning the *install-time*
@@ -217,7 +217,7 @@ same phase.
## Scope boundary
**In scope:** the static / install-time channel — what GSD writes into
**In scope:** the static / install-time channel — what MSD writes into
`~/.codex/agents/<agent>.toml`, how it validates what is already written, and how it repairs it.
**Out of scope:**
@@ -251,7 +251,7 @@ the promised-but-not-built shape that gate exists to catch. It is owned rather t
**Phase 4's scope is corrected here, and the correction is the point.** The epic body scopes the
smoke test to `model_profile: inherit`. That profile is precisely the one this ADR does **not**
change: `readGsdRuntimeProfileResolver` already returns `null` for `inherit`, so a Codex install
change: `readMsdRuntimeProfileResolver` already returns `null` for `inherit`, so a Codex install
under `inherit` omits the model today, before Phase 1. A smoke test scoped only to `inherit` would
therefore pass identically before and after the change it exists to prove — green, and vacuous.
@@ -271,7 +271,7 @@ to assemble it from Consequences and Scope boundary:
- **No deprecation window.** The default flips in a single minor release. A genuine departure from
deprecate-slowly-and-loudly, taken because the behavior being removed hard-400s for the majority
account type — but it is a departure, and no warning release is offered.
- **No model-availability detection.** GSD does not learn which models a Codex account exposes; it
- **No model-availability detection.** MSD does not learn which models a Codex account exposes; it
avoids the question by not pinning. Alternative 3 is the design to revisit if Codex ever exposes
such a signal.
- **Invocation-time effort-override drift is untouched.** ADR-1239's boundary.
@@ -339,7 +339,7 @@ implementation simply did not enforce it, and no test covered the case.
Codex now exposes `model` and `reasoning_effort` on some `spawn_agent` schemas. This is the
invocation-time capability signal that did not exist when this ADR adopted a session-only posture.
GSD therefore passes a workflow's resolved values on an individual spawn when — and only when —
MSD therefore passes a workflow's resolved values on an individual spawn when — and only when —
the visible schema advertises each field. The fields are detected independently from each other
and from `agent_type`; absent fields, empty values, and `"inherit"` continue to degrade to session
or static agent configuration.