Why We Taught AI to Doubt Its Own Product Guesses
The Gym Bag That Became a Product Line
When you paste a fitness brand's URL into Jiwa AI, our system scrapes the website, analyzes the content, and identifies what products to feature. This works well when the site explicitly lists products. It falls apart when the signals are ambiguous.
A gym website with images of athletes, protein shakers in the background, and motivational copy about "fueling your potential" was enough for our AI to confidently declare that the business sells something called "SHRED Fitness Bar." It sounded plausible. The name even had the right energy for a fitness brand. There was just one problem โ this product did not exist. The AI hallucinated it from vibes.
This is a different kind of hallucination than the usual AI failure mode. The system was not generating nonsensical output. It was generating a perfectly reasonable inference that happened to be wrong. And because it looked reasonable, it passed through our existing validation and ended up in a content calendar with captions and images featuring a fictional product.
Why Our Old Validation Missed It
We already had a safeguard: after the AI returned products, we checked whether each product name appeared in the source text. The check used simple substring matching โ does the word "shred" appear somewhere in the website copy or Instagram captions?
The problem with substring matching is that it is too forgiving. The word "shred" might appear inside "shredded chicken recipe" on a food blog. The word "bar" might appear in "sidebar navigation." Every short, common word in a product name could match against completely unrelated content, giving the validation a false green light.
Two Gates Instead of One
We replaced the single permissive check with two stricter gates that products must pass through.
The first gate is self-assessed confidence. We now ask the AI to rate its own certainty for each product it identifies, on a scale from zero to one. A product name that appears verbatim in the text gets a score above 0.9. A product implied by multiple signals โ images, captions, and contextual clues โ lands between 0.7 and 0.9. Anything the AI is guessing at from ambiguous signals scores below 0.6. We drop everything below 0.6.
This works because language models are surprisingly well-calibrated when you ask them to express uncertainty explicitly. The AI that confidently hallucinates "SHRED Fitness Bar" in its product list will, when pressed, admit it is only 0.4 confident about that identification. The hallucination was not a knowledge failure โ it was a framing failure. By default, the AI presents everything as fact. Force it to quantify certainty and it becomes honest about what it actually knows.
The second gate is exact word matching. Instead of checking whether product name words appear as substrings anywhere in the source text, we tokenize the entire corpus into a word set and check for exact word boundary matches. The word "bar" in "SHRED Fitness Bar" no longer matches against "sidebar." At least half the significant words in a product name must appear as standalone words in the source data, or the product is filtered out.
Empty Is Better Than Wrong
Our old system had a safety net that undermined the whole validation: if every product got filtered out, it fell back to keeping all of them. The logic was that an empty product list was worse than an imperfect one. In practice, this fallback meant that a site with zero identifiable products would get a full list of hallucinated ones.
We removed the fallback entirely. If no products pass both confidence and word matching gates, the business gets an empty product array. The downstream pipeline already handles this gracefully โ it generates brand-awareness content instead of product-specific posts. An empty product list is honest. A hallucinated product list erodes the trust that makes a business owner believe we understand their brand.
What Changed for Users
For businesses with clearly listed products โ the vast majority โ nothing changed. Their products were already high-confidence and verifiable. The improvement matters for the edge cases: businesses with sparse websites, ambiguous imagery, or content that implies products without naming them. These businesses now get fewer but accurate product identifications, or none at all, rather than a confidently wrong list.
The cost of this improvement is zero additional API calls. The confidence score is generated inside the same analysis step that already identifies products. The word matching runs on data already in memory. Better accuracy, no added latency, no added cost.
The Principle
The most dangerous AI outputs are the ones that look right. Obvious errors get caught by humans. Plausible-sounding fabrications slip through review and end up in production content where they damage brand trust. The fix is not to make the AI smarter โ it is to make it admit when it is guessing, and to treat guesses differently from knowledge.