Convert Markdown requirements to ReqIF format and back
Project description
md2reqif
Convert Markdown requirements documents to ReqIF XML and back. A lightweight bridge between plain-text authoring and systems engineering toolchains (IBM DOORS, PTC Integrity, Polarion, etc.).
What it does
- Parses structured Markdown with YAML front matter into an internal requirements model
- Generates standards-compliant ReqIF XML with SPEC-OBJECTs, DATATYPES, and SPECIFICATIONS
- Reverses ReqIF back to Markdown for human review and editing
- Validates ReqIF files for XML well-formedness
Install
# Recommended — isolated tool install
uv tool install md2reqif
# Or with pip
pip install md2reqif
Quick start
Given requirements.md:
# Braking System Requirements
## Functional Requirements
### REQ-BRAKE-001: Emergency Braking Response Time
- Status: Draft
- Priority: High
- Type: Functional
The system SHALL apply emergency braking within 100ms of detecting a collision event.
Convert to ReqIF:
md2reqif convert requirements.md -o requirements.reqif
Convert back to Markdown:
md2reqif reverse requirements.reqif -o recovered.md
Markdown format reference
---
module: Module Name # optional: populates ReqIF TITLE
version: 1.0 # optional
author: Your Name # optional
date: 2024-01-15 # optional
---
# Document Title
## Section Name
### REQ-PREFIX-NNN: Requirement Title
- Status: Draft|Approved|Rejected|Obsolete
- Priority: Critical|High|Medium|Low
- Type: Functional|Performance|Interface|Constraint|Informational|Safety
- CustomKey: any value
Requirement description using SHALL language. Keep it to one or two sentences.
ID format: REQ- followed by alphanumeric segments separated by hyphens. If no matching ID is found, one is auto-generated from the section name.
CLI commands
| Command | Description |
|---|---|
md2reqif convert INPUT [-o OUTPUT] [--pretty/--no-pretty] |
Convert Markdown to ReqIF XML |
md2reqif reverse INPUT [-o OUTPUT] |
Convert ReqIF XML back to Markdown |
md2reqif validate INPUT |
Check ReqIF file for XML well-formedness |
md2reqif --version |
Print version |
Agent usage
See SKILL.md for detailed guidance on using this tool in AI agent pipelines, including the full Markdown format specification, metadata key reference, and writing tips for requirements authoring.
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file md2reqif-0.1.0.tar.gz.
File metadata
- Download URL: md2reqif-0.1.0.tar.gz
- Upload date:
- Size: 10.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Linux Mint","version":"22.3","id":"zena","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
51dc24198d0312da2cdb473a824cacf47fb6357db9c799825d55037544c1b612
|
|
| MD5 |
8cbca98ad4c8c34e5c9f9900d6aaf6a5
|
|
| BLAKE2b-256 |
6baf09a9f2cc7659f9042db902c4ae5345ee3ea7d096e3b94b3294b8e058cc33
|
File details
Details for the file md2reqif-0.1.0-py3-none-any.whl.
File metadata
- Download URL: md2reqif-0.1.0-py3-none-any.whl
- Upload date:
- Size: 9.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Linux Mint","version":"22.3","id":"zena","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c50827d91fe57a72bc662d2953115c682e16d8dd3f26d1d90703f33d9b99d5a2
|
|
| MD5 |
85ebba25ad577f4619e620af574b3583
|
|
| BLAKE2b-256 |
fb54a79e4d77cc9f7ea354875b2753b91b11ddee5a6a49d2c1f09b99c53645c5
|