SageMaker inference logging for compliance, mapped onto a decision record
If your model serves from a SageMaker endpoint and someone has asked you for the record of a specific decision rather than a bucket of captured payloads, this page is the mapping. Auditrek accepts inference event payloads over REST or webhook and appends each one to a SHA-256 hash-chained, append-only record set for that AI system, with a documented payload mapping guide for AWS SageMaker.
Auditrek is not open yet, so anything on this page about what it does is what it is being built to do.

What your endpoint already logs, and what a record request actually asks for
A SageMaker deployment carrying real traffic is rarely logging nothing. There is usually a captured copy of request and response payloads landing in object storage, application logs from the inference handler, and platform metrics on top. When a supervisory authority, an internal audit function or a customer's third-party risk team asks you to produce the record of one decision, none of that is the problem and all of it is the problem.
What you have is keyed to infrastructure: invocation, container, time window, destination prefix. What is being asked for is keyed to a decision: this input, scored by this model version, produced this output with this confidence at this time, and a person either accepted it or overrode it. Getting from the first shape to the second is a join across two or three systems, performed under time pressure, by whoever still remembers how the pipeline was wired.
Two problems that surface at exactly the wrong moment
- Order. An object store can tell you when a file was written, but the files carry no evidence of their own sequence. Nothing inside the artefact distinguishes the log you kept from the log you tidied.
- Scope. Logs are grouped by bucket, stream and account. The record-keeping and logging obligations in Article 12 of the EU AI Act, and the transparency and information duties in Article 13, are framed around an AI system, which is not a unit your log infrastructure knows about.
Auditrek's ingestion layer exists to close that gap at write time instead of at audit time. It accepts inference event payloads over REST or webhook and appends each one to a SHA-256 hash-chained, append-only record set for a single ai_system. We are not going to tell you what Article 12 requires of your particular system, that is work for your own counsel. What the ingestion layer does is give the evidence a structure designed to support documentation of those obligations, rather than a structure that has to be reconstructed from three sources on the day someone asks.
How a SageMaker inference event becomes a decision record
- Register the endpoint as its own AI system
Each SageMaker endpoint you want on the record becomes its own ai_system in Auditrek, because the hash chain and the append-only record set are per system. A fraud scoring endpoint and a document triage endpoint do not share a chain, so a request scoped to one system produces one continuous sequence rather than a filtered slice of everything.
- Record the DPA, then connect
No API key and no webhook secret exists for a system until a dpa_confirmation with a signed_at timestamp is recorded against it. The check is enforced server-side on the connect endpoint, which returns a 403 while the confirmation is unsigned, so the gate cannot be stepped around from the client. The ordering is deliberate: the paperwork comes before the credentials, not after the first thousand events.
- Pick the emit point, not an injection point
Ingestion is an HTTP contract, so you decide where the call happens: from your inference handler after the response has already gone back to the caller, from a consumer that reads the payloads your endpoint already captures, or from the orchestration step that wraps the invocation. Nothing in Auditrek needs to sit between your caller and your model.
- Map the payload fields
The documented payload mapping guide for AWS SageMaker covers how a SageMaker inference event lines up with the decision record payload: input hash, model id and version, output, confidence, timestamp and the human override flag. There is no bespoke SageMaker SDK in the first release, deliberately, so there is nothing new to pin inside your inference container's dependency set.
- Post the event and pass the ingestion gate
Your handler or your log consumer calls the REST endpoint with the mapped payload, or fires the webhook, and the same contract serves both. Before anything is written, the payload is inspected for recognisable raw sensitive-field patterns, and a request carrying them is rejected with a 422 and an error body naming the problem rather than stored and cleaned up later. Subject identifiers are pseudonymised by default. The data minimisation page in this pillar goes through what that means field by field; the practical consequence for your mapping is that it should emit hashes and references, not raw fields.
- The record is appended, chained and acknowledged
Auditrek takes the last record for that ai_system, derives the next sequence_number and prev_hash from it, computes the record hash over the previous hash and the payload, and writes the whole set of fields in one transaction. The response is a 201 carrying the created record including its hash and sequence_number, so your own logs can hold the receipt for the write.
The mapping, field by field
| Decision record field | What it carries | Where it usually comes from in a SageMaker deployment |
|---|---|---|
| input hash | A digest that identifies the feature payload you scored, rather than the payload itself | Computed in your inference handler, or in the consumer that reads the request payload your deployment already captures |
| model id and version | Which artefact produced this output | Whatever identifier and version your deployment already tracks for the artefact behind the endpoint |
| output | The decision or score as it left the model | The response body your endpoint returned to the caller |
| confidence | The score that accompanied the output | The probability or score field in that response, where your model emits one |
| timestamp | When the inference happened | The invocation time recorded by your handler or by the log consumer that reads it |
| human override flag | Whether a person changed the outcome | Your review or case-management step, not the endpoint, which usually means this arrives later than the inference itself |
| subject reference | A pseudonymised identifier for the person or case the decision concerned, applied by default at ingestion | The application, case or claim reference your pipeline already carries, never the direct identifier itself |
Three deployment shapes, three emit points
The mapping guide is one document, but the place the call belongs depends on how your endpoint is invoked. Three shapes cover most of what we see described.
A synchronously invoked endpoint inside a request path
The caller is waiting, so the emit happens after the response has been returned, not before. Write the record from the handler once the response is on its way out, or hand the event to a queue and let a worker post it. The decision record is evidence about an inference that already happened, which means nothing about the write has to be on the critical path.
Batch or asynchronous scoring writing results to storage
Here the awkward question is not where to call from but what counts as one decision. A job that scores forty thousand rows is either one event, which is cheap and almost useless to an auditor asking about one applicant, or forty thousand records, which is honest and needs the loop to be built deliberately. Decide that before you write the mapping, because the answer changes the shape of every report that reads the chain afterwards.
An inference a person reviews before it takes effect
The human override flag almost never comes from the endpoint. It comes from a case-management or review tool, minutes or days later, and that tool usually has no idea your endpoint exists. Name the system that owns the flag, and decide whether a reviewed decision produces a second record in the chain or whether the review outcome is carried on the original mapping. Either is defensible. Undocumented is not.
What this buys you
No model migration and no new SDK in the container
The first release ships a generic REST and webhook ingestion layer with documented mapping guides rather than platform SDKs. Your model artefact, container image and endpoint configuration stay as they are, and the only new dependency is an HTTP call you already know how to make.
Your production inference path stays yours
Because you choose the emit point, the record can be written after the response has been served or entirely downstream of it. Nothing about the ingestion contract obliges you to put a third party between a caller and a scoring decision.
One record shape across a mixed estate
Mapping guides cover AWS SageMaker and Azure ML, so a SageMaker endpoint and an Azure ML deployment land in the same decision record payload. Compliance reviewers read one structure instead of learning two logging stacks.
Sequence is part of the evidence, not metadata about it
Records are appended per ai_system with each hash computed over the previous hash and the payload, written atomically so a sequence number and its hash cannot drift apart. The order of decisions is carried inside the artefact rather than inferred from file write times in a bucket, and a server-side endpoint recomputes the chain on demand to return a tamper status. The verification page in this pillar covers what that status does and does not evidence.
The input stays out of the ledger
The payload field is an input hash, not the input, and the ingestion gate refuses payloads carrying recognisable raw sensitive fields before any database write. For a credit or hiring pipeline that means the record can identify which input was scored without the ledger becoming another copy of personal data to defend.
Where this stands today
Auditrek is in build and open by waitlist, so this page describes what the ingestion layer is built to do, not what a reference deployment has done with it. The first release is the generic REST and webhook ingestion layer with documented payload mapping guides for AWS SageMaker and Azure ML. Deeper native platform integrations are a fast-follow rather than build-time scope, and we would rather say that plainly than imply a one-click SageMaker integration that does not exist yet.
Two things about the shape of the first release are worth knowing before you plan an integration. A system cannot be connected at all until its data processing agreement confirmation is recorded with a signed_at date. And the records a SageMaker endpoint writes are what the report generator reads, producing PDF and HTML output for a chosen system and date range, structured against EU AI Act Article 12 and 13 fields, with a fixed footer on every page stating that the report does not constitute legal advice and has not been reviewed by qualified regulatory counsel. One regulation and one field set at launch. We would rather ship that narrowly and describe it accurately.
Auditrek itself runs on Amazon Web Services, and sign-in is email and password. If you are mapping a SageMaker endpoint onto a record you may have to defend, join the waitlist and tell us the shape of your inference events. The mapping guides get better with the awkward cases, and the awkward cases are usually batch scoring, asynchronous overrides and model versions that were not pinned when the endpoint was first stood up.
Questions
Do I need a SageMaker SDK or a model migration to log inference events to Auditrek?
No. Ingestion is a generic REST and webhook layer with documented payload mapping guides for AWS SageMaker and Azure ML. There are no bespoke platform SDKs in this release, so nothing new goes into your inference container and the deployed artefact does not move.
Does Auditrek sit in my production inference path?
It does not have to. You choose the emit point: your handler after the response has been returned, a consumer reading the request and response payloads your deployment already captures, or an orchestration step around the invocation. The ingestion layer receives events over HTTP rather than intercepting them.
What exactly is stored for each inference event?
The decision record payload carries an input hash, model id and version, output, confidence, timestamp and a human override flag, with subject identifiers pseudonymised by default. Records are stored as a SHA-256 hash-chained, append-only set per ai_system, and the write returns a 201 with the record's hash and sequence number.
Do I need a signed DPA before I can connect a SageMaker endpoint?
Yes. No API key or webhook secret is issued for an ai_system until a dpa_confirmation with a signed_at timestamp is recorded, and the check runs server-side on the connect endpoint, returning a 403 while it is unsigned. Given that inference payloads from credit, hiring and clinical pipelines routinely touch special-category data, we would rather that ordering be structural than a matter of good intentions.
What happens if a payload carries a raw SSN or a diagnosis code?
The ingestion API inspects the payload for recognisable raw sensitive-field patterns, including SSN formats, ICD-10 style diagnosis codes and unredacted credit bureau fields, and rejects the request with a 422 and a clear error body before any database write. The design intent is that the ledger never becomes a second home for data you are already working to contain.
My endpoint does not return a confidence score. What goes in that field?
Confidence is a field in the payload, and what you put in it is a modelling decision about your pipeline rather than something we can decide for you. Those are exactly the choices the SageMaker mapping guide exists to document, so the mapping an auditor reads matches the one your engineers implemented.
Does the same approach work for Azure ML?
Yes. The documented payload mapping guides cover AWS SageMaker and Azure ML against the same ingestion contract, so a mixed estate produces one record shape rather than two.
Does this mean my logging satisfies EU AI Act Article 12?
That is not a question we answer, and nothing here should be read as legal advice. The record structure is designed to support documentation of Article 12 record-keeping and Article 13 transparency obligations, and every generated report says on every page that it does not constitute legal advice and has not been reviewed by qualified regulatory counsel. Whether your system and your practices meet those obligations is an assessment for your own counsel.