Skip to content

ecsplendid/prompt-format-json-vs-text

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Prompt Format Variants Across JSON and Text

This repo compares two prompt formats, structured JSON and natural-language text, across multiple FAL image models while holding the semantic content as closely matched as possible.

Public demo: https://ecsplendid.github.io/prompt-format-json-vs-text/

Current prompt set: v2-semantic-match

What The Repo Contains

  • A generator that submits both prompt formats to each configured FAL model.
  • A local/static viewer that groups results by model and shows JSON vs text side by side.
  • Downloaded local image outputs under web/generated/<model-slug>/<run-id>/.
  • A static manifest at web/data/experiment.json that the GitHub Pages build can serve directly.

Fairness Of The Comparison

The current rerun uses a prompt pair labeled v2-semantic-match. The earlier pilot prompts were directionally similar but not tightly mirrored, so this rerun aligns camera, composition, lighting, grading, typography, and exclusions much more closely. The format is intended to be the main variable.

Models In The Current Experiment

  • fal-ai/nano-banana-2
  • fal-ai/phota
  • fal-ai/flux/schnell
  • fal-ai/z-image/turbo
  • fal-ai/bytedance/seedream/v4.5/text-to-image
  • fal-ai/ideogram/v3
  • fal-ai/imagen4/preview

Current Snapshot Status

  • Nano Banana 2: complete
  • FLUX Schnell: complete
  • Z Image Turbo: complete
  • Seedream v4.5 Text to Image: complete
  • Ideogram V3: complete
  • Imagen 4 Preview: complete
  • Phota: partial on the fair rerun because the provider returned repeated downstream 500 errors for 4 natural-language variations

Local Usage

npm run generate
npm run dev
  • npm run generate expects FAL_KEY in the environment.
  • npm run dev serves the viewer locally with a dynamic /api/experiment endpoint.
  • The static GitHub Pages site serves the committed snapshot from web/data/experiment.json.
  • Rerunning with the same RUN_ID resumes from files already present on disk and only submits missing variation slots.

Optional Env Vars

  • MODELS=fal-ai/nano-banana-2,fal-ai/phota runs a subset of models.
  • RUN_ID=2026-03-27T09-40-17-299Z MODELS=fal-ai/phota npm run generate resumes only missing outputs for a partial run.
  • VARIATION_COUNT=15 changes the number of prompt variations per model.
  • GROUP_CONCURRENCY=5 controls how many jobs each model/prompt group runs in parallel.
  • MAX_VARIATION_ATTEMPTS=5 increases retry depth for flaky providers.

Repo Hygiene

  • No API keys are stored in this repo.
  • .env*, node_modules/, local junk, and archived scratch outputs are ignored.
  • The public snapshot is pinned to the fair rerun 2026-03-27T09-40-17-299Z; superseded scratch reruns are kept out of the public repo.
  • The generator reads FAL_KEY from the environment at runtime.

About

Prompt format variants across JSON and text, compared across multiple FAL image models.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors