Programming language for literate programming law specification
Go to file
Denis Merigoux 6c0097e12e Instructions
2020-03-08 06:54:35 +01:00
src Parsed entire thing 2020-03-08 06:49:29 +01:00
test Parsed entire thing 2020-03-08 06:49:29 +01:00
.gitignore Removed merlin files 2019-09-19 16:37:16 +02:00
.ocamlformat Weaving to LaTeX 2020-03-07 18:20:04 -08:00
dune-project Improved architecture 2020-03-07 16:52:31 -08:00
lawspec.opam Improved architecture 2020-03-07 16:52:31 -08:00
LICENSE.txt Code reorg 2019-09-04 10:32:33 +02:00
Makefile Successfully weaved all text 2020-03-07 18:30:37 -08:00
README.md Instructions 2020-03-08 06:54:35 +01:00

Lawspec

Lawspec is a domain-specific language for deriving faithful-by-construction algorithms from legislative texts.

Installation

The project is distributed as a Dune artifact. Use standard dune commands to build and install the library. In particular, if you want to install the library as an opam package, use the following command at the root of the repository:

opam install ./

You can then can the compiler using the lawspec command.

Usage

Use lawspec --help to get more information about the command line options available.

Test

In the test folder, you will find the allocations_familiales.lsp file which contains the algorithm computing French family benefits. The algorithm consists of annotations to the legislative texts that define the family benetifs, using the literate programming paradigm. The lawspec compiler can extract from the .lsp file a lawyer-readable version of the annotated text. To get that lawyer-readable version (which is a LaTeX-created) PDF, use make test at the root of the repository, and then use make inside ghe test directory to compile the LaTeX file.

License

The library is released under the Apache license (version 2).