Module: ImageGeneration::BrandStyleGuide
- Defined in:
- app/services/image_generation/brand_style_guide.rb
Overview
WarmlyYours brand helpers for the AI image generator.
Brand narrative lives in the AssistantBrainEntry titled
"WarmlyYours Brand Style Guide" — edit it there to update
the prompt snippet shown in the generator and injected into Sunny.
Color/typeface constants are kept here only for UI rendering (swatches).
Constant Summary collapse
- BRAIN_ENTRY_TITLE =
Brain entry title.
'WarmlyYours Brand Style Guide'- PRIMARY_COLOR =
Primary color.
'#CC2229'- SECONDARY_COLOR =
Secondary color.
'#333333'- WHITE_COLOR =
White color.
'#FFFFFF'- TYPEFACE =
Typeface.
'Sofia Pro'
Class Method Summary collapse
-
.logo_images ⇒ Object
Returns active images tagged 'brand-reference', ordered by id.
-
.prompt_snippet ⇒ Object
The brand style text users can append to prompts.
Class Method Details
.logo_images ⇒ Object
Returns active images tagged 'brand-reference', ordered by id.
36 37 38 |
# File 'app/services/image_generation/brand_style_guide.rb', line 36 def self.logo_images Image.tagged_with('brand-reference').where(inactive: false).order(:id) end |
.prompt_snippet ⇒ Object
The brand style text users can append to prompts.
Reads from the brain entry so there is one source of truth.
Falls back to a minimal inline string if the entry is missing.
27 28 29 30 31 32 33 |
# File 'app/services/image_generation/brand_style_guide.rb', line 27 def self.prompt_snippet AssistantBrainEntry .active .find_by(title: BRAIN_ENTRY_TITLE) &.rule .presence || 'WarmlyYours brand: primary red #CC2229, dark gray #333333, typeface Sofia Pro.' end |