openai

Stars and mentions

Last 30 days, Oct 5 – Nov 3

GitHub stars27,563
mentions2,667
02.2K4.3K6.5K8.6KOct 5Oct 19Nov 3
UTC days · repositories openai owns63 repositories

Package downloads

Cumulative recorded downloads · since 2025-10-19

crates.io—
npm—
PyPI3.9B
0975.4M2B2.9B3.9BOct 5Oct 19Nov 3
Oct 28crates.io: 0/3 packages observed · npm: 0/11 packages observed · PyPI: 1/9 packages observed

Across 23 known packages in repositories openai owns. Cumulative totals include recorded downloads before the selected range. Missing observations leave gaps; totals may be incomplete. PyPI excludes known mirrors.

Top repositories

openai’s repositories ranked by pull request authors, as on trending.

Loading

Contributes to

Repositories outside openai’s account where openai opened or reviewed pull requests in the past 365 days.

Who noticed openai

Everyone who starred or forked openai’s repositories since the archive began in 2011.

Notable accounts

Ordered by the stars their own repositories have received.

Biggest fans

Accounts that starred the most of these repositories.

Breakout weeks

Each repository’s best week of new stars, with the release published around it.

Mentions

2,648posts
Nov 45 posts
  1. 話者分離がうまくいかず、モデルを 7 つ替えても直らなかった <!-- タイトル候補: 話者分離の精度が出ないとき、最初に作るべきは正解データ 10 か所だった 「モデルを替えれば直る」は 1 本目で当たって 2 本目で外れた --> はじめに 最近英語を話す機会が多いので、自分の英語の改善のためにも、英会話の内容をもとに AI に復習プランを作成してもらいたいと考えました。最初は ChatGPT に録音をそのまま読み込ませようとしたのですが、長すぎて読み込めませんでした。 そこで文字起こしアプリをいくつか調べていたのですが、調べていくうちに、月額料金が思ったより高いことに気づきました。私がやりたいのは、文字起こしをして、それを AI に読み込ませて復習メニューを作ってもらうことだけです。それにしてはちょっと高いなと思ったので、文字起こしアプリを自作することにしました。 この時代すぐに作れますし、自分に必要な最低限のものをローカルで動かすだけなので、作っていこうと思いました。 ここで盲点だったのが話者分離(録音の中で誰が話したかを区別する処理)です。私はただ文字起こしをすればいいと思っていたのですが、話者分離ができたほうが復習にはかなり役に立ちますし、AI 側も汲み取って復習プランを組みやすいことに気づきました。なので、この時点での要件は、ローカルで動くこと、話者分離ができること、文字起こしができることの 3 つになります。 調べていくと、そういったライブラリが OSS ですでに提供されていることまで分かりました。いくつかあったので、それぞれ色々と試しました。今は文字起こしに Whisper、話者分離に sherpa-onnx を使っています。 ところが話者分離をかけると、講師と私が 1 人の話者にまとめられてしまいました。直すまでに 3 晩かかり、その間に原因の予想を 3 回外しています。最後は、誰の声か確実に分かる区間を 10 か所選んで測ったところで原因が分かりました。この記事はその記録です。 話者が 1 人しか出てこない 23 分の録音を話者分離にかけると、話者 A が 1580 語、話者 B が 0 語になりました。録音全体が 1 人の発言として扱われています。 <!-- TODO(本人): 画像 1。話者 A だけになった結果の画面(ツール名・講師名が映らないように切り抜く) --> 録音は iPhone でしています。講師の声は PC のスピーカー越しに入り、自分の声は直接入ります。 sherpa-onnx は、音声認識や音声合成、話者分離などをまとめて動かせるライブラリです。話者分離は次の順に進みます(構成は公式ドキュメントに載っています)。 録音から、誰かが話している区間を切り出す(pyannote の segmentation モデルを使います) 区間ごとに、声の特徴を数値の並びにする(埋め込みと呼ばれます) 特徴が近い区間をまとめて、まとまりごとに話者を決める(クラスタリング) 外れた予想が 3 つあった 録音に講師の声が入っていない? 最初に疑ったのは録音そのものです。イヤホンで聞いていたなら、講師の声は録音に入っていないかもしれません。 確かめると、録音には 2 人の声が入っていました。 ライブラリのバージョンが違う? 次に疑ったのは環境の違いです。同じ録音を Linux の環境で流すと、304 秒と 554 秒の 2 人に分かれました。それでバージョンか環境の差が原因だと考えました。 ところが翌日の 22 分の録音では、Linux でも 775 秒と 17 秒に偏りました。2 人目とされた 17 秒は相づちと雑音だけです。前の日に分かれたのはたまたまだったようです。 声の特徴を取るモデルが合っていない? 3 つ目に疑ったのは、埋め込みを作るモデルです。sherpa-onnx で使える 7 つのモデルを、うまく分かれた録音と偏った録音の 2 本でそれぞれ 8 分ずつ比べました。 うまく分かれた録音では、TitaNet large(NVIDIA)と ERes2Net base(3D-Speaker)で 132 秒と 136 秒にきれいに分かれ、「これだ」と思いました。でも偏った録音では、同じ 2 つのモデルが 268 秒と 4 秒、266 秒と 5 秒です。7 つのモデルのどれを使っても同じように偏りました。 1 本目の録音だけで比べていたら、TitaNet が正解に見えていたはずです。 自分はほとんど話していなかったかもしれない 775 秒と 17 秒という結果を見たとき、自分はこう話していました。 そうですね。私はあんまり喋れなかったと思います。そもそも今回講師の英語があんまり理解できなかったので、喋る回数が非常に少なかったかもしれません。特に最初の方は。 本当に自分の発言が少なかったなら、この数字は正しいのかもしれません。ツールは正しく動いていて、レッスンで自分があまり話せなかっただけ、という可能性も出てきました。 そこで ChatGPT 用に書き出した文字起こしを読んでみると、自分の自己紹介の音読がすべて講師の発言になっていました。やはりツールが間違えていました。 <!-- TODO(本人): 画像 2。自己紹介の音読が講師側に入っている文字起こし(自分の名前・講師名はぼかす) --> 誰の声か確実に分かる区間を 10 か所選ぶ ここまでは、話者ごとの秒数を見て、分かれていそうかどうかをなんとなく判断していました。誰の声かという正解と比べていなかったので、1 本目でうまく分かれたように見えても、本当に合っているかは分かりません。 そこで文字起こしの内容から、誰の声か確実に分かる区間を選ぶことにしました。講師の区間を 5 か所、自分の区間を 5 か所で、長さはそれぞれ 8〜40 秒です。内容を読めば判断できる区間だけを選んだので、1 時間ほどでできました。 声の特徴は 2 人を区別できていた 正解の区間ができたので、話者分離の 3 つの手順のどこで間違えているかを調べました。録音に 2 人の声が入っていることは最初に確認したので、次は手順 2 の埋め込みが 2 人の声を区別できているかを測りました。 正解の区間を 30 個の断片に分けて、断片同士の埋め込みがどれくらい近いかをコサイン類似度で測りました。1 に近いほど似ている、という数値です。 組み合わせ 類似度 同じ人の断片どうし 0.56 違う人の断片どうし 0.26 30 個の断片のうち 29 個は、埋め込みだけで正しい話者に分けられました。埋め込みは 2 人の声を区別できていて、間違えていたのは手順 3 のクラスタリングのほうでした。モデルを替えて変わるのは埋め込みなので、原因がクラスタリングにあるなら、モデルをいくつ試しても直りません。 sherpa-onnx の話者分離は、クラスタリングまで含めて 1 つの API になっています。その中のクラスタリングが、講師の声だけがスピーカー越しという今回の録音の条件に合わなかったのだと思います。 クラスタリングだけを自前のものに替える 区間の切り出しはライブラリの結果をそのまま使い、区間ごとに埋め込みを取り直して、クラスタリングだけを自前のものに替えました。中身は次の通りです。 埋め込みが近い区間同士を、近い順にまとめていく(平均リンク法の凝集型クラスタリング) 話している時間の合計が長い上位 2 つのまとまりを、2 人の話者とする 残った小さなまとまり(相づちや雑音)は、近いほうの話者に入れる 正解の区間で測ると、偏っていた録音の正解率は 78% から 98% になりました。もともと分かれていた録音は 92% のままで、下がってはいません。 <!-- TODO(本人): 画像 3。直したあとの結果の画面(話者 A / B に分かれている。ツール名・講師名が映らないように) --> 「精度が落ちた」と感じたときも測った その後、処理を速くするために、区間を切り出す部分を別の方法に差し替えました。 「ちょっと精度落ちたけどめちゃ早くなったいいやん!」って感じたので、実際に精度を比べてみました。 正解の区間で測り直した結果は次の通りです。 録音 差し替え前 差し替え後 偏っていた録音 98.2% 97.8% 分かれていた録音 91.7% 92.1% 精度はほとんど変わっていませんでした。感覚では落ちたと思っていましたが、正解の区間と比べて変わっていないと分かったので、ここは直さないことにしました。 まとめ 今回は、録音、環境、モデルの順に原因を疑いました。録音を最初に確かめたのはよかったのですが、その後は埋め込みとクラスタリングのどちらが間違えているかを確かめないまま、環境やモデルを替えにいっていました。 誰の声か確実に分かる区間を 10 か所選んで測ると、どの手順で間違えているかが分かりました。うまく分かれた録音と偏った録音の両方で試していたので、1 本目の結果だけでモデルを決めずに済んでいます。 間違えた例を実際に見て原因を調べる進め方は、Andrew Ng の講座 Structuring Machine Learning Projects でも「Carrying Out Error Analysis」(エラー分析)として紹介されています。 おわりに そもそも文字起こしに労力をかける気は全くなかったので、最初は ChatGPT に録音をそのまま読み込ませようと思っていました。ただ、長すぎて読み込めなかったので、自分で作る方向に転換しました。 基本的に、何かを作るというのは負債になりますし、時間もかかる行為です。すでに手段があるなら、積極的に活用していくべきだと思いました。 とはいえ、いろいろな数値が取れましたし、AI があるのですぐに開発ができて、結構楽しい経験になりました。まだここで話していないこともあるので、別の記事で話そうと思います。 参考 openai/whisper - GitHub k2-fsa/sherpa-onnx - GitHub Speaker Diarization: Pre-trained models - sherpa documentation pyannote/pyannote-audio - GitHub nvidia/speakerverification_en_titanet_large - Hugging Face modelscope/3D-Speaker - GitHub コサイン類似度 - Wikipedia Hierarchical clustering - Wikipedia Structuring Machine Learning Projects - Coursera

  2. Bro asked AI to reboot the server and it rebooted his entire bloodline. Source: codex#59060

    8 favourites · 2 comments · 4 boosts
  3. NVIDIAの音声修復モデルRE-USEでポッドキャストのノイズ除去と文字起こしを比較してみた 散歩しながらポッドキャストを録っていると、風切り音や周囲の音がどうしても入ります。私は「からあげ帝国放送局」というポッドキャストをしているのですが、そのノイズ低減に、今話題のNVIDIAの音声修復モデルRE-USEを試してみました。ノイズ低減と合わせて気になったのが、修復した音声を文字起こしに使った方がよいかで、そこも合わせて確認しています。 実際の配信音声を「原音」「音量調整のみ」「RE-USEで修復して音量調整」の3条件でWhisperに入力してみました。 この記事ではその比較結果と、ポッドキャストの文字起こしから概要・目次を作るまでのおすすめワークフローを紹介します。 先に結論を書くと、私は「文字起こしは原音、配信用は修復した音声」と使い分けることにしました。ただし、強風の区間では修復後に文字起こしが改善した例もあり、ノイズが大きい箇所では両方を比べるのがよさそうです。 あくまで自分の環境や条件、データでの話です。詳しく知りたい方は続きを読んでいただけましたら幸いです。 ! 今回の比較は2つの配信回を使った事例です。後半の結果は、AIが作った基準文との差を測ったものとなるのでご了承ください。 音声の違いを確認 こちらは第100回の冒頭を使った、風切り音の処理前後を比較する動画です。約48秒で、同じ発話を処理前・処理後の順に聴けます。比較用に音量を合わせ、波形と処理中の条件を表示しています。 x.com 元の配信は、以下から聴けます。冒頭60秒が強風音源の文字起こし比較に使った範囲です。 第100回の配信ページ 第100回の音声ファイルを開く ここでいう「原音」は、今回のRE-USE処理や音量調整をかける前の入力です。 RE-USEとWhisperの役割と仕組み ASRはAutomatic Speech Recognition(自動音声認識)の略で、音声を文字に変換する技術です。この記事では文字起こしと同じ意味で使っています。 今回使った修復モデルは、nvidia/NVIDIA-NemotronLabs-RE-USEの標準版です。音声のノイズや残響などを扱うモデルで、文字起こしには別途Whisperを使いました。 RE-USEは音声を入力して、修復した音声を出力 Whisperは音声を入力して、文字起こしを出力 モデルの説明と公式の試用デモへの入口はこちらです。 huggingface.co RE-USEのノイズ除去の仕組み 今回の標準版は約960万パラメータで、畳み込みによるエンコーダー・デコーダーと、時間・周波数方向を扱う双方向Mambaを組み合わせています。構成は公式モデルカードに記載されています。 公式の推論コードを見ると、入力音声を短時間フーリエ変換で時間と周波数の表現に変え、モデルに振幅と位相を渡し、推定した振幅・位相から波形へ戻しています。振幅は各周波数の強さ、位相は波の位置関係に相当します。モデル実装では、これらをそれぞれのデコーダーで出力しています。 入力波形 → 時間と周波数の特徴 → Mambaで特徴を処理 → 修復後の振幅と位相を推定 → 音声波形へ戻す つまり、修復後の音声は学習したモデルによる推定結果です。「ノイズ部分だけを完全に識別して取り除き、声をそのまま残す」ことをしているわけではありません。 Whisperの音声認識の仕組み Whisperは、音声の特徴をエンコーダーで処理し、デコーダーがそれまでに出した文字列も参照しながら次のトークンを予測する音声認識モデルです。音声はメルスペクトログラムという、周波数ごとの強さを時間に沿って並べた表現へ変換されます。Whisper論文の2.2節 このため、音が少し変わった場合でも認識結果が同じとは限らず、逆にノイズが残っていても文脈を手がかりに認識できる場合があります。修復後に聞こえ方が改善しても、Whisperが単語を選ぶための手がかりまで同じように改善するとは限らない、と考えると今回の比較を理解しやすくなります。 比較した音源と条件 本記事で取り上げる比較は以下です。 音源 比較範囲 特徴 第190回 全編17分41秒 通常の一人語りで認識結果の差を確認 第100回 冒頭60秒 風切り音が大きい区間 それぞれ、同じ音源から次の3条件を用意しました。 条件 処理 初回ASRへの入力 A 原音を音量変更なしで展開 PCM WAV B 音量調整のみ MP3 C RE-USE修復後に音量調整 MP3 BとCの音量調整は、目標を-16LUFS、ピークの上限を-1.5dBTPとする二段階の処理です。RE-USE側では24kHzモノラル化し、10秒単位、1秒重複で処理しています。 最初はWhisperのmediumで6条件を認識しました。言語は日本語、DGX SparkでCUDAを使用しています。使用したopenai-whisperは20250625、PyTorchは2.10.0+cu130です。 第190回の差分3区間を各15秒、第100回を60秒、合計105秒に揃え、large-v3とmediumのそれぞれで3条件を再認識しました。各モデル12件ずつの追試です。 ! これは、配信で実際に使う処理工程全体の比較です。WAVとMP3の違い、サンプリング周波数の変換、分割処理なども含むため、RE-USE単体の効果を示しているわけではありません。 修復後に誤認識が増えた例 第190回の13分21秒付近では、次の差が出ました。以下はASRの出力です。 原音 平気で2日3日遅れて変身していたようなメール 音量調整のみ 平気で2日3日遅れて変身していたようなメール RE-USE+音量調整 平気で深みか遅れて変身していたようなメール 「2日3日」が「深みか」になる差は、15秒区間でのmediumとlarge-v3の追試でも再現しました。 一方、「返信」に見える文脈で「変身」と出力している部分は、上の3条件とも同じです。原音を使えばすべて正しくなるわけではありません。概要を作る前に、こうした同音異義語も確認する必要があります。 第190回の全編認識では、修復後だけ「判断」が「ハンダー」になったり、「チュンチュン」が文字列から抜けたりする例もありました。ただし、短区間でlarge-v3を使うと修復後でも認識されています。文字列から語が抜けたことだけで、音声からその成分が消えたとは言えません。入力する区間やモデルの違いも影響します。 RE-USEで認識が改善した例 第100回の冒頭60秒では、mediumの出力に次の違いがありました。 原音 金魚の公園 音量調整のみ 金魚の公園 RE-USE+音量調整 近所の公園 散歩しながらの収録という文脈では、「近所の公園」のほうが自然です。 ただし、large-v3では原音でも「近所」と認識しました。 CERでの比較結果 同じ105秒について、large-v3による原音の認識結果を自動基準文として固定し、mediumの3条件を比較しました。 CERは文字単位の置換・削除・挿入の合計を、基準文の文字数で割ったものです。今回は人手で確定した正解文ではないため、数値は参考値です。 CER = (置換数 + 削除数 + 挿入数) / 基準文の文字数 Unicode NFKC正規化と小文字化を行い、空白・句読点・制御文字を取り除きました。漢字とかなの表記差は残しています。基準文はこの処理後で567文字です。 mediumへの入力 自動基準文に対するCER 編集数 原音 4.23% 24文字 音量調整のみ 4.41% 25文字 RE-USE+音量調整 5.11% 29文字 今回選んだ区間では原音が自動基準文に最も近い結果でした。 修復が役立つ条件を区間ごとに考える 全体の集計では強風区間の改善が隠れる 同じ追試データを区間別に見ると、原音と修復版の関係は一様ではありません。次の表も、large-v3の原音出力を基準にしたmediumのCERです。 区間 原音 音量調整のみ RE-USE+音量調整 第190回の鳥の話15秒 5.10% 6.12% 12.24% 第190回の判断の話15秒 3.45% 3.45% 3.45% 第190回の2日3日の話15秒 4.82% 4.82% 9.64% 第100回の強風60秒 4.01% 4.01% 2.01% 強風区間では基準文299文字に対する編集数が12から6に減っています。一方、鳥の話では5から12、2日3日の話では4から8へ増え、判断の話では3のままでした。合計の24対29という値には、改善した箇所と悪化した箇所の両方が入っています。 公式評価でのASR改善例 公式モデルカードのURGENT 2025 non-blindテストセット全体では、OWSM v3.1を使った文字認識の指標CAccが、ノイズ入り音声の81.29からNemotronLabs RE-USE処理後の89.17へ改善しています。公式評価表 これは開発元による別データ・別ASRでの評価で、今回の日本語ポッドキャストとWhisperによるCERとは直接比較できません。それでも、音声修復がASRにも役立つ条件があることを示す結果です。 ポッドキャスト向けのおすすめワークフロー 今回の結果を踏まえ、私のポッドキャストでは次の流れにしています。 文字起こしが修復の完了を待つ必要もなくなります。ただし、同じGPUで同時に実行すると処理が競合する場合があるので、実行順は環境に合わせてください。 transcriber-toolで文字起こしする 文字起こしを手軽に試すなら、私が作ったtranscriber-toolも使えます。Whisperを利用するCLIツールで、タイムスタンプ付きの出力にも対応しています。導入方法やGPUの使い方は、以前のZenn記事にまとめています。 zenn.dev Python 3.11以上とuvを用意すれば、例えば原音から展開したasr-input.wavを次のコマンドで文字起こしできます。 uvx transcriber_tool transcribe asr-input.wav \ --model-size medium --language ja --timestamps --output transcript.txt transcript.txtの誤認識を確認してから、時刻情報と一緒にLLMへ渡すと概要や目次を作る材料になります。音声をカットした場合は、目次の時刻を配信用音声で確認します。 まとめ NVIDIAの音声修復モデルRE-USEを使用した条件別での比較結果とポッドキャストでの活用例について紹介しました。 ポッドキャストの強い味方になりそうな強力なAIモデルだと思います。文字起こしと併用するときは、文字起こし用と配信用で入力音声を使い分けるとよいのではないかと思います。本記事が何かの参考になりましたら幸いです。 参考資料 NVIDIA-NemotronLabs-RE-USEのモデルカードと公式デモへの入口 OpenAI Whisper 今回使用したWhisper 20250625の公開版 RE-USE関連論文 Whisper論文

  4. Codex Was Torching Your SSD and Nobody Noticed for Months Your Codex log file looked fine. Your SSD counters did not. The file was small. That was the trick. If you opened <code>~/.codex/</code>, you could see a SQLite database called <code>logs_2.sqlite</code>. It was not huge. It was not swallowing the disk. Finder, Explorer, <code>du</code>, and every normal storage check had nothing dramatic to say. Meanwhile, one developer's SSD recorded roughly 37 TB of writes in 21 days. That works out to about 1.7 TB a day. If you stretch one heavy, continuous-use report across a full year, it becomes roughly 640 TB. The number is not a prediction for every Codex user. It came from one machine running for a long time. But it exposed a problem that is easy to miss with local developer tools: > a file can stay small while the storage device underneath it gets written to constantly. This is the story of a noisy TRACE logging sink, a SQLite database doing exactly what it was told, and the SSD wear that nobody could see from file size alone. The quick version - A user reported unusually high local disk writes and traced them to Codex CLI's <code>logs_2.sqlite</code> database and its WAL companion file. - The reported machine accumulated about 37 TB of writes over 21 days of uptime. - The file stayed bounded because new logs were inserted while older logs were deleted. - The reported cause was an overly verbose TRACE logging path that did not fully respect the expected <code>RUST_LOG</code> override. - The supplied investigation says version 0.142.0 reduced the noisy writes substantially, with early testing reporting around 85% fewer log writes. - If you used an older build heavily, update first, then inspect real write activity and your SSD's lifetime-write counters. The number that made people look twice 37 TB in 21 days is not a normal “developer tool wrote some logs” story. | Measurement | Value | | --- | --- | | Reported writes | ~37 TB | | Reporting window | 21 days | | Approximate daily rate | ~1.7 TB/day | | Annualized at that rate | ~640 TB/year | The annualized number needs context. It assumes the same workload every day for a year, which is rarely how people work. Someone running short sessions will produce far less. Someone leaving the tool open, working with long sessions, or using it in automation could produce much more than they expect. The useful point is not “every SSD will die in a year.” The useful point is that this level of write activity belongs in the category of things you should notice and control. <!-- Visual placement: use a clean SMART dashboard screenshot here, with all serial numbers and personally identifiable drive details blurred. --> Why the file size told you almost nothing Most of us check disk problems like this: du -sh ~/.codex ls -lh ~/.codex/logs_2.sqlite* Those commands answer one question: > How much data is stored right now? They do not answer this: > How much data has been written over time? The Codex log database was designed to retain a bounded amount of diagnostic information. New rows were written, old rows were removed, and the database could remain roughly the same size. So the folder looked calm while the disk was doing constant work. Imagine a café with four tables. Looking through the window at noon, you see four people sitting down. Come back at 6 PM, still four people. The table count tells you nothing about whether eight customers visited or eight hundred. The SQLite file was the same. Stable size, enormous turnover. !Diagram showing how a small SQLite log file can lead to high SSD write activity What was generating all those writes? The reported issue points to a logging path that defaulted to TRACE, the most detailed level in Rust's tracing ecosystem. TRACE logging is useful when you are trying to understand a very specific failure. It can include low-level events that are normally too noisy for everyday use: - file-open events - raw network or WebSocket activity - transport details - telemetry plumbing - dependency-library messages that get bridged into the application's tracing system The supplied breakdown estimates that TRACE-level entries made up 70.7% of the retained log-body size. The highest-volume targets included WebSocket handling, OpenTelemetry-related logs, a generic dependency log bridge, and client transport code. That is diagnostic exhaust. A little of it is fine. A default stream of it, persisted locally in SQLite, is a different kind of workload. The three parts that stacked together No single part of this design has to be bad on its own. 1. TRACE was active where it should have been opt-in TRACE is not a normal default for a tool used for hours at a time. It is the level you turn on when you are actively debugging. The reported behavior was that Codex initialized a feedback logging sink at TRACE. That turns every routine interaction into a lot of diagnostic detail. 2. RUST_LOG=warn did not fully quiet it Rust developers often reach for this first: RUST_LOG=warn codex That is supposed to turn down the volume. According to the issue analysis, it did not fully apply to the relevant sink. If a target did not have an explicit override, Codex's internal default still allowed noisy logging. That is worse than an obvious missing setting. A user can think they reduced logging while the disk keeps receiving the same workload. 3. SQLite turned event noise into storage churn SQLite is excellent. It is also not magic. For small structured local data, a SQLite database is a good choice. For a constant stream of fine-grained TRACE events, inserts, deletes, indexes, and checkpoints, it can create a lot of writes even when the database never becomes large. The problem was not “SQLite is bad.” The problem was using a write-heavy retention loop as a sink for a log level that should not have been permanently enabled. The part the operating system does not show you There are two kinds of amplification in this story. SQLite write amplification SQLite often uses WAL mode, short for write-ahead logging. In simplified form: 1. A log event is appended to the WAL file. 2. SQLite later checkpoints that change into the main database. 3. Older rows are deleted to keep retained data bounded. 4. Indexes and database pages are updated along the way. One logical log event can therefore create more than one write at the filesystem level. The WAL is not wrong. Checkpoints are not wrong. The problem appears when that loop is fed relentlessly with small, noisy events. SSD write amplification An SSD has its own internal life. It writes data in small pages but erases much larger blocks. When a small part of a block changes, the SSD controller often writes the new data to a fresh location, marks old data stale, later moves still-valid pages, and erases the old block. That movement is called garbage collection. Wear leveling moves writes around so one physical area does not wear out first. Both are useful. Both mean the flash may receive more physical writes than the operating system asked for. The ratio is called the write amplification factor. The exact number varies by drive, spare capacity, free space, workload, and controller. The supplied analysis does not measure the multiplier for the affected drive, so do not treat any guessed physical-wear number as a precise fact. The direction is enough: > High-churn, small random writes are one of the workloads SSDs work hardest to manage. Is 640 TB actually dangerous? It can be. SSDs have an endurance rating usually expressed as TBW, or terabytes written. A typical 1 TB consumer SSD may be rated for a few hundred TBW. Enterprise drives may be rated much higher. The exact number depends on the model, capacity, NAND type, and warranty. That does not mean a drive fails the moment it reaches its rated TBW. Ratings are warranty and endurance guidance, not a timer that hits zero at midnight. Plenty of drives outlive them. But a background development tool potentially consuming hundreds of terabytes of writes is still worth taking seriously. It can eat through a meaningful part of the drive's expected write budget without filling the disk or showing a visible failure. How to check your own machine The order matters. Update first. Then look at real I/O. Then check what the drive itself says. Step 1: update Codex The investigation supplied with this article identifies 0.142.0 as the version containing the logging reduction. Check the current release notes and your installed build, then update before you start measuring. Also remember that Codex CLI, the desktop app, and editor integrations can ship or bundle components on different schedules. Updating one does not automatically prove every local Codex-related process is updated. Step 2: find the log files On macOS and Linux: ls -la ~/.codex/logs_2.sqlite* On Windows PowerShell: Get-Item "$env:USERPROFILE\.codex\logs_2.sqlite*" You might see the database, a <code>-wal</code> file, and a <code>-shm</code> file. Do not stop after checking their size. A small database is the whole reason this incident was easy to miss. Step 3: watch actual writes On Linux, <code>pidstat</code> can show which process is writing: pidstat -d 5 To see whether a process has the database open: sudo lsof ~/.codex/logs_2.sqlite On macOS, open Activity Monitor, select the Disk tab, and watch bytes written for Codex-related processes while you work. On Windows, use Resource Monitor or Task Manager's disk column. Look at sustained per-process writes, not just a brief spike during startup. Step 4: check the drive's own lifetime write counter This is the closest thing to the truth you have. On Linux or macOS with smartmontools installed, an NVMe drive can often be checked with: sudo smartctl -a /dev/nvme0 Look for: - Data Units Written - Percentage Used - warnings or critical health indicators On Windows, CrystalDiskInfo exposes Total Host Writes and health information. PowerShell can also show some device health data: Get-PhysicalDisk | Get-StorageReliabilityCounter | Select-Object DeviceId, Wear, Temperature Compare lifetime writes with the TBW rating for your exact drive model. Do not compare against a random SSD number from a search result. <!-- Visual placement: add a small annotated image of a SMART page here. Highlight only Data Units Written or Total Host Writes, Percentage Used, and health status. --> What if I used an older version for months? First, do not panic and do not guess from file size. Check the drive counters. If the drive has low percentage used and reasonable total writes for its age and workload, update and move on. If the drive has unusually high wear, warnings, or a large write count compared with its TBW rating, back up your important data and plan for a replacement before failure forces the schedule. This is a good backup reminder even if your drive looks healthy. SSDs usually fail without much theatre. Workarounds if you cannot update immediately Updating is the right fix. These are temporary ways to reduce persistent write pressure while you arrange that update. Put throwaway logs on ephemeral storage For CI jobs and containers, the cleanest option is usually to run with a temporary home directory or mount the relevant config directory on ephemeral storage. Example for a disposable CI environment: export HOME="$(mktemp -d)" For a container workload, mount a tmpfs at the appropriate Codex state directory if the environment can tolerate losing local diagnostics when the job exits. This is especially useful for build runners that create and destroy their environment anyway. Be careful with /tmp Moving a log file to <code>/tmp</code> is only useful if <code>/tmp</code> is actually memory-backed in your environment. On many Linux systems it may be tmpfs. On macOS, <code>/tmp</code> is not automatically a RAM disk by default. Check the mount before assuming the write load vanished: mount | grep ' /tmp ' Then verify with a real I/O monitor. Never trust a workaround because it sounded plausible in a comment thread. Avoid unsupported database surgery unless you really need it Some community workarounds modify the SQLite log database so inserts are ignored. That can be useful in an emergency, but it is an unsupported change to an internal application file. Future versions may change the schema or assume the database behaves normally. If you choose that route, stop Codex first, make a copy of the database, document what you changed, and remove the workaround once you are on a fixed release. The bigger lesson for tool builders This bug is bigger than one CLI. Measure bytes written, not just disk space used Every local persistence feature should have an I/O budget under realistic usage. Test bytes written per hour, per session, and per day. File size is not a sufficient metric for databases, caches, indexes, or log rotation systems. TRACE must be an intentional decision Verbose logging needs an explicit opt-in and a clear way back out. Shipping it by default turns every user into a debugging environment. Standard controls have to work end to end If your ecosystem has a standard logging override, honour it for every sink. A partial override is dangerous because it gives experienced users false confidence. Structured logs have storage costs SQLite, RocksDB, local search indexes, and caches are all good tools. High-frequency writes have a cost. The design needs backpressure, batching, rate limits, retention rules, and test coverage for pathological verbosity. Privacy and wear are connected The more raw operational detail a tool records, the more it writes and the more sensitive local data it can retain. Logging file paths, raw transport frames, and low-level event payloads should be a deliberate debugging choice, not background noise. The bigger lesson for users There is a simple habit worth keeping: > When you install a new long-running developer tool, look at its write rate once. Two minutes in Activity Monitor, Resource Monitor, or <code>pidstat</code> can catch a surprising amount. Check lifetime SSD writes occasionally. Keep your tools updated. Treat a stable file size as a storage number, not an I/O number. The log file was small. The work it made the SSD do was not. What is confirmed and what is still uncertain The supplied investigation is clear about its limits, and those limits matter: - The 37 TB measurement came from one heavy user's machine. It is a data point, not a universal rate. - Reports disagree about when the highest logging verbosity began. The exact start date is uncertain. - The annualized 640 TB figure is arithmetic based on the reported 21-day sample, not a forecast. - SSD write amplification is real, but the exact physical NAND multiplier was not measured for this incident. - The reported 85% reduction after version 0.142.0 is an early observed result, not a guarantee for every platform or workload. That uncertainty does not weaken the main finding. The correct response is still simple: update, measure the process, and inspect the drive counter. Sources and further reading - GitHub issue #28224 in openai/codex - Official OpenAI Codex documentation - The public reporting and technical analysis supplied for this article, including Notebookcheck, Windows Report, Lilting.ch, yage.ai, and Daniel Vaughan's write-up

    11 reactions · 9 comments
  5. arXiv · · math.CO · Joshua Morris Mr. · openai/math

    A proof of Ryser's circulant Hadamard conjecture We show that an $n\times n$ circulant Hadamard matrix must satisfy a family of congruence equations that have solutions only when $n \leq 4$, proving Ryser's 1963 conjecture that no such matrices exist for $n>4$. Comments: Error found by AI. Corrected proof may be found here: github.com/openai/math/tree/main/preprints/The-ci…

  6. Four GPUs, One Quantization Ladder: Gemma 4 E2B From a 4 GB Laptop to an NVIDIA L4 --- title: "Four GPUs, One Quantization Ladder: Gemma 4 E2B From a 4 GB Laptop to an NVIDIA L4" published: true description: "Gemma 4 E2B from BF16 to Q2_K on a Tesla T4, an NVIDIA L4, a GTX 1650 laptop and an RTX 3050 desktop, with byte-identical GGUF files and the same llama.cpp build. The ladder keeps its shape on all four cards, 218 questions die on all four, and any two GPUs grade 2 to 4 questions differently at BF16." tags: gemma, llamacpp, quantization, nvidia cover_image: raw.githubusercontent.com --- This article provides a step by step guide to running Gemma 4 E2B's quantization ladder, BF16 down to Q2_K, on four NVIDIA GPUs with the same nine GGUF files and the same llama.cpp build, and comparing the four cards question by question. xbill9/gemma-graveyard The first article asked every rung of the ladder the same 250 GSM8K questions on a Tesla T4. The second repeated it on an NVIDIA L4 in AWS. This one adds two consumer cards: a GTX 1650 Ti laptop GPU with 4 GB and an RTX 3050 desktop card with 8 GB. All four run llama.cpp b11699 on files with the same sha256, and each card gives identical text when BF16 is run twice. --- The Results in Brief The ladder keeps its shape on all four GPUs. Against each card's own BF16, F16 to Q5_K_M lose 1 to 8 answers, Q4_K_M and Q4_0 lose 9 to 19, Q3_K_M loses 42 to 49, and Q2_K gets 3 to 6 right out of 250. The counts agree; the questions move. Any two GPUs grade 2 to 4 questions differently at BF16 and 12 to 22 at Q4_0. No question is lost at F16 or Q8_0 on all four cards, while 216 are lost at Q2_K on all four. 218 questions die at some rung on every GPU, and 147 of them die first at the same rung on every GPU. The 4 GB laptop runs every quantized rung entirely on its GPU. BF16 and F16 do not fit, so llama.cpp splits them between GPU and CPU, and they decode at 9.2 and 9.6 tokens per second against 45.9 for Q8_0 on the same card. The cover lays the four GPUs' grades over each other. One row per rung, BF16 at the top and Q2_K at the bottom, one cell per question: marigold where all four GPUs answer right, grey where all four answer wrong, violet where they disagree. docs/make_cover_gpu4.py draws it from the committed rows. --- What Changes and What Stays | | Tesla T4 | NVIDIA L4 | GTX 1650 Ti | RTX 3050 | | :--- | :--- | :--- | :--- | :--- | | Where | GCE n1-standard-2 | AWS g6.xlarge | laptop | desktop | | GPU memory | 15,360 MiB | 23,034 MiB | 4,096 MiB | 8,192 MiB | | Compute capability | 7.5 | 8.9 | 7.5 | 8.6 | | Host CPU | 2 vCPU | AMD EPYC 7R13 | Intel i7-10750H | Intel i7-5820K | | Driver | 615.71.10 | 595.112.07 | 615.71.10 | 615.78.08 | The same on all four: llama.cpp b11699 with GGML_CUDA=ON, built for each card's own compute capability; the nine GGUFs and Google's QAT Q4_0 file, byte for byte; the 250 questions in data/heldout.jsonl; temperature 0, one request at a time, thinking off, 1,024 max tokens, llama-server -c 4096 -np 1 --seed 0. Every rung runs with -ngl 99 except BF16 and F16 on the GTX 1650 (Step 4). --- At This Point You Should Have… - An NVIDIA GPU with at least 4 GB and a CUDA toolkit - About 58 GB of free disk for the checkpoint, the nine GGUFs and the QAT file - A clone: git clone https://github.com/xbill9/gemma-graveyard - The T4 run's committed results in runs/2026-10-27-ladder/ --- Step 1 — Build llama.cpp at the Same Tag On the RTX 3050: git -C ~/llama.cpp worktree add --detach /android/graveyard/llama.cpp b11699 cd /android/graveyard/llama.cpp cmake -B build -DGGML_CUDA=ON -DCMAKE_CUDA_ARCHITECTURES=86 -DCMAKE_BUILD_TYPE=Release cmake --build build -j12 --target llama-server llama-quantize The one build flag that changes per card is CMAKE_CUDA_ARCHITECTURES: 75 for the T4 and the GTX 1650, 89 for the L4, 86 for the RTX 3050. nvidia-smi --query-gpu=name,memory.total,compute_cap,driver_version --format=csv name, memory.total [MiB], compute_cap, driver_version NVIDIA GeForce RTX 3050 OEM, 8192 MiB, 8.6, 615.78.08 🔎 Tip: keep the pinned build in its own worktree. The desktop already had a newer llama.cpp checkout (b11983). git worktree add --detach <dir> b11699 gives a second working copy at the tag from the same clone, so the measured build and the everyday build sit side by side. --- Step 2 — Rebuild the Ladder and Check It Against the T4 ladder.sh converts the checkpoint to BF16 and F16 and quantizes seven rungs from BF16. Each run script then compares every file's size and sha256 with the T4's ladder.tsv: diff <(cut -f1,3,4 runs/2026-10-27-ladder/ladder.tsv) <(cut -f1,3,4 runs/2026-10-29-3050/ladder.tsv) && echo "ladder matches T4 sha256" ladder matches T4 sha256 The GTX 1650 and the RTX 3050 both print the same line, and Google's QAT Q4_0 file matches too (sha256 fa401b55…). Across the four machines, the GGUF bytes are identical; the card, its driver, its CUDA version and the kernels built for it are what differ. 🔎 Tip: the converter writes the checkpoint directory into the GGUF. convert_hf_to_gguf.py copies the model card and takes the model's name from the directory it reads. A checkpoint taken straight from the Hugging Face cache snapshot has neither the README.md nor the name gemma-4-E2B-it, and gives different bytes. Download with hf download google/gemma-4-E2B-it --local-dir <dir>/gemma-4-E2B-it. --- Step 3 — Prove Each Card Repeats Itself BF16 on 50 questions, twice, on every GPU: ./graveyard.py repeat runs/2026-10-29-3050/determinism-1 runs/2026-10-29-3050/determinism-2 BF16 {"rung": "BF16", "n": 50, "mismatched_extracted": 0, "mismatched_text": 0, "mismatched_right": 0, "right_a": 46, "right_b": 46} The T4, the L4 and the GTX 1650 give the same result: 0 mismatched characters and 46 of 50 right both times. Each card on its own is deterministic, so a difference between two cards comes from the GPU and its CUDA stack. --- Step 4 — Fit the 16-bit Rungs on 4 GB BF16 and F16 need a 4,384.87 MiB GPU buffer for their 36 layers (from the T4's load log), and the GTX 1650 has 4,096 MiB. With -ngl 99 the load fails. graveyard.py run --ngl auto leaves -ngl off, and llama.cpp's fit step places what it can: common_params_fit_impl: - CUDA0 (NVIDIA GeForce GTX 1650 Ti with Max-Q Design): 14 layers, 2546 MiB used, 1125 MiB free load_tensors: offloaded 14/36 layers to GPU load_tensors: CUDA0 model buffer size = 2407.92 MiB Every other rung fits whole. Q8_0 on the same card: load_tensors: offloaded 36/36 layers to GPU load_tensors: CUDA0 model buffer size = 2342.30 MiB The split changes speed and leaves the grades in line with the other GPUs: the GTX 1650's BF16 scores 229, the same as the T4 and the L4, and grades 2 to 4 questions differently from each of them. The 8 GB RTX 3050 holds BF16 whole at 4,651 MiB. --- Step 5 — Run the Ladder on Each Card and Score It Each run script runs the nine rungs and QAT Q4_0, then scores every rung against that card's own BF16: ./graveyard.py bury runs/2026-10-29-3050 BF16 F16 Q8_0 Q6_K Q5_K_M Q4_K_M Q4_0 Q3_K_M Q2_K --json graveyard-ladder.json Right answers, out of 250: | Rung | T4 | L4 | GTX 1650 | RTX 3050 | | :--- | :--- | :--- | :--- | :--- | | BF16 | 229 | 229 | 229 | 232 | | F16 | 229 | 229 | 228 | 232 | | Q8_0 | 227 | 228 | 229 | 226 | | Q6_K | 229 | 227 | 226 | 227 | | Q5_K_M | 231 | 228 | 226 | 226 | | Q4_K_M | 224 | 221 | 222 | 221 | | Q4_0 | 222 | 220 | 216 | 218 | | Q3_K_M | 191 | 186 | 183 | 191 | | Q2_K | 3 | 6 | 5 | 3 | Lost, against the same card's BF16: | Rung | T4 | L4 | GTX 1650 | RTX 3050 | | :--- | :--- | :--- | :--- | :--- | | F16 | 1 | 1 | 2 | 1 | | Q8_0 | 4 | 3 | 2 | 7 | | Q6_K | 4 | 6 | 7 | 8 | | Q5_K_M | 3 | 6 | 6 | 8 | | Q4_K_M | 9 | 14 | 12 | 14 | | Q4_0 | 15 | 16 | 19 | 16 | | Q3_K_M | 42 | 45 | 49 | 44 | | Q2_K | 226 | 225 | 225 | 229 | Lost: right at BF16, wrong at this rung, on the same GPU. The failures fall into the same kinds on every card. Q3_K_M runs out of room: 33 to 36 of its losses on each GPU are answers cut off at 1,024 tokens. Q2_K loops: 208 to 228 of its 250 answers repeat a line five or more times, and 246 to 249 hit the token cap. --- Step 6 — Line the Four GPUs Up, Question by Question docs/gpu4_derived.py rebuilds the T4's grid from its committed results and reads the other three from their rows, then compares all six pairs of GPUs at every rung: python3 docs/gpu4_derived.py > runs/2026-10-29-3050/four-gpus.txt | Rung | Graded differently, any two GPUs | Lost on all four | | :--- | :--- | :--- | | BF16 | 2 to 4 | — | | F16 | 3 to 5 | 0 | | Q8_0 | 3 to 9 | 0 | | Q6_K | 4 to 10 | 2 | | Q5_K_M | 7 to 10 | 1 | | Q4_K_M | 9 to 15 | 5 | | Q4_0 | 12 to 22 | 5 | | Q3_K_M | 26 to 34 | 20 | | Q2_K | 6 to 9 | 216 | Graded differently: right on one GPU and wrong on the other, at that rung, for the closest and the furthest of the six pairs. - The light rungs lose different questions on each card. F16 and Q8_0 lose 1 to 7 answers per GPU, and none of them is lost on all four. - The deep losses are shared. Q3_K_M loses 20 questions on all four GPUs and Q2_K 216. - Most of the graveyard is common ground. Each GPU has 226 questions that die at some rung, the RTX 3050 230. 218 die on all four, and 147 die first at the same rung on all four. One question dies only on the RTX 3050 (test-358) and one only on the GTX 1650 (test-147). - BF16 itself moves a few answers. 227 questions are right at BF16 on all four cards and 18 wrong on all four. Against the L4, the RTX 3050's BF16 changes the text of 31 answers out of 250, the extracted number of 4 and the grade of 3. --- Step 7 — Google's QAT Q4_0 on Four Cards ./graveyard.py bury runs/2026-10-29-3050 BF16 QAT_Q4_0 Q4_0 --json graveyard-qat.json | GPU | QAT Q4_0 right | Q4_0 right | QAT Q4_0 lost | Q4_0 lost | | :--- | :--- | :--- | :--- | :--- | | T4 | 221 | 🥇 222 | 15 | 15 | | L4 | 219 | 🥇 220 | 15 | 16 | | GTX 1650 | 🥇 222 | 216 | 11 | 19 | | RTX 3050 | 🥇 221 | 218 | 15 | 16 | QAT Q4_0 scores 219 to 222 on the four cards and plain Q4_0 216 to 222. On the T4 and the L4 the plain file is ahead by 1; on the GTX 1650 QAT is ahead by 6 and on the RTX 3050 by 3. The two files lose mostly different questions: on the RTX 3050, 5 questions are lost under both, 10 only under QAT and 11 only under the plain Q4_0. Across the four GPUs, 6 of QAT's losses and 5 of Q4_0's are lost on every card. --- Step 8 — Speed on Each Card Median decode speed in tokens per second. Each column is one machine; read down a column. | Rung | T4 | L4 | GTX 1650 | RTX 3050 | | :--- | :--- | :--- | :--- | :--- | | BF16 | 40.0 | 50.1 | 9.2 | 40.3 | | F16 | 39.6 | 50.0 | 9.6 | 40.3 | | Q8_0 | 64.3 | 83.0 | 45.9 | 67.8 | | Q6_K | 70.8 | 98.1 | 57.2 | 75.3 | | Q5_K_M | 78.7 | 107.7 | 61.9 | 82.2 | | Q4_K_M | 84.1 | 118.7 | 66.5 | 91.5 | | Q4_0 | 🥇 93.6 | 125.6 | 🥇 70.8 | 🥇 99.7 | | Q3_K_M | 74.2 | 111.1 | 55.9 | 64.2 | | Q2_K | 74.0 | 🥇 139.5 | 62.2 | 95.0 | - Q4_0 is the fastest rung on three of the four cards; on the L4 it is Q2_K, which is wrong on 244 of 250 questions. - Q5_K_M decodes 1.21 to 1.35 times as fast as Q8_0 on each card (arithmetic, from the table). Q8_0 is the baseline here because it is the largest rung that fits whole on all four GPUs. - Q3_K_M is slower than Q4_0 on every card, and on the RTX 3050 it is slower than Q8_0. - BF16 and F16 run at the same speed on the T4, the L4 and the RTX 3050. On the GTX 1650, with 22 of 36 layers on the CPU, they run at a fifth of Q8_0's speed. The full ladder with QAT took 5 hours 16 minutes on the RTX 3050 and 12 hours 25 minutes on the GTX 1650, from the first log line to the last (run-3050.log, run-1650.log). --- Compare and Contrast | | T4 | L4 | GTX 1650 | RTX 3050 | | :--- | :--- | :--- | :--- | :--- | | BF16 right of 250 | 229 | 229 | 229 | 🥇 232 | | Q5_K_M lost | 🥇 3 | 6 | 6 | 8 | | Q4_0 right, tok/s | 222, 93.6 | 220, 125.6 | 216, 70.8 | 218, 99.7 | | Every rung whole on the GPU | 🟢 yes | 🟢 yes | ❌ BF16, F16 split | 🟢 yes | | Same text twice at BF16 | 🟢 yes | 🟢 yes | 🟢 yes | 🟢 yes | --- So, Which One? On any of the four cards, take Q5_K_M: 39.0% of BF16's bytes, 226 to 231 right, 3 to 8 answers lost against the card's own BF16, and 1.21 to 1.35 times Q8_0's decode speed. For the fastest file that stays within 19 answers, take Q4_0, the fastest rung on three of the cards. On a 4 GB card, every quantized rung fits whole and the 16-bit rungs run at under 10 tokens per second. To compare two quantizations question by question, run both on one GPU: a different card moves 2 to 4 grades at BF16 and up to 34 at Q3_K_M. --- Summary The goal of this article was to run Gemma 4 E2B's quantization ladder on four GPUs, from a 4 GB laptop card to a data-centre L4, and see which grades hold. The key was holding everything else fixed: byte-identical GGUFs, the same llama.cpp tag and the same sampling, with each card checked to give identical text twice. The four-GPU results were: - 🟢 All nine GGUFs and the QAT file match the T4's sha256 on every machine, and BF16 gives identical text twice on 50 questions on every card. - 🟢 The ladder keeps its shape on all four GPUs: F16 to Q5_K_M lose 1 to 8, Q4_K_M and Q4_0 lose 9 to 19, Q3_K_M loses 42 to 49. - 🟢 Q5_K_M is the best trade on every card: 226 to 231 right at 1.21 to 1.35 times Q8_0's speed. - 🟢 A 4 GB GTX 1650 runs every quantized rung whole on the GPU; BF16 and F16 run split, 14 of 36 layers on the GPU, at 9.2 and 9.6 tokens per second. - ⚠️ Any two GPUs grade 2 to 4 questions differently at BF16 and 12 to 22 at Q4_0; no question is lost at F16 or Q8_0 on all four. - ⚠️ 218 questions die on all four GPUs, 147 of them first at the same rung. - ⚠️ QAT Q4_0 and plain Q4_0 trade places by card: plain ahead by 1 on the T4 and L4, QAT ahead by 6 on the GTX 1650 and by 3 on the RTX 3050. - ❌ Q3_K_M loses 42 to 49, mostly answers cut off at 1,024 tokens; Q2_K gets 3 to 6 right, with 208 to 228 looping answers per card. Scope: one run of each rung per GPU on four NVIDIA cards (a Tesla T4 on GCE, an L4 on AWS, a GTX 1650 Ti laptop GPU and an RTX 3050 desktop card), 250 GSM8K test questions, greedy, thinking off, 1,024 max tokens, llama.cpp b11699 built for each card. Determinism checked at BF16 on each card. The T4 grid is rebuilt from its committed per-question results. The hosts also differ in CPU, RAM, driver and CUDA version, and on the GTX 1650 BF16 and F16 run split between GPU and CPU. Speed is compared within each card only. The strategy for measuring Gemma 4's accuracy one quantization rung at a time on four GPUs was validated with an incremental step by step approach. --- References - Accuracy vs Speed: Gemma 4 E2B Quantization Tradeoffs, BF16 to Q2_K, the T4 article - Performance vs Quality: Gemma 4 E2B Quantization on an NVIDIA L4 and a Tesla T4, the L4 article - gemma-graveyard on GitHub - GTX 1650 run: runs/2026-10-29-1650 - RTX 3050 run: runs/2026-10-29-3050 - llama.cpp - google/gemma-4-E2B-it - google/gemma-4-E2B-it-qat-q4_0-gguf - GSM8K

    10 reactions · 1 comment
  7. Accuracy vs Speed: Gemma 4 E2B Quantization Tradeoffs, BF16 to Q2_K --- title: "Accuracy vs Speed: Gemma 4 E2B Quantization Tradeoffs, BF16 to Q2_K" published: true description: "Gemma 4 E2B quantized from BF16 to Q2_K on one Tesla T4, every rung asked the same 250 GSM8K questions, and each answer buried at the rung where it first goes wrong. Q5_K_M and above hold the score; Q3_K_M loses 38; Q2_K gets 3 right. With thinking on, Q3_K_M wins back 17." tags: devchallenge, hf26challenge, gemma, llamacpp cover_image: raw.githubusercontent.com --- This is a submission for the Hacktoberfest Open-Source AI Challenge Week 4: Ghost in the Machine This article provides a step by step guide to quantizing Gemma 4 E2B down a ladder of nine GGUF files with llama.cpp, asking every rung the same 250 maths questions on one Tesla T4, and burying each answer at the rung where it first goes wrong. Every count is computed by code and every row is committed. xbill9/gemma-graveyard A score per quantization level says how many answers a smaller file loses; a graveyard says which ones. Against the 229 of 250 questions BF16 gets right, Q8_0, Q6_K and Q5_K_M stay within 2, Q4_K_M and Q4_0 lose 5 and 7, Q3_K_M loses 38 and Q2_K gets 3 right. Above Q3_K_M most of the dead come back: 16 of the 23 questions that die between F16 and Q4_0 are right again at a lower rung. With thinking on, Q3_K_M climbs from 191 to 208. --- What I Built Quantization is the most common thing done to an open-weight model before it ships to a small device. The usual report is one accuracy number per file size. Two files with the same score can still get different questions wrong, and a net loss hides its parts: Q4_0 here is 7 answers down on BF16, made of 15 questions lost and 8 gained. The gemma-graveyard asks every rung of a quantization ladder the same 250 questions at temperature 0, so each answer is the model's single most likely one. BF16 is the reference, and every question a rung answers differently from BF16 lands in one of four records: - Dead: BF16 answers it right and the rung answers it wrong. A rung's dead count is every such question at that rung. - Tombstone: one per question, placed at the first rung, going down from BF16, where the question dies. A question dead at Q8_0 and again at Q4_0 has one tombstone, at Q8_0. - Rose again: a lower rung answers a tombstoned question right once more. test-687 dies at F16 and is right again at Q8_0, Q6_K, Q5_K_M and Q4_K_M. - Ghost: BF16 answers it wrong and the rung answers it right. test-1166 asks for an avocado tree's fruit over ten years, answer 2,350. BF16 says 1,000; Q8_0, Q6_K and Q4_0 get it right. A rung's score is BF16's 229, minus its dead, plus its ghosts: Q4_0 is 229 − 15 + 8 = 222. Quantization moves answers in both directions, and a score that holds can hide questions lost and found, so the article reports both. For Día de los Muertos: the dead are remembered one at a time, by name. Each tombstone here carries the question's id, the right answer, the wrong answer the rung gave, and every lower rung where it rose again. What the project delivers: - ladder.sh: BF16, F16 and seven quantized GGUFs of Gemma 4 E2B, with bytes and sha256 - graveyard.py run: one rung, its own llama-server, 250 questions, answers graded in code - graveyard.py bury: deaths, tombstones and ghosts per rung, computed in code - graveyard.py autopsy: how each rung's answers fail (cut off, looping, writing into the thinking block) - graveyard.py repeat: two runs of one rung compared question by question - one run of the whole ladder plus Google's QAT Q4_0 on a Tesla T4, committed with its report - a second pass with thinking on, over seven rungs from BF16 to Q3_K_M --- Demo The Results in Brief Q5_K_M is the best trade between speed and accuracy on the T4. It keeps BF16's score, 231 right against 229, at 39.0% of the bytes and 1.97 times BF16's decode speed. The 2 extra right answers come from the 8 questions where the two disagree, 5 ghosts against 3 dead; two equally accurate models split 8 questions at least that unevenly about three times in four, so the gap is within the noise. Q4_0 is the fastest rung at 2.34 times BF16, and costs 9 right answers against Q5_K_M for 1.19 times its speed. Q4_K_M sits between the two. Every other rung is beaten on both counts by one of those three: Q8_0 and Q6_K are slower than Q5_K_M with fewer or equal right answers, and Q3_K_M is slower than Q4_0 with 31 fewer. Below Q4 the accuracy collapses: Q3_K_M loses 38 and Q2_K gets 3 right. With thinking on, the order holds: Q5_K_M 230, Q4_K_M 226 and Q4_0 219, against BF16's 227. The cover is the graveyard. One row per rung, BF16 at the top and Q2_K at the bottom, one cell per question: marigold where the rung answers right, a grey headstone where it answers wrong. docs/make_cover.py draws it from the committed rows. The ladder, from graveyard.py bury, on 250 GSM8K test questions: | Rung | % of BF16 bytes | Right | Dead | Ghosts | Median tok/s | | :--- | :--- | :--- | :--- | :--- | :--- | | BF16 | 100.0 | 229 | 0 | 0 | 40.0 | | F16 | 100.0 | 229 | 1 | 1 | 39.6 | | Q8_0 | 53.3 | 227 | 4 | 2 | 64.3 | | Q6_K | 41.3 | 229 | 4 | 4 | 70.8 | | Q5_K_M | 39.0 | 🥇 231 | 3 | 5 | 78.7 | | Q4_K_M | 36.8 | 224 | 9 | 4 | 84.1 | | Q4_0 | 36.1 | 222 | 15 | 8 | 🥇 93.6 | | Q3_K_M | 34.4 | 191 | 42 | 4 | 74.2 | | Q2_K | 32.1 | 3 | 226 | 0 | 74.0 | Dead: BF16 right, this rung wrong. Ghosts: BF16 wrong, this rung right. --- Code xbill9/gemma-graveyard | Path | What | | :--- | :--- | | ladder.sh | Converts the checkpoint to BF16 and F16 GGUF, quantizes seven rungs from BF16, writes ladder.tsv | | f16_range.py | Counts the weights that overflow or underflow when BF16 is cast to F16 | | graveyard.py | run, bury, autopsy and repeat | | docs/think_derived.py | Thinking on against thinking off, question by question | | lazy_eval.py | Prompt, answer extraction and grading, reused from Week 3 | | run.md | Every command for the T4, in order, and how to resume after the VM stops | | runs/2026-10-27-ladder/run-ladder.sh | Runs the nine rungs in order, skips finished ones, then buries | | runs/2026-10-27-ladder/ | REPORT.md, the bury and autopsy tables, per-question tombstones | --- How I Built It At This Point You Should Have… - A GCE n1-standard-2 in us-west2-b with one Tesla T4, 15,360 MiB, driver 615.71.10, 2 vCPU and 7,436 MiB of RAM - llama.cpp built with CUDA for compute capability 7.5, at b11699 - google/gemma-4-E2B-it from Hugging Face, the BF16 checkpoint, text model only - google/gemma-4-E2B-it-qat-q4_0-gguf, Google's quantization-aware Q4_0 file - A clone: git clone https://github.com/xbill9/gemma-graveyard --- Step 1 — Build the Ladder ladder.sh converts the checkpoint twice, to BF16 and to F16, then quantizes seven rungs from the BF16 file with plain llama-quantize, with no importance matrix. That is the default a user gets. TMPDIR=/opt1/tmp ./ladder.sh /opt1/models/gemma-4-E2B-it /opt1/graveyard-gguf /opt1/llama.cpp rung file bytes sha256 BF16 /opt1/graveyard-gguf/e2b-BF16.gguf 9311305152 9fe40af9a72302151a5abc28a5057c5fe335eb80145e795ba745085fc73a2ad6 F16 /opt1/graveyard-gguf/e2b-F16.gguf 9311305152 5ab927e4b24a248de319e70467fc74d4ab87347ee9d6fb3ee60b293b12198cf8 Q8_0 /opt1/graveyard-gguf/e2b-Q8_0.gguf 4967497152 6b0301104c89a43c3bec5bae4b14d744f6000bc21e00e46e887fbbfe024de38a Q6_K /opt1/graveyard-gguf/e2b-Q6_K.gguf 3845346752 e800e0389f48646994d8ff6d3409dbf0c13b3fc217d0647b481385da33bd3d99 Q5_K_M /opt1/graveyard-gguf/e2b-Q5_K_M.gguf 3630288320 f6c3f4395a9d3839535d8c14ae48ab784096945cfc4485005853eede915cb4a9 Q4_K_M /opt1/graveyard-gguf/e2b-Q4_K_M.gguf 3427880384 dd9dc465bb535989205f158d77f28f6f8348e47d8ac8870920c152b5996cbc16 Q4_0 /opt1/graveyard-gguf/e2b-Q4_0.gguf 3360161216 2d84758474be87d0a74edfa98efbeb602484e26f2e5fa8695fd9641ad323c7b2 Q3_K_M /opt1/graveyard-gguf/e2b-Q3_K_M.gguf 3201351104 b10c1f38c93635ccee1c7f382e03f5d2f4e9516087d7d62a73ca7de0f52693ab Q2_K /opt1/graveyard-gguf/e2b-Q2_K.gguf 2989088192 65850f1a31efed2013ed148adc5dc937e973a8e79fd55cdba31edd53369fddb2 The reference is BF16 because that is the checkpoint's own dtype, so the BF16 GGUF holds the trained weights unchanged. F16 is a rung. --- Step 2 — Check What F16 Costs Before Running It F16 has more mantissa than BF16 and less exponent range, so the cast can overflow or round small weights to zero. f16_range.py counts both on the checkpoint, one line per tensor and a total: python3 f16_range.py /opt1/models/gemma-4-E2B-it/model.safetensors > runs/2026-10-27-f16-range/out.txt grep -E 'position_embedding_table|TOTAL' runs/2026-10-27-f16-range/out.txt {"tensor": "model.vision_tower.patch_embedder.position_embedding_table", "n": 15728640, "overflow": 0, "underflow": 5507733, "subnormal": 834716, "absmax": 0.431640625} {"tensor": "TOTAL", "tensors": 2011, "n": 5123178979, "overflow": 0, "underflow": 5523265, "subnormal": 7013885, "absmax": 900.0} No weight overflows. Of the 5,523,265 that underflow, 5,507,733 are in the vision tower's position table, which the text GGUF does not carry. --- Step 3 — Ask One Rung 250 Questions graveyard.py run starts its own llama-server on one GGUF and asks each question once: temperature 0, one request at a time, no prompt cache, thinking off, 1,024 max tokens. Only the reply's content is graded, in code: the number after Answer:, compared with the reference. ./graveyard.py run BF16 /opt1/graveyard-gguf/e2b-BF16.gguf data/heldout.jsonl runs/2026-10-27-ladder --llama /opt1/llama.cpp {"rung": "BF16", "n": 250, "right": 229, "errors": 0, "truncated": 4, "median_decode_tps": 40.0, "mean_tokens": 391.2} The whole model fits on the T4 at BF16: load_tensors: offloaded 36/36 layers to GPU load_tensors: CPU_Mapped model buffer size = 768.00 MiB load_tensors: CUDA0 model buffer size = 4384.87 MiB 🔎 Tip: Gemma 4 E2B keeps its embedding tables in CPU memory. The per-layer embedding table holds 2,348,810,240 of the checkpoint's weights, and llama.cpp leaves it memory-mapped on the CPU with -ngl 99. So each rung's GPU memory is about half its file size: 4,671 MiB in use at BF16 for a 9.3 GB file, 1,639 MiB at Q4_0, 1,287 MiB at Q2_K. --- Step 4 — Prove the Same Rung Gives the Same Answers A tombstone means something only if the same model on the same question always gives the same answer. BF16 on 50 questions, twice: for i in 1 2; do ./graveyard.py run BF16 /opt1/graveyard-gguf/e2b-BF16.gguf data/heldout.jsonl runs/2026-10-27-determinism-$i \ --llama /opt1/llama.cpp --limit 50 done The two runs compared in code, question by question: 0 mismatched extracted, 0 mismatched text, 46/50 both times Every answer and every character of text matched. The same holds below BF16. graveyard.py repeat compares a second full run of four rungs with the ladder's: ./graveyard.py repeat runs/2026-10-27-ladder runs/2026-10-28-repeat Q4_0 Q3_K_M Q8_0 F16 --common {"rung": "Q4_0", "n": 250, "mismatched_extracted": 0, "mismatched_text": 0, "mismatched_right": 0, "right_a": 222, "right_b": 222} {"rung": "Q3_K_M", "n": 250, "mismatched_extracted": 0, "mismatched_text": 0, "mismatched_right": 0, "right_a": 191, "right_b": 191} {"rung": "Q8_0", "n": 250, "mismatched_extracted": 0, "mismatched_text": 0, "mismatched_right": 0, "right_a": 227, "right_b": 227} {"rung": "F16", "n": 250, "mismatched_extracted": 0, "mismatched_text": 0, "mismatched_right": 0, "right_a": 229, "right_b": 229} A changed answer at a lower rung comes from the weights. --- Step 5 — Run the Ladder and Bury It runs/2026-10-27-ladder/run-ladder.sh runs the nine rungs in order and skips any rung whose results are complete, so it picks up again after the VM's evening stop. Then bury: ./graveyard.py bury runs/2026-10-27-ladder BF16 F16 Q8_0 Q6_K Q5_K_M Q4_K_M Q4_0 Q3_K_M Q2_K --json graveyard-ladder.json {"first_deaths_by_rung": {"Q2_K": 177, "Q3_K_M": 26, "Q4_0": 9, "Q8_0": 4, "Q5_K_M": 2, "Q4_K_M": 6, "Q6_K": 1, "F16": 1}, "tombstones": 226, "ghosts": 11} 226 tombstones and 11 ghosts: 226 different questions die at some rung, and 11 questions BF16 gets wrong come back right at one rung or more. The first-death counts add up to the tombstones, one per question; the per-rung dead counts in the ladder table add up to more, because one question can be dead at several rungs. Per-question detail is in graveyard-ladder.json. The one question that dies at F16: {'id': 'test-687', 'died_at': 'F16', 'answer': '13', 'said': 17.0, 'right_again_at': ['Q8_0', 'Q6_K', 'Q5_K_M', 'Q4_K_M']} "One twin is 7 years older than one triplet. If their combined ages are 44, how old is one of the twins?" BF16 answers 13, from two twins and three triplets. F16 adds up two twins and one triplet, and answers 17. Four lower rungs answer 13 again. --- Step 6 — Autopsy: How Each Rung Dies graveyard.py autopsy counts, per rung, answers cut off at 1,024 tokens, answers that repeat one line five or more times, and answers that put text in the thinking block: ./graveyard.py autopsy runs/2026-10-27-ladder BF16 F16 Q8_0 Q6_K Q5_K_M Q4_K_M Q4_0 Q3_K_M Q2_K {"rung": "Q3_K_M", "cut_off": 49, "looped": 0, "thought": 0, "empty_content": 0, "empty_right_in_reasoning": 0, "dead": 42, "dead_cut_off": 34, "dead_looped": 0, "dead_empty_content": 0, "first_deaths": 26, "first_deaths_right_again_lower": 0} {"rung": "Q2_K", "cut_off": 246, "looped": 228, "thought": 75, "empty_content": 63, "empty_right_in_reasoning": 2, "dead": 226, "dead_cut_off": 222, "dead_looped": 207, "dead_empty_content": 60, "first_deaths": 177, "first_deaths_right_again_lower": 0} Every rung: | Rung | Cut off | Looped | Thinking unprompted | Dead | Dead, cut off | | :--- | :--- | :--- | :--- | :--- | :--- | | F16 | 4 | 0 | 0 | 1 | 0 | | Q8_0 | 9 | 0 | 0 | 4 | 2 | | Q6_K | 4 | 0 | 0 | 4 | 1 | | Q5_K_M | 3 | 0 | 0 | 3 | 1 | | Q4_K_M | 6 | 0 | 0 | 9 | 3 | | Q4_0 | 10 | 0 | 0 | 15 | 8 | | Q3_K_M | 49 | 0 | 0 | 42 | 34 | | Q2_K | 246 | 228 | 75 | 226 | 222 | Three kinds of death: - F16 to Q4_0, a different road through the same problem. 23 first deaths; 16 of them are right again at some lower rung. Down to Q5_K_M most of the dead answers end normally with a wrong number: 4 of 12 were cut off. At Q4_K_M and Q4_0, 11 of 24 were. From F16 to Q5_K_M, ghosts (1 to 5 per rung) match deaths (1 to 4), so the score holds. From Q4_K_M down, deaths outnumber ghosts, 9 to 4 and 15 to 8. - Q3_K_M, out of room. 34 of its 42 deaths were cut off at 1,024 tokens, still working, with no repeated lines. BF16 used a median 466.5 tokens on the 44 questions Q3_K_M got wrong while cut off. - Q2_K, collapse. 246 of 250 answers run to the limit and 228 repeat a line five or more times. With thinking off, 75 answers open a thinking block anyway, and in 63 of them the whole answer lands there, leaving content empty. No other rung writes into the thinking block at all. 🔎 Tip: give two buries in one directory two names. bury writes its per-question tombstones to graveyard.json; --json picks the file, so the QAT comparison in Step 7 keeps the ladder's file intact. --- Step 7 — Google's QAT Q4_0 Beside the Plain Q4_0 Google publishes a Q4_0 GGUF of Gemma 4 E2B trained for 4-bit (quantization-aware training). Its weights differ from the base checkpoint, so it sits beside the ladder, against the same BF16 reference: ./graveyard.py bury runs/2026-10-27-ladder BF16 QAT_Q4_0 Q4_0 --json graveyard-qat.json {"rung": "QAT_Q4_0", "n": 250, "right": 221, "errors": 0, "truncated": 6, "median_decode_tps": 87.8, "mean_tokens": 391.9, "dead": 15, "ghosts": 7, "answer_changed": 27, "bytes": 3349516256, "gpu_mib_loaded": 1629, "gpu_mib_before": 0} {"rung": "Q4_0", "n": 250, "right": 222, "errors": 0, "truncated": 10, "median_decode_tps": 93.6, "mean_tokens": 430.4, "dead": 15, "ghosts": 8, "answer_changed": 27, "bytes": 3360161216, "gpu_mib_loaded": 1639, "gpu_mib_before": 0} Same number of deaths, same number of changed answers, one right answer apart. The graves differ: 6 of the 15 dead are the same question, 9 die only under QAT and 9 only under the plain Q4_0. QAT runs out of room less often: 2 of its deaths were cut off at 1,024 tokens, against 8 for the plain Q4_0. --- Step 8 — Bury the Ladder Again With Thinking On Gemma 4 can think before it answers. --think turns it on; the thinking goes to reasoning_content and only content is graded. Thinking needs room, so this pass allows 4,096 tokens in an 8,192-token context. It covers seven rungs, BF16 to Q3_K_M; F16, Q2_K and QAT Q4_0 were not run with thinking on. Each rung is buried against BF16 with thinking on, which gets 227 right. A second BF16 run of 50 questions matched the first exactly, 47 right both times. ./graveyard.py bury runs/2026-10-28-think BF16 Q8_0 Q6_K Q5_K_M Q4_K_M Q4_0 Q3_K_M --json graveyard.json {"rung": "BF16", "n": 250, "right": 227, "errors": 0, "truncated": 0, "median_decode_tps": 34.5, "mean_tokens": 842.2, "dead": 0, "ghosts": 0, "answer_changed": 0, "bytes": 9311305152, "gpu_mib_loaded": 4699, "gpu_mib_before": 0} {"rung": "Q3_K_M", "n": 250, "right": 208, "errors": 0, "truncated": 11, "median_decode_tps": 68.0, "mean_tokens": 1320.1, "dead": 26, "ghosts": 7, "answer_changed": 42, "bytes": 3201351104, "gpu_mib_loaded": 1517, "gpu_mib_before": 0} docs/think_derived.py lines the two passes up question by question: python3 docs/think_derived.py | tail -3 "q3_dead_cut_off_with_thinking_off": 34, "of_them_right_with_thinking_on": 21 } | Rung | Right, thinking off | Right, thinking on | Dead, off | Dead, on | Dead in both | | :--- | :--- | :--- | :--- | :--- | :--- | | BF16 | 229 | 227 | — | — | — | | Q8_0 | 227 | 🥇 230 | 4 | 2 | 0 | | Q6_K | 229 | 🥇 230 | 4 | 6 | 0 | | Q5_K_M | 231 | 🥇 230 | 3 | 6 | 0 | | Q4_K_M | 224 | 226 | 9 | 9 | 1 | | Q4_0 | 222 | 219 | 15 | 15 | 3 | | Q3_K_M | 191 | 208 | 42 | 26 | 12 | Three things change: - Q3_K_M recovers most of its loss. It gains 17 right answers. Of the 34 questions it lost by running out of room at 1,024 tokens, 21 are right with thinking on and 4,096 tokens. Both the thinking and the larger limit changed at once, so this run cannot say which one did it. - Above Q3_K_M the score holds and the graves move. Each rung stays within 3 answers of its thinking-off score, but the questions it loses are almost all new: 0 of the deaths at Q8_0, Q6_K and Q5_K_M are shared between the two passes, 1 of 9 at Q4_K_M and 3 of 15 at Q4_0. BF16 itself gets 218 questions right in both modes. - The cost is time. Answers use 2.08 to 2.18 times as many tokens, decoding runs at 0.79 to 0.93 of the thinking-off speed, and each rung takes 2.22 to 2.70 times as long on the T4. --- Compare and Contrast | | Q5_K_M | Q4_K_M | Q4_0 | QAT Q4_0 | Q3_K_M | | :--- | :--- | :--- | :--- | :--- | :--- | | Right of 250 (BF16: 229) | 🥇 231 | 🥈 224 | 🥉 222 | 221 | 191 | | Dead | 🥇 3 | 🥈 9 | 🥉 15 | 🥉 15 | 42 | | GPU MiB | 1,897 | 1,705 | 🥉 1,639 | 🥈 1,629 | 🥇 1,489 | | Median tok/s on the T4 | 78.7 | 🥉 84.1 | 🥇 93.6 | 🥈 87.8 | 74.2 | | Answers cut off | 🥇 3 | 🥈 6 | 10 | 🥈 6 | 49 | | Verdict | 🟢 same score as BF16 | 🟢 small loss | ⚠️ 15 dead | ⚠️ 15 dead, fewer cut off | ❌ 38 fewer right | --- So, Which One? To ship Gemma 4 E2B on a small GPU with BF16's score, take Q5_K_M: 39.0% of the bytes, 231 right against 229, and 1.97 times BF16's decode speed on the T4 (arithmetic from the medians). For the fastest file that stays within 7 answers, take Q4_0 or Q4_K_M. Below Q4, the losses stop being a few flipped answers: Q3_K_M saves 150 MiB of GPU memory over Q4_0 and costs 31 right answers, and Q2_K stops answering. With thinking on and 4,096 tokens, Q3_K_M gets 208 right, 11 short of Q4_0, at more than twice the time per question. --- Prior Work - Prompt, answer extraction and grading (lazy_eval.py) and the 250-question GSM8K split (data/, seed 0): from my Week 3 entry, lazy-gemma, whose grader came from my earlier Gemma 4 TPU work. - Open source used: llama.cpp (MIT) for conversion, quantization and serving; Gemma 4 E2B and Google's QAT Q4_0 GGUF (Gemma terms); GSM8K. --- Why Does Open Innovation Matter? A graveyard needs the same model at nine sizes, run the same way. - The weights are on the disk, so the ladder is built here. ladder.sh produces every rung from one BF16 file with the open converter and quantizer, and ladder.tsv records each file's sha256. A hosted API serves whichever quantization its provider chose, and it can change without notice. - The same answer twice. Greedy decoding on a fixed llama.cpp build gave identical text on every repeated run, BF16 to Q3_K_M, so every tombstone counts. That check needs control of the server, the seed and the build. - The failure is visible. Q2_K's answers in the thinking block show up only because llama-server returns reasoning_content and content separately and every row is kept. - No per-token bill. Ten models times 250 questions ran on one rented T4. --- The Spirit of It Every row in the graveyard is a grade-school maths problem, and each tombstone keeps its own epitaph: - test-687, twins and triplets, answer 13. Died at F16, said 17. Rose again at Q8_0, Q6_K, Q5_K_M and Q4_K_M. - test-2, a house flipped for profit, answer 70,000. Died at Q4_0, said 120,000. Never rose. - test-564, Judy's two weeks of reading, answer 240. Died at Q8_0, said 3. Rose again at every rung from Q6_K to Q4_0. Most graves above Q3_K_M have someone come back to them: 16 of 23. --- Prize Categories Gemma: Gemma 4 E2B, quantized locally with llama.cpp at nine levels and compared with Google's quantization-aware Q4_0 release, served on one Tesla T4. --- Summary The goal of this project was to find which answers Gemma 4 E2B loses at each quantization level, one question at a time. The key was a deterministic run: greedy decoding on one llama.cpp build, checked to give identical text twice at five rungs, so every changed answer comes from the weights. The results were: - 🟢 Q8_0, Q6_K and Q5_K_M stay within 2 right answers of BF16's 229 of 250; Q5_K_M scores 231 at 39.0% of the bytes. - 🟢 Every rung fits on the T4, BF16 included: all 36 layers on the GPU, 4,671 MiB in use, with the embedding tables in CPU memory. - 🟢 Above Q3_K_M, 16 of the 23 questions that die are right again at a lower rung. - ⚠️ Q4_K_M and Q4_0 lose 5 and 7, with 9 and 15 deaths. - ⚠️ Google's QAT Q4_0 scores 221 against the plain Q4_0's 222; the two share 6 of their 15 deaths. - 🟢 Q4_0, Q3_K_M, Q8_0 and F16 run a second time give the same text on all 250 questions. - ⚠️ With thinking on, rungs above Q3_K_M keep their score but lose different questions; at Q4_0, 3 of 15 deaths are shared. - ⚠️ Thinking on costs 2.1 times the tokens and 2.2 to 2.7 times the time per rung. - ❌ Q3_K_M loses 38; 34 of its 42 deaths are cut off at 1,024 tokens. With thinking on and 4,096 tokens it loses 19. - ❌ Q2_K gets 3 right: 246 answers hit the token limit, 228 loop, and 75 write into a thinking block with thinking off. Scope: one Tesla T4 on GCE, llama.cpp b11699, 250 GSM8K test questions per rung, greedy. Thinking off with a 1,024-token limit on all ten models; thinking on with a 4,096-token limit on seven rungs, BF16 to Q3_K_M. Determinism checked at BF16, F16, Q8_0, Q4_0 and Q3_K_M. No importance matrix, none of the other 1,069 GSM8K test questions, and no other machine. Speeds compare rungs on this T4 only. The strategy for burying Gemma 4's answers one quantization rung at a time was validated with an incremental step by step approach. --- References - Hacktoberfest Open-Source AI Challenge, Week 4: Ghost in the Machine - gemma-graveyard on GitHub - Run report: runs/2026-10-27-ladder/REPORT.md - lazy-gemma, the Week 3 entry - llama.cpp - google/gemma-4-E2B-it - google/gemma-4-E2B-it-qat-q4_0-gguf - GSM8K

    8 reactions · 3 comments
  8. So OpenAI has a thing that says Exponential Time Hypothesis is false (github.com/openai/math/blob/main/preprints/The-Ex…) I don't know how credible those claims are (my understanding is that these proofs haven't been generally disproven yet, but that the papers are a tough read to say the least) but, as someone who has done some work adjacent to "let's get the base of the exponent for 3-SAT down, shall we?" and who has uttered the sentence "Under strong exponential hypothesis..." this feels weird. And it also breaks my heart a little because it feels like a lot of the joy of the work has disappeared, and that it's really not replaced yet by the joy of reading a really nice proof. I already have that sort of feeling with code, and it feels like it would be worse if I were doing math. That's a lot of feels right there that I was not expecting when opening my RSS reader.

    1 comment
  9. Две лаборатории против одной гипотезы: что происходит вокруг ETH OpenAI и Anthropic сообщили, что их исследовательские модели нашли алгоритмы, опровергающие гипотезу экспоненциального времени — ETH. На этом предположении построены многочисленные оценки сложности вычислительных задач. Если результат выдержит проверку, исследователям придётся пересмотреть часть представлений о том, какие алгоритмы вообще возможны. Масштаб последствий зависит от того, какое ускорение обещают новые алгоритмы. Для этого нужно разобраться в связи ETH с проблемой P против NP. Что опубликовали лаборатории 26 октября 2026 года OpenAIобъявила о результатах в трёх областях: математическом анализе, теории вычислительной сложности и квантовой теории поля. Заявление об ETH относится ко второй. Компания выложила текст доказательства и его формализацию в Lean — системе проверки математических доказательств. Вскоре собственные материалыпредставила Anthropic. Компания приписывает результат внутренней исследовательской модели Claude. Заявленный алгоритм решает задачу 3-SAT за субэкспоненциальное время. Он также должен подсчитывать число удовлетворяющих формуле наборов значений. За внешнее изучение результата OpenAI взялись Райан Уильямс из MIT, Рассел Импальяццо и Рамамохан Патури из Калифорнийского университета в Сан-Диего. Воткрытом письме исследователи подчеркнули: их участие не означает, что заявленное опровержение уже получило научное подтверждение. Какую границу устанавливает ETH ETH касается задачи выполнимости булевых формул. В варианте 3-SAT формула состоит из условий, соединённых оператором «И». Каждое условие содержит до трёх переменных или их отрицаний, связанных через «ИЛИ». Нужно подобрать значения «истина» и «ложь», при которых вся формула окажется истинной. Простой пример: (x ИЛИ y ИЛИ НЕ z) И (НЕ x ИЛИ z ИЛИ w). Если x, z и w истинны, а y ложно, оба условия выполнены. Проверить предложенный набор значений нетрудно: достаточно пройти по условиям. При поиске подходящего набора готовой подсказки уже нет. У n булевых переменных есть 2ⁿ возможных наборов значений. Полный перебор проверяет их один за другим; добавление одной переменной удваивает число комбинаций. ETH утверждает более тонкую вещь: даже при другом подходе в худшем случае нельзя полностью избавиться от экспоненциальной зависимости. Пример представления булевой формулы графом и объединения групп узлов. Фрагмент иллюстрации из работы Anthropic СогласноETH, для 3-SAT нет алгоритма со временем 2^(o(n)), с точностью до полиномиальных множителей по размеру входа. Обозначение o(n) означает, что показатель растёт медленнее n: отношение этих величин стремится к нулю. Поэтому 2^(√n) — пример субэкспоненциальной зависимости, а 2^(0,01n) — всё ещё экспоненциальная. Маленький постоянный коэффициент сам по себе гипотезу не опровергает. Быстро решить много удачно подобранных формул недостаточно: нужна доказанная оценка для худшего случая. Именно такую гарантию заявляют лаборатории. Почему вопрос P против NP остаётся открытым Проблема P против NP проводит другую границу. Класс P включает задачи с ответом «да» или «нет», которые можно решить за полиномиальное время. В классе NP для положительного ответа существует свидетельство, которое можно проверить за полиномиальное время. Для 3-SAT таким свидетельством служит подходящий набор значений переменных. Если его предоставить, проверить формулу можно быстро. Вопрос в том, существует ли столь же эффективный общий способ определить, есть ли решение. «Быстро» здесь означает полиномиальную зависимость от длины входных данных, например квадрат или куб этой длины. Разницу между оценками удобно увидеть на трёх выражениях: Зависимость Тип роста Что происходит при увеличении n n³ Полиномиальный Размер входа возводится в фиксированную степень 2^(√n) Субэкспоненциальный, но сверхполиномиальный Растёт быстрее любой фиксированной степени n 2ⁿ Экспоненциальный Каждая дополнительная единица n удваивает значение Таблица иллюстрирует типы роста функций. Она не описывает измеренную скорость новых алгоритмов. Полиномиальная, субэкспоненциальная и экспоненциальная зависимости растут с разной скоростью. По вертикали показан двоичный логарифм значения функции; обе оси имеют логарифмический масштаб 3-SAT — NP-полная задача: полиномиальный алгоритм для неё дал бы полиномиальные алгоритмы для всех задач NP. ETH — более сильное предположение, чем P ≠ NP. Её истинность влечёт P ≠ NP, но опровержение ETH само по себе не устанавливает P = NP. У 3-SAT может существовать субэкспоненциальный алгоритм, который всё равно работает дольше любого полинома. Что подтверждает проверка в Lean Lean проверяет, что утверждение следует из заданных определений и аксиом. Человеку остаётся убедиться, что формализованная теорема соответствует исходной задаче. Безошибочное доказательство более слабого утверждения не подтверждает более сильное. Вописании формализации OpenAI уже видна существенная деталь. Рукопись заявляет время: 2^(O(n · log log n / √log n)). В документе о границах проверки Lean указана более слабая оценка: 2^(O(n · (log log n)² / √log n)). Оценки приведены для фиксированного k — максимальной длины условия; полиномиальные множители по размеру входа опущены. Дополнительный множитель log log n ухудшает верхнюю оценку времени. При этом обе зависимости остаются субэкспоненциальными и, если доказаны для нужной задачи, достаточны для опровержения ETH.GitHub Anthropic отдельно отмечает этот предел вREADME проекта: машина проверяет доказательства, но соответствие формальных утверждений тексту статьи требует человеческого прочтения. Для этого компания вынесла основные формулировки в отдельный короткий файл MainResults.lean.raw.githubusercontent.com Что изменится для алгоритмов и криптографии ETH использовали как исходное предположение для условных нижних оценок. Логика таких работ выглядит примерно так: «Если ETH верна, задача X не может решаться быстрее определённой границы». Опровержение предположения не делает условную теорему ошибочной, но лишает её основания для вывода о реальном пределе скорости. Сведения задач друг к другу, методы и промежуточные результаты сохраняют ценность. Здесь есть ещё одна тонкость. Из нового алгоритма для 3-SAT нельзя автоматически получить одинаковое ускорение для любой NP-полной задачи. При сведении одной задачи к другой размер входа может вырасти. Поэтому последствия нужно рассчитывать для каждого конкретного сведения, учитывая, по какому параметру измеряется сложность. Для разработчиков ПО важен следующий вопрос: при каких размерах данных новый алгоритм начинает выигрывать? Асимптотика описывает рост затрат при увеличении входа. Она скрывает постоянные коэффициенты и не сообщает, будет ли реализация полезна на доступном оборудовании. Anthropic прямо характеризует свой результат как асимптотический, без утверждений о практической скорости решения формул. По той же причине заявление об ETH не даёт оснований объявлять существующее шифрование взломанным. Для такого вывода нужен конкретный способ атаки, оценка его затрат и применимость к используемым параметрам криптосистемы. Общего утверждения об ускорении 3-SAT для этого недостаточно. Уильямс рассказал, что спросил OpenAI о возможных последствиях для криптографии. По его словам, компания проверила этот вопрос и не обнаружила оснований считать, что результат приводит к взлому криптосистем. Этопересказ ответа лаборатории в TechCrunch, а не независимый аудит безопасности. Как учёные собираются проверять результат Ранее Уильямс сравнил массовую публикацию ИИ-доказательств с DDoS-атакой на математиков: их проверка требует времени специалистов, которого новые тексты не прибавляют. Теперь OpenAI согласилась открыть материалы по ETH и профинансировать конференцию для обсуждения последствий. Участники внешней группы работают без вознаграждения от компании и без обязательств о неразглашении. Они могут публиковать собственные выводы, включая критику.openai.com Внешняя группа предлагает совместно разбирать доказательство, публиковать объяснения и изучать последствия для других задач. Отдельный вопрос — как признавать вклад тех, кто проверяет и упрощает результат, и кому предоставлять ранний доступ к материалам. Следить за проверкой можно насайте рабочей группы. В новых публикациях стоит обращать внимание на четыре вещи: Точную задачу: алгоритм находит решение, проверяет его существование или считает все решения. Параметры оценки: что обозначают n и размер входа, какие величины считаются фиксированными. Объём формальной проверки: совпадает ли доказанная теорема с главным утверждением рукописи. Практические результаты: есть ли реализация и измерения, позволяющие говорить о скорости на реальных данных. Если опровержение подтвердится, следующим шагом станет поиск более простых и эффективных алгоритмов. Для этого потребуется понять, какие идеи обеспечили ускорение и где ещё их можно применить. В блоге Спешу АИI мы разбираем новые исследования, возможности нейросетей и события вокруг их разработчиков. Подписывайтесь, чтобы следить за развитием ИИ и понимать, что стоит за громкими заявлениями. А познакомиться с разными ИИ-моделями на собственных задачах можно в speshu.ai — нашем сервисе, который объединяет их в одном месте.

  10. OpenAI и Anthropic почти одновременно заявили об опровержении одной из главных гипотез информатики OpenAI и Anthropic представили два алгоритма, которые опровергают гипотезу экспоненциального времени (ETH). Это одно из фундаментальных предположений теории вычислительной сложности, на которое исследователи опирались больше 25 лет. Обе компании получили результаты 16 октября. OpenAI опубликовала своё доказательство 26 октября, а следом появились материалы Anthropic. Разбираемся, что нашли модели и при чём тут IPO. Что вообще за ETH?Гипотезу сформулировали в 1999 году. Она утверждает, что задачу 3-SAT нельзя решить за субэкспоненциальное время по числу переменных. Если совсем просто, 3-SAT — это задача, в которой нужно подобрать значения логических переменных так, чтобы формула стала истинной. Сложность в том, что с ростом числа переменных количество возможных комбинаций увеличивается экспоненциально. ETH предполагает, что принципиально обойти такой характер роста вычислительных затрат не получится. На этой гипотезе основаны сотни работ по теории алгоритмов, графам, базам данных и другим направлениям. Что нашли модели? OpenAI сообщила, что её внутренняя модель разработала детерминированный алгоритм, который решает 3-SAT за субэкспоненциальное время. Более того, он умеет подсчитывать количество комбинаций, удовлетворяющих формуле, — это более сложная задача #3-SAT. Доказательство модель получила 16 октября, а 17 октября его формализовалив Lean. OpenAI уже привлекла к независимой проверке Рассела Импальяццо и Рамамохана Патури — исследователей, участвовавших в формулировке ETH, — а также Райана Уильямса из MIT. Anthropic опубликовала работу A 2^o(n) Time Algorithm for 3-SAT, автором которой указан Claude. Компания утверждает, что её внутренняя исследовательская модель независимо получила другой алгоритм с аналогичным результатом. Для него тоже подготовили формальное доказательствона Lean 4 с использованием Mathlib. Дополнительно предусмотрена проверка независимым ядром nanoda. В репозитории Anthropic, например, есть два sorry — специальных маркера незаполненных доказательств. Однако они находятся в файле Challenge.lean, который задаёт формулировки проверяемых теорем. Сами доказательства проверяются отдельно, поэтому считать наличие этих маркеров свидетельством ошибки было бы неправильно. Что это значит? Предложенные алгоритмы дают асимптотическое улучшение, то есть преимущество проявляется при чрезвычайно больших размерах задачи. Для практических вычислений они пока мало что меняют. Опровержение ETH также не решает проблему P против NP. Алгоритм с субэкспоненциальным временем работы всё ещё может быть намного медленнее полиномиального. При этом последствия для теоретической информатики могут оказаться серьёзными. Если результаты подтвердятся, придётся пересмотреть представления о сложности целого ряда задач, нижние оценки для которых выводились из ETH. Что ещё нашли модели OpenAI? Помимо опровержения ETH, OpenAI сообщила ещё о двух крупных результатах — в математике и теоретической физике. Гипотеза Какэя и локальное сглаживание Модель предложила доказательство гипотезы Согге 1991 года, которая описывает поведение волн при фокусировке. Если проще, очень сильная концентрация волны не может сохраняться долго. Ранее исследователям удавалось доказать связанные результаты лишь для отдельных размерностей, а модель OpenAI, по заявлению компании, справилась со всеми размерностями от двух и выше. Из этого доказательства также следуют результаты по гипотезам Какэя и Штейна — двум известным открытым задачам математического анализа. Работу получили 18 октября, а на следующий день формализовали в Lean. Материалы уже опубликованы. Квантовая хромодинамика и теория Янга — Миллса Здесь задача ещё масштабнее: строго математически доказать существование квантовых теорий поля, описывающих взаимодействия элементарных частиц. OpenAI утверждает, что её модели получили такие доказательства для четырёхмерной квантовой хромодинамики (КХД), чистой теории Янга — Миллса и одной из моделей объединения взаимодействий Стандартной модели. Это связано с одной из семи задач тысячелетия, но пока не означает её полного решения: отдельно требуется доказать существование массового зазора. Работы по физике пока не опубликованы. Их изучением займётся группа исследователей во главе с нобелевским лауреатом Дэвидом Гроссом. Научный прорыв или маркетинг? Есть у этой истории и любопытный финансовый контекст. 26 октября, в день публикации OpenAI, Anthropic официально подала заявку на IPO — компания планирует выйти на Nasdaq под тикером ANT. А вскоре после анонса конкурента опубликовала собственное опровержение ETH. По данным Reuters, OpenAI тоже готовится к выходу на биржу в 2027 году и ускоряет привлечение финансирования, чтобы опередить Anthropic. Обеим компаниям важно убедить инвесторов, что их модели способны не только писать код и генерировать тексты, но и совершать настоящие научные открытия. Поэтому к громким заявлениям стоит относиться с осторожностью. Независимая проверка ещё не завершена, зато публикации уже работают на репутацию разработчиков. Впрочем, само совпадение дат ничего не доказывает: свидетельств того, что компании специально приурочили исследования к IPO или подстроили публикации друг под друга, нет. И если доказательства подтвердятся, их научная ценность от этого не уменьшится.

Trending awards, every completed day and week
Gold
601st place finishes
Silver
342nd place finishes
Bronze
343rd place finishes
Awarded repositories
30Owned by openai now

Repositories

Ordered by gold, then silver, then bronze.

  1. openai-fmBest: 1st by forks, 1,485 forks824
  2. swarmBest: 1st by stars, 7,161 stars820
  3. whisperBest: 1st by stars, 8,061 stars811
  4. codexBest: 1st by stars, 15,881 stars634
  5. gpt-ossBest: 1st by stars, 9,077 stars541
  6. chatgpt-retrieval-pluginBest: 1st by stars, 3,946 stars532
  7. shap-eBest: 1st by stars, 1,775 stars311
  8. point-eBest: 1st by stars, 2,890 stars310
  9. universeBest: 1st by stars, 1,254 stars310
  10. evalsBest: 1st by stars, 2,283 stars302
  11. gpt-2Best: 1st by forks, 162 forks222
  12. codex-securityBest: 1st by stars, 13 stars200
  13. gpt-3Best: 1st by stars, 556 stars122
  14. jukeboxBest: 1st by stars, 540 stars101
  15. gymBest: 1st by forks, 82 forks100
  16. tiktokenBest: 1st by stars, 1,028 stars100
  17. openai-cs-agents-demoBest: 2nd by stars, 633 stars031
  18. openai-agents-pythonBest: 2nd by stars, 2,004 stars021
  19. mathBest: 2nd by stars, 8,034 stars020
  20. openai-cookbookBest: 2nd by stars, 825 stars014
  21. codex-plugin-ccBest: 2nd by stars, 47 stars011
  22. DALL-EBest: 2nd by stars, 717 stars010
  23. openai-pythonBest: 2nd by stars, 635 stars010
  24. transformer-debuggerBest: 2nd by stars, 1,676 stars010
  25. openai-realtime-agentsBest: 3rd by stars, 1,186 stars002
  26. glowBest: 3rd by forks, 81 forks001
  27. grokBest: 3rd by stars, 1,178 stars001
  28. parameter-golfBest: 3rd by forks, 92 forks001
  29. spinningupBest: 3rd by stars, 413 stars001
  30. symphonyBest: 3rd by stars, 769 stars001

A repository earns an award for finishing first, second or third in a completed trending day or week, ranked by new stars, new forks or pull request authors. Awards follow a repository through renames and transfers and count toward its current owner. Weeks run Monday to Sunday, UTC.