Results and assignments

Updated Oct 20, 2025

Chutoro::run returns a ClusteringResult, which exposes the per-item assignments and a pre-computed cluster_count. The helper enforces that cluster identifiers start at 0 and are contiguous. ClusteringResult::try_from_assignments is available when validation of identifiers is required before constructing a result manually. Errors are reported via the NonContiguousClusterIds enum so actionable feedback can be surfaced upstream.

Each assignment stores a ClusterId. The underlying value can be accessed with get() when serialising or displaying results.