VeuReu commited on
Commit
d154a5b
·
verified ·
1 Parent(s): bc0102e

Update api_schemas.py

Browse files
Files changed (1) hide show
  1. api_schemas.py +26 -17
api_schemas.py CHANGED
@@ -1,17 +1,26 @@
1
- # api_schemas.py
2
- DESCRIBE_RAW_MULTIPART = {
3
- "method": "POST",
4
- "path": "/api/describe_raw",
5
- "multipart_fields": [
6
- {"name": "image", "type": "file"},
7
- {"name": "text", "type": "text", "default": "Describe la imagen con detalle."},
8
- {"name": "max_new_tokens", "type": "int", "default": 256},
9
- {"name": "temperature", "type": "float", "default": 0.7}
10
- ]
11
- }
12
-
13
- PREDICT_JSON = {
14
- "method": "POST",
15
- "path": "/api/predict/describe",
16
- "json_body": {"data": ["<file or url>", "prompt text", 256, 0.7]}
17
- }
 
 
 
 
 
 
 
 
 
 
1
+ # api_schemas.py
2
+ DESCRIBE_RAW_MULTIPART = {
3
+ "method": "POST",
4
+ "path": "/api/describe_raw",
5
+ "multipart_fields": [
6
+ {"name": "image", "type": "file"},
7
+ {"name": "text", "type": "text", "default": "Describe la imagen con detalle."},
8
+ {"name": "max_new_tokens", "type": "int", "default": 256},
9
+ {"name": "temperature", "type": "float", "default": 0.7}
10
+ ]
11
+ }
12
+
13
+ PREDICT_JSON = {
14
+ "method": "POST",
15
+ "path": "/api/predict/describe",
16
+ "json_body": {"data": ["<file or url>", "prompt text", 256, 0.7]}
17
+ }
18
+
19
+ IMAGE_SIZE_MULTIPART = {
20
+ "method": "POST",
21
+ "path": "/api/image_size",
22
+ "multipart_fields": [
23
+ {"name": "image", "type": "file"}
24
+ ],
25
+ "response": {"data": ["<ancho>x<alto>"]}
26
+ }