Hallucinations in Katalon Studio

Katalon Studio is suggesting me to use waitForElementText().

But wait this Keyword does not exist.

Somehow it confidently suggests to use this keyword for waiting for element text.

This is definitely not expected at this level, given Katalon AI should have all the Katalon keywords handy.

Hehe, that’s exactly why every AI tool comes with a disclaimer: “AI-generated content may be incorrect. Please verify the information before relying on it.

exactly explains why human judgement critical while using AI

Yeah correct..

But what about beginners, they paid to Katalon Studio to get specific answers and if they implement in scripts, they might end up spending hours in finding out why the script is failing.

I completely agree with your point. In fact, the Katalon AI team should take this seriously, as it can significantly impact the credibility and trustworthiness of the AI tool.

Hi @akshay_sartabe, thanks for flagging this and for the screenshot. You’re right, waitForElementText() isn’t a real Katalon keyword, so the AI shouldn’t be suggesting it.

We’ll review this with the team and work on improving it. Thanks for helping us make it better! Also can you share the context, at which question or prompt did it get hallucinated.

Thanks for flagging this — AI suggestions are a helpful starting point, but they should always be verified against the official keyword documentation before use. In this case, the closest built-in options are waitForElementPresent(), waitForElementVisible(), and waitForElementAttributeValue(), and for text specifically you’d typically poll getText() inside a WebUI.waitForElementPresent or a short retry loop until the expected value appears. If you need this often, wrapping that logic in a small custom keyword is a clean way to reuse it across test cases. Reporting the hallucinated keyword to the team is also a good idea so the suggestion model can be improved.

For beginners, a cheap safeguard is to paste any AI-suggested keyword into a scratch test case first; Katalon’s editor and auto-complete will flag a nonexistent method before it reaches a real suite. That won’t catch wrong arguments or logic, but it catches hallucinated keyword names quickly. For waiting on text, a short retry around getText() is also easier to explain than a fake wait keyword.

Whether now this issue got fixed? As this is a blunder so it needs to be fixed ASAP

Bella might be able to provide an update on this

hi @akshay_sartabe
while waiting for the fix, you can wait on text with a real keyword. selenium’s getAttribute falls back to the dom property, so this should work:
WebUI.waitForElementAttributeValue(findTestObject('lbl_status'), 'textContent', 'Done', 10)
exact match only though, for partial text a small loop around getText is still the way

Thanks @depapp , I already have managed that.

But the only reason I highlighted here is beginners should be aware and cautious while using AI and how to free themselves from such situations.

An experienced guy would definitely look for workaround and not get blocked by this.

fair point, beginners won’t even know to doubt it. hopefully the fix checks the suggestion against the real keyword list before showing it

Yeah… that is whole point to avoid hallucinations.

Since Katalon Studio has Katalon Documentation inbuilt, such hallucinations are not expected.

Agreed. once Bella& katalon product confirms on the fix, we can reverify this

Agreed — verification first is the key. For text waits, I’d keep the workaround simple: poll getText() in a short retry loop, or use waitForElementAttributeValue where it fits, and wrap it as a custom keyword if it’s reused. Testing AI-suggested keywords in a scratch case first is also a quick way to catch nonexistent methods before they reach a real suite.