Lola NLP AI icon

Lola NLP AI

Basic Lola Sample Node

Overview

The Lola NLP AI node enables conversational AI interactions within n8n workflows. It sends user messages, context, and configuration to the Lola AI service, which responds with generated replies or commands. The node supports both synchronous (waits for a response) and asynchronous (returns immediately; response handled by another node) operation modes. This is useful for building chatbots, virtual assistants, or automated customer support agents that require contextual understanding and personality customization.

Example scenarios:

  • Automating customer support chats with tailored personalities.
  • Creating multilingual or culturally adapted chatbot experiences.
  • Integrating AI-driven responses into messaging platforms like Telegram.

Properties

Name Meaning
Personality and Skills Select one or more traits to define the assistant's behavior and background:
- Customer Chat
- Friendly
- Mexican
- Sarcastic
- Spanish
Knowledge Base Text used to train the AI on the context of the conversation. Provides background information or rules for the assistant.
Mode Determines how the node handles responses:
- Sync: Waits for Lola's reply and outputs it.
- Async: Returns immediately; response will be available in the Lola Callback node.
Assistant Name The name assigned to the assistant (required).
Incoming Message The user's message to process (required).
Chat Identifier Unique identifier for the chat session (required).
Message Identifier Optional ID to track the specific message.
Source ID Identifies the source platform of the message (e.g., "Telegram") (required).
Metadata Key-value pairs for additional metadata. Each entry has:
- Name: Metadata key
- Value: Value to set for the metadata key

Output

  • The node outputs an array with two possible branches:
    • First output: Items containing the original input plus a lola_response field with the AI's response.
    • Second output: Items where the response includes a command (command property present).

Structure of json.lola_response:

{
  // ...other fields from Lola API...
  "source": {
    "content": {
      // ...response content, except 'prompt' is removed...
    }
  },
  "command": { /* present if a command was returned */ }
}
  • If the response contains a command, the item is sent to the second output; otherwise, it goes to the first output.
  • No binary data is produced.

Dependencies

  • External Service: Requires access to the Lola AI API endpoint.
  • API Key: Optionally uses lolaKeyApi credentials if configured.
  • n8n Configuration: Ensure network access to the Lola API and configure credentials if needed.

Troubleshooting

Common issues:

  • Missing required properties: If required fields (Assistant Name, Incoming Message, Chat Identifier, Source ID) are not provided, the node may throw parameter validation errors.
  • Invalid API credentials: If the Lola API key is missing or incorrect, authentication errors may occur.
  • Network errors: Connectivity issues with the Lola API endpoint can cause request failures.
  • Async mode confusion: In async mode, the response is not immediately available; users must use the Lola Callback node to handle the reply.

Error messages and resolutions:

  • "Missing required parameter...": Ensure all required fields are filled.
  • "Authentication failed": Check and update your Lola API credentials.
  • "Network error" or "Request failed": Verify network connectivity and API endpoint availability.

Links and References

  • n8n Documentation
  • (If available) Lola AI documentation or API reference (not provided in code)

Discussion