Skip to content
bitzorcas
中EN

Concept

AI & Agentic Development

Comprehensive overview of BitzOrcas.Modern AI-Native architecture: turning enterprise vertical slices into Model Context Protocol (MCP) tools via compile-time source generation.

Last updated

AI & Agentic Engineering Overview

As enterprise software systems transition toward being AI-Native, equipping Large Language Models (LLMs) with actionable function-calling capabilities has become a central architectural concern. Traditional solutions often rely on hand-crafted OpenAPI documents, fragile glue controllers, or direct database connections given to agents—introducing severe interface drift, duplicate business logic, absent audit trails, and multi-tenant security leaks.

BitzOrcas.Modern adopts a fundamental architectural innovation: deep native integration of the open Model Context Protocol (MCP) standard released by Anthropic, coupled with C# compile-time Roslyn Source Generators. The framework turns existing CQRS vertical slices into standard MCP Tools with zero runtime reflection overhead and zero boilerplate glue code.


1. Architectural Paradigm: Vertical Slices as Agent Tools

In BitzOrcas, developers never build redundant, specialized API controllers for AI. Every validated, tenant-aware ICommand or IQuery protected by the Mediator pipeline can be directly declared as an AI-callable tool with a single compile-time attribute:

Mediator Pipeline & Domain CoreEnterprise Security Gate (Fail-Closed)BitzOrcas Gateway & TransportJSON-RPC 2.0 / SSEMCP Clients

Cursor IDE (Agent Mode)

Claude Desktop / Web

Antigravity / Custom Agent Frameworks

OpenResty / YARP Gateway

/mcp (Streamable HTTP / SSE)

Rate Limiting Policy (mcpPolicy)

Tenant Gate Authorization (mcpTenantAccess)

Tool Catalog Tenant Visibility Filter

Mediator Pipeline (Validation, UnitOfWork, TenantContext)

Command / Query Handler

Domain Aggregates & Storage

MCP Audit Logging (McpToolInvocationAuditor)


2. Core Pillars and Design Principles

BitzOrcas AI & Agentic development is founded upon 4 primary principles:

Core PillarTraditional PitfallBitzOrcas.Modern Solution
Metadata ExtractionRuntime assembly reflection scanning hurts startup performance and breaks Native AOTCompile-Time Roslyn Generator: BitzOrcas.Mcp.SourceGenerator extracts C# XML comments and primary constructor parameters into strict JSON Schemas during compilation.
Execution ChannelFragmented custom controllers or dedicated LLM RPC routes duplicate business rulesUnified Mediator Pipeline: Inbound MCP calls deserialize into real Command/Query messages, undergoing full validation, tenant context injection, and unit-of-work transactions.
Multi-Tenant SecurityAutonomous agents risk cross-tenant data leaks and unauthorized mutation callsFail-Closed Dual Gate: Inbound requests require active tenant entitlement (mcpTenantAccess); the catalog dynamically hides tools when a tenant lacks the required Feature.
AuditabilityMutations executed by autonomous models cannot be reliably tracked back to sessionsDedicated Audit Trail: McpToolInvocationAuditor records model session IDs, tool names, payload SHA256 hashes, duration, and execution outcomes.

3. Section Navigation

Explore the dedicated practical chapters in this section:


100%

Scroll or use controls to zoom · drag when enlarged · double-click for 100% / 200%