Datasets:
Upload 4 files
Browse files- cpp_dataset/README.md +162 -0
- cpp_dataset/test/test.jsonl +0 -0
- cpp_dataset/train/train.jsonl +0 -0
- cpp_dataset/validation/validation.jsonl +0 -0
cpp_dataset/README.md
ADDED
@@ -0,0 +1,162 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
license: apache-2.0
|
3 |
+
task_categories:
|
4 |
+
- text-generation
|
5 |
+
- fill-mask
|
6 |
+
language:
|
7 |
+
- code
|
8 |
+
size_categories:
|
9 |
+
- 1K<n<10K
|
10 |
+
dataset_info:
|
11 |
+
- config_name: all
|
12 |
+
features:
|
13 |
+
- name: repository_name
|
14 |
+
dtype: string
|
15 |
+
- name: func_path_in_repository
|
16 |
+
dtype: string
|
17 |
+
- name: func_name
|
18 |
+
dtype: string
|
19 |
+
- name: whole_func_string
|
20 |
+
dtype: string
|
21 |
+
- name: language
|
22 |
+
dtype: string
|
23 |
+
- name: func_code_string
|
24 |
+
dtype: string
|
25 |
+
- name: func_code_tokens
|
26 |
+
sequence: string
|
27 |
+
- name: func_documentation_string
|
28 |
+
dtype: string
|
29 |
+
- name: func_documentation_tokens
|
30 |
+
sequence: string
|
31 |
+
- name: split_name
|
32 |
+
dtype: string
|
33 |
+
- name: func_code_url
|
34 |
+
dtype: string
|
35 |
+
splits:
|
36 |
+
- name: train
|
37 |
+
num_bytes: 5850604083
|
38 |
+
num_examples: 1880853
|
39 |
+
- name: test
|
40 |
+
num_bytes: 308626333
|
41 |
+
num_examples: 100529
|
42 |
+
- name: validation
|
43 |
+
num_bytes: 274564382
|
44 |
+
num_examples: 89154
|
45 |
+
download_size: 5117370511
|
46 |
+
dataset_size: 6433794798
|
47 |
+
- config_name: cpp
|
48 |
+
features:
|
49 |
+
- name: repository_name
|
50 |
+
dtype: string
|
51 |
+
- name: func_path_in_repository
|
52 |
+
dtype: string
|
53 |
+
- name: func_name
|
54 |
+
dtype: string
|
55 |
+
- name: whole_func_string
|
56 |
+
dtype: string
|
57 |
+
- name: language
|
58 |
+
dtype: string
|
59 |
+
- name: func_code_string
|
60 |
+
dtype: string
|
61 |
+
- name: func_code_tokens
|
62 |
+
sequence: string
|
63 |
+
- name: func_documentation_string
|
64 |
+
dtype: string
|
65 |
+
- name: func_documentation_tokens
|
66 |
+
sequence: string
|
67 |
+
- name: split_name
|
68 |
+
dtype: string
|
69 |
+
- name: func_code_url
|
70 |
+
dtype: string
|
71 |
+
splits:
|
72 |
+
- name: train
|
73 |
+
num_bytes: 1429272535
|
74 |
+
num_examples: 454451
|
75 |
+
- name: test
|
76 |
+
num_bytes: 82377246
|
77 |
+
num_examples: 26909
|
78 |
+
- name: validation
|
79 |
+
num_bytes: 42358315
|
80 |
+
num_examples: 15328
|
81 |
+
download_size: 1060569153
|
82 |
+
dataset_size: 1554008096
|
83 |
+
configs:
|
84 |
+
- config_name: default
|
85 |
+
data_files:
|
86 |
+
- split: train
|
87 |
+
path: "cpp_dataset/train/train.jsonl"
|
88 |
+
- split: test
|
89 |
+
path: "cpp_dataset/test/test.jsonl"
|
90 |
+
- split: validation
|
91 |
+
path: "cpp_dataset/validation/validation.jsonl"
|
92 |
+
---
|
93 |
+
|
94 |
+
# C++ Dataset
|
95 |
+
> documentation source: https://huggingface.co/docs/datasets/main/en/repository_structure
|
96 |
+
|
97 |
+
|
98 |
+
|
99 |
+
### Supported Tasks and Leaderboards
|
100 |
+
|
101 |
+
- `language-modeling`: The dataset can be used to train a model for modelling programming languages, which consists in building language models for programming languages.
|
102 |
+
|
103 |
+
### Language
|
104 |
+
|
105 |
+
- C++ **programming** language
|
106 |
+
|
107 |
+
|
108 |
+
|
109 |
+
|
110 |
+
## Dataset Structure
|
111 |
+
|
112 |
+
### Data Instances
|
113 |
+
|
114 |
+
A data point consists of a function code along with its documentation. Each data point also contains meta data on the function, such as the repository it was extracted from.
|
115 |
+
```
|
116 |
+
{
|
117 |
+
'id': '0',
|
118 |
+
'repository_name': 'organisation/repository',
|
119 |
+
'func_path_in_repository': 'src/path/to/file.py',
|
120 |
+
'func_name': 'func',
|
121 |
+
'whole_func_string': 'def func(args):\n"""Docstring"""\n [...]',
|
122 |
+
'language': 'python',
|
123 |
+
'func_code_string': '[...]',
|
124 |
+
'func_code_tokens': ['def', 'func', '(', 'args', ')', ...],
|
125 |
+
'func_documentation_string': 'Docstring',
|
126 |
+
'func_documentation_string_tokens': ['Docstring'],
|
127 |
+
'split_name': 'train',
|
128 |
+
'func_code_url': 'https://github.com/<org>/<repo>/blob/<hash>/src/path/to/file.py#L111-L150'
|
129 |
+
}
|
130 |
+
```
|
131 |
+
|
132 |
+
### Data Fields
|
133 |
+
|
134 |
+
- `id`: Arbitrary number
|
135 |
+
- `repository_name`: name of the GitHub repository
|
136 |
+
- `func_path_in_repository`: tl;dr: path to the file which holds the function in the repository
|
137 |
+
- `func_name`: name of the function in the file
|
138 |
+
- `whole_func_string`: Code + documentation of the function
|
139 |
+
- `language`: Programming language in whoch the function is written
|
140 |
+
- `func_code_string`: Function code
|
141 |
+
- `func_code_tokens`: Tokens yielded by Treesitter
|
142 |
+
- `func_documentation_string`: Function documentation
|
143 |
+
- `func_documentation_string_tokens`: Tokens yielded by Treesitter
|
144 |
+
- `split_name`: Name of the split to which the example belongs (one of train, test or valid)
|
145 |
+
- `func_code_url`: URL to the function code on Github
|
146 |
+
|
147 |
+
### Data Splits
|
148 |
+
|
149 |
+
Three splits are available:
|
150 |
+
- train
|
151 |
+
- test
|
152 |
+
- valid
|
153 |
+
|
154 |
+
### Citation Information
|
155 |
+
|
156 |
+
- based on (format and idea): https://huggingface.co/datasets/code_search_net
|
157 |
+
- expanded by
|
158 |
+
@article{husain2019codesearchnet,
|
159 |
+
title={C++ Dataset},
|
160 |
+
author={Klaes, Malte},
|
161 |
+
year={2024}
|
162 |
+
}
|
cpp_dataset/test/test.jsonl
ADDED
The diff for this file is too large to render.
See raw diff
|
|
cpp_dataset/train/train.jsonl
ADDED
The diff for this file is too large to render.
See raw diff
|
|
cpp_dataset/validation/validation.jsonl
ADDED
The diff for this file is too large to render.
See raw diff
|
|