File size: 4,086 Bytes
119c031
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
---

license: other
task_categories:
- text-generation
language:
- en
- code
tags:
- kernel
- systems-programming
- computer-architecture
- algorithms
pretty_name: kernel-llm pool (part 1, knowledge slice)
---


# kernel-llm pool — part 1: books, algorithms, mathematics, architecture

Training text for a kernel/machine-level C specialist. This is **part 1 of a

multi-part pool**, not the full 1T-token dataset: it is the knowledge slice
(design, architecture, algorithms, maths), built from repositories whose licences
were read rather than assumed.

Volume is stated as measured: **15.6M tokens** across 6735 rows, where a token is
estimated as bytes/3.6 because no tokenizer was run over this part. Byte counts are
exact; the token figure is an estimate and is labelled as one in `stats.json`.

## Contents

| source | bucket | licence | rows | est. tokens | flag |
|---|---|---|---:|---:|---|
| `opentitan` | arch_code | Apache-2.0 | 4065 | 8034k | clean |

| `vulkan-spec` | books | CC-BY-4.0 | 726 | 3118k | clean |

| `aosa` | books | CC-BY-3.0 | 76 | 797k | clean |

| `rocket-chip` | arch_code | BSD-3-Clause OR Apache-2.0 | 308 | 592k | clean |
| `discrete-book` | math | CC-BY-NC-SA-4.0 | 132 | 577k | restricted |
| `cp-algorithms` | algorithms | CC-BY-SA-4.0 | 165 | 457k | clean |
| `miaow` | arch_code | BSD-3-Clause | 204 | 447k | clean |

| `opencl-spec` | books | CC-BY-4.0 | 106 | 422k | clean |

| `thealgorithms-c` | algorithms | GPL-3.0 | 398 | 275k | clean |

| `sdxpy` | books | CC-BY-NC-4.0 | 115 | 255k | restricted |

| `spike` | arch_code | BSD-3-Clause | 259 | 249k | clean |
| `vexriscv` | arch_code | MIT | 97 | 228k | clean |

| `ods` | books | CC-BY-2.5-CA | 19 | 135k | clean |

| `ods-code` | algorithms | CC-BY-2.5-CA | 65 | 61k | clean |

| **total** | | | **6735** | **15.6M** | |



Every row carries `source`, `repo_license`, `spdx`, `commit`, `n_bytes`, `n_tokens`
(`-1` when not measured), `restricted` and `path`, so a subset can be rebuilt exactly
and every row can be traced to the commit it came from.

## Licence flags — read before training

This pool contains NonCommercial material. It is included and marked, but it is
**not** free for commercial use:

* `discrete-book` — CC-BY-NC-SA-4.0
* `sdxpy` — CC-BY-NC-4.0

Filter those rows out of any commercial training mix:

```python

ds = ds.filter(lambda r: not r["restricted"])

```

Publishing this data, or keeping it private, does not change the position: an NC
licence restricts the *use*, not only the redistribution, so training a model you
sell on NC text is a commercial use even if the text never leaves your disk.

Publisher-copyrighted books (Operating Systems: Three Easy Pieces, Computer
Architecture: A Quantitative Approach, Designing Data-Intensive Applications,
Systems Performance, Linux Kernel Development, Refactoring, Design Patterns) are
**not present at all** — no rows, no URLs. A book you can read online is not a
book you may train on.

## What is not here

* kernel and driver trees (Linux, RTOS, GPU drivers) — part 2
* other kernels and compute kernels — part 3
* Stack v2 subsets — part 4 (gated)
* traces, commits, synthetic and replay data — part 5

## Dedup and splits

`6735` distinct near-duplicate signatures; exact duplicates and MinHash near-duplicates
were dropped, with sources deduplicated in priority order so a trusted copy wins over
a mirror. `heldout` is 2% of groups, capped so no bucket is gutted.

**The held-out split is public.** It is a development split for measuring
contamination, not a secret holdout; encrypting public data does not create one.

## How to load

```python

from datasets import load_dataset

ds = load_dataset("ruthvikanne/kernel-pool-knowledge", split="train")

```

`mix.json` and `mix-manifest.parquet` hold a *plan* (tier weights, repeat counts)
that joins on `path`; the text stays in the shards. `LICENSES.json` records, per
source, the declared licence, the evidence it was read from, and the exact commit.