prashant-7718 commited on
Commit
edfab9d
·
verified ·
1 Parent(s): 47d8be1

Upload dataset - 2025-09-30T10:05:32.591Z

Browse files

Automated upload of 12 JSONL files containing Mermaid diagram repair data

Files changed (13) hide show
  1. README.md +41 -0
  2. architecture.jsonl +2 -0
  3. block.jsonl +1 -0
  4. class.jsonl +5 -0
  5. er.jsonl +1 -0
  6. flowchart.jsonl +3 -0
  7. journey.jsonl +1 -0
  8. mindmap.jsonl +1 -0
  9. packet.jsonl +1 -0
  10. pie.jsonl +1 -0
  11. requirement.jsonl +1 -0
  12. sankey.jsonl +1 -0
  13. sequence.jsonl +1 -0
README.md ADDED
@@ -0,0 +1,41 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Mermaid Diagram Repair Dataset
2
+
3
+ ## Overview
4
+ This dataset contains failing Mermaid diagrams and their repair data, organized by diagram type.
5
+
6
+ ## Files
7
+ - **architecture.jsonl**: architecture diagram repairs
8
+ - **block.jsonl**: block diagram repairs
9
+ - **class.jsonl**: class diagram repairs
10
+ - **er.jsonl**: er diagram repairs
11
+ - **flowchart.jsonl**: flowchart diagram repairs
12
+ - **journey.jsonl**: journey diagram repairs
13
+ - **mindmap.jsonl**: mindmap diagram repairs
14
+ - **packet.jsonl**: packet diagram repairs
15
+ - **pie.jsonl**: pie diagram repairs
16
+ - **requirement.jsonl**: requirement diagram repairs
17
+ - **sankey.jsonl**: sankey diagram repairs
18
+ - **sequence.jsonl**: sequence diagram repairs
19
+
20
+ ## Format
21
+ Each line in the JSONL files contains:
22
+ ```json
23
+ {
24
+ "task": "REPAIR",
25
+ "input": {
26
+ "diagram": "string - The failing Mermaid diagram code",
27
+ "diagram_type": "string - Type of diagram (flowchart, sequence, etc.)",
28
+ "compiler_errors": ["array of error messages from Mermaid parser"]
29
+ }
30
+ }
31
+ ```
32
+
33
+ ## Usage
34
+ This dataset is designed for training and testing AI models to repair broken Mermaid diagrams.
35
+
36
+ ## Generated
37
+ - **Timestamp**: 2025-09-30T10:05:32.590Z
38
+ - **Total Files**: 12
39
+
40
+ ## License
41
+ Please check with Mermaid Chart for licensing information.
architecture.jsonl ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ {"task":"REPAIR","input":{"diagram":"architecture-beta\n group api(cloud)[API]\n\n service db(database)[Database] in api\n service disk1(disk)[Storage] in api\n service disk2(disk)[Storagei\n service server(servServer] in api\n\n db:L -- R:server\n disk1:T -- B:server\n disk2:T - B:db\n","diagram_type":"architecture","compiler_errors":["Parsing failed: unexpected character: ->[<- at offset: 150, skipped 1 characters.\nunexpected character: ->(<- at offset: 178, skipped 1 characters.\nunexpected character: ->]<- at offset: 189, skipped 1 characters. Expecting: one of these possible Token sequences:\n 1. [NEWLINE]\n 2. [EOF]\nbut found: 'Storagei'\nExpecting token of type ':' but found `\n`.\nExpecting: one of these possible Token sequences:\n 1. [--]\n 2. [-]\nbut found: '\n'\nExpecting token of type 'ID' but found `\n`.\nExpecting: one of these possible Token sequences:\n 1. [NEWLINE]\n 2. [EOF]\nbut found: 'servServer'\nExpecting token of type ':' but found `in`.\nExpecting: one of these possible Token sequences:\n 1. [--]\n 2. [-]\nbut found: 'in'\nExpecting token of type 'ID' but found `in`.\nExpecting token of type 'ARCH_TITLE' but found `B`.\nExpecting token of type 'ID' but found `B`.\nExpecting token of type 'EOF' but found `B`.\nExpecting token of type ':' but found `\n`.\nExpecting: one of these possible Token sequences:\n 1. [--]\n 2. [-]\nbut found: '\n'\nExpecting token of type 'ID' but found `\n`."]}}
2
+ {"task":"REPAIR","input":{"diagram":"architecture-beta\n group api(cloud)[API]\n\n service db(database)[Database] in api\n service disk1(disk)[Storage] in api\n service disk2(disk)[Storage] in api\n service server(server)Server] in api\n\n db:L -- R:server\n disk1:T -- B:server\n disk2:T -- B:db","diagram_type":"architecture","compiler_errors":["Parsing failed: unexpected character: ->]<- at offset: 199, skipped 1 characters. Expecting: one of these possible Token sequences:\n 1. [NEWLINE]\n 2. [EOF]\nbut found: 'Server'\nExpecting token of type ':' but found `in`.\nExpecting: one of these possible Token sequences:\n 1. [--]\n 2. [-]\nbut found: 'in'\nExpecting token of type 'ID' but found `in`."]}}
block.jsonl ADDED
@@ -0,0 +1 @@
 
 
1
+ {"task":"REPAIR","input":{"diagram":"block-beta\n columns 1\n db((\"DB\n blockArrowId6<[\"&nbsp;&nbsp;&nbsp;\"]>(down)\n block:ID\n A\n B[\"A wide one in the middle\"]\n C\n end\n space\n D\n ID --D\n C --> D\n style B fill:#d6dAdding,stroke:#333,stroke-width:4px\n ","diagram_type":"block","compiler_errors":["Lexical error on line 4. Unrecognized text.\n... blockArrowId6<[\"&nbsp;&nbsp;&nbsp;\"]\n-----------------------^"]}}
class.jsonl ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ {"task":"REPAIR","input":{"diagram":"classDiagram\n Animal <|-- Duck\n Animal <|-- Fish\n Animal Zebra\n Animal : +int age\n Animal : +String gender\n Animal: +isMammal()\n Animal: +mate()\n class Duck {\n +String beakColor\n +swim()\n +quack()\n }\n class Fish {\n -int sizeInFeet\n -canEat()\n }\n class Zebra \n +bool is_wild\n +run()\n }","diagram_type":"class","compiler_errors":["Parse error on line 19:\n...ss Zebra +bool is_wild \n----------------------^\nExpecting 'EOF', 'acc_title', 'acc_descr', 'acc_descr_multiline_value', 'NAMESPACE', 'CLASS', 'ANNOTATION_START', 'MEMBER', 'SEPARATOR', 'NOTE_FOR', 'NOTE', 'CLASSDEF', 'ALPHA', 'direction_tb', 'direction_bt', 'direction_rl', 'direction_lr', 'CALLBACK', 'LINK', 'CLICK', 'STYLE', 'CSSCLASS', 'NUM', 'MINUS', 'UNICODE_TEXT', 'BQUOTE_STR', got 'PLUS'"]}}
2
+ {"task":"REPAIR","input":{"diagram":"classDiagram\n Animal <|-- Duck\n Animal <|-- Fish\n Animal <|-- Zebra\n Animal : +int age\n Animal : +String gender\n Animal Mammal()\n","diagram_type":"class","compiler_errors":["Parse error on line 7:\n... Animal Mammal()\n-----------------------^\nExpecting 'STR', 'ALPHA', 'LINE', 'DOTTED_LINE', 'NUM', 'MINUS', 'UNICODE_TEXT', 'BQUOTE_STR', got 'NEWLINE'"]}}
3
+ {"task":"REPAIR","input":{"diagram":"classDiagram\n Animal <|-- Duck\n Animal <|-- Fish\n Animal <|-- Zebra\n Animal : +int age\n Animal : +String gender\n Animal: +isMammal()\n Animal +mate()\n class Duck {\n +String beakColor\n +swim()\n +quack()\n }\n class Fish {\n -int sizeInFeet\n -canEat()\n }\n ","diagram_type":"class","compiler_errors":["Parse error on line 8:\n...al() Animal +mate() clas\n----------------------^\nExpecting 'NEWLINE', 'EOF', 'SQS', 'STR', 'DOT', 'GENERICTYPE', 'LABEL', 'STRUCT_START', 'STRUCT_STOP', 'STYLE_SEPARATOR', 'ANNOTATION_END', 'ALPHA', 'AGGREGATION', 'EXTENSION', 'COMPOSITION', 'DEPENDENCY', 'LOLLIPOP', 'LINE', 'DOTTED_LINE', 'CALLBACK_NAME', 'HREF', 'NUM', 'MINUS', 'UNICODE_TEXT', 'BQUOTE_STR', got 'PLUS'"]}}
4
+ {"task":"REPAIR","input":{"diagram":"\n Animal <|-- Duck\n Animal <|-- Fish\n Animal <|-- Zebra\n Animal : +int age\n Animal : +String gender\n Animal : +isMammal()\n Animal : +mate()\n class Duck {\n +String beakColor\n +swim()\n +quack()\n }\n class Fish {\n -int sizeInFeet\n -canEat()\n }\n","diagram_type":"class","compiler_errors":["No diagram type detected matching given configuration for text: Animal <|-- Duck\n Animal <|-- Fish\n Animal <|-- Zebra\n Animal : +int age\n Animal : +String gender\n Animal : +isMammal()\n Animal : +mate()\n class Duck {\n +String beakColor\n +swim()\n +quack()\n }\n class Fish {\n -int sizeInFeet\n -canEat()\n }\n"]}}
5
+ {"task":"REPAIR","input":{"diagram":"classDdfsdfsdiagram\n Animal <|-- Duck\n Animal <|-- Fish\n Animal <|-- Zebra\n Animal : +int age\n Animal : +String gender\n Animal : +isMammal()\n Animal : +mate()\n class Duck {\n +String beakColor\n +swim()\n +quack()\n }\n class Fish {\n -int sizeInFeet\n -canEat()\n }\n","diagram_type":"class","compiler_errors":["No diagram type detected matching given configuration for text: classDdfsdfsdiagram\n Animal <|-- Duck\n Animal <|-- Fish\n Animal <|-- Zebra\n Animal : +int age\n Animal : +String gender\n Animal : +isMammal()\n Animal : +mate()\n class Duck {\n +String beakColor\n +swim()\n +quack()\n }\n class Fish {\n -int sizeInFeet\n -canEat()\n }\n"]}}
er.jsonl ADDED
@@ -0,0 +1 @@
 
 
1
+ {"task":"REPAIR","input":{"diagram":"erDiagram\n CUSTOMER }|..|{ DELIVERY-ADDRESS : has\n CUSTOMER ||--o{ ORDER : places\n CUSTOMER ||--o{ INVOICE : \"liable for\"\n DELIVERY-ADDRESS ||--o{ ORDER : receives\n INVOICE ||--|{ ORDER : covers\n ORDER ||--|{ ORDER-ITEM : includes\n PRODUCT-CATEGORY ||--|{ PRODUCT : contains\n PRODUCT ||- -o{ ORDER-ITEM : \"ordered in\"","diagram_type":"er","compiler_errors":["Parse error on line 9:\n...tains PRODUCT ||- -o{ ORDER-ITEM : \n----------------------^\nExpecting 'NON_IDENTIFYING', 'IDENTIFYING', got 'UNICODE_TEXT'"]}}
flowchart.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ {"task":"REPAIR","input":{"diagram":"---\nconfig:\n theme: redux\n---\nflowchart TD\n A([\"Start\"])\n A --> B{\"Decision\"}\n B --> C[\"Option A\"]\n B --> D[\"Option B\"\n","diagram_type":"flowchart","compiler_errors":["Parse error on line 7:\n...B --> D[\"Option B\"\n---------------------^\nExpecting 'SQE', 'DOUBLECIRCLEEND', 'PE', '-)', 'STADIUMEND', 'SUBROUTINEEND', 'PIPE', 'CYLINDEREND', 'DIAMOND_STOP', 'TAGEND', 'TRAPEND', 'INVTRAPEND', 'UNICODE_TEXT', 'TEXT', 'TAGSTART', got '1'"]}}
2
+ {"task":"REPAIR","input":{"diagram":"---\nconfig:\n theme: redux\n---\nflowchart TD\n A([\"Start\"])\n A --> B{\"Decision\"}\n B --> C[\"Option A\"\n B --> D[\"Option B\"]\n","diagram_type":"flowchart","compiler_errors":["Parse error on line 5:\n...n A\" B --> D[\"Option B\"]\n----------------------^\nExpecting 'SQE', 'DOUBLECIRCLEEND', 'PE', '-)', 'STADIUMEND', 'SUBROUTINEEND', 'PIPE', 'CYLINDEREND', 'DIAMOND_STOP', 'TAGEND', 'TRAPEND', 'INVTRAPEND', 'UNICODE_TEXT', 'TEXT', 'TAGSTART', got 'SQS'"]}}
3
+ {"task":"REPAIR","input":{"diagram":"---\nconfig:\n theme: redux\n---\nflowchart TD\n A([\"Start\"])\n A --> B{\"Decision\"}\n B --> C[\"Option A\"]\n B --> D[\"Option B\"\n","diagram_type":"flowchart","compiler_errors":["Parse error on line 7:\n...B --> D[\"Option B\"\n---------------------^\nExpecting 'SQE', 'DOUBLECIRCLEEND', 'PE', '-)', 'STADIUMEND', 'SUBROUTINEEND', 'PIPE', 'CYLINDEREND', 'DIAMOND_STOP', 'TAGEND', 'TRAPEND', 'INVTRAPEND', 'UNICODE_TEXT', 'TEXT', 'TAGSTART', got '1'"]}}
journey.jsonl ADDED
@@ -0,0 +1 @@
 
 
1
+ {"task":"REPAIR","input":{"diagram":"journey\ntitle My working day\nsection Go to work\n Make tea: 5: Me\n Go upstairs: 3: Me\n Do work: 1: Me, Cat\nsection Go home n: 5 Me\n","diagram_type":"journey","compiler_errors":["Parse error on line 7:\n...atsection Go home n: 5 Me\n----------------------^\nExpecting 'EOF', 'SPACE', 'NEWLINE', 'title', 'acc_title', 'acc_descr', 'acc_descr_multiline_value', 'section', 'taskName', got 'taskData'"]}}
mindmap.jsonl ADDED
@@ -0,0 +1 @@
 
 
1
+ {"task":"REPAIR","input":{"diagram":"mindmap\n root((mindmap\n Origins\n Long history\n ::icon(fa fa-book)\n Popularization\n British popular psychology author Tony Buzan\n Research\n On effectiveness<br/>and features\n On Automatic creation\n Uses\n Creative techniques\n Strategic planning\n Argument mapping\n Tools\n Pen and paper\n Mermaid","diagram_type":"mindmap","compiler_errors":["Parse error on line 5:\n...istory ::icon(fa fa-book) Po\n----------------------^\nExpecting 'SPACELINE', 'NL', 'EOF', got 'NODE_ID'"]}}
packet.jsonl ADDED
@@ -0,0 +1 @@
 
 
1
+ {"task":"REPAIR","input":{"diagram":"packet-beta\ntitle: UDP Packet\n0-15: \"Source Port\"\n16-31: \"Destination Port\"\n32-47: \"Length\"\n48-63: \"Checksum\"\n64-95: \"Data (variable length)\"","diagram_type":"packet","compiler_errors":["Parsing failed: unexpected character: ->U<- at offset: 19, skipped 3 characters.\nunexpected character: ->P<- at offset: 23, skipped 6 characters. Expecting: one of these possible Token sequences:\n 1. [NEWLINE]\n 2. [EOF]\nbut found: ':'\nExpecting token of type 'EOF' but found `:`."]}}
pie.jsonl ADDED
@@ -0,0 +1 @@
 
 
1
+ {"task":"REPAIR","input":{"diagram":"pie title Pets adopted by volunteers\n\"Dogs\" : 386\n\"Cats\" : 85\n\"Rats\" ","diagram_type":"pie","compiler_errors":["Parsing failed: Expecting token of type ':' but found `\n`."]}}
requirement.jsonl ADDED
@@ -0,0 +1 @@
 
 
1
+ {"task":"REPAIR","input":{"diagram":"requirementDiagram\nrequirement test_req {\nid: 1\ntext: the test text.\nrisk: high\nverifyMethod: test\n}\nelement test_entity {\ntype simulation\n}\ntest_entity - satisfies -> test_req","diagram_type":"requirement","compiler_errors":["Parse error on line 9:\n...test_entity {type simulation}test_en\n----------------------^\nExpecting 'COLONSEP', got 'unqString'"]}}
sankey.jsonl ADDED
@@ -0,0 +1 @@
 
 
1
+ {"task":"REPAIR","input":{"diagram":"sankey-beta\nNet Primary production %,Consumed energy %,85\nNet Primary production %,Detritus %,15\nConsumed energy %,Egested energy %,20%\nConsumed energy %,Assimilated Energy %,65\nAssimilated Energy %, Energy for Growth %, 25\nAssimilated Energy %, Respired energy %, 40\nDetritus %, Consumed by microbes %, 10\nDetritus %, Stored in the earth ","diagram_type":"sankey","compiler_errors":["Parse error on line 9:\n... Stored in the earth\n-----------------------^\nExpecting 'COMMA', got 'EOF'"]}}
sequence.jsonl ADDED
@@ -0,0 +1 @@
 
 
1
+ {"task":"REPAIR","input":{"diagram":"sequenceDiagram\n actor Alice\n actor Bob\n Alice --> Bob: Hi Bob\n Bob --> Alice Hi Alice\n","diagram_type":"sequence","compiler_errors":["Parse error on line 5:\n...b --> Alice Hi Alice\n-----------------------^\nExpecting 'TXT', got 'NEWLINE'"]}}