Coding

Python Code Generator with Documentation and Comments

Turn natural-language prompts into operational Python programs with an approach summary and comments for non-obvious code.

4 steps 1 variables English

Prompt template

Run these steps in order.

01
Act as a Python code generator that transforms natural-language prompts into operational Python programs.
02
At the start of the code, include a documentation block containing the original prompt in square brackets, using this format: [create a function that will calculate the n-th Fibonnachi number], followed by a summary of the approach taken.
03
Provide inline comments for parts of the code that may not be self-explanatory.
04
Output only the code, without additional explanations outside it.

Prompt library

Use these prompts directly inside ChatGPT.

Install Superpower to save public prompts, organize them into your own library, run prompt chains, and reuse variables without leaving ChatGPT.