How sshiv-1/fiat works
Fiat is a terminal-based coding assistant. A user interacts through the CLI, which delegates requests to the orchestrator: simple requests go directly to a tool-enabled coder, while complex ones proceed through planning, implementation, testing, and review, with retries when needed. The CLI also supports provider/model configuration and a context dashboard. The README documents these workflow stages and capabilities; some implementation details, especially CLI command routing and the review loop, were not fully excerpted, so the graph omits uncertain connections.
Main entry points: orchestrator.py Orchestrator · cli.py Interactive CLI · provider_factory.py Provider Factory · state.py Session State
Components 18
CLI and Tools
- Interactive CLI
src/fiat/cli.py - Repository Tools
src/fiat/cli.py - System Prompt
src/fiat/prompt.py - Provider Config
src/fiat/config.py
Agent Workflow
- Orchestrator
src/fiat/agents/orchestrator.py - Planner
src/fiat/agents/orchestrator.py - Coder
src/fiat/agents/orchestrator.py - Tester
src/fiat/agents/orchestrator.py - Reviewer
src/fiat/agents/orchestrator.py
Model Providers
- Provider Factory
src/fiat/provider_factory.py - Provider Interface
src/fiat/providers.py - Gemini Provider
src/fiat/provider_gemini.py - OpenAI-Compatible Provider
src/fiat/provider_openai.py - Anthropic Provider
src/fiat/provider_anthropic.py
Session and Context
- Session State
src/fiat/state.py - Context Dashboard
src/fiat/context_ui.py
Other components
- User
- LLM Services
Connections 27
- User → Interactive CLI: enters request
README.md - Interactive CLI → Orchestrator: delegates chat
src/fiat/cli.py - Interactive CLI → Provider Config: loads and saves
src/fiat/cli.py - Interactive CLI → System Prompt: configures prompt
src/fiat/cli.py - Interactive CLI → Context Dashboard: opens dashboard
src/fiat/cli.py - Orchestrator → Provider Factory: creates providers
src/fiat/agents/orchestrator.py - Orchestrator → Provider Config: loads credentials
src/fiat/agents/orchestrator.py - Orchestrator → Session State: updates workflow status
src/fiat/agents/orchestrator.py - Orchestrator → Planner: plans complex tasks
README.md - Orchestrator → Coder: implements changes
README.md - Orchestrator → Tester: runs validation
README.md - Orchestrator → Reviewer: requests review
README.md - Planner → Repository Tools: inspects repository
README.md - Coder → Repository Tools: edits and runs commands
src/fiat/agents/orchestrator.py - Tester → Repository Tools: runs commands
src/fiat/agents/orchestrator.py - Reviewer → Repository Tools: inspects changes
README.md - Provider Factory → Provider Interface: implements contract
src/fiat/provider_factory.py - Provider Factory → Gemini Provider: creates
src/fiat/provider_factory.py - Provider Factory → OpenAI-Compatible Provider: creates
src/fiat/provider_factory.py - Provider Factory → Anthropic Provider: creates
src/fiat/provider_factory.py - Gemini Provider → LLM Services: streams requests
src/fiat/provider_gemini.py - OpenAI-Compatible Provider → LLM Services: streams requests
src/fiat/provider_openai.py - Anthropic Provider → LLM Services: streams requests
src/fiat/provider_anthropic.py - Context Dashboard → Session State: reads usage and status
src/fiat/context_ui.py - Gemini Provider → Session State: updates token usage
src/fiat/provider_gemini.py - OpenAI-Compatible Provider → Session State: updates token usage
src/fiat/provider_openai.py - Anthropic Provider → Session State: updates token usage
src/fiat/provider_anthropic.py