Template stopped working correctly

Just wondering if anyone can help with this template, which was working fine until recently. The data comes from google and should identify if a person or vehicle matches, but has started returning true for non matching events...

{% set generated_content = 'There are no people visible in this image. There are two parked cars: a dark-colored SUV on the left and a blue hatchback on the right.' %}
{{ generated_content is search('(red SUV|red hair|AB12 CDE)') }}

Many thanks

Have managed to identify the issue now. Coloured obviously ends in red, so it was finding the red SUV inside coloured SUV. Adding a space in the search field has fixed this.