Pick the on-ramp that matches how you want to use Devlish. Every path below gets you from zero to a running program; the ideas can wait until it works.
The full compiler and VM, running in your browser via WebAssembly. Load an example, press Run. Nothing to set up, nothing uploaded.
Open the playground Native · 5 minutesBuild the Rust toolchain once, then compile and run .dvl files locally: validate, disassemble, and execute with JSON input.
Install the CLI For your LLM · 5 minutesRun devlish mcp and every .dvl file becomes a tool Claude, GPT, or any MCP client can call with structured JSON in and out.
One npm install. Load a compiled rule like a JSON asset and run it in React, Node, or the edge, sandboxed and off the main thread.
Install the runtimeThe toolchain is pure Rust: one build, no runtime dependencies after that.
# 1. Get the code (Rust required: https://rustup.rs)
git clone https://github.com/adubinsky/devlish
cd devlish
# 2. Build and add `devlish` to your PATH
./install.sh
# 3. Write a program
cat > hello.dvl << 'EOF'
Ask "What is your name?" as user name
Print user name
EOF
# 4. Run it
devlish run hello.dvl --input '{"user_name": "World"}'
# Also useful:
devlish validate hello.dvl # check syntax
devlish compile hello.dvl -o hello.dvlc.json # compile to bytecode
devlish disassemble hello.dvlc.json # inspect the bytecode
The run command auto-compiles .dvl files in memory; devlish script.dvl is shorthand for devlish run script.dvl.
The MCP server ships inside the CLI, so finish the CLI install above first. Then:
# 1. Start the MCP server over a folder of .dvl tools
devlish mcp --tools-dir ./tools/
# 2. Register it with your MCP client, e.g. Claude Code:
claude mcp add devlish -- devlish mcp --tools-dir /path/to/tools
# 3. Every .dvl file is now a callable tool. This IS the tool:
Ask "Customer tier?" as customer_tier
Ask "Deal size?" as deal_size
discount_rate equals 0.05
If customer_tier is "enterprise":
discount_rate equals 0.15
Respond with record with deal_size times discount_rate as discount
Ask lines define the tool's input schema. Respond with returns typed JSON; Fail with returns a structured error the LLM can parse and retry.
Compiled rules load like static assets and run in a sandboxed WASM VM, off the main thread.
# 1. Install the runtime
npm install devlish-runtime
# 2. Compile a rule with the CLI (or commit the .dvlc.json)
devlish compile pricing.dvl -o public/rules/pricing.dvlc.json
// 3. Load and run it in your app
import { loadTool } from "devlish-runtime";
const tool = await loadTool({
bytecode: await fetch("/rules/pricing.dvlc.json").then(r => r.json())
});
const result = await tool.run({ customer_tier: "enterprise", deal_size: 500000 });
console.log(result.response); // => 75000
Programs cannot reach your network or filesystem; tools that declare HTTP or file permissions are rejected at load time.
How embedding works under the hood