Understanding how to comment and uncomment parts of your system prompt or code is essential when building and testing your AI Agents. Commenting allows you to temporarily disable specific lines without deleting them, making it easy to test or make changes.
// This is a comment. It wonβt be read by the AI.
// Role: Customer Support Specialist
// To enable (uncomment), remove the two slashes:
Role: Customer Support Specialist
# This is a comment line
# Goal: Help users with their questions and provide support.
# To enable (uncomment), remove the hash (#):
Goal: Help users with their questions and provide support.
<!-- This is a comment in HTML -->
<!-- <p>Role: Customer Support Specialist</p> -->
<!-- To uncomment, remove the <!-- and --> -->
<p>Role: Customer Support Specialist</p>
Comment out roles, goals, or sections while testing new versions:
// Role: Customer Support Agent
// Goal: Assist with product-related questions and troubleshooting.
Role: Sales Agent
Goal: Focus on generating leads and booking appointments.
Simply remove the comment symbols from the line or block:
// Role: Customer Support Agent β Role: Customer Support Agent
Using comments is a smart way to version control your AI agent prompts. You can easily switch roles, test different personalities, or experiment without losing any of your original instructions.
This method keeps your system prompt clean, organized, and easy to manage as you improve your AI Agent.