r/MachineLearning • • 11h ago

Project NInfer RTX 4090 – Native CUDA LLM inference on Windows, up to 326 tok/s with Qwen 27B and DFlash2 in short benchmarks [R]

0 Upvotes

Hey everyone,

I've been working on an independently maintained version of NInfer-all, specifically optimized for the RTX 4090 and its SM89 architecture.

The goal is to get as much performance as possible out of a single 24GB GPU while running larger local models, especially for coding and long-context workloads.

I've just released v0.1.4 as a stable, GPU-tested Windows build.

Features:

  • Native C++/CUDA 13.4 inference
  • RTX 4090 / SM89 optimizations
  • DFlash2 and MTP speculative decoding
  • Qwen3.8 27B and Ternary Bonsai 2.5 support
  • Quantized KV cache (rk4v4, rk8v4, etc.)
  • Hybrid prefix caching
  • OpenAI- and Anthropic-compatible APIs
  • Portable Windows binaries
  • Apache 2.0 license

Recent RTX 4090 benchmarks:

Model / BackendDecode
Qwen 27B IQ3_S – No speculation70.38 tok/s
Qwen 27B – MTP K5242.59 tok/s
Qwen 27B – DFlash2 K5257.13 tok/s
Qwen 27B – DFlash2 K7326.41 tok/s
Qwen 27B – DFlash2 K9269.33 tok/s
Bonsai 2.5 PTQ1_0 – MTP K3291.69 tok/s
Bonsai 2.5 PQ2_0 – MTP K3323.88 tok/s

These are short synthetic engine benchmarks with 2048 prompt tokens and 128 timed decode tokens, not guaranteed real-world serving speeds. The methodology and measurement data are publicly available.

I've also built a project website with an interactive VRAM calculator, launch command generator, model downloads, installation guides and benchmark results.

GitHub: https://github.com/spk-c/ninfer-all-rtx4090

Project website: https://spk-c.github.io/ninfer-all-rtx4090/

Benchmarks: https://spk-c.github.io/ninfer-all-rtx4090/benchmarks.html

VRAM calculator: https://spk-c.github.io/ninfer-all-rtx4090/configurator.html

Credit to the original NInfer and NInfer-all developers. This project builds on their work.

I'd love to hear feedback from other RTX 4090 owners, especially people running local coding agents with 64K–192K contexts.

If you try it, please share your results, even if they're worse than expected. I'm interested in finding bottlenecks and improving the engine further.


r/MachineLearning • • 17h ago

Research Structure-first AI execution: Can we determine whether inference is necessary before invoking an LLM? [R]

6 Upvotes

We recently published our research on KORA, an architecture that prioritizes structured execution before model inference.

While much of AI research focuses on improving model capabilities and inference efficiency, we explore a different question: Can unnecessary inference be avoided at the architectural level?

In our controlled 100-task benchmark, KORA avoided 80% of simulated model calls with zero mismatches on deterministic tasks.

These results are limited to the evaluated benchmark and should not be interpreted as production-level cost savings.

We are particularly interested in feedback on:

  • Task classification before inference
  • Deterministic execution versus probabilistic inference
  • Evaluation methodology and benchmark design
  • Generalization to real-world workloads

The paper, implementation, and reproducible benchmarks are publicly available.

Paper: https://arxiv.org/abs/2610.35869

GitHub: https://github.com/Krako-Labs/KORA

Krako Labs: https://krako.xyz

Disclosure: I'm one of the authors and a founder of Krako Labs.


r/MachineLearning • • 7h ago

Discussion Do we really need LLM ACs at ICLR? [D]

28 Upvotes

I am a bit salty. Since the end of the review phase, two ACs sent messages to start a discussion. Both messages summarized the status, asked individual reviewers to take positions/do work, and both were 100% AI generated. Of course these summaries included factual errors.

So now we have LLM papers being reviewed by LLM reviewers, discussed by LLM agents and moderated by LLM ACs. Is it LLMs all the way down?

Where exactly does this involve scientific integrity? What are we even doing here? Don't get me wrong, I understand AC is a lot of work and now with extended length LLM discussions it is borderline impossible to follow the status of a paper, let alone 10. I am painfully aware. But the solution cannot be to outsource the moderation activity to LLMs and let the few remaining human reviewers also correct the wrong AC summary.


r/MachineLearning • • 9h ago

Research What a looped transformer actually does inside its loop [R]

23 Upvotes

Hey everyone — with looped transformers showing up in Inkling 2 Mini, varloop, and Z.ai's GLM-5.4 this week, I put together an in-depth visual post on how they actually work under the hood, with interactive diagrams, a minimal PyTorch implementation comparing Inkling's restart-and-message loop vs. GLM-5.4's chain-and-write-gate loop, and experiments opening up the two 26.4B open-weight models pass by pass.

Full post: https://drhb.github.io/blog/posts/looped-transformers/


r/MachineLearning • • 2h ago

Project envscan: static checks for reward hacks in RL environments [P]

4 Upvotes

We just open sourced envscan, a static scanner we built while auditing 90 public RL environments by hand.

It reads an environment's source, never runs it, and flags places where a policy could earn reward without doing the task: graders running in the agent's sandbox, answer keys the agent can read, substring checks that a list of every option passes. When it says "likely", it was right 35 of 36 times on the envs we audited by hand, and it finds about two thirds of what a person found.

Try it: pip install git+https://github.com/ALLENDE123X/envscan, then envscan owner/name

Writeup with every number: https://aginno.dev/blog/we-tried-to-pass-90-rl-environments/

I'd love to hear what you think: what it misses, what it flags that it shouldn't, and what environment formats it should read next.

https://github.com/ALLENDE123X/envscan


r/MachineLearning • • 8h ago

Project TontaubeV1.1 Flash, an open-source, LLM-based TTS model that runs in real time in your browser on CPU [P]

4 Upvotes

We just released TontaubeV1.1 Flash, an open-source TTS model (Apache-2.0) that achieves ~10ms TTFA streaming on consumer GPUs and runs realtime in your browser on CPU (and on some phones!). It is a single-speaker model we distilled from our bigger V1.1 model.

Links

Model Overview

  • A 0.6B model with a Qwen3-0.6B backbone that speaks through our own single-voice codec on top of the VibeVoice decoder. With 4-bit weights it is a download of about 700 MB.
  • One English voice, Marcus. No voice cloning and no style controls.
  • Weights and code are Apache 2.0.
  • It runs on an NVIDIA GPU, on a plain CPU (Linux, Windows, macOS on Apple silicon) and inside Chrome without any server.

How it works

The model speaks through our own codec, an autoencoder built for only this one voice. It packs each frame of VibeVoice latents into just 16 values (through an autoencoder we trained on a single voice), at 7.5 frames per second of speech. The backbone reads the text character by character and predicts those 16 values one frame at a time with a small sampling head (several flow-matching steps). The codec's decoder expands them back into VibeVoice latents, the VibeVoice decoder turns those into 24 kHz audio, and an upsampler raises it to 48 kHz. Additionally, a small detector listens to the audio while it streams. When it detects an artifact, the engine goes back a frame and draws those frames again before they are played (can be disabled for a small increase in generation speed).

Numbers

Where it runsHardwareSpeedTime to first audio
GPU engineRTX 3090about 25-30x real time per stream, over 100x across many streams at onceabout 10 ms
CPU enginedesktop or server CPUabout 2-4x real timeabout 60-150 ms
Chrome on a desktopCPU onlyabout 1.3-2x real timeunder a second
Chrome on a desktopwith the graphics card (WebGPU)about 3-6x real timeabout 0.1-0.2 s

Output is 48 kHz by default. Switching to 24 kHz makes everything faster.

How to try it

The easiest way is the browser demo linked above. It downloads the model once and then runs on your own machine. Nothing you type leaves the browser. Running through WebAssembly costs some performance, so if you hit buffering issues, try the native CPU server through the repo. It comes with a local web UI (uv run tontaube ui, then open http://127.0.0.1:3000).

To run it locally:

git clone https://github.com/craitech/tontaube.git
cd tontaube
uv run python flash/speak.py "Welcome to Tontaube Flash." --wav flash.wav               # NVIDIA GPU
uv run python flash/speak.py --device cpu "Welcome to Tontaube Flash." --wav flash.wav  # CPU
uv run tontaube serve --model flash                                                      # server

The server also answers OpenAI's text-to-speech API at /v1/audio/speech, so tools built for that API work with it unchanged.

Limitations

  • English only, with one voice and no cloning.
  • It is autoregressive, so it can occasionally skip, repeat or mispronounce a word.
  • The browser version needs about 1.2 GB of memory. On an Android phone it reaches about real time for short texts. iPhones may run into issues in the browser.
  • On Linux, Chrome only gives web pages the graphics card after you enable two settings in chrome://flags. Without them it only runs on the CPU.
  • The GPU engine is Linux only for now. On Windows and macOS it runs on the CPU.

A native engine for phones is in development.

Please let me know if you run into any issues. We weren't able to test all possible platforms, so this helps us fix the things we couldn't test ourselves :)