Skip to main content

Vera: a programming language designed for LLMs, with full contracts, algebraic effects, and typed slot references

Project description

Vera

Vera is a programming language designed for large language models to write. It has mandatory contracts, algebraic effects, typed slot references instead of variable names, and a compiler that emits WebAssembly.

Full documentation, examples, and the language specification are available at veralang.dev and in the GitHub repository.

Install a released version

Vera requires Python 3.11 or later. Create a virtual environment and install the veralang distribution:

python -m venv .venv
source .venv/bin/activate
python -m pip install veralang

On Windows, activate the environment with .venv\Scripts\activate instead. For editor and agent integration through the language server, install the LSP extra:

python -m pip install "veralang[lsp]"

The distribution is named veralang, but the installed command remains vera, and Python code still imports it as import vera. Do not run pip install vera: that name belongs to an unrelated ERAV citizen-science project on PyPI. The wheel ships the compiler and the vera command only — the bundled examples, the conformance suite, and the specification live in the GitHub repository.

Install from GitHub source

The source route provides the full environment — the examples, conformance programs, and specification alongside the toolchain (the recommended setup for agents learning the language) — and remains the route for compiler development, unreleased changes, and testing the current main branch:

git clone https://github.com/aallan/vera.git
cd vera
python -m venv .venv
source .venv/bin/activate
python -m pip install -e .

Use python -m pip install -e ".[lsp]" for the language server or python -m pip install -e ".[dev]" when working on the compiler.

Try it

public fn safe_divide(@Int, @Int -> @Int)
  requires(@Int.1 != 0)
  ensures(@Int.result == @Int.0 / @Int.1)
  effects(pure)
{
  @Int.0 / @Int.1
}

public fn main(-> @Int)
  requires(true)
  ensures(@Int.result == 5)
  effects(pure)
{
  safe_divide(2, 10)
}
vera check program.vera
vera verify program.vera    # proves main returns 5 from safe_divide's contract
vera run program.vera       # prints 5

See the CLI cookbook, language reference, supported-platform policy, and issue tracker for more.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

veralang-0.1.7.tar.gz (1.8 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

veralang-0.1.7-py3-none-any.whl (937.5 kB view details)

Uploaded Python 3

File details

Details for the file veralang-0.1.7.tar.gz.

File metadata

  • Download URL: veralang-0.1.7.tar.gz
  • Upload date:
  • Size: 1.8 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for veralang-0.1.7.tar.gz
Algorithm Hash digest
SHA256 f991cc40af82fdca15cf8140d5e24b2564a4ce3773eee78bae704a95ad661601
MD5 1fdac81a117764b1b6407c0393a7cd89
BLAKE2b-256 6447f17d2596fe4b26fd0cd16d9a9ca0b15fc90c06a774b964ce3ca1cc8feb11

See more details on using hashes here.

Provenance

The following attestation bundles were made for veralang-0.1.7.tar.gz:

Publisher: release.yml on aallan/vera

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file veralang-0.1.7-py3-none-any.whl.

File metadata

  • Download URL: veralang-0.1.7-py3-none-any.whl
  • Upload date:
  • Size: 937.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for veralang-0.1.7-py3-none-any.whl
Algorithm Hash digest
SHA256 8e38bb00bb9e9ed8bdf463906cb5f3e0f880e35c48fc7f7943e66e2ad6cdbd65
MD5 e30ea389f822064aca51ca26f2191bc4
BLAKE2b-256 1f4a7f3dfd3801036edeb167e569e851e51fea860d060f88bc051426770c4acb

See more details on using hashes here.

Provenance

The following attestation bundles were made for veralang-0.1.7-py3-none-any.whl:

Publisher: release.yml on aallan/vera

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page