Reference
CLI Reference
The CLI uses the fixed session ID 1 — normal and RAG conversations are persisted in sessions/1.json. Agent mode keeps its graph state in memory. --rag and --agent cannot be combined.
Usage
Common invocations of the CLI entry point
# Use the provider and model configured in .env python src/main.py # Select a provider and optionally override its model python src/main.py --llm-provider openai --model gpt-4o-mini python src/main.py --llm-provider anthropic python src/main.py --llm-provider ollama # Ground answers in documents from docs/ python src/main.py --rag # Enable approval-gated tools python src/main.py --agent # Show all CLI options python src/main.py --help
Flags
| Flag | Description |
|---|---|
| --rag | Retrieve context from local documents in docs/ and cite sources. Cannot be combined with --agent. |
| --agent | Run the LangGraph agent with approval-gated tools instead of the plain chain. Cannot be combined with --rag. |
| --llm-provider | Overrides LLM_PROVIDER for this process: gemini, openai, anthropic, or ollama. |
| --model | Overrides the model name for whichever provider is active. |
| --help | Shows all CLI options. |
Exiting
Submit an empty prompt to exit the chat loop. History for normal and RAG conversations is written to sessions/1.json on exit; agent mode's graph state does not persist between runs.
Next steps
- See what each provider requires — Configuration & LLM Providers.
- See the three agent tools and the approval prompt — LangGraph Agent.