Silk
Systems language with formal verification built in.
Write native tools and libraries with practical modules, typed failures, and contracts the compiler checks.
A checked withdrawal
Walkthrough
Formal Silk proves the numeric contract at compile time. Parse CLI input and validate it before this call.
#require balance >= 0;
#require amount >= 0 && amount <= balance;
#assure result == balance - amount;
#assure result >= 0;
fn withdraw (balance: int, amount: int) -> int {
return balance - amount;
}
fn main () -> int {
let remaining = withdraw(100, 30);
#assert remaining == 70;
return 0;
}
Start
Write a program, then choose your next task.
Getting started
Install, build, and run your first program.
What Silk is for
Design goals, constraints, and where Silk fits.
Hello world
A minimal program and the toolchain workflow.
Standard library
What’s included and how the library is organized.
CLI
silk commands for check, test, build, and tooling.Specification (2026)
Reader-focused spec view with a searchable ToC.
Wiki
Learning-first explanations, design notes, and cross-links.