Skip to content

33 Slice Development Landscapes

Pipeline Slice: Therapeutic Development Programs and Landscapes

Section titled “Pipeline Slice: Therapeutic Development Programs and Landscapes”

Status: CONVERGED CORE VERTICAL. Contextual program synthesis, state history, milestones, evidence drill-down, query models, contracts, checks, and database acceptance tests are implemented. Additional source families extend owner slices rather than changing this model. Denoising state: converged (noise -> rough -> sharp -> converged) Updated: 2026-07-23

Model the therapeutic development story that ties drugs and regimens to diseases, patient contexts, trials, approvals, publications, organisations, targets, and technologies.

This slice answers:

What is being developed for whom, how far has it progressed, what is happening now, and what evidence supports that view?

It owns cross-slice synthesis. It does not take ownership away from the slices that produce trial, approval, publication, organisation, disease, or drug facts.

therapy + disease
-> development program
-> one or more evidence-backed population contexts
-> source-grounded milestones
-> deterministic state over time
-> queryable landscapes
flowchart LR
  Therapy["Drug or regimen identity"]
  Disease["Disease identity"]
  Context["Patient / line / setting context"]
  Trials["Trial facts"]
  Approvals["Regulatory facts"]
  Publications["Reported outcomes and safety"]
  Organisations["Sponsors and temporal owners"]
  Program["Therapeutic Development Program"]
  Milestones["Program milestones"]
  State["Program state history"]
  Query["q_development_* and q_emerging_clinical_evidence"]

  Therapy --> Program
  Disease --> Program
  Context --> Program
  Trials --> Milestones
  Approvals --> Milestones
  Publications --> Milestones
  Organisations --> State
  Program --> Milestones --> State --> Query
  1. Development state is contextual, not an attribute of drug identity. Pembrolizumab can be approved in one disease, active in Phase 2 in another, and stopped in a third.
  2. Clinical phase, clinical activity, and regulatory state are separate axes. Approval is not “Phase 5” or rank 100.
  3. Current state and historical maximum are separate facts. A terminated Phase 3 program can have no active Phase 3 trial while still retaining a maximum historical phase of 3.
  4. A landscape is a query projection, not a canonical entity. It groups programs by disease, target, technology, organisation, line, or state without minting a second truth model.
  5. Cross-slice synthesis consumes canonical assets, never q_*. Query models remain terminal consumer surfaces.
  6. Unknown context remains unknown. Missing treatment line, biomarker, setting, or phase is null/unknown, never silently defaulted.
  7. Time is explicit. Source-effective time and system-observed time are kept separate; state rows use validity intervals.

These decisions are recorded in adr/0008-development-state-is-contextual.md.

Data Gov’s drug_development_programs views, development-phase analytics, TPP reporting specs, and Aero’s disease/drug/target/technology pages demonstrate a real product need: current development programs, historical progression, competitive landscapes, and emerging clinical data.

The legacy implementation accumulated incompatible meanings inside one ranking problem:

Legacy behaviorUseful intentGreenfield model
approval row assigned a rank above clinical phasesshow marketed/approved maturityregulatory_state, independent of phase
“current” views used active statuses plus a recent-completed time windowshow present development activityexplicit normalized activity state and state_as_of
“all trials” views ranked highest phase everretain historical progressmaximum_historical_phase derived from accepted milestones
phase/status lived on the drugshow a compact drug summaryderive summaries from contextual programs; identity remains stable
missing line sometimes became 1Lkeep rows filterablenull means unknown; source-backed lines only
approved contexts hid development rowsavoid duplicate displaykeep regulatory and clinical facts together; deduplicate only at declared query grain
parent-drug and component rollups changed counting behaviormake landscapes readableexplicit therapy/regimen identity and declared deduplication key
publication and registry metrics were blended for reportssurface emerging evidencepreserve each source observation and expose selection/ranking separately

Evidence: ../bioloupe-data-gov/db/views/drug_development_programs_v11.sql, ../bioloupe-data-gov/openspec/specs/development-phase-analytics/spec.md, ../bioloupe-data-gov/openspec/specs/tpp-reporting/spec.md, and Aero’s ../bioloupe-aero/apps/studio-server/src/entities/registry.ts.

FactPrimary authoritySupporting evidenceNot sufficient alone
registered trial phase/status/dates/sponsortrial registry snapshotpublication, sponsor announcementnews summary
regulatory approval/status/labelregulator product/decision recordlabel artifact, company filingtrial phase or press release
reported efficacy/safety resultexact publication, conference artifact, or registry result recordlinked trial protocolsecondary news article
disease/population/line/settingsource protocol, label, publication, or guideline at the fact’s grainaccepted extraction and identity receiptsdrug-level therapeutic-area tag
target/technology relationtarget/technology spine evidencetrial/publication contextname similarity
sponsor/owner relationshiptrial registry for sponsor role; organisation slice for temporal ownershipfiling, deal evidencecurrent company name alone

ClinicalTrials.gov explicitly models study phase and overall recruitment status as distinct protocol fields; the greenfield normalization preserves that distinction. See https://clinicaltrials.gov/data-api/about-api/study-data-structure and https://clinicaltrials.gov/policy/protocol-definitions.

NounGrainMeaning
Therapeutic Development Programone resolved therapy + one resolved diseaseThe stable effort to develop a drug or regimen in a disease. Phase, status, sponsor, and approval are not part of its identity.
Program Contextone program + one evidence-supported population contextOptional patient segment, biomarkers, treatment line/range, setting, intent, and geography. A generic unknown context may exist until narrower evidence appears.
Program Evidence Linkone program context + one canonical source factConnects a trial, approval indication, publication observation, SOC assertion, or event to the context with a stated relation and acceptance receipt.
Program Milestoneone accepted source-grounded changeTrial start/status/phase observation, regulatory filing/decision, result disclosure, ownership event, or other typed milestone with effective and observed time.
Program State Intervalone program context + one validity intervalDeterministic interpretation of clinical activity, phase, regulatory state, and current relationships over [valid_from, valid_to).
Development Landscapea query-time grouping of programsA disease/target/technology/organisation/line/state projection. It is not stored as canonical identity.
Emerging Clinical Evidence Observationone source-reported endpoint or safety statisticSource-specific observation at trial, arm, population, endpoint, timepoint, and report grain. It is not a cross-source average.
  • development_program_key identifies therapy_key + resolved_disease_key using a stable opaque key.
  • therapy_key points to exactly one resolved_drug_key or one regimen_key; monotherapy and regimen programs do not collapse.
  • program_context_key identifies a stable context within a program. Context attributes are resolved through the disease/biomarker spine and evidence-backed treatment-line/setting vocabularies.
  • phase, status, approval, owner, sponsor, target, technology, and evidence source do not enter either identity key.
  • a newly resolved narrow context creates or links a context; it does not silently rewrite the meaning of older evidence. Reviewed merge/split decisions preserve supersession history.
  • aggregation declares its count key: program, program context, therapy, or trial. “Drug count” must not accidentally count one multi-target program several times.
AxisValues / formDerivation rule
clinical_activity_stateactive, halted, completed, stopped, unknown, no_trial_evidencenormalized from accepted trial status at state_as_of; source status remains separately available
current_clinical_phasenormalized phase or nullhighest phase among accepted active trial facts at state_as_of; no recent-completed heuristic
latest_observed_phasenormalized phase or nullphase on the latest accepted phase-bearing milestone by effective time, with deterministic tie-break
maximum_historical_phasenormalized phase or nullmaximum phase ordinal across all accepted historical trial milestones
regulatory_statenot_observed, filed, approved, conditional, rejected, withdrawn, suspended, unknownaccepted regulator milestones for the program context and region
ownership_statetemporal organisation relationshipssupplied by the organisation slice at state_as_of

Combined phases remain source-faithful values (early_phase_1, phase_1, phase_1_2, phase_2, phase_2_3, phase_3, phase_4, not_applicable, unknown). A documented ordinal supports sorting and maximum-phase derivation; the ordinal does not turn regulatory approval into a phase.

ClinicalTrials.gov status normalization is explicit:

Source overall statusProgram activity bucket
NOT_YET_RECRUITING, RECRUITING, ENROLLING_BY_INVITATION, ACTIVE_NOT_RECRUITINGactive
SUSPENDEDhalted
COMPLETEDcompleted
TERMINATED, WITHDRAWNstopped
UNKNOWN or unmapped source valueunknown

At program-context grain, precedence is active -> halted -> completed -> stopped -> unknown; no_trial_evidence applies only when no accepted trial-status fact exists. Every source status remains queryable, so the summary bucket never erases mixed trial histories.

Every milestone and derived state carries:

  • effective_at or a bounded effective date when the source says the event happened;
  • observed_at when Bioloupe captured it;
  • source_release_or_snapshot;
  • valid_from and valid_to on derived state intervals;
  • derivation_revision and provenance_key.

Corrections append new evidence or decisions and supersede old interpretations. They do not mutate historical source observations.

The physical state-history table uses a half-open tstzrange ([valid_from, valid_to)) and a GiST exclusion constraint over program_context_key + derivation_revision + validity_range to reject overlapping intervals. PostgreSQL range and exclusion constraints are designed for exactly this non-overlap invariant: https://www.postgresql.org/docs/current/rangetypes.html.

AssetGrainInputs
canonical.development_programsone programdrug/regimen + disease identities
canonical.development_program_contextsone program contextresolved segment/biomarker/line/setting claims
canonical.development_program_evidenceone accepted evidence relationcanonical trial, approval, publication, SOC, news-event, and organisation facts
canonical.development_program_milestonesone typed milestoneaccepted evidence links with effective time
canonical.development_program_state_historyone validity intervaldeterministic fold over ordered milestones and temporal relationships

The state-history asset may be recomputed under a new derivation_revision; milestones remain stable evidence. This makes fixes replayable without provider calls when no extraction contract changed.

Contract fieldRequired meaning
PurposeCurrent, filterable development state for each evidence-backed program context.
GrainOne program_context_key at the latest published state_as_of.
Stable row keyprogram_context_key.
Identity columnsdevelopment_program_key, program_context_key, therapy_key, therapy_kind, resolved_drug_key, regimen_key, resolved_disease_key, segment_key, resolved_biomarker_keys, treatment_line_min, treatment_line_max, setting.
State columnsclinical_activity_state, source_trial_statuses, current_clinical_phase, latest_observed_phase, maximum_historical_phase, regulatory_states_by_region, state_as_of.
Relationship columnsactive/supporting trial keys, approval indication keys, current sponsor keys, current owner keys, target keys, technology keys.
Evidence columnsfirst_evidence_at, latest_evidence_at, milestone_count, provenance_key, derivation_revision.
Search/indexesbtree/composite filters for disease + phase + activity, target, technology, organisation, line, and regulatory state; GIN for key arrays.
Provenancebundle; each derived state expands to the milestones and owner-spine facts used.

No global drug_status field substitutes for this model.

One row per program context and validity interval. Required columns include all state axes, valid_from, valid_to, state_as_of, derivation_revision, changed field names, causing milestone keys, and provenance_key. This is the authoritative SQL surface for “what did we know then?” and state-diff questions.

One row per accepted milestone. Required columns include milestone key/type, program/context keys, source fact kind/key, normalized and source-native phase/status/regulatory values, effective/observed time, region, relationship roles, assertion state, and provenance key.

One row per accepted program-context-to-evidence relation. It supports drill-down without forcing consumers to infer links from denormalized arrays. Required columns include program/context keys, evidence kind/key, relation type, source family, effective/observed time, acceptance decision, and provenance key.

One row per source-reported efficacy or safety observation linked to a program context.

Required dimensions:

  • source type and exact source fact key;
  • trial, program, program context, therapy, and disease keys;
  • arm/result-group key and label;
  • analysis population and cohort text/keys;
  • endpoint or adverse-event key, source term, statistic kind, value, unit, denominator, grade, timepoint, and analysis method where applicable;
  • treatment intent, line, setting, target, technology, and organisation keys when source-backed;
  • report/effective/observed dates, evidence coverage, assertion state, and provenance key.

Registry and publication observations remain separate rows. A later evidence-selection policy may identify a preferred observation for a specific use case, but must record the policy/revision and never overwrite the source rows.

Why there is no q_competitive_landscape_counts

Section titled “Why there is no q_competitive_landscape_counts”

The first contract keeps landscapes composable: consumers aggregate q_development_programs using an explicit count key and drill through to milestones/evidence. A pre-aggregated model is justified only by measured query cost or a stable consumer contract, and must reconcile exactly to the base rows.

Deterministic logic owns:

  • source status and phase normalization;
  • phase ordinals and state folding;
  • effective/observed time ordering;
  • current, latest, and maximum-phase derivation;
  • owner-spine joins, deduplication, and query aggregation;
  • referential, temporal, and provenance checks.

Inference may help extract:

  • unstructured population/line/setting context;
  • investigational regimen components from prose;
  • publication arm/population/endpoint observations;
  • relationship/event candidates from documents.

Inference output follows 06-llm-extraction-and-verification.md: immutable request/attempt/result records, deterministic validation, explicit acceptance, source locators, and quarantine. A model does not decide current phase, approval status, or canonical identity by intuition.

Reviewed overlays may:

  • merge or split development programs/contexts;
  • correct a program-evidence link;
  • resolve ambiguous line, segment, setting, or regimen context;
  • suppress an unsupported milestone;
  • correct an ownership relationship through the organisation owner;
  • select preferred evidence for a declared reporting purpose.

Curation does not edit source facts, invent missing phases, or turn a news claim into regulatory truth.

  • schema_contract and provenance_coverage on every query model;
  • referential_integrity for every drug/regimen, disease, biomarker, trial, approval, organisation, target, technology, endpoint, and adverse-event key;
  • source_authority for phase, trial status, regulatory state, and outcomes;
  • temporal_validity for milestone ordering and non-overlapping state intervals;
  • development_program_semantics, a slice-owned gate suite that verifies:
    • one program at therapy + disease grain and one stable program-context interpretation;
    • no silent context mutation;
    • regulatory state never enters clinical phase or its ordinal;
    • current phase comes from active trials only;
    • maximum historical phase reconciles to accepted milestones;
    • unknown treatment line remains unknown;
    • grouped landscapes reconcile to the declared distinct count key;
    • emerging evidence never collapses source, arm, population, endpoint, or timepoint grains.
ScenarioExpected result
terminated Phase 3 plus active Phase 2 trialcurrent phase 2; maximum historical phase 3; activity active
approved indication plus active Phase 2 expansion studyregulatory state approved; current phase 2; neither overwrites the other
terminated-only Phase 3 programcurrent phase null; activity stopped; maximum historical phase 3
completed Phase 3 five years ago, no active trialno arbitrary “current” status from a recency window; latest/max phase remain inspectable
missing treatment lineline fields remain null; the row is filterable as unknown, not 1L
same drug in two diseasestwo programs with independent state and evidence
same drug as monotherapy and combinationdistinct therapy/program identities
one program linked to two targetsdisease program count remains one when count key is program; target drill-down shows both links
publication and registry report different ORR valuestwo source-specific observations with separate arm/population/timepoint/provenance; no silent average
source correction arrives lateobserved time shows late capture; effective time places the milestone correctly; state history is replayed under a new derivation revision
  • source partitions follow their owner slices; this synthesis does not refetch upstream systems;
  • a changed accepted milestone or identity/curation decision targets affected program contexts;
  • state derivation is deterministic and replayable from persisted canonical inputs;
  • target publication generations keep the previous good query state when blocking checks fail; current in-place query publication does not yet provide this guarantee;
  • materialization metadata reports changed programs, inserted/superseded intervals, unresolved contexts, and landscape reconciliation counts.
ResponsibilityImplementation owner
Deterministic canonical rebuilddefs/canonical/development.py and sql/canonical/development/
Agent-facing read modelsdefs/query/development.py and sql/query/development/
Query contracts and blocking checkslib/checks/contracts_schema/development__*.yaml and defs/query/development.py
Temporal/domain acceptance teststests/test_slice_development.py

The canonical asset consumes accepted owner-slice facts and performs no network or provider calls. Replaying a derivation or fixing state logic is therefore free once the source evidence is stored. The implemented first vertical synthesizes the trial, approval, publication, organisation, and identity facts currently published by those owners; adding richer publication outcomes or new registries belongs in those slices, not in a second development model.