Production Ready - This project facilitates the migration of Spring Boot applications to Helidon MP 4.x with high fidelity.
An intelligent AI-powered RAG (Retrieval-Augmented Generation) agent that automatically migrates Spring Boot 3.x.x projects to Helidon MP 4.x.x projects with version-specific compatibility handling.
- AI-Powered Migration - Uses RAG (Retrieval-Augmented Generation) with regex fallback for high-fidelity transformations
- Knowledge Base - Vector database (ChromaDB) with 10,000+ migration patterns
- Hybrid Intelligence - Combines Vector Search (Semantics) with Deterministic Regex (Syntax)
- Multi-LLM Support - Ollama, OpenAI, Claude, or Groq
- Version-Aware - Handles Spring Boot 3.x.x → Helidon MP 4.x.x (Java 21)
- Dependency Resolution - Intelligent Maven dependency mapping and deduplication
- Configuration Migration - Automatic conversion to MicroProfile Config
- Multi-Agent System - Specialized agents for Dependencies, Code Transformation, and Validation
- Quick Start
- User Guide Start Here
- Installation
- Usage
- Architecture
- What Gets Migrated
- Contributing
- License
- Python 3.10+
- Java 21 (for Helidon 4.x)
- Maven 3.8+
- Clone the Repository
- Get the Brain: Download
knowledge_base.zipfrom Releases and unzip tomigration_db/. - Migrate Project:
# Basic migration (auto-detects versions) python migration_agent_main.py migrate \ /path/to/source-spring-app \ /path/to/target-helidon-app # Migration with Version Specification python migration_agent_main.py migrate \ /path/to/source-spring-app \ /path/to/target-helidon-app \ --spring-version 3.4.5 \ --helidon-version 4.3.2
The agent uses a Multi-Agent Orchestrator pattern:
- Dependency Agent: Scans
pom.xml, removes Spring artifacts, adds Helidon Bundles (MP, CDI, etc.), and fixes parent POMs. - Code Transform Agent:
- RAG Lookup: Finds semantic equivalents for Annotations and Classes.
- Regex Engine: Applies deterministic fixes (e.g.,
RestTemplate->ClientBuilder,ThreadPoolTaskExecutor->ExecutorService).
- Knowledge Base: A curated ChromaDB vector store containing typical migration patterns, "learned" through manual refinement.
- Annotations:
@RestController→@Path,@ApplicationScoped@GetMapping→@GET,@Path@Autowired→@Inject@Value→@ConfigProperty
- Dependencies: Spring Boot Starters → Helidon MP Bundles
- Configuration: Spring Beans (
@Bean) → CDI Producers (@Produces) - HTTP Client:
RestTemplate→ JAX-RSClient - Threading:
ThreadPoolTaskExecutor→ExecutorService - Proxy: Spring Cloud Gateway Proxy → JAX-RS Client Proxy
- Currently supports Maven only.
- Java only.
- Complex Spring Integration flows may require manual review.
To run the agent completely offline (privacy-focused) without OpenAI:
- Install Ollama: Download from ollama.com
- Pull a Coding Model:
ollama pull codellama:7b # OR ollama pull llama3 - Update Configuration: Edit your
.envfile:LLM_PROVIDER=ollama # Optional: Customize model or URL OLLAMA_MODEL=codellama:7b OLLAMA_BASE_URL=http://localhost:11434
The agent uses a ChromaDB vector database (migration_db/) to store migration patterns. To regenerate it from scratch (e.g., after modifying the dataset generator):
- Run Initialization:
# Generates 10,000+ patterns and loads them into ChromaDB python migration_agent_main.py init- Generates:
migration_dataset_production.json - Builds:
migration_db/(Vector Store)
- Generates:
We welcome community contributions to the migration knowledge base!
- Reference the Schema: Check
CONTRIBUTING_SAMPLE.jsonin the root directory for the required JSON structure. - Add Patterns:
- Option A (Preferred): Add logic to
src/dataset/production_dataset_generator.py. - Option B: Create a validated JSON file following the sample schema.
- Option A (Preferred): Add logic to
- Validate: Run
python migration_agent_main.py initto ensure your patterns are valid and loadable. - Submit PR: Raise a Pull Request with your changes.
Sample Pattern Structure:
{
"migration_type": "annotation",
"spring_pattern": "@RestController",
"helidon_pattern": "@Path",
"spring_code": "@RestController class Foo {}",
"helidon_code": "@Path(\"/\") @ApplicationScoped class Foo {}",
"description": "Migrates Spring RestController to JAX-RS Path"
}See the User Guide for more details.
This project is licensed under the Apache 2.0 License.