---
title: "ClikaRT::io::SafetensorsEntries"
sidebar_label: "SafetensorsEntries"
description: "A safetensors checkpoint read in the file's own order: entries as the header states them (a sharded checkpoint: the index's weight_map order) and the checkpoint-level metadata as (key, value) text pai…"
---

<!-- Generated by tools/doxygen2mdx from Doxygen XML. Do not edit. -->

<span class="api-kind api-kind--struct">struct</span>

**Header:** `ClikaRT/io/io.h`

A safetensors checkpoint read in the file's own order: [`entries`](./SafetensorsEntries.md#entries) as the header states them (a sharded checkpoint: the index's `weight_map` order) and the checkpoint-level metadata as `(key, value)` text pairs in header order. The order is the point: [`NamedTensors`](../NamedTensors.md) is an unordered map, and a consumer that must give a checkpoint back with its keys in their original order (a saved pytree, a state dict) reads and writes through this form.

## Data members

### entries {#entries}

<div class="api-signature">

`std::vector<std::pair<std::string,` [`Tensor`](../Tensor.md)`>>` **`entries`**

</div>

The tensors, `(name, tensor)`, in the order the file states them.

<div class="api-declared">

Declared in `ClikaRT/io/io.h`, line 233

</div>

### metadata {#metadata}

<div class="api-signature">

`std::vector<std::pair<std::string, std::string>>` **`metadata`**

</div>

The checkpoint-level metadata in header order: a single file's `__metadata__`; a sharded checkpoint's index document "metadata" object (the per-shard `__metadata__` entries are not aggregated). A string value as is, any other JSON value as its JSON text. Empty when the file has none.

<div class="api-declared">

Declared in `ClikaRT/io/io.h`, line 239

</div>
