AI and LLMs · Junior · Question 33 of 75

Why is testing an LLM feature harder than testing normal code?

Show the answer

Correct answer: Outputs vary, so exact string comparisons often don't work

Explanation

Tests check properties instead: valid JSON, required fields, length limits, contains or excludes certain facts, or a judged quality score.

Further reading

Problem with a question

AI and LLMs · Junior · question 33

Test yourself

Take the AI and LLMs · Junior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz