Spaces:
Runtime error
Runtime error
LinkangZhan
commited on
Commit
•
a7d37a3
1
Parent(s):
46d73db
test gradio
Browse files
app.py
ADDED
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
from peft import PeftModel, PeftConfig
|
2 |
+
from transformers import AutoModelForCausalLM, AutoTokenizer
|
3 |
+
import gradio as gr
|
4 |
+
|
5 |
+
# config = PeftConfig.from_pretrained("Junity/Genshin-World-Model")
|
6 |
+
# model = AutoModelForCausalLM.from_pretrained("baichuan-inc/Baichuan-13B-Base")
|
7 |
+
# model = PeftModel.from_pretrained(model, "Junity/Genshin-World-Model")
|
8 |
+
# tokenizer = AutoTokenizer.from_pretrained("Junity/Genshin-World-Model")
|
9 |
+
|
10 |
+
with gr.Blocks() as demo:
|
11 |
+
gr.Markdown(
|
12 |
+
"""
|
13 |
+
## Genshin-World-Model
|
14 |
+
- 模型地址 [https://huggingface.co/Junity/Genshin-World-Model](https://huggingface.co/Junity/Genshin-World-Model)
|
15 |
+
- 此模型不支持要求对方回答什么,只支持续写。
|
16 |
+
"""
|
17 |
+
)
|
18 |
+
demo.queue().launch()
|