# OpenAI Cookbook — Official Prompting Guides > Official prompting guides from OpenAI: GPT-5.2, Codex, Meta Prompting, and Realtime API guides. The definitive reference for OpenAI model optimization. ## Install Paste the prompt below into your AI tool: ## Quick Use Browse the guides at [github.com/openai/openai-cookbook](https://github.com/openai/openai-cookbook) or read online at [cookbook.openai.com](https://cookbook.openai.com). --- ## Intro Official prompting guides and code examples from OpenAI. Covers best practices for every major model: GPT-5.2, GPT-5.1, GPT-5, GPT-4.1, Codex CLI, and specialized guides for meta-prompting, realtime API, and Whisper. The authoritative source for understanding how to get the best results from OpenAI models. **Works with**: GitHub Copilot, OpenAI Codex --- ## Prompting Guides ### GPT-5.2 Prompting Guide Latest model best practices: structured outputs, tool use, chain-of-thought, system prompt design. ### Codex Prompting Guide Optimizing prompts for the Codex CLI agent: code generation, debugging, refactoring, multi-file edits. ### Meta Prompting Guide Using AI to improve your prompts: automated prompt optimization, self-critique patterns, prompt chaining. ### Realtime Prompting Guide Best practices for the Realtime API: voice interactions, streaming responses, latency optimization. ### GPT-4.1 Prompting Guide Instruction following, long context handling, agentic coding patterns. ## Code Examples The cookbook includes runnable Jupyter notebooks for: - Function calling and tool use - Embeddings and semantic search - Fine-tuning workflows - Batch processing - Vision and multimodal - Text-to-speech and speech-to-text --- ### FAQ **Q: What is OpenAI Cookbook?** A: Official prompting guides from OpenAI: GPT-5.2, Codex, Meta Prompting, and Realtime API guides. The definitive reference for OpenAI model optimization. **Q: How do I install OpenAI Cookbook?** A: Check the Quick Use section above for step-by-step installation instructions. Most assets can be set up in under 2 minutes. ## Source & Thanks > Created by [OpenAI](https://github.com/openai). Licensed under MIT. > [openai-cookbook](https://github.com/openai/openai-cookbook) > [cookbook.openai.com](https://cookbook.openai.com) --- Source: https://tokrepo.com/en/workflows/26b9b7dd-dbe6-41e3-a093-17db5409d739 Author: Prompt Lab