
Understand how large language models process text into tokens, guided by prompts and context, producing probabilistic responses via APIs. Design effective prompts and manage temperature to build robust .NET applications.
Build a simple console chatbot in .NET that uses AI with OpenAI, includes streaming text, and demonstrates context-aware responses.
Build a console app, obtain an OpenAI API key, install the OpenAI SDK via NuGet, and use a chat client to query a model like GPT 5.4 nano for testing.
Learn how to add conversation history to a chat bot by passing the full list of user and assistant chat messages to the AI, giving it context for coherent responses.
Explore how system prompts shape model behavior in .NET and other languages, preventing markdown formatting and enforcing plain text responses through practical examples.
Explore streaming the response to display model text as it arrives, improving perceived speed, while coding for continuous updates, history handling, and using a string builder to preserve context.
This lecture demonstrates building a Claude-based chatbot in .NET using Anthropic Cloth, including installing the SDK, configuring API keys, selecting Haiku, streaming responses, and comparing with OpenAI implementations.
Explore communicating with models via APIs by sending HTTP POST requests without SDKs. Send JSON payloads with system prompts, user prompts, reasoning, and responses using a C# HTTP client.
Explore the fundamentals of artificial intelligence, including learning, reasoning, pattern recognition, and decision making, and examine generative artificial intelligence, large language models, prompts, system prompts, message rules, hallucination, and chatbots.
Design systems with provider abstraction to decouple AI models from specific providers using Microsoft Extensions AI, enabling seamless provider switches and consistent interactions across OpenAI, Anthropic, and Google.
Centralize iChatClient creation with dependency injection in a console app using Microsoft.Extensions.Hosting and NuGet, configuring services to select OpenAI, Anthropic, or Cloud providers and models via command-line arguments.
Create a middleware for iChatClient in .NET to intercept prompts before and after sending them to the model, enabling visibility into messages and an optional cache layer within the pipeline.
Use chat options to centralize model behavior in .NET, set max output tokens, and distinguish input from output tokens. Adjust temperature to 0.7 for OpenAI and cloud models.
Explore the Microsoft Extensions AI library to create abstractions for AI models from providers, like OpenAI, and expose a client interface for sending messages to LLM and receiving responses.
Discover tooling to let ai perform actions, like querying databases and sending emails, beyond answering questions. Learn to invoke multiple functions in sequence, handle user confirmations, and reduce errors.
Expose a weather fetch function to the AI model, using a fake weather service and getWeather tool, with function invocation enabled for city queries like santo domingo and madrid.
Define a special tool that requires user approval before actions like sending emails. Implement an approval flow in a .NET chatbot with fake email services and actionable tool descriptions.
Master how to handle tool errors in a chatbot by reading exception messages and proposing fixes to retry tool invocations.
Explore tooling and tool calling, where an ai model invokes user-defined functions with parameters, uses results to proceed, and applies human-in-the-loop oversight and error handling for exceptions.
Migrate the chatbot to a Blazor web app, enable consecutive tools with human intervention, add a data query tool, and support canceling during AI responses.
Add a tools class to the Blazor application and configure the chat client to use tools, fetching weather API key via IConfiguration and environment variables, then test Santo Domingo weather.
Add a typing indicator with three animated dots when the AI chat text is empty, signaling thinking with CSS in the chat component.
Understand how retrieval augmented generation (rach) enables llms to fetch up-to-date information from data sources, reducing hallucinations by providing relevant context through embeddings and retrieved fragments.
Explore how embeddings convert words into real-valued vectors that capture semantic relationships. Store chunked documents as embeddings in a vector database and retrieve nearest matches by vector similarity.
Store embeddings in vector databases to enable semantic search by retrieving vectors closest in multidimensional space, while indexing metadata such as source, date, author, and tags for LLM responses.
Implement a real RAG pipeline by uploading markdown files to Azure AI Search as a cloud vector database, storing embeddings and fragments for semantic search.
Implement a semantic search workflow in Azure using the Azure Search rack service, embedding generation, and vector search to retrieve and rank relevant documents from a vector database.
Explore retrieval augmented generation (RAG) that blends information retrieval with generative models to answer using external data, leveraging embeddings and vector databases for fast semantic searches and JSON-style responses.
Explore the model context protocol, MCP, which standardizes structured context, tools, resources, and prompts to let AI models query data sources and interact with external services outside prompts.
Add prompts to the MCP server by creating a prompts class and exposing four prompts: get all, get by ID, activate, and deactivate, then verify in the MCP inspector.
Publish the MCP server to production by adding an api controller with a get all endpoint and enabling controllers. Test by updating Gloria's status via the MCP inspector.
Explore how the model context protocol enables AI to interact with external systems by defining tools, data, and prompts, separating AI logic from integrations.
Explore how local models run on your own hardware, offering privacy, control, and potential cost savings, while noting hardware demands, performance gaps, and the technical complexity of setup.
Install olama to run artificial intelligence models locally on your PC without internet or external APIs. Use PowerShell on Windows or download executable to manage models with a common interface.
Integrate Olama in a console app by installing the Olama sharp NuGet package, configuring the Olama API client with a model, and testing with a weather service and capital questions.
Integrate a local Olama model into a Blazor AI project by installing Olamasharp, configuring models via user secrets, and wiring the chat client to the Olama endpoint.
Learn how local models run on user hardware to boost privacy and data control, managing memory, storage, and performance via OLAMA for downloading and running open-source models.
Build an mvc application with separate front-end and back-end, enabling AI interactions via Angular, React, or Blazor, and support multiple conversations with separate context.
Create a SendMessageDTO with conversationId and text and an API endpoint to send messages to the AI, returning the response. Use vanilla JavaScript to post prompts and update chat UI.
Replicate the first user message as the conversation title, replacing the default new chat label. If the first message is under 60 characters, use it; otherwise trim and add ellipsis.
Learn to implement streaming in .NET by sending text and events with a stream event protocol, enabling real-time delta updates and tool approval handling.
Implement operation cancellation in a .NET AI agent using a cancellation token and an abort controller. Update the UI to disable the send button and enable cancel during processing.
Store chat messages and pending approval requests in a database to maintain full interaction history, support multiple concurrent conversations, and resume any conversation exactly where you left off.
Discover how to take your .NET applications to the next level by integrating artificial intelligence in a practical, modern, and production-ready way. In this course, you’ll learn step by step how to add AI capabilities to your applications, with minimal theory and a strong focus on real-world scenarios.
We’ll start with the basics by integrating AI into a console application, so you can understand the fundamentals of interacting with language models. From there, we’ll move on to Microsoft Extensions AI, one of the key components of the modern .NET ecosystem for working with AI in a flexible and decoupled way, allowing you to switch between providers such as OpenAI, Anthropic, or Google without rewriting your application.
As we progress, we’ll build a fully functional chatbot using ASP.NET Core. This won’t be just another text generator: we’ll implement response streaming to improve the user experience, enabling text to appear in real time without unnecessary waiting. You’ll also learn how to use tool calling, a technique that allows the AI to execute functions from your C# code, integrate with your database, or consume external APIs.
We’ll also cover more advanced scenarios, such as human-in-the-loop workflows, where the AI requests approval before performing sensitive actions like sending emails. This is essential for building secure and reliable systems in real-world environments.
In the RAG (Retrieval-Augmented Generation) module, you’ll learn how to build applications that allow AI to answer questions based on your company’s own documents. Not only that, but we’ll also implement a source citation system, increasing the reliability of responses and making it possible to verify the information being used.
Finally, we’ll explore the Model Context Protocol (MCP), where we’ll build a server that enables tools like ChatGPT or Claude to interact directly with your application. This opens the door to scenarios where users can perform real actions in your system simply through natural language.
This course is designed for .NET developers who want to learn by building real-world projects they can immediately apply to their jobs or products. You don’t need prior experience with artificial intelligence, but you should have a basic understanding of C# and ASP.NET Core.
By the end of the course, you won’t just understand how modern AI works, but also you’ll be able to integrate it effectively into your own applications, creating smarter, more automated solutions aligned with today’s industry trends.
If you want to learn how to build AI and agent-powered .NET applications, this course is for you.