From bfce3af7a5e48cb16645fb43104ede8a9edaddae Mon Sep 17 00:00:00 2001 From: H Lohaus Date: Sun, 28 Apr 2024 22:58:27 +0200 Subject: Update README.md --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) 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) ``` -- cgit v1.2.3