fix(autopilot): boot warning must not recommend the DB-plane config set path

`gbrain config set anthropic_api_key` writes the config TABLE via
engine.setConfig; buildGatewayConfig only folds file-plane keys
(~/.gbrain/config.json) + env, so following the warning's advice left
isAvailable('chat') false and the warning firing forever (verified
empirically on a scratch brain). Point at the two paths that actually
resolve: ~/.gbrain/env (sourced by the daemon wrapper) and the
config.json file plane.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Garry Tan
2026-07-22 11:47:19 -07:00
co-authored by Claude Fable 5
parent e29bf0d0d1
commit 822d7fec0b
+5 -1
View File
@@ -365,7 +365,11 @@ export function chatBootWarning(chatAvailable: boolean): string | null {
if (chatAvailable) return null;
return (
'[autopilot] WARNING: no chat provider available — LLM phases (extract, dream, enrich) will no-op. ' +
'Set a key via `gbrain config set anthropic_api_key <key>` or export it in ~/.gbrain/env (sourced by the daemon wrapper).'
// NOT `gbrain config set anthropic_api_key`: that writes the DB plane,
// which the gateway never reads (isAvailable('chat') stays false) — the
// split-brain class build-gateway-config.ts documents. File plane or env
// are the two paths that actually resolve.
'Export ANTHROPIC_API_KEY in ~/.gbrain/env (sourced by the daemon wrapper) or set "anthropic_api_key" in ~/.gbrain/config.json.'
);
}