01

Install

seqc targets Linux x86_64. The reference environment is Ubuntu 24.04 LTS; on Windows, use WSL2.

Install seqc
curl -fsSL https://raw.githubusercontent.com/tomjnet/seq-lang/HEAD/install.sh | bash

The 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.

ToYou need
Install seqcLinux x86_64, bash, and curl. Building from source also needs CMake 3.28 or newer, Ninja, and GCC 13 or newer.
Compile and run workflowsA 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:

Ubuntu 24.04
sudo apt install build-essential cmake ninja-build libgtest-dev curl python3

llama-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.

Terminal
seqc new top3Companycd top3Companyseqc doctorseqc model pullseqc src/main.seq
  • seqc new creates the project. It needs no model and no compiler.
  • seqc doctor says, one line per prerequisite, whether this host can compile and run workflows.
  • seqc model pull downloads 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.seq validates the workflow, builds it or reuses the last accepted build, runs it, and lists the results.
What the last command ends with
Results:
  output/company.txt  (212 bytes)
  output/top3Company.png  (4.1 KiB)  final

A project keeps your source, your inputs, and everything the compiler made, side by side:

Project layout
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 records

03

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:

src/main.seq
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.

DeclarationRule
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 size1 MiB
name length64 characters
One request4096 bytes
Steps per workflow64
ask() statements per step16

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("...")
Try it in the playground

04

Commands

CommandWhat 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 doctorCheck 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 --settingsList 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.

ExitMeaningWhat to do
2Bad command line or settingRead the message; seqc --help.
3The workflow is not validFix the reported path:line:column.
4The model could not be used, or its response was unusableseqc doctor; seqc model pull; rerun, with --rebuild to ask again.
5The generated program or its tests were not accepted within the repair limitInspect output/temp/runs/<run-id>/attempts/; reword the requests; rerun.
6The program failed, hit a limit, or produced invalid outputsRead the step message. Nothing was published.
7A filesystem or isolation rule stopped the runAn output would overwrite a file seqc did not create, another seqc is running, or the sandbox is unavailable.
8A prerequisite is missingseqc doctor.

06

Reference