Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -281,9 +281,11 @@ def analyze_crop_with_gemini(jpeg_b64: str) -> Dict[str, Any]:
|
|
| 281 |
prompt = (
|
| 282 |
"You are an assistant that identifies clothing item characteristics from an image. "
|
| 283 |
"Return only a JSON object with keys: type (single word like 'shoe','top','jacket'), "
|
| 284 |
-
|
|
|
|
| 285 |
"tags (an array of short single-word tags describing visible attributes, e.g. ['striped','leather','white']). "
|
| 286 |
-
|
|
|
|
| 287 |
)
|
| 288 |
|
| 289 |
contents = [types.Content(role="user", parts=[types.Part.from_text(text=prompt)])]
|
|
|
|
| 281 |
prompt = (
|
| 282 |
"You are an assistant that identifies clothing item characteristics from an image. "
|
| 283 |
"Return only a JSON object with keys: type (single word like 'shoe','top','jacket'), "
|
| 284 |
+
# "summary (a single short sentence, one line), brand (brand name if visible else empty string), "
|
| 285 |
+
"summary (a very detailed sentence, with details like if its collar or round-neck, explain it in good detail), brand (brand name if visible else empty string), "
|
| 286 |
"tags (an array of short single-word tags describing visible attributes, e.g. ['striped','leather','white']). "
|
| 287 |
+
# "Keep values short and concise."
|
| 288 |
+
"Keep values short and concise except in summary which requires expressiveness."
|
| 289 |
)
|
| 290 |
|
| 291 |
contents = [types.Content(role="user", parts=[types.Part.from_text(text=prompt)])]
|