Spaces:
Sleeping
Sleeping
Create app.py
Browse files
app.py
ADDED
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import streamlit as st
|
2 |
+
|
3 |
+
from transformers import pipeline
|
4 |
+
|
5 |
+
try:
|
6 |
+
|
7 |
+
messages = [
|
8 |
+
{"role": "user", "content": "Who are you?"},
|
9 |
+
]
|
10 |
+
pipe = pipeline("text-generation", model="deepseek-ai/deepseek-vl2-tiny", trust_remote_code=True)
|
11 |
+
response = pipe(messages)
|
12 |
+
except:
|
13 |
+
response = False
|
14 |
+
if response:
|
15 |
+
st.write('Model imported successfully')
|
16 |
+
print('Done')
|