sdc-mapper-mcp
OfficialClick on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@sdc-mapper-mcpmap record.xml to UBL and report every value's fidelity"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
sdc-mapper
The shared core of the Semantic Data Charter's Governed Data Record mappers. It validates a record, reads the model the record names, resolves every value against what the model says about it, hands the result to a target mapper, and reports every value: how it reached the target, or that the target cannot hold it. Where the record says why a value is missing or unusable (an Exceptional Value, from the ISO 21090 null flavors), the report also says whether the target could say it too. Every call is appended to a hash-chained log that holds no values.
Each target format is its own package (sdc-gdr2ubl, sdc-gdr2edifact, sdc-gdr2omop, ...) registered under the
entry-point group sdc_mapper.targets. Outbound only. Apache 2.0.
Status: 4.1.1. The first target mapper, sdc-gdr2ubl (OASIS UBL 2.3), is in development.
Use
sdc-map targets
sdc-map map TARGET record.xml --package DIR [--mapping m.yaml] [-o out/]
sdc-map fidelity record.xml --package DIR # every installed target, side by side, per Exceptional Value
sdc-map check-mapping m.yaml --package DIR
sdc-map log summary --days 7 | sdc-map log verify
sdc-mapper [--log-dir DIR] [--host URL] # MCP stdio server (also sdc-mapper-mcp): the primary way agents use the mappersA model is a package directory (dm-<ct>.jsonld, dm-<ct>.xsd) or a published model's --ct-id, fetched from the
SDCStudio host; with neither, the record's own root names it. Exit status: 0 mapped, 1 refused, 2 error.
Related MCP server: LogicMem MCP Server
The three outcomes
valid: mapped.
valid with Exceptional Values: a value that failed its constraint is covered by an Exceptional Value (Invalid, with the constraint kept), and the rest of the record is mapped. Exceptional Values written at the source (a refusal, a masked field) are kept as written.
refused: a broken structure, the wrong model, or an error no Exceptional Value covers. Nothing is written; the reasons are returned and logged.
Mapping files
YAML, validated against schemas/mapping.schema.json, bound to one model schema version and one target version.
mapping: {id: credit-note-to-ubl, version: 1}
model: {ct_id: jkuyr38hydqaiwlq5vhp2rjr, schema_sha256: "…"}
target: {name: OASIS UBL, version: "2.3 CreditNote"}
rules:
- cluster: <Accounting Supplier Party> # a cluster to a target element
to: cac:AccountingSupplierParty
- cluster: <Party> # relative to the enclosing mapped cluster
to: cac:Party
- component: <Party Identification Value>
to: cac:PartyIdentification/cbc:ID
transform: copy
- component: <Party Identification Scheme>
to: cac:PartyIdentification/cbc:ID/@schemeName # an attribute of the same element
transform: copy
- component: <Line Extension Amount>
to: cbc:LineExtensionAmount
transform: copy
units: {to: "@currencyID", transform: copy}
- cluster: <Party Contact>
to: "-"
transform: omit
reason: the target profile carries no contactTransforms: copy, code (a table), format, constant, omit; clusters group or omit. within: restricts a
rule to a context. A value no rule reaches is reported, never dropped. place(record, mapping) turns a record and its
mapping into placements a mapper writes from.
Writing a mapper
A mapper has name, target, target_version, package, version, an Exceptional Value table (ev_table: an
EVRule per ISO 21090 code: preserved, degraded, carried or lost) and map(record, mapping) -> MapResult. It returns
one ValueOutcome for every value it was given, never writes a rejected value as a value, and registers itself:
[project.entry-points."sdc_mapper.targets"]
ubl = "sdc_gdr2ubl:UBLMapper"Tests
python -m pytest tests -q (offline). The fixture is a HalvorsenDemo Credit Note record and its model's package;
the reference mapper in tests/refmapper.py is a flat CSV used only to exercise the contract.
License
Apache 2.0. See NOTICE for the shipped SDC4 reference model schema and the fixture.
Available Tools
6 toolscheck_mappingB
Validate a mapping file against the mapping schema, and, given a model, check it is bound to that model's current schema.
| Name | Required | Description | Default |
|---|---|---|---|
| ct_id | No | The model's identifier (CUID2) in the public catalog; the package is fetched from the host this server was started with. | |
| mapping | Yes | Path to a mapping file (YAML) for this model and target, if the model alone does not settle the mapping. | |
| directory | No | A package directory already on disk (dm-<ct>.jsonld and dm-<ct>.xsd, optionally catalog.json and versions.json). Give this or ct_id, not both. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the burden, and it does disclose the checks performed (schema conformance plus binding to the model's current schema). However it says nothing about whether validation is read-only, whether it mutates the mapping file, what the result looks like on failure, or that ct_id triggers a network/package fetch from the host.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
One front-loaded sentence with no filler; the two capabilities are ordered sensibly. Slightly overstuffed comma structure costs a point but nothing is wasted.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema and no annotations, so the description should say more about what a validation result or failure mode looks like and about the fetch implied by ct_id. It covers both operating modes but leaves the agent guessing about the return contract.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the schema already documents mapping, ct_id and directory including the 'give this or ct_id, not both' constraint. The description only gestures at the model-vs-file distinction ('given a model'), adding little beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Names two specific verbs (validate, check binding) on a well-defined resource (mapping file against mapping schema / model schema) – the agent can tell this apart from siblings like map_record and fidelity, which transform or score rather than validate. It stops short of explicitly contrasting with those siblings.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies the situation ('given a model, check it is bound to that model's current schema') but never states when to use this versus map_record or fidelity, nor any prerequisites. Usage is inferable from the phrasing rather than spelled out.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
fidelityB
Run every installed mapper on one record and compare what each target did with each Exceptional Value: one row per Exceptional Value, one column per target. Shows which formats can say why a value is missing or unusable, and which can only leave it empty.
| Name | Required | Description | Default |
|---|---|---|---|
| ct_id | No | The model's identifier (CUID2) in the public catalog; the package is fetched from the host this server was started with. | |
| record | Yes | Path to the Governed Data Record's XML file on disk. | |
| mappings | No | Mapping file paths by mapper name. | |
| directory | No | A package directory already on disk (dm-<ct>.jsonld and dm-<ct>.xsd, optionally catalog.json and versions.json). Give this or ct_id, not both. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so the description carries the full behavioral burden. It adds useful output semantics (row/column layout, what the comparison reveals) but omits whether it is read-only, whether it requires installed mappers or exact prerequisites, cost/perf, and output encoding. Some value added, meaningful gaps remain.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two dense sentences, action-first, with the output structure front-loaded right after the verb. Minor jargon ('Exceptional Value') adds cognitive load but every clause earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
There is a nested object (mappings), no output schema, and no annotations, so the description should do more — yet it gives no return encoding, error behavior, or mention of how mappings/directory interplay works. Adequate conceptually but incomplete for this complexity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so parameters and the ct_id/directory exclusivity are documented in the schema itself. The description adds nothing about parameter behavior, so the baseline of 3 applies.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific action: run every installed mapper on one record and compare per-target handling of Exceptional Values. The output shape (one row per EV, one column per target) makes the resource concrete. It doesn't explicitly name a sibling like map_record for contrast, so it falls just short of a 5.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Implied usage is clear from the comparison framing — you'd use this to see how various formats represent missing/unusable values. However, there is no explicit when-to-use versus map_record/check_mapping, and no stated preconditions (mappers must be installed).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_targetsA
The target mappers installed: each target format and version, its package, and how it writes each ISO 21090 Exceptional Value (preserved, degraded, carried or lost).
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description must carry the behavioral burden. It helpfully discloses the shape of each listed item, including value disposition categories (preserved, degraded, carried, lost), but it does not state that this is a read-only operation, whether it is cached, or any auth or side-effect behavior.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single front-loaded sentence that efficiently describes the resource and the fields each entry includes. Every phrase contributes to understanding what is returned.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With no annotations and no output schema, the description usefully explains the content and value-disposition vocabulary of the return data. It is nearly complete for a simple zero-parameter listing tool, though it could say slightly more about the list's ordering or shape.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has zero parameters, so there are no parameter semantics to explain. The baseline for a no-parameter tool is 4.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a clear listing verb implied by 'The target mappers installed' and specifies the resource: target formats, versions, packages, and exceptional-value handling. It is distinct from mutation/checking siblings like map_record or check_mapping, though it does not explicitly name them.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
There is no explicit guidance on when to call this tool, when not to, or how it relates to siblings such as map_record or check_mapping. Usage is only implied by the list-like purpose.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
log_summaryB
Read the log back over a window: calls, outcomes, value classes and Exceptional Value classes per target, and the models and mapping files in use.
| Name | Required | Description | Default |
|---|---|---|---|
| days | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the behavioral burden. "Read the log back" implies a non-destructive read and it lists the summary content, but it omits permissions, rate limits, return format, and other operational details.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single front-loaded sentence with no wasted words. The colon-delimited list efficiently enumerates the summary dimensions.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple one-parameter read tool, the description covers the purpose and the categories returned. However, with no output schema, no annotations, and 0% schema description coverage, it should do more to explain the days parameter and the return structure.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The sole parameter is days, and the schema provides no description for it. The description mentions "over a window" but does not explain that days controls the window, nor does it mention the default of 7 or the minimum of 0.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description gives a specific verb and resource: "Read the log back over a window," then lists the summary dimensions returned. It is clear what the tool does, but it does not explicitly distinguish itself from siblings such as verify_log or list_targets.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
There is no explicit guidance on when to use this tool versus alternatives. The description implies it summarizes a log window, but it does not name when-not-to-use cases or point to sibling tools.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
map_recordA
Map one Governed Data Record to one target format. The record is validated first: valid, valid with Exceptional Values (one bad value is marked, not fatal), or refused with the reasons. Returns the output (inline, or written to output_dir), the coverage report (how every value reached the target, and what happened to every Exceptional Value), one sentence of what the target could not say, and the hash of the log entry. The model is the one the record names unless ct_id or directory is given.
| Name | Required | Description | Default |
|---|---|---|---|
| ct_id | No | The model's identifier (CUID2) in the public catalog; the package is fetched from the host this server was started with. | |
| record | Yes | Path to the Governed Data Record's XML file on disk. | |
| target | Yes | A mapper name, as list_targets gives it. | |
| mapping | No | Path to a mapping file (YAML) for this model and target, if the model alone does not settle the mapping. | |
| directory | No | A package directory already on disk (dm-<ct>.jsonld and dm-<ct>.xsd, optionally catalog.json and versions.json). Give this or ct_id, not both. | |
| output_dir | No | Write the outputs and coverage.json here instead of returning them inline. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden and does so well: it discloses the three validation outcomes (valid, valid-with-Exceptional-Values, refused), that a bad value is marked rather than fatal, that outputs may be written to disk, and that a log entry (with hash) is produced. It stops short of stating side effects like idempotency, overwrite behavior in output_dir, or the fact that a log record is persisted.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Four tight sentences, front-loaded with the action, then the validation semantics, then the return payload, then the model-selection rule. No filler and no repetition of the schema.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
There is no output schema, and the description compensates by enumerating the return payload (output, coverage report, one-sentence limitation, log hash). For a six-parameter tool with a multi-step pipeline this is nearly complete; only error/refusal return shape and file-write side effects are left vague.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the baseline is 3, but the description adds real meaning: it explains model-resolution precedence ('the model is the one the record names unless ct_id or directory is given') and ties output_dir to the inline-vs-file return behavior. It does not explain what 'target' or 'mapping' mean beyond the schema, but the precedence rule is a genuine addition.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource ('Map one Governed Data Record to one target format') with clear scope ('one... to one'). It does not, however, contrast itself with siblings like check_mapping or fidelity, so the agent must infer when mapping differs from checking or measuring fidelity.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Usage is implied by the verb, and the description explains the validation pipeline a caller will encounter. It never says when to reach for this tool versus check_mapping/fidelity, nor does it state prerequisites (e.g. that a target must come from list_targets — that detail lives only in the schema).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
verify_logA
Walk the log's hash chain from the first entry and report whether any entry was altered or removed.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description must carry the behavioral burden. It usefully discloses that the walk starts at the first entry and covers both alteration and removal, which implies a read-only, whole-log operation, but it says nothing about cost/latency on long chains, whether it short-circuits at the first bad entry, or whether auth is required.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single sentence with the operation and its result front-loaded; every clause earns its place and nothing is redundant.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema exists, but the description conveys the key return semantics (tampered-or-removed vs. clean). Minor gaps remain — result granularity (per-entry vs. boolean) and behavior on failure — which keep it just short of complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool takes zero parameters, so the baseline is 4; there are no parameter semantics to explain and the description correctly implies it is invoked without arguments, scoped only to 'the log'.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource (walk the log's hash chain from the first entry) plus the exact outcome it produces (whether any entry was altered or removed). This is clearly distinguishable from siblings like log_summary or fidelity, which do not claim integrity verification.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Usage is only implied by the verb 'verify' — an agent can infer this is for integrity/tamper checking. There is no explicit when-to-use vs. log_summary or when-not guidance (e.g., cost on very large logs, or that it only covers this log's chain).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
6 tool updates
v4.1.1- First observed
check_mapping - First observed
fidelity - First observed
list_targets - First observed
log_summary - First observed
map_record - First observed
verify_log
TDQS
Scored across 6 tools
Each tool has a clearly distinct role: listing targets, mapping a record, validating a mapping file, comparing fidelity across mappers, summarizing the log, and verifying log integrity. Although map_record and fidelity both involve mapping a record, their scopes are clearly separated (single target vs. cross-target comparison) and descriptions make the boundary explicit.
Most tools follow a clear verb_noun pattern (list_targets, map_record, check_mapping, log_summary, verify_log), with 'fidelity' being the lone noun-only exception. The set remains readable and predictable overall, but the deviation prevents a perfect score.
Six tools is well-scoped for a mapping and logging server, and each tool appears to earn its place. There is no apparent bloat or missing essential operation at the count level.
The surface covers target listing, mapping, mapping validation, cross-target fidelity comparison, log summarization, and log integrity verification. Minor gaps exist around discovering available models or mapping files, but core workflows are covered and agents can work around these omissions.
Related MCP Connectors
- kanonikOAuthai.kanonik
Governance runtime for compliance: verified, human-approved writes to a tamper-evident record.
Governed data discovery, exact queries, decisions, simulations, and runtime utilities over MCP.
Live behavioral security verifier, schema auditor, and trust oracle for A2A, MCP & x402 agents.
Guarded MCP server for agent-readable business truth, provenance, readiness, and discovery.
Related MCP Servers
- AlicenseBqualityDmaintenanceProvides persistent memory, reasoning engine, agent-to-agent sharing, and immutable audit trail for AI agents via the Model Context Protocol.12MIT

LogicMem MCP Serverofficial
AlicenseBqualityDmaintenanceProvides persistent memory, reasoning, agent-to-agent sharing, and immutable audit trail for AI agents via the Model Context Protocol.121MIT- AlicenseNot gradedqualityDmaintenanceA governed context layer for internal data exposed over MCP, enabling agents to query governed definitions, retrieve grounded data, and execute scoped actions with citations and auditing.Apache 2.0
- AlicenseNot gradedqualityDmaintenanceAn auditable memory, lifecycle, and governance server for AI agents, providing durable memories with provenance, lifecycle management, and guarded workflows through the Model Context Protocol.Apache 2.0