radix16/pramen-498m
neural assembly-to-C decompiler for Windows and DOS
2 min readupdated
Pramen 498M is a scaled-up language model (498M parameters) built on a GPT-2-style decoder-only transformer architecture that translates single-function assembly code back into C. Unlike models targeting Linux and GCC, it was trained from scratch specifically for Windows and MS-DOS toolchains, including MSVC, Open Watcom, Microsoft C, and Digital Mars. Compared to the smaller 223M version, this release generates more accurate code, adds support for new DOS targets, and fits well into reverse-engineering and binary analysis workflows.
Key features
- Supports 17 compiler and platform targets, including 32-bit DOS/4GW and legacy Microsoft and Digital Mars compilers.
- Higher generation accuracy: hits 57.3% on the HumanEval-C benchmark (best of 8 candidates), up from 53.6% on the 223M model.
- 24-layer architecture with a hidden size of 1,280 and a 4,096-token context window.
- Low resource footprint: supports int8 quantization, requiring just 0.6 GB of VRAM or RAM.
What you can do
- Decompile assembly listings from Ghidra or MSVC debuggers into readable C code.
- Recover function logic from classic MS-DOS games and apps using the newly added 16-bit and 32-bit DOS targets.
- Run candidate mode (`--candidates 8`) with automated recompilation via the native compiler to pick the best-matching output.
- Launch the local web UI (`python -m pramen.web`) for interactive code analysis right in your browser.
Example
pip install huggingface_hub
hf download radix16/pramen-498m --local-dir pramen
cd pramen
pip install -r requirements.txt
# Декомпиляция файла ассемблера для MSVC x64
python -m pramen example-count_words-msvc-x64-Od.asm --variant msvc-x64-Od
Read more
DetailsBenchmarks: HumanEval-C (greedy) — 45.5%, with 8 candidates — 57.3%
Hardware requirements: GPU recommended for smooth performance, or CPU (roughly half the speed of the 223M version; int8 quantization mode uses 0.6 GB)
Limitations: Processes strictly one function at a time (up to ~3,500 input tokens); variable and function names are synthetic guesses
License: Apache-2.0 (code and weights)










Comments