How ravisidh36/argon works
Argon is a local-first CLI agent: a user request enters the agent loop, the selected model may request tools, and the loop executes them and continues with results until it can return a response. Its capabilities include filesystem operations, calculation, web search, and document RAG. The RAG path parses and cleans documents, chunks and embeds them, stores vectors, then retrieves and reranks candidates. The graph follows documented workflows and shown imports/calls; unsampled implementation details are represented only where the README documents them.
Main entry points: executor.py Tool executor · index_document.py Document indexing · loop.py Agent loop · endpoint_llm.py Endpoint model
Components 23
Agent orchestration
- Agent loop
agent/loop.py - Tool executor
agent/executor.py
Model integrations
- Endpoint model
models/endpoint_llm.py - Gemini model
models/gemini.py - Configuration
config.py
Agent tools
- Tool definitions
tools/__init__.py - Filesystem tools
tools/file_access.py - Calculator
tools/calculator.py - Web search
tools/web_search.py
Document retrieval
- Document indexing
retrieval/index_document.py - Document parsing
tools/document_understanding.py - Text cleaning
retrieval/cleaner.py - Chunk creation
retrieval/chunking.py - Text embeddings
retrieval/embeddings.py - FAISS vector store
retrieval/vector_store.py - Document registry
retrieval/document_registry.py - Candidate retrieval
retrieval/retrieve.py - Cross-encoder reranking
retrieval/rerank.py
Other components
- CLI user
- CLI entry
main.py - OpenAI-compatible endpoint
- Gemini API
- DuckDuckGo search
Connections 23
- CLI user → CLI entry: submits request
README.md - CLI entry → Agent loop: starts and queries
main.py - CLI entry → Configuration: selects model
- Agent loop → Tool executor: dispatches tools
README.md - Agent loop → Endpoint model: requests responses
README.md - Endpoint model → Tool definitions: loads schemas
models/endpoint_llm.py - Endpoint model → OpenAI-compatible endpoint: sends requests
models/endpoint_llm.py - Agent loop → Gemini model: uses common interface
README.md - Gemini model → Gemini API: sends chat messages
models/gemini.py - Tool executor → Filesystem tools: dispatches operations
agent/executor.py - Tool executor → Calculator: dispatches calculations
agent/executor.py - Tool executor → Web search: dispatches searches
agent/executor.py - Tool executor → Document indexing: dispatches indexing
agent/executor.py - Tool executor → Candidate retrieval: dispatches retrieval
agent/executor.py - Web search → DuckDuckGo search: queries
tools/web_search.py - Document indexing → Document parsing: parses document
retrieval/index_document.py - Document indexing → Text cleaning: cleans text
retrieval/index_document.py - Document indexing → Chunk creation: creates chunks
retrieval/index_document.py - Document indexing → FAISS vector store: saves vectors
retrieval/index_document.py - Document indexing → Document registry: registers document
retrieval/index_document.py - FAISS vector store → Text embeddings: embeds documents
retrieval/vector_store.py - Candidate retrieval → FAISS vector store: loads and searches
retrieval/retrieve.py - Candidate retrieval → Cross-encoder reranking: reranks candidates
retrieval/retrieve.py