> ## Documentation Index
> Fetch the complete documentation index at: https://praison.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Record Streaming • AI Agents Framework

> record_streaming: Record streaming metrics.

# record\_streaming

<div className="flex items-center gap-2">
  <Badge color="purple">Method</Badge>
</div>

> This is a method of the [**Profiler**](../classes/Profiler) class in the [**profiler**](../modules/profiler) module.

Record streaming metrics.

## Signature

```python theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
def record_streaming(name: str, ttft_ms: float, total_ms: float, chunk_count: int, total_tokens: int) -> None
```

## Parameters

<ParamField query="name" type="str" required={true}>
  No description available.
</ParamField>

<ParamField query="ttft_ms" type="float" required={true}>
  No description available.
</ParamField>

<ParamField query="total_ms" type="float" required={true}>
  No description available.
</ParamField>

<ParamField query="chunk_count" type="int" required={false} default="0">
  No description available.
</ParamField>

<ParamField query="total_tokens" type="int" required={false} default="0">
  No description available.
</ParamField>

## Uses

* `cls.is_enabled`
* `StreamingRecord`

## Used By

* [`StreamingTracker.end`](../functions/StreamingTracker-end)

## Source

<Card title="View on GitHub" icon="github" href="https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai/praisonai/profiler.py#L506">
  `praisonai/profiler.py` at line 506
</Card>
