<jupyter_start><jupyter_text>Example of creating a dataset from filesystem using `datasets` Installing [gdown](https://github.com/wkentaro/gdown) to automatically download the dataset from gdrive provided by the dataset creator.<jupyter_code>!pip install gdown
!gdown "https://drive.google.com/u/0/uc?export=download&confirm=2rTA&id=130flJ0u_5Ox5D-pQFa5lGiBLqILDBmXX" # for files

import json
with open("evaluate_news.json","r+") as f, open('dataset.jsonl', 'w') as outfile:
    JSON_file = json.load(f)
    for entry in JSON_file:
        json.dump(entry, outfile)
        outfile.write('\n')

from datasets import load_dataset

ds = load_dataset('json', data_files='dataset.jsonl')
ds["train"][0]
ds["train"].features<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.1308411214953271, 'fraction_numerical': 0.01335113484646195, 'mean_word_length': 5.8807339449541285, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '475321', 'license': 'MIT', 'n_tokens_mistral': 268, 'n_tokens_neox': 259, 'n_words': 57, 'path': 'dataset-creation.ipynb', 'repo_name': 'philschmid/keras-financial-summarization-huggingface', 'size': '749'}