Spaces:
Running
Running
LordFarquaad42
commited on
Commit
·
24aab2e
1
Parent(s):
5cb3e42
app.py now reflects new chroma class
Browse files
app.py
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
import streamlit as st
|
2 |
from openai import OpenAI
|
3 |
from params import params
|
4 |
-
from
|
5 |
|
6 |
# from add_data import start_troggin_off, create_client
|
7 |
|
8 |
-
CLIENT =
|
9 |
APP_NAME: str = "Groove-GPT"
|
10 |
history = []
|
11 |
st.set_page_config(layout="wide")
|
@@ -50,8 +50,8 @@ with l_col:
|
|
50 |
openai_client = OpenAI(api_key=access_key)
|
51 |
|
52 |
with st.spinner("Loading..."):
|
53 |
-
|
54 |
-
results =
|
55 |
query_texts=[user_question],
|
56 |
n_results=num_samples,
|
57 |
include=["documents"],
|
|
|
1 |
import streamlit as st
|
2 |
from openai import OpenAI
|
3 |
from params import params
|
4 |
+
from Chroma import Chroma
|
5 |
|
6 |
# from add_data import start_troggin_off, create_client
|
7 |
|
8 |
+
CLIENT = Chroma()
|
9 |
APP_NAME: str = "Groove-GPT"
|
10 |
history = []
|
11 |
st.set_page_config(layout="wide")
|
|
|
50 |
openai_client = OpenAI(api_key=access_key)
|
51 |
|
52 |
with st.spinner("Loading..."):
|
53 |
+
collection = CLIENT.get_collection()
|
54 |
+
results = collection.query(
|
55 |
query_texts=[user_question],
|
56 |
n_results=num_samples,
|
57 |
include=["documents"],
|