Normal1919
commited on
Commit
•
6245f34
1
Parent(s):
04dbb2b
Update README.md
Browse files
README.md
CHANGED
@@ -6,4 +6,28 @@ language:
|
|
6 |
library_name: transformers
|
7 |
tags:
|
8 |
- translation
|
9 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
6 |
library_name: transformers
|
7 |
tags:
|
8 |
- translation
|
9 |
+
widget:
|
10 |
+
- text: "I am Amy"
|
11 |
+
---
|
12 |
+
# Normal1919/opus-mt-en-zh-lil-fine-tune
|
13 |
+
|
14 |
+
## Model description
|
15 |
+
|
16 |
+
* source group: English
|
17 |
+
* target group: Chinese
|
18 |
+
* model: transformer
|
19 |
+
* source language(s): eng
|
20 |
+
* target language(s): cjy_Hans cjy_Hant cmn cmn_Hans cmn_Hant gan lzh lzh_Hans nan wuu yue yue_Hans yue_Hant
|
21 |
+
## How to use
|
22 |
+
```python
|
23 |
+
>>> from transformers import AutoModelWithLMHead,AutoTokenizer,pipeline
|
24 |
+
>>> mode_name = 'Normal1919/opus-mt-en-zh-lil-fine-tune'
|
25 |
+
>>> model = AutoModelWithLMHead.from_pretrained(mode_name)
|
26 |
+
>>> tokenizer = AutoTokenizer.from_pretrained(mode_name)
|
27 |
+
>>> translation = pipeline("translation_en_to_zh", model=model, tokenizer=tokenizer)
|
28 |
+
>>> translation('I {i}should{/i} say that I feel a little relieved to find out that {i}this{/i} is why you’ve been hanging out with Kaori lately, though. She’s really pretty and I got jealous and...I’m sorry', max_length=400)
|
29 |
+
[{'我{i}应该{/i}说发现{i}这{/i}是你最近和Kaori出去的原因,我有点松了一口气。她很漂亮,我嫉妒,而且......我很抱歉。'}]
|
30 |
+
```
|
31 |
+
## Contact
|
32 |
+
|
33 |
+
517205163@qq.com
|