Skip to main content

udsdoc

AUTOSAR DCM/CanTp/DEM ARXML → ISO 14229 (UDS) / 15765 / 22901-1 (ODX/PDX) specification documents.

PyPI version Python License: MIT

udsdoc parses AUTOSAR diagnostic ARXML (DCM, CanTp, DEM, DoIP, COM, AP) and renders a complete UDS specification in LaTeX / PDF / HTML / Markdown / RST, plus ASAM ODX 2.2.0 / PDX (ISO 22901-1) for diagnostic tooling. Drive it from the command line or a local browser UI — both run the same pipeline.

Renamed from udsxml2tex in v0.66.0. The old package, udsxml2tex CLI, UDSXML2TEX_* env vars and pre-commit hook ids keep working as deprecated aliases until v1.0.

Install

pip install udsdoc          # core (LaTeX / Markdown / RST)
pip install udsdoc[web]     # browser UI (--serve) + inline SVG figures
pip install udsdoc[all]     # everything

PDF output needs a LaTeX distribution with xelatex (TeX Live / MiKTeX). The [all] extra pulls in every optional feature (browser UI, LLM analysis, ECU hardware testing, and more).

Command line

udsdoc dcm.arxml -o spec.tex                              # single ARXML → LaTeX
udsdoc dcm.arxml cantp.arxml --dem dem.arxml -o spec.tex  # merge modules
udsdoc --repo /path/to/bsw-project -o spec.tex            # auto-discover a BSW repo
udsdoc dcm.arxml --format html -o spec.html               # other formats: html, md, rst, pdx
udsdoc dcm.arxml --pdf                                    # compile to PDF
udsdoc dcm.arxml --lang en+ja -o spec.tex                 # stacked multi-language output

Python API:

from udsdoc import ArxmlParser, TexGenerator

spec = ArxmlParser().parse_multi(["dcm.arxml", "cantp.arxml"])
TexGenerator().generate(spec, "spec.tex")

Browser UI

pip install udsdoc[web]
udsdoc --serve            # opens http://127.0.0.1:8765

A local server with four tabs in the sidebar:

  • Generate — point it at a BSW repository folder (or load a built-in sample bundle). The server scans every ARXML / C file, classifies the Dcm / CanTp / Dem modules and auto-detects single- vs multi-ECU. Pick output language(s), then Parse & Preview to inspect the spec and Generate & Download a LaTeX ZIP (with spec.pdf when xelatex is available) — or Export ODX / PDX for CANalyzer / CANoe. An optional Compliance Matrix CSV adds a requirements-compliance chapter.
  • Spec — parsed sessions, services, DIDs, RIDs and DTCs as browsable tables.
  • Chat — ask questions about the loaded spec via an LLM (Anthropic / OpenAI-compatible / Ollama).
  • About — version and build info.

CUI / HPC batch verification

The full pipeline — Compliance Matrix + arxml/c/h → consistency verification → pdf/pdx — also runs head-less from the command line (no browser), so it fits a CI step or a supercomputer batch job. The semantic "does the concluded OEM↔supplier dialogue match the implementation?" check that the browser UI exposes as Verify all is available via --verify:

# Single ECU — deterministic, fully offline
udsdoc dcm.arxml cantp.arxml --dem dem.arxml \
    --compliance-matrix matrix.csv --verify --format pdx -o out/spec

# Dual uC (Primary + Secondary, IPC forwarding) — per-ECU matrices in the config
udsdoc --system src/udsdoc/samples/system_dual_uc.yaml \
    --verify --format pdx --system-output-dir out/

--verify runs a layered engine so real-project scale (10 docs × ~500 requirements) stays tractable instead of sending every row to an LLM:

  1. status triage — accepted/verified → match, rejected-but-implemented → deviation, others → out of scope (no LLM);
  2. numeric / session structural checks — BS/STmin/P2/P2*/S3 and session-membership compared against the parsed DcmDspSession / AccessTiming / CanTp config (no LLM);
  3. lexical fast-path — a hex id / UDS element absent from the parsed config (no LLM);
  4. LLM — only the prose-ambiguous residue, and only with --verify-llm.

Each row is written to a machine-readable report (*_verify.json + .md). Verdicts are de-duplicated and, with --verify-cache DIR, reused across runs.

flag effect
--verify run verification, write the report (deterministic, offline)
--verify-llm enable the LLM layer for the residue (uses the --llm-* flags / $UDSDOC_LLM_*)
--verify-workers N parallel LLM workers (I/O-bound)
--verify-cache DIR persistent cross-run verdict cache (biggest speed-up at scale)
--verify-strict exit non-zero when any row deviates (CI / HPC gate)

In multi-ECU mode each ECU is verified against its own parsed spec, so a requirement that traces to a Secondary-only DID is checked on the Secondary — not the Primary. pdx needs no LaTeX; pdf is produced only when xelatex is available. Ready-to-run wrappers: examples/run_single_uc.sh and examples/run_dual_uc.sh.

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

udsdoc-0.83.3.tar.gz (1.8 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

udsdoc-0.83.3-py3-none-any.whl (1.8 MB view details)

Uploaded Python 3

File details

Details for the file udsdoc-0.83.3.tar.gz.

File metadata

  • Download URL: udsdoc-0.83.3.tar.gz
  • Upload date:
  • Size: 1.8 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for udsdoc-0.83.3.tar.gz
Algorithm Hash digest
SHA256 44df8e7864e72907b4c2133806b87e4a30ddbfa02dded2add7f3728d2246f1c3
MD5 296e1dcf2a7e24ac57f44a7d29996a5a
BLAKE2b-256 4dc37866280ade439d331d8d2fd010fc6ca246c9b81155b55462da3b58f47b9c

See more details on using hashes here.

File details

Details for the file udsdoc-0.83.3-py3-none-any.whl.

File metadata

  • Download URL: udsdoc-0.83.3-py3-none-any.whl
  • Upload date:
  • Size: 1.8 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for udsdoc-0.83.3-py3-none-any.whl
Algorithm Hash digest
SHA256 13e2c5be9eea98ba89044b615680233fbb0dc83fb7eeb642c6bdda0455bf1998
MD5 54b9dabb3c807541d9eaa4d6ff0cd121
BLAKE2b-256 85ef92e8a61bb29ab0ac9d77582eb37027701898e54bd0d70a8014752eda5ce5

See more details on using hashes here.

Release history Release notifications | RSS feed

0.187.0

2 files

0.186.0

2 files

0.185.0

2 files

0.184.0

2 files

0.183.0

2 files

0.182.0

2 files

0.181.0

2 files

0.180.2

2 files

0.180.1

2 files

0.179.0

2 files

0.178.0

2 files

0.177.0

2 files

0.176.0

2 files

0.175.0

2 files

0.174.0

2 files

0.173.1

2 files

0.173.0

2 files

0.172.1

2 files

0.172.0

2 files

0.171.0

2 files

0.170.9

2 files

0.170.8

2 files

0.170.7

2 files

0.170.3

2 files

0.170.2

2 files

0.170.1

2 files

0.170.0

2 files

0.169.0

2 files

0.168.0

2 files

0.167.0

2 files

0.166.0

2 files

0.165.0

2 files

0.164.0

2 files

0.163.0

2 files

0.162.3

2 files

0.162.2

2 files

0.162.1

2 files

0.162.0

2 files

0.161.0

2 files

0.160.0

2 files

0.159.0

2 files

0.158.0

2 files

0.157.0

2 files

0.156.0

2 files

0.155.0

2 files

0.154.0

2 files

0.153.0

2 files

0.152.0

2 files

0.151.0

2 files

0.150.2

2 files

0.150.1

2 files

0.150.0

2 files

0.149.0

2 files

0.148.0

2 files

0.147.0

2 files

0.146.0

2 files

0.145.1

2 files

0.145.0

2 files

0.144.0

2 files

0.143.0

2 files

0.142.0

2 files

0.141.0

2 files

0.140.0

2 files

0.139.0

2 files

0.138.0

2 files

0.137.0

2 files

0.136.0

2 files

0.135.0

2 files

0.134.0

2 files

0.133.0

2 files

0.132.0

2 files

0.131.0

2 files

0.130.0

2 files

0.129.0

2 files

0.128.0

2 files

0.127.0

2 files

0.126.0

2 files

0.125.0

2 files

0.124.0

2 files

0.123.0

2 files

0.122.0

2 files

0.121.0

2 files

0.120.0

2 files

0.119.0

2 files

0.118.0

2 files

0.117.0

2 files

0.116.0

2 files

0.115.0

2 files

0.114.0

2 files

0.113.0

2 files

0.112.0

2 files

0.111.0

2 files

0.110.0

2 files

0.109.0

2 files

0.108.1

2 files

0.108.0

2 files

0.107.0

2 files

0.106.1

2 files

0.106.0

2 files

0.105.0

2 files

0.104.0

2 files

0.103.0

2 files

0.102.0

2 files

0.101.0

2 files

0.100.0

2 files

0.99.0

2 files

0.98.0

2 files

0.97.0

2 files

0.96.0

2 files

0.95.0

2 files

0.94.0

2 files

0.93.0

2 files

0.92.0

2 files

0.91.0

2 files

0.90.0

2 files

0.89.0

2 files

0.88.0

2 files

0.87.0

2 files

0.86.0

2 files

0.85.0

2 files

0.84.0

2 files

0.83.5

2 files

0.83.4

2 files

This release

0.83.3 This release

2 files

0.83.2

2 files

0.83.1

2 files

0.83.0

2 files

0.82.0

2 files

0.81.7

2 files

0.81.6

2 files

0.81.5

2 files

0.81.4

2 files

0.81.3

2 files

0.81.2

2 files

0.81.1

2 files

0.81.0

2 files

0.80.0

2 files

0.79.0

2 files

0.78.1

2 files

0.78.0

2 files

0.77.2

2 files

0.77.1

2 files

0.77.0

2 files

0.76.0

2 files

0.75.0

2 files

0.74.0

2 files

0.73.0

2 files

0.72.0

2 files

0.71.0

2 files

0.70.1

2 files

0.70.0

2 files

0.69.0

2 files

0.68.0

2 files

0.67.0

2 files

0.66.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page