Skip to content
Astera Technology

Report label coverage without inventing workload prevalence

Compare class-conditional error counts under separately supplied or unknown deployment prevalence.

Download complete case notes and answer keys ↓

Define the local evaluation task

A synthetic evaluation gives errors and totals for standard and exception classes. Report class-conditional error fractions and the pooled fixture fraction. Separately, the required standardShare field supplies either null for unknown deployment prevalence or an integer basis-point standard-class share from 0 to 10000. Weight the two conditional rates only under that assumption; null prevalence leaves deployment error unknown. Counts are finite invented evidence, not measured traffic or a validated population estimate.

  1. Calculate error counts within each class
  2. Keep pooled fixture rate separate
  3. Apply deployment weighting only to a supplied share

Invalid counts or shares stop calculation; unknown prevalence uses explicit null, while an omitted share field is invalid.

Use the filled cases

Original synthetic input and literal answer key
CaseSupplied inputExpected structured outputDecision and reason
Deployment prevalence unmeasured{"standard":{"errors":1,"total":4},"exception":{"errors":3,"total":4},"standardShare":null}{"standardError":[1,4],"exceptionError":[3,4],"fixtureError":[1,2],"assumedDeploymentError":null}The balanced fixture has error 1/2; without deployment shares no weighted deployment figure follows.
Separately supplied 90/10 assumption{"standard":{"errors":1,"total":4},"exception":{"errors":3,"total":4},"standardShare":9000}{"standardError":[1,4],"exceptionError":[3,4],"fixtureError":[1,2],"assumedDeploymentError":[3,10]}0.9×1/4+0.1×3/4=3/10 under this separate assumption, unlike the balanced fixture’s 1/2.
Prevalence channel omitted{"standard":{"errors":1,"total":4},"exception":{"errors":3,"total":4}}{"error":"counts-or-prevalence"}The envelope requires standardShare; unknown prevalence must be explicitly null rather than omitted.
Supplied all-standard assumption{"standard":{"errors":1,"total":4},"exception":{"errors":3,"total":4},"standardShare":10000}{"standardError":[1,4],"exceptionError":[3,4],"fixtureError":[1,2],"assumedDeploymentError":[1,4]}At the supplied 100% standard boundary only its 1/4 conditional rate receives weight; exception evidence remains shown.
Download editable CSV ↓

Work the all-standard-assumption case. Which output is required, and why?

Show the worked answer

{"standardError":[1,4],"exceptionError":[3,4],"fixtureError":[1,2],"assumedDeploymentError":[1,4]} — At the supplied 100% standard boundary only its 1/4 conditional rate receives weight; exception evidence remains shown.

Run the self-contained evaluator

Save as .mjs and run with Node.js; supplied fixtures only
import assert from 'node:assert/strict';

function evaluate(x){
 const gcd=(a,b)=>b?gcd(b,a%b):a,frac=(n,d)=>{const g=gcd(n,d);return [n/g,d/g];};const a=x.standard,b=x.exception;
 if([a,b].some(c=>!Number.isInteger(c.errors)||!Number.isInteger(c.total)||c.total<1||c.total>10000||c.errors<0||c.errors>c.total)||(x.standardShare!==null&&(!Number.isInteger(x.standardShare)||x.standardShare<0||x.standardShare>10000)))return {error:'counts-or-prevalence'};
 const deployment=x.standardShare===null?null:frac(x.standardShare*a.errors*b.total+(10000-x.standardShare)*b.errors*a.total,10000*a.total*b.total);
 return {standardError:frac(a.errors,a.total),exceptionError:frac(b.errors,b.total),fixtureError:frac(a.errors+b.errors,a.total+b.total),assumedDeploymentError:deployment};
}

const cases = [
  {
    "id": "unknown-prevalence",
    "input": {
      "standard": {
        "errors": 1,
        "total": 4
      },
      "exception": {
        "errors": 3,
        "total": 4
      },
      "standardShare": null
    },
    "expected": {
      "standardError": [
        1,
        4
      ],
      "exceptionError": [
        3,
        4
      ],
      "fixtureError": [
        1,
        2
      ],
      "assumedDeploymentError": null
    }
  },
  {
    "id": "supplied-ninety-ten",
    "input": {
      "standard": {
        "errors": 1,
        "total": 4
      },
      "exception": {
        "errors": 3,
        "total": 4
      },
      "standardShare": 9000
    },
    "expected": {
      "standardError": [
        1,
        4
      ],
      "exceptionError": [
        3,
        4
      ],
      "fixtureError": [
        1,
        2
      ],
      "assumedDeploymentError": [
        3,
        10
      ]
    }
  },
  {
    "id": "share-channel-omitted",
    "input": {
      "standard": {
        "errors": 1,
        "total": 4
      },
      "exception": {
        "errors": 3,
        "total": 4
      }
    },
    "expected": {
      "error": "counts-or-prevalence"
    }
  },
  {
    "id": "all-standard-assumption",
    "input": {
      "standard": {
        "errors": 1,
        "total": 4
      },
      "exception": {
        "errors": 3,
        "total": 4
      },
      "standardShare": 10000
    },
    "expected": {
      "standardError": [
        1,
        4
      ],
      "exceptionError": [
        3,
        4
      ],
      "fixtureError": [
        1,
        2
      ],
      "assumedDeploymentError": [
        1,
        4
      ]
    }
  }
];
for (const c of cases) assert.deepEqual(evaluate(c.input), c.expected, c.id);
console.log(JSON.stringify({checked:cases.length,caseIds:cases.map(c=>c.id)}));
Download runnable example ↓

Keep the prevalence assumption’s source beside the weighted figure. Changing deployment class mix changes this conditional projection; the fixture supplies no assurance that class-specific rates will transfer to real work.

Related resources