Exporting OpenAI’s API for gpt4free
git clone https://github.com/tgscan-dev/g4f-api
cd g4f-api
poetry install
poetry run python3 main.py
- set
openai.api_base
tohttp://localhost:7001
in your code, e.g.:
openai.api_base = "http://localhost:7001"
Contributions are welcome!