Skip to content

Commit c43e38b

Browse files
committed
docs(readme): add usage workflow and refine project documentation
update core project description, add step-by-step usage workflow, and refine the before/after token savings example
1 parent 02d8910 commit c43e38b

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

README.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,22 @@ Every `CTRL+C → CTRL+V` to an AI chat burns tokens on code that has nothing to
3232

3333
## The Solution
3434

35-
`codei` builds a **hierarchical tree index** of your codebase. When you ask a question, LLM reasoning selects exactly which modules, files, and symbols are relevant — then returns only that.
35+
`codei` turns your repository into a compact, queryable map that AI tools can use on demand. Instead of asking an assistant to inspect every file, you build a local index once and let `codei` retrieve the few modules, files, symbols, and dependency signatures that matter for the current question.
36+
37+
The workflow is deliberately simple:
38+
39+
1. `codei index .` scans the project, respects your ignore rules, parses supported languages, and stores a local `.index/` tree.
40+
2. `codei query "<your question>"` uses the index to find the relevant parts of the codebase.
41+
3. The output is already formatted for an AI chat or coding agent, including selected source snippets plus lightweight dependency context.
42+
4. After code changes, `codei update` refreshes the index incrementally so future queries stay current.
43+
44+
This makes `codei` useful as a context layer for Codex, Claude Code, Cursor, Windsurf, Cline, Antigravity, and any agent that can run shell commands or call the local HTTP server. The agent asks `codei` first, then works with targeted context instead of guessing which files to open.
3645

3746
**Result: \~1,000-3,000 tokens per query instead of 50,000+**
3847

3948
```
4049
Before: Paste 200 files (50KB) → Ask "fix my login bug"
41-
After: Paste 3 files (2KB) → Same answer
50+
After: Query codei, paste 3 focused files (2KB) → Same answer
4251
```
4352

4453
***

0 commit comments

Comments
 (0)