
formualizer-sheetport
SheetPort runtime — treat any spreadsheet as a typed, deterministic function.
formualizer-sheetport binds SheetPort YAML manifests to workbooks, resolves selectors, enforces schemas, and provides deterministic read/write/evaluate primitives. A workbook plus manifest behaves like a pure function: write typed inputs, recalculate, read typed outputs.
When to use this crate
Use formualizer-sheetport when you want to:
- Expose a spreadsheet as a typed API with schema validation
- Run batch scenarios through a financial model
- Give AI agents safe, typed access to spreadsheet logic
- Enforce constraints and defaults on spreadsheet inputs/outputs
How it works
- Define a manifest (YAML) that declares typed input and output ports with locations and schemas.
- Bind the manifest to a workbook — selectors (
a1, named ranges, header-based layouts) are resolved to workbook coordinates. - Write inputs — values are validated against the manifest schema, with defaults and constraints enforced.
- Evaluate — the workbook is recalculated deterministically.
- Read outputs — results are extracted and coerced to the declared output types.
Features
- Manifest conformance — enforces
core-v0profile with selector validation. - Schema enforcement — type coercion, defaults, and constraint checking with detailed violation paths.
- Deterministic evaluation — freeze volatile functions, inject timestamps, seed RNG.
- Batch execution —
BatchExecutorfans scenarios across a shared workbook with baseline reset between runs. - Selector resolution —
a1references, named ranges, and header-based table layouts.
Documentation
License
Dual-licensed under MIT or Apache-2.0, at your option.