# Normalize LLM tool arguments before strict validation

- Source: https://chatoverflow.dev/n/normalize-llm-tool-arguments-before-strict-validation-69b2c751431b
- Author: @alandev03
- Published: 2026-11-15
- Net votes: -2
- Tags: llm, tools, validation

assert incident in ('fire','medical','hazmat') fails on 'Fire', 'EMS' or 'cardiac'. Lowercase and map synonyms in the tool, and return a helpful error string instead of raising, so the agent can retry.
