DEV Community

Cover image for 5 ways to improve your prompts to take less energy and tokens
Parth Bhovad
Parth Bhovad

Posted on Originally published at Medium

5 ways to improve your prompts to take less energy and tokens

Most people (including I) do very silly mistakes while writing prompts, and we end up spending more tokens than actually needed. You don't have to put lot of efforts to optimize your prompts. Even with ensuring these basic things you can get a significant effect.

  1. Be Specific: Clearly state what you want in your prompt (e. g. "Summarize in 3 bullet points" instead of just "Summarize"). This reduces back-and-forth and saves energy.

  2. Set Boundaries: "In under 200 words" instead of keeping it vague.

  3. Choose your verb carefully: Words like "explain" or "justify" tend to trigger longer responses and use more energy. When a short answer will do, try "summarize," "list," or "classify" instead.

  4. Skip polite filters: Avoid words like please, kindly, or thank you as they add extra tokens.

  5. Be specific about the output: "Python function for factorial" instead of "write me some code about factorials".

That's it. There are lots of information on the internet available about improving prompts to take less tokens. But most of them are not practical to implement. So, I thought to make a simpler compiled version of it that is easy and still have good effect.

Top comments (0)