Skip to content

Fix the incorrect string formatting and ensure the subcategories variable is embedded in the prompt #1770

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions examples/How_to_combine_GPT4o_with_RAG_Outfit_Assistant.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -331,16 +331,16 @@
" \"content\": [\n",
" {\n",
" \"type\": \"text\",\n",
" \"text\": \"\"\"Given an image of an item of clothing, analyze the item and generate a JSON output with the following fields: \"items\", \"category\", and \"gender\". \n",
" \"text\": f\"\"\"Given an image of an item of clothing, analyze the item and generate a JSON output with the following fields: \"items\", \"category\", and \"gender\".\n",
" Use your understanding of fashion trends, styles, and gender preferences to provide accurate and relevant suggestions for how to complete the outfit.\n",
" The items field should be a list of items that would go well with the item in the picture. Each item should represent a title of an item of clothing that contains the style, color, and gender of the item.\n",
" The category needs to be chosen between the types in this list: {subcategories}.\n",
" You have to choose between the genders in this list: [Men, Women, Boys, Girls, Unisex]\n",
" Do not include the description of the item in the picture. Do not include the ```json ``` tag in the output.\n",
" \n",
"\n",
" Example Input: An image representing a black leather jacket.\n",
"\n",
" Example Output: {\"items\": [\"Fitted White Women's T-shirt\", \"White Canvas Sneakers\", \"Women's Black Skinny Jeans\"], \"category\": \"Jackets\", \"gender\": \"Women\"}\n",
" Example Output: {{\"items\": [\"Fitted White Women's T-shirt\", \"White Canvas Sneakers\", \"Women's Black Skinny Jeans\"], \"category\": \"Jackets\", \"gender\": \"Women\"}}\n",
" \"\"\",\n",
" },\n",
" {\n",
Expand Down