Build pillar · runtime-cohort agent
How to build runtime-readable behavioral cohorts for multi-location AI agents
TypeScript discriminated-union per-cohort schema + JSON Schema Draft 2020-12 + OpenAPI 3.1.0 + AsyncAPI 2.6 + Apache Avro + Protobuf + Confluent Schema Registry + Apicurio per-cohort runtime schema registry + LaunchDarkly + Statsig + Optimizely Feature Experimentation + Split.io + Flagsmith + Unleash + Eppo + GrowthBook + ConfigCat + Vercel Edge Config feature-flag + Open Policy Agent (OPA) + Rego + Cedar + AWS Verified Permissions + Casbin per- cohort policy + Segment Personas + RudderStack + Tealium + Lytics + mParticle CDP + Feast + Tecton + Vertex AI Feature Store + SageMaker Feature Store + Databricks Feature Store + Hopsworks online/offline feature-store + Redis + Memcached + Hazelcast + Aerospike + Vercel KV + Cloudflare KV + AWS DynamoDB Accelerator DAX + Upstash Redis edge-cache + scikit-learn + XGBoost + LightGBM + CatBoost + PyMC + NumPyro + Stan + DoWhy + EconML + causalml + R MatchIt propensity-score-matching ship per- account flat behavioral-cohort primitives. The Define + Compute + Expose + Audit skill bundle on the runtime- cohort agent sits above the schema-registry + feature- flag + policy-engine + CDP + feature-store + edge-cache + causal-inference + warehouse substrate and writes a per-customer per-cohort canonical runtime-readable record with named regulatory anchors covering runtime cohort- schema + sub-millisecond cohort-assignment + sub-100ms feature-vector + per-customer RFM + CLV + per-cart-abandon + per-session behavior + propensity-score matching + A/B test framework (Bayesian + frequentist + sequential + bandit + Thompson + UCB + SPRT) + per-cohort consent (GDPR Article 22 automated decision-making + Article 17 right-to-erasure + Article 16 right-to-rectification + Article 21 right-to-object + CCPA opt-out + per-state biometric + Apple ATT iOS 14.5+ + Google Privacy Sandbox Topics + Attribution Reporting + Protected Audience API) + TCPA + CAN-SPAM + GLBA + HIPAA + EU AI Act Article 50 + SOX 302/404/906.
Published January 14, 2027 · 3,200 words
The 4-skill bundle on the runtime-cohort agent
One agent. Four coordinated skills. The Define + Compute + Expose + Audit bundle runs above the schema-registry + feature-flag + policy-engine + CDP + feature-store + edge-cache + causal-inference + warehouse substrate and writes one canonical per-customer per-cohort runtime- readable record.
Define
Per-cohort schema: TypeScript discriminated-union + JSON Schema + AsyncAPI 2.6 + Avro + Protobuf + Confluent Schema Registry. Per-cohort feature-flag (LaunchDarkly + Statsig + Optimizely + Split.io + Flagsmith + Unleash + Eppo + GrowthBook + Vercel Edge Config). Per-cohort policy (OPA Rego + Cedar + AWS Verified Permissions + Casbin). Per-cohort latency budget (sub-millisecond cohort-assignment + sub-100ms feature-vector). Per-cohort consent-requirement (GDPR Article 6/7/22/17/16/21 + CCPA opt-out + per-state biometric + Apple ATT + Privacy Sandbox).
Compute
Per-cohort feature-engineering: per-customer RFM (recency + frequency + monetary) + CLV + churn- probability + per-product behavioral + per-cart-abandon + per-checkout-completion + per-session depth + scroll + time + form + exit-intent + bounce + pageview- velocity + NPS + CSAT + CES. Feature-store (Feast + Tecton + Vertex AI + SageMaker + Databricks + Hopsworks) online + offline. Per-cohort propensity- score matching (PSM + CEM + GenMatch + IPTW via DoWhy + EconML + causalml + R MatchIt).
Expose
Per-cohort runtime exposure via edge-cache (Redis + Memcached + Hazelcast + Aerospike + Vercel KV + Cloudflare KV + DAX + Upstash Redis). Per-cohort A/B test framework: Bayesian + frequentist + sequential + multi-armed bandit + contextual bandit + Thompson sampling + epsilon-greedy + UCB + per-test peeking- correction + SPRT + Gittins index. Per-cohort observability (OpenTelemetry + Prometheus + log + incident-routing). Per-cohort severity P0-P4.
Audit
Per-customer per-cohort WORM runtime-readable record: per-cohort schema snapshot + per-cohort assignment + per-cohort feature-vector + per-cohort consent-state + per-anchor gate-pass + AI-ML provenance + EU AI Act FRIA + GDPR Article 22 automated decision-making log + Article 17 right-to-erasure propagation log. Retention: 7-year FTC + 7-year IRS + 7-year HIPAA + 7-year GLBA + 7-year state bar + 6-year SEC + 3-year FINRA + 7-year SOX + GDPR Article 30 + EU AI Act Article 12 + SOC 2 CC7/CC8.
The real ecosystem this sits above
Define + Compute + Expose + Audit does not replace schema-registry, feature-flag, policy-engine, CDP, feature-store, edge-cache, causal-inference, or warehouse substrate. It sits above them and writes one canonical per-customer per-cohort runtime-readable record.
Schema-registry + feature-flag + policy
- TypeScript discriminated-union per-cohort schema
- JSON Schema Draft 2020-12 + AsyncAPI 2.6 + Avro + Protobuf
- LaunchDarkly + Statsig + Optimizely + Split.io + Flagsmith
- Unleash + Eppo + GrowthBook + Vercel Edge Config
- OPA Rego + Cedar + AWS Verified Permissions + Casbin
CDP + feature-store + causal-inference
- Segment Personas + RudderStack + Tealium + Lytics + mParticle
- Feast + Tecton + Vertex AI Feature Store + SageMaker FS
- Databricks Feature Store + Hopsworks online/offline
- scikit-learn + XGBoost + LightGBM + CatBoost
- DoWhy + EconML + causalml + R MatchIt propensity-score
Edge-cache + warehouse + governance
- Redis + Redis Cluster + Memcached + Hazelcast + Aerospike
- Vercel KV + Cloudflare KV + DAX + Upstash Redis
- Snowflake + BigQuery + Databricks + Redshift + ClickHouse
- Iceberg + Hudi + Delta Lake time-travel
- Apple ATT iOS 14.5+ + Google Privacy Sandbox Topics
Compliance overlay
Five anchors run per-customer per-cohort before any cohort assignment exposes to runtime AI agent. The first anchor is operationally distinctive: runtime-readable cohort-schema + sub-millisecond cohort-assignment + sub- 100ms feature-vector + RFM + CLV + per-cart-abandon + per-session behavior + propensity-score matching + A/B test framework converge on every per-cohort runtime decision.
Anchor 1: Runtime cohort-schema + sub-millisecond cohort-assignment + sub-100ms feature-vector + RFM + CLV + cart-abandon + per-session behavior + PSM + A/B framework (operationally distinctive)
Runtime-readable behavioral-cohort schema (TypeScript discriminated-union + JSON Schema + AsyncAPI 2.6 + Apache Avro + Protobuf + per-cohort feature-flag + per-cohort OPA Rego + Cedar + Casbin). Per-cohort runtime computability (sub-millisecond cohort- assignment + sub-100ms feature-vector + edge-cache + precomputed-feature-store + online-feature-store + offline-feature-store + Feast + Tecton + Vertex AI + SageMaker + Databricks Feature Store + Hopsworks). Per-cohort feature-engineering (per-customer RFM + CLV + churn-probability + per-product behavioral + per-cart-abandon + per-checkout-completion + per- session depth + scroll-depth + time-on-page + form- completion + exit-intent + bounce + pageview-velocity + NPS + CSAT + CES). Per-cohort propensity-score matching (PSM + CEM + GenMatch + IPTW). Per-cohort A/B test framework (Bayesian + frequentist + sequential + multi-armed bandit + contextual bandit + Thompson + epsilon-greedy + UCB + per-test peeking-correction + SPRT + Gittins index).
Anchor 2: FTC + Lanham + Sherman/Clayton
FTC Section 5 + Pfizer 1972 + CFPB UDAAP + Lanham + USPTO + Robinson-Patman + Sherman + Clayton.
Anchor 3: TCPA + CAN-SPAM + GLBA + HIPAA + FINRA + per-state biometric
TCPA 47 USC 227 when SMS retargeting + CAN-SPAM email retargeting + GLBA financial-customer cohort + HIPAA 45 CFR 164.502/504/514 health-customer cohort + COPPA + per-state biometric (BIPA + CUBI + Washington biometric + Maryland HB1093) + FINRA Rule 2210 + SEC Regulation FD.
Anchor 4: EU AI Act + GDPR Article 22/17/16/21 + Apple ATT + Google Privacy Sandbox
EU AI Act Article 50 transparency when AI-ML cohort- assignment + Article 13/14/15 + Annex III when AI-ML cohort-assignment drives personalization + Article 6/27 FRIA + DSA + DMA. GDPR Article 6 legal-basis + Article 7 consent + Article 22 automated decision- making + Article 17 right-to-erasure + Article 16 right-to-rectification + Article 21 right-to-object + LGPD + DPDP + PIPEDA + Quebec Law 25 + CCPA + CPRA + 18-state + Apple ATT iOS 14.5+ + Google Privacy Sandbox Topics + Attribution Reporting + Protected Audience API.
Anchor 5: Accessibility + SOX + WORM retention
WCAG 2.2 AA + ARIA + EAA + ADA Title III + Section 508. SOX 302/404/906 when public-company per-cohort material + COSO + Exchange Act 13(b)(2) + SEC Reg S-K. NIST AI RMF + ISO 42001 + ISO 27001 + SOC 2 Type II. Per-vendor LLM zero-retention + per-source DPA + per- API rate-limit. Storage: AWS S3 Object Lock + Azure Blob immutable + GCS + Wasabi WORM. Retention: 7-year FTC + 7-year IRS + 7-year HIPAA + 7-year GLBA + 7- year state bar + 6-year SEC + 3-year FINRA + 7-year SOX + GDPR Article 30 + EU AI Act Article 12 + SOC 2 CC7/CC8.
6-workstream reporting cycle
Every two weeks during a Tier 3 Fractional CMO engagement, six workstreams report against the pre-engagement baseline. No personalization accuracy claims. Process commitments only.
- 1. Per-portfolio per-customer per-cohort runtime- readable cohort coverage. Customers covered + cohorts defined + feature-vectors computed + consent- states tracked.
- 2. Define per-cohort schema definition flow. TypeScript + JSON Schema + Avro + Protobuf + feature- flag + OPA/Cedar/Casbin + runtime-target latency budget + consent-requirement linking absorbed.
- 3. Compute per-cohort feature-engineering flow. RFM + CLV + cart-abandon + per-session behavior + propensity-score matching + feature-store (Feast + Tecton + Vertex AI + SageMaker + Databricks + Hopsworks).
- 4. Expose per-cohort runtime exposure flow. Edge-cache + A/B test framework (Bayesian + frequentist + sequential + bandit) + observability + incident- routing.
- 5. Regulatory-defense audit coverage. Runtime cohort-schema + feature-vector + RFM + CLV + propensity-score + A/B framework + GDPR Article 22/17/16/21 + CCPA opt-out + per-state biometric + Apple ATT + Privacy Sandbox + TCPA + CAN-SPAM + GLBA + HIPAA + EU AI Act Article 50 + SOX.
- 6. FBC feedback-loop pattern-learning. Per-customer per-cohort realized-vs-predicted assignment + per-A/B test peeking retrospective + per-consent enforcement retrospective.
FAQ
- What is runtime-readable behavioral cohorts for multi-location AI agents — and what is the runtime-cohort-schema-times-sub-100ms-feature-vector-times-RFM-CLV-times-cart-abandon-times-per-session-behavior-times-propensity-score-matching-times-GDPR-Article-22-times-CCPA-opt-out-times-Apple-ATT problem distinctive to this skill?
- A DTC ecommerce operator with $5M-$50M annual revenue ships per-customer per-cohort runtime-readable cohort assignments for personalization + recommendation + cart-recovery + retention. Per-millisecond latency budget at edge requires runtime-readable cohort schema + sub-millisecond cohort-assignment + sub-100ms feature-vector compute. The four-skill bundle on the runtime-cohort agent — Define, Compute, Expose, Audit — sits above the schema-registry + feature-flag + policy-engine + CDP + feature-store + edge-cache + causal-inference + warehouse substrate (TypeScript + JSON Schema + Apache Avro + Protobuf + Confluent Schema Registry + LaunchDarkly + Statsig + Optimizely + Split.io + Flagsmith + Unleash + Eppo + GrowthBook + Vercel Edge Config + OPA Rego + Cedar + Casbin + Segment Personas + RudderStack + Tealium + Lytics + mParticle + Feast + Tecton + Vertex AI Feature Store + SageMaker Feature Store + Databricks Feature Store + Hopsworks + Redis + Memcached + Vercel KV + Cloudflare KV + DAX + scikit-learn + XGBoost + PyMC + Stan + DoWhy + EconML + R MatchIt) and writes a per-customer per-cohort canonical runtime-readable record. The operationally distinctive anchor: runtime-readable behavioral-cohort schema (TypeScript discriminated-union + JSON Schema + AsyncAPI 2.6 + Avro + Protobuf + per-cohort feature-flag + per-cohort OPA Rego + Cedar + Casbin policy) + per-cohort runtime computability (sub-millisecond cohort-assignment + sub-100ms feature-vector + edge-cache + precomputed-feature-store + online-feature-store + offline-feature-store + Feast + Tecton + Vertex AI + SageMaker + Databricks Feature Store + Hopsworks) + per-cohort feature-engineering (per-customer RFM + CLV + churn-probability + per-product behavioral + per-cart-abandon + per-checkout-completion + per-session depth + per-session scroll-depth + per-session time-on-page + per-session form-completion + per-session exit-intent + per-session bounce + per-session pageview-velocity + per-customer NPS + CSAT + CES) + per-cohort propensity-score matching (PSM + CEM + GenMatch + IPTW) + per-cohort A/B test framework (Bayesian + frequentist + sequential + multi-armed bandit + contextual bandit + Thompson sampling + epsilon-greedy + UCB + per-test peeking-correction + SPRT + Gittins index) + per-cohort consent (GDPR Article 6 legal-basis + Article 7 consent + Article 22 automated decision-making consent + Article 17 right-to-erasure + Article 16 right-to-rectification + Article 21 right-to-object + CCPA opt-out + CCPA Sale + CCPA Share + per-state biometric consent + COPPA + Quebec Law 25 + Apple ATT iOS 14.5+ + Google Privacy Sandbox Topics + Attribution Reporting + Protected Audience API).
- Why do LaunchDarkly + Statsig + Segment Personas + Feast + Tecton + Vertex AI Feature Store + Redis + Vercel KV + OpenAI break at multi-location-multi-cohort-sub-millisecond-runtime-cohort scale?
- Each feature-flag + CDP + feature-store + edge-cache vendor ships per-account flat cohort-assignment primitive at single-cohort level. None coordinates runtime-readable cohort schema + sub-millisecond cohort-assignment + sub-100ms feature-vector + per-cohort feature-engineering (RFM + CLV + cart-abandon + per-session behavior) + per-cohort propensity-score matching + per-cohort A/B test framework + per-cohort consent (GDPR Article 22 + Article 17 + Article 16 + Article 21 + CCPA opt-out + per-state biometric + Apple ATT + Google Privacy Sandbox). None handles per-cohort consent propagation through edge-cache + precomputed-feature-store + online-feature-store. None gates against TCPA when SMS retargeting + CAN-SPAM email + GLBA financial + HIPAA health + FINRA financial-services. None enforces SOX 302/404/906 when public-company per-cohort material. None writes a per-customer per-cohort WORM runtime-readable audit trail. The four-skill bundle Define + Compute + Expose + Audit sits above the schema-registry + feature-flag + policy-engine + CDP + feature-store + edge-cache + causal-inference + warehouse substrate — it does not replace it.
- How does Define + Compute work?
- Define runs per-cohort schema definition: TypeScript discriminated-union + JSON Schema Draft 2020-12 + AsyncAPI 2.6 + Apache Avro + Protobuf + Confluent Schema Registry registration. Per-cohort feature-flag (LaunchDarkly + Statsig + Optimizely + Split.io + Flagsmith + Unleash + Eppo + GrowthBook + Vercel Edge Config). Per-cohort policy (OPA Rego + Cedar + AWS Verified Permissions + Casbin). Per-cohort runtime-target latency budget (sub-millisecond cohort-assignment + sub-100ms feature-vector compute + edge-cache TTL + precomputed-feature-store refresh-cadence). Per-cohort consent-requirement linking (GDPR Article 6 legal-basis + Article 7 consent + Article 22 automated decision-making + Article 17 right-to-erasure + Article 16 right-to-rectification + Article 21 right-to-object + CCPA opt-out + CCPA Sale + CCPA Share + per-state biometric + COPPA + Quebec Law 25 + Apple ATT + Google Privacy Sandbox Topics + Attribution Reporting + Protected Audience API). Compute runs per-cohort feature-engineering: per-customer RFM (recency + frequency + monetary) + per-customer CLV + per-customer churn-probability + per-product behavioral + per-cart-abandon + per-checkout-completion + per-session depth + scroll-depth + time-on-page + form-completion + exit-intent + bounce + pageview-velocity + per-customer NPS + CSAT + CES. Per-cohort precomputed-feature-store (Feast + Tecton + Vertex AI Feature Store + SageMaker Feature Store + Databricks Feature Store + Hopsworks) + online-feature-store + offline-feature-store. Per-cohort propensity-score matching (PSM + CEM + GenMatch + IPTW via DoWhy + EconML + causalml + R MatchIt).
- What does Expose + Audit do?
- Expose runs per-cohort runtime exposure via edge-cache (Redis + Redis Cluster + Memcached + Hazelcast + Apache Ignite + Aerospike + ScyllaDB + Vercel KV + Cloudflare KV + AWS DynamoDB Accelerator DAX + Upstash Redis). Per-cohort A/B test framework: Bayesian A/B + frequentist A/B + sequential A/B + multi-armed bandit + contextual bandit + Thompson sampling + epsilon-greedy + UCB + per-test peeking-correction + SPRT + Gittins index. Per-cohort observability instrumentation: per-cohort OpenTelemetry trace + Prometheus metric + structured log + incident-routing (PagerDuty + Opsgenie + Datadog + Honeycomb). Per-cohort severity classification: P0 GDPR Article 22 automated decision-making consent-gap (immediate block + cohort-rollback + alert) + P1 GDPR Article 17 right-to-erasure propagation gap 72-hour + P2 per-state biometric consent-gap 7-day + P3 Apple ATT/Privacy Sandbox compatibility drift 30-day + P4 docs-only. Gate runs 5 anchors per-customer per-cohort before any cohort assignment exposes to runtime AI agent. (1) Runtime-readable cohort-schema + sub-millisecond cohort-assignment + sub-100ms feature-vector + per-cohort feature-engineering + per-cohort propensity-score matching + per-cohort A/B test framework. (2) FTC Section 5 + Pfizer 1972 + CFPB UDAAP + Lanham + USPTO + Robinson-Patman + Sherman + Clayton. (3) TCPA when SMS retargeting + CAN-SPAM email + GLBA financial-customer + HIPAA 45 CFR 164.502/504/514 health-customer + COPPA + per-state biometric + FINRA Rule 2210 + SEC Regulation FD. (4) EU AI Act Article 50 transparency when AI-ML cohort-assignment + Article 13/14/15 + Annex III when AI-ML cohort-assignment drives personalization + Article 6/27 FRIA + DSA + DMA + GDPR Article 6 legal-basis + Article 7 consent + Article 22 automated decision-making + Article 17 right-to-erasure + Article 16 right-to-rectification + Article 21 right-to-object + LGPD + DPDP + PIPEDA + Quebec Law 25 + CCPA + CPRA + 18-state + Apple ATT iOS 14.5+ + Google Privacy Sandbox Topics + Attribution Reporting + Protected Audience API. (5) WCAG 2.2 AA + ARIA + EAA + ADA Title III + Section 508 + SOX 302/404/906 + COSO + Exchange Act 13(b)(2) + SEC Reg S-K. Audit writes a per-customer per-cohort WORM runtime-readable record: per-cohort schema snapshot + per-cohort assignment + per-cohort feature-vector + per-cohort consent-state + per-anchor gate-pass + AI-ML provenance + EU AI Act FRIA + GDPR Article 22 automated decision-making log + Article 17 right-to-erasure propagation log. Retention: 7-year FTC + 7-year IRS + 7-year HIPAA + 7-year GLBA + 7-year state bar + 6-year SEC + 3-year FINRA + 7-year SOX + GDPR Article 30 + EU AI Act Article 12 + SOC 2 CC7/CC8.
- What does this skill connect to on the runtime-cohort agent and across the swarm?
- On the runtime-cohort agent: runtime-readable cohort schema + sub-millisecond cohort-assignment + sub-100ms feature-vector + per-cohort A/B test framework + per-cohort consent. Across the swarm: peer-cohort computation (#612 UPSTREAM canonical for per-cohort assignment) + per-location AI-calibrated forecasting (#600 DOWNSTREAM consumer of per-cohort feature) + per-location per-cohort two-sigma anomaly detection (#608 DOWNSTREAM consumer of per-cohort feature) + idempotent CRM record creation (#601 same per-vendor Idempotency-Key substrate) + per-location custom-system adapters (#611 same per-vendor SDK + OAuth + transport substrate) + per-state-overlay-composer (#599 UPSTREAM canonical for CCPA + per-state biometric + TCPA + GLBA per-state overlays) + per-field conflict-resolution policy (#607 same per-source authority hierarchy substrate). Commercial-pillar parent: /runtime-personalization-orchestration.
- What does the 6-workstream pre-engagement-baseline reporting cycle look like for this skill?
- Every two weeks during the Tier 3 Fractional CMO with AI Swarm engagement, six workstreams report against the pre-engagement baseline. Workstream 1: per-portfolio per-customer per-cohort runtime-readable cohort coverage — customers covered + cohorts defined + feature-vectors computed + consent-states tracked. Workstream 2: Define per-cohort schema definition flow — TypeScript + JSON Schema + Avro + Protobuf + per-cohort feature-flag + OPA Rego/Cedar/Casbin + runtime-target latency budget + consent-requirement linking absorbed. Workstream 3: Compute per-cohort feature-engineering flow — RFM + CLV + cart-abandon + per-session behavior + propensity-score matching + feature-store (Feast + Tecton + Vertex AI + SageMaker + Databricks + Hopsworks). Workstream 4: Expose per-cohort runtime exposure flow — edge-cache + A/B test framework (Bayesian + frequentist + sequential + bandit) + observability + incident-routing. Workstream 5: Regulatory-defense audit coverage — runtime cohort-schema + feature-vector + RFM + CLV + propensity-score + A/B framework + GDPR Article 22/17/16/21 + CCPA opt-out + per-state biometric + Apple ATT + Privacy Sandbox + TCPA + CAN-SPAM + GLBA + HIPAA + EU AI Act Article 50 + SOX. Workstream 6: FBC feedback-loop pattern-learning — per-customer per-cohort realized-vs-predicted assignment + per-A/B test peeking retrospective + per-consent enforcement retrospective.
Engage Completions
Two ways to engage. The Tier 1 AI Readiness Assessment maps the schema-registry + feature-flag + policy-engine + CDP + feature-store + edge-cache + causal-inference + warehouse substrate + runtime cohort-schema + sub-100ms feature-vector + RFM + CLV + cart-abandon + propensity- score + A/B framework + GDPR/CCPA/ATT/Privacy Sandbox consent surface against the Define + Compute + Expose + Audit bundle. The Tier 3 Fractional CMO with AI Swarm embeds 1-2 days per week for 6+ months and runs the bundle end-to-end against the runtime-cohort agent across the swarm.
Related reading
- Parent commercial pillar: runtime personalization orchestration
- Sibling build-pillar: peer-cohort computation (#612 UPSTREAM canonical for per-cohort assignment)
- Sibling build-pillar: idempotent CRM record creation (#601 same per-vendor Idempotency-Key substrate)
- Sibling build-pillar: per-location custom-system adapters (#611 same per-vendor SDK + OAuth + transport substrate)
- Fractional CMO with AI Swarm
- AI Readiness Assessment