Tenor is a formal contract language for declaring provably correct business logic. You write a single .tenor file that specifies every entity, authority boundary, rule, and workflow in a domain. The evaluator computes deterministic verdicts and action spaces from that specification, and static analysis proves properties of your contracts before they ever run.
This documentation covers the open-source language and toolchain, the commercial execution platform, and everything in between.
Documentation Sections
Getting Started
Install the CLI, write your first contract, run the evaluator, and deploy to the platform.
- Installation -- CLI and evaluator setup
- First Contract -- Write and evaluate a contract from scratch
- Evaluator -- How deterministic evaluation works
- Deploy -- Push contracts to the Tenor platform
Language Reference
Complete reference for every construct in the Tenor language.
- Overview -- Language structure and concepts
- Symbols, Facts, Entities, Personas -- Data model primitives
- Rules, Operations, Flows -- Decision and workflow logic
- Types, Sources, Systems -- Type system, external data, system integration
- Parallel Composition -- Composing multiple contracts
Guides
Conceptual guides, tutorials, and deep dives.
- What Is Tenor? -- Conceptual introduction
- The Tenor Narrative -- Why Tenor exists and the problems it solves
- Author Guide -- How to write contracts effectively
- Agent Orientation -- Building AI agents that operate inside Tenor
- Minimal Kernel -- The smallest possible Tenor contract
- Migration Guide -- Migrating existing systems to Tenor
- Trust and Signing -- Cryptographic guarantees and contract integrity
- Source Declarations -- Connecting contracts to external data
Platform
The commercial Tenor execution platform: HTTP APIs, authentication, and provenance.
- Overview -- Platform architecture and capabilities
- HTTP API -- Evaluate contracts and execute operations via HTTP
- Management API -- Deploy, version, and manage contracts
- Authentication -- API keys, tokens, and access control
- Provenance -- Audit trails and decision reconstruction
SDKs
Client libraries for integrating Tenor into application code.
- Overview -- SDK design principles and common patterns
- TypeScript --
@tenor/sdkfor Node.js and browser - Python --
tenor-sdkfor Python applications - Go --
tenor-gofor Go services
CLI Reference
All 26 commands in the tenor CLI with flags, options, and example output.
Reference
Configuration, error codes, static analysis checks, and executor obligations.
- Configuration --
.tenorrc, environment variables, project config - Errors -- Error codes and diagnostic messages
- Static Analysis -- The eight formal checks (S1--S8)
- Executor Obligations -- What executors must guarantee
Domain Contracts
Six validated domain contracts demonstrating Tenor in production scenarios.
Specification
The full formal Tenor language specification.
Where to Start
New to Tenor? Begin with Getting Started. Install the CLI, write a contract, and see evaluation in action within minutes.
Writing contracts? Read the Author Guide for practical patterns, then use the Language Reference as you write.
Integrating with code? The SDK Overview covers client libraries for TypeScript, Python, and Go. Pick your language and start calling the evaluator from application code.
Deploying to production? The Platform docs cover the hosted execution platform, including HTTP APIs, authentication, and provenance tracking.
Building AI agents? The Agent Orientation guide explains how agents read action spaces and make decisions within Tenor's authority model.
Open Source and Platform
The Tenor language, evaluator, CLI, and static analysis tools are open source. You can write contracts, evaluate them, and run static analysis entirely locally.
The Tenor platform is the commercial hosted service that adds atomic execution, persistent state, provenance recording, management APIs, and multi-tenant deployment. Platform documentation is included here alongside the open-source toolchain docs.