Inspiration

I wanted to explore one idea in Bria FIBO that feels genuinely different from other generative models: translating short natural language into structured JSON. This removes prompt engineering and replaces it with something controllable, predictable and editable. I built Refractions to see how far that idea can go for creating consistent campaign-style imagery from a single product photo.

Refractions takes a brief sentence, turns it into a structured JSON plan, and generates multiple editorial variants from that structure. Each image is paired with its full JSON prompt so users can edit camera, lighting and composition directly. I also added a critique loop where the system reviews the output and rewrites only the relevant JSON fields before regenerating the image.

Challenges

The main challenge was latency. Remote generation was slow enough to block the request cycle, so I moved image generation into a ThreadPoolExecutor and returned job updates asynchronously. This kept the UI responsive and allowed multi-shot generation to feel smooth.

Tech Stack

Backend: Python (FastAPI), Gemini (multi-agent orchestration) Frontend: React + TypeScript (Vite) Image Generation: Bria AI FIBO (JSON-native text-to-image model) Storage: Google Cloud Storage, MongoDB

Built With

Share this project:

Updates