Sema
Sema support for Sublime Text — a Lisp with first-class LLM primitives
Details
Installs
- Total 0
- Win 0
- Mac 0
- Linux 0
| Jul 24 | Jul 23 | Jul 22 | Jul 21 | Jul 20 | Jul 19 | Jul 18 | Jul 17 | Jul 16 | Jul 15 | Jul 14 | Jul 13 | Jul 12 | Jul 11 | Jul 10 | Jul 9 | Jul 8 | Jul 7 | Jul 6 | Jul 5 | Jul 4 | Jul 3 | Jul 2 | Jul 1 | Jun 30 | Jun 29 | Jun 28 | Jun 27 | Jun 26 | Jun 25 | Jun 24 | Jun 23 | Jun 22 | Jun 21 | Jun 20 | Jun 19 | Jun 18 | Jun 17 | Jun 16 | Jun 15 | Jun 14 | Jun 13 | Jun 12 | Jun 11 | Jun 10 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Windows | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Mac | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Linux | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Readme
- Source
- raw.githubusercontent.com
Language support for Sema, a Lisp dialect with first-class LLM primitives, for Sublime Text 4.
Install
Package Control (recommended)
- Install Package Control if you haven't already.
- Open the command palette (
Cmd+Shift+P/Ctrl+Shift+P) → Package Control: Install Package. - Search for Sema and install it.
Manual
Clone into your Sublime Text Packages directory:
# macOS
git clone https://github.com/sema-lisp/sublime-sema \
"$HOME/Library/Application Support/Sublime Text/Packages/Sema"
# Linux
git clone https://github.com/sema-lisp/sublime-sema \
"$HOME/.config/sublime-text/Packages/Sema"
# Windows (PowerShell)
git clone https://github.com/sema-lisp/sublime-sema `
"$env:APPDATA\Sublime Text\Packages\Sema"
Find the Packages directory quickly via the command palette → Preferences: Browse Packages.
Features
- Syntax highlighting for
.semafiles (special forms, builtins, LLM primitives, keywords, strings, numbers, characters, quote operators, and more) via a native.sublime-syntaxdefinition - Comment toggling with
Cmd+//Ctrl+/(Sema's;line comments) - Symbol navigation (
Cmd+R/Ctrl+R) fordefine,defun,defmacro,defagent,deftool, and friends - Eval the selection (or whole file) via Sema: Eval Selection or Buffer — output shows in the Sema panel (optional key binding below)
- Build systems for running, formatting, compiling, and building a standalone executable
- Optional language server (
sema lsp) via the LSP package
Building & running
Open a .sema file and use Tools → Build System → Sema (or Cmd+B / Ctrl+B). Variants (Cmd+Shift+B / Ctrl+Shift+B):
| Variant | Command |
|---|---|
| Sema | sema <file> — run the program |
| Sema — Format | sema fmt <file> |
| Sema — Compile to bytecode | sema compile <file> |
| Sema — Build executable | sema build <file> |
To evaluate code without a full build, select an expression and run Sema: Eval Selection or Buffer from the command palette. With nothing selected, the whole file is evaluated. Output appears in the Sema panel.
The build systems and the eval command invoke the sema binary, so it must be on your PATH. Install it from sema-lang.com.
Language server
For IDE features — completions, hover, go-to-definition, references, rename, signature help, and diagnostics — install the LSP package via Package Control. Sema registers its sema lsp server automatically for source.sema files; no manual configuration is needed. Restart Sublime Text (or run LSP: Restart Servers) after installing LSP.
To override the server command or options, open Preferences → Package Settings → Sema → Settings (or run Preferences: Sema Settings from the command palette).
Key bindings
The package ships no active key bindings, so it never overrides yours or Sublime's defaults. To bind the eval command, open Preferences → Package Settings → Sema → Key Bindings — the left pane shows ready-to-copy examples, the right pane is your user keymap. For instance:
[
{
"keys": ["super+enter"],
"command": "sema_eval",
"context": [
{ "key": "selector", "operator": "equal", "operand": "source.sema" }
]
}
]
Use ctrl+enter on Linux/Windows. Heads up: this chord shadows Sublime's built-in “insert line after” inside Sema files — pick another if you rely on it.
Requirements
- Sublime Text 4
- The
semabinary on yourPATH— used by the build systems (sema,sema fmt,sema compile,sema build), the Eval command (sema eval), and the language server (sema lsp) - The LSP package (optional) for IDE features
Links
- Website — sema-lang.com
- Playground — sema.run
- Documentation — sema-lang.com/docs
- Grammar — tree-sitter-sema
- Repository — sema-lisp/sublime-sema