Goal
This page gives developers the minimum architecture map needed to extend OpenTestability safely.
Current core packages
src/opentestability/core/
├── cop/ # Probability-based controllability/observability
├── scoap/ # Classical CC0/CC1/CO metrics
├── dag/ # DAG build/save helpers
├── reconvergence/ # basic/simple/advanced + integration
└── testpoint/ # TPI orchestrator and insertion pipeline
Main extension points
- Add a gate model:
- COP:
core/cop/gate_logic.py - SCOAP:
core/scoap/gate_logic.py
- COP:
- Add or tune reconvergence behavior:
core/reconvergence/basic.pycore/reconvergence/simple.pycore/reconvergence/advanced.py
- Extend TPI flow:
- ranking:
core/testpoint/analyzer.py - selection/design:
core/testpoint/designer.py - netlist edits:
core/testpoint/inserter.py - output generation:
core/testpoint/verilog_writer.py
- ranking:
Compatibility note
Public imports are intentionally re-exported in package __init__.py files where possible. Prefer package-level imports unless you are intentionally targeting a specific internal module.
Safe-change checklist
- Validate both
--genusand--yosyspaths for mode-sensitive edits. - Keep file/path handling through existing utilities, not hardcoded directories.
- Preserve output schema compatibility for metrics consumed by TPI.
- Run unit and integration tests for touched modules.