Resolving the 'Service Unavailable' Error

Encountering the "Service Currently Unavailable" message in Parloa can be frustrating. This guide aims to help you understand why this issue occurs, how to identify the root cause, and implement safeguards to prevent future occurrences.

Error Overview

This error usually indicates an infinite loop—a situation where your Parloa bot repeats the same action without progressing. Most often, these loops are due to an error in the global error handling, causing the error-handling flow to loop indefinitely. To resolve this, inspect your bot's global error handling and review the last State block executed in the debugger.

How Parloa Processes Conversations

Parloa's conversation model is based on sequential question-and-answer transactions. Each conversation is a series of these transactions, visible in the debugger. An incomplete transaction, where the bot does not move to the next State block, typically indicates an infinite loop and stops debugger updates.

Identifying and Resolving Infinite Loops

Infinite loops often arise from issues in global error handling or bot flow misconfigurations. Follow these steps to resolve them –

Step 1 – Isolate the Error

Redirect global error handling temporarily to an End Conversation block. This isolates the primary error triggering the loop.

Step 2 – Reconnect and Test

  1. Examine the last State block – Begin with the last State block shown in the debugger. The error usually lies between this block and the next.

  2. Reintegrate components gradually – Carefully add each bot component back into the flow. Test after each addition to verify if the bot works or if the error recurs.

  3. Systematic testing for stability – Maintain this add-and-test routine. It ensures bot stability and helps pinpoint the exact cause of the error.

Step 3 – Implement a Counter

Add a counter directly after the Global Intents block. This counter consists of a storage variable to increment each time the global error handling is triggered, and a preceding condition to check the counter's value. This setup helps identify whether the entry into global error handling is the first occurrence or a part of an ongoing loop.

In the case of a loop, the bot should take a different path, most likely ending the conversation. This step is crucial for revealing errors within the global error handling flow and ensuring that there's a 'break' condition to prevent infinite loops.

Additional Considerations

If the error occurs immediately after a bot prompt, consider retraining the Natural Language Understanding (NLU) module. This is especially important following system updates or migrations.

Last updated