> This page is for version Nightly (default).
> For other versions, use one of these documentation indexes:
> - Nightly (default): https://docs.nvidia.com/nemo/automodel/nightly/llms.txt
> - Latest: https://docs.nvidia.com/nemo/automodel/latest/llms.txt
> - 0.5.0 · 26.06: https://docs.nvidia.com/nemo/automodel/v0.5/llms.txt
> - 0.4.0 · 26.04: https://docs.nvidia.com/nemo/automodel/v0.4/llms.txt

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.nvidia.com/nemo/automodel/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.nvidia.com/nemo/automodel/_mcp/server.

# nemo_automodel.shared.retrieval_ids

Stable passage identities shared by retrieval text and image collators.

## Module Contents

### Functions

| Name                                                                                | Description                                                            |
| ----------------------------------------------------------------------------------- | ---------------------------------------------------------------------- |
| [`document_id_to_int64`](#nemo_automodel-shared-retrieval_ids-document_id_to_int64) | Encode a corpus ID consistently across processes and input modalities. |

### API

```python
nemo_automodel.shared.retrieval_ids.document_id_to_int64(
    document_id: str
) -> int
```

Encode a corpus ID consistently across processes and input modalities.

**Parameters:**

**`document_id`** `str`

Corpus document identifier encoded as UTF-8.

---

**Returns:** `int`

Nonnegative 63-bit integer, preserving the existing text-collator encoding.