Sashkanik13
commited on
Commit
•
6658878
1
Parent(s):
f908e14
Update README.md
Browse files
README.md
CHANGED
@@ -2,4 +2,20 @@
|
|
2 |
language:
|
3 |
- ru
|
4 |
---
|
5 |
-
Модель IlyaGusev/rugpt_large_turbo_instructed в формате ggml
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
language:
|
3 |
- ru
|
4 |
---
|
5 |
+
Модель IlyaGusev/rugpt_large_turbo_instructed в формате ggml
|
6 |
+
|
7 |
+
Код запуска:
|
8 |
+
```
|
9 |
+
from ctransformers import AutoModelForCausalLM
|
10 |
+
|
11 |
+
llm = AutoModelForCausalLM.from_pretrained("Sashkanik13/rugpt3large_turbo_instructed_ggml", model_file="ggml-model.bin", model_type="gpt2")
|
12 |
+
|
13 |
+
while True:
|
14 |
+
user_input = input("\n>>> ")
|
15 |
+
text = "Задание: Ты общительный чатбот. Продолжи диалог. Вопрос: " + user_input + "Ответ:"
|
16 |
+
for text in llm(text, stream=True):
|
17 |
+
if '</s>' in text:
|
18 |
+
break
|
19 |
+
else:
|
20 |
+
print(text, end="", flush=True)
|
21 |
+
```
|