S1000D Reader (S1000D Stack)

v0.22.0
io.github.shuji-bonji/s1000d-reader-mcp Checked 2 hours ago Published 2 hours ago

Read S1000D data and publication modules as structure, with applicability and verification status.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

list_data_modules

List the CSDB objects (data modules by default; optionally publication modules, DML, DDN, IMF, UPF, ICN) in the CSDB folders with DMC parts, techName/infoName, issue, language, schema name (descript/proced/…), S1000D issue and applicability display text. A DML or DDN row also carries its code, issue date, entry/item count and a reconciliation summary against the CSDB (found / issue-mismatch / not-found / not-checked; for a DML also how many DMs and PMs it does not list). Filter by modelIdentCode, systemCode, infoCode, schemaName or title text. Paged with offset/limit.

ParameterTypeDescription
csdbDirsarrayCSDB folders to search for data modules by DMC, referenced objects, ACT/CCT/PCT and BREX (default: S1000D_CSDB_DIR / the config file). When given, these folders replace S1000D_CSDB_DIR and the csdbDir…
filterobject
includearrayObject kinds to list (default: dm).
limitnumberObjects per call (default 100, max 1000).
offsetnumberIndex of the first object (default 0).

read_data_module

Read one data module as structure, not XML: identification and status (DMC, issue, language, title, BREX ref, QA, DM-level applicability), the body as a tree of blocks (sections, paragraphs, lists, tables, figures with ICN, warnings/cautions/notes, numbered steps, requirements; processes and fault isolation too), the reference list at the head of the content when the data module has one (content.refs: targets and the titles written there), the references it makes, ALWAYS a "verification" status (XSD by default) and ALWAYS "securityClassification" (the data module's value and the values carried…

ParameterTypeDescription
csdbDirsarrayCSDB folders to search for data modules by DMC, referenced objects, ACT/CCT/PCT and BREX (default: S1000D_CSDB_DIR / the config file). When given, these folders replace S1000D_CSDB_DIR and the csdbDir…
dmcstringDMC of the data module to read from the CSDB (e.g. "S1000DBIKE-AAA-D00-00-00-00AA-041A-A"; "DMC-" prefix optional). Alternative to path/xml.
includeLocationbooleanAdd "location" (path, line, column) to every node of the body or the outline (default false). Pass true when you are going to edit the data module with s1000d-writer-mcp edit_data_module: its "at" and…
maxNodesnumberCap on body nodes returned (default 5000).
omitNotApplicablebooleanDrop blocks that are notApplicable for the given product (default false: keep them, marked). The number dropped is reported.
outlineDepthintegerWith section "outline": how many levels of headings / steps to return (default: all levels).
pathstringFile path of the document.
productobjectThe product to evaluate applicability for. attributes: ACT productAttribute id → value (e.g. {"model": "Brook trekker", "version": "Mk9"}); conditions: CCT cond id → value. Omit to get "undetermin…
sectionstringWhich part to return (default all). "outline" returns only headings, step numbers, the first sentence and the size (nodes / chars / admonitions) of each subtree — call it first on a large data modul…
verifystringHow much to verify before reading: "schema" (default) runs XSD validation only; "full" also checks BREX along the brexDmRef chain and resolves references; "none" skips verification (reported as not-ru…
xmlstringThe document as an XML string (alternative to path; max 5 MB).

read_publication_module

Read a publication module (PMC) as a table of contents: the pmEntry tree with titles, and for each dmRef/pmRef the resolved target (file, techName/infoName, issue) from the CSDB. Also returns the PM identification and a verification status.

ParameterTypeDescription
csdbDirsarrayCSDB folders to search for data modules by DMC, referenced objects, ACT/CCT/PCT and BREX (default: S1000D_CSDB_DIR / the config file). When given, these folders replace S1000D_CSDB_DIR and the csdbDir…
pathstringFile path of the document.
pmcstringPMC to read from the CSDB (e.g. "S1000DBIKE-B6865-EPWG1-00"; "PMC-" prefix optional). Alternative to path/xml.
verifystringHow much to verify before reading: "schema" (default) runs XSD validation only; "full" also checks BREX along the brexDmRef chain and resolves references; "none" skips verification (reported as not-ru…
xmlstringThe document as an XML string (alternative to path; max 5 MB).

resolve_reference

Resolve one reference to a CSDB object: a DMC, a PMC, or an ICN (file name or entity name). Returns the file path(s), issue(s) and title. For an ICN, pass "fromPath" of the data module whose DOCTYPE declares the entity to get the declared file and notation.

ParameterTypeDescription
csdbDirsarrayCSDB folders to search for data modules by DMC, referenced objects, ACT/CCT/PCT and BREX (default: S1000D_CSDB_DIR / the config file). When given, these folders replace S1000D_CSDB_DIR and the csdbDir…
dmcstringDMC to resolve.
fromPathstringData module whose DOCTYPE declares the ICN entity (optional).
icnstringICN (entity name or file name) to resolve.
pmcstringPMC to resolve.

describe_applicability

Describe the applicability vocabulary of a data module so a product can be chosen: the ACT product attributes (ids, names, enumerations/patterns, which one identifies the product), the CCT condition types and conditions, the PCT products (ready-made product values), the applic statements in the data module (ids and display texts), and which attributes used by the statements have no value in the PCT. Nothing is evaluated here; pass the chosen values as "product" to read_data_module.

ParameterTypeDescription
csdbDirsarrayCSDB folders to search for data modules by DMC, referenced objects, ACT/CCT/PCT and BREX (default: S1000D_CSDB_DIR / the config file). When given, these folders replace S1000D_CSDB_DIR and the csdbDir…
dmcstringDMC of the data module to read from the CSDB (e.g. "S1000DBIKE-AAA-D00-00-00-00AA-041A-A"; "DMC-" prefix optional). Alternative to path/xml.
pathstringFile path of the document.
xmlstringThe document as an XML string (alternative to path; max 5 MB).

read_icn_metadata

Read an ICN metadata file (IMF, icnmetadata.xsd): ICN, issue, title, keywords, security, source/originator and other status items as a flat list, plus the related ICN files found in the CSDB.

ParameterTypeDescription
csdbDirsarrayCSDB folders to search for data modules by DMC, referenced objects, ACT/CCT/PCT and BREX (default: S1000D_CSDB_DIR / the config file). When given, these folders replace S1000D_CSDB_DIR and the csdbDir…
icnstringICN whose IMF to read from the CSDB (e.g. "C0419-S1000D0360-001-01" or "ICN-C0419-…").
pathstringFile path of the document.
xmlstringThe document as an XML string (alternative to path; max 5 MB).