> ## Documentation Index
> Fetch the complete documentation index at: https://docs.retellai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Manually test your agent

> Learn how to effectively test and debug your AI agents using the LLM Playground

The LLM Playground provides a convenient environment for testing your AI agents without making actual web or phone calls. This interactive testing interface enables:

* Rapid prototyping and debugging of agent responses
* Testing different conversation scenarios
* Immediate feedback on agent behavior
* Faster development iterations

<Steps>
  <Step title="Access the LLM Playground">
    1. Navigate to your agent's detail page
    2. Click on the "Test LLM" tab
    3. Choose "Manual Chat".
    4. You'll see the chat interface where you can start testing

    <Frame caption="LLM Playground Interface">
      <img height="700" src="https://mintcdn.com/retellai/pRGcctz_zOqy0mSt/images/test-llm/test-llm-full.png?fit=max&auto=format&n=pRGcctz_zOqy0mSt&q=85&s=fa9e0b2f8326de3eda9f09468a792b1d" alt="Screenshot of the LLM Playground interface" data-path="images/test-llm/test-llm-full.png" />
    </Frame>
  </Step>

  <Step title="Test Basic Conversations">
    1. Type your message in the input field
    2. Observe the agent's response
  </Step>

  <Step title="Test Function Calling">
    1. Use prompts that should trigger specific functions
    2. Verify that functions are called with correct parameters

    <Frame>
      <img style={{width: "100%", height: "600px"}} src="https://mintcdn.com/retellai/M9QYKZE4hbt00HfL/images/p_1.png?fit=max&auto=format&n=M9QYKZE4hbt00HfL&q=85&s=25bb628a14d79a19ae43e6f68c1cd236" alt="Screenshot of the function calling test" width="454" height="1247" data-path="images/p_1.png" />
    </Frame>
  </Step>

  <Step title="Iterate and Refine">
    1. Monitor agent behavior and responses
    2. Update prompts or functions as needed
    3. Click the "delete" button to reset conversations
    4. Test the updated behavior

    <Frame caption="Iterate and test">
      <img style={{width: "100%", height: "600px"}} src="https://mintcdn.com/retellai/M9QYKZE4hbt00HfL/images/p_3.png?fit=max&auto=format&n=M9QYKZE4hbt00HfL&q=85&s=dbb504c870bd62d98588fd73e6b7c5cf" alt="Screenshot of the iteration process" width="454" height="1247" data-path="images/p_3.png" />
    </Frame>
  </Step>

  <Step title="Save Test Cases">
    1. Click the "Save" button to store your test conversation
    2. Add a descriptive name for the test case
    3. Access saved tests from the agent detail page

    <Frame caption="Save test case">
      <img style={{width: "100%", height: "600px"}} src="https://mintcdn.com/retellai/M9QYKZE4hbt00HfL/images/p_4.png?fit=max&auto=format&n=M9QYKZE4hbt00HfL&q=85&s=fbbd89e600b01ced0dd4bac139270a9e" alt="Screenshot of saving a test case" width="454" height="1247" data-path="images/p_4.png" />
    </Frame>

    <Frame caption="Saved test cases">
      <img style={{width: "100%", height: "600px"}} src="https://mintcdn.com/retellai/M9QYKZE4hbt00HfL/images/p_2.png?fit=max&auto=format&n=M9QYKZE4hbt00HfL&q=85&s=256b0caa78f0d6567773a8e6b6604a5d" alt="Screenshot of saved test cases" width="452" height="1225" data-path="images/p_2.png" />
    </Frame>
  </Step>

  <Step title="Test Dynamic Variables">
    1. Use dynamic variables in your prompts
    2. Verify that variables are properly interpolated
    3. Test different variable values and scenarios

    <Frame>
      <img style={{width: "300px" }} src="https://mintcdn.com/retellai/pRGcctz_zOqy0mSt/images/test-llm/dynamic-variable.png?fit=max&auto=format&n=pRGcctz_zOqy0mSt&q=85&s=2366a40145cf70c007b9801d763fc42f" alt="Screenshot of dynamic variables" width="1060" height="1060" data-path="images/test-llm/dynamic-variable.png" />
    </Frame>
  </Step>

  <Step title="Mock Custom Function">
    Add a mock response for functions during testing. This response will be returned instead of making an actual function call, ensuring that no real execution occurs.

    <Frame>
      <img style={{width: "300px" }} src="https://mintcdn.com/retellai/pRGcctz_zOqy0mSt/images/test-llm/custom-function-mock.png?fit=max&auto=format&n=pRGcctz_zOqy0mSt&q=85&s=159972b5bc8e2cb24b7a035ba84d4dc5" alt="Screenshot of custom function mock" width="1078" height="990" data-path="images/test-llm/custom-function-mock.png" />
    </Frame>
  </Step>
</Steps>

### Best Practices

* Start with simple conversations and gradually test more complex scenarios
* Save important test cases for regression testing
* Test edge cases and error handling
* Document unexpected behaviors for future reference
