stgem: System Testing Using Generative Models
stgem is a tool for runtime verification of cyber-physical systems. It supports falsification of requirements described
in Signal Temporal Logic (STL) and other runtime monitors using robustness semantics. This is achieved by training a generative machine learning
model online to produce system inputs that yield a low robustness.
This repository contains stgem implementing the API Version 2.
The INSTALLATION.md file describes how to set up stgem.
Documentation
Use the generate-docs.sh script to build stgem documentation, available in the docs folder.
Please refer to the demo folder for a demonstration on how to setup a system under test, use stgem in conjunction with a test generator to search for inputs that violate a specified safety requirements and subsequently how to analyze the results.
Research Articles
stgem has been used in the folling research articles:
Main algorithms
-
J. Peltomäki, I. Porres. Requirement falsification for cyber-physical systems using generative models. Autom. Softw. Eng 32(33) (2025). DOI, Preprint. The code specific for this paper is available here.
-
J. Peltomäki, I. Porres. Learning test generators for cyber-physical systems (2024), submitted. Preprint
Benchmarks
-
T. Khandait, F. Formica, P. Arcaini, S. Chotaliya, G. Fainekos, A. Hekal, A. Kundu, E. Lew, M. Loreti, C. Menghi, L. Nenzi, G. Pedrielli, J. Peltomäki, I. Porres, R. Ray, V. Soloviev, E. Visconti, M. Waga, Z. Zhang. ARCH-COMP 2024 category report: Falsification. Proceedings of 11th International Workshop on Applied Verification of Continuous and Hybrid Systems, ARCH24. EPiC Series in Computing, Vol. 103, 122-144 (2024). DOI. The code specific for this paper is available here.
-
C. Menghi, P. Arcaini, W. Baptista, G. Ernst, G. Fainekos, F. Formica, S. Gon, T. Khandait, A. Kundu, G. Pedrielli, J. Peltomäki, I. Porres, R. Ray, M. Waga, Z. Zhang. ARCH-COMP 2023 category report: Falsification. Proceedings of 10th International Workshop on Applied Verification of Continuous and Hybrid Systems, ARCH23. EPiC Series in Computing, Vol. 96, 151-169 (2023). DOI. The code specific for this paper is available here.
Applications
-
J. Winsten, I. Porres. Unified Search for Multi-requirement Falsification for Cyber-Physical Systems. Proceedings of International Conference on Software Testing, Verification and Validation Workshops, ICSTW 2025 (2025). DOI. The code specific for this paper is available here.
-
J. Winsten, V. Soloviev, J. Peltomäki, I. Porres. Adaptive test generation for unmanned aerial vehicles using WOGAN-UAV. The 17th Intl. Workshop on Search-Based and Fuzz Testing, SBFT 2024 (2024). DOI. The code specific for this paper is available here.
-
J. Peltomäki, J. Winsten, M. Methais, I. Porres. Testing cyber-physical systems with explicit output coverage. Proceedings of International Conference on Software Testing, Verification and Validation Workshops, ICSTW 2024 (2024). DOI. The code specific for this paper is available here.
-
J. Winsten, I. Porres. WOGAN at the SBFT 2023 tool competition - Cyber-physical systems track. The 16th Intl. Workshop on Search-Based and Fuzz Testing, SBFT 2023 (2023). DOI, Preprint.
-
J. Peltomäki, F. Spencer, I. Porres. Wasserstein generative adversarial networks for online test generation for cyber physical systems. The 15th Intl. Workshop on Search-Based Software Testing, SBST 2022 (2022). DOI, Preprint.
-
J. Peltomäki, F. Spencer, I. Porres. WOGAN at the SBST 2022 CPS tool competition. The 15th Intl. Workshop on Search-Based Software Testing, SBST 2022 (2022). DOI, Preprint.
-
J. Peltomäki, I. Porres. Falsification of multiple requirements for cyber-physical systems using online generative adversarial networks and multi-armed bandits. The 6th. Intl. Workshop on Testing Extra-Functional Properties and Quality Characteristics of Software Systems, ITEQS 2022 (2022). DOI, Preprint.
Contact us
stgem is developed at Åbo Akademi University. Contact Ivan Porres ivan.porres@abo.fi for more information.
Metadata
Release files for stgem 2.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| stgem-2.0.1.tar.gz | 108.9 kB | Without provenance | Details for stgem-2.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| stgem-2.0.1-py3-none-any.whl | Python 3 | none | any | Details for stgem-2.0.1-py3-none-any.whl |
Total release size: 223.0 kB
Release files / stgem-2.0.1.tar.gz
| Download URL | stgem-2.0.1.tar.gz |
|---|---|
| Size | 108.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b329c8b4da37d1e417b2b5602256a726423822a077bd9e8c3f5516edca8f25e8
|
|
BLAKE2b-256 checksum How to use checksums |
f32f2ee3feb013a9816f0406179b4f53320d86198eaa20e8f0103afb1e826525
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.11
|
Release files / stgem-2.0.1-py3-none-any.whl
| Download URL | stgem-2.0.1-py3-none-any.whl |
|---|---|
| Size | 114.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ba8c1deefbf6583a3e1359a8f1741536065b916c364c69cbeebd265341a8ac9f
|
|
BLAKE2b-256 checksum How to use checksums |
42f5623c79a74db1fcb10463c920fe3c788e352c0964ec71abc2365bc5e75bd8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.11
|
Security for stgem 2.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.