ling-lang 2030.1.13

Ling - The Omniglot Systems Language
Documentation

Ling logo

ling · 灵 · 霊 · 령 · ลิง

The Omniglot Systems Language

CI crates.io docs.rs Website Docs License GitHub Stars

Write in your language. Run everywhere.


Ling is a polyglot scripting and systems language whose keywords and builtins are available in 16+ human languages simultaneously — Chinese, Thai, Korean, Japanese, English, Arabic, Hebrew, Russian, and more — in the same source file, with no #lang pragmas or context switches. It compiles to native code via a Rust backend.


Quick Start

cargo install ling-lang
ling run examples/basics/thai_hello_world.ling
# Or from source
git clone https://github.com/taellinglin/ling
cd ling
cargo run --bin ling -- run examples/basics/thai_hello_world.ling

Hello World · 五種語言

fn main() {
  bind x = 42
  print("Hello!")
}
函 主函数() {
  令 甲 = 42
  打印("你好!")
}
関数 メイン() {
  束縛 甲 = 42
  印刷("こんにちは!")
}
함수 메인() {
  바인드 갑 = 42
  출력("안녕하세요!")
}
ฟังก์ชัน หลัก() {
  ผูก ก = 42
  พิมพ์("สวัสดี!")
}

All five are valid in a single .ling file — mix and match freely.


Language Keywords

Concept 🇺🇸 EN 🇨🇳 ZH 🇯🇵 JA 🇰🇷 KO 🇹🇭 TH
Bind bind 束縛 바인드 ผูก
Function fn 関数 함수 ฟังก์ชัน
If if もし 만약 ถ้า
Else else 否则 아니면 มิฉะนั้น
While while 동안 ขณะที่
For for 위해 สำหรับ
Return return 戻る 반환 คืน
Do block do 実行 실행 ทำ
Match match 一致 매치 จับคู่
Module mod モジュール 모듈 โมดูล
Import use 使う 사용 ใช้
True true จริง
False false 거짓 เท็จ

3D / Visual Builtins

Ling has a built-in software renderer for interactive 3D rooms and visualisations. All drawing builtins are multilingual — Thai aliases shown alongside English.

Window · Camera

set_camera(cry, sry, crx, srx)    # orient camera
set_camera_pos(x, y, z)
set_zdist(2.0)
set_ambient(0.1)
present()                          # flush depth queue → screen

Vector Geometry · vtex_*

All vtex calls draw line-based 3D geometry on a plane defined by centre + two tangent vectors. They are fast (no pixel fills) and depth-sorted automatically. Every function has aliases in Thai, Chinese, Japanese, and Korean.

English 🇹🇭 Thai 🇨🇳 Chinese 🇯🇵 Japanese 🇰🇷 Korean
vtex_grid ลายตาราง 纹格 格子模様 격자무늬
vtex_rings ลายวงแหวน 纹环 リング模様 링무늬
vtex_spiral ลายก้นหอย 纹螺 螺旋模様 나선무늬
vtex_star ลายดาว 纹星 星模様 별무늬
vtex_flower ลายดอกไม้ 纹花 花模様 꽃무늬
vtex_lotus ลายดอกบัว 纹莲 蓮模様 연꽃무늬
vtex_chakra ลายจักร 纹轮 輪模様 바퀴무늬
vtex_yantra ลายยันต์ 纹扬特拉 ヤントラ模様 얀트라무늬
vtex_torii ประตูโทริอิ 纹鸟居 鳥居 도리이
vtex_pagoda เจดีย์ 纹塔
# vtex_grid(cx,cy,cz, ux,uy,uz, vx,vy,vz, cols,rows, cw,ch, fr,hue)
vtex_grid(0, -4, 8,  1,0,0,  0,0,1,  12,8,  1.0,1.0,  FR, 0.0)

# vtex_chakra — same call, Thai name:
ลายจักร(0, 0, 8,  1,0,0,  0,1,0,  4,32,  2.0,0.08,  FR, 1.57)

Full vtex reference: docs.ling-lang.org/reference/vtex.html

Audio · audio_*

audio_tone(slot, x, y, z, w, freq_hz, amp, lfo_rate, lfo_depth)
audio_volume(0.5)
audio_bgm("track.wav")
audio_bgm_volume(0.8)
audio_listener(x, y, z)

ling-fu · Package Manager

lingfu (also 灵符 / 霊符 / 영부 / ลิงฟู) is the project manager — think Cargo for Ling.

lingfu new my-room             # scaffold a new project
lingfu run                     # build & run
lingfu build                   # compile only
lingfu test                    # run tests
lingfu normalize thai          # translate entire project to Thai
lingfu normalize zh --dry-run  # preview Chinese normalization
灵符 运行                       # run in Chinese
ลิงฟู รัน                      # run in Thai

The normalize command rewrites all .ling keywords, builtin names, and file/folder names to a single target language — great for keeping large codebases consistent.


Gallery

These rooms are real .ling programs rendered live by Ling's built-in renderer:

The Matrix Cathedral East Asian Chan Temple Eno-Ji Meditation Hall
Matrix Cathedral Chinese Room Japanese Room
Mirror Garden Thai-Japanese Clocktown The Synthetic Garden
Mirror Garden Clocktown Garden

Workspace Crates

Crate Purpose
ling-core Core types and errors
ling-audio 4D spatial audio + FFT
ling-graphics 3D/4D line renderer
ling-game ECS + physics
ling-crypto AES-GCM, Blake3, Curve25519
ling-net Async QUIC networking
ling-ai LLM inference integration
ling-wasm WebGL2 WASM target

Project Structure

ling/
├── src/
│   ├── runtime/mod.rs       # builtins, eval loop, vtex_* dispatch
│   ├── parser/              # hand-written polyglot lexer + grammar
│   ├── lexer/mod.rs         # 16-language keyword classifier
│   └── visualize.rs         # SVG AST map generator
├── crates/
│   ├── ling-audio/          # FFT + 4D positional synthesis
│   ├── ling-fu/             # lingfu package manager
│   └── ...
├── examples/                # .ling demo rooms
│   ├── ling-dao-chamber.ling
│   ├── Garden.ling
│   └── ...
├── lexicons/                # language alias documentation
│   ├── en.ling  zh.ling  ja.ling  ko.ling  th.ling
└── docs/                    # mdBook → docs.ling-lang.org

Building

cargo build                                        # debug
cargo build --release                              # release
cargo run --bin ling -- run examples/audiovisual/Garden.ling   # run a room
cargo run --bin ling -- visualize examples/audiovisual/Garden.ling > Garden.svg
mdbook build docs && mdbook serve docs             # local docs

Documentation

Resource Link
Language reference docs.ling-lang.org
API docs (docs.rs) docs.rs/ling-lang
Website + gallery ling-lang.org
vtex builtin reference docs.ling-lang.org/reference/vtex.html
Multilingual builtins docs.ling-lang.org/multilingual/builtins.html
Source code github.com/taellinglin/ling

License

Licensed under either of Apache License 2.0 or MIT License at your option.

ling-lang.org docs.ling-lang.org

灵语 · 霊語 · 령어 · ภาษาลิง · Ling Language