Windows x64
64-bit code, unoptimized and with /O2.
msvc-x64-Od / msvc-x64-O2Pramen is my neural decompiler for Windows and MS-DOS. It takes a single function’s assembly and proposes readable C. I trained it from scratch, on assembly and C alone.
An actual saved model output for string length. This variant passed the repository’s tests; this is not live inference in the browser.
MOV ECX,dword ptr [ESP + 4]
MOV EAX,ECX
CMP byte ptr [ECX],0
JE LAB_1
NOP dword ptr [EAX + EAX]
LAB_2:
INC EAX
CMP byte ptr [EAX],0
JNE LAB_2
LAB_1:
SUB EAX,ECX
RETsize_t strlen(const char *str)
{
const char *p = str;
while (*p)
p++;
return p - str;
}The output is a proposal. Names are invented, types are inferred and the logic needs checking. It does not recover the original source code verbatim.
Six variants for specific compilers and optimization levels. The included normalizer handles input from dumpbin, wdis or Ghidra.
64-bit code, unoptimized and with /O2.
msvc-x64-Od / msvc-x64-O232-bit cdecl code, unoptimized and with /O2.
msvc-x86-Od / msvc-x86-O216-bit real mode: unoptimized small model and large model with far calls and -ox.
dos16-small-od / dos16-large-oxA task counts as solved when the generated C compiles and passes the original tests. HumanEval-C is recompiled with the same toolchains as the training data.
Greedy decoding, up to 600 new tokens. Optimized code is much harder; common failures include parameter types and invented helper names. The model card does not report a result for msvc-x86-O2.
Methodology and results ↗| Variant | Tasks | Pass rate |
|---|---|---|
msvc-x64-Od | 167 | 40.7 % |
msvc-x64-O2 | 167 | 13.2 % |
msvc-x86-Od | 167 | 32.3 % |
dos16-small-od | 163 | 30.1 % |
dos16-large-ox | 163 | 11.7 % |
A GPT-2-style decoder-only transformer: 16 layers, 16 attention heads, a 4,096-token context and a custom 16,384-token tokenizer.
Training uses 5.26 million assembly → C pairs from ExeBench (2.33 billion tokens), compiled six ways and deduplicated, plus 3.5 billion tokens of C/C++ source code.
Pramen handles one function at a time, up to roughly 3,500 input tokens. Compilers other than MSVC 19.36 and Open Watcom V2 are outside its training distribution. Globals and structs are only visible as addresses and offsets.
Download the model and start the Python web UI at 127.0.0.1:8780. A GPU is recommended; CPU inference works but is slow.
Documentation on Hugging Face ↗pip install huggingface_hub
hf download radix16/pramen --local-dir pramen
cd pramen
pip install -r requirements.txt
python -m pramen.web Use the included Python runtime. The custom tokenizer is not compatible with standard text prompts in llama.cpp / LM Studio.
Source: Pramen model card and examples, as of October 6, 2026. Weights and code: Apache-2.0. Training sources retain their original licenses and include GPL-2.0; see the model repository for details.