Portfolios

Workspace architecture

Single-table multi-tenant Postgres with RLS + a sparse EAV override layer. One pattern, three substrates: configuration (what users edit), audit + lineage (what happened), computed (what's been derived). All three sit on a shared reference foundation that public + tenant rows co-occupy via workspace_id + Postgres RLS per DD-016. Adding a new analytical dimension is schema-additive, not architecturally novel.

live · 5s

Schema rows are queried live from information_schema.columns + pg_indexes — always honest. For the full prose, read tenant_workspace_v2 README, architecture overview, schema reference, governance, and decisions.md.

Portfolios
5
Assets
42
Variants
2
Overrides
9
Audit events
109
Sessions
12
Stale outputs
2

configuration · audit + lineage · modeling · Your session has performed 0 actions · fa2c9fb8-e42

Reference foundation

DD-016 unified storage

The shared data layer. Public EIA-derived rows (workspace_id IS NULL) live alongside tenant-private rows in the same physical table; Postgres RLS draws the boundary at read time per DD-016. Legacy `engineering_plant` + `engineering_generator` were dropped in 04m.12 — substrate is the only engineering grain.

Read the canonical doc

Configuration substrate

what users edit

Where the workspace expresses its view of the world. `tenant_overrides` is a row-per-field EAV cell store; `tenant_variants` groups override sets into named what-if scenarios; `tenant_templates` are reusable blueprints. The resolver primitives in `provenance.ts` merge baseline + variant overlays at read time — the rendered page is always derived, never persisted.

Read the canonical doc

Audit + lineage substrate

what happened

Append-only history. Every mutation handler wraps the data write + audit row in one transaction (DD-013); `event_session_id` groups multi-write actions like Promote-variant into one user-readable line. `model_input_snapshot` extends the same idea for modeling — every output row carries a snapshot ID, so the inputs that produced a number stay reproducible after the workspace moves on.

Read the canonical doc

Computed / modeling substrate

what's been derived

Modeled outputs (DD-033/DD-034) at monthly grain. Production is staleness-driven: a config edit fires a `modeling_invalidation` row per affected output dim (DD-038), the UI surfaces an amber badge, and Re-run clears it. Currently a mock — real model orchestration lands later without changing this surface. 04m.13.9: per-field `modelDependencies` declarations are preliminary; the runtime fires all dims on every edit until the modeling team validates.

Read the canonical doc

Recent portfolio_asset (last 10)

paidportfolioplantvariantcap (eff / ref)updated
65c55339Test63688Topaz Generatingbaseline6052026-06-29
2a52af7dTest63910Bluegrass Solarbaseline79.62026-06-29
0885d5f5Test64430American Beech Solar LLCbaseline1402026-06-29
175e55baTest68998Long Point Solarbaseline1202026-06-29
11fbb06dTest62406City of Gallup Solarbaseline82026-06-29
a8bb6274Test60299HMV Minster Energy Storage Systembaseline72026-06-29
4fb17c28Test69096Jerichobaseline52026-06-29
c2c33578Test69787AC IL - Hillsborobaseline52026-06-29
e3663fc0Test67747Nachtigall 1836-WDbaseline4.62026-06-29
ff8e24c5Test63727Slate Hybridbaseline440.32026-06-18

Recent audit_event (last 10)

timeactoractionresource_iddiff
2026-06-29617e3094portfolio_asset.add65c55339…
  • plant_uuid: 18d9876d-35f9-43f7-808b-bffa428f348c
  • is_baseline: true
  • eia_plant_id: 63,688
  • portfolio_id: ef5bd170-618b-461c-925b-fa82de117523
  • variant_name: baseline
  • portfolio_kind: portfolio
  • workspace_asset_state: portfolio
2026-06-29617e3094portfolio_asset.add2a52af7d…
  • plant_uuid: cae5f8c0-6964-4762-87e8-3c6073e6ac24
  • is_baseline: true
  • eia_plant_id: 63,910
  • portfolio_id: ef5bd170-618b-461c-925b-fa82de117523
  • variant_name: baseline
  • portfolio_kind: portfolio
  • workspace_asset_state: portfolio
2026-06-29617e3094portfolio_asset.add0885d5f5…
  • plant_uuid: a26d10ca-5557-41d3-aa27-8f7d941634d6
  • is_baseline: true
  • eia_plant_id: 64,430
  • portfolio_id: ef5bd170-618b-461c-925b-fa82de117523
  • variant_name: baseline
  • portfolio_kind: portfolio
  • workspace_asset_state: portfolio
2026-06-29617e3094portfolio_asset.add175e55ba…
  • plant_uuid: e5d50566-1790-48fe-86dc-4d0853dcce40
  • is_baseline: true
  • eia_plant_id: 68,998
  • portfolio_id: ef5bd170-618b-461c-925b-fa82de117523
  • variant_name: baseline
  • portfolio_kind: portfolio
  • workspace_asset_state: portfolio
2026-06-29617e3094portfolio_asset.add11fbb06d…
  • plant_uuid: f855ad02-d332-4b22-994b-38ddef0d29c1
  • is_baseline: true
  • eia_plant_id: 62,406
  • portfolio_id: ef5bd170-618b-461c-925b-fa82de117523
  • variant_name: baseline
  • portfolio_kind: portfolio
  • workspace_asset_state: portfolio
2026-06-29617e3094portfolio_asset.adda8bb6274…
  • plant_uuid: 27e48b48-628f-4229-9e99-be7581076783
  • is_baseline: true
  • eia_plant_id: 60,299
  • portfolio_id: ef5bd170-618b-461c-925b-fa82de117523
  • variant_name: baseline
  • portfolio_kind: portfolio
  • workspace_asset_state: portfolio
2026-06-29617e3094portfolio_asset.add4fb17c28…
  • plant_uuid: dbb97718-7bad-42e7-947e-e4ff34f17c46
  • is_baseline: true
  • eia_plant_id: 69,096
  • portfolio_id: ef5bd170-618b-461c-925b-fa82de117523
  • variant_name: baseline
  • portfolio_kind: portfolio
  • workspace_asset_state: portfolio
2026-06-29617e3094portfolio_asset.addc2c33578…
  • plant_uuid: 3a9eba63-b4eb-427d-97b7-d9a44ee2c9c5
  • is_baseline: true
  • eia_plant_id: 69,787
  • portfolio_id: ef5bd170-618b-461c-925b-fa82de117523
  • variant_name: baseline
  • portfolio_kind: portfolio
  • workspace_asset_state: portfolio
2026-06-29617e3094portfolio_asset.adde3663fc0…
  • plant_uuid: 2fc2cb57-656f-48a1-919a-4c8390f63ab3
  • is_baseline: true
  • eia_plant_id: 67,747
  • portfolio_id: ef5bd170-618b-461c-925b-fa82de117523
  • variant_name: baseline
  • portfolio_kind: portfolio
  • workspace_asset_state: portfolio
2026-06-18617e3094portfolio_asset.addff8e24c5…
  • bulk: true
  • is_baseline: true
  • portfolio_id: ef5bd170-618b-461c-925b-fa82de117523
  • variant_name: baseline
  • reference_plant_id: 63,727