llm_uuid: A short, sortable, process-unique identifier

View source: R/hash.R

llm_uuidR Documentation

A short, sortable, process-unique identifier

Description

Mints a compact id without a UUID dependency, useful for tagging runs, spans, or records. The id sorts in creation order within a session: it is a base-36 timestamp, the process id, and a monotone counter, joined by - (with an optional prefix). It is unique within a process and practically unique across processes on a host; it is not a registered UUID and makes no cross-host global-uniqueness guarantee.

Usage

llm_uuid(prefix = NULL)

Arguments

prefix

Optional short string prepended as prefix-....

Value

A character scalar.

Examples

llm_uuid()
llm_uuid("run")

LLMR documentation built on July 11, 2026, 1:06 a.m.