Have you ever seen AI build something that wasn’t what you actually wanted? Did it happen to you as well? Over the weekend, I came across another AI coding agent, Cline. While experimenting, I asked it to add a feature to my blog posts and daily tips to show visit counts and highlight the most popular articles for readers. Long story short, I have that feature implemented, and when I reviewed the codebase, I found that visits were being fetched from a temporary cache. It was supposed to hold the counts for some time and flush them to SQL to minimize database hits. As a result, the counts were getting reset to 0 every few minutes.

 

I didn’t implement this feature through any AI development assistant tool like OpenSpec or BMad. I just provided a straightforward prompt to the Cline coding agent. When I looked more closely, I realized that AI needs more than just a prompt, because writing code and understanding the problem are two different things. For example, let's assume I asked the AI coding agent, “Build a currency codes API.” That sounds like a reasonable instruction, but there is a lot the AI doesn’t know:

  • What are the business rules?
  • What security rules apply?
  • What are the architectural constraints?
  • What does a successful or failed response look like?
  • And many more…

I think AI is not the issue here. The information and task details we provide aren't enough. To make the code work, AI would have to make a few assumptions, and as a result, the code can be technically correct, but the software is functionally wrong. We can also describe it as AI needing information to understand the problem and determine what “the right thing” means. Let's conclude this tip. The better AI understands the problem, the better chance it has of implementing the right solution. This opens the next discussion: how to best organize all the information so AI can use it effectively? Let's cover this in the next daily tip. Get ready.