Audit Trail (v2.6.33 + Target)
Last modified by Robert Schaub on 2026/02/08 08:31
Current Implementation
erDiagram
JOBS ||--o{ JOB_EVENTS : logs
JOBS {
int JobId_PK
string Status
datetime CreatedAt
datetime UpdatedAt
json ResultJson
text ReportMarkdown
}
JOB_EVENTS {
int Id_PK
int JobId_FK
datetime TsUtc
string Level
string Message
}
Current audit capabilities:
- Job creation and completion timestamps
- Job execution events (start, progress, errors)
- No entity-level versioning
- No user attribution (no user system)
Target Architecture (Future)
erDiagram
USERS ||--o{ EDITS : makes
CLAIMS ||--o{ EDITS : tracks
EVIDENCE ||--o{ EDITS : tracks
SOURCES ||--o{ EDITS : tracks
KEY_FACTORS ||--o{ EDITS : tracks
USERS {
uuid id_PK
text name
text email
}
CLAIMS {
uuid id_PK
text text
}
EVIDENCE {
uuid id_PK
uuid claim_id_FK
}
SOURCES {
uuid id_PK
text name
}
KEY_FACTORS {
uuid id_PK
uuid claim_id_FK
text question
}
EDITS {
uuid id_PK
text entity_type
uuid entity_id
uuid user_id_FK
text change_type
boolean is_automated
jsonb changes
text reason
timestamp created_at
}
Target features:
- Full entity versioning (Claims, Evidence, Sources, KeyFactors)
- User attribution for all changes
- AKEL vs human edit distinction
- Hot/cold storage tiering (PostgreSQL + S3)
See Data Model for complete target architecture.