create-scenic-scenario

Generates and validates Scenic scenario files from natural-language descriptions for CARLA simulation.

3|Updated Jul 20, 2026
One-click install
npx skills add https://github.com/carla-simulator/carla-agentic-tools --skill create-scenic-scenario-carla-simulator
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: create-scenic-scenario
Source: https://github.com/carla-simulator/carla-agentic-tools/tree/main/skills/scenic/create-scenic-scenario
Command: npx skills add https://github.com/carla-simulator/carla-agentic-tools --skill create-scenic-scenario-carla-simulator

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires scenic, carla, shapely, trimesh, scipy, numpy, pygame, and includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve? Writing Scenic scenarios by hand is error-prone: illegal asserts on random values, missing containment waivers for pedestrians, mismatched map parameters, and blueprint ids that do not exist in the build all cause failures that surface late and read like scenario bugs. This Skill turns a natural-language traffic description into a spec, generates a .scenic file from idioms proven on the local build, and validates it by compiling and sampling before any simulator is involved. ## Core Features & Use Cases - Spec-driven generation: scaffold_scenic.py converts a JSON spec (map, placement, ego, actors, relations) into a complete .scenic file using proven placement idioms like lane-section neighbour selection and conflicting-maneuver geometry. - Compile-and-sample validation: every generated file is compiled and sampled automatically, with verdicts (COMPILE-FAIL, SAMPLE-FAIL, PASS) mapped to concrete fixes. - Blueprint verification: blueprint_table.py diffs the CARLA build's content JSONs against Scenic's version-keyed table so scenarios only reference spawnable ids. - Use Case: Ask for "a pedestrian steps into the road ahead of the ego" and receive a validated .scenic file using CrossingBehavior with regionContainedIn waived, ready to simulate with the run-scenic-scenario skill. ## Quick Start Ask the agent to write a Scenic scenario where a car cuts in from the right lane on Town05 and validate that it compiles and samples.

Frequently Asked Questions about create-scenic-scenario

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a Scenic scenario from a text description?▼

Describe the situation in natural language, then the skill builds a JSON spec (map, placement, ego, actors with relations like ahead or right_lane) and runs scaffold_scenic.py to emit the .scenic file. Generation automatically validates by compiling and sampling the scenario.

How do I check which vehicle blueprints exist in my CARLA build?▼

Run blueprint_table.py to diff the build's Content/Carla/Config JSONs against Scenic's version-keyed table. Use --check with specific ids to verify spawnability, or --category to list what Scenic offers for a type like bicycle.

Does creating a Scenic scenario require a running CARLA server?▼

No. Generating and validating a scenario only needs Scenic installed, since validation compiles and samples the scenario locally. A running simulator is only required later when simulating the scenario with the run-scenic-scenario skill.

Why does my Scenic scenario fail with RandomControlFlowError?▼

RandomControlFlowError occurs when control flow, such as assert len(x) > 0, depends on a value derived from Uniform(). Scenic evaluates scenarios symbolically, so asserts are only allowed on deterministic lists built from network attributes.

Why does sampling never converge for pedestrian scenarios?▼

Pedestrians and props placed on the road fail the default containment region check on every sample. Adding 'with regionContainedIn None' to the placement waives containment so generation converges.

What are the limitations of generated Scenic scenarios for CARLA?▼

Scenarios are written for 2D mode only, since the CARLA model does not define 3D meshes. Scenario composition across files is unsupported, and traffic-light state control is limited to what the CARLA model exposes.