Skip to content

vendor_connectors.meshy.persistence.utils

Utilities for spec hashing and canonicalization.

canonicalize_specConvert asset spec to canonical JSON string for hashing.
compute_spec_hashCompute truncated SHA256 hash of asset spec.

Convert asset spec to canonical JSON string for hashing.

Args: spec: Asset specification dict

Returns: Canonical JSON string (sorted keys, no whitespace)

Compute truncated SHA256 hash of asset spec.

Args: spec: Asset specification dict length: Hash length (default 12 chars)

Returns: Truncated hex hash safe for filenames