Crates.io | ashlang |
lib.rs | ashlang |
version | 0.1.3 |
source | src |
created_at | 2024-10-11 18:15:19.307461 |
updated_at | 2024-10-17 23:59:08.381632 |
description | A language for zero knowledge proofs |
homepage | https://github.com/chancehudson/ashlang |
repository | https://github.com/chancehudson/ashlang |
max_upload_size | |
id | 1405657 |
size | 272,153 |
A language designed to compile and execute on mathematical virtual machines.
Simplicity is the philosophy of ashlang. The language is simple to learn and expresses relationships very close to the arithmetization. Functions are globally available to encourage the development of a single, well audited, well maintained standard library of logic that can be re-used in many proving systems.
ashlang currently supports two targets:
ar1cs
- an extended rank 1 constraint system that includes witness calculation instructionstasm
- a novel assembly language used to express instructions for the Triton VMashlang supprts proving on the following systems:
TritonVM/triton-vm
- using tasm
target in this cratemicrosoft/spartan
- using ar1cs
target in chancehudson/ashlang-spartanashlang is a scripting language for expressing mathematical relations between scalars and vectors in a finite field.
The language is untyped, with each variable being one of the following:
ashlang is designed to be written in conjunction with a lower level language. Each file is a single function, it may be invoked using its filename. Directories are recursively imported and functions become globally available.
val[0..10] * lav[0..5]
tasm
let
assignmentstatic
assignment (static evaluation)assert_eq
crash
v[2][3][4][1]
[0..5]
v[i]
r1cs
let
assignmentstatic
assignment (static evaluation)assert_eq
crash
v[2][3][4][1]
[0..5]
v[i]