Spaces:
Runtime error
Runtime error
import os | |
# Folder | |
HISTORY_DIR = "history" | |
SAVE_DIR = "documents" | |
if not os.path.exists(HISTORY_DIR): | |
os.makedirs(HISTORY_DIR) | |
if not os.path.exists(SAVE_DIR): | |
os.makedirs(SAVE_DIR) | |
# Whisper API | |
API_KEY = "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" | |
MODEL_ID = "whisper-1" | |
# Azure endpoint | |
OPENAI_API_TYPE = "azure" | |
OPENAI_API_VERSION = "2023-05-15" | |
# Embedding openai | |
EMBEDDING_API_KEY = "e672d672cf2d4c778e352e2f88271ebc" | |
EMBEDDING_API_BASE = "https://qaigpt2.openai.azure.com/" | |
EMBEDDING_DEPLOYMENT_ID = "embed" | |
# ChatGPT | |
OPENAI_API_KEY = "1941ec6a33bd405bac7f2f800b10d171" | |
OPENAI_API_BASE ="https://qaigptjp.openai.azure.com/" | |
DEPLOYMENT_ID = "gpt" | |
# Pinecone vector DB | |
PINECONE_API_KEY = "82b9902a-2908-4ece-88bf-483c413a91d7" | |
PINECONE_ENVIRONMENT = "us-west1-gcp-free" | |
INDEX_NAME = "text-indexing" | |
# Google search API | |
GOOGLE_API_KEY="AIzaSyBcwB4YIqjDcYr5XnPt5IrktqbH4Mb_1hE" | |
GOOGLE_CSE_ID="e61c62a86e2b848fd" | |
# Custom google search API | |
CUSTOM_API_KEY = "AIzaSyDycFFOFtPg123bm9N3BRCy_q5gyEk7fzs" | |
CUSTOM_CSE_ID = "3364dacc2a4144b22" | |
# Local host | |
TIMEOUT_STREAM = 60 | |
SEVER = "0.0.0.0" | |
PORT = 7860 | |
DEBUG = True | |