|
--- |
|
license: apache-2.0 |
|
language: |
|
- zh |
|
- ja |
|
pipeline_tag: text-generation |
|
--- |
|
|
|
# Sakura-13B-Galgame |
|
|
|
# 介绍 |
|
|
|
基于LLaMA2-13B和OpenBuddy构建,在Galgame中日文本数据上进行微调. |
|
|
|
# 模型详情 |
|
|
|
## 描述 |
|
|
|
- Finetuned by [SakuraUmi](https://github.com/pipixia244) |
|
- Finetuned on [openbuddy-llama2-13b](https://huggingface.co./OpenBuddy/openbuddy-llama2-13b-v8.1-fp16) |
|
- Base model: [Llama2-13B](https://huggingface.co./meta-llama/Llama-2-13b-chat-hf) |
|
- Languages: Chinese/Japanese |
|
|
|
## 基本参数 |
|
|
|
数据集:约260k Galgame中日文本 |
|
|
|
微调epoch数:2 |
|
|
|
参数量:13B |
|
|
|
## 效果 |
|
|
|
| 日文原文 | 中文翻译 | |
|
| ---- | ---- | |
|
| 「女の子の一人暮らしって、やっぱ一階は防范的に危ないのかな~? お父さんには、一階はやめとけ~って言われててね?」 | 「一个女孩子住在一楼,还是有点不太安全吧?爸爸说让我不要住在一楼」 | |
|
| 「助けて、誰か助けてって思いながら、ただただ泣いてたんです……」 | 「我一边祈祷着,祈祷着有人能来救救我们,一边不停地哭泣……」| |
|
| 「そうだよ。これが太一の普通の顔だって。でも、ちょっと不気味だから、わたしみたいにニッコリ笑ってみて?」 | 「是啊。这就是太一的普通表情。但是,因为有点吓人,所以你也试着像我一样微笑一下吧?」 | |
|
| 「そういうヒトの感情は、発情期を迎えてもいないネコには難しい」 | 「这种人类的感情,对还没有迎来发情期的猫来说太难懂了」 | |
|
| 「朝になって、病院に行くまで。ずっと、ずーっとそばに居てくれて……」 | 「一直陪我到早上去医院。一直,一直陪在我身边……」 | |
|
| 「それ以外は、自由に過ごしているため、各自が好きにできる、とても平和な部活だった……。」 | 「除此之外,社团活动都是自由参加的,每个人都可以按自己的意愿去做自己想做的事情,所以社团活动也是非常和平的……」 | |
|
| 「そーだそーだ。せっかくお店休みにして遊びに来たのに」 | 「是啊是啊,难得休息一天,我还想出来玩一下呢」| |
|
| この世界に生まれた存在という束縛からさえ解放された | 甚至从生于这个世界这个束缚中得到了解放 | |
|
|
|
# 推理 |
|
|
|
- Galgame翻译的prompt构建: |
|
|
|
```python |
|
input_text = "" # 用户输入 |
|
query = "将下面的日文文本翻译成中文:" + input_text |
|
prompt = "Human: \n" + query + "\n\nAssistant: \n" |
|
``` |
|
|
|
- 推理参数: |
|
|
|
| 参数 | 值 | |
|
| ---- | ---- | |
|
| beams number | 2 | |
|
| repetition penalty | 1 | |
|
| max new token | 512 | |
|
| min new token | 1 | |
|
|
|
其余推理流程与LLaMA2一致 |
|
|
|
# 微调 |
|
|
|
流程与LLaMA2一致,prompt构造参考推理部分 |
|
|
|
# 后续工作 |
|
|
|
1. 优化数据集,包括提高数据集质量和增加数据数量 |
|
2. 支持上下文理解 |
|
3. 支持指定专有名词 |
|
|
|
# Copyright Notice |
|
|
|
This model is built upon Meta's LLaMA series of models and is subject to Meta's licensing agreement. |
|
|
|
This model is intended for use only by individuals who have obtained approval from Meta and are eligible to download LLaMA. |
|
|
|
If you have not obtained approval from Meta, you must visit the https://ai.meta.com/llama/ page, read and agree to the model's licensing agreement, submit an application, and wait for approval from Meta before downloading the model from this page. |