search was running in cwd and missing the repo you indexed. Persist the indexed
path per provider in the selection store and resolve it back so `search` reads
the same graph `index` built. Graphify availability now checks `graphify --version`
(installed = selectable) instead of "a graph already exists here", and the CLI
keys Graphify sources on the repo path.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
contract.ts: repo-oriented interface (four required ops, three optional),
typed CodeProviderError, egress + capability consent guards.
Three real, runtime-drivable adapters:
- GbrainProvider: gbrain CLI (reuses lib/gbrain-exec + lib/gbrain-sources),
all seven capabilities.
- GraphifyProvider: graphify CLI — `graphify <dir>` builds the local graph,
`graphify query` searches it, export reads graphify-out/graph.json. Fully
local; never auto-installed.
- SourcebotProvider: self-hosted server over HTTP — register writes a local
git connection to config.json, search is POST /api/search, status is a
liveness probe. Loopback base URL = local (no egress); remote = consent.
selection.ts persists the chosen provider + per-repo indexing consent under
$GSTACK_HOME. picker.ts recommends GBrain first, resolves the selected
provider or null (provider-OFF), and probes live availability. Every adapter
degrades to PROVIDER_UNAVAILABLE when its tool/server is absent.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>