Skill

Answer Questions Using Your Own Data

3 Semantic Kernel samples for RAG using Azure OpenAI's On Your Data API, including function calling and vector search variants.

Works with azure openai

91
Spark score
out of 100
Updated 9 days ago
Version dotnet-1.78.0
Models

Add to Favorites

Why it matters

Leverage your private documents and data to power intelligent conversations and gain insights. This asset enables retrieval-augmented generation (RAG) with Azure OpenAI, allowing you to query your data using natural language.

Outcomes

What it gets done

01

Index your data for efficient retrieval.

02

Generate responses based on your specific information.

03

Integrate with Azure OpenAI for advanced language capabilities.

04

Build conversational interfaces that understand your context.

Install

Add it to your toolbox

Run in your project directory:

curl -fsSL https://spark.entire.vc/get/sk-concept-onyourdata | bash

Overview

Semantic Kernel - On Your Data

Three Semantic Kernel Python samples for RAG using Azure OpenAI's managed On Your Data API, including function calling and vector search variants. Use when Azure OpenAI's managed retrieval is sufficient; build a custom pipeline instead if you need deeper control over chunking or reranking.

What it does

This is a set of 3 Semantic Kernel Python concept samples demonstrating Retrieval-Augmented Generation via Azure OpenAI's On Your Data API: a baseline chat-with-data sample (azure_chat_gpt_with_data_api.py), a variant that combines it with function calling (azure_chat_gpt_with_data_api_function_calling.py), and a variant using vector search specifically (azure_chat_gpt_with_data_api_vector_search.py).

When to use - and when NOT to

Use these when you want Azure OpenAI to handle the RAG retrieval step itself via its native On Your Data API, rather than building and managing a separate vector store and retrieval pipeline yourself. The function-calling variant is useful when the agent also needs to invoke tools alongside grounded data retrieval; the vector-search variant is the fit when you specifically want vector-based (as opposed to keyword or hybrid) retrieval against your data source.

Not the right samples if you're not using Azure OpenAI, or if you need full control over the retrieval pipeline (custom chunking, reranking, hybrid search tuning) beyond what the managed On Your Data API exposes - a custom vector-database-backed RAG pipeline would be needed for that level of control.

Inputs and outputs

Inputs: an Azure OpenAI deployment configured with On Your Data (pointing at your data source), plus user chat messages.

Outputs: chat completions grounded in the connected data source, optionally combined with function-calling tool invocations or restricted to vector-search retrieval specifically.

Integrations

Microsoft Semantic Kernel (Python), Azure OpenAI On Your Data API.

Who it's for

Developers on Azure OpenAI who want managed RAG via On Your Data rather than building a custom retrieval pipeline, and need the specific variant matching whether they also need function calling or vector-search-specific retrieval.

Source README

Retrieval-augmented generation (RAG) with Azure OpenAI On Your Data

Examples (3 files):

  • azure_chat_gpt_with_data_api.py
  • azure_chat_gpt_with_data_api_function_calling.py
  • azure_chat_gpt_with_data_api_vector_search.py

FAQ

Common questions

Discussion

Questions & comments · 0

Sign In Sign in to leave a comment.