TokenBender commited on
Commit
ff83410
·
verified ·
1 Parent(s): 0136d89

Expand dataset README with file tree and oracle flow

Browse files
Files changed (1) hide show
  1. README.md +117 -2
README.md CHANGED
@@ -22,6 +22,81 @@ This is a tiny 5-row Hugging Face dataset skeleton for generating oracle SFT dat
22
 
23
  The rows are intentionally synthetic. They define the exact shape we want for real PIE C++ tasks without exposing or depending on private prepared artifacts.
24
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
25
  ## What The Oracle Writer Receives
26
 
27
  Each row is a prompt-only optimization task. The canonical input is `messages`, not `prompt`.
@@ -38,7 +113,7 @@ Each row is a prompt-only optimization task. The canonical input is `messages`,
38
  - `constraints`: required assistant output contract.
39
  - `metadata`: problem notes and expected optimization direction.
40
 
41
- ## Required Oracle Return Format
42
 
43
  The 5 seed rows intentionally vary the input style so the model does not overfit to one prompt wording:
44
 
@@ -48,6 +123,10 @@ The 5 seed rows intentionally vary the input style so the model does not overfit
48
  - structured user spec with a system contract;
49
  - natural user request with inline answer-format instruction.
50
 
 
 
 
 
51
  For each input row, return one SFT-ready chat row. Copy the input `messages` exactly, then append the assistant answer:
52
 
53
  ```json
@@ -84,7 +163,17 @@ The assistant message must contain exactly:
84
  2. One fenced C++ block starting with ```` ```cpp ````.
85
  3. No extra prose outside those two parts.
86
 
87
- The output format is intentionally fixed. Only the input prompt style varies.
 
 
 
 
 
 
 
 
 
 
88
 
89
  ## Validation Rule For Real Training
90
 
@@ -96,6 +185,32 @@ Returned oracle rows should not be used for SFT until our local verifier confirm
96
  - hidden/generated tests pass when available;
97
  - reward or grade is full mark.
98
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
99
  ## Loading Locally
100
 
101
  ```python
 
22
 
23
  The rows are intentionally synthetic. They define the exact shape we want for real PIE C++ tasks without exposing or depending on private prepared artifacts.
24
 
25
+ The goal is to give an oracle-data writer a clean contract:
26
+
27
+ 1. read a C++ optimization task;
28
+ 2. produce one verified optimized solution;
29
+ 3. return the result in chat/SFT format;
30
+ 4. include enough verification metadata for us to decide whether the row is safe to train on.
31
+
32
+ This dataset is not a benchmark and should not be used to claim model quality. It is a format sample for building the real oracle dataset.
33
+
34
+ ## Repository Layout
35
+
36
+ ```text
37
+ dummy-pie-cpp-oracle-seed
38
+ ├── README.md
39
+ ├── ORACLE_WRITER_INSTRUCTIONS.md
40
+ ├── data/
41
+ │ ├── oracle_seed.jsonl
42
+ │ └── oracle_return_example.jsonl
43
+ └── schema/
44
+ ├── oracle_seed.schema.json
45
+ └── oracle_return.schema.json
46
+ ```
47
+
48
+ ### `README.md`
49
+
50
+ This file. It explains the dataset purpose, the row contract, the expected return format, and the intended reading order.
51
+
52
+ ### `ORACLE_WRITER_INSTRUCTIONS.md`
53
+
54
+ The short handoff file for the person or agent generating oracle solutions. Send them this file first. It tells them how to read each row, what answer format to produce, and what verification fields to fill.
55
+
56
+ ### `data/oracle_seed.jsonl`
57
+
58
+ The actual 5-row seed dataset. Each line is one prompt-only C++ optimization task.
59
+
60
+ Important fields:
61
+
62
+ - `messages`: the canonical chat input. Use this as the real prompt.
63
+ - `prompt_template_id`: the input style used by the row.
64
+ - `prompt`: a flattened fallback for tools that cannot consume chat messages.
65
+ - `source_code`: the original inefficient but correct C++20 program.
66
+ - `visible_tests`: public tests included in the task.
67
+ - `compile`: compiler command and timeout.
68
+ - `run`: runtime and memory limits.
69
+ - `constraints`: required assistant output contract.
70
+ - `metadata`: problem notes and expected optimization direction.
71
+
72
+ ### `data/oracle_return_example.jsonl`
73
+
74
+ One solved example showing the expected output from an oracle writer. The returned row copies the original input `messages` and appends one `assistant` message with the optimized C++ answer.
75
+
76
+ ### `schema/oracle_seed.schema.json`
77
+
78
+ JSON Schema for validating input seed rows before sending them to an oracle writer.
79
+
80
+ ### `schema/oracle_return.schema.json`
81
+
82
+ JSON Schema for validating returned oracle rows before running the stronger local verifier.
83
+
84
+ ## Recommended Reading Order
85
+
86
+ For an oracle-data writer:
87
+
88
+ 1. `ORACLE_WRITER_INSTRUCTIONS.md`
89
+ 2. `data/oracle_seed.jsonl`
90
+ 3. `data/oracle_return_example.jsonl`
91
+
92
+ For a training or verification owner:
93
+
94
+ 1. `README.md`
95
+ 2. `schema/oracle_seed.schema.json`
96
+ 3. `schema/oracle_return.schema.json`
97
+ 4. `data/oracle_seed.jsonl`
98
+ 5. `data/oracle_return_example.jsonl`
99
+
100
  ## What The Oracle Writer Receives
101
 
102
  Each row is a prompt-only optimization task. The canonical input is `messages`, not `prompt`.
 
113
  - `constraints`: required assistant output contract.
114
  - `metadata`: problem notes and expected optimization direction.
115
 
116
+ ## Prompt Diversity
117
 
118
  The 5 seed rows intentionally vary the input style so the model does not overfit to one prompt wording:
119
 
 
123
  - structured user spec with a system contract;
124
  - natural user request with inline answer-format instruction.
125
 
126
+ The output format is intentionally fixed. Only the input prompt style varies.
127
+
128
+ ## Required Oracle Return Format
129
+
130
  For each input row, return one SFT-ready chat row. Copy the input `messages` exactly, then append the assistant answer:
131
 
132
  ```json
 
163
  2. One fenced C++ block starting with ```` ```cpp ````.
164
  3. No extra prose outside those two parts.
165
 
166
+ ## End-To-End Flow
167
+
168
+ ```text
169
+ oracle_seed row
170
+ -> oracle writer reads messages
171
+ -> oracle writer writes optimized C++ answer
172
+ -> oracle writer compiles and runs visible tests
173
+ -> oracle writer returns oracle_return row
174
+ -> local verifier checks format, compile, tests, and score
175
+ -> only full-mark verified rows become SFT data
176
+ ```
177
 
178
  ## Validation Rule For Real Training
179
 
 
185
  - hidden/generated tests pass when available;
186
  - reward or grade is full mark.
187
 
188
+ The `verification` object in returned rows is useful metadata, but it is not enough by itself. It should be treated as a claim from the oracle writer. The final training set should be built only after our own verifier confirms the row.
189
+
190
+ ## Intended SFT Conversion
191
+
192
+ Once a returned row is verified, the `messages` array is already in SFT-ready chat form:
193
+
194
+ ```json
195
+ [
196
+ {"role": "system", "content": "...optional system instruction..."},
197
+ {"role": "user", "content": "...C++ optimization task..."},
198
+ {"role": "assistant", "content": "<reasoning>...</reasoning>\n```cpp\n...\n```"}
199
+ ]
200
+ ```
201
+
202
+ Rows that fail compilation, fail tests, have invalid formatting, or receive partial credit should be excluded from SFT.
203
+
204
+ ## Boundary
205
+
206
+ This dummy dataset only specifies the data interface. It does not include:
207
+
208
+ - real PIE C++ train/eval rows;
209
+ - hidden tests;
210
+ - a full verifier implementation;
211
+ - model training scripts;
212
+ - claims about model improvement.
213
+
214
  ## Loading Locally
215
 
216
  ```python