How shimaiibrahim/bi-agent- works
This is a multi-agent business intelligence and machine-learning platform: a client submits structured data through the API, which runs schema analysis, LLM-assisted planning, preprocessing, model training and evaluation, then produces a business report and persists artifacts. The README documents the principal staged workflow; core/workflow.py confirms its orchestration, while sampled code confirms planner-to-Gemini and model-registry behavior. The API, most agents, and concrete storage implementation were not sampled, so their internal wiring is shown only where documented, and uncertain artifact writes are omitted.
Main entry points: workflow.py Agent Workflow · model_agent.py Model Agent · llm_planner_agent.py LLM Planner · api.py FastAPI
Components 20
API and Workflow
- FastAPI
api.py - Agent Workflow
core/workflow.py
Dataset Analysis
- Schema Agent
agents/schema_agent.py - LLM Planner
agents/llm_planner_agent.py - Planning Prompt
prompts/planner_prompt.py - Gemini Provider
llm/gemini_provider.py - Preprocessing Agent
agents/preprocessing_agent.py - Data Processing Tools
tools/process_tools.py
Modeling
- Model Agent
agents/model_agent.py - Dataset Splitter
models/splitter.py - Model Registry
models/registry.py - Model Trainer
models/trainer.py - Model Validator
models/validator.py - Model Evaluator
models/evaluator.py
Reports and Storage
- Insights Report Agent
agents/insights_report_agent.py - Report Prompt
prompts/insights_report_prompt.py - Artifact Store
storage/base_store.py - Local Store
storage/local_store.py
Other components
- Client
- Gemini API
Connections 18
- Client → FastAPI: submits dataset
- FastAPI → Agent Workflow: starts workflow
- Agent Workflow → Schema Agent: runs
- Agent Workflow → LLM Planner: runs
- Agent Workflow → Preprocessing Agent: runs
- Agent Workflow → Model Agent: runs
- Agent Workflow → Insights Report Agent: runs
- LLM Planner → Planning Prompt: builds prompt
- LLM Planner → Gemini Provider: requests plan
- Gemini Provider → Gemini API: generates content
- Preprocessing Agent → Data Processing Tools: applies operations
- Model Agent → Dataset Splitter: splits data
- Model Agent → Model Registry: loads candidates
- Model Agent → Model Trainer: trains models
- Model Agent → Model Validator: validates models
- Model Agent → Model Evaluator: evaluates models
- Insights Report Agent → Report Prompt: builds prompt
- Artifact Store → Local Store: backed by