Introduction
Organizations generate vast amounts of internal knowledge every day through documentation, policies, technical guides, support articles, meeting notes, and operational procedures. Unfortunately, employees often spend significant time searching for information across multiple systems, resulting in reduced productivity and duplicated efforts.
An Internal Knowledge Assistant addresses this challenge by allowing employees to ask questions in natural language and receive accurate answers based on company documentation. Instead of manually browsing documents, users can interact with an AI-powered assistant that retrieves relevant information and generates contextual responses.
By combining Azure AI Search, Azure OpenAI, and Blazor, .NET developers can build intelligent knowledge assistants that improve information accessibility while maintaining enterprise security and governance.
In this article, we'll explore the architecture, implementation approach, and best practices for building an internal knowledge assistant using Azure AI Search and Blazor.
Understanding the Solution Architecture
An internal knowledge assistant typically follows a Retrieval-Augmented Generation (RAG) architecture.
The workflow looks like this:
User Question
↓
Blazor UI
↓
Azure OpenAI Embedding Model
↓
Azure AI Search
↓
Relevant Documents Retrieved
↓
Azure OpenAI Chat Model
↓
Generated Response
↓
User Interface
This architecture ensures that AI responses are grounded in organizational knowledge rather than relying solely on model training data.
Key Components
The solution consists of several core services.
Blazor Frontend
Blazor provides the user interface where employees can:
Ask questions
View AI-generated responses
Browse referenced documents
Continue conversations
Azure AI Search
Azure AI Search serves as the retrieval layer.
It stores:
Indexed documents
Metadata
Vector embeddings
The service identifies the most relevant content for each query.
Azure OpenAI
Azure OpenAI performs two important tasks:
Generating embeddings for document indexing
Producing conversational responses
Enterprise Knowledge Sources
Common sources include:
SharePoint documents
PDF manuals
Knowledge base articles
Internal wiki pages
Technical documentation
HR policies
Preparing Documents for Indexing
Before documents can be searched, they must be processed and indexed.
Example document:
VPN Access Guide
Step 1:
Install the VPN client.
Step 2:
Authenticate using corporate credentials.
Step 3:
Connect to the approved gateway.
Rather than indexing the entire document as one large record, it should be divided into meaningful chunks.
Example:
Chunk 1:
VPN Installation
Chunk 2:
Authentication Process
Chunk 3:
Connection Procedure
This improves retrieval precision and response quality.
Creating Embeddings in .NET
Each document chunk is converted into a vector embedding before being stored in Azure AI Search.
Example:
using Azure.AI.OpenAI;
var client = new OpenAIClient(
new Uri(endpoint),
new AzureKeyCredential(apiKey));
var embeddingResponse =
await client.GetEmbeddingsAsync(
deploymentName: "text-embedding-model",
input: documentChunk);
var embedding =
embeddingResponse.Value.Data[0].Embedding;
The generated vector is stored alongside the document content.
Designing the Search Index
A typical Azure AI Search index may contain:
{
"id": "123",
"title": "VPN Access Guide",
"content": "Install the VPN client...",
"category": "IT Support",
"contentVector": []
}
Important fields include:
Document title
Content
Category
Tags
Department
Embedding vector
Metadata enables filtering and improved search experiences.
Building the Blazor User Interface
A simple Blazor page can collect user questions.
@page "/assistant"
<h3>Knowledge Assistant</h3>
<input @bind="Question" />
<button @onclick="AskQuestion">
Ask
</button>
<p>@Response</p>
Join the conversation! Your thoughts help the community grow.