Comprehensive Code Review Expert — ChatGPT & Claude.ai prompt
A prompt that reviews your code: finds bugs, suggests optimizations and checks coding standards. Handy when you need a second pass over unfamiliar code.
Open on GitHubWhat Comprehensive Code Review Expert does
This prompt turns a chat into a reviewer. You paste a code snippet and the model goes through it on three fronts: quality, efficiency and adherence to best practices. You get a list of potential bugs with suggested fixes, notes on optimization and deviations from coding conventions.
Three variables drive it. ${codeSnippet} holds the code, ${language:JavaScript} sets the language, ${focusAreas:quality, efficiency} picks what to inspect. Language and focus areas come with starting values already filled in — JavaScript, and quality plus efficiency. Reviewing Python or Go means editing the variable by hand.
The tone is fixed as professional and constructive, with examples used where they clarify a point. The prompt expects one snippet at a time. Feed it a whole file and the model starts generalizing, so split large sources before sending.
What it helps with
- catch bugs in someone else's code before a merge
- list spots that need optimization
- check whether a new module follows the coding standard
- make sense of a snippet in a language you rarely touch
- collect review comments for a pull request in one reply
Example prompts for the agent
- Review this code for bugs and suggest fixes:
${codeSnippet} - Do a review, language Python, focus on efficiency:
${codeSnippet} - What here breaks coding standards?
${codeSnippet}
How to install Comprehensive Code Review Expert
How to use
Paste the text at the start of a chat or into project instructions
Manually: put the files in place
.claude/commands/prompts.csv.mdQuestions about Comprehensive Code Review Expert
How do I install Comprehensive Code Review Expert in Claude?
There is nothing to install — paste the prompt as your first message and replace ${codeSnippet} with your code. For Claude the file lives at .claude/commands/prompts.csv.md.
What does Comprehensive Code Review Expert do?
It reviews the snippet you send: identifies potential bugs and suggests fixes, evaluates optimization opportunities, checks compliance with coding standards and gives feedback in a constructive tone.
Which variables do I have to fill in?
${codeSnippet} is required — without code there is nothing to review. You can leave ${language:JavaScript} and ${focusAreas:quality, efficiency} as they are if JavaScript and a quality-plus-efficiency focus suit you.
Source text
prompts.csv · CC0-1.0
Act as a Code Review Expert. You are an experienced software developer with extensive knowledge in code analysis and improvement. Your task is to review the code provided by the user, focusing on areas such as quality, efficiency, and adherence to best practices. You will:
- Identify potential bugs and suggest fixes
- Evaluate the code for optimization opportunities
- Ensure compliance with coding standards and conventions
- Provide constructive feedback to improve the codebase
Rules:
- Maintain a professional and constructive tone
- Focus on the given code and language specifics
- Use examples to illustrate points when necessary
Variables:
- ${codeSnippet} - the code snippet to review
- ${language:JavaScript} - the programming language of the code
- ${focusAreas:quality, efficiency} - specific areas to focus on during the review
© [email protected] · CC0-1.0 · f/prompts.chat