Severity: LOW (latent — inert in prod, which runs PLATFORM_AI_ENABLED="true"). Found in the 2026-07-16 storage/AI sweep (deferred).
With ai === null (flag off), the storage engine no-ops without throwing:
vectorizeStore returns [] → handleAddKnowledge reports vectorized:true
vectorizeRepoFile returns 0 → repo state machine marks every file done with 0 vectors → status done, "Ready (N files)"
vectorSearch returns [] → RAG always empty
Net: every KB add / URL import / repo index reports success, the console shows green, and the agent can answer nothing from its knowledge. The flag's documented default is "off", so any future toggle/misconfig silently produces this.
Files: workers/api/src/agent-do.ts:72 (gate), workers/api/src/agent-storage.ts (vectorizeStore :51, vectorizeRepoFile :222, vectorSearch :115).
Fix sketch: when the platform AI binding is intentionally off, either surface a clear "indexing disabled" state to the console/prompt instead of green "Ready", or make the ingest/search paths return an explicit disabled signal rather than empty-success.
Severity: LOW (latent — inert in prod, which runs
PLATFORM_AI_ENABLED="true"). Found in the 2026-07-16 storage/AI sweep (deferred).With
ai === null(flag off), the storage engine no-ops without throwing:vectorizeStorereturns[]→handleAddKnowledgereportsvectorized:truevectorizeRepoFilereturns0→ repo state machine marks every file done with 0 vectors → statusdone, "Ready (N files)"vectorSearchreturns[]→ RAG always emptyNet: every KB add / URL import / repo index reports success, the console shows green, and the agent can answer nothing from its knowledge. The flag's documented default is "off", so any future toggle/misconfig silently produces this.
Files:
workers/api/src/agent-do.ts:72(gate),workers/api/src/agent-storage.ts(vectorizeStore:51,vectorizeRepoFile:222,vectorSearch:115).Fix sketch: when the platform AI binding is intentionally off, either surface a clear "indexing disabled" state to the console/prompt instead of green "Ready", or make the ingest/search paths return an explicit disabled signal rather than empty-success.