Security-First Decision Automation Architecture
Code Effects was designed as an embeddable infrastructure component rather than an externally hosted rule-processing service.
The engine executes directly inside your application process as a self-contained library, without requiring external execution servers, vendor-hosted APIs, cloud-managed rule runtimes, or remote decision-processing infrastructure.
Version 7 extends the same model to the entire decision lifecycle. The Rule Repository, the optional Audit library and the optional MCP server are libraries too: they run inside your own applications, on your own sign-in, against a database you own, so rule management, approvals, testing and the record of production decisions stay within the same security boundary as the decisions themselves.
This architectural model fundamentally changes the security, compliance, reliability, and operational characteristics of enterprise decision automation systems.
Embedded Execution Instead of External Processing
Many modern rule platforms operate as external services. In these architectures:
- rules are stored remotely
- evaluations occur outside the application boundary
- business data is transmitted to external runtimes
- user context leaves the local environment
- decision records are kept on vendor infrastructure
- execution depends on network connectivity
- operational availability depends on vendor infrastructure
This creates additional layers of:
- security exposure
- infrastructure dependency
- latency
- compliance complexity
- operational risk
- vendor lock-in
Code Effects takes the opposite approach. Our rules engine executes directly inside your application and infrastructure.
Your application remains fully in control of:
- rule storage
- execution flow
- data access
- security enforcement
- AI integrations
- authentication
- authorization
- auditing
- infrastructure isolation
In a stand-alone implementation, your own code stores and loads the Rule XML wherever you decide. With the Rule Repository, storage is handled for you, but in a SQL Server or PostgreSQL database that you own and operate, with database scripts that you run when you decide. Either way, Code Effects platform becomes part of your architecture rather than a dependency on somebody else’s runtime environment and security policies.
Data Never Has to Leave Your Environment
Business rules often operate on highly sensitive information:
- AI-generated assessments
- financial records
- healthcare data
- underwriting information
- customer identities
- legal workflows
- operational analytics
- internal governance systems
When external rule services are used, this information frequently needs to cross system boundaries for evaluation. Even when encrypted, transmitting operational decision data outside the primary environment introduces additional attack surfaces, compliance considerations, and governance complexity.
Code Effects avoids this entirely.
Rules execute locally against your in-memory objects and application context. Data remains under your infrastructure, networking, and security policies at all times. No external transmission is required unless explicitly implemented by your own application logic.
The same applies to the Rule Repository, Audit and the MCP server. They run inside your own application, on your sign-in and permissions, and no Code Effects component calls a Code Effects service. When Audit records a production evaluation, the values it read are written to a local journal and then to your own database, and your application can record all values read or only the values you select. The only data that leaves your environment is what the Rule Repository's optional AI features send to the AI provider you configure.
AI Integration Without External Rule Processing
Version 6 introduced Adaptive Source and Prompt-enabled rule elements for integrating AI into deterministic business rules. Version 7 adds the AI Rule Editor and the AI Assistant to the Rule Repository, and the MCP server for external AI agents. Importantly, the presence of AI does not change the underlying architecture. The AI features use the models your application registers, with your own API keys, and organizations still retain full control over:
- AI providers
- model hosting
- inference infrastructure
- prompt handling
- execution policies
- security boundaries
- data routing
Code Effects does not force AI requests through vendor-managed orchestration layers or externally hosted rule runtimes. Your team decides:
- whether AI is used
- which models are used
- where inference occurs
- which data can be exposed
- how prompts are constructed
- how AI outputs are validated
- which users may work with AI, and what it may do on their behalf
This preserves security and governance consistency even in AI-assisted decision systems.
AI in the Rule Repository works under the permissions of the person using it, and AI agents connected through the MCP server sign in through your application's own OAuth authentication, so credentials are handled by authentication rather than passed to individual tools. Every rule written by AI is checked against its structure and its source object, and structurally invalid logic is rejected with validation feedback. Structural validity guarantees that a rule is well formed and compatible with your data; whether it expresses the intended business policy is still confirmed by testing and review.
On top of request permissions, AI agents and services can never delete, approve, make a rule version live or take it offline, even if your application grants those permissions by mistake. Every rule an AI saves requests a person's approval, and tests that would call production code require confirmation from the person using the agent.
Security Boundaries Remain Under Your Control
Code Effects platform does not impose:
- vendor-hosted execution endpoints
- forced cloud synchronization
- external telemetry pipelines
- remote evaluation APIs
- centralized runtime authorization
- externally managed rule repositories
- a separate user directory or password store
This means your security model remains entirely under your control.
Organizations can integrate Code Effects into existing:
- authentication systems
- identity providers
- zero-trust architectures
- audit pipelines
- SIEM environments
- internal governance frameworks
- compliance controls
- network segmentation strategies
without adapting security boundaries around third-party runtime infrastructure.
The Rule Repository has no users or passwords of its own. Your application tells it who the current user is and what that user may do on every request, from a set of 37 permissions that can reflect your organization's identities, roles and access policies. Permissions are enforced in the interface, where unavailable actions are disabled, and on the server, where unauthorized requests are rejected. Notifications keep your application informed of approvals and other repository events, so they can flow into your existing processes.
Built for Strict Application Security
The browser components are designed for demanding security environments. The Rule Editor and the Rule Repository provide:
- names, descriptions and values always rendered as text
- an interface built without HTML strings
- support for pages that enforce Trusted Types
- support for a Content Security Policy without inline styles
- an anti-forgery token on every Rule Repository request
- configurable limits on request sizes and counts
- dependency-free npm packages built on modern JavaScript modules
Together with request-level authorization, these protections let the Rule Repository run inside applications that already enforce strict browser security policies, without relaxing them.
Reduced Attack Surface
Every external service introduced into an application architecture expands the operational attack surface. External decision-processing systems may introduce risks related to:
- exposed APIs
- credential management
- service authentication
- token leakage
- runtime interception
- network attacks
- third-party outages
- cross-tenant vulnerabilities
Embedded execution dramatically reduces these exposure points. Code Effects engine executes under the same application process, security context, and infrastructure protections already established for your platform. This simplifies both architecture and security review processes.
The version 7 components follow the same principle. The Rule Repository is placed in one element of a page in your own web application and served by an endpoint of that application, Audit runs inside your production applications, and the MCP server is added to your own ASP.NET Core application. There is no separate Code Effects service to expose, patch, authenticate against or monitor, and no other tenant shares your rules or your decision records.
Rule content itself is controlled too. A rule is built only from the members of its source object, and the server checks every rule again against its source object before it becomes Rule XML, including checks for circular references between rules, so every saved rule is structurally valid, whether a person, a script or an AI agent wrote it.
Assembly Whitelisting for Evaluation Security
Version 6 also introduced Assembly Whitelisting feature as an additional security layer for rule evaluation.
When enabled through evaluation options passed to the Evaluate() method, the engine enforces a whitelist of trusted assemblies that are allowed to declare fields, enums, in-rule methods, and rule actions.
During rule execution, if the engine encounters a referenced type whose declaring assembly is not included in the approved whitelist, the evaluation process immediately throws an exception and terminates further execution.
This mechanism allows organizations to explicitly restrict rule evaluation to approved internal libraries, assemblies, or service layers.
Importantly, this validation occurs during rule evaluation itself, providing runtime enforcement rather than relying solely on design-time controls or UI restrictions. It protects production regardless of who or what wrote the rule, which matters more as AI agents take part in rule authoring.
The result is an additional layer of operational protection for environments where rule execution security, governance, and infrastructure isolation are treated as critical architectural requirements.
Controlled Changes to Production Logic
Security also means controlling who can change the logic that decides real business outcomes. With the Rule Repository, production changes follow an explicit decision workflow:
- every saved change creates an immutable rule version
- versions can be submitted for approval, approved, declined or revoked
- each rule has at most one live version: the version your application evaluates
- Go Live, Take Offline and approval actions require a typed confirmation
- your application decides which of its users may take each step
- every change is recorded with who made it and when, including the person an AI agent acted for
Your production code loads the live versions of your rules, together with the rules they depend on, as a complete ruleset. Logic that has not been deliberately approved and published does not reach production.
Compatible With Isolated and Air-Gapped Environments
Certain environments cannot depend on externally hosted execution systems. Examples include:
- government systems
- defense environments
- healthcare infrastructure
- critical manufacturing systems
- financial institutions
- classified networks
- industrial automation
- disconnected operational environments
Because Code Effects operates entirely as an embedded library, the platform works naturally in:
- isolated deployments
- offline environments
- air-gapped systems
- restricted-access networks
- sovereign cloud architectures
- hybrid infrastructures
without requiring external connectivity for rule execution. The Rule Repository and Audit work against your own database in the same isolated network; only the optional AI features need a connection, and only to the AI provider you configure.
This is increasingly important as organizations tighten infrastructure governance and data sovereignty requirements.
Lower Latency and Higher Reliability
External rule services inherently introduce network overhead. Even highly optimized API-based architectures still depend on:
- outbound requests
- serialization
- transport latency
- remote processing
- service availability
- retry strategies
- distributed failure handling
Embedded execution eliminates these layers. In Code Effects, rules are compiled into IL and execute locally within the application runtime, enabling:
- lower latency
- deterministic execution timing
- higher throughput
- reduced operational complexity
- fewer infrastructure dependencies
This becomes especially important in:
- high-frequency transaction systems
- real-time decision processing
- low-latency operational workflows
- large-scale evaluation pipelines
- industrial automation scenarios
where external processing overhead becomes operationally significant.
Recording decisions does not reintroduce that overhead. Audit writes each record to a local journal first and transfers it to the database with a background worker, so by default a decision never waits for a database write.
Better Alignment With Compliance Requirements
Modern compliance frameworks increasingly focus on:
- data residency
- processing transparency
- auditability
- decision explainability
- operational ownership
- infrastructure control
- vendor risk reduction
- AI governance
- access isolation
Because Code Effects executes entirely within customer-controlled infrastructure, organizations maintain complete visibility into:
- where rules execute
- where data resides
- how decisions are processed
- how AI integrations are implemented
- how prompts are handled
- how operational access is governed
Version 7 adds the evidence that compliance reviews ask for. Audit records when each production decision was made and for whom, the exact rule and source versions, the values read, the branch taken and the actions that followed. In the Rule Repository, any recorded decision can be replayed step by step and explained, and turned into a test using the actual production data. Immutable versions, approvals and activity records show which logic was in force, who approved it, and when it went live.
This significantly simplifies compliance alignment for frameworks such as:
- HIPAA
- SOC 2
- ISO 27001
- GDPR
- FedRAMP-related environments
- internal governance policies
and similar regulatory or enterprise security programs.
Infrastructure Ownership as a Security Strategy
Security is not only about encryption and authentication. It is also about ownership and control. By operating as an embeddable library instead of an external service, Code Effects allows organizations to retain ownership of:
- runtime execution
- operational policies
- deployment architecture
- infrastructure boundaries
- data handling
- rule and decision history
- AI integrations
- compliance strategy
- system availability
The result is a decision automation platform designed for organizations that treat security, compliance, and infrastructure governance as architectural requirements rather than optional deployment considerations.