Dataset Viewer
Auto-converted to Parquet Duplicate
messages
listlengths
1
1
ground_truth
listlengths
12
23
dataset
stringclasses
1 value
difficulty
stringclasses
2 values
id
stringlengths
36
36
problem_family
stringclasses
1 value
name
stringlengths
19
27
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(YR)*' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YRYR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YRYRYR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RGBYRGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBRRYRRY" } ]
manufactoria
easy
043931b9-c6b5-44a4-ac0d-55de9660a472
regex_pattern
Regex Pattern: (YR)*
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(GG)+(YRB)*' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGGGGGYRBYRBYRB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGGGYRBYRB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGYRBYRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRBGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGYYRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRYGYRY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRYYRYRY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBYRBR" } ]
manufactoria
medium
6fa01b17-88ee-4832-a94e-f535c2054604
regex_pattern
Regex Pattern: (GG)+(YRB)*
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(YRR)?(GRG)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GRG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GRGGRG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YRRGRGGRGGRGGRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GRGYRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRRRGRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRRYRBRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGBGRYGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BYRBYYBB" } ]
manufactoria
medium
e2efe231-4f76-41d6-bb3a-b7681f5e6dd9
regex_pattern
Regex Pattern: (YRR)?(GRG)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(YGR)+(GGB)?' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGRGGB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGRYGR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGRYGRYGRYGRGGB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGBYGR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGRYGGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BGBYGBGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRBGGRRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GRBGGBGB" } ]
manufactoria
medium
0e258680-9765-4389-b588-595765f597d0
regex_pattern
Regex Pattern: (YGR)+(GGB)?
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(BG)?(GGG)*' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "G" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BGGGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BGGGGGGGGGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGGGGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGGBG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BGBGGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GYBBGYB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRBGGYRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBYGGG" } ]
manufactoria
medium
d7a3dce9-296a-4fc7-bd6b-85b69630d7a1
regex_pattern
Regex Pattern: (BG)?(GGG)*
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(BY)?' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "G" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYYBYYY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GRRYY" } ]
manufactoria
easy
3f616741-8dec-415c-8e7e-ceb559c72125
regex_pattern
Regex Pattern: (BY)?
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(Y)?' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRGYRRYB" } ]
manufactoria
easy
4d50ce3c-d650-4e69-889f-a1f14784a32b
regex_pattern
Regex Pattern: (Y)?
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(RRY)?(RG)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRYRG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRYRGRGRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RGRRY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRYRRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GYRRRGYR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RYBRRYB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBYGRYRG" } ]
manufactoria
medium
f7d0ddbd-d709-45bb-a1cc-9e09511a5109
regex_pattern
Regex Pattern: (RRY)?(RG)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(YBB)+(YY)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "G" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YBBYY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YBBYYYY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YBBYBBYBBYBBYYYYYY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYYBB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBBRYY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRGYBYRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBGYYBG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBBBYGRB" } ]
manufactoria
medium
7c5c0e7d-598d-4904-bb43-ad98103e0a83
regex_pattern
Regex Pattern: (YBB)+(YY)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(YGR)?(YRR)*' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGRYRR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YRR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGRYRRYRRYRR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YRRYRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRRYGR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGRBYRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGYYGGGY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRBYRYRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RYYRBR" } ]
manufactoria
medium
aa0e65f2-0284-4756-9043-97aa059b0be3
regex_pattern
Regex Pattern: (YGR)?(YRR)*
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(BG)?' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRBBRRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BGBYY" } ]
manufactoria
easy
ea330d9f-1578-4de5-81d1-c8e15f5304b3
regex_pattern
Regex Pattern: (BG)?
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(GRG)?(RGG)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "G" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GRGRGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RGGRGGRGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GRGRGGRGGRGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RGGGRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GRGYRGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBBGRBBB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GRGRGGRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BYGRY" } ]
manufactoria
medium
8bbc28df-fafa-4649-9cb1-a3088908ccf8
regex_pattern
Regex Pattern: (GRG)?(RGG)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(YGB)+(YRG)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGBYRG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGBYGBYRGYRGYRG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGBYGBYGBYGBYRGYRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRGYGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGBRYRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBRYGBBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBRYRYBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRBGGGBR" } ]
manufactoria
medium
208f754c-933b-4924-bd18-72d4fff673f3
regex_pattern
Regex Pattern: (YGB)+(YRG)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(GBR)*(GBG)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "B" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GBRGBRGBG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GBRGBRGBRGBRGBGGBGGBGGBG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBRGBR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GBG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBGGBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBRGGBG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRGGBBRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBRGBRBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GYBGRR" } ]
manufactoria
medium
5444500c-8c20-4b73-91fb-79dd3ca76c84
regex_pattern
Regex Pattern: (GBR)*(GBG)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(BGY)?(BBG)*' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BGYBBGBBGBBG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BGYBBGBBG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBGBBG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBGBGY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BGYRBBG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRRBGYRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRRBBBRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RGYRG" } ]
manufactoria
medium
608ef7f7-b380-40aa-a561-172ecc0aaf31
regex_pattern
Regex Pattern: (BGY)?(BBG)*
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(BBR)+(YYG)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBRYYG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBRBBRBBRYYGYYG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBRBBRBBRBBRYYGYYGYYGYYG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYGBBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBRBYYG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRRBBRRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBRYYRBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBRGGRY" } ]
manufactoria
medium
f8347611-9481-4359-9330-6cba9752dee2
regex_pattern
Regex Pattern: (BBR)+(YYG)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(RRG)+(BBB)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRGBBB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRGRRGBBBBBBBBB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBBRRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRGRBBB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRGRRRRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RYBBBRYB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BGYRBYB" } ]
manufactoria
medium
81f967bd-37fa-44d5-a969-c0f224d3d833
regex_pattern
Regex Pattern: (RRG)+(BBB)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(RRG)?(YGY)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRGYGY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRGYGYYGYYGY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGYRRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRGYYGY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBGRRGBG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBRYGGBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYYGRGYY" } ]
manufactoria
medium
699788b2-1b21-4dd3-a300-4b705183b97d
regex_pattern
Regex Pattern: (RRG)?(YGY)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(RRB)*(RGG)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRBRGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRBRRBRGGRGGRGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRBRRBRRBRRBRGGRGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRBRRB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RGGRRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRBBRGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RYGRRRYG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RYYRGRYY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RYYRGBYY" } ]
manufactoria
medium
d1bac678-fb71-4fdc-8eba-497b4584deea
regex_pattern
Regex Pattern: (RRB)*(RGG)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(GRR)*(YBY)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GRRGRRYBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GRRGRRGRRYBYYBYYBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GRRGRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBYGRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GRRYYBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRBGRRRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BYBYBBYB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GYBYYGGG" } ]
manufactoria
medium
39f64f78-be34-4c91-b6ce-6bad99ce1d20
regex_pattern
Regex Pattern: (GRR)*(YBY)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(BR)+(YGB)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "G" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BRYGB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BRBRBRBRYGBYGBYGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGBBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRYYGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBRBBBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRRYGRRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBBYRYRB" } ]
manufactoria
medium
09537cf8-77a1-4205-b829-673e5f65b28d
regex_pattern
Regex Pattern: (BR)+(YGB)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(GGY)*(BR)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "B" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGYGGYBRBRBR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGYGGYGGYGGYBRBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGYGGY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRGGY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGYGBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGRGGYGR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYYBYYY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RGYRR" } ]
manufactoria
medium
a429e0e4-ede1-4813-8961-58b6dc61f8ed
regex_pattern
Regex Pattern: (GGY)*(BR)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(YRB)+(YGG)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YRBYGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YRBYGGYGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YRBYRBYRBYGGYGGYGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGGYRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRBBYGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GYRYRGYR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RYYYGRYY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRGGYRB" } ]
manufactoria
medium
551d4a41-56d8-44c1-a7bb-f08c032d87c0
regex_pattern
Regex Pattern: (YRB)+(YGG)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(YGB)?(YBY)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "G" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGBYBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YGBYBYYBYYBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBYYGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGBYYBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GYBYGGYB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGGYBGGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BGYRBYBG" } ]
manufactoria
medium
1cb73f2e-5b7a-4e13-9840-65697979bfef
regex_pattern
Regex Pattern: (YGB)?(YBY)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(RRB)+(RBY)*' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRBRBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRBRBYRBYRBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRBRRBRRBRBYRBYRBYRBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRBRBYRBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBYRRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRBRRBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RYBRRRYB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BYYRBBYY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBBRRYY" } ]
manufactoria
medium
5a39d8c1-61e0-40d0-9151-f18d348fa6b0
regex_pattern
Regex Pattern: (RRB)+(RBY)*
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(BRY)?(YG)?' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BRYYG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGBRY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRYRYG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRGBRBRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRBYRRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYGGYR" } ]
manufactoria
medium
853e3e30-7bd3-4895-a913-bf30ffe5bd71
regex_pattern
Regex Pattern: (BRY)?(YG)?
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(YBY)+(BY)*' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YBYBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YBYYBYBYBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YBYYBYYBYBYBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YBY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YBYBYBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BYYBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YBYRBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RGGYBRGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRRBRRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYYGY" } ]
manufactoria
medium
187cb2d2-3981-46a8-bc7a-786019ccaacb
regex_pattern
Regex Pattern: (YBY)+(BY)*
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(GG)*(YRG)?' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGYRG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGGGYRG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "YRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRGGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGBYRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YGYGYGY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGBYRGGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYBBYRYB" } ]
manufactoria
medium
e18163f5-eddb-4de4-8221-ef043b934ecb
regex_pattern
Regex Pattern: (GG)*(YRG)?
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(GGB)?(RGG)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGBRGGRGG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "GGBRGGRGGRGGRGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RGGGGB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GGBBRGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBYGGGBY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBRRGGBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GBYBGB" } ]
manufactoria
medium
2fc3c433-ccf3-4431-923c-1fbd5300f5f7
regex_pattern
Regex Pattern: (GGB)?(RGG)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(BBR)*(BBB)+' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBRBBB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBRBBRBBBBBBBBB" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBRBBRBBRBBBBBB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBRBBR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBBBBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBRRBBB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRRBBYRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BGGBBBGG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRBBRGYR" } ]
manufactoria
medium
9f6d72d3-966a-4930-b4bc-9c740c80750b
regex_pattern
Regex Pattern: (BBR)*(BBB)+
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(BBG)+(BRG)*' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "B" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBGBRGBRG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBGBBGBRGBRG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBGBBGBBGBRGBRGBRG" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "BBG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRGBBG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBGYBRG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BYRBBBYR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBBBRRBB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BYBGB" } ]
manufactoria
medium
633bb3fc-b7b3-4b11-b243-3074d2f38db2
regex_pattern
Regex Pattern: (BBG)+(BRG)*
[ { "content": "# Manufactoria Solution DSL\n\nA Domain Specific Language for describing Manufactoria puzzle solutions in text format.\n\n## Overview\n\nManufactoria is a puzzle game where you build automated factories to sort robots based on their colored tape patterns. Robots enter your factory carrying sequences of colored tape, and you must route them to the correct destinations based on the given criteria.\n\n## Game Mechanics\n\n### Robots and Tape\n- **Robots**: Each robot carries a sequence of colored tapes\n- **Tape Colors**: Primary colors are Blue (B) and Red (R), with additional Yellow (Y) and Green (G) for advanced puzzles\n- **Tape Representation**: Sequences are represented as strings (e.g., `RBRR`, `BBR`, or empty string `\"\"`)\n\n### Operations\n- **Pull**: Remove tape from the front of the robot's sequence\n- **Paint**: Add colored tape to the end of the robot's sequence\n- **Route**: Direct robots through the factory based on their current tape state\n\n### Objective\nRoute robots to the correct destinations based on their final tape configuration and the puzzle requirements:\n- **Accepted**: Robot reaches the END node\n- **Rejected**: Robot is not routed to the END node or caught in an infinite loop. \n\n## DSL Syntax\n\n### Program Structure\n\nEvery solution must start with a `START` directive and end with an `END` directive, wrapped in ```manufactoria ...```:\n\n```manufactoria\nSTART start:\n NEXT <next_node_id>\n\n# Factory logic goes here\n\nEND end\n```\n\n### Node Types\n\n#### 1. Puller Nodes\n\nPullers remove specific colors from the front of the robot's tape sequence and route based on the current front color.\n\n**Red/Blue Puller:**\n\n```manufactoria\nPULLER_RB <node_id>:\n [R] <next_node_id> # Route and remove color if front tape is Red\n [B] <next_node_id> # Route and remove color if front tape is Blue\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither red nor blue\n```\n\n**Yellow/Green Puller:**\n\n```manufactoria\nPULLER_YG <node_id>:\n [Y] <next_node_id> # Route and remove color if front tape is Yellow\n [G] <next_node_id> # Route and remove color if front tape is Green\n [EMPTY] <next_node_id> # Route if no tape or front tape is neither yellow nor green\n```\n\n**Note**: Unspecified branches default to `NONE`, which rejects the robot.\n\n#### 2. Painter Nodes\n\nPainters add colored tape to the end of the robot's sequence and continue to the next node.\n\n```manufactoria\nPAINTER_RED <node_id>:\n NEXT <next_node_id>\n\nPAINTER_BLUE <node_id>:\n NEXT <next_node_id>\n\nPAINTER_YELLOW <node_id>:\n NEXT <next_node_id>\n\nPAINTER_GREEN <node_id>:\n NEXT <next_node_id>\n```\n\n## Syntax Rules\n\n1. **Node IDs**: Must be unique identifiers (alphanumeric characters and underscores only)\n2. **Comments**: Lines starting with `#` are comments (single-line only)\n3. **Indentation**: Use consistent spaces or tabs for route definitions\n4. **Case Sensitivity**: Colors must be uppercase (R, B, Y, G)\n5. **Termination**: \n - Robots routed to `NONE` are rejected\n - Robots routed to the END node are accepted\n6. **Code Blocks**: Final factory code should be wrapped in triple backticks with ``` markers\n\n## Example\n\nHere's a simple example that accepts robots with exactly one red tape (ending tape should be empty):\n\n```manufactoria\nSTART start:\n NEXT entry\n\nPULLER_RB entry:\n [R] end\n\nEND end\n```\n\n# Task \nYour task is to design a factory with code with following functionality:\n\nAccept if the tape matches the regex pattern '(RRR)+(RY)*' exactly; reject otherwise. '+' means one or more repetitions, '?' means zero or one occurrence, '*' means zero or more repetitions.", "role": "user" } ]
[ { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "R" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "Y" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BG" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RBR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "GB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "BR" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRRRYRY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRRRY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRRRRRRRRRYRYRYRY" }, { "check_output": false, "description": "", "expected_accepted": true, "expected_output": "", "input": "RRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RYRRR" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "RRRYRY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYYRRYYY" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YRBRYRB" }, { "check_output": false, "description": "", "expected_accepted": false, "expected_output": "", "input": "YYYBRGRG" } ]
manufactoria
medium
ae9ad67e-5395-49dd-862c-94675d7cada9
regex_pattern
Regex Pattern: (RRR)+(RY)*
End of preview. Expand in Data Studio
README.md exists but content is empty.
Downloads last month
22