Skip to main content

Scale Tiers, Multi-Calc Mode, and Data Source Types (Locked)

Moved from SKILL.md on 2026-11-03 to keep the always-loaded skill lean. Read this for very wide (100+ field) or very large data sources, multi-calc runs, and blended, federated, live, or multi-table sources.

calc-writer adapts Phase 1 field-inventory strategy and Phase 4 verification behavior based on data source size. Every scale tier has explicit handling.

Field-Count Tiers​

TierField CountPhase 1 Strategy
Narrow<10 fieldsSingle list-available-fields call. Skip batching. Full inventory in one call.
Typical10-50 fieldsSingle list-available-fields call. No batching required.
Wide50-100 fieldsSingle call still viable; consider batching if response payload approaches token cap.
Very Wide100-200 fieldsBatch in groups of ~10 with inline progress notes. Reuse inventory across chained invocations in-session.
Massive200+ fieldsBatch in groups of ~10. Recommend user narrow scope to a specific logical table before proceeding. If user refuses, batch anyway with a note about likely token pressure.

Row-Count Tiers (Verification Confidence)​

TierRow CountVerification Behavior
Tiny<100 rowsVerification runs; mark verified: true, sample_size: N but note "very small dataset; verification is directional."
Small100-999 rowsVerification runs; mark sample_size: "below_threshold" per Sample-Size Reliability rule.
Standard1,000-999,999 rowsVerification runs; mark verified: true, sample_size: N.
Large1M-100M rowsVerification runs on a sample; sample_size is the actual rows returned. Note in handoff that this is a sample, not the full extract.
Very Large100M+ rowsVerification samples per default; get-summary-data may return a truncated result. Note the truncation explicitly in handoff notes.

Multi-Calc Sequential Mode​

Multi-calc mode (HC#1 opt-in) runs the full pipeline per calc, one at a time, in the order the user named them. Explicit runtime characteristics:

  • N calcs = N inventory reuses. Phase 1 inventory from calc #1 is reused for calcs #2 through #N in the same invocation.
  • N calcs = N V-gate passes. Every calc runs all 8 checks independently. No shared V-gate.
  • N calcs = N handoff YAMLs, only when HC#7 applies. One calc_write_handoff/1 per calc, emitted in order, when a downstream calc skill requested it.
  • Failure isolation. If calc #3 fails V-gate, calcs #4 through #N still proceed. Failed calcs report the specific V-gate rule failure; downstream peers see the failure count in a session summary at the end.
  • Session summary. After the last calc, calc-writer emits a summary: "N of M calcs shipped successfully. Failed: [calc-X (R-gate-fail), calc-Y (field-missing)]."

Data Source Type Branching​

Data Source TypeHandling
Extract (.hyper)Full verification supported. Preferred for verified-tier confidence.
Live connectionVerification runs but sample may reflect connection latency; note in handoff.
Cross-DS blendRefuse per Edge-Case Boundary (blended sources use query-time joins; calc semantics differ).
Federated multi-sourceRefuse per Edge-Case Boundary; route to calc-translator if source-dialect port required.
Multi-table (relationships)Confirm which logical table before authoring; document grain in handoff notes.