How kaviyasivakumarc29-debug/-multi-agent-legacy-code-migration-engine works
This is a multi-agent legacy-code migration engine: a user starts a repository migration, then files are parsed and dependency-ordered, risk-planned, migrated, parity-tested in a Docker sandbox with bounded correction, reviewed, and held for per-file human approval. Approved files advance; rejected files return to migration, and the API exposes a final report. The React UI starts jobs, polls status, and displays diffs and review decisions. Edges follow the shown API, orchestrator, agent, and tool calls; unshown persistence or deployment details are omitted.
Main entry points: orchestrator.py Workflow orchestrator · llm_client.py LLM client · App.jsx Migration dashboard · main.py Migration API
Components 19
User interface
- Migration dashboard
frontend/src/App.jsx - Diff viewer
frontend/src/components/DiffViewer.jsx - Approval panel
frontend/src/components/ApprovalPanel.jsx
API control
- Migration API
backend/app/main.py - Job state
backend/app/main.py - Migration schemas
backend/app/models.py - Runtime settings
backend/app/config.py - Migration report
backend/app/main.py
Migration workflow
- Workflow orchestrator
backend/app/orchestrator.py - Repository parser
backend/app/tools/repo_parser.py - Risk planner
backend/app/agents/planner.py - Migration coder
backend/app/agents/coder.py - Parity tester
backend/app/agents/tester.py - Migration reviewer
backend/app/agents/reviewer.py
Agent tools
- LLM client
backend/app/tools/llm_client.py - Docker test runner
backend/app/tools/sandbox_runner.py
Other components
- Migration user
- Anthropic API
- Docker runtime
Connections 19
- Migration user → Migration dashboard: starts and reviews
frontend/src/App.jsx - Migration dashboard → Migration API: calls migration endpoints
frontend/src/App.jsx - Migration dashboard → Diff viewer: renders diff
frontend/src/App.jsx - Migration dashboard → Approval panel: renders decisions
frontend/src/App.jsx - Migration API → Workflow orchestrator: starts and resumes
backend/app/main.py - Migration API → Job state: stores job state
backend/app/main.py - Migration API → Migration report: builds report
backend/app/main.py - Workflow orchestrator → Repository parser: parses repository
backend/app/orchestrator.py - Workflow orchestrator → Risk planner: plans files
backend/app/orchestrator.py - Workflow orchestrator → Migration coder: migrates files
backend/app/orchestrator.py - Workflow orchestrator → Parity tester: generates and runs tests
backend/app/orchestrator.py - Workflow orchestrator → Migration reviewer: reviews results
backend/app/orchestrator.py - Risk planner → LLM client: requests plan
backend/app/agents/planner.py - Migration coder → LLM client: requests migration
backend/app/agents/coder.py - Parity tester → LLM client: generates tests
backend/app/agents/tester.py - Migration reviewer → LLM client: requests review
backend/app/agents/reviewer.py - LLM client → Anthropic API: calls model
backend/app/tools/llm_client.py - Parity tester → Docker test runner: executes tests
backend/app/agents/tester.py - Docker test runner → Docker runtime: runs isolated container
backend/app/tools/sandbox_runner.py