Hamxa1997 commited on
Commit
5f40329
·
verified ·
1 Parent(s): 5d7428b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -31,7 +31,7 @@ embedder = SentenceTransformer('paraphrase-MiniLM-L6-v2')
31
  dataset_embeddings = embedder.encode(train_dataset['question'], convert_to_tensor=True)
32
  index = faiss.IndexFlatL2(dataset_embeddings.shape[1]) # Create an index based on L2 distance
33
  index.add(dataset_embeddings.cpu().numpy()) # Add the embeddings to the index
34
-
35
  # Set up Groq API with direct API key
36
 
37
  client = Groq(api_key=api_key)
 
31
  dataset_embeddings = embedder.encode(train_dataset['question'], convert_to_tensor=True)
32
  index = faiss.IndexFlatL2(dataset_embeddings.shape[1]) # Create an index based on L2 distance
33
  index.add(dataset_embeddings.cpu().numpy()) # Add the embeddings to the index
34
+ api_key = os.getenv("api_key")
35
  # Set up Groq API with direct API key
36
 
37
  client = Groq(api_key=api_key)