Advanced architecture
Digital twin
You can rehearse a rule on simulated people before you ship it. Four personas walk a short path. Turn on one rule and the predicted funnel changes. The people are written on the page. They are not visitors.
Example data, not real traffic.
A production twin would sample consented behavior. These four personas are fixed.
Understanding the labHow to use it and why you'd want to
Why you'd want to
You want to see a rule change on simulated people before you ship it. Turn the offer on and compare the two funnels, because these people are not visitors.
How to use it
- Read the four personas and who converts.
- Turn on the offer after the lab.
- Compare the done count before and after.
Loading the lab…
WalkthroughHow we built itShowHide
Example vendor setup is marked below. eVar and event numbers are examples. This lab does not call Adobe.
simulateTwin walks four written personas. With the rule off, only a persona who already reached packages converts. With the offer on, anyone who reached the lab also reaches done.
Write the people down
Ana and Dee reach the lab. Ben reaches packages. Cio stops at consent.
Apply one rule
offer-after-lab adds an offer and a conversion for personas who reached the lab.
Compare the funnels
The page runs the function twice and shows the done count before and after.
From the code
The offer converts people who reached the lab.
const offered = rule === "offer-after-lab" && reached.has("lab")Both funnels are on the page at once.
const before = simulateTwin("none")
const after = simulateTwin("offer-after-lab")Google and Adobe
Google queues advanced_lab_view after Accept. Adobe is an example of the same fields.
After Accept, this lab queues advanced_lab_view. The demo payload stays on the page. This site does not call Adobe.
Simplified shape of the object queued after Accept.
dataLayer.push({
event: "advanced_lab_view",
lab_id: "digital-twin",
})Example implementation. This site does not call Adobe. eVar174, prop174, and event174 are example variable numbers. In Launch, a data element reads the value and a rule sends it when the value changes. In the report suite, enable eVar174 with Most Recent allocation and expire it on the hit.
Example alloy payload. _example is a placeholder schema, not a real tenant.
alloy("sendEvent", {
xdm: {
eventType: "web.webinteraction.linkClicks",
_example: {
twinRule: "offer-after-lab",
},
},
})Example hit. eVar174 is hit-scoped in this example.
s.eVar174 = "offer-after-lab"
s.prop174 = "offer-after-lab"
s.events = "event174"
s.tl(true, "o", "advanced_lab_view")Translation
Each lab field, the GA4 name, and the example Adobe variable. Scope is the part that usually gets lost in the translation.
Lab id
GA4. Parameter lab_id on advanced_lab_view.
Adobe. Example eVar, expire on the hit.
Scope. Event. It names this lab, not the user.
Demo value
GA4. Not sent. Scores, proofs, and payloads stay on the page.
Adobe. Example prop. Do not copy the demo value.
Scope. Local state. It is not a user property.
Example counts
GA4. Not sent. Labeled example data is not a metric.
Adobe. Example event. Not sent.
Scope. A figure on the page, not a hit.
Consent
GA4. The view event is skipped until Accept.
Adobe. Example: skip the hit while consent is off.
Scope. A gate on the hit.
Recommended next
Why these picksReading path transitions…