# json-structured-prompting

json-structured-prompting defines a JSON architecture for complex image prompts with multiple subjects, explicit positioning, and variable templates.

- rule · `type=rule` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline · ★ 78316 repo stars
- Author: calesthio
- License: AGPL-3.0 · policy=link-only · description only; the file stays with the author
- Source: https://github.com/calesthio/OpenMontage/tree/HEAD/.agents/skills/flux-best-practices/rules/json-structured-prompting.md
- Updated: 2026-10-24
- Security check: automated, 2026-11-16 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/rules/json-structured-prompting

## What it does

This rule establishes a standard schema for describing visual compositions using structured fields instead of loose sentences. Prompts are separated into isolated blocks: environment parameters, an array of subjects with specific coordinates and actions, artistic medium details, and camera settings such as focal length or lighting angle.

The framework covers multi-entity interactions via assigned identifiers, multi-layered spatial depth, and parameter placeholders for automated asset generation. Each segment maintains dedicated keys for hex color accents and composition balance.

Raw JSON must be flattened into descriptive prose before feeding it into image models, as diffusion pipelines interpret natural descriptive sentences far better than nested syntax.

## Install

### Claude Code (native platform)

**Manually: put the files in place**
- File: `.claude/rules/json-structured-prompting.md` — The paths frontmatter field limits the files

### Codex

**AGENTS.md**
- Codex reads AGENTS.md: paste the rule text there

### Cursor

**Manually: put the files in place**
- File: `.cursor/rules/json-structured-prompting.mdc` — Frontmatter: description, globs, alwaysApply

### GitHub Copilot

**Manually: put the files in place**
- File: `.github/instructions/json-structured-prompting.instructions.md` — The applyTo field sets which files it applies to

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/rules/json-structured-prompting.md`

### Cline

**Manually: put the files in place**
- File: `.clinerules/json-structured-prompting.md`

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/calesthio/OpenMontage/tree/HEAD/.agents/skills/flux-best-practices/rules/json-structured-prompting.md

## When to use it
- organize multi-character scenes with clear spatial positions
- isolate lighting and camera settings from artistic style
- build reusable prompt templates with variable replacement
- separate foreground, midground, and background focus levels

## Example prompts
- Structure a multi-character detective scene using the json-structured-prompting schema
- Create a product photography JSON layout with specific hex color values and lighting
- Convert this scene JSON definition into natural language prose for image generation

## Similar
- [nano-banana-prompt](https://affpapa.org/en/nevibecode/skills/nano-banana-prompt.md) — skill · 290 installs
- [vgl](https://affpapa.org/en/nevibecode/skills/vgl.md) — skill · ★ 76 repo stars
- [video-prompting](https://affpapa.org/en/nevibecode/skills/video-prompting.md) — skill · 753 installs
- [storyboard-prompting](https://affpapa.org/en/nevibecode/skills/storyboard-prompting.md) — skill · 1 install
- [fal-prompting](https://affpapa.org/en/nevibecode/skills/fal-prompting.md) — skill · 683 installs
- [gpt-5-4-prompting](https://affpapa.org/en/nevibecode/skills/gpt-5-4-prompting.md) — skill · 742 installs

From the same set: [calesthio/openmontage](https://affpapa.org/en/nevibecode/by/calesthio/openmontage.md) — 101 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
