01
Install
seqc targets Linux x86_64. The reference environment is Ubuntu 24.04 LTS; on Windows, use WSL2.
curl -fsSL https://raw.githubusercontent.com/tomjnet/seq-lang/HEAD/install.sh | bashThe installer needs no root access. By default it downloads the pre-built package of the latest release and verifies its SHA-256 checksum; when no package fits, it builds from source. It never downloads a model and never installs system packages. Run it with --help for the options, including--from-source, --prefix, and --uninstall.
| To | You need |
|---|---|
| Install seqc | Linux x86_64, bash, and curl. Building from source also needs CMake 3.28 or newer, Ninja, and GCC 13 or newer. |
| Compile and run workflows | A kernel 6.2 or newer with Landlock, GCC with the static C library, g++, Google Test, and llama.cpp’s llama-server. |
On Ubuntu, the build tools and Google Test come from one command:
sudo apt install build-essential cmake ninja-build libgtest-dev curl python3llama-server comes from llama.cpp. Put it on your PATH, or name it with the model.llama_server setting.
02
Your first workflow
Five commands take you from nothing to published results.
seqc new top3Companycd top3Companyseqc doctorseqc model pullseqc src/main.seqseqc newcreates the project. It needs no model and no compiler.seqc doctorsays, one line per prerequisite, whether this host can compile and run workflows.seqc model pulldownloads the model, about 1.1 GB, verifies its SHA-256, and writesseq.lock. It is the only command that downloads anything. A build never does.seqc src/main.seqvalidates the workflow, builds it or reuses the last accepted build, runs it, and lists the results.
Results:
output/company.txt (212 bytes)
output/top3Company.png (4.1 KiB) finalA project keeps your source, your inputs, and everything the compiler made, side by side:
top3Company/
├── seq.lock pinned model (written by seqc model pull)
├── src/main.seq the workflow
├── input/ read-only data for the workflow
└── output/
├── company.txt published results
├── top3Company.png
└── temp/ compiler-owned: generated C, assembly,
executable, tests, and run records03
A tour of the language
A Seq source file declares a model, a backend, a name, and an ordered list of steps. This is a complete program:
model("https://huggingface.co/Qwen/Qwen2.5-Coder-1.5B-Instruct")
backend.C()
name = "hello"
step step1():
ask("print Hello from Seq")Header declarations
Each of the three is required exactly once. They may come in any order, and all of them come before the first step.
| Declaration | Rule |
|---|---|
model("<url>") | Which model writes the program: https://huggingface.co/<owner>/<repo>, optionally followed by /tree/<revision>. |
backend.C() | The language of the generated program. C is the only backend in v0.1. |
name = "<name>" | The project name and the basename of generated artifacts. Letters, digits, underscores, and hyphens; at most 64 characters. |
Steps and requests
step <name>():
ask("<request>")
ask("<another request>")- A workflow has at least one step. Steps run in source order.
- A step name is a label, not something that can be called. Names are unique.
- A step holds one or more
ask("...")statements, one per line, indented exactly four spaces. - Strings are double-quoted and single-line. A comment runs from
#to the end of the line. - Tabs are rejected everywhere. Indentation is zero or four spaces.
ask() is a compile-time directive. The model receives the whole workflow at once, so a later step can use what an earlier step creates. The generated executable never contacts the model.
Limits
Exceeding a limit is a validation error. Nothing is truncated.
| Source file size | 1 MiB |
name length | 64 characters |
| One request | 4096 bytes |
| Steps per workflow | 64 |
ask() statements per step | 16 |
Diagnostics
seqc reports every error it can find in one run, each with its line and column, and all of them before any model access. The codes are stable.
src/main.seq:6:9: error[E0204]: ask requires parentheses
ask "print Hello from Seq"
^
hint: write ask("...")04
Commands
| Command | What it does |
|---|---|
seqc new <name> | Create a project. Needs no model and no compiler. |
seqc <file.seq> | Validate, build or reuse the cached build, run, and list results. |
seqc check <file.seq> | Parse and validate only. |
seqc doctor | Check the prerequisites on this host. |
seqc model pull [--update] | Download, verify, and lock the project’s model. |
seqc clean [--all] | Remove run records; --all also removes build artifacts. Outputs and inputs are kept. |
seqc --settings | List every setting and its default. |
Options for seqc <file.seq>: --build-only, --rebuild,--force, --quiet. Every command accepts --set section.key=value.
05
When something fails
The exit status says which stage stopped. A failed build never replaces the last accepted build and never runs a stale executable.
| Exit | Meaning | What to do |
|---|---|---|
| 2 | Bad command line or setting | Read the message; seqc --help. |
| 3 | The workflow is not valid | Fix the reported path:line:column. |
| 4 | The model could not be used, or its response was unusable | seqc doctor; seqc model pull; rerun, with --rebuild to ask again. |
| 5 | The generated program or its tests were not accepted within the repair limit | Inspect output/temp/runs/<run-id>/attempts/; reword the requests; rerun. |
| 6 | The program failed, hit a limit, or produced invalid outputs | Read the step message. Nothing was published. |
| 7 | A filesystem or isolation rule stopped the run | An output would overwrite a file seqc did not create, another seqc is running, or the sandbox is unavailable. |
| 8 | A prerequisite is missing | seqc doctor. |
06