This repository contains different examples and use cases showcased in the book Developing Apps with GPT-4 and ChatGPT.
If you are coming from the first edition, you will find that the code has been updated to use a more recent OpenAI Python library version. You will also find additional code examples that are not in this book's first edition. To switch back to the original code, go to this tag. The chapters and numbering of the examples are identical across book editions.
Install the requirements for all the examples with:
pip install -r requirements.txt
Each example contains either a Jupyter notebook, or a Python file that can be run with:
python [example_folder]/run.py
Some examples require some additional setup.
Start Redis with
docker-compose up -d
The Gradio interface is available at the address displayed in the output.
Customize if needed the docker-compose.yml file and start Weaviate with
docker-compose up -d
Alternatively, run:
docker run -p 8080:8080 -p 50051:50051 cr.weaviate.io/semitechnologies/weaviate:1.24.9