AI Auditability and Traceability in Pharma: Reconstructing AI-Supported Decisions
Direct answer
AI auditability and traceability in pharma mean keeping records that allow an AI-supported decision to be reconstructed: which model and version, which data, what inputs and outputs, which configuration or prompt, who reviewed it and what they decided, and when. In GxP contexts, these records support audit trails, investigations and inspections.
Executive summary
When something goes wrong, or when an inspector asks, organisations need to show how an AI-supported decision was made. Without records, this is impossible.
This page is part of Track A, AI for pharmaceutical manufacturers, within the AI in Pharma section. Statements describe potential applications (claim levels 1 and 2) unless a source is cited.
Definition and scope
This page is part of AI governance in Pharma.
The problem and today's process
AI applications often log little, or logs are not linked to model versions and human decisions.
What to record
| Record | Purpose |
|---|---|
| Model and version | Know which model produced the output |
| Data and dataset versions | Reproduce training and testing |
| Inputs | Understand what the model received |
| Outputs | Know what the model produced |
| User and decision | Attribute the human decision |
| Timestamps | Establish sequence |
| Configuration and prompts | Reproduce behaviour for language models |
| Changes | Link to change control records |
Potential AI applications
| Potential application | What AI may do | Technology | Typical data | Decision that remains human |
|---|---|---|---|---|
| Decision logging | Recording inputs, outputs and decisions | Application design | Interaction data | Audit use |
| Log analysis | Searching logs for investigations | LLMs | Logs | Investigator conclusions |
How a use case fits together
- Define what must be reconstructable
- Record model and data versions
- Log inputs, outputs and configuration
- Record reviewer and decision
- Protect logs from alteration
- Retain per requirements
- Enable retrieval for audits
- Link to change control
Data requirements
Logs may contain personal and confidential data, requiring security and retention controls.
The human role
System owners define logging; quality verifies adequacy for GxP; auditors and investigators use records.
Regulatory considerations
Regulatory expectations for AI in medicinal product development and manufacturing are evolving, and differ by jurisdiction and use. This page describes common principles, not regulatory requirements. Organisations should identify the guidance, legislation and standards applicable to their products, markets and uses, and verify their current status.
Applicable regulatory guidance differs by product, market and use; consult current guidance from the relevant authorities and standards bodies.
Limitations
- Logging everything creates storage and privacy burdens.
- Some third-party services limit logging.
- Non-deterministic models may not reproduce outputs exactly.
Risks and governance
| Risk | Typical control |
|---|---|
| Unreconstructable decisions | Defined logging requirements |
| Altered logs | Protected audit trails |
Measuring whether it helps
Measure a baseline first, then compare. Possible measures:
- Share of AI systems meeting logging requirements
- Time to reconstruct a decision
No specific improvement should be assumed. See AI implementation in Pharma.
Questions to ask before implementation
- What must be reconstructable?
- Are model and data versions linked?
- Are logs protected?
- How long are records retained?
Related use cases are listed in the AI use cases in Pharma directory.
Frequently asked questions
What is AI auditability?
It is the ability to examine and reconstruct how an AI system was built, how it behaved and how its outputs were used in decisions.
What should be recorded for AI-supported decisions?
Model and data versions, inputs, outputs, configuration or prompts, the reviewer and decision, timestamps and links to change control.
Do AI systems need audit trails in GxP?
Where AI supports GxP records or decisions, audit trail and data integrity expectations apply.
Can LLM outputs be reproduced for audits?
Not always exactly, because some models are non-deterministic, which makes logging actual inputs and outputs important.
