caption-space / README.md
sciencellama's picture
caption-space: deploy README.md
ba42c46 verified
|
Raw
History Blame Contribute Delete
1.7 kB

A newer version of the Gradio SDK is available: 6.20.0

Upgrade
metadata
title: Caption Space
emoji: 🎨
colorFrom: indigo
colorTo: gray
sdk: gradio
sdk_version: 5.0.0
app_file: app.py
pinned: false
hardware: zero-a10g

Caption Space — LLaVA-1.5-7B

Vision-language descriptions of inspiration images for the La Compagnie d'Intérieur pipeline.

What it does

Takes one or more inspiration images (mood boards / Pinterest references) and returns a natural-language interior-design description: style/era, color palette, materials, key furniture, patterns, vibe.

The main pipeline uses this output as a starting point for the style prompt that drives FAISS retrieval — the user reads the description, edits it ("but with more orange tones"), then submits the redesign job with the edited prompt.

API contract

api_name="/describe"

Input Type Notes
images_b64 str Single base64 image OR JSON-array string of base64 images
instruction str Optional override; empty string = use the default design prompt

Returns {"description": "<prose>"}.

Multi-image inputs

LLaVA-1.5 takes one image per call. For N inspiration images, the Space calls the model N times and joins the outputs with " Also: ". The user can then edit the merged result manually. (Future: swap to LLaVA-OneVision / Qwen2-VL for native multi-image, when revenue justifies the larger model and slower cold-start.)

Why LLaVA-1.5-7B

  • Strong style-vocabulary captioning out of the box
  • Open-source, no commercial licensing required
  • Mature transformers integration
  • ~14 GB at fp16 → fits ZeroGPU A10G with room to spare
  • Faster cold-start than larger alternatives (LLaVA-NeXT, Qwen2-VL-7B)