Wave-6 item 7. The first cross-tool transform-graph schema in
the field. Per the wave-6 brief: every transform-graph tool
(Maltego, Flowsint, IntelOwl, sales-intel waterfalls like Clay
and Common Room, bio-KG expansion, e-discovery via SALI)
instantiates the same abstract shape — *an entity goes in, a
transform fans it out into typed entities + links + status
messages* — but **no published cross-tool schema exists**.
Maltego's TRX is XML and de facto one company's; W3C PROV-O is
the only published cross-domain provenance standard and nobody
in this corner uses it. We publish the open shape.
Surface:
- `Entity { id, entity_type, value, properties, weight }` —
Maltego-style typed entity. `entity_type` SHOULD be a stable
IRI (`maltego.IPv4Address`, `bio.Gene`, `sales.Company`).
Weight clamps to [0.0, 1.0].
- `Link { source, target, label, metadata }` — predicate-style
edge; consumers wanting RDF emit (source, label, target)
triples.
- `UiMessage { kind: { Inform | Debug | PartialError |
FatalError }, text }` — Maltego's status taxonomy.
- `TransformResult { entities, links, messages, activity }` —
what one transform returns.
- `ProvActivity { @id, @type: "prov:Activity", transform_id,
prov:wasAssociatedWith, prov:used[], started_at, ended_at }`
— PROV-O `Activity` record with JSON-LD `@id`/`@type` keys.
- `Transform` trait — `transform_id`, `expected_input_type`,
`run(input) -> TransformResult`. `apply(transform, input)`
helper enforces input-type check + appends input id to
`prov:used`.
- `ProvJsonLd<T>` wrapper — attaches `@context =
"https://www.w3.org/ns/prov-o-20130430"` for full PROV-O
RDF round-trip.
Honest scope (v1): types + PROV-O-aligned JSON-LD only. No
XML/TRX wire format (consumers wanting Maltego interop write a
thin adapter). Sync trait; async impls bridge their own runtime.
No transport — wire to jouleclaw-graph-mcp for agent traversal.
13 tests cover: apply rejects input-type mismatch + succeeds on
match + records input id in prov:used; Entity builders compose
+ weight clamps to [0,1]; ProvActivity carries @type + agent;
ProvJsonLd attaches context; full TransformResult JSON round-
trip; UiMessageKind round-trip all four variants; backend error
propagates; @id + @type serialize with at-prefix; empty
links/messages/entities omit from wire; Link round-trip.
Co-Authored-By: Claude Opus 4.7 <[email protected]>