# Best approach for building a chatbot — retained record

> Retained reddit record from reddit:AI_Agents.

Canonical: https://highsignal.app/data/records/3cac85154f26cc90

[← sources](https://highsignal.app/data)


source: [reddit](https://highsignal.app/data/reddit) (reddit:AI_Agents)  published 2026-09-30 06:01 ingested 2026-10-01 02:37

[original source ↗](https://www.reddit.com/r/AI_Agents/comments/1wtx75z/best_approach_for_building_a_chatbot/)

## retained text



```
We have a client who currently has logistics data from their existing logistics software and wants a chatbot where they can ask questions about the data.

We are thinking of using a SQL agent to generate queries based on the schema.

A few questions:

 Is there any better way to do this kind of chatbot?

 How can we validate that the generated SQL is logically correct, not just syntactically valid?

 How can we validate the final query result/answer?

 We're considering using another reviewer agent and a feedback loop for validation. Is this a common/reliable approach?

I'd love to hear from anyone who's built something similar in production.
```



document fetched 2026-10-01 00:20 · canonical https://reddit.com/r/AI_Agents/comments/1wtx75z/best_approach_for_building_a_chatbot
