summaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
authorH Lohaus <hlohaus@users.noreply.github.com>2024-04-28 22:58:27 +0200
committerGitHub <noreply@github.com>2024-04-28 22:58:27 +0200
commitbfce3af7a5e48cb16645fb43104ede8a9edaddae (patch)
treee4ca3f258abcdf1b573312cd3e8a0b3ae15978e6 /README.md
parentMerge pull request #1908 from KPCOFGS/main (diff)
downloadgpt4free-bfce3af7a5e48cb16645fb43104ede8a9edaddae.tar
gpt4free-bfce3af7a5e48cb16645fb43104ede8a9edaddae.tar.gz
gpt4free-bfce3af7a5e48cb16645fb43104ede8a9edaddae.tar.bz2
gpt4free-bfce3af7a5e48cb16645fb43104ede8a9edaddae.tar.lz
gpt4free-bfce3af7a5e48cb16645fb43104ede8a9edaddae.tar.xz
gpt4free-bfce3af7a5e48cb16645fb43104ede8a9edaddae.tar.zst
gpt4free-bfce3af7a5e48cb16645fb43104ede8a9edaddae.zip
Diffstat (limited to 'README.md')
-rw-r--r--README.md3
1 files changed, 2 insertions, 1 deletions
diff --git a/README.md b/README.md
index 346d0904..14da463f 100644
--- a/README.md
+++ b/README.md
@@ -425,10 +425,11 @@ client = Client(
api_key="...",
provider=GeminiPro
)
+image = requests.get("https://example.jpg", stream=True).raw
response = client.chat.completions.create(
model="gemini-pro-vision",
messages=[{"role": "user", "content": "What are on this image?"}],
- image=open("docs/waterfall.jpeg", "rb")
+ image=image
)
print(response.choices[0].message.content)
```