Instructions to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1", filename="ornith-1.0-35b-IQ4_XS-MTP-graft-headQ6.gguf", )
llm.create_chat_completion( messages = [ { "role": "user", "content": "What is the capital of France?" } ] ) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M # Run inference directly in the terminal: llama cli -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M # Run inference directly in the terminal: llama cli -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
Use Docker
docker model run hf.co/LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
- Ollama
How to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with Ollama:
ollama run hf.co/LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
- Unsloth Studio
How to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 to start chatting
- Pi
How to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
Run Hermes
hermes
- Atomic Chat new
- OpenClaw new
How to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
- Docker Model Runner
How to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with Docker Model Runner:
docker model run hf.co/LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
- Lemonade
How to use LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1 with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1:Q4_K_M
Run and chat with the model
lemonade run user.Ornith-1.0-35B-GGUF-llamacpp-tp1-Q4_K_M
List all available models
lemonade list
Refresh HF release verification readback
Browse files- ARTIFACT_MANIFEST.json +14 -12
- README.md +1 -1
- RELEASE_AUDIT.md +5 -5
- probes/hf-release-verification.json +11 -11
- scripts/verify_hf_release.py +29 -3
ARTIFACT_MANIFEST.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
{
|
| 2 |
-
"generated_at": "2026-06-28T00:
|
| 3 |
"known_remaining_gaps": [
|
| 4 |
"No release-candidate SFT/post-training adapter exists because SFT was stopped and checkpoint-8000 failed behavior gates.",
|
| 5 |
"The recommended strong repair blend and resume preflight are prepared CPU-side, but no resumed GPU training has been run from them.",
|
|
@@ -127,22 +127,22 @@
|
|
| 127 |
"release_verification": {
|
| 128 |
"latest_report_checks": 21,
|
| 129 |
"latest_report_failed_checks": 0,
|
| 130 |
-
"latest_report_generated_at": "2026-06-28T00:
|
| 131 |
"latest_report_hashes": {
|
| 132 |
-
"checked":
|
| 133 |
"skipped_large": 0,
|
| 134 |
"skipped_missing_local": 0,
|
| 135 |
"skipped_missing_remote": 0
|
| 136 |
},
|
| 137 |
"latest_report_status": "pass",
|
| 138 |
-
"latest_report_verified_remote_sha": "
|
| 139 |
"latest_report_warnings": 0,
|
| 140 |
"note": "The JSON report records the HF commit it verified. Re-run the script to verify the current default branch head after any new upload.",
|
| 141 |
"report": "probes/hf-release-verification.json",
|
| 142 |
"script": "scripts/verify_hf_release.py"
|
| 143 |
},
|
| 144 |
-
"remote_file_count_before_upload":
|
| 145 |
-
"remote_head_before_upload": "
|
| 146 |
"repair_artifacts": {
|
| 147 |
"code_only_extract_format": {
|
| 148 |
"assistant_code_fence": 0.0,
|
|
@@ -278,11 +278,11 @@
|
|
| 278 |
"bytes": 9436,
|
| 279 |
"path": "README.md",
|
| 280 |
"remote_before_upload": {
|
| 281 |
-
"blob_id": "
|
| 282 |
-
"bytes":
|
| 283 |
"exists": true
|
| 284 |
},
|
| 285 |
-
"sha256": "
|
| 286 |
},
|
| 287 |
{
|
| 288 |
"bytes": 12029,
|
|
@@ -2315,12 +2315,14 @@
|
|
| 2315 |
"sha256": "b1db75a43b9b3415cba337b868638a496f960cf492bbdfa4c31ad978c277908c"
|
| 2316 |
},
|
| 2317 |
{
|
| 2318 |
-
"bytes":
|
| 2319 |
"path": "scripts/verify_hf_release.py",
|
| 2320 |
"remote_before_upload": {
|
| 2321 |
-
"
|
|
|
|
|
|
|
| 2322 |
},
|
| 2323 |
-
"sha256": "
|
| 2324 |
}
|
| 2325 |
]
|
| 2326 |
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"generated_at": "2026-06-28T00:32:34.978784+00:00",
|
| 3 |
"known_remaining_gaps": [
|
| 4 |
"No release-candidate SFT/post-training adapter exists because SFT was stopped and checkpoint-8000 failed behavior gates.",
|
| 5 |
"The recommended strong repair blend and resume preflight are prepared CPU-side, but no resumed GPU training has been run from them.",
|
|
|
|
| 127 |
"release_verification": {
|
| 128 |
"latest_report_checks": 21,
|
| 129 |
"latest_report_failed_checks": 0,
|
| 130 |
+
"latest_report_generated_at": "2026-06-28T00:30:33.331758+00:00",
|
| 131 |
"latest_report_hashes": {
|
| 132 |
+
"checked": 207,
|
| 133 |
"skipped_large": 0,
|
| 134 |
"skipped_missing_local": 0,
|
| 135 |
"skipped_missing_remote": 0
|
| 136 |
},
|
| 137 |
"latest_report_status": "pass",
|
| 138 |
+
"latest_report_verified_remote_sha": "d1de198ef32cf39bec2814ea9e22e73323335a52",
|
| 139 |
"latest_report_warnings": 0,
|
| 140 |
"note": "The JSON report records the HF commit it verified. Re-run the script to verify the current default branch head after any new upload.",
|
| 141 |
"report": "probes/hf-release-verification.json",
|
| 142 |
"script": "scripts/verify_hf_release.py"
|
| 143 |
},
|
| 144 |
+
"remote_file_count_before_upload": 235,
|
| 145 |
+
"remote_head_before_upload": "d1de198ef32cf39bec2814ea9e22e73323335a52",
|
| 146 |
"repair_artifacts": {
|
| 147 |
"code_only_extract_format": {
|
| 148 |
"assistant_code_fence": 0.0,
|
|
|
|
| 278 |
"bytes": 9436,
|
| 279 |
"path": "README.md",
|
| 280 |
"remote_before_upload": {
|
| 281 |
+
"blob_id": "9684adc3ae830eb06330e82a87659adc3fe45aad",
|
| 282 |
+
"bytes": 9436,
|
| 283 |
"exists": true
|
| 284 |
},
|
| 285 |
+
"sha256": "33d1f77408f9a3da9bc165eb08b92469fbf977084846af29f13dce2fe50a10eb"
|
| 286 |
},
|
| 287 |
{
|
| 288 |
"bytes": 12029,
|
|
|
|
| 2315 |
"sha256": "b1db75a43b9b3415cba337b868638a496f960cf492bbdfa4c31ad978c277908c"
|
| 2316 |
},
|
| 2317 |
{
|
| 2318 |
+
"bytes": 16906,
|
| 2319 |
"path": "scripts/verify_hf_release.py",
|
| 2320 |
"remote_before_upload": {
|
| 2321 |
+
"blob_id": "fe3adbf8f47fa6c48f99381adba3218aca120779",
|
| 2322 |
+
"bytes": 15922,
|
| 2323 |
+
"exists": true
|
| 2324 |
},
|
| 2325 |
+
"sha256": "8adf5c4ed64d5fe9143dbec9341642a18455e5054798f6f473bbe36ee96f0ea9"
|
| 2326 |
}
|
| 2327 |
]
|
| 2328 |
}
|
README.md
CHANGED
|
@@ -40,7 +40,7 @@ SFT remediation plan: [SFT_REMEDIATION_PLAN.md](SFT_REMEDIATION_PLAN.md).
|
|
| 40 |
HF release verification: [probes/hf-release-verification.json](probes/hf-release-verification.json)
|
| 41 |
via [scripts/verify_hf_release.py](scripts/verify_hf_release.py). Latest recorded
|
| 42 |
run passed 21/21 checks with 0 warnings against HF commit
|
| 43 |
-
`
|
| 44 |
|
| 45 |
## Current Serving Baseline
|
| 46 |
|
|
|
|
| 40 |
HF release verification: [probes/hf-release-verification.json](probes/hf-release-verification.json)
|
| 41 |
via [scripts/verify_hf_release.py](scripts/verify_hf_release.py). Latest recorded
|
| 42 |
run passed 21/21 checks with 0 warnings against HF commit
|
| 43 |
+
`d1de198ef32cf39bec2814ea9e22e73323335a52`.
|
| 44 |
|
| 45 |
## Current Serving Baseline
|
| 46 |
|
RELEASE_AUDIT.md
CHANGED
|
@@ -1,11 +1,11 @@
|
|
| 1 |
# Release Audit
|
| 2 |
|
| 3 |
-
Generated: 2026-06-28T00:
|
| 4 |
|
| 5 |
- HF repo: `LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1`
|
| 6 |
-
- Remote head before this upload: `
|
| 7 |
-
- Remote files before this upload:
|
| 8 |
-
- Staged support files excluding generated audit files:
|
| 9 |
- Overall status: `pass for serving/quant/MTP support files; SFT adapter remains unreleased`
|
| 10 |
- Latest HF release verifier: `pass` (`21/21` checks, `0` warnings)
|
| 11 |
|
|
@@ -54,7 +54,7 @@ Generated: 2026-06-28T00:20:00.254958+00:00
|
|
| 54 |
|
| 55 |
- Script: `scripts/verify_hf_release.py`
|
| 56 |
- Latest report: `probes/hf-release-verification.json`
|
| 57 |
-
- Verified remote commit: `
|
| 58 |
- Result: `21/21` checks passed, `0` failures, `0` warnings.
|
| 59 |
- Coverage: model-card metadata, required support files, staged support-file
|
| 60 |
hashes, all `14` published GGUF artifacts, and SFT remediation gate summaries.
|
|
|
|
| 1 |
# Release Audit
|
| 2 |
|
| 3 |
+
Generated: 2026-06-28T00:32:34.978784+00:00
|
| 4 |
|
| 5 |
- HF repo: `LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1`
|
| 6 |
+
- Remote head before this upload: `d1de198ef32cf39bec2814ea9e22e73323335a52`
|
| 7 |
+
- Remote files before this upload: 235
|
| 8 |
+
- Staged support files excluding generated audit files: 207
|
| 9 |
- Overall status: `pass for serving/quant/MTP support files; SFT adapter remains unreleased`
|
| 10 |
- Latest HF release verifier: `pass` (`21/21` checks, `0` warnings)
|
| 11 |
|
|
|
|
| 54 |
|
| 55 |
- Script: `scripts/verify_hf_release.py`
|
| 56 |
- Latest report: `probes/hf-release-verification.json`
|
| 57 |
+
- Verified remote commit: `d1de198ef32cf39bec2814ea9e22e73323335a52`
|
| 58 |
- Result: `21/21` checks passed, `0` failures, `0` warnings.
|
| 59 |
- Coverage: model-card metadata, required support files, staged support-file
|
| 60 |
hashes, all `14` published GGUF artifacts, and SFT remediation gate summaries.
|
probes/hf-release-verification.json
CHANGED
|
@@ -54,12 +54,12 @@
|
|
| 54 |
]
|
| 55 |
},
|
| 56 |
{
|
| 57 |
-
"detail": "
|
| 58 |
"name": "files:required_support",
|
| 59 |
"status": "pass"
|
| 60 |
},
|
| 61 |
{
|
| 62 |
-
"detail": "
|
| 63 |
"name": "files:staged",
|
| 64 |
"status": "pass"
|
| 65 |
},
|
|
@@ -139,17 +139,17 @@
|
|
| 139 |
"status": "pass"
|
| 140 |
},
|
| 141 |
{
|
| 142 |
-
"checked":
|
| 143 |
"detail": "local staged file hashes match manifest",
|
| 144 |
"name": "hash:local_manifest",
|
| 145 |
"status": "pass"
|
| 146 |
},
|
| 147 |
{
|
| 148 |
-
"checked":
|
| 149 |
"detail": "remote staged files match local staged files",
|
| 150 |
"name": "hash:remote_local",
|
| 151 |
"skipped": {
|
| 152 |
-
"checked":
|
| 153 |
"skipped_large": 0,
|
| 154 |
"skipped_missing_local": 0,
|
| 155 |
"skipped_missing_remote": 0
|
|
@@ -157,14 +157,14 @@
|
|
| 157 |
"status": "pass"
|
| 158 |
}
|
| 159 |
],
|
| 160 |
-
"generated_at": "2026-06-28T00:
|
| 161 |
"local": {
|
| 162 |
"local_dir": "hf_upload",
|
| 163 |
"manifest": "hf_upload/ARTIFACT_MANIFEST.json"
|
| 164 |
},
|
| 165 |
"remote": {
|
| 166 |
-
"file_count":
|
| 167 |
-
"sha": "
|
| 168 |
},
|
| 169 |
"repo_id": "LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1",
|
| 170 |
"revision_requested": null,
|
|
@@ -172,14 +172,14 @@
|
|
| 172 |
"checks": 21,
|
| 173 |
"failed_checks": 0,
|
| 174 |
"hashes": {
|
| 175 |
-
"checked":
|
| 176 |
"skipped_large": 0,
|
| 177 |
"skipped_missing_local": 0,
|
| 178 |
"skipped_missing_remote": 0
|
| 179 |
},
|
| 180 |
"published_gguf": 14,
|
| 181 |
-
"required_support_files":
|
| 182 |
-
"staged_files":
|
| 183 |
"status": "pass",
|
| 184 |
"warnings": 0
|
| 185 |
}
|
|
|
|
| 54 |
]
|
| 55 |
},
|
| 56 |
{
|
| 57 |
+
"detail": "27 expected remote files are present",
|
| 58 |
"name": "files:required_support",
|
| 59 |
"status": "pass"
|
| 60 |
},
|
| 61 |
{
|
| 62 |
+
"detail": "207 expected remote files are present",
|
| 63 |
"name": "files:staged",
|
| 64 |
"status": "pass"
|
| 65 |
},
|
|
|
|
| 139 |
"status": "pass"
|
| 140 |
},
|
| 141 |
{
|
| 142 |
+
"checked": 207,
|
| 143 |
"detail": "local staged file hashes match manifest",
|
| 144 |
"name": "hash:local_manifest",
|
| 145 |
"status": "pass"
|
| 146 |
},
|
| 147 |
{
|
| 148 |
+
"checked": 207,
|
| 149 |
"detail": "remote staged files match local staged files",
|
| 150 |
"name": "hash:remote_local",
|
| 151 |
"skipped": {
|
| 152 |
+
"checked": 207,
|
| 153 |
"skipped_large": 0,
|
| 154 |
"skipped_missing_local": 0,
|
| 155 |
"skipped_missing_remote": 0
|
|
|
|
| 157 |
"status": "pass"
|
| 158 |
}
|
| 159 |
],
|
| 160 |
+
"generated_at": "2026-06-28T00:30:33.331758+00:00",
|
| 161 |
"local": {
|
| 162 |
"local_dir": "hf_upload",
|
| 163 |
"manifest": "hf_upload/ARTIFACT_MANIFEST.json"
|
| 164 |
},
|
| 165 |
"remote": {
|
| 166 |
+
"file_count": 235,
|
| 167 |
+
"sha": "d1de198ef32cf39bec2814ea9e22e73323335a52"
|
| 168 |
},
|
| 169 |
"repo_id": "LordNeel/Ornith-1.0-35B-GGUF-llamacpp-tp1",
|
| 170 |
"revision_requested": null,
|
|
|
|
| 172 |
"checks": 21,
|
| 173 |
"failed_checks": 0,
|
| 174 |
"hashes": {
|
| 175 |
+
"checked": 207,
|
| 176 |
"skipped_large": 0,
|
| 177 |
"skipped_missing_local": 0,
|
| 178 |
"skipped_missing_remote": 0
|
| 179 |
},
|
| 180 |
"published_gguf": 14,
|
| 181 |
+
"required_support_files": 27,
|
| 182 |
+
"staged_files": 207,
|
| 183 |
"status": "pass",
|
| 184 |
"warnings": 0
|
| 185 |
}
|
scripts/verify_hf_release.py
CHANGED
|
@@ -292,6 +292,8 @@ def check_local_and_remote_hashes(
|
|
| 292 |
) -> dict[str, int]:
|
| 293 |
stats = {
|
| 294 |
"checked": 0,
|
|
|
|
|
|
|
| 295 |
"skipped_large": 0,
|
| 296 |
"skipped_missing_local": 0,
|
| 297 |
"skipped_missing_remote": 0,
|
|
@@ -299,9 +301,29 @@ def check_local_and_remote_hashes(
|
|
| 299 |
mismatches: list[dict[str, Any]] = []
|
| 300 |
local_manifest_mismatches: list[dict[str, Any]] = []
|
| 301 |
|
| 302 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 303 |
with tempfile.TemporaryDirectory(prefix="hf-release-verify-") as cache_dir:
|
| 304 |
-
for item in
|
| 305 |
rel = item.get("path")
|
| 306 |
if not rel:
|
| 307 |
continue
|
|
@@ -335,6 +357,10 @@ def check_local_and_remote_hashes(
|
|
| 335 |
)
|
| 336 |
remote_sha = sha256_file(remote_path)
|
| 337 |
stats["checked"] += 1
|
|
|
|
|
|
|
|
|
|
|
|
|
| 338 |
if remote_sha != local_sha:
|
| 339 |
mismatches.append(
|
| 340 |
{"path": rel, "local_sha256": local_sha, "remote_sha256": remote_sha}
|
|
@@ -354,7 +380,7 @@ def check_local_and_remote_hashes(
|
|
| 354 |
"hash:local_manifest",
|
| 355 |
"pass",
|
| 356 |
"local staged file hashes match manifest",
|
| 357 |
-
checked=stats["
|
| 358 |
)
|
| 359 |
|
| 360 |
if mismatches:
|
|
|
|
| 292 |
) -> dict[str, int]:
|
| 293 |
stats = {
|
| 294 |
"checked": 0,
|
| 295 |
+
"checked_staged": 0,
|
| 296 |
+
"checked_generated": 0,
|
| 297 |
"skipped_large": 0,
|
| 298 |
"skipped_missing_local": 0,
|
| 299 |
"skipped_missing_remote": 0,
|
|
|
|
| 301 |
mismatches: list[dict[str, Any]] = []
|
| 302 |
local_manifest_mismatches: list[dict[str, Any]] = []
|
| 303 |
|
| 304 |
+
hash_items: list[dict[str, Any]] = []
|
| 305 |
+
seen_paths: set[str] = set()
|
| 306 |
+
for item in manifest.get("staged_files", []):
|
| 307 |
+
rel = item.get("path")
|
| 308 |
+
if not rel:
|
| 309 |
+
continue
|
| 310 |
+
hash_items.append({**item, "source": "staged"})
|
| 311 |
+
seen_paths.add(str(rel))
|
| 312 |
+
|
| 313 |
+
generated_paths = ["ARTIFACT_MANIFEST.json", "RELEASE_AUDIT.md"]
|
| 314 |
+
report_path = manifest.get("release_verification", {}).get("report")
|
| 315 |
+
if report_path:
|
| 316 |
+
generated_paths.append(str(report_path))
|
| 317 |
+
for rel in generated_paths:
|
| 318 |
+
if rel in seen_paths:
|
| 319 |
+
continue
|
| 320 |
+
local_path = local_dir / rel
|
| 321 |
+
size = local_path.stat().st_size if local_path.exists() else 0
|
| 322 |
+
hash_items.append({"path": rel, "bytes": size, "source": "generated"})
|
| 323 |
+
seen_paths.add(rel)
|
| 324 |
+
|
| 325 |
with tempfile.TemporaryDirectory(prefix="hf-release-verify-") as cache_dir:
|
| 326 |
+
for item in hash_items:
|
| 327 |
rel = item.get("path")
|
| 328 |
if not rel:
|
| 329 |
continue
|
|
|
|
| 357 |
)
|
| 358 |
remote_sha = sha256_file(remote_path)
|
| 359 |
stats["checked"] += 1
|
| 360 |
+
if item.get("source") == "generated":
|
| 361 |
+
stats["checked_generated"] += 1
|
| 362 |
+
else:
|
| 363 |
+
stats["checked_staged"] += 1
|
| 364 |
if remote_sha != local_sha:
|
| 365 |
mismatches.append(
|
| 366 |
{"path": rel, "local_sha256": local_sha, "remote_sha256": remote_sha}
|
|
|
|
| 380 |
"hash:local_manifest",
|
| 381 |
"pass",
|
| 382 |
"local staged file hashes match manifest",
|
| 383 |
+
checked=stats["checked_staged"],
|
| 384 |
)
|
| 385 |
|
| 386 |
if mismatches:
|