You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+9-5Lines changed: 9 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,27 +34,31 @@
34
34
</tr>
35
35
</table>
36
36
37
+
37
38
🚀 Repository for automated Java code migration research, part of the [MigrationBench](https://huggingface.co/collections/AmazonScience/migrationbench-68125452fc21a4564b92b6c3) project.
38
39
40
+
39
41
## 📦 Packages
40
42
41
43
This repository contains two main packages for Java code migration:
LLM-based agent library for automated Java 8 to Java 17 migration, built on the [Strands Agents](https://strandsagents.com/latest/) framework. Supports multiple migration strategies including baseline, PE (prompt engineering), RAG, and hybrid approaches.
45
47
46
-
### 🔧 [self_debug](./self_debug)
48
+
### 2. 🔧 [self_debug](./self_debug)
47
49
SDFeedback implementation for code migration with LLMs using self-debugging feedback. Includes both single-job and batch processing capabilities with AWS EMRS support.
48
50
51
+
49
52
## 📊 Data
50
53
51
54
Agent trajectories and execution results are stored in the `data/` folder.
Copy file name to clipboardExpand all lines: java_migration_agent/README.md
+30-21Lines changed: 30 additions & 21 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -52,22 +52,22 @@
52
52
53
53
## 1. Overview
54
54
55
-
Java Migration Agent is a library for automated code migration from Java 8 to Java 17 using LLM-based agents built on the [Strands Agents](https://github.com/strands-agents/strands-agents) framework.
55
+
Java Migration Agent is a library for automated code migration from Java 8 to Java 17 using LLM-based agents built on the [Strands Agents](https://github.com/strands-agents) framework.
56
56
57
57
It provides multiple agent strategies for migration:
58
-
-**Baseline**: Direct LLM-based migration
59
-
-**PE (Prompt Engineering)**: Baseline with enhanced prompts for dependency updates
60
-
-**RAG**: Uses retrieval-augmented generation for dependency version lookup
61
-
-**Hybrid**: Pre-processes dependencies before LLM migration
58
+
1.**Baseline**: Direct LLM-based migration
59
+
1.**PE (Prompt Engineering)** (Baseline + PE): Baseline with enhanced prompts for dependency updates
60
+
1.**RAG** (Baseline + PE + RAG): Uses retrieval-augmented generation for dependency version lookup
61
+
1.**Hybrid** (Seed change, followed by baseline + PE): Pre-processes dependencies before LLM migration
62
62
63
63
The agent relies on the [MigrationBench](https://github.com/amazon-science/MigrationBench) package for evaluation.
| 1 |[AmazonScience/migration-bench-java-full](https://huggingface.co/datasets/AmazonScience/migration-bench-java-full)| 5,102 | Each repo has a test directory or at least one test case |
70
-
| 2 |[AmazonScience/migration-bench-java-selected](https://huggingface.co/datasets/AmazonScience/migration-bench-java-selected)| 300 | A **subset** of migration-bench-java-full |
69
+
| 1 |[🤗 AmazonScience/migration-bench-java-full](https://huggingface.co/datasets/AmazonScience/migration-bench-java-full)| 5,102 | Each repo has a test directory or at least one test case |
70
+
| 2 |[🤗 AmazonScience/migration-bench-java-selected](https://huggingface.co/datasets/AmazonScience/migration-bench-java-selected)| 300 | A **subset** of migration-bench-java-full |
71
71
72
72
## 3. Installation
73
73
@@ -95,19 +95,26 @@ If you haven't done it yet, follow the instructions in [MigrationBench](https://
95
95
### 3.2 Install Package
96
96
97
97
```bash
98
-
cd java_migration_agent
99
-
pip install -e .
98
+
# cd .../JavaMigration/
99
+
100
+
cd java_migration_agent/
101
+
pip install -r requirements.txt -e .
100
102
```
101
103
102
104
Or with uv:
103
105
104
106
```bash
105
-
cd java_migration_agent
107
+
# cd .../JavaMigration/
108
+
109
+
cd java_migration_agent/
106
110
uv pip install -e .
107
111
```
108
112
109
113
## 4. Usage
110
114
115
+
See the full binary script at [java_migration_agent/src/java_migration_agent/main.py](https://github.com/amazon-science/JavaMigration/blob/main/java_migration_agent/src/java_migration_agent/main.py).
0 commit comments