JSSP LLaMA 8B Fine-tuned Model
Model Description
μ΄ λͺ¨λΈμ Job Shop Scheduling Problem (JSSP) μ΅μ νλ₯Ό μν΄ νμΈνλλ LLaMA 8B λͺ¨λΈμ
λλ€.
inference_jssp_fssp.pyμμ λ°λ‘ μ¬μ©ν μ μλλ‘ μ΅μ νλμμ΅λλ€.
Training Details
- Base Model:
unsloth/Meta-Llama-3.1-8B-Instruct-bnb-4bit - Fine-tuning Method: LoRA (Low-Rank Adaptation)
- LoRA Rank: 64
- Training Epochs: 4
- Max Sequence Length: 40,000 tokens
- Dataset: ACCORD JSSP dataset
- Training Framework: Unsloth + HuggingFace Transformers
Usage (inference_jssp_fssp.py μ€νμΌ)
from unsloth import FastLanguageModel
import torch
# 1. λͺ¨λΈ λ‘λ (inference_jssp_fssp.pyμ λμΌ)
model, tokenizer = FastLanguageModel.from_pretrained(
model_name="HYUNJINI/jssp_llama8b_accord_r64_ep4",
max_seq_length=40000, # JSSP λ¬Έμ μ²λ¦¬λ₯Ό μν κΈ΄ μνμ€
load_in_4bit=True,
dtype=torch.bfloat16,
)
# 2. μΆλ‘ λͺ¨λ μ€μ
FastLanguageModel.for_inference(model)
# 3. JSSP λ¬Έμ μΆλ‘
from solution_generation_english import generate_multiple_solutions
# JSSP λ¬Έμ λ°μ΄ν° μ€λΉ
jssp_problem = "..." # λΉμ μ JSSP λ¬Έμ
inst_for_ortools = [...] # λ¬Έμ λ§€νΈλ¦μ€
# μ루μ
μμ±
best_gap, is_feasible_list, gap_list, _, calculated_makespan_list, time_list, initial_solutions, recalculated_solutions, _, _ = generate_multiple_solutions(
model=model,
tokenizer=tokenizer,
jssp_problem=jssp_problem,
inst_for_ortools=inst_for_ortools,
real_makespan=optimal_makespan,
dev_map="cuda:0",
sample=True,
num_solutions=10,
top_k=50,
top_p=0.95,
temperature=1.0,
max_len=40000,
reflexion_iterations=0,
enable_improvement=False
)
Model Performance
- νμ΅ λ°μ΄ν°: ACCORD λ°μ΄ν°μ μ JSSP λ¬Έμ λ€
- μΆλ ₯ νμ:
Job X Operation Y, MZννμ μ€μΌμ€λ§ μ루μ - κ²μ¦: μμ ν μ€μΌμ€ κ²μ¦ λ° makespan κ³μ° ν¬ν¨
Inference Parameters
μ΄ λͺ¨λΈμ λ€μ νλΌλ―Έν°λ€λ‘ μ΅μ νλμμ΅λλ€:
max_seq_length=40000: 볡μ‘ν JSSP λ¬Έμ μ²λ¦¬temperature=1.0: λ€μν μ루μ μμ±top_k=50,top_p=0.95: κ· νμ‘ν νμ
Files Structure
HYUNJINI/jssp_llama8b_accord_r64_ep4/
βββ adapter_config.json # LoRA μ€μ
βββ adapter_model.safetensors # νμ΅λ LoRA κ°μ€μΉ
βββ tokenizer.json # ν ν¬λμ΄μ
βββ tokenizer_config.json # ν ν¬λμ΄μ μ€μ
βββ README.md # μ΄ νμΌ
Citation
@misc{jssp_llama8b_2024,
title={JSSP LLaMA 8B Fine-tuned Model},
author={HYUNJINI},
year={2024},
note={Fine-tuned on ACCORD dataset for Job Shop Scheduling}
}
License
Apache 2.0 License
Model tree for HYUNJINI/jssp_llama8b_accord_r64_ep4
Base model
meta-llama/Llama-3.1-8B
Finetuned
meta-llama/Llama-3.1-8B-Instruct