Articles
Building AI agents with .NET and the cloud — 61 guides · page 2 of 4.
Agent Skills for .NET: A Practical Guide
Agent Skills for .NET is now stable in the Microsoft Agent Framework. Learn how to package, distribute, and govern agent skills in C#, with working code.
Foundry IQ and Agent Memory: Managed RAG and Memory for .NET Agents
Foundry IQ gives .NET agents serverless retrieval, knowledge bases, and managed memory. What it replaces in your RAG stack, and when to keep pgvector.
Hosted Agents in Foundry Agent Service: A .NET Developer's Guide
Hosted agents in Foundry Agent Service are GA: per-session sandboxes, scale-to-zero, and a simple path to deploy Microsoft Agent Framework agents from .NET.
What BUILD 2026 Means for .NET Agent Developers
Build 2026 for .NET agent developers: Agent Harness, Hosted Agents, Agent Skills, CodeAct, and Foundry IQ memory — what shipped, why it matters, what to do.
Using the Anthropic Claude API in C#
How to call Anthropic's Claude models from C#: authenticate, send a message, stream the response, and use Claude through the provider-agnostic Microsoft.Extensions.AI abstraction.
Azure OpenAI vs OpenAI: Which Should .NET Developers Use?
Azure OpenAI or the OpenAI API? A clear comparison for .NET developers — on data residency, authentication, models, and cost — with a straight recommendation.
Caching LLM Responses in .NET
LLM calls are slow and cost money. Add caching to your .NET AI app — response caching and prompt caching — to cut latency and spend without losing quality.
Build a "Chat with your PDF" App in .NET
Let users ask questions about a PDF and get grounded answers. Build a chat-with-your-documents app in C# using extraction, embeddings, and retrieval-augmented generation.
Content Moderation and Guardrails for .NET AI Apps
User input and AI output both need checking. How to add content moderation and guardrails to a .NET AI app — filtering unsafe input, output, and enforcing scope.
How to Count Tokens in C#
Tokens drive LLM cost and context limits. How to count tokens in C# with a tokenizer, estimate cost before a call, and keep prompts under the model's limit.
Embeddings in .NET, Explained
What are embeddings, and how do you generate and use them in C#? A clear, practical explanation of vector embeddings for .NET developers — with code and use cases.
Using Google Gemini in C# and .NET
How to call Google's Gemini models from C#: get an API key, send a prompt, stream responses, and use Gemini through a provider-agnostic interface in .NET.
Microsoft.Extensions.AI: The .NET AI Abstraction, Explained
Microsoft.Extensions.AI gives .NET one common interface for every AI provider. What IChatClient and IEmbeddingGenerator are, why they matter, and how to use them.
How to Use Function Calling with OpenAI in C#
Function calling lets an OpenAI model trigger your C# code. A step-by-step guide to defining functions, letting the model call them, and returning the result — in .NET.
Vector Search in .NET with pgvector and PostgreSQL
You do not need a new database for vector search. Use pgvector in PostgreSQL from .NET to store embeddings and run similarity queries — with the database you already run.
Prompt Engineering for .NET Developers
Prompt engineering, minus the hype. Practical techniques .NET developers can use to get reliable, consistent output from an LLM — with C# examples.
Chunking Strategies for RAG (with .NET Examples)
Bad chunking is the #1 reason RAG underperforms. A practical guide to chunking strategies — size, overlap, and structure-aware splitting — for .NET RAG apps.
Resilient LLM Calls in .NET with Polly
LLM APIs rate-limit, time out, and hiccup. Make your .NET AI calls resilient with Polly — retries with backoff, circuit breakers, and timeouts done right.
Building Semantic Search in C# with Embeddings
Keyword search misses meaning. Build semantic search in C# using embeddings and vector similarity, so queries match by intent — not just matching words.
Serverless AI: Deploy an OpenAI Endpoint with Azure Functions
Host an AI endpoint that scales to zero and costs nothing when idle. Build and deploy a serverless OpenAI-powered API in .NET with Azure Functions.