{"id":81177,"date":"2026-08-27T10:17:17","date_gmt":"2026-08-27T04:47:17","guid":{"rendered":"https:\/\/www.tothenew.com\/blog\/?p=81177"},"modified":"2026-09-01T15:53:32","modified_gmt":"2026-09-01T10:23:32","slug":"building-intelligent-net-applications-with-microsoft-foundry-beyond-basic-chatbot-integration","status":"publish","type":"post","link":"https:\/\/www.tothenew.com\/blog\/building-intelligent-net-applications-with-microsoft-foundry-beyond-basic-chatbot-integration\/","title":{"rendered":"Building Intelligent .NET Applications with Microsoft Foundry: Beyond Basic Chatbot Integration"},"content":{"rendered":"<h2>Introduction<\/h2>\n<p>Artificial Intelligence is rapidly becoming a key component of modern enterprise applications, enabling businesses to automate workflows, understand documents, perform intelligent searches, and deliver personalized user experiences. However, building production-ready AI solutions involves much more than integrating an AI model\u2014it requires seamless integration with existing .NET architectures while ensuring security, scalability, reliability, and governance. Microsoft Foundry addresses these challenges by providing a unified platform that combines AI models, enterprise search, document intelligence, AI agents, and built-in governance, empowering .NET developers to build secure, scalable, and intelligent enterprise applications.<\/p>\n<h2>Why a direct model call is not enough<\/h2>\n<p>A basic AI integration may look like this :<\/p>\n<div id=\"attachment_81152\" style=\"width: 152px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81152\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81152 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Basic_AI_Integration-300x91.png\" alt=\"Basic AI Integration\" width=\"142\" height=\"43\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Basic_AI_Integration-300x91.png 300w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Basic_AI_Integration-768x233.png 768w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Basic_AI_Integration-624x190.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Basic_AI_Integration.png 862w\" sizes=\"(max-width: 142px) 100vw, 142px\" \/><p id=\"caption-attachment-81152\" class=\"wp-caption-text\">Basic AI Integration<\/p><\/div>\n<p>This approach works for demonstrations and general-purpose content generation. However, the model usually does not know:<\/p>\n<ul>\n<li style=\"list-style-type: none;\">\n<ul>\n<li>Your latest business data<\/li>\n<li>Internal policies and documents<\/li>\n<li>User-specific information<\/li>\n<li>Application authorization rules<\/li>\n<li>Whether its response is factually correct<\/li>\n<li>A production-ready application normally needs retrieval, validation, security, monitoring, and business-service integration around the model.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<div id=\"attachment_81155\" style=\"width: 255px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81155\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81155 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Advanced_AI_Integration-1-300x104.png\" alt=\"Advanced AI Integration\" width=\"245\" height=\"85\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Advanced_AI_Integration-1-300x104.png 300w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Advanced_AI_Integration-1-768x267.png 768w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Advanced_AI_Integration-1-624x217.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Advanced_AI_Integration-1.png 867w\" sizes=\"(max-width: 245px) 100vw, 245px\" \/><p id=\"caption-attachment-81155\" class=\"wp-caption-text\">Advanced AI Integration<\/p><\/div>\n<p>The model is therefore one part of the application rather than the complete application.<\/p>\n<h2>Why a direct model call is not enough<\/h2>\n<p>The following simplified example uses the OpenAI-compatible client with Microsoft Entra authentication. For new Azure OpenAI applications, Microsoft recommends considering the Responses API instead of starting with the older Chat Completions API.<\/p>\n<div id=\"attachment_81157\" style=\"width: 240px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81157\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81157 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/OpenAI-compatible_clinet_code-300x210.png\" alt=\"OpenAI Client Code\" width=\"230\" height=\"161\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/OpenAI-compatible_clinet_code-300x210.png 300w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/OpenAI-compatible_clinet_code-768x539.png 768w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/OpenAI-compatible_clinet_code-624x438.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/OpenAI-compatible_clinet_code.png 868w\" sizes=\"(max-width: 230px) 100vw, 230px\" \/><p id=\"caption-attachment-81157\" class=\"wp-caption-text\">OpenAI Client Code<\/p><\/div>\n<p>In a real application, this code should be placed behind an application service rather than directly inside a controller.<\/p>\n<div id=\"attachment_81160\" style=\"width: 251px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81160\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81160 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/OpenAI-compatible_clinet_code_placement-300x71.png\" alt=\"OpenAI Client Code Placement\" width=\"241\" height=\"57\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/OpenAI-compatible_clinet_code_placement-300x71.png 300w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/OpenAI-compatible_clinet_code_placement-768x182.png 768w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/OpenAI-compatible_clinet_code_placement-624x148.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/OpenAI-compatible_clinet_code_placement.png 865w\" sizes=\"(max-width: 241px) 100vw, 241px\" \/><p id=\"caption-attachment-81160\" class=\"wp-caption-text\">OpenAI Client Code Placement<\/p><\/div>\n<p>This abstraction makes it easier to:<\/p>\n<ul>\n<li style=\"list-style-type: none;\">\n<ul>\n<li>Replace or upgrade models<\/li>\n<li>Add retries and timeouts<\/li>\n<li>Record token consumption<\/li>\n<li>Apply content filtering<\/li>\n<li>Test business logic without calling the model<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h2>Retrieval-Augmented Generation<\/h2>\n<p>One of the most useful patterns for enterprise AI is Retrieval-Augmented Generation, commonly known as RAG.<\/p>\n<p>Instead of asking a model to answer from its general training knowledge, the application first retrieves relevant information from an approved knowledge source.<\/p>\n<div id=\"attachment_81167\" style=\"width: 214px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81167\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81167 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Retrieval-Augmented_Generation-300x137.png\" alt=\"Retrieval-Augmented Generation\" width=\"204\" height=\"93\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Retrieval-Augmented_Generation-300x137.png 300w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Retrieval-Augmented_Generation-768x351.png 768w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Retrieval-Augmented_Generation-624x285.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Retrieval-Augmented_Generation.png 867w\" sizes=\"(max-width: 204px) 100vw, 204px\" \/><p id=\"caption-attachment-81167\" class=\"wp-caption-text\">Retrieval-Augmented Generation<\/p><\/div>\n<p>Azure AI Search supports full-text, vector, hybrid, and multimodal retrieval. A vector index stores numerical representations of content so that semantically similar information can be found even when the words are different.<\/p>\n<p>For example, these requests express a similar intent:<\/p>\n<div id=\"attachment_81168\" style=\"width: 226px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81168\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81168 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Example_Request-300x32.png\" alt=\"Example Request\" width=\"216\" height=\"23\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Example_Request-300x32.png 300w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Example_Request-768x83.png 768w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Example_Request-624x67.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Example_Request.png 862w\" sizes=\"(max-width: 216px) 100vw, 216px\" \/><p id=\"caption-attachment-81168\" class=\"wp-caption-text\">Example Request<\/p><\/div>\n<p>A keyword-only search may treat them differently. Vector search can identify their semantic similarity.<\/p>\n<h2>A practical enterprise workflow<\/h2>\n<p>Consider an invoice-processing application built with ASP.NET Core.<\/p>\n<div id=\"attachment_81165\" style=\"width: 236px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81165\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81165 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Enterprise_Workflow-300x223.png\" alt=\"Enterprise Workflow\" width=\"226\" height=\"168\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Enterprise_Workflow-300x223.png 300w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Enterprise_Workflow-768x570.png 768w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Enterprise_Workflow-624x463.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Enterprise_Workflow.png 862w\" sizes=\"(max-width: 226px) 100vw, 226px\" \/><p id=\"caption-attachment-81165\" class=\"wp-caption-text\">Enterprise Workflow<\/p><\/div>\n<p>The AI component performs extraction and classification, while deterministic .NET services continue to enforce business rules. This separation is important because probabilistic AI output should not directly replace critical validation logic.<\/p>\n<h2>Simplified vector-search example<\/h2>\n<p>Assume that an embedding has already been generated for the user&#8217;s question:<\/p>\n<div id=\"attachment_81169\" style=\"width: 254px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81169\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81169 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Simplified_vector-search-282x300.png\" alt=\"Simplified vector-search example\" width=\"244\" height=\"259\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Simplified_vector-search-282x300.png 282w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Simplified_vector-search-624x663.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Simplified_vector-search-24x24.png 24w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Simplified_vector-search.png 718w\" sizes=\"(max-width: 244px) 100vw, 244px\" \/><p id=\"caption-attachment-81169\" class=\"wp-caption-text\">Simplified vector-search example<\/p><\/div>\n<p>For production workloads, hybrid search is often preferable because it combines keyword matching and vector similarity rather than relying entirely on one retrieval method. Azure AI Search supports both precomputed embeddings and integrated vectorization during indexing.<\/p>\n<h2>A practical enterprise workflow<\/h2>\n<p>Consider an invoice-processing application built with ASP.NET Core.<\/p>\n<div id=\"attachment_81165\" style=\"width: 263px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81165\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81165 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Enterprise_Workflow-300x223.png\" alt=\"Enterprise Workflow\" width=\"253\" height=\"188\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Enterprise_Workflow-300x223.png 300w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Enterprise_Workflow-768x570.png 768w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Enterprise_Workflow-624x463.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Enterprise_Workflow.png 862w\" sizes=\"(max-width: 253px) 100vw, 253px\" \/><p id=\"caption-attachment-81165\" class=\"wp-caption-text\">Enterprise Workflow<\/p><\/div>\n<p>The AI component performs extraction and classification, while deterministic .NET services continue to enforce business rules. This separation is important because probabilistic AI output should not directly replace critical validation logic.<\/p>\n<h2>Where AI agents fit<\/h2>\n<p>Agents are useful when a workflow requires the model to choose tools, retrieve information, and complete multiple connected steps.<\/p>\n<p>For example, a support agent might:<\/p>\n<ul>\n<li style=\"list-style-type: none;\">\n<ul>\n<li>Classify a customer request.<\/li>\n<li>Search the knowledge base.<\/li>\n<li>Retrieve account information.<\/li>\n<li>Check an internal policy.<\/li>\n<li>Draft a response.<\/li>\n<li>Escalate when confidence is low.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<div id=\"attachment_81163\" style=\"width: 273px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81163\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81163 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/AI_agents_fit-300x131.png\" alt=\"AI agents fit\" width=\"263\" height=\"115\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/AI_agents_fit-300x131.png 300w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/AI_agents_fit-768x335.png 768w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/AI_agents_fit-624x272.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/AI_agents_fit.png 868w\" sizes=\"(max-width: 263px) 100vw, 263px\" \/><p id=\"caption-attachment-81163\" class=\"wp-caption-text\">AI agents fit<\/p><\/div>\n<p>Agents should not be introduced merely because they are currently popular. A normal service workflow is often more predictable, faster, and cheaper. Agents provide value when the sequence of actions cannot be fully determined in advance.<\/p>\n<h2>Recommended .NET architecture<\/h2>\n<p>A maintainable solution could use the following separation:<\/p>\n<div id=\"attachment_81161\" style=\"width: 263px\" class=\"wp-caption alignnone\"><img aria-describedby=\"caption-attachment-81161\" decoding=\"async\" loading=\"lazy\" class=\"wp-image-81161 \" src=\"https:\/\/www.tothenew.com\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Recommended_NET_architecture-300x172.png\" alt=\"Recommended .NET architecture\" width=\"253\" height=\"145\" srcset=\"\/blog\/wp-ttn-blog\/uploads\/2026\/08\/Recommended_NET_architecture-300x172.png 300w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Recommended_NET_architecture-768x439.png 768w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Recommended_NET_architecture-624x357.png 624w, \/blog\/wp-ttn-blog\/uploads\/2026\/08\/Recommended_NET_architecture.png 871w\" sizes=\"(max-width: 253px) 100vw, 253px\" \/><p id=\"caption-attachment-81161\" class=\"wp-caption-text\">Recommended .NET architecture<\/p><\/div>\n<p>This prevents Azure SDK types and prompt-specific logic from spreading across controllers and domain services.<\/p>\n<h2>Conclusion<\/h2>\n<p>Microsoft Foundry enables .NET teams to build applications that can generate content, understand documents, retrieve enterprise knowledge, and coordinate intelligent workflows.<\/p>\n<p>The real value does not come from adding a chat window to an existing application. It comes from combining AI capabilities with sound software architecture:<\/p>\n<ul>\n<li style=\"list-style-type: none;\">\n<ul>\n<li>Use models for reasoning and language tasks.<\/li>\n<li>Use Azure AI Search to ground answers in trusted data.<\/li>\n<li>Use Document Intelligence for structured document extraction.<\/li>\n<li>Keep business validation deterministic.<\/li>\n<li>Add agents only when dynamic tool orchestration is genuinely required.<\/li>\n<li>Build security, observability, and human review into the solution from the beginning.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Introduction Artificial Intelligence is rapidly becoming a key component of modern enterprise applications, enabling businesses to automate workflows, understand documents, perform intelligent searches, and deliver personalized user experiences. However, building production-ready AI solutions involves much more than integrating an AI model\u2014it requires seamless integration with existing .NET architectures while ensuring security, scalability, reliability, and governance. [&hellip;]<\/p>\n","protected":false},"author":2218,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"iawp_total_views":1},"categories":[5867],"tags":[7046,8872,8876,8873,8877,6723,8878,6966,7988,5918,6570,8658],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/81177"}],"collection":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/users\/2218"}],"replies":[{"embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/comments?post=81177"}],"version-history":[{"count":4,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/81177\/revisions"}],"predecessor-version":[{"id":82006,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/81177\/revisions\/82006"}],"wp:attachment":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/media?parent=81177"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/categories?post=81177"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/tags?post=81177"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}