File size: 1,794 Bytes
6eec01b
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
f5cb56d
 
 
6eec01b
 
 
 
 
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
---
language:
- en
license: cc-by-sa-4.0
tags:
- python
- stackoverflow
- question-answering
- instruct
size_categories:
- 1K<n<10K
---

# StackOverflow Python QA Dataset

[![Status](https://img.shields.io/badge/Status-Active-success)](https://github.com/meeAtif)
[![License](https://img.shields.io/badge/License-CC--BY--SA--4.0-lightgrey)](https://creativecommons.org/licenses/by-sa/4.0/)

## Description

This dataset contains high-quality Python questions and answers scraped from StackOverflow. It is designed for instruct-tuning Large Language Models (LLMs) or for question-answering tasks.

- **Source**: StackOverflow
- **Selection Criteria**:
    - Tag: `python`
    - Score: > 10
    - Must have an **accepted answer**
- **Content**: Pairs of instructions (Question) and outputs (Accepted Answer).

## Dataset Structure

The dataset consists of the following fields:

- `question_id`: The unique identifier for the question on StackOverflow.
- `score`: The vote score of the question.
- `tags`: A list of tags associated with the question.
- `creation_date`: The timestamp of when the question was asked.
- `instruction`: The full question title and body, cleaned of HTML.
- `output`: The full body of the accepted answer, cleaned of HTML.

## Sample Entry

```json
{
  "question_id": 12345,
  "score": 50,
  "tags": ["python", "list-comprehension"],
  "instruction": "How do I create a list... \n\n I have a loop that...",
  "output": "You can use a list comprehension:\n\n [x for x in iterable]"
}
```


## Author


- **GitHub:** [@meeAtif](https://github.com/meeAtif)
- **Linkedin:** [@meAtif](https://www.linkedin.com/in/meatif/)
- **HuggingFace:** [@meeAtif](https://huggingface.co/meeAtif)
- **Email:** iatif@proton.me
- **DM For:** Collaborations, Feedback, or Updates

---
---