# Training

Train Better Response

Debug Mode

To enable debug mode, go into the chatbot’s Details tab and open up Advanced Settings. Scroll to the very bottom and click the checkbox next to “Debug Mode” to enable.

When debug\_mode is enabled, Admins only (not users) will be able to see the knowledge base search results generated by the query and the data exchanged with the ChatGPT API for troubleshooting or analysis purposes.

What does this mean?

When a user sends a message to the chatbot, the system will take their message and use it to search through the information in the knowledge base (KB). The system will find the info that is most similar/ provides the most context in relation to the user’s message and return the top 3 results. These KB results are the first item you will see when looking at the debug mode section.

The second section in the debug mode is the information that is being sent to OpenAI to generate a response.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://lety.gitbook.io/lety-docs/agente-chatbot/training.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
