This script uses the Replicate class from the langchain_community.llms module to generate responses to a given prompt. The responses adhere to a specified JSON schema.
- Initialize the virtual environment
python -m venv venv
source venv/bin/activate
- Install the necessary dependencies
pip install -r requirements
- Run the script
python replicate_chain.py
- After running
REPLICATE_API_TOKEN = getpass()
Put in the API token to the top bar in VSCode