Spaces:
Configuration error
Configuration error
Create gemini (#5)
Browse files- Create gemini (fd53eb93c34d88be7ae12295f74f424ebae8c1ca)
Co-authored-by: Ben <BenK0y@users.noreply.huggingface.co>
gemini
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import google.generativeai as genai
|
| 2 |
+
import os
|
| 3 |
+
|
| 4 |
+
genai.configure(api_key=os.environ["AIzaSyB5WiEJf_yLMD1dMQf305EAbaPTzF_QD-I"])
|
| 5 |
+
|
| 6 |
+
model = genai.GenerativeModel('gemini-1.5-flash')
|
| 7 |
+
response = model.generate_content(
|
| 8 |
+
text_input="the color of the car is ?",
|
| 9 |
+
image_input="car.jpg"
|
| 10 |
+
)
|
| 11 |
+
print(response.text)
|