Skip to content

Improve migration quality, add repair loop, improved rag#14

Closed
gvanica wants to merge 36 commits intomainfrom
improve-migration-quality
Closed

Improve migration quality, add repair loop, improved rag#14
gvanica wants to merge 36 commits intomainfrom
improve-migration-quality

Conversation

@gvanica
Copy link
Copy Markdown
Collaborator

@gvanica gvanica commented Apr 7, 2026

No description provided.

gvanica added 30 commits April 2, 2026 21:30
Merge from main, with maxKernel changes
- Replace monolithic convert_multimodal.py with 3 separate scripts:
  step1_clone_repo.py, step2_populate_rag.py, step3_convert.py
- Add config.py for shared paths and setup
- Update README with setup and demo instructions
- step3_merge.py: scans repo for nn.Module files using AST, merges into one
- step4_convert.py: converts the merged file (renamed from step3_convert.py)
- No hardcoded file lists — model files discovered automatically
- Updated README and Quick Start with 4-step flow
step1 now takes an optional URL argument so the demo pipeline can
convert any PyTorch repo, not just the hardcoded Multimodal-Transformer.
config.py derives REPO_URL/REPO_DIR from the MAXCODE_REPO_URL env var,
falling back to the original default.
…ercomputer/accelerator-agents into improve-migration-quality

# Conflicts:
#	MaxCode/agents/migration/primary_agent.py
gvanica added 6 commits April 13, 2026 11:30
Move merge and verification logic from demo scripts into reusable
agents so PrimaryAgent.run(repo_dir) handles the full pipeline
(merge -> convert -> verify) end-to-end.

New files:
- agents/migration/merge_agent.py: MergeAgent with file discovery,
  filtering, import graph analysis, and merging (pure logic, no LLM)
- agents/migration/verification_agent.py: VerificationAgent with
  AST-based completeness + optional LLM-based correctness scoring
- tools/verification_tool.py: standalone ADK tool for quality checks

Modified:
- primary_agent.py: directory path now uses MergeAgent instead of
  per-file processing; caches merge result for downstream use
- migration_tool.py: handles model+utils output format, auto-runs
  verification scorecard after conversion
- adk_agents.py: registers verify_conversion_tool on both agents
- step3_merge.py: simplified to thin wrapper around MergeAgent
- step5_verify.py: simplified to thin wrapper around VerificationAgent
- ARCHITECTURE.md, README.md: updated pipeline documentation
@gvanica gvanica closed this Apr 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant