User Setup Guide#
Installation#
pip install languageassistant
Configure API keys#
There are two environment variables that must be configured for LanguageAssistant to fully work. For development, you may choose to just use a .env file with python-dotenv.
If you have cloned the repo for developing LanguageAssistant, it already uses the Poetry dotenv plugin to use a local .env file.
Necessary environment variables:
OPENAI_API_KEY: OpenAI’s API key to use for Whisper audio transcriptionGOOGLE_API_KEY: Google’s Text-to-Speech API key
OpenAI#
Login or create an new OpenAI account
Click the
Create new secret keybuttonCopy that API key and export the
OPENAI_API_KEYenvironment variable with the API key as its value
Google Cloud#
Setting up Google Cloud takes a bit more work of navigating menus.
Login to Google at https://console.cloud.google.com/
Click
Select a projectCreate a new project
Select the newly created project as your active project
Enable the Cloud Text-to-Speech API
Return to the console and click
CredentialsClick
Create Credentials->API KeyCopy and export the
GOOGLE_API_KEYenvironment variable with the API key as its value
Run the assistant#
Download the demo from the GitHub repository.
python main.py