Ask + print
Call a model with ask, bind the
result, and print it. Dry-run uses offline fixtures.
ask "Explain gravity in one sentence" -> text
print text
SparkLang — the Spark programming language
Write programs in plain .spark files.
Dry-run offline with fixtures, or run live
ask against your own
OpenAI-compatible gateway. Download the runtime, try the playground,
or start with the learn guides.
Call a model with ask, bind the
result, and print it. Dry-run uses offline fixtures.
ask "Explain gravity in one sentence" -> text
print text
./spark --dry-run uses offline
fixtures. Pass --live with your
own AI_GATEWAY_URL when you want
real model calls.
ask "Summarize: {doc}" -> text
./spark --dry-run my_task.spark
Optional listen /
speak for local demos.
voice {
listen -> user
classify Intent { support, sales } from user -> intent
ask "Reply as {intent}: {user}" -> reply
speak reply
}
Ready-made .spark snippets for
common tasks (fix tests, refactor, review).
include "lib/ai.spark"
ask "Fix this test failure: {msg}" -> fix
Language ops with dry fixtures; live via
spark-rag-http when you configure
a gateway.
embed "SparkLang workflows" -> vec
retrieve "dry-run" from project "docs" -> hits
model train /
model build submit a real training
job (adapters / checkpoints). Dry-run uses fixtures with no GPU and
no network. Live uses a pluggable backend
(http or allowlisted
local-yield).
# model_train.spark — dry-run first
model train dataset "examples/fixtures/train/dataset.jsonl" base "fixture-base" out "out/train/job-dry-001" backend "http" -> job
model status "job-dry-001" -> status
Analyze / compare / improve remain eval helpers.
model plan writes optional markdown.
Model training docs ·
Build a Model ·
Language reference.
Optional listen /
speak ops for local demos.
voice {
listen -> user
classify Intent { support, sales, billing } from user -> intent
ask "Reply helpfully to: {user}" -> reply
speak reply -> "out/turn.wav"
}
# PSTN off by default — placeholders only until you enable gates
voice pstn status -> st
voice pstn dial "+15555550100" -> call
See AI in 5 Minutes — voice, Playground voice tab, and language reference (listen/speak/pstn).
Language ops for capture, browser automation, and engine fetch.
First-class http get /
http post are on the roadmap.
network capture probe -> info
network open "examples/fixtures/sample.pcap" -> pcap
network analyze pcap -> traffic_report
engine fetch "file://examples/fixtures/engine/sample.html"
browser run "examples/browser_main.spark"
Not a Python stub driver — asm dispatch today. First-class
http get / http post
are [roadmap]; use engine fetch
for HTTP now.
Network + web guide ·
Language reference ·
Browser / MITM
Language and runtime first. Live gateway, voice, and capture are optional.
Language, dry-run fixtures, playbooks,
embed /
retrieve, IDE language ops.
Live ask /
embed with
--live; voice; browser / capture.
Prefer LSP + syntax highlighting. Verified
ide language ops and playbooks
remain; homegrown Electron/PyQt chrome is not the product focus.
include "lib/ai.spark"
ide new "out/ide/task.spark"
ide ask "Explain this buffer" -> reply
./spark --dry-run examples/ide_ask_show.spark
Terminal-first IDE today — not Electron product chrome. IDE status · AI models guide · Programming guide
Follow the tutorial path — same structure as official language docs for Java or C++.
Install the runtime, run your first dry-run, and set up live ask.
Start here →
Hello world with use,
ask, and
print.
Classify, extract, pipeline, voice, and model workflow — the primitives for AI programs in one file.
Quick tour →Wizard for analyze → compare → improve → build — modify an Train a model — submit a dry-run job, then poll status, or start from eval helpers and an optional plan file.
Open wizard →# Dry-run — no network, no API key
./spark --dry-run examples/hello.spark
# Optional live ask — any OpenAI-compatible gateway
export AI_GATEWAY_URL=http://127.0.0.1:4000
./spark --live examples/ask_live.spark
Sample program:
Then
ask "…" -> text. See
full programming guide and
language reference.