# Lepton: An automaton for Literate Executable Papers

Sébastien Li-Thiao-Té

► To cite this version:

Sébastien Li-Thiao-Té. Lepton: An automaton for Literate Executable Papers. Journal of Open Source Software, 2019, 4 (42), pp.1005. 10.21105/joss.01005. hal-03943612

HAL Id: hal-03943612

https://hal.science/hal-03943612

Submitted on 17 Jan 2023

HAL is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_1.png" /></figure>

Distributed under a Creative Commons Attribution 4.0 International License
# Lepton: An automaton for Literate Executable Papers

Sébastien Li-Thiao-Té¹

1 Université Paris 13, Sorbonne Paris Cité, LAGA, CNRS UMR 7539

DOI: 10.21105/joss.01005

## Software

- Review ⚗

- Repository ⚗

- Archive ⚗

Submitted: 19 July 2018

Published: 24 October 2019

## License

Authors of papers retain copyright and release the work under a Creative Commons Attribution 4.0 International License (CC-BY).

## Summary

Source code is very hard to maintain when the documentation is missing. Recognizing this fact, Knuth (1984) proposed the literate programming paradigm, i.e., that source code and documentation should be written at the same time, inside the same file, and in a format designed for human understanding.

"Lepton" is a tool for writing reproducible research papers and similar documents by extending literate programming to data analysis reports. "Lepton" makes it easy to include scripts or complete programs, compilation and execution instructions, as well as execution results in the same file. Offloading execution to "Lepton" makes the analysis operator-independent and easy to reproduce. In the spirit of literate programming, the plain text file format used by "Lepton" is intended to be human-understandable as opposed to machine-readable, and simple enough to be usable without the software.

Among the current approaches proposed for reproducible research, "Lepton" focuses on:

- offline execution so that results are operator independent,

- long-term maintainability of "Lepton" itself and the documents produced with it through a plain text format and a well documented reference implementation

- adaptability: users are not tied to a single data analysis environment such as R, C or Python but can use them concurrently, and users can document freely regardless of the constraints of the programming language.

"Lepton" consists in a standalone executable that processes plain text files written in a documentation format such as HTML or LaTeX with optional blocks that can contain files to be written to disk, source code or executable instructions. It is distributed as a "Lepton" file containing the full source code, manual, and a tutorial (Li-Thiao-Té, 2018). The package contains an extracted copy of the source code that can be compiled without "Lepton". The public repository is hosted on Github. "Lepton" has been used in research publications related to teaching computational science and reproducible research (Li-Thiao-Té, 2012a, 2012b).

## References

Knuth, D. E. (1984). Literate Programming. *The Computer Journal*, 27(2), 97–111. doi:10.1093/comjnl/27.2.97

Li-Thiao-Té, S. (2012a). Literate program execution for teaching computational science. *Procedia Computer Science*, 9(0), 1723–1732. doi:10.1016/j.procs.2012.04.190

Li-Thiao-Té, S. (2012b). Literate program execution for reproducible research and executable papers. *Procedia Computer Science*, 9(0), 439–448. doi:10.1016/j.procs.2012.04.047

Li-Thiao-Té, S. (2018, July). Lepton: V1.0. doi:10.5281/zenodo.1311588