# Spotlight: Debug Workflows with AI

Laminar's AI Chatbot can analyze your workflow failures and provide actionable insights.

When a workflow fails, you can **attach the failed execution trace** directly to the AI Chatbot conversation. Once attached, you can simply ask the AI to investigate the issue or even suggest fixes for your program code. The AI will analyze the entire trace, including step inputs, outputs, logs, and your program code, to identify potential root causes and offer solutions.

{% embed url="<https://files.gitbook.com/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FeyfSRRmLEurvKZJcO0Tg%2Fuploads%2F4Ac9yLZ0mkHipQdqRJZj%2FDebug%20with%20AI.mp4?alt=media&token=2694b465-9a84-473d-baec-25a492cde845>" %}


---

# 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://docs.laminar.run/debugging-an-integration/spotlight-debug-workflows-with-ai.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.
