nemo_gym.harness_capabilities.reader

View as Markdown

Streaming native Gym reader with explicit, loss-detecting payload joins.

Module Contents

Functions

NameDescription
_reject_constant-
digest_file-
hydrate_recordRestore payloads by exact model_call_id, never order or content hash.
json_rowsRead JSONL strictly; malformed/truncated rows are checker errors.

Data

PAYLOADS

API

nemo_gym.harness_capabilities.reader._reject_constant(
value: str
) -> None
nemo_gym.harness_capabilities.reader.digest_file(
path: pathlib.Path
) -> str
nemo_gym.harness_capabilities.reader.hydrate_record(
record: dict,
capture_dir: pathlib.Path | None = None
) -> dict

Restore payloads by exact model_call_id, never order or content hash.

The native collector moves bodies from capture.calls into ng_trajectory. An optional capture directory cross-checks the retained transport exchanges. It never repairs payloads missing from the delivered JSONL. Conflicts are preserved as reader failures instead of being overwritten.

nemo_gym.harness_capabilities.reader.json_rows(
path: pathlib.Path
) -> typing.Iterator[tuple[int, dict]]

Read JSONL strictly; malformed/truncated rows are checker errors.

nemo_gym.harness_capabilities.reader.PAYLOADS = ('request', 'response', 'request_raw', 'response_raw')