mlc-ai/xgrammar has 51,302 source lines of code out of 63,427 total lines across 153 files, counted from the main ref at commit 614ab01d2af3 by the OctoCounts tokei engine on 2026-10-18. The report is cached by commit, tokei version, and analysis options, so recounting the same revision returns exactly these numbers.
As of 2026-10-18 (commit 614ab01d2af3), mlc-ai/xgrammar contains 63,427 total lines: 51,302 code, 6,835 comments, 5,290 blank, across 153 files in 16 languages (top: C++ 53.8%). Custom configuration (tests excluded, docs excluded, generated excluded). Counted with tokei via OctoCounts.
OctoCounts produced this report by resolving mlc-ai/xgrammar to commit 614ab01d2af3, downloading the repository source archive, and counting every source file with tokei, the open-source line counter written in Rust. The table below breaks the count down by programming language into files, total lines, code lines, comment lines, and blank lines, so the figures can be compared across languages and projects. Results are cached by commit, tokei version, and analysis options, so counting the same revision again reproduces exactly these numbers.
This is a medium-sized codebase by counted code lines. Code represents 80.9% of all lines, comments represent 10.8%, and the repository averages 335 code lines per file. C++ accounts for 53.8% of counted code.
| Language | Files | Lines | Code | Comments | Blanks |
|---|---|---|---|---|---|
| C++ | 33 | 32253 | 27587 | 2222 | 2444 |
| Python | 28 | 8699 | 7633 | 213 | 853 |
| C Header | 44 | 12250 | 7160 | 3544 | 1546 |
| JSON | 5 | 6881 | 6881 | 0 | 0 |
| TypeScript | 4 | 1293 | 782 | 407 | 104 |
| CUDA | 1 | 286 | 237 | 18 | 31 |
| Sass | 1 | 238 | 200 | 1 | 37 |
| Shell | 11 | 324 | 199 | 64 | 61 |
| CMake | 5 | 218 | 178 | 14 | 26 |
| TOML | 1 | 188 | 126 | 34 | 28 |
| SVG | 3 | 111 | 104 | 0 | 7 |
| JavaScript | 3 | 80 | 72 | 0 | 8 |
Top language (C++ 53.8%). Generated at .
mlc-ai/xgrammar has 63,427 total lines, including 51,302 code lines, 6,835 comment lines, and 5,290 blank lines.
OctoCounts resolved the public GitHub repository to commit 614ab01d2af3, downloaded the source archive, counted it with tokei, and cached the report by commit, tokei version, and analysis options.
This OctoCounts report was generated from main at commit 614ab01d2af3 on 2026-10-18T23:08:27.315148422+00:00.
Other public repositories with an OctoCounts report, ranked by top language and code size similarity:
Play the growth animation for mlc-ai/xgrammar on this page — 51,302 code lines across 12 languages, counted by tokei.