How sumitkrsah05/agent-test works
Swarn is an autonomous ML engineering platform with two complementary task paths: an interactive tool-using agent and a solution-tree search workflow for iterative model experiments. Users initiate work through the CLI; the agent path dispatches tools, while search drafts, runs, reviews, and improves candidate solutions under budgets and a validation contract. The wider platform includes data and ML capabilities, document intelligence, persistent learning, evaluation, and MCP/web interfaces. Some subsystems are represented from README claims and the source index rather than inspected implementations, so their internal links are limited to documented relationships.
Main entry points: runner.py Tree search runner · agent_loop.py Agent loop · cli.py CLI · dashboard.py Dashboard
Components 32
Entry and orchestration
- CLI
agent/cli.py - Agent loop
agent/core/agent_loop.py - Role orchestrator
agent/core/orchestrator.py
Agent runtime
- Tool registry
agent/runtime/tools.py - LLM routing
agent/llm/router.py - Sandbox execution
agent/runtime/execution.py - Self-correction
agent/core/self_correction.py
ML engineering
- Data ingestion
agent/data/pipeline.py - Data analysis
agent/data/analysis.py - Data cleaning
agent/data/cleaner.py - Feature engineering
agent/ml/feature_engineering.py - Model training
agent/ml/model_training.py - ML evaluation
agent/ml/evaluation.py - Model deployment
agent/ml/deployment.py - Tree search runner
agent/ml/search/runner.py - Search policy
agent/ml/search/agent.py - Run journal
agent/ml/search/journal.py - Validation contract
agent/ml/search/contract.py - LLM evaluation
swarn/capabilities/llm_eval/runner.py
Knowledge and documents
- Cross-run learning
agent/memory/knowledge.py - Repository RAG
agent/memory/context_engine.py - Multimodal RAG
agent/memory/multimodal_rag.py - Document intelligence
swarn/capabilities/doc_intelligence.py - Document Q&A
swarn/capabilities/doc_qa.py - Document store
swarn/capabilities/doc_store.py
Platform services
- MCP interface
agent/integrations/mcp_server.py - Dashboard
agent/web/dashboard.py - Session memory
agent/memory/memory.py - Observability
agent/observability/observability.py - Data API
agent/web/data_api.py - Evaluation API
agent/web/eval_api.py
Other components
- User
Connections 40
- User → CLI: submits task
- CLI → Agent loop: starts agent
agent/cli.py - CLI → Role orchestrator: starts team run
agent/cli.py - Agent loop → LLM routing: requests model
agent/core/agent_loop.py - Agent loop → Tool registry: dispatches tools
agent/core/agent_loop.py - Agent loop → Self-correction: assesses results
agent/core/agent_loop.py - Tool registry → Sandbox execution: runs generated code
agent/runtime/tools.py - Tool registry → Data ingestion: loads datasets
agent/runtime/tools.py - Tool registry → Data analysis: invokes analysis
agent/runtime/tools.py - Tool registry → Feature engineering: invokes engineering
agent/runtime/tools.py - Role orchestrator → Agent loop: runs role agents
agent/core/orchestrator.py - Data ingestion → Data analysis: profiles datasets
agent/data/analysis.py - Data ingestion → Data cleaning: provides datasets
agent/data/cleaner.py - Data ingestion → Feature engineering: feeds features
agent/ml/feature_engineering.py - Feature engineering → Model training: prepares training
- Model training → ML evaluation: evaluates models
- ML evaluation → Model deployment: supports deployment
- User → Tree search runner: requests solve
- CLI → Tree search runner: starts search
- Tree search runner → Search policy: selects actions
- Tree search runner → Sandbox execution: executes candidates
- Tree search runner → Validation contract: checks candidates
- Tree search runner → Run journal: records attempts
- Tree search runner → LLM routing: requests drafts
- Tree search runner → Cross-run learning: learns across runs
- Agent loop → Repository RAG: queries code context
- Multimodal RAG → Repository RAG: shares index
agent/memory/multimodal_rag.py - Document Q&A → Document intelligence: uses extraction
swarn/capabilities/doc_qa.py - Document Q&A → Document store: retrieves documents
swarn/capabilities/doc_qa.py - Document intelligence → Multimodal RAG: indexes documents
swarn/capabilities/doc_intelligence.py - CLI → MCP interface: serves MCP
agent/cli.py - CLI → Dashboard: serves dashboard
- Dashboard → Run journal: reads search runs
agent/web/dashboard.py - Dashboard → Cross-run learning: reads playbook
agent/web/dashboard.py - Dashboard → Session memory: reads sessions
agent/web/dashboard.py - Dashboard → Data API: uses data API
agent/web/dashboard.py - Dashboard → Evaluation API: uses evaluation API
agent/web/dashboard.py - Agent loop → Session memory: stores history
agent/core/agent_loop.py - Role orchestrator → Observability: shares hooks
agent/core/orchestrator.py - User → LLM evaluation: requests evaluation