Spaces:
Runtime error
Runtime error
Test changing model to Quen2.5
Browse files
app.py
CHANGED
|
@@ -2,14 +2,19 @@ import streamlit as st
|
|
| 2 |
from transformers import pipeline
|
| 3 |
#from datasets import load_dataset
|
| 4 |
|
| 5 |
-
qa_pipeline = pipeline("question-answering", model="microsoft/Phi-3-mini-4k-instruct")
|
| 6 |
#qa_pipeline = pipeline("question-answering")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 7 |
st.title("Adrega AI Help")
|
| 8 |
#dataset = load_dataset("andreska/adregadocs", split="test")
|
| 9 |
context = "Adrega is a very cool company, that implements AI" #dataset[0]["text"]
|
| 10 |
|
| 11 |
-
|
| 12 |
-
|
| 13 |
user_input = st.text_input('Ask me a question')
|
| 14 |
if st.button("Submit"):
|
| 15 |
if user_input:
|
|
|
|
| 2 |
from transformers import pipeline
|
| 3 |
#from datasets import load_dataset
|
| 4 |
|
| 5 |
+
#qa_pipeline = pipeline("question-answering", model="microsoft/Phi-3-mini-4k-instruct")
|
| 6 |
#qa_pipeline = pipeline("question-answering")
|
| 7 |
+
|
| 8 |
+
messages = [
|
| 9 |
+
{"role": "user", "content": "Who are you?"},
|
| 10 |
+
]
|
| 11 |
+
pipe = pipeline("text-generation", model="Qwen/Qwen2.5-Coder-32B-Instruct")
|
| 12 |
+
#pipe(messages)
|
| 13 |
+
|
| 14 |
st.title("Adrega AI Help")
|
| 15 |
#dataset = load_dataset("andreska/adregadocs", split="test")
|
| 16 |
context = "Adrega is a very cool company, that implements AI" #dataset[0]["text"]
|
| 17 |
|
|
|
|
|
|
|
| 18 |
user_input = st.text_input('Ask me a question')
|
| 19 |
if st.button("Submit"):
|
| 20 |
if user_input:
|