Team Moscova

Overall Objectives
Scientific Foundations
Application Domains
New Results
Other Grants and Activities

Section: Software

OTT: One true tool for the working semanticist

Participants : Peter Sewell [ U. of Cambridge ] , Francesco Zappa Nardelli.

Ott is a tool for writing definitions of programming languages and calculi. It takes as input a definition of a language syntax and semantics, in a concise and readable ASCII notation that is close to what one would write in informal mathematics. It generates output:

  1. a LaTeX source file that defines commands to build a typeset version of the definition;

  2. a Coq version of the definition;

  3. an Isabelle version of the definition; and

  4. a HOL version of the definition.

Additionally, it can be run as a filter, taking a LaTeX/Coq/Isabelle/HOL source file with embedded (symbolic) terms of the defined language, parsing them and replacing them by typeset terms.

The main goal of the Ott tool is to support work on large programming language definitions, where the scale makes it hard to keep a definition internally consistent, and to keep a tight correspondence between a definition and implementations. We also wish to ease rapid prototyping work with smaller calculi, and to make it easier to exchange definitions and definition fragments between groups. The theorem-prover backends should enable a smooth transition between use of informal and formal mathematics.

In collaboration with Peter Sewell (Cambridge University).

The current version of Ott is about 24000 lines of OCaml. The tool is available from (BSD licence).

Since its release in December 2007, the tool has been used in several projects, including a large proof of type preservation for the OCaml language (without modules) done by Scott Owens.

In 2009 we completed the development of a new theorem-prover backend that produces language definitions in "locally-nameless" style, thus supporting reasoning about alpha-equivalent terms. A paper describing the metalanguage used by Ott and its semantics (including the new backend) will appear in the Journal of Functional Programming [19] .


Logo Inria