Project Root and Config
Understand how eye picks a project root and bootstraps .eye/config.json.
Project Root and Config
eye resolves one project root at a time. It no longer depends on environment variables for project selection.
Root detection order
- Explicit
projectRootfrom the MCP tool call. - The nearest ancestor that already has
.eye/config.json. - The nearest workspace root marked by
.git,pnpm-workspace.yaml, orturbo.json. - The nearest project root marked by
package.json,tsconfig.json,jsconfig.json,pyproject.toml, orsetup.py. - The server process current working directory when nothing else matches.
For the smoothest setup, launch the server from the repository root or from any directory inside the target repository.
First-run config
On the first index-backed operation, eye creates .eye/config.json and seeds sourceRoots with inferred relative paths such as src, app, or packages/web/src.
sourceRoots decides which paths are indexed. Structure and source reads still work across the whole project root.
Edit the generated config when you need to narrow or widen the indexed surface.
Root override
Every MCP tool still accepts projectRoot. Use it when one server instance needs to inspect multiple repositories or when the client launches the server from an unrelated working directory.
Next step: prompt patterns for reliable navigation.