File size: 1,629 Bytes
d26ccd4
 
52d502c
 
 
 
 
 
 
 
 
 
 
d26ccd4
52d502c
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
---
license: apache-2.0
base_model: Qwen/Qwen2.5-7B-Instruct
language:
- en
tags:
- instructlab
- lora
- code
- java
- code-refactoring
- qwen2.5
pipeline_tag: text-generation
---

# Qwen2.5-7B-Instruct Fine-Tuned for Java Code Refactoring

## Overview

This model is a fine-tuned version of **Qwen2.5-7B-Instruct** specialized for **Java code refactoring** using the **InstructLab** framework.

The training dataset was generated using the **Skills** pipeline of InstructLab, with **GPT-4o** acting as the teacher model to generate instruction-response pairs. A total of **1,440 synthetic training instances** were used for fine-tuning.

## Base Model

- Qwen/Qwen2.5-7B-Instruct

## Training

The dataset was generated using:

```bash
ilab data generate \
  --model "openai/gpt-4o" \
  --endpoint-url "http://localhost:8000/v1" \
  --api-key "$ILAB_API_KEY" \
  --pipeline simple
```

The model was fine-tuned using:

```bash
ilab model train \
  --model-path Qwen/Qwen2.5-7B-Instruct \
  --num-epochs 3 \
  --device cpu \
  --max-seq-len 2048 \
  --max-batch-len 10000 \
  --effective-batch-size 128 \
  --lora-rank 32 \
  --lora-alpha 64 \
  --lora-dropout 0.1 \
  --learning-rate 1e-4 \
  --is-padding-free false
```

## Intended Use

This model is intended for Java code refactoring tasks. It is designed to generate refactored Java code while preserving the original program behavior.

## Training Data

- Framework: InstructLab
- Pipeline: Skills
- Teacher model: GPT-4o
- Number of training instances: 1,440

## License

This model is released under the Apache 2.0 license, consistent with the license of the base model.