jcbtc commited on
Commit
07ba77c
·
verified ·
1 Parent(s): b5702ce

Check the selected runtime before model load and clarify launcher upgrades

Browse files
README.md CHANGED
@@ -50,11 +50,14 @@ Existing v4.2 users can update the launcher without rebuilding or downloading we
50
 
51
  [Hermes task results and grading notes](benchmarks/v4.3.0/HERMES-RESULTS.md) | [v4.3 release](https://github.com/ciru-ai/Qwen3.8-Flash-CIRU-STRIX-IU4/releases/tag/v4.3.0)
52
 
53
- For an existing **corrected v4.2** installation, download only the new launcher:
 
 
54
 
55
  ```bash
56
  hf download jcbtc/Qwen3.8-Flash-CIRU-STRIX-Orca \
57
- --revision v4.3.0 run-server.sh --local-dir ./model
 
58
  RUNTIME_DIR="$(realpath ./ciru-runtime-v4.2.0)" bash ./model/run-server.sh
59
  ```
60
 
 
50
 
51
  [Hermes task results and grading notes](benchmarks/v4.3.0/HERMES-RESULTS.md) | [v4.3 release](https://github.com/ciru-ai/Qwen3.8-Flash-CIRU-STRIX-IU4/releases/tag/v4.3.0)
52
 
53
+ **Launcher update, 16 September:** the current `main` launcher checks the HIP library selected by the dynamic loader for the v4.2 indexed-attention correction before loading the model. It stops with upgrade instructions if an older or incomplete runtime is selected, and prints the actual server/library paths and library hash. Updating the model folder alone does not upgrade `RUNTIME_DIR`, `BUILD_DIR` or `SERVER_BIN`. This check was added after the immutable v4.3.0 tag; fetch the current launcher below to use it with an existing corrected v4.2/v4.3 installation.
54
+
55
+ For an existing **corrected v4.2 or v4.3** installation, download and verify the current launcher:
56
 
57
  ```bash
58
  hf download jcbtc/Qwen3.8-Flash-CIRU-STRIX-Orca \
59
+ --revision main run-server.sh launcher-checksums.sha256 --local-dir ./model
60
+ (cd model && sha256sum -c launcher-checksums.sha256)
61
  RUNTIME_DIR="$(realpath ./ciru-runtime-v4.2.0)" bash ./model/run-server.sh
62
  ```
63
 
launcher-checksums.sha256 ADDED
@@ -0,0 +1 @@
 
 
1
+ 5584c936f4bfe1202a06d4a1a3891889e539ddf753f336505b2951d37a7258e5 run-server.sh
run-server.sh CHANGED
@@ -90,6 +90,38 @@ done
90
  server_bin="$(realpath "${server_bin}")"
91
  export LD_LIBRARY_PATH="$(dirname "${server_bin}")${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}"
92
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
93
  mkdir -p "${slot_dir}"
94
 
95
  set -a
 
90
  server_bin="$(realpath "${server_bin}")"
91
  export LD_LIBRARY_PATH="$(dirname "${server_bin}")${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}"
92
 
93
+ # Check the library selected by the loader, including BUILD_DIR/SERVER_BIN overrides.
94
+ unset LD_PRELOAD
95
+ runtime_fail() {
96
+ echo "CIRU runtime check: $*" >&2
97
+ echo "Selected server: ${server_bin}" >&2
98
+ echo "Updating the model folder or launcher does not update the inference runtime." >&2
99
+ echo "Build/install CIRU v4.2.0 or newer, then set RUNTIME_DIR and BUILD_DIR to that installation." >&2
100
+ echo "Keep its executable and shared libraries together; no model-weight download is needed." >&2
101
+ exit 2
102
+ }
103
+ for runtime_tool in ldd grep sha256sum; do
104
+ command -v "${runtime_tool}" >/dev/null || runtime_fail "Missing runtime-check tool: ${runtime_tool}"
105
+ done
106
+ [[ -z "${GGML_BACKEND_PATH:-}" ]] || runtime_fail "Clear GGML_BACKEND_PATH; an extra backend can bypass this runtime check."
107
+ runtime_dependencies="$(ldd "${server_bin}" 2>&1)" || runtime_fail "Cannot resolve shared libraries for this server. Check the SDK and loader dependencies."
108
+ hip_library=""
109
+ while IFS= read -r runtime_line; do
110
+ if [[ "${runtime_line}" == *"libggml-hip.so"*" => "* ]]; then
111
+ hip_library="${runtime_line#* => }"
112
+ hip_library="${hip_library% (*}"
113
+ fi
114
+ done <<< "${runtime_dependencies}"
115
+ [[ -n "${hip_library}" && -f "${hip_library}" ]] || runtime_fail "The selected server does not resolve a HIP library. Use the matching CIRU shared-library build."
116
+ hip_library="$(realpath "${hip_library}")"
117
+ for correction_marker in flash_attn_index_mask_clear flash_attn_index_mask_set flash_attn_index_mask_empty; do
118
+ grep -aFq "${correction_marker}" "${hip_library}" || runtime_fail "The HIP library lacks the v4.2 indexed-attention correction: ${hip_library}"
119
+ done
120
+ hip_sha256="$(sha256sum "${hip_library}")"
121
+ hip_sha256="${hip_sha256%% *}"
122
+ echo "CIRU runtime check: indexed-attention correction detected; HIP SHA256 ${hip_sha256}" >&2
123
+ echo "CIRU runtime check: server ${server_bin}; HIP ${hip_library}" >&2
124
+
125
  mkdir -p "${slot_dir}"
126
 
127
  set -a
v4.3.0-checksums.sha256 CHANGED
@@ -1,4 +1,4 @@
1
- c68aac25e1ee4427c8e72bd0c9da7f52debdf9a724f0661dbbeed7a11c85d589 run-server.sh
2
  e44b9ad60148bb5843070b7e89120bfa0526b0bedfcf488bbbce237e91d203f1 benchmarks/v4.3.0/HERMES-80-CASES.csv
3
  e0a630f97621352cae224f1d07acb1a6298bca8564c89115fbbf4da336a10ec9 benchmarks/v4.3.0/HERMES-POOLED.json
4
  b9fa142b24571b37f8a3d7bb7f271a28d800018f29fbec506cb857a02f38aa9d benchmarks/v4.3.0/HERMES-RESULTS.md
 
1
+ 5584c936f4bfe1202a06d4a1a3891889e539ddf753f336505b2951d37a7258e5 run-server.sh
2
  e44b9ad60148bb5843070b7e89120bfa0526b0bedfcf488bbbce237e91d203f1 benchmarks/v4.3.0/HERMES-80-CASES.csv
3
  e0a630f97621352cae224f1d07acb1a6298bca8564c89115fbbf4da336a10ec9 benchmarks/v4.3.0/HERMES-POOLED.json
4
  b9fa142b24571b37f8a3d7bb7f271a28d800018f29fbec506cb857a02f38aa9d benchmarks/v4.3.0/HERMES-RESULTS.md