Docs / Command Reference

Invocation

After installing the package (pip install . or via Nix), the CLI is on PATH as the opentest console script:

opentest <command> [options]
python -m opentestability <command> [options]   # equivalent module form

From a raw checkout (no install), the repo-root dev shim works too:

python3 opentest <command> [options]

Use help for command-specific details:

opentest help

If you installed via Nix, the equivalent entry point is:

nix run github:ranaumarnadeem/OpenTestability -- <command> [options]

(or just opentest <command> [options] after nix profile install.)

OpenTestability ingests Yosys JSON netlists. (A leading --yosys flag is accepted and ignored for backward compatibility.)

Commands

Command Purpose
cop COP probabilistic metrics on a Yosys JSON netlist
scoap SCOAP metrics on a Yosys JSON netlist
analyze_and_add_tp End-to-end analysis plus test-point insertion
status Show current project status
help Show help text

Options

Option Meaning
--tech PDK / technology library: sky130 (default), osu035, ihp, nangate, auto
-r, --reconvergence Enable reconvergence analysis alongside metrics
-a, --algorithm Reconvergence algorithm: basic, simple, advanced, dominator
--scoap Use SCOAP metrics (one of --scoap/--cop is required for analyze_and_add_tp; neither is a default)
--cop Use COP metrics
-i, --input Input Yosys JSON netlist
-o, --output Output file name
-v, --verbose Detailed logs and reports
-j, --json Write JSON output where supported
-t, --threshold TPI threshold
-m, --max-points Max test points to insert (default 10; no cap when only --area-budget is given)
--dont-touch Net glob to leave alone, repeatable; cell:<glob> matches cell instances
--dont-touch-file File of --dont-touch patterns, one per line (# starts a comment)
--area-budget Max total test point cell area, in the PDK’s Liberty area units
--obs-share XOR up to N observation points onto each output port (default 1, no sharing)
--tpi-algorithm TPI candidate-selection algorithm (default: heuristic; see --list-algorithms)
--list-algorithms List the registered TPI selection algorithms and exit
--output-root Directory to write run outputs under (default: repo root in a dev checkout, cwd when installed)

The --tpi-algorithm selector is pluggable: third-party packages can register their own algorithm under the opentestability.tpi_algorithms entry-point group and it becomes selectable by name. --list-algorithms shows what is registered.

For the ATPG-guided closed-loop flags (--atpg-loop, --oracle, --oracle-cmd, --coverage-target, --max-iterations, --oracle-dir) see the ATPG coverage oracle guide.

Quick recipes

SCOAP plus TPI:

python3 opentest scoap -i <design.json> -j
python3 opentest analyze_and_add_tp -i <design.json> --scoap -t 50 -m 10

With technology selection:

python3 opentest analyze_and_add_tp -i <design.json> --scoap -t 50 -m 10 --tech sky130
python3 opentest analyze_and_add_tp -i <design.json> --scoap -t 50 -m 10 --tech osu035

Leaving a clock tree and an IP block alone, within an area budget, sharing observation outputs four to a port:

python3 opentest analyze_and_add_tp -i <design.json> --scoap -t 50     --dont-touch 'clk*' --dont-touch 'cell:u_ip.*' --area-budget 200 --obs-share 4

See Test Point Insertion for how each constraint behaves.

With reconvergence-aware analysis:

python3 opentest analyze_and_add_tp -i <design.json> --scoap -r -t 50 -m 10 --tech sky130

FaultFlow integration

OpenTestability exposes a machine interface for FaultFlow to obtain reconvergence structural data (fanout signals with Yosys net IDs and enriched reconvergence records) before ATPG, without inserting test points. The interface writes tpi_manifest.json with net-ID-enriched structural_hints that FaultFlow reads for fault ordering.

See docs/faultflow_preflight_protocol.md for the full contract, field schema, and invocation example.