Simulation Setup

SkillFiles & storage

Set up Virtuoso simulation with Ocean SKILL. Use when configuring simulator, design target, model files, or design variables before running simulation.

Available today. Use it from your connected AI after setup.

Connect ahel once, and every AI you use reads what you have installed.

Then ask your AI: use the Simulation Setup skill

What this skill tells your AI

The instructions your AI receives, as published by deanyou/virtuoso-cli in .agents/skills/sim-setup/SKILL.md and read by ahel’s review.

Configure Ocean environment for circuit simulation via virtuoso-cli.

Steps

1. Set simulator and design

virtuoso sim setup --lib <LIB> --cell <CELL> --view <VIEW> --format json

View defaults to schematic. Check available views first if setup returns nil:

virtuoso skill exec 'let((cell) cell=ddGetObj("LIB" "CELL") foreach(mapcar v cell~>views v~>name))' --format json

2. Set model files (if not already configured in ADE)

virtuoso skill exec 'modelFile(list("/path/to/models.lib" "tt") list("/path/to/models.lib" "res_tt"))' --format json

Critical: Do NOT include entries with empty section names "" for .lib files — spectre will fail with SFE-675. Only .ckt files can have empty sections.

3. Set design variables

virtuoso skill exec 'desVar("L" 130e-9)' --format json
virtuoso skill exec 'desVar("VGS" 0.6)' --format json

Check required variables by looking at spectre.out errors — they list undefined parameters.

4. Set results directory

virtuoso skill exec 'resultsDir("/tmp/my_sim_results")' --format json

Critical workflow

The correct order for a fresh simulation is:

# 1. Setup simulator and design
virtuoso sim setup --lib LIB --cell CELL

# 2. Set resultsDir BEFORE anything else
virtuoso skill exec 'resultsDir("/tmp/my_sim")' --format json

# 3. Set modelFile with CORRECT absolute paths (verify files exist!)
virtuoso skill exec 'modelFile(list("/path/to/model.lib" "tt") list("/path/to/model.lib" "res_tt"))' --format json

# 4. Set design variables
virtuoso skill exec 'desVar("L" 130e-9)' --format json

# 5. Run
virtuoso sim run --analysis dc --param saveOppoint=t --timeout 120

# 6. Measure
virtuoso sim measure --analysis dcOp --expr 'value(getData("/NM0:gm" ?result "dcOpInfo"))'

Known issues

  • simulator('spectre) resets modelFile — always re-set modelFile after sim setup
  • Ocean functions don't work inside let blocks — call simulator(), design(), analysis(), run() at top level
  • Ocean state persists across CLI calls — no need to re-setup between runs, but modelFile must be set each session
  • design() returns nil: the cell may not have the view you specified — check with v~>name
  • run() takes <0.3s and no spectre.out: modelFile not set or paths wrong — spectre silently fails
  • run() takes >1s with spectre.out: real execution happened — check spectre.out for errors
  • Netlisting error OSSHNL-116: a subcell has no spectre/schematic view (e.g., notes cell)
  • Model path errors: verify paths exist on disk — PDK symlinks can break (use direct path, not through oa/)

Signals

GitHub stars
32
Forks
10
Last commit
Sep 2026
Advanced
Catalog kind
skill
Gateway key
sim-setup
Source
github.com/deanyou/virtuoso-cli