Files
Qwen3-4B-Thinking-2507-reas…/README.md
ModelHub XC be0b2c1fd6 初始化项目,由ModelHub XC社区提供模型
Model: OsakanaTeishoku/Qwen3-4B-Thinking-2507-reasoning-ja-20260329
Source: Original Platform
2026-04-12 00:53:01 +08:00

58 lines
1.6 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
base_model: unsloth/Qwen3-4B-Thinking-2507
tags:
- text-generation-inference
- transformers
- unsloth
- qwen3
license: apache-2.0
language:
- en
- ja
datasets:
- DataPilot/Knowledge-QA-SingleTurn-Dataset
---
# 概要
DataPilot/Knowledge-QA-SingleTurn-DatasetでSFTし日本語の入力に対し日本語で思考するようにしたモデルですコンテキスト長は16384です
# 使い方
```python
from transformers import AutoTokenizer, AutoModelForCausalLM, TextStreamer
tokenizer = AutoTokenizer.from_pretrained("OsakanaTeishoku/Qwen3-4B-Thinking-2507-reasoning-ja-20260329")
model = AutoModelForCausalLM.from_pretrained("OsakanaTeishoku/Qwen3-4B-Thinking-2507-reasoning-ja-20260329", dtype="auto", device_map="auto")
messages = [
{"role": "user", "content": "肉じゃがの作り方を教えて"},
]
inputs = tokenizer.apply_chat_template(
messages,
add_generation_prompt=True,
tokenize=True,
return_dict=True,
return_tensors="pt",
).to(model.device)
streamer = TextStreamer(tokenizer, skip_prompt=True, skip_special_tokens=True)
outputs = model.generate(
**inputs,
max_new_tokens=5000,
do_sample=True,
temperature=0.7,
top_p=0.8,
top_k=20,
streamer=streamer,
)
```
# Uploaded finetuned model
- **Developed by:** OsakanaTeishoku
- **License:** apache-2.0
- **Finetuned from model :** unsloth/Qwen3-4B-Thinking-2507
This qwen3 model was trained 2x faster with [Unsloth](https://github.com/unslothai/unsloth) and Huggingface's TRL library.
[<img src="https://raw.githubusercontent.com/unslothai/unsloth/main/images/unsloth%20made%20with%20love.png" width="200"/>](https://github.com/unslothai/unsloth)