Skip to content

Commit 51e540e

Browse files
committed
ci: test qwen35 pre-norm flag initialization
1 parent d2b1837 commit 51e540e

1 file changed

Lines changed: 7 additions & 14 deletions

File tree

.github/workflows/test.yaml

Lines changed: 7 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -56,28 +56,21 @@ jobs:
5656
uname -a
5757
lscpu
5858
python -c "import platform; print(platform.machine(), platform.architecture())"
59-
- name: Instrument Linux get_rows_f32 assertion
59+
- name: Patch Linux Qwen3.5 pre-norm flag initialization
6060
run: |
6161
python - <<'PY'
6262
from pathlib import Path
6363
64-
path = Path("vendor/llama.cpp/ggml/src/ggml-cpu/ops.cpp")
64+
path = Path("vendor/llama.cpp/src/llama-context.cpp")
6565
text = path.read_text()
66-
old = " GGML_ASSERT(i01 >= 0 && i01 < ne01);\n\n ggml_vec_cpy_f32(nc,"
66+
old = " cparams.embeddings = params.embeddings;\n cparams.embeddings_pre_norm = false;\n"
6767
new = (
68-
" if (!(i01 >= 0 && i01 < ne01)) {\n"
69-
" fprintf(stderr,\n"
70-
" \"%s: invalid row index in get_rows_f32: dst=%s src0=%s src1=%s i=%lld i10=%lld i11=%lld i12=%lld i01=%lld ne01=%lld src1_ne=[%lld,%lld,%lld,%lld]\\\\n\",\n"
71-
" __func__, dst->name, src0->name, src1->name,\n"
72-
" (long long) i, (long long) i10, (long long) i11, (long long) i12,\n"
73-
" (long long) i01, (long long) ne01,\n"
74-
" (long long) ne10, (long long) ne11, (long long) ne12, (long long) ne13);\n"
75-
" }\n"
76-
" GGML_ASSERT(i01 >= 0 && i01 < ne01);\n\n"
77-
" ggml_vec_cpy_f32(nc,"
68+
" cparams.embeddings = params.embeddings;\n"
69+
" cparams.embeddings_pre_norm = false;\n"
70+
" cparams.embeddings_pre_norm_masked = false;\n"
7871
)
7972
if old not in text:
80-
raise SystemExit("get_rows_f32 assertion pattern not found")
73+
raise SystemExit("cparams pre-norm initialization pattern not found")
8174
path.write_text(text.replace(old, new, 1))
8275
PY
8376
- name: Install dependencies (Linux/MacOS)

0 commit comments

Comments
 (0)