AI Blocks › Build and ship software
Driving test scenario writer
Describe the traffic event. Get a RoadRunner scenario with actors, routes and triggers, built in code.
Driving test scenario writer is a free AI skill for the job "Build and ship software". Give the instructions to an AI assistant that supports the required files and tools, then review its output.
Free · No account · BSD 2 Clause licence · Made by MathWorks · Level: advanced
Made by MathWorks. See the original on GitHub; we copied it as it is, with its licence.
What it does
Describe a traffic event in words and get a RoadRunner scenario written as code. A car cuts in, a pedestrian crosses, a lead vehicle brakes hard. Each one becomes actors, routes and trigger logic you can run and change. The skill works through the roadrunnerAPI in MATLAB. It first confirms a RoadRunner session is open. Then it adds vehicles and pedestrians, sets their routes and waypoints, and places them on roads by anchor or map position. Next it writes the scenario logic as phases, conditions and actions. Last, it checks the structure before you simulate. Scenes, road shapes and simulation runs are handled by other skills.
You give it
- A plain description of the traffic event
- The road or scene to use
- Actor types and speeds (optional)
- Trigger conditions (optional)
You get
- MATLAB code that builds the scenario
- Actors with routes and waypoints
- Phase logic with conditions and actions
- A structure check before simulation
Use it when
- You need a cut-in or lead-brake test for an automated driving system.
- You want a pedestrian crossing set up without clicking through the editor.
- You plan many variations of one traffic event.
- You want the scenario checked before you simulate.
How to use it
- Add it to your AI once: download it and add the folder to Claude, ChatGPT or Codex as a skill.
- Ask for the job in your own words. Your AI opens the skill when it fits.
- It works best when your AI can run MATLAB with RoadRunner.