一个包含很多JSON的文件,这个文件的定义是什么?
A file that contains many JSON, what is the definition of such file?
我有一个包含很多词典的文件,每一行都有自己独特的词典,而且这个文件中有很多行。
{"text": "bla bla", "year": 1933, "price": 43}
{"text": "bla blu", "year": 1934, "price": 41}
{"text": "blu bla", "year": 1935, "price": 43}
{"text": "blu blu", "year": 1936, "price": 44}
只是想强调字典没有插入到列表中,这就是它的方式,文件中的每个新行都包含一个字典。
这是一个 JSON 行文本文件格式:http://jsonlines.org/
JSON Lines text format, also called newline-delimited JSON. JSON Lines is a convenient format for storing structured data that may be processed one record at a time. It works well with unix-style text processing tools and shell pipelines. It's a great format for log files. It's also a flexible format for passing messages between cooperating processes.
我有一个包含很多词典的文件,每一行都有自己独特的词典,而且这个文件中有很多行。
{"text": "bla bla", "year": 1933, "price": 43}
{"text": "bla blu", "year": 1934, "price": 41}
{"text": "blu bla", "year": 1935, "price": 43}
{"text": "blu blu", "year": 1936, "price": 44}
只是想强调字典没有插入到列表中,这就是它的方式,文件中的每个新行都包含一个字典。
这是一个 JSON 行文本文件格式:http://jsonlines.org/
JSON Lines text format, also called newline-delimited JSON. JSON Lines is a convenient format for storing structured data that may be processed one record at a time. It works well with unix-style text processing tools and shell pipelines. It's a great format for log files. It's also a flexible format for passing messages between cooperating processes.