The app for independent voices

A common 'coding with AI' mistake is trying once and giving up because it didn't work the first time. AI takes trial and error, and with a few tricks, you can have it start "reading your mind" in no time.

Here are a few pro tips when using AI in "Agent Mode" in your Editor:

  1. Instead of asking it to do the task right away, first have it create a detailed plan

By asking it to plan, it takes a step back and thinks how it will do each step before going down a "rabbit hole of doom," where it ends up chasing its tail into fixing all the different errors it introduced and making the codebase worse.

Once planning is finished, ask it to execute the plan "step by step."

  1. Include examples of what you have in mind

If you want AI to make a new API file, and you have a specific example you know you want it to look like, tell it!! Don't just assume it will find that example.

AI, like engineers, feeds off of great copy-paste and examples it can reference.

  1. Give it a role

If you’re generating docs, tell it it's a Technical Writer

If you’re planning out a huge feature, tell it it's a Principal Engineer

If you’re writing test cases, tell it its a QA Engineer.

By giving it a role, it learns all the implicit instructions you don't want to have to type out. If you tell it it's a principal engineer, it will start thinking about scalability, security, and architecture patterns without you needing to say all that.

Want 4 more tips like this so you can ship code faster than ever before? Check the latest High Growth Engineer article: read.highgrowthengineer…

May 18
at
3:34 PM

Log in or sign up

Join the most interesting and insightful discussions.