Update README.md
Browse files
README.md
CHANGED
@@ -1,22 +1,100 @@
|
|
1 |
---
|
2 |
base_model: cyberagent/calm3-22b-chat
|
3 |
language:
|
4 |
-
-
|
5 |
-
license:
|
6 |
tags:
|
7 |
- text-generation-inference
|
8 |
- transformers
|
9 |
- unsloth
|
10 |
- llama
|
11 |
- trl
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
12 |
---
|
13 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
14 |
# Uploaded model
|
15 |
|
16 |
- **Developed by:** Aratako
|
17 |
-
- **License:**
|
18 |
- **Finetuned from model :** cyberagent/calm3-22b-chat
|
19 |
|
20 |
This llama model was trained 2x faster with [Unsloth](https://github.com/unslothai/unsloth) and Huggingface's TRL library.
|
21 |
|
22 |
-
[<img src="https://raw.githubusercontent.com/unslothai/unsloth/main/images/unsloth%20made%20with%20love.png" width="200"/>](https://github.com/unslothai/unsloth)
|
|
|
1 |
---
|
2 |
base_model: cyberagent/calm3-22b-chat
|
3 |
language:
|
4 |
+
- ja
|
5 |
+
license: cc-by-nc-sa-4.0
|
6 |
tags:
|
7 |
- text-generation-inference
|
8 |
- transformers
|
9 |
- unsloth
|
10 |
- llama
|
11 |
- trl
|
12 |
+
datasets:
|
13 |
+
- Aratako/Synthetic-Japanese-Roleplay-NSFW-Claude-3.5s-10.5k-formatted
|
14 |
+
- Aratako/Synthetic-Japanese-Roleplay-gpt-4o-mini-19.8k-formatted
|
15 |
+
- Aratako/Rosebleu-1on1-Dialogues-RP
|
16 |
+
- SicariusSicariiStuff/Bluemoon_Top50MB_Sorted_Fixed
|
17 |
+
- grimulkan/LimaRP-augmented
|
18 |
+
- MinervaAI/Aesir-Preview
|
19 |
+
- openerotica/freedom-rp
|
20 |
+
- openerotica/lima-nsfw
|
21 |
+
- Chaser-cz/roleplay_scripts
|
22 |
+
- roleplay4fun/aesir-v1.1
|
23 |
---
|
24 |
|
25 |
+
# calm3-22b-RP-v0.1
|
26 |
+
[cyberagent/calm3-22b-chat](https://huggingface.co/cyberagent/calm3-22b-chat)をベースにロールプレイ用にQLoRAでファインチューニングしたモデルです。
|
27 |
+
|
28 |
+
[Aratako/calm3-22b-RP](https://huggingface.co/Aratako/calm3-22b-RP)の素材となるモデルとして利用しています。
|
29 |
+
|
30 |
+
# プロンプトフォーマット
|
31 |
+
元モデルから変更なく、ChatMLのフォーマットでご利用ください。以下は2ターン目の会話を行う際の形式です。
|
32 |
+
```
|
33 |
+
<|im_start|>system
|
34 |
+
{ロールプレイの指示、世界観・あらすじの説明、キャラの設定など}<|im_end|>
|
35 |
+
<|im_start|>user
|
36 |
+
{userの1ターン目の入力}<|im_end|>
|
37 |
+
<|im_start|>assistant
|
38 |
+
{assistantの1ターン目の応答}<|im_end|>
|
39 |
+
<|im_start|>user
|
40 |
+
{userの2ターン目の入力}<|im_end|>
|
41 |
+
<|im_start|>assistant
|
42 |
+
```
|
43 |
+
|
44 |
+
また、`tokenizer.apply_chat_template()`を使って自動で成形することも可能です。
|
45 |
+
|
46 |
+
```
|
47 |
+
tokenizer = AutoTokenizer.from_pretrained("Aratako/calm3-22b-RP-v0.1")
|
48 |
+
|
49 |
+
messages = [
|
50 |
+
{"role": "system", "content": "{ロールプレイの指示、世界観・あらすじの説明、キャラの設定など}"},
|
51 |
+
{"role": "user", "content": "{userの1ターン目の入力}"},
|
52 |
+
{"role": "assistant", "content": "{assistantの1ターン目の入力}"},
|
53 |
+
{"role": "user", "content": "{userの2ターン目の入力}"}
|
54 |
+
]
|
55 |
+
|
56 |
+
prompt = tokenizer.apply_chat_template(messages, add_generation_prompt=True, tokenize=False)
|
57 |
+
```
|
58 |
+
|
59 |
+
# 学習データセット
|
60 |
+
本モデルの学習には以下のデータセットを利用しています。
|
61 |
+
|
62 |
+
### 日本語データセット
|
63 |
+
- [Aratako/Rosebleu-1on1-Dialogues-RP](https://huggingface.co/datasets/Aratako/Rosebleu-1on1-Dialogues-RP)
|
64 |
+
- [Aratako/Synthetic-Japanese-Roleplay-NSFW-Claude-3.5s-10.5k-formatted](https://huggingface.co/datasets/Aratako/Synthetic-Japanese-Roleplay-NSFW-Claude-3.5s-10.5k-formatted)
|
65 |
+
- [Aratako/Synthetic-Japanese-Roleplay-gpt-4o-mini-19.8k-formatted](https://huggingface.co/datasets/Aratako/Synthetic-Japanese-Roleplay-gpt-4o-mini-19.8k-formatted)
|
66 |
+
### 英語データセット
|
67 |
+
- [grimulkan/LimaRP-augmented](https://huggingface.co/datasets/grimulkan/LimaRP-augmented)
|
68 |
+
- [SicariusSicariiStuff/Bluemoon_Top50MB_Sorted_Fixed](https://huggingface.co/datasets/SicariusSicariiStuff/Bluemoon_Top50MB_Sorted_Fixed)
|
69 |
+
- [MinervaAI/Aesir-Preview](https://huggingface.co/datasets/MinervaAI/Aesir-Preview)
|
70 |
+
- [openerotica/freedom-rp](https://huggingface.co/datasets/openerotica/freedom-rp)
|
71 |
+
- [openerotica/lima-nsfw](https://huggingface.co/datasets/openerotica/lima-nsfw)
|
72 |
+
- [Chaser-cz/roleplay_scripts](https://huggingface.co/datasets/Chaser-cz/roleplay_scripts)
|
73 |
+
- [roleplay4fun/aesir-v1.1](https://huggingface.co/datasets/roleplay4fun/aesir-v1.1)
|
74 |
+
|
75 |
+
## 学習の設定
|
76 |
+
UnslothのQLoRAを用い、Runpod上のA10一枚で学習を行いました。主な学習パラメータは以下の通りです。
|
77 |
+
- lora_r: 128
|
78 |
+
- lisa_alpha: 256
|
79 |
+
- lora_dropout: 0
|
80 |
+
- lora_target_modules: ["q_proj", "k_proj", "v_proj", "o_proj", "gate_proj", "up_proj", "down_proj"]
|
81 |
+
- learning_rate: 5e-5
|
82 |
+
- num_train_epochs: 1
|
83 |
+
- batch_size: 64
|
84 |
+
- max_seq_length: 8192
|
85 |
+
- weight_decay: 0.01
|
86 |
+
- warmup_ratio: 0.05
|
87 |
+
|
88 |
+
# ライセンス
|
89 |
+
本モデルの学習データにはOpenAI社のGPT-4o-miniの出力やAnthropic社のClaude 3.5 Sonnetの出力が含まれるため、これらの競合となるサービスには本モデルは利用できません。
|
90 |
+
そのため、本モデルは[CC-BY-NC-SA 4.0](https://creativecommons.org/licenses/by-nc-sa/4.0/deed.ja)の元配布します。
|
91 |
+
|
92 |
# Uploaded model
|
93 |
|
94 |
- **Developed by:** Aratako
|
95 |
+
- **License:** cc-by-nc-sa-4.0
|
96 |
- **Finetuned from model :** cyberagent/calm3-22b-chat
|
97 |
|
98 |
This llama model was trained 2x faster with [Unsloth](https://github.com/unslothai/unsloth) and Huggingface's TRL library.
|
99 |
|
100 |
+
[<img src="https://raw.githubusercontent.com/unslothai/unsloth/main/images/unsloth%20made%20with%20love.png" width="200"/>](https://github.com/unslothai/unsloth)
|