nemo_automodel.components.speculative.eagle.remote.protocol
nemo_automodel.components.speculative.eagle.remote.protocol
Shared wire protocol between the remote target server and client.
The control plane is HTTP: the client POSTs input_ids and receives, in the
NCCL data path, only tensor metadata (dtype + shape) as JSON so it knows what
to recv; the actual tensors arrive over NCCL. In the fallback path the body
is the binary :mod:wire blob instead.
Module Contents
Functions
Data
API
Decode the JSON metadata body into (keys_order, metadata).
Map a wire dtype code back to a torch.dtype.
Encode tensor metadata (dtype code + shape) as a JSON HTTP body.
Only metadata is encoded — no tensor data. The client uses it to allocate the receive buffers before the NCCL recv.