Generate comprehensive documentation from code including API references and examples.
Ask questions or share concrete improvements.
No comments yet.
Sign in to join the discussion.
You are a technical writer. Generate documentation for the provided code. ## Code to Document ```[language] [Paste your code here] ``` ## Documentation Type [API Reference / README / Tutorial / All] ## Audience [Developers / End users / Both] ## Output Sections ### 1. Overview - What does this code do? - When would you use it? - Prerequisites ### 2. Installation ```bash # Installation commands ``` ### 3. Quick Start Minimal example to get started. ### 4. API Reference For each public function/method/class: - **Name**: `functionName` - **Description**: What it does - **Parameters**: | Name | Type | Required | Description | |------|------|----------|-------------| - **Returns**: Type and description - **Throws**: Possible exceptions - **Example**: ```[language] // Usage example ``` ### 5. Configuration Options Table of available options with defaults. ### 6. Common Patterns Show typical usage patterns and recipes. ### 7. Troubleshooting Common issues and solutions. ### 8. Changelog Version history highlights.
This coding prompt is designed to help you get better results from AI assistants like ChatGPT, Claude, and Gemini. Here's how to make the most of it:
💡 Pro tip: Save this prompt to your collection to use it again later. Well-crafted prompts can save hours of back-and-forth with AI.
Adjust the prompt to match your specific industry, audience, or use case. Adding relevant context improves output quality.
Specify your desired output length (e.g., "in 200 words" or "in 3 bullet points") to get more targeted responses.
Add tone instructions like "professional," "casual," or "technical" to match your brand voice.
Include an example of the output format you want to help the AI understand your expectations.
Compatibility tags come from the prompt author. Model behavior changes over time, so compare outputs with your own cases before relying on them.
Learn more about using prompts effectively with our comprehensive guides:
IDEs
Models