JSON file

JavaScript Object Notation (JSON) is a standard data interchange format. This lightweight and readable format is used for data transfer between servers and web applications, and for storing structured data in a programming environment.

In BrainSoup, JSON is used in particular to set up Custom Contexts and Custom Events. JSON was chosen as the main data format in BrainSoup because it is well interpreted by large language models (LLMs) and can be easily generated by almost all scripting and programming languages. Furthermore, it also enables BrainSoup to directly use output data from a Web API in JSON form.

JSON syntax includes objects using curly braces {} , arrays using square brackets [] , and key-value pairs where values can be numbers, strings, other objects or arrays, booleans, or null.

Here's an example JSON showing these features and types:

{

"firstName":"John",

"age":30,

"hobbies":[

"reading",

"traveling",

{

"nestedHobby":{

"name":"coding",

"language":["python", "javascript"]

}

}

],

"isMarried":true,

"children":null

}

This JSON example demonstrates key JSON features, including nested structures and recursion.