diff options
author | Heiner Lohaus <hlohaus@users.noreply.github.com> | 2024-02-12 11:41:27 +0100 |
---|---|---|
committer | Heiner Lohaus <hlohaus@users.noreply.github.com> | 2024-02-12 11:41:27 +0100 |
commit | aba4b96f23ef38ca75195b3b78a88bb92035b4a9 (patch) | |
tree | 92575678f27d48e2258e823fa299ed21af6cbad2 /README.md | |
parent | Improve preview in image generation of Gemini (diff) | |
download | gpt4free-aba4b96f23ef38ca75195b3b78a88bb92035b4a9.tar gpt4free-aba4b96f23ef38ca75195b3b78a88bb92035b4a9.tar.gz gpt4free-aba4b96f23ef38ca75195b3b78a88bb92035b4a9.tar.bz2 gpt4free-aba4b96f23ef38ca75195b3b78a88bb92035b4a9.tar.lz gpt4free-aba4b96f23ef38ca75195b3b78a88bb92035b4a9.tar.xz gpt4free-aba4b96f23ef38ca75195b3b78a88bb92035b4a9.tar.zst gpt4free-aba4b96f23ef38ca75195b3b78a88bb92035b4a9.zip |
Diffstat (limited to '')
-rw-r--r-- | README.md | 17 |
1 files changed, 17 insertions, 0 deletions
@@ -226,6 +226,23 @@ docker-compose down ## 💡 Usage +### New Client with Image Generation +```python +from g4f.client import Client + +client = Client() +response = client.images.generate( + model="gemini", + prompt="a white siamese cat", + ... +) +image_url = response.data[0].url +``` +Result: +[![Image with cat](/docs/cat.jpeg)](/docs/client.md) + +[to the client API](/docs/client.md) + ### The Web UI To start the web interface, type the following codes in the command line. |