Compliance
Design AI systems that respect legal, privacy, and industry requirements.
Compliance
AI systems increasingly support healthcare, finance, education, retail, employment, government, and other important activities. These solutions may process sensitive information or influence decisions that affect people, so they must operate within applicable legal, regulatory, contractual, industry, and organizational requirements.
Compliance is a core architecture concern because obligations affect what data may be collected, where processing may occur, which explanations or reviews are required, how long records must be kept, and which controls and evidence must exist throughout the system lifecycle.
What Is AI Compliance?
AI compliance is the process of identifying applicable obligations, converting them into clear requirements, implementing controls, collecting evidence, validating effectiveness, and maintaining conformity as the AI system and its environment change.
- Laws and regulations in each relevant jurisdiction
- Industry-specific and professional obligations
- Contracts, licenses, customer commitments, and provider terms
- Security, privacy, records, accessibility, and procurement standards
- Internal policies, risk decisions, and approved-use restrictions
- Required notices, consent, human review, appeal, and auditability
The exact requirements depend on the use case, affected people, data, industry, geography, deployment, model provider, and level of risk. Legal and compliance specialists should interpret obligations; architects make the resulting requirements implementable and testable.
Why Is Compliance Important?
- Protects people, privacy, sensitive information, and legal rights
- Reduces legal, financial, contractual, and reputational exposure
- Supports market access, procurement, audits, and customer confidence
- Creates consistent requirements for teams and vendors
- Provides evidence that controls were designed and operated responsibly
- Improves incident readiness and accountability
- Prevents expensive redesign after architecture choices are fixed
Compliance is not a guarantee that a system is ethical, safe, accurate, or useful. It establishes a required baseline that must be combined with governance, risk management, security, quality, and responsible product design.
Compliance, Governance, and Security
| Discipline | Primary Question |
|---|---|
| Compliance | Which external and internal obligations apply, and can conformity be demonstrated? |
| Governance | Who owns, decides, approves, monitors, and remains accountable? |
| Risk management | What can go wrong, what is the impact, and how will risk be treated? |
| Security | How are identities, data, systems, models, and availability protected? |
| Privacy | Is personal data used lawfully, minimally, transparently, and with appropriate rights? |
| Audit | Does independent evidence show that required controls are designed and operating? |
Main Compliance Areas
Privacy and Data Protection
Define the purpose and authority for processing personal data, minimize collection, provide required notice or consent, enforce access and retention, protect sensitive categories, support applicable individual rights, and control international or third-party transfers.
Security
Apply risk-appropriate authentication, least privilege, encryption, secret and key management, secure development, vulnerability management, network controls, logging, incident response, resilience, and supplier security.
AI-Specific Obligations
Depending on context, an AI system may need risk classification, transparency notices, technical documentation, human oversight, accuracy and robustness evidence, event logs, provider or deployer responsibilities, prohibited-use screening, and ongoing monitoring.
Industry and Domain Rules
Healthcare, financial services, employment, education, government, insurance, and safety-related environments may impose specialized rules for records, decisions, validation, professional review, retention, reporting, or system qualification.
Consumer Protection and Accessibility
AI interfaces and claims should not mislead users. Products may need accessible interaction, clear material limitations, understandable notices, appropriate review, and usable complaint or appeal channels.
Intellectual Property and Licensing
Review rights for training and retrieval data, model and software licenses, generated output, attribution, confidential information, open-source obligations, and provider terms before use and redistribution.
Records and Audit Evidence
Preserve required versions, approvals, evaluations, data lineage, access, changes, consequential actions, incidents, and communications. Records must be accurate, protected, searchable, retained for the correct period, and deleted when their purpose or obligation ends.
From Obligation to Architecture
Source obligation -> Interpreted requirement -> Control objective
-> Architecture and process control -> Test procedure -> Evidence
-> Owner and monitoring -> Review/change trigger| Requirement | Possible Architecture Control | Evidence |
|---|---|---|
| Restrict sensitive data access | Identity-aware authorization and least privilege | Access tests, role mappings, audit events |
| Delete data after retention period | Lifecycle rules and deletion workflow across derived stores | Deletion logs and periodic verification |
| Provide human review | Approval queue, reviewer interface, override and appeal | Review records, outcomes, timing, sampling |
| Explain data and model use | Versioned user notices and system documentation | Notice version, acceptance or delivery record |
| Maintain service records | Tamper-resistant version and event logging | Searchable retained records and integrity checks |
| Manage provider changes | Vendor inventory, version pinning, regression gate | Change notices, evaluations, approvals |
A compliance matrix makes each obligation traceable to an owner, implementation, test, artifact, monitoring signal, and review schedule. This prevents requirements from remaining only in legal documents.
Data Mapping and Classification
A team cannot protect or govern data it cannot locate. Map the complete data lifecycle, including prompts, uploaded files, retrieved content, model inputs and outputs, feedback, logs, caches, analytics, backups, and provider processing.
- Identify data owner, source, purpose, legal or policy basis, and users.
- Classify public, internal, confidential, personal, sensitive, regulated, and derived data.
- Record system, provider, region, transfer path, storage, and subprocessors.
- Define access, encryption, retention, deletion, backup, and recovery.
- Track whether data may be used for training, evaluation, monitoring, or feedback.
- Propagate permissions and deletion through embeddings, indexes, caches, logs, and copies.
Privacy by Design
- Collect only the information necessary for an approved purpose.
- Use aggregated, de-identified, tokenized, or synthetic data when suitable.
- Separate production personal data from development and test environments.
- Redact sensitive fields before model or provider calls when possible.
- Give users required notice, choices, access, correction, export, or deletion workflows.
- Set retention at collection and enforce it in every downstream store.
- Evaluate privacy impact when purpose, model, data, geography, or provider changes.
Identity, Access, and Separation of Duties
- Federate workforce access and use strong authentication for privileged roles.
- Give human and workload identities the smallest necessary permissions.
- Separate development, approval, deployment, audit, and production administration where risk requires it.
- Review access periodically and remove it promptly when roles change.
- Protect emergency access with stronger monitoring and post-use review.
- Enforce tenant, document, row, tool, and environment boundaries consistently.
Transparency and Human Oversight
Transparency should match the audience and impact. Users, reviewers, auditors, and operators need different information, but each should understand the system sufficiently for their role.
- Disclose AI interaction or assistance where required or materially relevant.
- Explain intended purpose, important inputs, limitations, uncertainty, and appropriate reliance.
- Show sources or decision factors when they help users verify an outcome.
- Provide qualified human review before high-impact or irreversible actions.
- Allow authorized override, correction, complaint, contest, and appeal.
- Measure whether human reviewers have enough context, time, training, and authority.
Third-Party Compliance
Managed model and cloud providers can process data or change service behavior, but the deploying organization often retains important responsibilities. Review the full supplier chain before approval and throughout the contract.
| Vendor Area | Questions |
|---|---|
| Data | What is collected, retained, reused, transferred, or deleted? |
| Security | Which controls, certifications, testing, and incident duties exist? |
| Model | Can versions or behavior change, and how is notice provided? |
| Location | Where is processing performed and which subprocessors participate? |
| Rights | What licenses, confidentiality, and output terms apply? |
| Evidence | Can required audit and compliance information be obtained? |
| Continuity | What are the service, backup, export, termination, and migration options? |
Compliance Lifecycle
1. Determine Scope
Define the use case, users, affected people, decision impact, data, industry, jurisdictions, provider roles, integrations, and deployment locations.
2. Identify and Interpret Obligations
Work with legal, privacy, security, risk, accessibility, records, procurement, and domain specialists to create an applicability and obligations register.
3. Translate Requirements into Controls
Define control objectives, architecture, procedures, accountable owners, required records, and acceptance criteria. Record conflicts, assumptions, exceptions, and residual risk.
4. Implement and Validate
Build controls into data flows, identity, interfaces, models, providers, deployment, monitoring, and user workflows. Test design and operation with representative scenarios and negative cases.
5. Review and Approve
Present traceable evidence to authorized reviewers. Approval should define scope, conditions, accepted residual risk, expiry or review date, and changes that require reevaluation.
6. Monitor and Maintain
Track control health, access, incidents, complaints, model and data changes, provider notices, regulatory developments, evidence freshness, and overdue corrective actions.
7. Retire Responsibly
Stop processing, revoke access, terminate integrations, export or delete data as required, preserve mandatory records, communicate transitions, and verify that derived copies and providers follow the plan.
Compliance Testing
| Test Area | Example Test |
|---|---|
| Access | A user cannot retrieve another tenant's data or invoke an unauthorized tool |
| Retention | Expired data disappears from primary, derived, cache, index, and provider paths |
| Consent/purpose | Processing stops or changes when required permission is absent or withdrawn |
| Transparency | Correct notice and limitation information appears for the relevant workflow |
| Human oversight | A high-impact action cannot execute without qualified approval |
| Records | A decision can be reconstructed from protected versions and audit evidence |
| Incident | Required teams can contain, assess, preserve evidence, and communicate on time |
| Accessibility | Users can complete critical AI workflows using required assistive interaction |
Documentation and Evidence
- Applicability assessment and obligations register
- Use-case, system, model, provider, and data inventories
- Architecture, data-flow, trust-boundary, and integration diagrams
- Privacy, security, risk, impact, and vendor assessments
- Model, prompt, data, tool, and configuration versions
- Evaluation plans, datasets, results, limitations, and approvals
- Access reviews, training records, deployment records, and exceptions
- Monitoring, incidents, complaints, appeals, corrective actions, and audits
- Retention, deletion, backup, recovery, change, and retirement evidence
Automate evidence collection from real systems when practical, but protect evidence from unauthorized access and unnecessary personal data. Evidence should demonstrate that a control operated, not merely that a policy document exists.
A Simple Analogy
A restaurant must satisfy food safety, fire, labor, accessibility, licensing, recordkeeping, and local operating requirements. Owners identify which rules apply, design facilities and procedures around them, train staff, keep evidence, pass inspections, and update operations when requirements change.
AI compliance follows the same pattern: applicability, design, implementation, evidence, monitoring, review, and improvement continue throughout operation.
Python Consent Example
This simplified example makes purpose-specific consent explicit and records a clear decision. Consent is not the only possible basis for data processing, and production systems need verified identity, notices, withdrawal, retention, authorization, audit protection, and specialist review.
from dataclasses import dataclass
@dataclass(frozen=True)
class ProcessingDecision:
allowed: bool
reason: str
def may_process(consent: bool, requested_purpose: str, consented_purpose: str):
if not consent:
return ProcessingDecision(False, "Required consent is absent")
if requested_purpose != consented_purpose:
return ProcessingDecision(False, "Purpose is outside the consent scope")
return ProcessingDecision(True, "Purpose-specific consent is present")
print(may_process(True, "support_assistance", "support_assistance"))Monitoring and Change Triggers
- New or changed laws, regulations, standards, contracts, and internal policies
- New model, prompt, provider, subprocessor, tool, data source, or integration
- Expansion to a new country, language, industry, user group, or decision type
- Change in autonomy, human oversight, data sensitivity, retention, or purpose
- Material quality, fairness, safety, security, privacy, availability, or cost drift
- Incident, complaint, appeal, audit finding, or failed control
- Provider pricing, behavior, location, retention, security, or service change
Common Challenges
- Determining which overlapping rules apply across regions and industries
- Translating broad legal language into precise engineering requirements
- Tracking data, models, prompts, tools, providers, and derived copies
- Maintaining evidence as AI systems and provider behavior change quickly
- Coordinating legal, business, technical, security, privacy, and domain teams
- Preserving user rights and data controls across third-party services
- Balancing required records with data minimization and retention limits
- Treating certification or a prelaunch review as proof of permanent compliance
- Applying one control set to every use case regardless of actual risk
Best Practices
- Begin compliance scoping during requirements analysis, not after implementation.
- Use qualified legal and domain specialists to interpret obligations for the actual context.
- Maintain a current applicability register with sources, owners, dates, and review triggers.
- Map data, models, providers, users, regions, decisions, and trust boundaries end to end.
- Translate obligations into traceable controls, tests, monitoring, evidence, and ownership.
- Apply privacy, security, accessibility, transparency, and human oversight by design.
- Review vendors continuously and preserve realistic export, fallback, and exit plans.
- Version architecture, data, models, prompts, policies, evaluations, approvals, and notices.
- Test negative cases, rights workflows, retention, access, incidents, and recovery regularly.
- Monitor changes and revalidate compliance throughout operation and retirement.