This project has been archived by its maintainers, and is no longer receiving any updates.
NLBook: Natural Language Notebooks.
Authors:
Luca de Alfaro, dealfaro@acm.org
Overview
Natural Language Notebooks (NLBook) allow you to create notebooks where the cells are written in natural language. The natural language is automatically converted to code via AI, and executed. The results of the execution are then displayed below the natural language cell.
In NLBooks, natural language is the programming language. The goal of NLBooks is to allow users to create and share notebooks in natural language, without having to write code, or understand the code that is shared with them. Actions to be performed are described in natural language, and the natural languate is retained, so users can edit it, improve it, and share it. We are building methods for verifying that the code implementation is faithful to the natural language description, so that users can trust the notebooks they receive from others.
Natural Language Notebooks have two type of cells:
-
Action cells, where the user describes in natural language the action to be performed (e.g., "Load the dataset from file data.csv and display the first 10 rows"). The system converts the description to code, executes it, and displays the results below the cell.
-
Comment cells, where the user can add comments, section headers, and so forth, using markdown syntax.
Differently from other notebook systems, NLBooks are executed from start to end: random cell execution order, as in Jupyter notebooks, is not allowed. This ensures that the results are obtained in the same order in which a human reader would read the notebook.
This project is in an early stage of development.
Running NLBook
nlbook path/to/notebook.nlb
(where .nlb is a Natural Language Notebook file; you can use other extensions if you wish).
For a list of command-lien options, do:
nlbook --help
If you want to be able to generate or check code from explanations, you need to add a Gemini API key in the settings (click on the gear icon in the top-right corner of the web interface).
Development
Run with:
python -m nlbook.main --debug
Running with the VSCode launch.json does not work, due to a VScode bug/quirk. See DEVELOP.md for development instructions, and see TODO.md for planned features.
Metadata
Release files for nlbook 0.0.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| nlbook-0.0.5.tar.gz | 894.5 kB | Without provenance | Details for nlbook-0.0.5.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| nlbook-0.0.5-py3-none-any.whl | Python 3 | none | any | Details for nlbook-0.0.5-py3-none-any.whl |
Total release size: 1.8 MB
Release files / nlbook-0.0.5.tar.gz
| Download URL | nlbook-0.0.5.tar.gz |
|---|---|
| Size | 894.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
581ca0f2584a27027e891aacb14b431b748b0d5f1a0aeabc445a680bf4ac977a
|
|
BLAKE2b-256 checksum How to use checksums |
2d394d8c4abaffd66eb17a5a84892836b0d642f37b3ff356136a928a6c9fe3d0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.2
|
Release files / nlbook-0.0.5-py3-none-any.whl
| Download URL | nlbook-0.0.5-py3-none-any.whl |
|---|---|
| Size | 900.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9def528f8cb33a5787891a9027724831a04e134b3f952d3bc4ff6e90028da374
|
|
BLAKE2b-256 checksum How to use checksums |
39cc8a2e37bf714035dc753adf8a5f01b544723573e0760511189228cdc34d11
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.2
|
Security for nlbook 0.0.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.