A production-grade, permission-aware RAG copilot built with .NET 10 and Aspire 13, a Next.js 16 generative UI, and a Python RAGAS evaluation harness. Users ask questions over company documents and get streamed, cited answers built only from documents they are allowed to read. Charts, tables and approval-gated actions are rendered as UI widgets.
It is also a learning project: every part is built step by step with a coding agent, from prompts that are written, explained and reviewed as part of the repo, so you learn the system and prompt engineering together.
Free (local OSS, $0) |
Azure (managed, ~$10–25/month) |
|
|---|---|---|
| LLM + embeddings | Ollama | Azure OpenAI |
| Vector + keyword search | Qdrant (dense + sparse) | Azure AI Search (Free tier) |
| Reranker | TEI cross-encoder | TEI container on Container Apps |
| Metadata DB | PostgreSQL | Azure SQL (free offer) |
| Blob + queue | Azurite | Azure Storage |
| Parsing | Markdown built-in + docling-serve | Markdown built-in + Document Intelligence F0 |
| Identity | Keycloak | Entra ID |
| Run with | make dev (Aspire) or docker compose |
Bicep + GitHub Actions to Container Apps |
The profile is a configuration switch; application code depends only on ports (see architecture §6).
| docs/README.md | Index and reading order |
| docs/project-overview.md | Guided architecture overview, current Steps 0–1, and how ASP.NET Core, Aspire, and containers work together |
| docs/architecture.md | Full architecture with C4 views, data model and sequence diagrams |
| docs/decisions.md | Architecture decision records |
| docs/prompt-engineering.md | How to prompt coding agents: principles P1–P12, template, anti-patterns |
| docs/steps/README.md | Roadmap: 13 steps, each with a plan and a copy-paste prompt |
| Step | Delivers | Prompt technique |
|---|---|---|
| 0 | Scaffold, AppHost, CI, Makefile | Scoping by naming; non-goals |
| 1 | Shared contracts and codegen | Single source of truth |
| 2 | Ports, fakes, profile wiring | Interface-first prompting |
| 3 | Ingestion pipeline with ACLs | Invariants and failure scenarios |
| 4 | Hybrid retrieval + rerank | Test oracles |
| 5 | Streaming chat API, tools, approvals | Protocol-exact examples |
| 6 | RAGAS eval harness and CI gate | Precise metric definitions |
| 7 | Next.js generative UI | Enumerating UI states |
| 8 | Auth and multi-tenancy | Threat-model prompting |
| 9 | OpenTelemetry, GenAI spans, cost | Naming conventions as constraints |
| 10 | Docker Compose packaging | Environment parity |
| 11 | Azure deployment | Guardrails and human gates |
| 12 | Load tests, limits, safe caching | Measure first |
Planning complete; implementation starts at Step 0.
A .NET port of the Python plan in rajair/knowledge-copilot.
See LICENSE.