fix(hosts): delete five dead HostConfig fields

metadataFormat (generator hardcodes openai.yaml), sidecar (behavior lives in
setup's create_agents_sidecar — knowledge preserved as a comment in codex.ts),
install.prefixable (skill_prefix is implemented entirely in bin/gstack-config),
staticFiles (docstring cited a SOUL.md that never existed anywhere), and
adapter (its only would-be consumer, openclaw-adapter.ts, was fully dead —
with a test asserting the field was undefined). Kept: learningsMode (wired
next), linkingStrategy (validation reads it), coAuthorTrailer (consumed by
resolvers/utility.ts).

Proof: JSON dump diff shows ONLY the deleted keys vanishing; zero-diff regen
across all 10 hosts; host-config + gen-skill-docs suites green. Note: this
commit also carries chunk-23 edits to the shared hosts/claude.ts +
define-host.ts + host-config.test.ts files (skipSkills collapse, stale
line-number comment drops) — pathspec commits, concurrent prep.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Garry Tan
2026-08-14 21:12:22 -07:00
co-authored by Claude Fable 5
parent 2b27d89ae3
commit 9124559810
7 changed files with 25 additions and 86 deletions
+8 -17
View File
@@ -9,11 +9,9 @@
* paths, the shared runtimeRoot asset list, and symlink-generated install.
*
* Defaults are constructed fresh per call, so no two host configs ever share
* a mutable array/object. Fields that are absent today (staticFiles, adapter,
* sidecar, toolRewrites, coAuthorTrailer, boundaryInstruction) stay absent
* unless a host explicitly sets them — the factory never default-populates
* optional fields (test/host-config.test.ts pins e.g. openclaw.adapter as
* undefined).
* a mutable array/object. Optional fields that are absent today (toolRewrites,
* coAuthorTrailer, boundaryInstruction) stay absent unless a host explicitly
* sets them — the factory never default-populates optional fields.
*/
import type { HostConfig } from '../scripts/host-config';
@@ -27,11 +25,11 @@ type PathRewrite = { from: string; to: string };
* non-Claude agent runtimes (OpenClaw, Hermes, GBrain).
*/
export const CROSS_MODEL_RESOLVERS: string[] = [
'DESIGN_OUTSIDE_VOICES', // design.ts:485 — invokes Codex for outside voices
'ADVERSARIAL_STEP', // review.ts:408 — invokes Codex adversarially
'CODEX_SECOND_OPINION', // review.ts:257 — invokes Codex
'CODEX_PLAN_REVIEW', // review.ts:541 — invokes Codex
'REVIEW_ARMY', // review-army.ts:180 — multi-model orchestration
'DESIGN_OUTSIDE_VOICES', // design.ts — invokes Codex for outside voices
'ADVERSARIAL_STEP', // review.ts — invokes Codex adversarially
'CODEX_SECOND_OPINION', // review.ts — invokes Codex
'CODEX_PLAN_REVIEW', // review.ts — invokes Codex
'REVIEW_ARMY', // review-army.ts — multi-model orchestration
];
/**
@@ -111,16 +109,12 @@ export function defineHost<const N extends string>(overrides: HostOverrides<N>):
'review': ['checklist.md', 'TODOS-format.md'],
},
},
sidecar,
install = {
prefixable: false,
linkingStrategy: 'symlink-generated',
},
coAuthorTrailer,
learningsMode = 'basic',
boundaryInstruction,
staticFiles,
adapter,
} = overrides;
if (pathRewrites && extraPathRewrites) {
@@ -156,12 +150,9 @@ export function defineHost<const N extends string>(overrides: HostOverrides<N>):
...(toolRewrites !== undefined ? { toolRewrites } : {}),
suppressedResolvers,
runtimeRoot,
...(sidecar !== undefined ? { sidecar } : {}),
install,
...(coAuthorTrailer !== undefined ? { coAuthorTrailer } : {}),
learningsMode,
...(boundaryInstruction !== undefined ? { boundaryInstruction } : {}),
...(staticFiles !== undefined ? { staticFiles } : {}),
...(adapter !== undefined ? { adapter } : {}),
};
}