Coding made simple, let your ideas flow.
Sesi is a clean, minimal, and highly legible programming language. Built from the ground
up to be concise and buildable, Sesi removes unnecessary boilerplate. Because .sesi
itself is so simple, integrating external tools becomes effortless.
let page_title = "Sesi"
let tagline = "Coding made simple, let your ideas flow."
prompt details {"Create a stunning landing page for Sesi.
Title: " page_title
"Tagline: " tagline}
print "Generating Sesi landing page..."
// Use reasoning natively
let html = model("gemini-3.5-flash") {details}
try {
write_file("index.html", html)
print "Website successfully built!"
} catch (e) {
print "Failed to build website:" e
}
try {
exec("start index.html")
} catch (e) {
print "Failed to open website:" e
}
Clean code organization. Import relative local modules using import/export, or access
native namespaces like std/math, std/time, std/json, and
std/db.
Write less, do more. Sesi's syntax is stripped of boilerplate, allowing you to express complex logic,
structured outputs, and model interactions in plain text .sesi files without SDK
overhead.
Powered by a robust, single-threaded tree-walking interpreter, Sesi evaluates Abstract Syntax Trees directly, providing predictable execution, lexical scoping, and straightforward debugging.
Safe-by-default execution. Strict path whitelisting and prototype-free objects (via
Object.create(null)) prevent prototype pollution and unauthorized system access.
Network-aware scripts. Perform HTTP GET and POST requests out of the box with zero external
dependencies using web_get() and web_send().
LLM calls are native language primitives. Use models directly within your control flow just like standard functions, with built-in support for vision and thinking levels.
Built for the modern network. Sesi handles concurrency via the spawn() background
process builtin, and uses multi_req() to run closures and API requests physically in
parallel.
High-efficiency execution. Sesi caches model queries and expensive operations locally in
.sesi_cache.json to speed up subsequent runs and minimize API costs.
Sesi operates on a unique execution model tailored for developer friendly language. Unlike
traditional compiled languages, Sesi utilizes a highly optimized tree-walking interpreter that
evaluates .sesi files line-by-line. Execution is strictly blocking, ensuring
predictable state management during model interactions.
| Phase | Description |
|---|---|
| Lexing & Parsing | Converts plain text .sesi files into an AST. |
| Tree-Walking | Interpreter traverses the AST, executing basic commands with lexical scoping. |
| Blocking Runtime | Execution pauses natively when awaiting model inference or structured outputs. |
| Native Concurrency | Manage processes via spawn()/exec() and execute requests in
parallel using multi_req(). |
// Sesi Internal Tree-Walking Interpreter
private async evaluateExpression(expr: Expression): Promise<RuntimeValue> {
switch (expr.type) {
case 'ModelCallExpression':
// First-class reasoning primitive
return await this.evaluateModelCall(expr);
case 'Assignment':
return await this.evaluateAssignment(expr);
case 'StructuredOutputExpression':
// Natively handles AI structured outputs
return await this.evaluateStructuredOutput(expr);
}
}
# 1. Install the Sesi toolchain
git clone https://github.com/Misterscan/Sesi.git
cd Sesi
npm install
npm run build
# Unlock the `sesi` command globally
npm install -g .
# 2. (OPTIONAL) Set your environment variable
export GEMINI_API_KEY="your_api_key_here"
# 3. Create a new Sesi file
sesi -e 'let txt = "Hello, Sesi!"
let filename = "hello.sesi"
prompt file {"print \"" txt "\""}
write_file(filename, file)
print "hello.sesi created."'
# 4. Run the script
sesi hello.sesi
> Hello, Sesi!
Getting started with Sesi is incredibly straightforward. Install it globally via npm (recommended):
npm install -g @misterscan/sesi
Or download standalone executables for Windows, Mac, and Linux from our downloads page to run Sesi without installing Node.js.
To compile and run from source for development, follow the terminal instructions on the left to clone the repository and compile the Sesi toolchain.