Prompt Buddy logoPrompt Buddy

openai · OpenAI Platform Docs

Citation Formatting | OpenAI API

Explains how to implement and format citations within model responses to ensure proper attribution of source material.

Import to Prompt Buddy

Derived skill

Files assembled from official documentation

Viewing SKILL.md

Citation Formatting | OpenAI API

Explains how to implement and format citations within model responses to ensure proper attribution of source material.

When To Use

Use when you need to implement a workflow that requires the model to provide verifiable references or citations for the information it generates from provided context.

Reference Files

FileContainsUse For
SKILL.mdEntry point: scope, routing table, and workflow.Start here.
docs/citation-formatting-openai-api-workflow-guide.mdA guide detailing how to prepare citable material and instruct models to format citations effectively using the OpenAI API.Questions about a guide detailing how to prepare citable material and instruct models to format citations effectively using the OpenA...
examples/citation-formatting-openai-api-openai-api-citation-formatting.textA text file demonstrating the specific syntax for citation markers including start, delimiter, and stop tokens used in the OpenAI API.Exact payloads, commands, or snippets shown in A text file demonstrating the specific syntax for citation markers including start, delimiter, and stop tokens used i...
examples/citation-formatting-openai-api-openai-api-citation-formatting-syntax-tem.textA text template demonstrating the specific syntax and delimiters required for OpenAI API citation formatting.Exact payloads, commands, or snippets shown in A text template demonstrating the specific syntax and delimiters required for OpenAI API citation formatting.
examples/citation-formatting-openai-api-openai-api-citation-formatting-syntax.textA text example demonstrating the specific syntax and delimiters used for citation formatting within the OpenAI API.Exact payloads, commands, or snippets shown in A text example demonstrating the specific syntax and delimiters used for citation formatting within the OpenAI API.
examples/citation-formatting-openai-api-openai-api-citation-formatting-syntax-2.textA text example demonstrating the specific syntax for citation start, delimiter, and stop tokens used in the OpenAI API.Exact payloads, commands, or snippets shown in A text example demonstrating the specific syntax for citation start, delimiter, and stop tokens used in the OpenAI API.
examples/citation-formatting-openai-api-openai-api-citation-formatting-2.textA text example demonstrating how to identify and format source reference IDs like turn2file1 within citation results.Exact payloads, commands, or snippets shown in A text example demonstrating how to identify and format source reference IDs like turn2file1 within citation results.
examples/citation-formatting-openai-api-openai-api-citation-formatting-3.textA text example demonstrating the specific syntax required for citing tool results using the citation marker format.Exact payloads, commands, or snippets shown in A text example demonstrating the specific syntax required for citing tool results using the citation marker format.
examples/citation-formatting-openai-api-openai-api-citation-formatting-guidelines.textA text-based guide outlining principles for relevance, diversity, and trustworthiness when formatting citations in API responses.Exact payloads, commands, or snippets shown in A text-based guide outlining principles for relevance, diversity, and trustworthiness when formatting citations in AP...
examples/citation-formatting-openai-api-openai-api-citation-formatting-python-con.textPython constant definitions for CITATIONSTART, CITATIONDELIMITER, and CITATIONSTOP used in OpenAI API citation formatting.Exact payloads, commands, or snippets shown in Python constant definitions for CITATIONSTART, CITATIONDELIMITER, and CITATIONSTOP used in OpenAI API citation format...
examples/citation-formatting-openai-api-openai-api-citation-formatting-constants.textA text file defining the constant string values for CITATIONSTART, CITATIONDELIMITER, and CITATIONEND used in OpenAI API citation formatting.Exact payloads, commands, or snippets shown in A text file defining the constant string values for CITATIONSTART, CITATIONDELIMITER, and CITATIONEND used in OpenAI...
examples/citation-formatting-openai-api-openai-api-citation-formatting-marker-exa.textText examples demonstrating the specific syntax for citation markers including start, delimiter, and stop tokens.Exact payloads, commands, or snippets shown in Text examples demonstrating the specific syntax for citation markers including start, delimiter, and stop tokens.
examples/citation-formatting-openai-api-openai-api-citation-formatting-marker-exa-2.textText examples demonstrating the specific syntax for citation markers including start, delimiter, and stop tokens.Exact payloads, commands, or snippets shown in Text examples demonstrating the specific syntax for citation markers including start, delimiter, and stop tokens.
examples/citation-formatting-openai-api-openai-api-citation-formatting-4.textA text example demonstrating how to format and identify source reference IDs for citations within the OpenAI API.Exact payloads, commands, or snippets shown in A text example demonstrating how to format and identify source reference IDs for citations within the OpenAI API.
examples/citation-formatting-openai-api-openai-api-citation-formatting-5.textA text example demonstrating the specific syntax and unicode characters used for citation formatting within the OpenAI API.Exact payloads, commands, or snippets shown in A text example demonstrating the specific syntax and unicode characters used for citation formatting within the OpenA...
examples/citation-formatting-openai-api-openai-api-citation-formatting-6.textA text sample demonstrating how to apply citation formatting to a document excerpt.Exact payloads, commands, or snippets shown in A text sample demonstrating how to apply citation formatting to a document excerpt.
examples/citation-formatting-openai-api.textA text example demonstrating how to format citations using citable unit IDs within a prompt.Exact payloads, commands, or snippets shown in A text example demonstrating how to format citations using citable unit IDs within a prompt.
examples/citation-formatting-openai-api-openai-api-citation-formatting-7.textA text example demonstrating the use of special citation tokens within a string for the OpenAI API.Exact payloads, commands, or snippets shown in A text example demonstrating the use of special citation tokens within a string for the OpenAI API.

What This Skill Covers

  • Reliable citations build trust and help readers verify the accuracy of responses. This guide provides practical guidance on how to prepare citable material a...
  • Main sections: Overview, Choose citable units, Represent citable material, Define citation format, Template.

Workflow

  1. Open the most relevant file under docs/ for the exact documented workflow and wording.
  2. Open schemas/ files for exact structured contracts.
  3. Open examples/ files for concrete requests, commands, snippets, and manifests.
  4. Do not add behavior or configuration that is not present in the attached source files.

Canonical source: https://developers.openai.com/api/docs/guides/citation-formatting