Skip to content

Repository files navigation

Veln

Veln is an experimental programming language and toolchain based on https://oakcask.github.io/docs/202605-programming-language-for-agents/.

The current prototype explores a language for AI-agent-assisted programming: small syntax, explicit public boundaries, typed holes, contracts, coarse effects, and structured diagnostics are treated as one tool surface.

Commands

Use the prototype CLI as veln:

veln --version
veln check samples/demo/hello.veln
veln fmt samples/demo/hello.veln
veln run main samples/demo/hello.veln
veln test samples/demo

The CLI shape is:

veln check [--json] [path ...]
veln fmt [path ...]
veln run <entry> [path ...]
veln test [--json] [target ...]

Example

use stdio

pub fn main() -> () effects [stdio]
  stdio::println("hello from veln")
  stdio::eprintln("stderr from veln")
  ()
end
veln check samples/demo/hello.veln
ok
veln run main samples/demo/hello.veln
stderr from veln
hello from veln

Agent-Oriented Features

Public functions carry explicit signatures and effect declarations:

pub fn main() -> () effects [stdio]
  stdio::println("hello from veln")
  ()
end

Typed holes keep partial programs checkable and report repair context:

pub fn main() -> Result<(), AppError> effects []
  _todo satisfy candidate => candidate == Ok(())
end
veln check samples/demo/hole_error.veln
samples/demo/hole_error.veln:2:3: hint[hole.unfilled]: hole requires a `Result<(), AppError>` value
  note: samples/demo/hole_error.veln:1:1: Return type declared here.
  note: samples/demo/hole_error.veln:2:9: Satisfy predicate contributes a repair constraint.

The same diagnostics can be emitted as JSON for tools and coding agents:

veln check --json samples/demo/hole_error.veln

About

An experimental programming language focused on visible boundaries, explicit effects, and local verification

Resources

Stars

0 stars

Watchers

0 watching

Forks

Contributors

Languages