Instructions to use fieldvalley-llm2025/llm2025_main_merged_dpo03 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Local Apps Settings
- Unsloth Studio
How to use fieldvalley-llm2025/llm2025_main_merged_dpo03 with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for fieldvalley-llm2025/llm2025_main_merged_dpo03 to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for fieldvalley-llm2025/llm2025_main_merged_dpo03 to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for fieldvalley-llm2025/llm2025_main_merged_dpo03 to start chatting
Load model with FastModel
pip install unsloth from unsloth import FastModel model, tokenizer = FastModel.from_pretrained( model_name="fieldvalley-llm2025/llm2025_main_merged_dpo03", max_seq_length=2048, )
2025最終課題メインコンペ Submission (DPO Round 3)
本モデルは、2025年最終課題メインコンペティションへの提出用モデルです。
ベースモデル Qwen/Qwen2.5-7B-Instruct に対し、SFTおよび3段階のDPO(Direct Preference Optimization)を適用して調整されています。
特に最終段階(Round 3)では、JSON形式の厳格な出力(コードブロックや説明文の排除)に特化して学習を行いました。
Model Details
- Base Model: Qwen/Qwen2.5-7B-Instruct
- Fine-tuning Method: Unsloth (LoRA) + DPO
- Total Training Steps (Round 3): 100 (Fixed)
- Learning Rate: 1e-7
Training Process
1. SFT (Supervised Fine-Tuning)
- データセット:
daichira/structured-hard-sft-4k(High Quality) +u-10bei/structured_data_with_cot_dataset_512_v4 - 目的: 指示追従能力と基本的なフォーマット厳守(JSON/XML/TOML/YAML/CSV)の学習。
- 特徴: Completion-only学習により、回答部分のみを効率的に学習。
2. DPO Round 1 & 2
- 目的: 一般的な選好学習およびハルシネーションの抑制。
3. DPO Round 3 (This Model)
- 目的: JSONタスクにおける「余計な出力(Markdownフェンス、Here is...等の前置き)」の完全排除。
- データセット:
u-10bei/dpo-dataset-qwen-cot(JSONタスク抽出) - 戦略:
- Ultra-Aggressive Augmentation: 1つのChosen(正解)に対し、以下の8種類のRejected(不正解)を生成して対比学習。
- コードフェンスあり (
json ...) - 言語指定なしフェンス (
...) - 前置きあり ("Here is the JSON...")
- 後書きあり ("Notes: ...")
- Markdown見出しあり ("### Output")
- コードフェンスあり (
- Strict Filtering:
{で始まり}で終わる純粋なJSON以外は学習データから除外。 - Minimal Steps: 既に能力の高いモデルに対し、出力形式のみを矯正するため 100ステップのみ学習。
- Ultra-Aggressive Augmentation: 1つのChosen(正解)に対し、以下の8種類のRejected(不正解)を生成して対比学習。
Usage
from unsloth import FastLanguageModel
model, tokenizer = FastLanguageModel.from_pretrained(
model_name = "YOUR_USERNAME/dpo-qwen-round3-final", # Replace with your repo id
max_seq_length = 2048,
dtype = None,
load_in_4bit = True,
)
FastLanguageModel.for_inference(model)
prompt = "以下のデータをJSON形式に変換してください..."
inputs = tokenizer([prompt], return_tensors = "pt").to("cuda")
outputs = model.generate(**inputs, max_new_tokens = 512, use_cache = True)
print(tokenizer.batch_decode(outputs))
Acknowledgements
- Base Model: Qwen Team
- Library: Unsloth, TRL
- Dataset: u-10bei, daichira
- Downloads last month
- 2
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support