Table of Contents....5
About the Author....10
About the Technical Reviewer....11
Acknowledgments....12
Chapter 1: Introduction to .NET MAUI....13
Introduction....13
.NET....15
.NET MAUI....16
.NET MAUI Focus....17
Prepare Your Development Environment....20
Visual Studio Setup....21
Create Your .NET MAUI Application....22
Summary....24
Chapter 2: Introduction to AI....26
Introduction....26
AI Is Everywhere....27
AI Models....29
Overview of AI Services (Azure AI, Google AI, OpenAI)....30
Azure AI....31
Google AI....32
OpenAI....32
Summary....33
Chapter 3: Integrating AI Capabilities in .NET MAUI....34
Introduction....34
How to Call REST APIs in .NET MAUI....34
Understand How to Use AI APIs, Handle Authentication, and How to Handle Responses....39
How to Process AI-Generated Content....40
How to Integrate Azure AI....45
How to Integrate Google AI....57
How to Integrate OpenAI....60
Summary....64
Chapter 4: Sentiment Analysis....65
Introduction....65
Linguistics and Feelings....65
Azure AI Language Service....67
Create the Service....71
Use the Service in Your App....74
Our AI Assistant....81
Summary....81
Chapter 5: AI-Powered Chatbots....82
Introduction....82
Chatbots....82
Prompts....83
Integrate an Azure Chatbot....83
Integrate ChatGPT....88
Integrate Gemini Chatbot....105
Custom UI AI Chatbot....111
Improve UX and UI for Your Chatbot....115
Summary....116
Chapter 6: AI-Based Image Capabilities....117
Introduction....117
Inside an Image....117
Generate Image Description....118
Detect Object Inside Images....132
Your Photos, Your Power....141
Summary....143
Chapter 7: OCROptical Character Recognition....144
Introduction....144
Detect Handwritten Notes....145
Detect Text Inside a Picture....154
Summary....157
Chapter 8: Voice App with Speech Recognition....158
Introduction....158
Voice or Text?....158
Speech Recognition....159
From Text to Speech....173
Summary....177
Chapter 9: AI-Powered Translations....178
Introduction....178
Lost in Translation....178
How AI Translation Works....179
Azure AI Translation....180
Summary....194
Chapter 10: AI-Powered Content Summarizer....195
Introduction....195
Beyond ChatGPT....195
OpenAI Models....196
Content Summarizer....196
Integrate a Content Summarizer in a .NET MAUI Application....197
Summary....207
Chapter 11: Let Google Gemini Search into Your .NET MAUI App....208
Introduction....208
Google Search....208
Google Gemini....210
Retrieval-Augmented Generation....210
Add Gemini to a .NET MAUI App....213
Summary....226
Chapter 12: Edge AI and Offline AI Models....227
Introduction....227
Edge AI....227
Local AI Devices....228
Edge AI and .NET MAUI....229
Create Your AI Model....231
Summary....248
Chapter 13: Ethical Considerations with AI and AI Applications....249
Introduction....249
Ethics....249
Ethics and AI....250
UNESCO Ethical Compass....251
AI Regulations Around the World....253
Big Tech Companies and Responsible AI....254
AI Pope Act....255
Considerations....256
Summary....256
Chapter 14: Security Standards and AI....257
Introduction....257
API Calls....258
Secure Storage....262
Data Encryption....264
Authentication and Authorization....265
Input Validation....265
Check Your Logs....266
Check for Updates....266
Privacy and Compliance....267
Obfuscation....271
Dev-Friendly App Security Checklist....272
Summary....272
Chapter 15: Deploying AI-Powered .NET MAUI Apps....274
Introduction....274
Dont Forget to Test Your Application....274
AI-Specific Checks....276
Check Your App Accessibility....276
Check App Permissions....277
Get Your Assets Ready....279
Your Apps Metadata Is Who You Are....279
Get Your Certificates....280
Prepare Your Accounts and Packages....280
Conquer the World with Your App....282
Summary....282
Chapter 16: Conclusion....284
Index....287
Learn to build AI-powered cross-platform applications using .NET MAUI. Designed for developers of all levels, this book offers a structured, project-based approach to integrating artificial intelligence into modern applications that run on Android, iOS, Windows, and macOS from a single codebase.
As artificial intelligence continues to transform software development, understanding how to effectively integrate AI services into applications has become an essential skill. The growing demand for intelligent, data-driven applications makes this knowledge highly relevant for developers seeking to enhance user experiences, automate processes, and leverage AI capabilities in real-world scenarios. Simultaneously, .NET MAUI is emerging as the leading framework for cross-platform development in the .NET ecosystem, enabling developers to create powerful applications with a native experience across multiple devices. By the end of this book, developers will have gained the technical expertise and practical experience needed to integrate AI into their applications efficiently.
Whether you are an experienced MAUI developer aiming to expand your skill set or someone new to AI-powered development, this book will equip you with the tools and knowledge to build smarter, more efficient applications in today’s rapidly evolving tech landscape.