Enterprise Search Service

The Enterprise Search Service provides intelligent search capabilities across your organization’s data, allowing users to find information through natural language queries. The service consists of two main components:

  1. Conversational Search API - Enables chat-style interactions with your data
  2. Semantic Search API - Powers direct search queries across your content

Architecture Overview

The Enterprise Search Service is built on a Node.js backend with MongoDB for data persistence. It leverages AI models to provide accurate responses and semantic search capabilities. The service integrates with other components such as:

  • AI Backend - Processes queries and generates responses
  • IAM Service - Handles user authentication and authorization
  • Configuration Manager - Manages application settings

Data Models

Conversations

Conversations represent chat sessions with the AI assistant. Each conversation consists of:

  • User queries and AI responses stored as messages
  • Citations that reference source documents
  • Metadata about the conversation (creation time, sharing status, etc.)

Citations

Citations are references to source documents that back the AI’s responses:

  • Content snippets from source documents
  • Metadata about the source (document name, type, location)
  • Relevance information

Searches

Searches represent individual search queries and their results:

  • The original query
  • Citation results
  • Metadata about the search (creation time, sharing status, etc.)

Conversation API

The Conversation API enables chat-style interactions with your organizational data.

Create Conversation Thread

Start a new conversation thread.

POST /api/v1/conversations/create

Add Message

Adds a new message to an existing conversation.

POST /api/v1/conversations/:conversationId/messages

Get All Conversations

Retrieves all conversations for the authenticated user.

GET /api/v1/conversations

Get Conversation By ID

Retrieve conversation by id for the authenticated user.

GET /api/v1/conversations/:conversationId

Delete Conversation

Delete a conversation by its id for the authenticated user. This is a soft delete operation.

DELETE /api/v1/conversations/:conversationId

Share Conversation

Share the conversation within your organization.

POST /api/v1/conversations/:conversationId/share

Unshare Conversation

Revoke the shared conversation access.

POST /api/v1/conversations/:conversationId/unshare

Regenerate Answer

Regenerate the answer.

POST /api/v1/conversations/:conversationId/message/:messageId/regenerate

Update Title

Update the Title of a conversation thread.

PATCH /api/v1/conversations/:conversationId/title

Add Feedback

Provide the feedback to the AI Service.

POST /api/v1/conversations/:conversationId/message/:messageId/feedback

Archive Conversation

Archive a conversation thread.

PATCH /api/v1/conversations/:conversationId/archive

Unarchive Conversation

Unarchive archived conversation thread.

PATCH /api/v1/conversations/:conversationId/unarchive

List Archived Conversations

List all the archived conversation.

GET /api/v1/conversations/show/archives

Semantic Search API

The Semantic Search API allows for direct search queries across your organization’s content.

Performs a semantic search across indexed content.

POST /api/v1/search

Search History

Retrieves all of the search history in pagination.

GET /api/v1/search

Get Search By ID

Retrieve a particular search id.

GET /api/v1/search/:searchId

Delete a particular search id.

DELETE /api/v1/search/:searchId

Delete Search History

Clean all search history.

DELETE /api/v1/search

Share the search result within organization.

PATCH /api/v1/search/:searchId/share

Unshare the shared search.

PATCH /api/v1/search/:searchId/unshare

Archive a search result.

PATCH /api/v1/search/:searchId/archive

Unarchive a search result.

PATCH /api/v1/search/:searchId/unarchive

Schema Definitions