
In May I wrote about extending the CJA MCP with a semantic sidecar: a small MCP server that hands an LLM the business context CJA’s metadata can’t hold. Definitions, caveats, required filters, governance rules, one JSON entry per component. It works. Ask for this year’s orders and the LLM warns you about refunds before it runs the report.
But look closely at one field in that schema: related_components. It’s a comma-separated string, “orders, net_orders, refunds”. That’s a relationship trying to squeeze into a flat file. It says three things are related, but not how, not in which direction, and not why.
Once I started asking how things connect, rather than what one thing means, the flat file ran out. Which KPI depends on this metric? Which journey stage does it measure? If a developer changes this data layer variable, what breaks? The sidecar has no answer, because the answer isn’t on any single component.
This is the first post in a five-part series on the next step: modelling that context as a knowledge graph, with business meaning and technical metadata in one connected structure that people and LLMs can query. Everything in the series is built and running, and the code is public on GitHub. This post is about the why.
1. The meaning is scattered, and the connections live nowhere
Ask where the business meaning of your martech data lives and you’ll usually get four answers:
- CJA component metadata. Names, descriptions, maybe a tag. Technically accurate, rarely enough to interpret a number correctly.
- Journey knowledge. Which steps make up the login flow or the purchase funnel, and how each step is identified. Usually in the head of whoever built the first Workspace project for it.
- KPI definitions. Formula, target, owner. Somewhere in a slide deck from the last planning cycle.
- Data layer mappings. Which digitalData variable ends up in which XDM field and which component. In the implementation docs (or Solution Design Reference) if you’re lucky, only in the Tags property if you’re not.
Each of these pieces exists somewhere. What exists nowhere is the connection between them. Nobody writes down that the order conversion rate rolls up from the Order stage of the purchase journey, which is measured by the Orders metric, which is populated by digitalData.conversion.conversionFunnel.step. You reconstruct that chain when something breaks, and then you forget it again.
I’m usually the person doing the reconstructing. That doesn’t scale for me, and it scales even worse for an LLM. It has no hallway to walk down and no colleague to ask.
2. Where a flat file runs out
The obvious fix is a richer dictionary, and that’s what the sidecar is. Each component gets a full record: business, implementation and industry context, caveats, allowed and forbidden combinations, required filters, owner, governance level. It answers “what is X, and how should I use it?” very well. But every record is still about one component, and anything outside that record is just a string.
The questions that actually hurt are about relationships. Take digitalData.conversion.conversionFunnel.step. In my example ecommerce funnel, that one data layer variable populates all four funnel metrics: Product views, Product list adds, Checkouts and Orders. If a developer changes how it’s set, which journeys and KPIs are affected? The sidecar can’t tell you. There’s no KPI or journey record to point to, and related_components only links components to other components, as plain text. Add separate files for journeys, KPIs and mappings, plus the lookups to stitch them together, and you’re rebuilding a graph, just badly.
It gets worse when the same component means different things in different places. In the login journey, two stages are measured by the same dimension, web.webPageDetails.name. The only thing that tells them apart is the value you filter on: /customer/login for the Login stage, /customer/login/success for Login success. A row per component has nowhere to put that. The meaning isn’t on the component, and it isn’t on the stage. It sits on the relationship between them. That modelling problem gets its own post, because it’s the one that shaped the whole ontology.
| Flatfile | Graph | |
| Architecture | Stores isolated things | Stores things + how they connect |
| Connections | Implied (they happen to share a column) | Explicit (named, followable edges) |
| Context | Fixed statically to one component | Dynamic, existing on the relationship between stages |
| LLM Capability | Single-item lookup | Traces impact across entire business models. |
A flat file stores things. A graph stores things and how they connect, and the connections are where the questions live.
3. What the graph actually holds
First, a quick definition, because “knowledge graph” gets used for a lot of things. A knowledge graph stores facts as small three-part sentences: a thing, a relationship, another thing. Orders measures the Order stage. The Order stage rolls up to Order conversion rate. Orders is populated by digitalData.conversion.conversionFunnel.step. The things are nodes, the relationships are named edges between them, and every fact has the same shape, whether it’s about a KPI, a metric or a data layer variable.
The difference to a table is where the relationships live. In a spreadsheet, a connection is implied: two tabs happen to share a column, and you know to look one up in the other. In a graph, the connection is stored as a fact with a name, so you can follow it. Start at a KPI, go back to the stage that rolls up to it, on to the component that measures that stage, down to the variable that populates it. That’s all a query really is: walking edges.

What stops it from turning into a pile of arbitrary facts is the ontology, the rules for which kinds of nodes exist and which edges may connect them. Designing that is post 2. For now, the shape is enough.
The model is one chain, from the business question at the top down to the raw implementation at the bottom. Here it is for the Orders example, straight from the demo data in the repo:
| Node type | In the example | Question it answers |
| Requirement | Understand shop performance and drop-off | Why are we measuring this at all? |
| KPI | Order conversion rate (Orders / Product Views, target 0.20%) | Which number tells us whether it’s working? |
| Journey | Ecommerce purchase journey, four stages | Which user flow are we talking about? |
| Stage | Order, stage 4 of 4, rolls up to the KPI | Which step of that flow? |
| Component | Orders (metric) | Which CJA component measures that step, and what do I need to know before trusting it? |
| Data layer variable | digitalData.conversion.conversionFunnel.step | What in the implementation populates it? |
The important part is where the business meaning sits. The Orders component carries four fields that no platform metadata has a slot for: a definition (completed purchase orders), a caveat (includes orders later cancelled or refunded, so it’s not net of returns), context (the funnel’s terminal event and the numerator of the conversion rate KPI) and an owner (Digital Analytics).
Notice the owners along the chain, too. The KPI belongs to Ecommerce and Digital Marketing, the journey to Digital Marketing, the component to Digital Analytics. Three teams, one chain. In a spreadsheet those are three documents maintained by three people. In a graph they’re three nodes with edges between them.

This is where the graph does something the sidecar couldn’t. The sidecar returns the refund caveat when you ask about Orders. The graph returns it when you ask about the KPI, because it knows Orders feeds it. One SPARQL query (SPARQL is the query language for graphs, roughly what SQL is for tables), run through the graph’s MCP server, walks from every KPI down to the caveats of the components behind it:
SELECT ?kpi ?component ?caveat WHERE {
?stage m:rolls_up_to ?k .
?k rdfs:label ?kpi .
?meas m:measured_entity ?stage ;
m:measured_component ?c .
?c rdfs:label ?component ;
m:caveats ?caveat .
}
For Order conversion rate, it comes back with Orders and the refund caveat. Nobody had to know which metric to look up first.
4. What you can do with it
Graphs aren’t new in martech. Nobody would model an identity graph in a spreadsheet: ECIDs, CRM IDs and hashed emails linked across devices are a graph problem, and Adobe RTCDP treats them as one. Business meaning has the same shape. We just haven’t treated it that way. Once it’s in a graph, four use cases open up.
A semantic layer a LLM can use
The sidecar already covers the single-component lookup. The graph lets an LLM start from a business question instead, a requirement, a KPI or a journey, and walk down to the components and caveats that matter.
Impact analysis before something breaks
If digitalData.conversion.conversionFunnel.step changes, the graph tells you it feeds four components, which measure four stages, one of which rolls up to the order conversion rate. That’s one query, before the release, instead of a fallout report nobody can explain after it.
Journeys as first-class objects
Today a journey mostly exists as a Workspace project and some tribal knowledge about which filters define each step. In the graph, the login journey is a node with two ordered stages, each tied to a component and a filter value. You can query it, reuse its components elsewhere, and hand it to someone new without a walkthrough.
Governance where the data is described
Every component can carry an owner, an is_pii flag and free-text governance notes like consent requirements or retention rules. Nothing sets these automatically, and that’s deliberate. They’re judgement calls, just like caveats, and they belong next to the definition rather than in a separate compliance register.
5. The one decision that shapes everything else: reference, don’t duplicate
Adobe already has a graph of its own. AEP knows your schemas, datasets, identities, flows and audiences and how they connect, and the aepp Python library can export all of it as an RDF knowledge graph. Julien Piccini, who builds and maintains aepp, has written an excellent walkthrough of the AEP knowledge graph: the ontology, the URI patterns, and how to extract and extend it. It’s the best companion read for this series. Big thanks to Julien, both for the tool and for the conversations about how the two graphs should fit together.
So the first design question wasn’t “what do I model?” It was “what do I leave alone?”
The rule I settled on: anything Adobe already owns stays in Adobe’s graph, and my graph only points at it. A Component node doesn’t copy a schema definition. It carries references instead:
urn:cja:<dataViewId>:<componentId>
https://sandbox/<sandbox>/xdm/commerce.checkouts.value
The first points at the CJA component, the second at the XDM field behind it, in the same URI pattern aepp uses for XDM paths. Both are written automatically when components are synced from CJA. My graph doesn’t describe the field, it just points at the node Julien’s graph already has. When the schema changes, the source of truth hasn’t moved, and there’s no second copy quietly drifting out of date.
The same rule decided what’s not in the ontology. Segments and destinations are obvious candidates for nodes, and I left both out on purpose. AEP’s native graph already models audiences and flows. Adding them to mine would have meant keeping two versions of the same fact in sync, which is precisely the problem I’m trying to get rid of.
What’s left for my graph is exactly what AEP has no object for: a Requirement, a KPI, a journey stage, a caveat. That boundary between the two graphs gets a full post of its own later in the series.

Where this series goes next
The rest of the series moves from why to how:
- Why a knowledge graph for martech (this post)
- Designing the ontology, and the modelling problem nobody mentions: what to do when a relationship needs its own attribute, with the login journey as the proof case
- From model to turtle: RDF, SPARQL and two real funnels, code included
- Why I’m not just using AEP’s own knowledge graph: the reference pattern in detail
- Making the graph queryable by an LLM, and maintaining it: the MCP server and how content stays current
You don’t have to wait for the later posts to try it. The GitHub repo is a working context layer, not just sample code. One pip install gives you a local web UI that syncs components from CJA, lets you curate their definitions, caveats, owners and governance flags, and builds journeys from those components through a form. You can browse the resulting graph and run SPARQL against it in the browser. Next to it sits an MCP server with two read-only tools, run_sparql and get_ontology_schema, so any MCP client can query the same graph. And a skills page drafts a skill file for your agent, grounded in your actual ontology and in example queries run against your own data. There’s no database: everything is stored as plain turtle files you can read, diff and version. It ships with a demo workspace containing the ecommerce and login journeys from this post, so you can click through the whole loop before connecting your own CJA.
Before the next post, try one thing. Pick the KPI you report most often and trace it all the way down: which journey stage feeds it, which component measures that stage, what the caveats are, and which data layer variable populates it. Count how many places you had to look, and how many people you had to ask.
That number is the case for a graph.