Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pinecone API Key Bug Fix #440

Merged
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
[fix]: Added an exception in main.py if pinecone_api_key is not provided
  • Loading branch information
keenborder786 committed Apr 7, 2023
commit b983faa95339843f170258bd06923f6b81c1dc42
3 changes: 2 additions & 1 deletion scripts/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -281,11 +281,12 @@ def parse_arguments():
# Make a constant:
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.
# this is particularly important for indexing and referencing pinecone memory
memory = PineconeMemory()
memory.clear()

print('Using memory of type: ' + memory.__class__.__name__)

# Interaction Loop
Expand Down