Improvement after an intervention is not necessarily improvement caused by the intervention. Difference-in-differences (DiD) compares the change in an outcome for a treated group with the corresponding change for a comparison group. Under a suitable design, including a parallel untreated-trends assumption and no anticipation, that contrast can identify a treatment effect on the treated. It is the expected change without treatment that must be justified, not merely equality of the groups’ starting levels.
Vocabulary Coding and Engineering must preserve the baseline, counterfactual trend, comparison group and treatment timing behind the word improvement. This article builds a small fictional two-archive example, calculates a ten-percentage-point effect and tests the assumptions that make the calculation meaningful. We then propose a Z-layer record for time-indexed evidence. This is a research discipline for the Second Intelligence Pool, not a claim that every observed change can already be explained by AI.
- Before-and-after changes include trends unrelated to an intervention.
- A comparison group can help estimate the treated group’s counterfactual change.
- Parallel trends is a claim about untreated potential outcomes, not identical baseline levels.
- Anticipation, spillovers, changing composition and differential shocks can threaten the design.
- Past trend checks are useful but cannot prove the unobserved post-treatment counterfactual.
- Staggered adoption needs an estimator suited to timing and effect heterogeneity.
- Preserve the groups, times, scale, estimator and assumptions in any transferable effect claim.
Choose your reading route
Calculate a causal comparison · Challenge the comparison · Engineer an evidence record
Contents
Calculate a causal comparison · Sections 1–4
Challenge the comparison · Sections 5–8
Engineer an evidence record · Sections 9–12
1. A system improves, but why?
Imagine a fictional organisation introducing an AI-assisted checklist at archive A. Its documents pass an independent quality test 50% of the time before the change and 70% afterwards. An administrator concludes that the checklist caused a twenty-point improvement.
During the same interval, archive B continues using its previous procedure. Its passing rate rises from 60% to 70%. Perhaps a shared training programme, seasonal changes or a general improvement in document preparation helped both archives. The treated archive’s before-and-after result contains those possible background changes as well as the checklist’s effect.
A difference-in-differences design tries to use the comparison archive’s outcome change to construct the treated archive’s unobserved trend without the checklist. The design may be persuasive or unpersuasive depending on the comparison and assumptions. Wing, Simon and Bello-Gomez discuss why careful comparison selection and sensitivity checks are essential in applied DiD studies.
2. The four-cell calculation
Let A be the treated archive and B the untreated comparison archive. Let time zero be before the checklist and time one be after it. Define the outcome as the proportion of eligible documents that pass the same quality criterion within a fixed observation window. The following values are invented.
| Group | Before | After | Change |
|---|---|---|---|
| A: checklist adopted | 50% | 70% | +20 percentage points |
| B: usual procedure | 60% | 70% | +10 percentage points |
The DiD contrast is the change for A minus the change for B: 20 − 10 = 10 percentage points. The treated archive and comparison archive finish at the same passing rate, but the changes differ. A simple after-only comparison gives zero, which answers a different question.
The design can be useful even when starting levels differ. The key is whether the untreated changes would be parallel under the assumptions. A word such as baseline must identify both the time and the group; otherwise a receiving system cannot reconstruct the counterfactual comparison.
Contents · Previous section · Next section
3. Make the missing counterfactual explicit
Let Y(0) denote the outcome without the checklist. For the simplest two-group setup, parallel untreated trends says that the expected change in Y(0) for the treated group would equal the expected change in Y(0) for the comparison group. With no anticipation and a valid untreated comparison, B’s ten-point observed increase can represent that counterfactual change.
Under those assumptions, archive A’s estimated post-period passing probability without the checklist is 50% + 10% = 60%. Its observed rate with the checklist is 70%. Subtracting 60% from 70% yields the same ten-point estimate.
| Quantity | Probability |
|---|---|
| A before | 0.50 |
| Comparison change | +0.10 |
| A counterfactual without checklist | 0.60 |
| A observed after adoption | 0.70 |
| Estimated effect on treated | 0.10 |
This ten-point effect is not directly observed for the treated group. The receiving intelligence must retain its identification argument. The earlier article on Markov-equivalent causal models illustrates why different causal accounts can agree with observed data. Here the missing untreated trajectory is the central unobserved quantity.
Contents · Previous section · Next section
4. Two possible histories can fit the same observed table
Suppose an archive-specific technology upgrade would have increased A’s passing rate by 20 points even without the checklist. Archive B would still have improved by ten points. The observed table can be identical, yet the checklist’s actual effect for A could be zero.
In another hypothetical history, A would have improved by only five points without the checklist. Then the effect could be fifteen points. The observed group means do not choose among these possibilities on their own.
| Assumed untreated change for A | Counterfactual post rate | Implied effect |
|---|---|---|
| +5 points | 55% | +15 points |
| +10 points | 60% | +10 points |
| +20 points | 70% | 0 points |
Parallel trends supplies a particular identification restriction. An AI should explain why the ten-point counterfactual change is credible for this institution, not simply call the DiD formula objective. The companion article on sensitivity analysis develops a wider discipline for testing how conclusions depend on assumptions. This small example applies that discipline to a counterfactual trend.
Contents · Previous section · Next section
5. A pre-trend check is evidence, not a guarantee
Imagine two additional pre-policy periods. Archive A rises from 40% to 45% to 50%; archive B rises from 50% to 55% to 60%. Their observed pre-intervention changes match. This can support the credibility of the comparison, but it does not prove that their untreated trajectories would have continued in parallel after the policy.
A group-specific shock can appear exactly when treatment begins. A short historical series may also have little statistical power to detect important pre-existing differences. Selecting studies or specifications because a pre-trends test was not significant can itself affect inference.
Roth’s 2022 analysis explains limitations of conventional pre-trend testing. Report the size and uncertainty of pre-period contrasts, investigate institutional circumstances, and conduct appropriate sensitivity analyses. A non-significant test is not proof of the causal assumption.
Contents · Previous section · Next section
6. Anticipation and treatment timing
Suppose staff begin using the checklist’s principles a month before its formal launch because training materials were distributed in advance. The before period may already contain part of the intervention. A record that uses the announcement date, software deployment date and first substantive exposure interchangeably loses important timing information.
Alternatively, archive B could adopt the new principles shortly after archive A but before the post-period measurement ends. Then B may no longer provide the untreated comparison assumed by the simple design.
ZTime should record the decision date, public announcement, actual availability, exposure window and outcome measurement separately. The relevant start of treatment depends on the causal question. It must be justified rather than selected solely to produce an attractive graph.
Contents · Previous section · Next section
7. Spillovers can contaminate the comparison
Archive A and archive B may share a knowledge repository. If staff at B learn from the checklist used in A, B’s improvement could include a treatment spillover. Subtracting B’s increase would remove some of the effect that a system-wide policy evaluation should retain.
The preceding article on causal interference distinguishes direct, spillover and overall policy contrasts. In a DiD study, a comparison unit affected by the treated unit is not automatically an adequate untreated counterfactual. A researcher may instead need a different comparison, an explicitly modelled exposure, or an estimate with a more limited interpretation.
Do not assume that every connected organisation can be analysed as an independent observation. Shared shocks and dependence matter for both identification and statistical inference. If the intervention is assigned at the archive level, thousands of documents do not automatically provide thousands of independent treatment assignments.
Contents · Previous section · Next section
8. Staggered adoption requires more than one convenient coefficient
Suppose archive A adopts in January, archive B in March and archive C never adopts during the observation period. Effects may change with the time since adoption, and each archive may respond differently. A comparison between a newly treated unit and an already treated unit can be problematic if the latter’s outcomes already include a changing treatment effect.
Callaway and Sant’Anna (2021) develop approaches for multiple periods and differing treatment timing, including group-time treatment effect quantities and aggregation under stated assumptions. The intended estimand should determine the choice of comparison units and how effects are combined.
A result labelled the policy effect must therefore state whether it is a particular group’s effect at a particular time, an average by duration since treatment or another aggregation. Treating every estimate as interchangeable can hide heterogeneous outcomes and weight choices.
Contents · Previous section · Next section
9. A proposed Z-layer trend-comparison record
| Field | Meaning to preserve |
|---|---|
| Unit and group | Treated and eligible comparison units |
| Exposure timing | Adoption, anticipation and follow-up |
| Outcome | Common definition, scale and measurement window |
| Counterfactual | Untreated trend assumption and evidence |
| Estimand | Treated group and time or specified aggregation |
| Design checks | Composition, pre-trends, shocks and spillovers |
| Estimator | Comparison selection, adjustments and uncertainty |
| Provenance | Data versions and documented deviations |
| Authority | Separate causal evidence from deployment permission |
The W3C PROV framework can help retain the origin of each historical observation. It does not validate parallel trends. A receiving agent should see both the factual historical means and the assumptions used to infer the missing treated-group trajectory.
Record changes in the composition of each group. If the post-period denominator includes easier documents that were previously excluded, an apparent improvement may concern a changed population or criterion. Consistent arithmetic cannot restore the meaning of an inconsistent outcome definition.
Contents · Previous section · Next section
10. Zoom levels: the word improvement carries a history
At word scale, distinguish change from caused change. At unit scale, distinguish adoption from outcome. At institutional scale, identify groups, comparable conditions and common changes. At network scale, recognise that information and resource flows can affect comparison units. At civilisational scale, many changes occur together; temporal sequence alone rarely isolates one cause.
The Second Intelligence Pool could help investigate multiple historical patterns and candidate comparison groups. Its advantage would be to preserve the context of each comparison, surface counterexamples and identify data that could challenge the conclusion. It would not gain the ability to observe every unchosen history.
ZTime supports the proposed architecture by keeping a causal estimate attached to its exact periods, intervention version and available evidence. A later revision can coexist with the original evidence record rather than being silently inserted into the earlier analysis.
Contents · Previous section · Next section
11. A four-week causal-trend trial
Week one: reproduce the four-cell calculation and the three alternative untreated trajectories. Ask agents to explain why the observed data are compatible with different effects. Week two: create several pre-treatment observations and simulated post-treatment shocks. Compare a valid parallel-trends scenario with one that violates it.
Week three: introduce anticipated adoption, spillovers and staggered treatment in separate synthetic datasets. Require the agent to name the eligible comparisons and estimands; do not accept a generic two-period calculation as a complete staggered analysis.
Week four: pass the Z-layer record to an independent agent. Evaluate whether it reproduces the ten-point result, explains the causal restriction and refuses to treat a pre-trends check as proof. This is a proposed test programme, not a report of existing measured AI capability.
Contents · Previous section · Next section
12. The frontier: inherit evidence without inheriting a false history
Can AI use historical change to estimate a causal effect? Yes, under an appropriate quasi-experimental design. Does the calculation alone prove that a policy worked? No. The counterfactual trend and other conditions require justification. Does a credible estimate justify any subsequent expansion? No. Transport, costs, consequences and authority must also be considered.
Vocabulary Coding and Engineering should preserve the distinction between what happened and what would likely have happened under a specified alternative. A meaningful causal claim carries the history of the comparison, not just the headline number.
This is one way a portable intelligence system can accumulate knowledge about changing societies. It can reproduce the arithmetic, challenge the missing trajectory and revise its conclusions when new evidence warrants it.
Contents · Previous section · Sources
Primary sources and further reading
- Wing, Simon and Bello-Gomez (2018), Designing Difference in Difference Studies
- Callaway and Sant’Anna (2021), Difference-in-Differences with Multiple Time Periods
- Roth (2022), Pretest with Caution: Event-Study Estimates after Testing for Parallel Trends
- W3C PROV Overview
All numerical examples and proposed Z-layer studies are original teaching constructions, not results from deployed AI systems. Causal interpretations require the assumptions described in the article.
Editorial review: 1 December 2026.
