mirror of
https://github.com/aljazceru/Auto-GPT.git
synced 2025-12-17 22:14:28 +01:00
[fix]: Added an exception in main.py if pinecone_api_key is not provided
This commit is contained in:
@@ -281,11 +281,12 @@ next_action_count = 0
|
|||||||
# Make a constant:
|
# Make a constant:
|
||||||
user_input = "Determine which next command to use, and respond using the format specified above:"
|
user_input = "Determine which next command to use, and respond using the format specified above:"
|
||||||
|
|
||||||
|
# raise an exception if pinecone_api_key or region is not provided
|
||||||
|
if not cfg.pinecone_api_key or not cfg.pinecone_region: raise Exception("Please provide pinecone_api_key and pinecone_region")
|
||||||
# Initialize memory and make sure it is empty.
|
# Initialize memory and make sure it is empty.
|
||||||
# this is particularly important for indexing and referencing pinecone memory
|
# this is particularly important for indexing and referencing pinecone memory
|
||||||
memory = PineconeMemory()
|
memory = PineconeMemory()
|
||||||
memory.clear()
|
memory.clear()
|
||||||
|
|
||||||
print('Using memory of type: ' + memory.__class__.__name__)
|
print('Using memory of type: ' + memory.__class__.__name__)
|
||||||
|
|
||||||
# Interaction Loop
|
# Interaction Loop
|
||||||
|
|||||||
Reference in New Issue
Block a user