Update app.py
Browse files
app.py
CHANGED
@@ -129,7 +129,7 @@ class MultiModelName(str, Enum):
|
|
129 |
async def open_router_multimodal(
|
130 |
token: Annotated[str, Depends(verify_token)],
|
131 |
model: MultiModelName = Query(..., description="Select a model"),
|
132 |
-
prompt: str = Query(..., description="Enter your prompt (ex: What is in this image?"),
|
133 |
image_url: str = Query(..., description="Enter the image URL"),
|
134 |
):
|
135 |
async with httpx.AsyncClient() as client:
|
@@ -170,7 +170,8 @@ async def open_router_multimodal(
|
|
170 |
async def open_router_multimodal_upload(
|
171 |
token: Annotated[str, Depends(verify_token)],
|
172 |
image: UploadFile = File(...),
|
173 |
-
|
|
|
174 |
):
|
175 |
image_bytes = await image.read()
|
176 |
encoded_string = base64.b64encode(image_bytes).decode('utf-8')
|
|
|
129 |
async def open_router_multimodal(
|
130 |
token: Annotated[str, Depends(verify_token)],
|
131 |
model: MultiModelName = Query(..., description="Select a model"),
|
132 |
+
prompt: str = Query(..., description="Enter your prompt (ex: What is in this image?)"),
|
133 |
image_url: str = Query(..., description="Enter the image URL"),
|
134 |
):
|
135 |
async with httpx.AsyncClient() as client:
|
|
|
170 |
async def open_router_multimodal_upload(
|
171 |
token: Annotated[str, Depends(verify_token)],
|
172 |
image: UploadFile = File(...),
|
173 |
+
model: MultiModelName = Query(..., description="Select a model"),
|
174 |
+
prompt: str = Query(..., description="Enter your prompt (ex: What is in this image?)")
|
175 |
):
|
176 |
image_bytes = await image.read()
|
177 |
encoded_string = base64.b64encode(image_bytes).decode('utf-8')
|