UPLC-CAPE: Network profiles measure and report submissions per network
@Unisay ya está trabajando en esto.
Desde el 25/11/2026.
Evaluación
Este issue todavía no se ha evaluado.
Descripción
CAPE measures every submission with the cost model built into the linked plutus-core (1.63) and passes no protocol version. A network profile makes the network explicit: a named set of data (protocol version, cost-model parameters and the other protocol parameters CAPE's numbers depend on) under which every measurement and every report page is computed. This issue makes the profile an entity of the domain model and of the report, and implements the design recorded in ADR 20260526, Refinement 5, "If a network gets ahead of mainnet".
Profile
A profile is data in the repository, one file per profile. A sketch of the type:
data NetworkProfile = NetworkProfile
{ profileName :: Text -- for example "mainnet-pv11", "preview"
, profileNetwork :: Network -- Mainnet | Preview
, profileStatus :: ProfileStatus -- Past | Current | Future
, profileProtocolVersion :: MajorProtocolVersion
, profileCostModelV3 :: [Int64] -- in on-chain order
, profileParameters :: ProtocolParameters -- prices, ref-script fee, tx limits
, profileSource :: ProfileSource -- OnChain EpochNo | Projected
, profileActiveFrom :: Maybe (EpochNo, Day) -- hard fork on this network; Nothing if not yet
}
ProtocolParameters is a new record for the values that are top-level constants in lib/Cape/Protocol/Parameters.hs today. A typical set is mainnet at its previous, current and next protocol version, plus Preview while it runs ahead of mainnet. A past or current profile copies its values from the chain at a named epoch. A future profile has no on-chain values yet, so it takes the parameters that plutus-core ships for its protocol version and is marked as projected.
Measurement
Every evaluation takes a profile, which replaces runCekDeBruijn defaultCekParametersForTesting in lib/Cape/PrettyResult.hs:
- Each script is decoded with
deserialiseScriptat the profile's protocol version. A builtin that the version does not allow is rejected here. - Validators run through
PlutusLedgerApi.V3.evaluateScriptCounting, with an evaluation context thatmkEvaluationContextbuilds from the profile's cost model. - Scenarios that return a value, such as
fibonacci, run on the CEK machine with machine parameters from the same profile. Before that, they need the UPLC version check that the ledger does separately (plcVersionsAvailableIn).
When a profile does not admit a submission, CAPE records the submission as not executable on that profile. This result is kept apart from a test that is expected to fail.
Report
Each profile gets its own report under its own URL (for example profiles/mainnet-pv11/): rankings, scenario pages and the evolution view, all computed from that profile's measurements. The current mainnet profile is the default. A submission appears in every profile that admits it, and each profile lists the submissions it does not admit. A submission keeps one artifact; only its cost changes from one profile to another.
A timeline page puts the profiles of each network in order: the protocol version, the epoch and date it took effect, and a link to its report. A visitor can follow how mainnet changed and see which profile was in force on a given date. A future profile sits at the end of its network's line, marked as projected.
Upgrades
A newer plutus-core keeps the behaviour of earlier protocol versions, so an upgrade should leave every profile's results and budgets unchanged. CI compares them per profile before and after the upgrade. This replaces the current rule that an evaluator upgrade re-measures every submission.
Open questions
- How
metrics.jsonstores results per profile, and how the schema change treats existing submissions. - How profile values are refreshed from the chain, and when a future profile becomes the current one.
- Whether aggregates compare profiles with each other or stay within one profile.
Out of scope: a different compiler per profile. The compiler decides what the program is, and the profile decides what it costs.
- Lenguaje dominante
- Untyped Plutus Core
- Estrellas
- 12
- Forks
- 10
- Merge medio
- 2 d 5 h
- PR fusionados (30 d)
- 9
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de IntersectMBO/UPLC-CAPE
-
Dificultad 4/5 3-5 días Aptitud para principiantes 45/100
IntersectMBO/UPLC-CAPE#279 ·
-
UPLC-CAPE: ScriptContextBuilder: placeholder values the ledger never producesQuizá libre de nuevo @Unisay la tomó hace 30 días y no hay ningún pull request abierto. AbiertoUPLC-CAPE
IntersectMBO/UPLC-CAPE#273 · 1 asignado ·
-
UPLC-CAPE: ScriptContextBuilder: build TxInfo in the ledger's orderQuizá libre de nuevo @Unisay la tomó hace 30 días y no hay ningún pull request abierto. AbiertoUPLC-CAPE
IntersectMBO/UPLC-CAPE#271 · 1 asignado ·
-
Add a programmable-tokens (CIP-113) benchmark scenarioQuizá libre de nuevo @Unisay la tomó hace 152 días y no hay ningún pull request abierto. AbiertoUPLC-CAPE
IntersectMBO/UPLC-CAPE#228 · 1 asignado ·
-
Add synthetic benchmark scenarios for common Value operationsQuizá libre de nuevo @Unisay la tomó hace 152 días y no hay ningún pull request abierto. AbiertoUPLC-CAPE
IntersectMBO/UPLC-CAPE#227 · 1 asignado ·