Download patch/steps/_ops.py from nota-ai/Amazon-Ergo-NVFP4: direct link, hf CLI and curl.
- Browser
- Download file 558 Bytes
-
https://huggingface.co/nota-ai/Amazon-Ergo-NVFP4/resolve/main/patch/steps/_ops.py
- Command line
-
hf download hf://nota-ai/Amazon-Ergo-NVFP4/patch/steps/_ops.py
-
curl -L -o _ops.py https://huggingface.co/nota-ai/Amazon-Ergo-NVFP4/resolve/main/patch/steps/_ops.py
558 Bytes
| """File operations a patch step can return. Paths are relative to vllm/.""" | |
| from __future__ import annotations | |
| from dataclasses import dataclass | |
| class Copy: | |
| """Create (or overwrite) ``dst`` with ``text``.""" | |
| dst: str | |
| text: str | |
| class Edit: | |
| """Replace ``old`` with ``new`` in ``path``. | |
| ``old`` must occur exactly ``count`` times, otherwise the whole patch | |
| aborts before writing anything. This catches vLLM version drift. | |
| """ | |
| path: str | |
| old: str | |
| new: str | |
| reason: str | |
| count: int = 1 | |