mirror of
https://github.com/garrytan/gstack.git
synced 2026-09-10 06:58:59 +02:00
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:
co-authored by
Claude Fable 5
parent
2b27d89ae3
commit
9124559810
+2
-13
@@ -63,14 +63,14 @@ That expands to the full `HostConfig` with these defaults:
|
||||
- `globalRoot` / `localSkillRoot`: `.myhost/skills/gstack`, `hostSubdir`: `.myhost`
|
||||
- `usesEnvVars: true` (false only for Claude, which uses literal `~` paths)
|
||||
- `frontmatter`: allowlist keeping `name` + `description`, no description limit
|
||||
- `generation`: no metadata sidecar, `skipSkills: ['codex']` (codex skill is Claude-only)
|
||||
- `generation`: no metadata file, `skipSkills: ['codex']` (codex skill is Claude-only)
|
||||
- `pathRewrites`: the standard trio derived from the resolved paths
|
||||
(`~/.claude/skills/gstack` → `~/{globalRoot}`, `.claude/skills/gstack` →
|
||||
`{localSkillRoot}`, `.claude/skills` → `{hostSubdir}/skills`)
|
||||
- `suppressedResolvers`: the GBrain pair (`GBRAIN_CONTEXT_LOAD`, `GBRAIN_SAVE_RESULTS`)
|
||||
- `runtimeRoot`: the shared asset list (`bin`, `browse/dist`, `browse/bin`,
|
||||
`gstack-upgrade`, `ETHOS.md` + review checklist files)
|
||||
- `install`: `{ prefixable: false, linkingStrategy: 'symlink-generated' }`
|
||||
- `install`: `{ linkingStrategy: 'symlink-generated' }`
|
||||
- `learningsMode: 'basic'`
|
||||
|
||||
Override any field by passing it to `defineHost()`. Two path-rewrite options:
|
||||
@@ -167,17 +167,6 @@ Key fields:
|
||||
| `suppressedResolvers` | Resolver functions that return empty for this host |
|
||||
| `coAuthorTrailer` | Git co-author string for commits |
|
||||
| `boundaryInstruction` | Anti-prompt-injection warning for cross-model invocations |
|
||||
| `adapter` | Path to adapter module for complex transformations |
|
||||
|
||||
## Adapter pattern (for hosts with different tool models)
|
||||
|
||||
If string-replace tool rewrites aren't enough (the host has fundamentally
|
||||
different tool semantics), use the adapter pattern: set the `adapter` field
|
||||
to the adapter module path. See `scripts/host-adapters/openclaw-adapter.ts`
|
||||
for the reference implementation (no shipped host currently sets `adapter`).
|
||||
|
||||
The adapter runs as a post-processing step after all generic rewrites. It
|
||||
exports `transform(content: string, config: HostConfig): string`.
|
||||
|
||||
## Validation
|
||||
|
||||
|
||||
Reference in New Issue
Block a user