Structured JSON Output
GPT-4o is highly reliable at structured JSON output when given an exact schema. Adding confidence scores and source text spans makes the extraction auditable. The 'never fabricate' rule with null fallback prevents hallucinated data in extraction tasks.
Extract structured data from the following {{inputType}}: <input> {{inputContent}} </input> **Output as JSON matching this exact schema:** \`\`\`json {{jsonSchema}} \`\`\` **Extraction rules:** - If a field is not found in the input, use null (never fabricate data) - For {{ambiguousField}}: {{disambiguationRule}} - Normalize {{fieldsToNormalize}} to {{normalizationFormat}} - If multiple values exist for a single field, return as array **Validation:** - {{validationRules}} - Include a "_confidence" field (0.0-1.0) for each extracted value - Include a "_source" field with the exact text span used for extraction Return ONLY the JSON object. No markdown, no explanation.
Variables to customize
Why this prompt works
GPT-4o is highly reliable at structured JSON output when given an exact schema. Adding confidence scores and source text spans makes the extraction auditable. The 'never fabricate' rule with null fallback prevents hallucinated data in extraction tasks.
What you get when you save this prompt
Your workspace unlocks powerful tools to iterate and improve.
AI Optimization
One-click improvement with structure analysis and pattern suggestions.
Version History
Track every edit. Compare versions side-by-side with word-level diffs.
Folders & Tags
Organize your library with nested folders, tags, and drag-and-drop.
$ npm i -g @promptingbox/mcpUse Everywhere
Access prompts from Claude, Cursor, ChatGPT & more via MCP integration.
Your prompts, organized
Save, version, and access your best prompts across ChatGPT, Claude, Cursor, and more.