Definition
A JSON prompt uses structured JSON data instead of free-form text to instruct an AI model. Each field acts as a contract — defining input, constraints, and the exact output schema. JSON prompts produce deterministic shape across runs, which is critical for production AI workflows that ingest model output into databases, APIs, or pipelines. Studies show 83% reduction in 'try again' attempts when using JSON prompts for structured tasks.
Example
{ 'task': 'extract_entities', 'input': '...email text...', 'output_schema': { 'name': 'string', 'company': 'string', 'topic': 'string' } }
When to use
Production AI, structured extraction, classification, multi-shot character consistency. Skip for creative or exploratory work.
Also known as
json prompting, structured prompt