# Rest.message.received.timeout because of LLM Answer

**URL:** <https://forum.rasa.com/t/rest-message-received-timeout-because-of-llm-answer/67373>\
**Category:** Rasa Open Source\
**Created:** [July 8, 2025, 1:24pm UTC](https://forum.rasa.com/t/rest-message-received-timeout-because-of-llm-answer/67373 "2025-07-08T13:24:07Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![T-Mac-1](https://avatars.discourse-cdn.com/v4/letter/t/59ef9b/32.png) [@T-Mac-1](https://forum.rasa.com/u/T-Mac-1)\
**Post date:** [July 8, 2025, 1:24pm UTC](https://forum.rasa.com/t/rest-message-received-timeout-because-of-llm-answer/67373/1 "2025-07-08T13:24:07Z")

</div>

Whenever my Mistral LLM from Ollama takes too much time for a response I receive an error executing my custom action: action\_give\_llm\_answer. Responses from the LLM with less than 1 minute and around 30 seconds work fine:

I am using: Rasa Version : 3.6.21 Rasa SDK Version : 3.6.2 Python Version : 3.9.11

> 2025-07-08 13:20:08 DEBUG rasa.core.actions.action - Calling action endpoint to run action ‘action\_give\_llm\_answer’. 2025-07-08 13:21:22 DEBUG rasa.core.lock\_store - Deleted lock for conversation ‘50114’. 2025-07-08 13:21:22 ERROR rasa.core.channels.rest - [error] rest.message.received.timeout

In my endpoints.yml I tried to increase the time for a timeout:

> action\_endpoint: url: “[http://localhost:5055/webhook](http://localhost:5055/webhook)” timeout: 350

I use Websocket between my ollama on port: 11434 and my .NET at my localhost:9000

```auto
 @app.websocket("/ws")
async def websocket_endpoint(websocket: WebSocket):
    await websocket.accept()
    try:
        # Client (.NET)
        prompt_data = await websocket.receive_text()
        print(f"\n🟢 Prompt vom Client: {prompt_data}")

ollama_url = "http://localhost:11434/api/generate"
        payload = {
            "model": "mistral",
            "prompt": prompt_data,
            "stream": True
        }

        try:
            response = requests.post(
                ollama_url,
                json=payload,
                stream=True,
                timeout=350 
            )

```

In .NET program.cs I increased timeout time for the RasaService for http request to 5 minutes

> builder.Services.AddHttpClient\<IRasaService, RasaService\>(client =\> { client.Timeout = TimeSpan.FromMinutes(5); });
