https://github.com/daleonpz/raiz
Simply CLI Requirements management tool
https://github.com/daleonpz/raiz
embedded embedded-systems python requirements-management software software-engineering systems-engineering
Last synced: 11 months ago
JSON representation
Simply CLI Requirements management tool
- Host: GitHub
- URL: https://github.com/daleonpz/raiz
- Owner: daleonpz
- License: apache-2.0
- Created: 2025-07-14T18:54:00.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-08-09T20:09:40.000Z (12 months ago)
- Last Synced: 2025-08-12T16:57:23.872Z (12 months ago)
- Topics: embedded, embedded-systems, python, requirements-management, software, software-engineering, systems-engineering
- Language: Python
- Homepage:
- Size: 71.3 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ๐งฐ Raiz - Simple CLI Requirements Management Tool
A CLI tool to manage, track, and trace software requirements with automated test case linking, traceability reporting, and seamless integration with Robot Framework.
> Built for developers and teams working with embedded systems, Zephyr RTOS, or other projects where traceability and coverage are crucial.
You can try Raiz using the provided [example](example/).
## ๐ Table of Contents
* [๐ Features](#features)
* [๐ฆ Installation](#installation)
* [โ๏ธ Requirements Format (YAML)](#requirements-format-yaml)
* [๐งช Robot Framework Integration](#robot-framework-integration)
* [๐งพ CLI Usage](#cli-usage)
* [Add a Requirement](#add-a-requirement)
* [Remove a Requirement](#remove-a-requirement)
* [Trace Requirements Coverage](#trace-requirements-coverage)
* [List Requirements](#list-requirements)
* [Update Requirement](#update-requirement)
* [Sync Requirements](#sync-requirements)
* [๐ Reports and Temp Files](#reports-and-temp-files)
* [๐งช Testing](#testing)
* [๐๏ธ Roadmap](#roadmap)
* [๐ License](#license)
* [๐ค Contributing](#contributing)
## ๐ Features
* ๐ **Define and manage software requirements** (Functional, Non-functional, Constraints)
* ๐ **Link test cases** (from Robot Framework) to specific requirements using tags (e.g., `REQ-001`)
* โ
**Trace test coverage** โ which requirements are tested, which are missing
* ๐๏ธ **SQLite-backed DB** for performance and reliability
* ๐งช **Robot Framework integration** using `output.xml`
* ๐ฆ Installable via `pip`
* ๐ **Traceability reporting**: Console, JSON
* ๐งน Automatic renumbering of requirements
* ๐งฐ Modular and extensible codebase
## ๐ฆ Installation
```bash
pip install raiz
```
## โ๏ธ Requirements Format (YAML)
All requirements are stored in a single `requirements.yaml` file and look like:
```yaml
- id: REQ-001
description: "The system shall support BLE communication."
type: functional
domain: ble
linked_tests: []
```
IDs are renumbered automatically.
## ๐งช Robot Framework Integration
Tests should be tagged with requirement IDs:
```robot
*** Test Cases ***
Test BLE Connection
[Tags] REQ-001
Do Something
```
After executing tests (which generates `output.xml`), you can trace coverage.
## ๐งพ CLI Usage
Run **raiz** from your repository
```bash
cd my_repo/
raiz [options]
```
### Add a Requirement
```bash
raiz add
```
Prompts for description, type, domain.
### Remove a Requirement
```bash
raiz rm
raiz rm 3
```
Deletes requirement `REQ-003` and renumbers all remaining ones.
### Trace Requirements Coverage
```bash
raiz trace --fmt json --output trace_report
```
* `--format`: `console`, `json`
* `--robot-output`: location of the Robot Framework output file
* `--output`: output of the report file. The extension is added automatically
* `--detail`: generates a more detailed trace report
```json
{
"timestamp": "2025-08-08T19:16:46.837013",
"coverage": {
"total_requirements": 2,
"tested_requirements": 2,
"pass_rate": 75.0,
"coverage_rate": 100.0
},
"report": {
"REQ-001": {
"uuid": "c567c0d4-fe18-4d9b-8a1a-2e6b128ed89f",
"description": "Library should have add function",
"type": "functional",
"domain": "math",
"linked_tests": [
"Add Integers",
"Fail Add Integers"
],
"test_results": [
[
"test_math.robot",
"Add Integers",
"PASS"
],
[
"test_math.robot",
"Fail Add Integers",
"FAIL"
]
]
},
"REQ-XXX": {
...
}
},
"detailed_report": {
"domains": {
"math": {
"total_requirements": 2,
"tested_requirements": 2,
"pass_rate": 75.0,
"coverage_rate": 100.0
}
},
"types": {
"functional": {
"total_requirements": 2,
"tested_requirements": 2,
"pass_rate": 75.0,
"coverage_rate": 100.0
}
}
}
}
```
Options valid only for `--fmt console`
* `--domain`: Filter report by specific domain
* `--type`: Filter report by specific requirement type
```bash
raiz trace --fmt console --domain ble
raiz trace --fmt console --type functional
```

### Show Requirements
```bash
raiz show all # Show all saved requirements
raiz show domains # Show all unique domains found across the saved requirements
raiz show types # Show all unique requirement types found across the saved requirements
```

### Update Requirement
```bash
raiz update
raiz update 3
```
Prompts to update description/type/domain
Or directly update the `type` for requirement REQ-003
```bash
raiz update 3 --field type -value performance
```
### Sync Requirements
Requirements are stored in a temporary SQLite database. To generate a YAML file with all requirements and commit your changes, use:
```bash
raiz sync to-yaml
git add requirements.yaml
```
If you have a `requirements.yaml` file and want to load it into the SQLite database, use:
```bash
raiz sync from-yaml
```
## Reports and Temp Files
* `.req_cache/` contains temporal files required to manage requirements
* `traceability.json` default output
## ๐งช Testing
```bash
robot tests/system
```
## ๐๏ธ Roadmap
* [x] Report in YAML format
* [x] Multiple output formats (Console/JSON)
* [ ] Support to [Requirements Interchange Format - ReqIF](https://de.wikipedia.org/wiki/Requirements_Interchange_Format)
* [ ] Support for the Zephyr RTOS testing framework.
* [ ] Improve documentation and create wiki.
## ๐ License
Apache License 2.0
## ๐ค Contributing
Pull requests welcome! Please run the linter (ruff) and tests before submitting.