> For the complete documentation index, see [llms.txt](https://docs.karini.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.karini.ai/prompt-management/deep-agent-beta/test-deep-agent-prompt.md).

# Test Deep Agent prompt

Deep Agent prompt can be tested using various combinations of LLMs and model parameters, and comparing the responses. Refer to [Test Agent Prompt ](/prompt-management/agentic-prompts/test-agent-prompt.md)for details about prompt testing.&#x20;

#### Execution Control Using Interrupt Tool

The following steps outline the Deep Agent behavior when an Interrupt Tool enabled tool is triggered during testing.

* Navigate to the **Test & Compare** tab in deep agent  prompt.
* Enter the required input in the **User Input** section.
* Click **Test** to execute the Deep Agent prompt
* Once testing starts, the Deep Agent begins processing the request.
* All execution activity is displayed in the **Events** panel on the right side of the screen.
* The **Events** panel provides a structured and real-time view of the execution flow. It displays:
  * The original user input
  * The Deep Agent’s processing steps
  * Any tool that is being invoked
  * The current execution status (e.g., running, interrupted, completed)
  * This panel allows users to track how the request is being handled at each stage.
* When the Deep Agent invokes a tool configured with **Interrupt Tool**, execution pauses automatically. At this point:
  * The workflow is temporarily halted.
  * The execution state is preserved.
  * The Events panel indicates that the tool invocation has been interrupted.

<figure><img src="https://415930246-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7ZrVuiAUMyuYVvrK5KaB%2Fuploads%2FmieRciLQSlshkTA3bMn9%2Fimage.png?alt=media&amp;token=a7cf6ddf-bad3-410d-a368-d8df4f635ba3" alt=""><figcaption></figcaption></figure>

* Click **Format response** to view the structured tool invocation details.

  This displays:

  * The tool name
  * The generated tool arguments
  * The available user decision options

  <figure><img src="https://415930246-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7ZrVuiAUMyuYVvrK5KaB%2Fuploads%2FbFUkDgx2y908SSOW4eTS%2Fimage.png?alt=media&amp;token=4d7618ba-03be-4c4e-a260-8f49312be4b1" alt=""><figcaption></figcaption></figure>

When interruption occurs, the following options are displayed

* **Approve**

  * The tool executes using the generated inputs.
  * The Deep Agent resumes execution from the paused state.
  * A **Submit** button becomes visible.
  * Click **Submit** to continue execution.

  <figure><img src="https://415930246-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7ZrVuiAUMyuYVvrK5KaB%2Fuploads%2Fu481w40Cw7BMqQlrCW5z%2Fimage.png?alt=media&amp;token=63da01d5-1fc1-4c2a-b0f6-45593995ab1b" alt=""><figcaption></figcaption></figure>

  #### Edit

  * The system displays the tool inputs in editable form.
  * The user may modify:
    * Tool function arguments
    * File inputs (if applicable)
  * After making changes, click **Submit**.
  * The tool executes using the updated inputs.
  * The Deep Agent resumes execution from the preserved state.

  <figure><img src="https://415930246-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7ZrVuiAUMyuYVvrK5KaB%2Fuploads%2FjDzGccMZMXBCFP4BSOEx%2Fimage.png?alt=media&amp;token=458981d3-2790-4eda-a8cf-cefa2ebcd7bd" alt=""><figcaption></figcaption></figure>
* #### Reject

  * The tool invocation is canceled.
  * The current execution flow is terminated.
  * No further processing occurs for that test run.

  <figure><img src="https://415930246-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7ZrVuiAUMyuYVvrK5KaB%2Fuploads%2FViTk4LgcAZBHF20fm428%2Fimage.png?alt=media&amp;token=fac7d94b-d6b0-40e2-b4d6-4d9ab7ae500d" alt=""><figcaption></figcaption></figure>
* For lengthy or multi-step queries, the Deep Agent may trigger additional tool invocations that are also configured with interruption.
* In such cases:

  * Execution will pause again.
  * The user must review the tool invocation.
  * Approve, Edit, or Reject.
  * Click **Submit** to continue.

  This process may repeat until all required tool invocations are completed and the final response is generated.

<figure><img src="https://415930246-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7ZrVuiAUMyuYVvrK5KaB%2Fuploads%2FRcdm5lMvgZzXq1ZRIU4Y%2Fimage.png?alt=media&amp;token=67d40769-763b-4a15-987c-1357313cd8db" alt=""><figcaption></figcaption></figure>

After all required tool invocations are reviewed and approved (or edited and submitted), the Deep Agent completes execution and generates the final response. The completed output is displayed in the **Events** panel under the corresponding model, indicating that the workflow has successfully finished.

<figure><img src="https://415930246-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7ZrVuiAUMyuYVvrK5KaB%2Fuploads%2FBm7yk4vuGVvEtXEGyHaV%2Fimage.png?alt=media&amp;token=e0432021-3605-45a1-8402-9ca3ee2a0acd" alt=""><figcaption></figcaption></figure>
