Skip to content

victorbjor/azure-ai-search-lab

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🚀 Azure AI Search Minimal PoC

This project is a minimal proof-of-concept (PoC) for using Azure AI Search with vector search capabilities. It includes:

  1. Data Ingestion Pipeline (Python script for processing text and pushing vector embeddings to Azure AI Search)
  2. Backend API (FastAPI, serves search queries and hosts the frontend)
  3. Frontend (Simple search input + results display)
  4. Azure Deployment Script (Shell script to set up Azure resources and deploy the backend/frontend)

📌 Features

Push-based ingestion (connects to S3 storage, extracts text, generates vectors, and pushes to AI Search) ✅ Azure AI Search integration (supports vector search) ✅ FastAPI backend (exposes search endpoint and serves frontend) ✅ Minimal frontend (simple UI for querying search results) ✅ Azure CLI automation (one script to set up everything)


🛠 Setup & Deployment

1️⃣ Prerequisites

  • An Azure account
  • Python 3.9+ installed
  • Azure CLI (``) installed
  • boto3 (for S3 access)
  • OpenAI API key (or another embedding provider)

If az CLI is not installed, the deployment script will install it.


2️⃣ Deploy to Azure

Run the shell script to set up Azure resources:

chmod +x deploy.sh
./deploy.sh

This will: ✅ Create an Azure Resource Group ✅ Deploy an Azure AI Search service ✅ Deploy a FastAPI backend & frontend using Azure App Service

Once completed, it will output:

Azure AI Search Service: https://your-search-service.search.windows.net
AI Search API Key: YOUR_API_KEY
App Service (Backend & Frontend): https://aisearch-app.azurewebsites.net

3️⃣ Run Locally (Optional)

If you want to run the backend and frontend locally:

pip install -r requirements.txt
uvicorn main:app --reload

Then open http://127.0.0.1:8000/ to access the frontend.


4️⃣ Search API Endpoint

GET /search?query=your-search-term

Example:

curl "https://aisearch-app.azurewebsites.net/search?query=Azure AI"

📜 Project Structure

.
│
├── search-service
│   ├── main.py               # FastAPI backend
│   ├── requirements.txt      # Dependencies
│   └── frontend/
│       └── index.html        # Minimal HTML/JS frontend
│
├── ingestion-pipeline/
│   ├── requirements.txt      # Dependencies
│   ├── ingestion.py          # Python script to process S3 data
│   └── document-store/
│       └── generate_docs.py  # Script for generating dummy docs from topics
│       └── dummy_documents/  
│           └── ...           # Generated documents live here
│
├── deploy.sh                 # Shell script to set up Azure resources
└── README.md                 # This file

📌 Summary

This project provides a fully functional, minimal setup for experimenting with Azure AI Search and vector search. 🚀 It’s designed to be simple, effective, and easy to deploy.


About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published