<!--
{
  "availability" : [
    "iOS: 27.3.0 -",
    "iPadOS: 27.3.0 -",
    "macOS: 27.3.0 -",
    "visionOS: 27.3.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SiriEvaluations",
  "identifier" : "/documentation/SiriEvaluations/SiriTranscript",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "Siri Evaluations"
    ],
    "preciseIdentifier" : "s:15SiriEvaluations0A10TranscriptV"
  },
  "title" : "SiriTranscript"
}
-->

# SiriTranscript

The immutable record of one scenario’s execution.

```
struct SiriTranscript
```

## Overview

A transcript records what Siri does while running one scenario. For each turn,
it holds:

- the intents Siri calls, with their arguments
- how each call ends
- the entities Siri finds
- the entities onscreen
- the skills Siri loads
- the reply Siri gives

A [`SiriExpectationEvaluator`](/documentation/SiriEvaluations/SiriExpectationEvaluator) reads the transcript to compute metrics. When you
write an evaluator of your own, read the transcript through the
[`siriTranscript`](/documentation/SiriEvaluations/SiriScenarioSubject/siriTranscript) property of the evaluation subject.

Look up a turn with [`turn(for:)`](/documentation/SiriEvaluations/SiriTranscript/turn(for:)) using the identifier of the [`UserTurn`](/documentation/SiriEvaluations/UserTurn) that
produces it, not its position. Identifier lookup keeps a run that stops early
from pairing a recorded turn with the wrong turn from the scenario.

The following shows a function that counts the intents Siri runs during a turn:

```swift
func ranIntentCount(for turn: UserTurn, in subject: SiriScenarioSubject) -> Int {
    // Look up the recorded turn by the identifier.
    guard let recorded = subject.siriTranscript.turn(for: turn.id) else {
        return 0
    }

    // Count the calls that run, not the ones that stop to ask a
    // question or fail.
    return recorded.intentInvocations
        .filter { $0.value.outcome.ran }
        .count
}
```

## Topics

### Inspecting a transcript

[`let turns: [SiriTranscript.Turn]`](/documentation/SiriEvaluations/SiriTranscript/turns)

The turns the run reached, in conversation order.

[`func turn(for: UUID) -> SiriTranscript.Turn?`](/documentation/SiriEvaluations/SiriTranscript/turn(for:))

Returns the turn produced by the scenario turn with this identity, if it ran.

### Reading transcript contents

[`struct Turn`](/documentation/SiriEvaluations/SiriTranscript/Turn)

Everything observed during one user turn.

[`struct IntentInvocation`](/documentation/SiriEvaluations/SiriTranscript/IntentInvocation)

A record of one intent call, including its arguments and result.

[`struct Observation`](/documentation/SiriEvaluations/SiriTranscript/Observation)

A value from the run, with the time the framework built its transcript.

## Relationships

### Conforms To

[`Sendable`](/documentation/Swift/Sendable)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)