LogoLogo
Documentation
Documentation
  • Getting Started
    • Introduction
    • Sign up to Developer Edition
    • Build Your First Agent
    • Developer Support
  • Core Concepts
    • Agent
      • Knowledge
      • Webhook
    • PII Masking
    • Sub-Agent
    • Intent
    • Workflow
      • Node
        • Input
        • Output
        • Loader
        • Display
        • API Node
        • Web Crawler
        • Table Write
        • Table Read
        • Ruleset
        • Upload Document
        • Javascript
        • Workflow
        • Loop
        • Document To Image
        • External Database
        • Storage Write
        • Storage Read
        • Fetch Document
        • Prompt
        • RAG Query
        • Vector Search
        • Emit Event
    • RAG
    • Model Hub
      • Entity Recognizers
    • Data Gateway
    • Rulesets
    • Code Snippets
    • Tables
    • Storage
    • Widget
  • Overview of GenAI
    • Introduction
    • Key concepts
      • Intent Classification
      • Inference
      • Generative AI Models
      • Large Language Models (LLMs)
      • Prompt Engineering
      • AI Agents
      • RAG (Retrieval Augmented Generation)
      • AI Workflow Automation
      • AI Agents vs LLM-based APPs
Powered by GitBook
On this page
  • Overview
  • How to Create a New Entity Recognizer
  • Using an Entity Recognizer in Workflows
  • Key Takeaways for Developers
Export as PDF
  1. Core Concepts
  2. Model Hub

Entity Recognizers

Overview

The Entity Recognizer (ER) feature enables developers to define custom patterns to identify specific entities in natural language user queries. These patterns are used to extract relevant entities (e.g., email addresses, loan application numbers, phone numbers) that are critical for processing workflows efficiently.

For example: A user submits the query, "Give me the amortization schedule for my loan application: LA:12312331."

  • Developers can define a custom regex to recognize the loan application number LA:12312331.

  • The Entity Recognition Node in the workflow can then use this pattern to extract the entity dynamically from the user query.

How to Create a New Entity Recognizer

  1. Navigate to the Model Hub → Select the Entity Recognizer tab.

  2. Click "Create Entity Recognizer."

  3. Fill in the following fields:

    • Name: Provide a meaningful name (e.g., Loan Application Recognizer).

    • Pattern: Enter a regex pattern for the entity you wish to recognize.

      • Example: To identify loan application numbers in the format LA:12312331, use the regex LA:\d{8}.

    • Flags: Optionally, specify regex flags to modify the pattern’s behavior.

      • Flags Explanation:

        • g → Global flag to find all matches in the input.

        • i → Case-insensitive matching.

        • s → Enables the dot . to match newline characters.

  4. Click "Create" to save the recognizer.

Using an Entity Recognizer in Workflows

To use a created Entity Recognizer, follow these steps:

  1. Add the Entity Recognition Node to the workflow.

  2. Pass the user query as input to the node.

    • Use the special variable $agent.query, which contains the user’s natural language query.

  3. The node processes the input using the defined Entity Recognizer and outputs the recognized entity as shown in example below.

Example:

  • Entity Recognizer: Loan Application Number

  • Input: Give me the amortization schedule for my loan application: LA:12312331

  • Output:

{
  "result": ["support@example.com"]
}

The output from this node will be used as input for the next connected node, where the named entity can be accessed using the 'result' key

Key Use Cases for Entity Recognizers

✅ Extract Named Entities – Recognize and extract structured data (e.g., email addresses, IDs, dates) from user queries. ✅ Enhance Workflow Automation – Use extracted entities to dynamically route workflows or fetch related data. ✅ Handle Complex Inputs – Process unstructured natural language queries with precision.

Key Takeaways for Developers

✅ Customizable Patterns – Define regex patterns to recognize specific entities tailored to your use case. ✅ Seamless Workflow Integration – Use the Entity Recognition Node to incorporate entity extraction directly into workflows. ✅ Efficient Processing – Simplify user query handling by dynamically identifying and isolating critical information. ✅ Regex Flexibility with Flags – Use flags to adjust pattern behavior for better matching and adaptability.

By leveraging Entity Recognizers, developers can create AI workflows that intelligently extract and process key information, improving the efficiency and accuracy of automated responses.

PreviousModel HubNextData Gateway

Last updated 4 months ago