Two bugs surfaced by the first dev smoke test: 1. Profile JSON declared "llm": "gemini" (lowercase). llm_config's dispatcher compares model_name == "Gemini" case-sensitively (matches the rest of the codebase), so the check fell through to "Invalid model selected" and never reached the API. Every other profile uses "Gemini" with capital G. Spec mistake — fixed. 2. get_client_from_profile() resolves the per-report output folder from the profile_id via hardcoded prefix matches. No 'hp_' branch existed, so hp_copy_review reports landed under output-dev/general/ instead of output-dev/hp/ — the UI then couldn't find them. Added 'hp_' → 'hp' alongside the existing mappings. The check itself works correctly otherwise: profile_source was user_selected, brand resolved to 'hp', and the reference asset was successfully attached. Bug 1 just prevented Gemini from being called. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| amazon_static.json | ||
| axa_accessibility.json | ||
| axa_policy_document.json | ||
| axa_policy_document_diff.json | ||
| boots_ppack.json | ||
| boots_static.json | ||
| diageo_key_visual.json | ||
| diageo_packaging.json | ||
| general_check.json | ||
| hp_copy_review.json | ||
| inclusive_accessibility.json | ||
| loreal_static.json | ||
| README.md | ||
| static_general.json | ||
| unilever_key_visual.json | ||
| unilever_packaging.json | ||
| video_general.json | ||
Visual AI QC Profiles
This directory contains JSON profile configurations for the Visual AI QC application. Profiles determine which QC checks are run, their weights, and which LLM (OpenAI or Gemini) is used for each check.
Profile Structure
Each profile is defined in its own JSON file with the following structure:
{
"name": "Profile Name",
"description": "Description of the profile and its purpose",
"checks": {
"check_name_1": {
"weight": 0.10,
"llm": "OpenAI",
"enabled": true
},
"check_name_2": {
"weight": 0.15,
"llm": "Gemini",
"enabled": true
}
// Add more checks as needed
}
}
Fields Explanation
name: The display name of the profile (shown in the UI)description: A short description explaining the profile's purposechecks: A dictionary of QC checks to include in this profile- Each check entry contains:
weight: The weight of this check in the overall score (between 0 and 1, sum of all weights should equal 1)llm: The LLM to use for this check ("OpenAI" or "Gemini")enabled: Whether this check is enabled (true/false)
- Each check entry contains:
Adding New Profiles
To add a new profile:
- Create a new JSON file in this directory (e.g.,
my_brand.json) - Define the profile structure following the format above
- Include only the checks relevant to your profile
- Ensure the sum of weights equals 1.0 (100%)
- Restart the application to load the new profile
The profile ID will be the filename without the .json extension. For example, my_brand.json will create a profile with ID my_brand.
Available QC Checks
Here are the available QC checks you can include in your profiles:
Visual Design Checks
logo_visibility: Checks if the logo is clearly visiblebrand_assets_visibility: Checks if brand assets are prominentvisual_elements_count: Counts and evaluates visual elementsbackground_contrast: Evaluates contrast between foreground and backgroundface_visibility: Checks if faces are clearly visiblevisual_hierarchy: Analyzes the visual hierarchysupporting_images: Evaluates supporting imagerycurved_edges: Checks for curved edges in designproduct_visibility: Checks if product is clearly visible
Text & Copy Checks
lowercase_text: Checks text casingcall_to_action: Evaluates call to action textword_count: Checks word countimperative_verb: Checks for imperative verbstext_readability: Evaluates text readability
Layout & Composition Checks
new_visibility: Checks if "NEW" tag is prominently displayedvisuals_left_text_right: Checks layout for visuals on left, text on rightface_gaze_direction: Checks direction of faces gazingelement_alignment: Checks alignment of elementsaspect_ratio: Verifies correct aspect ratioresponsiveness: Tests responsiveness for different screens
Technical Checks
file_naming: Checks file naming conventionslayer_organization: Validates layer organizationcolor_format: Checks color format complianceimage_resolution: Verifies image resolutionsafety_area: Checks safety areas/marginsprint_bleed: Verifies print bleed areascrop_marks: Checks crop marksanimation_transitions: Evaluates animation transitionsdark_mode_legibility: Tests legibility in dark mode
Example Profile
Here's an example profile for a brand that focuses on product visibility and call to action:
{
"name": "Product Marketing",
"description": "Profile optimized for product marketing materials",
"checks": {
"product_visibility": {
"weight": 0.30,
"llm": "OpenAI",
"enabled": true
},
"call_to_action": {
"weight": 0.20,
"llm": "OpenAI",
"enabled": true
},
"brand_assets_visibility": {
"weight": 0.15,
"llm": "OpenAI",
"enabled": true
},
"background_contrast": {
"weight": 0.10,
"llm": "Gemini",
"enabled": true
},
"visual_hierarchy": {
"weight": 0.15,
"llm": "OpenAI",
"enabled": true
},
"image_resolution": {
"weight": 0.10,
"llm": "Gemini",
"enabled": true
}
}
}
Default Profiles
The system includes these default profiles:
default.json- All checks enabled with equal weightingdiageo.json- Diageo brand guidelinesunilever.json- Unilever brand guidelinesgeneral.json- General technical checks