quanghieupham commited on
Commit
5fb8685
·
verified ·
1 Parent(s): 1aed8d6

Prepare dataset card for public release

Browse files
Files changed (1) hide show
  1. README.md +128 -98
README.md CHANGED
@@ -2,146 +2,176 @@
2
  pretty_name: LongHarness
3
  language:
4
  - en
 
 
 
 
 
 
 
5
  tags:
6
  - long-context
7
  - benchmark
8
  - language-model-agents
 
 
 
 
9
  ---
10
 
11
- # LongHarness
12
 
13
- LongHarness evaluates language-model harnesses on long-context tasks that
14
- require retrieval, verification, and multi-step reasoning. It contains four
15
- task suites and 200 evaluation instances.
 
 
16
 
17
- ## Links
 
18
 
19
- - Project website: `https://stringnlplab.github.io/longharness` (planned)
20
- - Full dataset: [StringNLP/longharness](https://huggingface.co/datasets/StringNLP/longharness)
21
- - Paper: forthcoming
22
 
23
- The GitHub repository contains evaluation code, documentation, and two complete
24
- examples from each task. The full benchmark, including all contexts, manifests,
25
- and answer keys, will be distributed through Hugging Face.
 
 
 
26
 
27
- ## Tasks
 
 
28
 
29
- | Task ID | Paper name | Full instances | GitHub examples |
30
- |---|---|---:|---:|
31
- | `constraint-solving-search` | Constraint Solving Search | 50 | 2 |
32
- | `equivalent-program-pair-search` | Equivalent Program Pair Search | 50 | 2 |
33
- | `program-execution-tracing` | Program Execution Tracing | 50 | 2 |
34
- | `outlier-memo-detection` | Outlier Memo Detection | 50 | 2 |
35
 
36
- Task-specific descriptions and response formats are under `tasks/<task>/`.
 
37
 
38
- ## Repository Contents
 
 
 
 
 
 
 
 
 
 
39
 
40
  ```text
41
  README.md
42
  RELEASE.json
43
- examples-manifest.jsonl # eight examples tracked by GitHub
 
44
  score.py
 
45
  tasks/
46
- <task>/
47
  README.md
48
- contexts/
49
- sample-00000.md # tracked example
50
- sample-00001.md # tracked example
51
- answers/
52
- sample-00000.json
53
- sample-00001.json
54
- tools/
55
- stage_huggingface.py
56
- verify_release.py
57
- ```
58
-
59
- The full Hugging Face snapshot additionally contains:
60
-
61
- ```text
62
- manifest.jsonl # all 200 instances
63
- DATA_CHECKSUMS.sha256
64
- tasks/<task>/manifest.jsonl
65
- tasks/<task>/contexts/ # 50 contexts per task
66
- tasks/<task>/answers/ # 50 answer keys per task
67
- ```
68
-
69
- Contexts are model-visible. Answer files must remain outside the agent's
70
- workspace during evaluation.
71
-
72
- ## Getting the Data
73
-
74
- The complete release is distributed through Hugging Face:
75
-
76
- ```bash
77
- hf download StringNLP/longharness \
78
- --repo-type dataset \
79
- --local-dir longharness
80
  ```
81
 
82
- Until then, this repository's tracked examples can be used to inspect the task
83
- formats and test integrations.
 
84
 
85
- ## Verify the Data
86
 
87
- The verifier automatically checks the full 200-instance release when
88
- `manifest.jsonl` is available. In a GitHub-only checkout, it checks the eight
89
- tracked examples instead.
90
-
91
- ```bash
92
- python tools/verify_release.py
93
- ```
94
 
95
- To explicitly check only the tracked examples:
96
 
97
- ```bash
98
- python tools/verify_release.py --examples
99
  ```
100
 
101
- ## Submission Format
102
-
103
- `score.py` accepts one JSON object per line with `task`, `index`, and
104
- `prediction`. Predictions use these schemas:
105
 
106
  - Constraint Solving Search: `{"matches": [...]}`
107
  - Equivalent Program Pair Search: `[[cell_a, cell_b], ...]`
108
  - Program Execution Tracing: `{"answer": {...}, "evidence": [...]}`
109
  - Outlier Memo Detection: `["M-001", "M-002", ...]`
110
 
111
- Score a full release with:
112
 
113
  ```bash
 
114
  python score.py predictions.jsonl --output scores.json
115
  ```
116
 
117
- Score only the GitHub examples with:
 
118
 
119
- ```bash
120
- python score.py predictions.jsonl \
121
- --manifest examples-manifest.jsonl \
122
- --output scores.json
123
- ```
124
-
125
- The primary metric is exact instance accuracy. The scorer also reports
126
- answer-only accuracy for tasks whose required response includes provenance.
127
-
128
- ## Distribution
129
-
130
- The repositories serve distinct roles:
131
-
132
- - **GitHub:** code, documentation, issue tracking, and two examples per task.
133
- - **Hugging Face:** the complete versioned dataset and answer keys.
134
- - **Project website:** task overview, results, paper, and links to both repos.
135
 
136
- The planned website URL does not require a separate organization homepage
137
- repository. A repository named `longharness` under the `stringnlplab` GitHub
138
- organization can publish a project site directly at
139
- `https://stringnlplab.github.io/longharness` through GitHub Pages.
140
 
141
- Maintainer instructions for creating the GitHub repository, staging the full
142
- Hugging Face snapshot, and enabling the website are in `PUBLISHING.md`.
 
 
143
 
144
- ## Release Status
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
145
 
146
- The data snapshot and scoring code are prepared. Before public release, replace
147
- the placeholder links and add the final license and citation metadata.
 
2
  pretty_name: LongHarness
3
  language:
4
  - en
5
+ multilinguality:
6
+ - monolingual
7
+ size_categories:
8
+ - n<1K
9
+ task_categories:
10
+ - question-answering
11
+ - text-classification
12
  tags:
13
  - long-context
14
  - benchmark
15
  - language-model-agents
16
+ - agent-evaluation
17
+ - retrieval
18
+ - reasoning
19
+ - code
20
  ---
21
 
22
+ # LongHarness: Stress-Testing Language Model Harnesses for Long-Context Reasoning
23
 
24
+ LongHarness evaluates how language-model harnesses access and reason over long
25
+ contexts. It is designed to distinguish context-access strategies, including
26
+ direct reading, lexical and semantic retrieval, iterative agents, and recursive
27
+ language-model harnesses. The benchmark contains 200 evaluation instances
28
+ across four task suites.
29
 
30
+ - [Project website](https://stringnlplab.github.io/longharness/)
31
+ - [GitHub repository](https://github.com/StringNLPLAB/longharness)
32
 
33
+ ## Benchmark Tasks
 
 
34
 
35
+ | Task | Context | Required output | Instances |
36
+ |---|---|---|---:|
37
+ | Constraint Solving Search | Documents about 160 people and a query containing three to five conditions | The five person IDs satisfying every condition | 50 |
38
+ | Equivalent Program Pair Search | 200 anonymous Python programs with semantically confusable mutants | Every semantically equivalent program pair | 50 |
39
+ | Program Execution Tracing | 320 shuffled computation cells and an eight-step final query | The final structured result and eight supporting cell IDs | 50 |
40
+ | Outlier Memo Detection | 700 memos containing 2,500 statements | The 15 memo IDs containing conflicting claims | 50 |
41
 
42
+ Every task uses exact instance accuracy. Partial outputs, missing items, and
43
+ extra items are incorrect under the primary metric. Program Execution Tracing
44
+ also reports answer-only accuracy as an auxiliary metric.
45
 
46
+ ## Download
 
 
 
 
 
47
 
48
+ LongHarness is distributed as raw Markdown contexts, JSON answer keys, and
49
+ JSONL manifests. Download the complete repository snapshot with:
50
 
51
+ ```bash
52
+ hf download StringNLP/longharness \
53
+ --repo-type dataset \
54
+ --local-dir longharness
55
+ ```
56
+
57
+ This release is not packaged as a row-oriented `datasets.Dataset`. Preserving
58
+ the original context documents and keeping answer keys outside the agent's
59
+ workspace are part of the evaluation protocol.
60
+
61
+ ## Repository Structure
62
 
63
  ```text
64
  README.md
65
  RELEASE.json
66
+ DATA_CHECKSUMS.sha256
67
+ manifest.jsonl
68
  score.py
69
+ tools/verify_release.py
70
  tasks/
71
+ <task-id>/
72
  README.md
73
+ manifest.jsonl
74
+ contexts/sample-00000.md
75
+ answers/sample-00000.json
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
76
  ```
77
 
78
+ The root manifest contains all 200 instances. Each row identifies the task,
79
+ instance index, context path, answer path, context byte count, and SHA-256
80
+ digest. Task manifests may include additional task-specific statistics.
81
 
82
+ ## Evaluation Protocol
83
 
84
+ Expose only the selected context and task instruction to the evaluated system.
85
+ Do not expose `answers/`, manifests containing answer paths, the scorer, or
86
+ other instances from the repository. Answer files are public for reproducible
87
+ scoring, so results should be treated as benchmark evaluation rather than
88
+ closed-test assessment.
 
 
89
 
90
+ Predictions are JSON Lines records with `task`, `index`, and `prediction`:
91
 
92
+ ```json
93
+ {"task":"constraint-solving-search","index":0,"prediction":{"matches":["P-018","P-076","P-096","P-101","P-155"]}}
94
  ```
95
 
96
+ The prediction value has a task-specific schema:
 
 
 
97
 
98
  - Constraint Solving Search: `{"matches": [...]}`
99
  - Equivalent Program Pair Search: `[[cell_a, cell_b], ...]`
100
  - Program Execution Tracing: `{"answer": {...}, "evidence": [...]}`
101
  - Outlier Memo Detection: `["M-001", "M-002", ...]`
102
 
103
+ Run the official scorer from the downloaded snapshot:
104
 
105
  ```bash
106
+ cd longharness
107
  python score.py predictions.jsonl --output scores.json
108
  ```
109
 
110
+ The scorer reports exact and answer-only accuracy per task, plus macro-average
111
+ exact accuracy across the four task suites.
112
 
113
+ ## Integrity Check
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
114
 
115
+ Validate all manifests, files, checksums, and task counts before evaluation:
 
 
 
116
 
117
+ ```bash
118
+ cd longharness
119
+ python tools/verify_release.py
120
+ ```
121
 
122
+ `DATA_CHECKSUMS.sha256` and the digests in `RELEASE.json` provide additional
123
+ snapshot-level integrity information.
124
+
125
+ ## Construction
126
+
127
+ Each instance is generated from a hidden structured specification before its
128
+ public context is rendered. The specification is a predicate world, relation
129
+ graph, computation graph, or executable program family, depending on the task.
130
+ A task-specific solver computes the gold answer, controlled mutations create
131
+ hard distractors, and deterministic validators recompute the answer and verify
132
+ the intended role of every required item.
133
+
134
+ Equivalent Program Pair Search is adapted from standard-input APPS problems.
135
+ Its answer keys represent agreement over the retained valid-input test suites
136
+ and additional checks; they are not formal proofs of equivalence over arbitrary
137
+ Python inputs.
138
+
139
+ ## Intended Use
140
+
141
+ LongHarness is intended for evaluating the accuracy and efficiency of systems
142
+ that process long contexts, especially agent harnesses and retrieval-augmented
143
+ reasoning systems. It is not intended as a training corpus, a measure of general
144
+ intelligence, or a substitute for evaluation on natural user workloads.
145
+
146
+ When reporting results, include the model, harness, task-level exact accuracy,
147
+ macro-average exact accuracy, token accounting method, and execution-cost
148
+ assumptions. Harness configurations and tool access can materially affect both
149
+ accuracy and cost.
150
+
151
+ ## Limitations
152
+
153
+ - The benchmark contains constructed evaluation environments rather than
154
+ naturally occurring user sessions.
155
+ - It covers English documents and Python programs only.
156
+ - Exact-set scoring can understate progress on partially correct responses.
157
+ - Public answer keys make contamination possible; do not use this release for
158
+ training or expose answer-bearing files during inference.
159
+ - Program equivalence is validated behaviorally over explicit input contracts
160
+ and tests, not proven for every possible Python object.
161
+ - Performance on these 200 instances should not be interpreted as a complete
162
+ measure of long-context capability.
163
+
164
+ ## Citation
165
+
166
+ The paper is in preparation. In the meantime, please use this provisional
167
+ citation:
168
+
169
+ ```bibtex
170
+ @misc{pham2026longharness,
171
+ title = {{LongHarness Bench}: Stress-Testing Language Model Harnesses for Long-Context Reasoning},
172
+ author = {Pham, Quang Hieu and Nguyen, Thuy Duong and Chen, Jocelyn Qiaochu and Ye, Xi},
173
+ year = {2026},
174
+ note = {Preprint}
175
+ }
176
+ ```
177