Skip to content

Systems and records

Enterprise context graph dataset: what must stay linked from records

By SourceX Editorial · Reviewed by Noah Loul ·

10 sections

Short answer

When business records become a context graph, keep six links intact: one identity per real entity across systems, each event tied to its actors and objects, each fact tied to the source record that asserts it, valid time and recorded time, the authority and permission behind the fact, and the chain of corrections and deletions. Without them an agent remembers stale, unsourced or forbidden facts and cannot prove why it acted.

Agent run

Enterprise context graph

This page covers enterprise context graph dataset: what must stay linked from records.Illustrative

Key takeaways

  • Treat every remembered fact as a dated, sourced, permission-bound claim, not as a timeless truth.
  • Every edge needs the source record id, valid-from and valid-to times, the time it was recorded, the authority that asserted it and who may see it.
  • Corrections and deletions must be linked edges, not silent overwrites, so an agent can explain what it believed and when.
  • Many systems overwrite or expire history, so the graph has to capture change history before it is lost.
  • A status field such as resolved or approved is not an outcome; link the record that proves the result.
  • A dataset is ready when a reviewer can rebuild any decision from linked records alone.

Which relationships must survive when business records become a context graph?

Six relationships must survive: entity identity across systems, event participation, source provenance, valid and recorded time, authority and permission, and correction and deletion history. Lose any one and the graph stops being memory an agent can rely on; it becomes a pile of plausible facts.

At a glance

Which relationships must survive when business records become a context graph

An enterprise context graph is a graph of the people, organizations, objects and events in a company's systems, built so an AI agent can retrieve what is true for a task at a given time. Unlike a static knowledge graph, it changes constantly: customers move, terms are renegotiated, tickets are reopened, a record is corrected or deleted. The relationships above are what let the graph change without lying about the past.

This page builds one small example end to end. The example is illustrative, but every field in it maps to something real systems store, and the schema can be used as is for a dataset specification.

  • Identity: one node per real customer, product or employee, with a crosswalk to each system's id
  • Participation: each event linked to who acted, on what, through which system
  • Provenance: each fact linked to the record that asserts it and the extraction that produced it
  • Time: valid-from and valid-to in the business world, plus when the graph recorded it
  • Authority and permission: which system or role is authoritative for the fact, and who may read it
  • Corrections and deletions: what superseded what, and what was removed, when and why

Why is a context graph more than a knowledge graph of facts?

Because an agent acts on facts at a point in time, the graph has to answer what was true then and what the system knew then, which a graph of current facts cannot. Two timelines are needed, and the difference between them is often the whole story.

The Zep paper on a temporal knowledge graph for agent memory describes this as a bi-temporal model: one timeline orders events as they happened, and a second orders them as the system ingested them. Its graph engine handles changing information through temporal extraction and edge invalidation, marking superseded facts rather than discarding them.

Business records add two dimensions that conversational memory often lacks. Facts have an authority: the ERP customer master, not a sales rep's note, decides credit terms. And facts have permissions: an HR record may be true and still not readable by a sales agent. A context graph built from records has to carry both on every edge.

What does a provenance-preserving entity and event graph look like?

It has three kinds of nodes, entities, events and source records, and every assertion between them carries provenance, time, authority and permission. The W3C PROV ontology gives standard names for most of this: an Entity, an Activity that generates or uses entities, an Agent responsible for them, and relations such as wasDerivedFrom, wasAttributedTo, generatedAtTime and invalidatedAtTime.

Use the schema below as a dataset specification. Property names are suggestions; what matters is that each one is present and populated from a record, not inferred.

What does a provenance-preserving entity and event graph look like?
Graph elementRequired propertiesPopulated fromPROV mapping
Entity node (customer, product, employee)graph id, type, crosswalk of system ids, merge historyCRM, ERP and HR master recordsprov:Entity
Event node (order, ticket update, approval)event id, type, occurred_at, system, case idTransaction tables, audit logs, ticket historyprov:Activity
Actor linkactor id, role at the time, acting systemUser tables, approval recordsprov:wasAssociatedWith, prov:Agent
Fact edge (entity has attribute or relation)value, valid_from, valid_to, recorded_at, source record idField values and field historyprov:generatedAtTime, prov:invalidatedAtTime
Source linksystem, table or object, record id, extraction run idExtraction pipeline metadataprov:wasDerivedFrom
Authority and permissionauthoritative system or role, access label, permitted usesData ownership register, access policyprov:wasAttributedTo
Correction or deletion linksuperseded edge id, reason, requester role, timeChange logs, correction and erasure ticketsprov:wasRevisionOf, prov:wasInvalidatedBy

Worked case: should the agent apply net-60 terms? (illustrative)

This case is illustrative; the company, records and dates are invented. A wholesale distributor's order agent receives a new order from a customer, Customer C-112, on March 12. The task is to decide whether to apply net-60 payment terms, which the customer's buyer requests in the order email.

Starting state: the CRM account shows net-60 in a free-text note from a sales rep dated last July. The ERP customer master shows net-30, changed from net-60 on February 3 by a finance user. A credit review record dated February 2 records two late payments and the decision to shorten terms.

Linked evidence: the graph holds the net-60 fact edge with valid_to February 3 and an invalidation link to the finance change, the net-30 edge with valid_from February 3 and authority set to the ERP customer master, and a derivation link from that edge to the credit review record. The CRM note is a separate edge with authority set to sales, which the rule ranks below finance for payment terms.

Rule and decision: payment terms come from the ERP customer master; requests for longer terms route to credit review. The agent applies net-30, cites the ERP record and the credit review, and opens a credit review task for the buyer's request instead of promising net-60.

Verified outcome: the outcome is not the agent's reply or the order status. It is the invoice posted with net-30 terms and the payment received against it, both linked to the order event. Until the payment record exists, the graph marks the outcome as pending.

Worked case: should the agent apply net-60 terms? (illustrative)
EdgeValid timeSource and authorityStatus at March 12
C-112 terms = net-60Until February 3ERP customer master, financeInvalidated by finance change
C-112 terms = net-30February 3 to openERP customer master, financeCurrent and authoritative
Note: customer on net-60Last July, never closedCRM note, salesCurrent but not authoritative for terms
Terms shortened after late paymentsFebruary 2Credit review record, credit teamDerivation source for net-30

Flattening produces confident wrong actions. Suppose the same records are loaded as current facts only: one customer node, one terms attribute, last write wins. The CRM sync ran after the ERP change, so the attribute reads net-60.

The agent applies net-60 and sends a polite, plausible confirmation. The order status reads approved. Nothing in the flattened graph shows that finance had shortened terms, why, or that the CRM note was never authoritative. The error surfaces weeks later as a late payment, and no one can reconstruct what the agent believed or why.

Each missing link maps to a specific failure: no valid time means stale facts look current, no authority means the loudest system wins, no invalidation link means corrections vanish, and no outcome link means a status field passes for success.

When should the agent update, forget or stop using a remembered fact?

Update when an authoritative source supersedes a fact, forget when a deletion obligation or retention limit applies, and stop using a fact when its permission is withdrawn or sources of equal authority conflict. Each action should leave a linked record so the graph can explain it later.

Personal data adds legal triggers. The GDPR gives people a right to rectification of inaccurate data in Article 16 and a right to erasure in Article 17, subject to listed exceptions, and Article 19 requires controllers to tell recipients about rectification or erasure. Counsel decides how these apply to a given graph; the engineering point is that the graph needs correction and erasure links and a list of where each fact was sent.

When should the agent update, forget or stop using a remembered fact?
TriggerAgent actionGraph changeEvidence kept
Authoritative source changes the valueUse the new value from its valid_fromClose old edge, open new edge, link invalidationSource record id and change time
Lower-authority source disagreesKeep the authoritative value; flag the conflictAdd a conflict edge between the two factsBoth source records
Sources of equal authority disagreeStop using the fact; escalate to the ownerMark both edges disputedEscalation task id
Correction request acceptedUse the corrected valueSupersede with reason correctionRequest record and approver role
Erasure request or retention expiryStop retrieving the fact and its derived summariesDelete content, keep a minimal tombstone if policy allowsDeletion record and recipient list
Permission withdrawn or role changedStop surfacing the fact to that roleUpdate access label on the edgePolicy change record

What proves the agent chose correctly, and what proves it worked?

The decision is proved by the rule, the authoritative fact edges it read and their source records; the outcome is proved by a downstream record the agent did not write. Link both, because a status field or a final message only shows that something was claimed.

Good outcome records are ones another system produces: a payment posted against an invoice, a shipment scan, a ticket that stays closed for an agreed period, a refund in the ledger. Pair each task type with its outcome record when the dataset is specified, and mark tasks whose outcome record is missing as unverified rather than successful.

How do you keep history when source systems overwrite it?

Capture change history at the source before it expires, because many systems keep only the current value or keep history for a limited time. The graph can only link what was recorded.

Check each system's history mechanism. Salesforce's help documentation says field history tracking starts only when it is turned on for a field and is not retroactive, and that history is retained about 18 months in the interface and up to 24 months through the API. SQL Server system-versioned temporal tables, by contrast, move the previous row version to a history table on every update and delete, and a FOR SYSTEM_TIME AS OF query reconstructs the table at a past moment.

Record the extraction itself as provenance. OpenLineage models pipelines as runs, jobs and datasets with facets, and its dataset metadata updates can describe schema, ownership or documentation changes. Storing the run id on every source link lets a reviewer trace a fact edge back to the exact extraction that produced it.

What should an enterprise context graph dataset include before you accept it?

Accept the dataset when a reviewer can rebuild any sampled decision from linked records alone. The checklist below turns that into items a supplier can deliver and a buyer can test on a sample of 50 to 100 cases.

Checklist · 9 items

  1. Entity crosswalk with merge and split history for every system id
  2. Fact edges with valid_from, valid_to and recorded_at populated from records, with null meaning still valid, documented
  3. Source record id and extraction run id on every edge
  4. Authority ranking per fact type, written down and applied
  5. Access labels and permitted uses per edge, matching the license
  6. Correction, conflict and invalidation edges kept, not overwritten
  7. Deletion manifest listing removed facts by id and date, without their content
  8. Outcome records linked to task events, with unverified outcomes marked
  9. A time-semantics note explaining time zones, backdated entries and late-arriving records

0 of 9 ticked. Tick each item as you go.

Where can context graph data be sourced, and what should the request carry?

Context graph data has to come from operating companies' own systems, because the links that matter live in their field histories, approvals and outcome records. SourceX finds such records on request from U.S. businesses rather than from a stock catalog; its request form asks for scope, volume, language, format, timing and licensing needs, and the schema and checklist above can be attached to it.

On the supplier side, the company approves the scope and terms and signs before any data is delivered, so permitted uses and access labels can be agreed before the graph is built rather than reverse-engineered afterward.

What belongs in a minimal decision packet cut from the graph?

Seven elements, each read from the graph as of the moment the decision was committed: the decision point, the decider and authority, the facts in force, the rule version, the options that were open, the action taken and the outcome, with the outcome kept on the label side. The acceptance checklist above lists edge properties; the packet is the subgraph one decision needs, and the table says what to do when an element is missing.

Options are the element this page's schema does not yet carry. MADR, an open template for architecture decision records in software teams, keeps Considered Options as one of the three mandatory sections of its minimal template, next to Context and Problem Statement and Decision Outcome. Business systems rarely store options as data, so link option nodes to the decision event where the source has them, such as quotes compared or approve with conditions versus deny, and otherwise record that options were not captured. In the net-60 case the options were to apply net-60, apply net-30 or route the request to credit review; the rule ruled out the first, and the agent chose the second and opened the third.

What belongs in a minimal decision packet cut from the graph?
ElementRead from the graph asUsually missing becauseIf missing
Decision pointThe commit event node; decision_at is its recorded timeOnly a status field changed, with no event rowDrop: without decision_at the window cannot be cut
Decider and authorityActor link plus the authority edge valid at decision_atOnly the person's current role is storedKeep for outcome grading; exclude from authority tests
Facts in forceFact edges recorded by decision_at and not yet invalidated at that timeOnly current values were exportedDrop until history is rebuilt; never substitute current values
Rule versionThe policy or rule edge valid at decision_atThe rule exists only as today's policy textMark rule unknown; never attach today's text
Options openOption nodes linked to the decision event, chosen and rejected, with reasonsOnly the chosen option was storedKeep for imitation; exclude from tests of weighing options
Action takenEdges written by the commit eventThe action was inferred from later stateFlag the action as inferred
OutcomeA downstream record the decider did not write, read at a fixed horizonHorizon not yet elapsed, or the record is not linkedKeep as unverified; label side only

Which edges fall inside a decision's window?

An edge enters a decision's inputs only if it was recorded at or before decision_at; being true earlier by valid time is not enough. Each decision gets three boundaries: a lookback start set by the task owner, such as the policy versions and the year of account history the decider would normally consult; the decision cut at decision_at; and an outcome horizon after it, such as the payment due date plus a grace period, fixed per task type before extraction.

The reason is the standard definition of leakage. scikit-learn's documentation describes data leakage as using information that would not be available at prediction time when building a model, which produces overly optimistic performance estimates and poorer performance on new data. A context graph leaks less visibly than a table, because its corrections are linked rather than overwritten: the corrected edge is right there to be picked up, and only recorded_at says whether the decider could have seen it.

Before and after, on a variant of the net-60 case (illustrative): suppose finance had entered the change to net-30 on March 13, backdated to a valid_from of February 3. A packet filtered by valid time shows net-30 as current on March 12, so an agent that applied net-60 looks wrong. A packet filtered by recorded time shows what the ERP showed on March 12, net-60, and the agent that applied it acted correctly on the information available. The hindsight version rewards knowledge nobody had and penalizes the correct behavior.

Cases whose outcome horizon has not elapsed at extraction are left out of outcome-graded sets rather than labeled as failures. Run these checks on every packet before delivery and report how many packets each one rejects.

Which edges fall inside a decision's window?
CheckRule on every packetLeak it catches
Recorded before the cutEvery input edge has recorded_at at or before decision_atThe invoice, payment or credit review answer that came later
Invalidations as known thenAn edge invalidated after decision_at appears in the inputs as currentA correction applied to a decision made before it
Backdated entriesEdges with valid_from before decision_at but recorded_at after it are excluded and countedA late entry that looks contemporaneous by valid time
Derived nodesSummaries and embeddings are built only from edges inside the windowAn account summary regenerated last month that mentions the late payment
Visible to the deciderEdges whose access label at decision_at excluded the decider's role stay out of imitation inputsA credit note the order desk could not open
Outcome isolationOutcome edges and the decision's own action edges appear only in the label recordPosted invoice terms in the inputs of the decision that set them

How do you test that a reproducible business decision dataset really reproduces the decision?

Give two reviewers who have not seen the outcome only the packet and the rule, ask each to state the decision and cite the edges used, and count a case as reproduced when both reach the recorded decision from in-window edges. Anthropic's engineering guidance on agent evals, published January 9, 2026, counts a task as good when two domain experts, each working without the other, would return the same pass or fail verdict; a decision packet should clear that bar too.

Report reproduced cases over sampled cases for each task type, with the count for each code. If reviewers fail on complete packets, the missing piece is usually an unwritten rule or a judgment call, and the owner has to write the rule down before more records will help. No results from running this test on supplier records are published yet; the rate is a quantity to measure on a sample, not a figure to assume. SourceX sources records on request rather than from stock, so attaching the element table, the window boundaries and these codes to a request lets each candidate company's systems be checked against them early.

When a reviewer cannot reproduce a decision, code the gap instead of guessing at it. One code per missing element means a supplier's sample report shows why each case failed, not only how many did; each code below carries its keep, fix or exclude rule.

  • Not recorded: the source never held it, such as an approval given by phone. Keep the case only if the packet states the gap and it was not the deciding fact.
  • Recorded, not linked: the record exists without an edge to the decision. Fix the crosswalk and run the case again.
  • Recorded after the cut: it exists but was entered after decision_at. Keep it out of the inputs; if it was the deciding fact, the decider knew something the records do not show, so exclude the case from training and keep it for audit.
  • Withheld: hidden by an access label or removed under the deletion manifest. Keep the tombstone and never back-fill the content.
  • Rule unknown: no rule version valid at decision_at can be found. Use the case for outcome grading only.

Sources for this section

  • MADR's minimal template, which contains only its mandatory sections, consists of Context and Problem Statement, Considered Options and Decision Outcome. Source
  • scikit-learn's documentation defines data leakage as using information that would not be available at prediction time when building a model, which yields overly optimistic performance estimates and poorer performance on novel data. Source
  • Anthropic's agent-eval guidance (January 9, 2026) says a good task is one where two domain experts would independently reach the same pass or fail verdict. Source

Frequently asked questions

What is an enterprise context graph?

It is a graph of the entities and events in a company's systems, built so an AI agent can retrieve what was true for a task at a given time. Each fact carries its source record, time, authority and permission, so the agent can use, update or stop using it correctly.

How is it different from an enterprise knowledge graph?

A knowledge graph often stores current facts and relations for grounding or completion. A context graph for agent memory must also keep valid and recorded time, which source is authoritative, who may see each fact, and how facts were corrected or deleted.

Why do I need two timestamps on every fact?

Valid time says when the fact was true in the business; recorded time says when the system learned it. Without both, you cannot tell whether an agent acted on stale data or on the best information it had at that moment.

Should deleted facts be removed from the graph entirely?

Content subject to a deletion obligation should be removed, including derived summaries. Many teams keep a minimal tombstone with an id and date so the deletion itself is auditable, where policy and counsel allow it.

How many cases are enough to test a context graph dataset?

Start with a sample of 50 to 100 decisions across task types and check whether each can be rebuilt from linked records alone. Any case that cannot is a specification gap to fix before scaling up.

Sources

  • The W3C PROV ontology defines Entity, Activity and Agent and relations such as wasDerivedFrom, wasRevisionOf, wasAttributedTo, wasAssociatedWith, wasInvalidatedBy, generatedAtTime and invalidatedAtTime. Source
  • The Zep paper describes a bi-temporal model with one timeline for event order and one for ingestion order, and handles changing facts through temporal extraction and edge invalidation. Source
  • SQL Server system-versioned temporal tables move previous row versions to a history table on update and delete, and FOR SYSTEM_TIME AS OF reconstructs past state. Source
  • Salesforce field history tracking starts when it is turned on for a field and is not retroactive; history is retained about 18 months in the interface and up to 24 months via the API. Source
  • OpenLineage models runs, jobs and datasets with facets, and dataset metadata updates can describe schema, ownership or documentation changes. Source
  • The GDPR provides a right to rectification (Article 16), a right to erasure with exceptions (Article 17) and a duty to notify recipients of rectification or erasure (Article 19). Source

Tell us what data you need

Share scope, volume, format, timing and licensing needs. Datasets are sourced on request.

See if your company qualifies