imene-kolli commited on
Commit
4577c12
·
1 Parent(s): dbf3cab
Files changed (1) hide show
  1. README.md +115 -45
README.md CHANGED
@@ -104,46 +104,142 @@ It is particularly useful for comparing:
104
 
105
  ## Access Patterns
106
 
107
- The dataset can be accessed in multiple ways depending on research needs. Scripts for downloading specific subsets are provided on [Github](https://github.com/tobischimanski/pdfQA).
 
108
 
109
- The repository supports multiple usage patterns:
110
 
111
- #### Download Everything
112
 
113
- Clone the entire repository (includes Git LFS objects).
114
 
115
- #### Download by Category
 
 
116
 
117
- Download only `real-pdfQA/` or only `syn-pdfQA/`.
118
 
119
- #### Download by Dataset
120
 
121
- Download a specific dataset across all file types.
122
 
123
- #### Download by Dataset + Type
124
 
125
- Example:
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
126
 
127
- * Only PDFs for a dataset
128
- * Only CSV annotations for a dataset
129
- * Only raw source files for a dataset
130
 
131
- #### Download Single File
132
 
133
- Individual files can be downloaded directly via the Hugging Face API.
134
 
135
- Example (Python):
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
136
 
137
- ```python
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
138
  from huggingface_hub import hf_hub_download
139
 
140
  hf_hub_download(
141
- repo_id="pdfqa/pdfQA",
142
  repo_type="dataset",
143
  filename="syn-pdfQA/01.2_Input_Files_PDF/FinQA/AAL_2010.pdf"
144
  )
145
  ```
146
 
 
 
 
 
 
 
 
 
 
 
147
  ---
148
 
149
  ## Data Modalities
@@ -156,15 +252,7 @@ Depending on the dataset:
156
  * Table-heavy documents
157
  * Mixed structured/unstructured content
158
 
159
- Formats may include:
160
-
161
- * PDF
162
- * CSV
163
- * XLS/XLSX
164
- * EPUB
165
- * HTML/HTM
166
- * TEX
167
- * TXT
168
 
169
  ---
170
 
@@ -186,24 +274,6 @@ This enables:
186
 
187
  ---
188
 
189
- ## Limitations
190
-
191
- * Some datasets originate from external benchmarks and inherit their constraints.
192
- * Synthetic datasets may not reflect real-world noise distribution.
193
- * File sizes can be large due to preservation of raw formats.
194
- * Users must install Git LFS for full cloning.
195
-
196
- ---
197
-
198
- ## License
199
-
200
- Each sub-dataset inherits the license of its original source.
201
- Users must ensure compliance with the licensing terms of individual datasets.
202
-
203
- If you use this collection, please cite the original datasets in addition to this repository.
204
-
205
- ---
206
-
207
  ## Citation
208
 
209
  If you use **pdfQA**, please cite:
 
104
 
105
  ## Access Patterns
106
 
107
+ The dataset supports multiple access patterns depending on research
108
+ needs.
109
 
110
+ All official download scripts are available in the GitHub repository:
111
 
112
+ 👉 https://github.com/tobischimanski/pdfQA
113
 
114
+ Scripts are provided in both:
115
 
116
+ - **Bash (git + Git LFS)** --- recommended for large-scale downloads\
117
+ - **Python (huggingface_hub API)** --- recommended for programmatic
118
+ workflows
119
 
120
+ ------------------------------------------------------------------------
121
 
122
+ ### 1️⃣ Download Everything
123
 
124
+ Download the entire repository (all categories, types, and datasets).
125
 
126
+ #### Bash (git + LFS)
127
 
128
+ ``` bash
129
+ ./tools/download_using_bash/download_all.sh
130
+ ```
131
+
132
+ [Bash script](https://github.com/tobischimanski/pdfQA/blob/main/tools/download_using_bash/download_all.sh)
133
+
134
+
135
+ #### Python (HF API)
136
+
137
+ ``` bash
138
+ python tools/download_using_python/download_all.py
139
+ ```
140
+
141
+ [Python script](https://github.com/tobischimanski/pdfQA/blob/main/tools/download_using_python/download_all.py)
142
+
143
+ ------------------------------------------------------------------------
144
+
145
+ ### 2️⃣ Download by Category
146
+
147
+ Download only:
148
+
149
+ - `real-pdfQA/`
150
+ - or `syn-pdfQA/`
151
+
152
+ #### Example
153
+
154
+ ``` bash
155
+ ./tools/download_using_bash/download_category.sh syn-pdfQA
156
+ ```
157
 
158
+ [Bash script](https://github.com/tobischimanski/pdfQA/blob/main/tools/download_using_bash/download_category.sh)
 
 
159
 
160
+ [Python script](https://github.com/tobischimanski/pdfQA/blob/main/tools/download_using_python/download_category.py)
161
 
162
+ ------------------------------------------------------------------------
163
 
164
+ ### 3️⃣ Download by Dataset (All Types)
165
+
166
+ Download a single dataset across all three file-type folders:
167
+
168
+ - `01.1_Input_Files_Non_PDF/`
169
+ - `01.2_Input_Files_PDF/`
170
+ - `01.3_Input_Files_CSV/`
171
+
172
+ #### Example
173
+
174
+ ``` bash
175
+ ./tools/download_using_bash/download_dataset.sh syn-pdfQA books
176
+ ```
177
+
178
+ [Bash script](https://github.com/tobischimanski/pdfQA/blob/main/tools/download_using_bash/download_dataset.sh)
179
+
180
+ [Python script](https://github.com/tobischimanski/pdfQA/blob/main/tools/download_using_python/download_dataset.py)
181
+
182
+ ------------------------------------------------------------------------
183
+
184
+ ### 4️⃣ Download Arbitrary Folders
185
+
186
+ Download one or multiple arbitrary folder paths.
187
+
188
+ #### Example
189
+
190
+ ``` bash
191
+ ./tools/download_using_bash/download_folders.sh \
192
+ "syn-pdfQA/01.2_Input_Files_PDF/books" \
193
+ "syn-pdfQA/01.3_Input_Files_CSV/books"
194
+ ```
195
 
196
+ [Bash script](https://github.com/tobischimanski/pdfQA/blob/main/tools/download_using_bash/download_folders.sh)
197
+
198
+ [Python script](https://github.com/tobischimanski/pdfQA/blob/main/tools/download_using_python/download_folders.py)
199
+
200
+ ------------------------------------------------------------------------
201
+
202
+ ### 5️⃣ Download Specific Files
203
+
204
+ Download one or more individual files.
205
+
206
+ #### Example (Bash)
207
+
208
+ ``` bash
209
+ ./tools/download_using_bash/download_files.sh \
210
+ "syn-pdfQA/01.2_Input_Files_PDF/books/file1.pdf"
211
+ ```
212
+
213
+ [Bash script](https://github.com/tobischimanski/pdfQA/blob/main/tools/download_using_bash/download_files.sh)
214
+
215
+ [Python script](https://github.com/tobischimanski/pdfQA/blob/main/tools/download_using_python/download_files.py)
216
+
217
+ ------------------------------------------------------------------------
218
+
219
+ ### 6️⃣ Direct API Access (Single File)
220
+
221
+ Files can also be downloaded directly using the Hugging Face API. Example:
222
+
223
+ ``` python
224
  from huggingface_hub import hf_hub_download
225
 
226
  hf_hub_download(
227
+ repo_id="pdfqa/pdfQA-Benchmark",
228
  repo_type="dataset",
229
  filename="syn-pdfQA/01.2_Input_Files_PDF/FinQA/AAL_2010.pdf"
230
  )
231
  ```
232
 
233
+ ------------------------------------------------------------------------
234
+
235
+ ## Recommended Usage
236
+
237
+ - For **large-scale research experiments** → use **Bash + git LFS**
238
+ (fully resumable).
239
+ - For **automated pipelines** → use **Python scripts**.
240
+ - For **fine-grained subset control** → use folder or file-based
241
+ scripts.
242
+
243
  ---
244
 
245
  ## Data Modalities
 
252
  * Table-heavy documents
253
  * Mixed structured/unstructured content
254
 
255
+ Formats may include: `PDF`, `CSV`, `XLS/XLSX`, `EPUB`, `HTML/HTM`, `TEX`, `TXT`
 
 
 
 
 
 
 
 
256
 
257
  ---
258
 
 
274
 
275
  ---
276
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
277
  ## Citation
278
 
279
  If you use **pdfQA**, please cite: