Skip to content
25 / 31

Как организовать audit trail для AI-решений: что логировать, retention, replayability и как соответствовать GDPR Article 22 / EU AI Act Article 12?

AI audit trail = structured durable log каждого inference-вызова, который удовлетворяет regulatory (GDPR Art 22 right-to-explanation, EU AI Act Art 12 traceability), operational (debug + postmortem) и legal (litigation defense) requirements. Минимум что логировать: request_id (ULID), timestamp, tenant_id, user_id (pseudonymized через sha256(user_id + tenant_salt)), model_id+version, prompt_template_version, full prompt (или hash если PII), tools called с args, RAG context (doc_ids + chunk_ids), full response, logprobs/confidence, cost, decision_metadata (HITL override, policy flags, refusal reason), safety_evals (toxicity, PII detected, hallucination probability). Retention: GDPR Art 5 data minimization + EU AI Act Art 12 (4 года для high-risk); baseline 90 дней hot + 1 год cold. Replayability: deterministic (temperature=0 + fixed seed) vs stochastic с logprobs для approximate replay. Tools: Langfuse, LangSmith, Arize Phoenix, Datadog LLM Observability, OpenTelemetry GenAI semantic conventions.

Как организовать audit trail для AI-решений: что логировать, retention, replayability и как соответствовать GDPR Article 22 / EU AI Act Article 12? | JScriptiser