# SparkLang llms-full version: 0.8.0 sha: df8ec5b5a0f8 verified: 2026-09-04 site: https://sparklang.dev ## index https://sparklang.dev/llms.txt https://sparklang.dev/llms-full.txt https://sparklang.dev/agent.md https://sparklang.dev/robots.txt ## core # Core Lexical rules, let/print, expect gates, pipelines, and include. This is the smallest useful .spark surface. Does not: Does not train models or call external AI. Verbs: let, print, expect, pipeline, include Example: examples/dry_run.spark ``` model code model train dataset "examples/fixtures/train/dataset.jsonl" base "fixture-base" out "out/train/job-dry-001" backend "http" method "spark_distill_cpu" -> job model status "job-dry-001" -> status expect contains job fixture "examples/fixtures/train/want_accepted.txt" expect contains status fixture "examples/fixtures/train/want_succeeded.txt" ``` ## models # Models model train/status/plan, LoRA methods, trainer contract, and ModelScope inspect/diff/probe/decompile/patch. Does not: Does not load staged adapters into serving without an owner token. Verbs: model train, model status, model inspect, model diff, model probe, model decompile, model patch, model eval, model stage Example: examples/train_sam_lora.spark ``` # VoiceCore reference — Sam store persona LoRA (redacted for public) # Dataset: #321 mini-freeze 140 rows # sha256: 272b64eb1d40aaf8a186df6a2f6c8e7090a1d69d03ac4928ac75a246f8e439f0 # Live trainer: SPARK_TRAIN_URL (host redacted) # Histogram floors of 20 fail on a thin freeze — that is the gate. model code model train dataset "examples/fixtures/train/dataset.jsonl" base "hf://Qwen/Qwen3-27B" out "out/train/job-lora-001" backend "http" method "lora_bf16" -> job model status "job-lora-001" -> status expect gte status $.metrics.golden_bucket 0.8 expect eq status $.metrics.grounding_facts true expect eq status $.metrics.rachel_bleed 0 expect histogram_min status W2a 20 expect histogram_min status W2b 20 expect histogram_min status W-SNC 20 expect histogram_min status W-TF-RECOVER 20 ``` ## ai-ops # AI ops ask, classify, extract, embed/retrieve, tools, and abstain heads. Does not: Does not invent Bifrost task aliases from prompt text. Verbs: ask, classify, extract, embed, retrieve Example: examples/dry_run.spark ``` model code model train dataset "examples/fixtures/train/dataset.jsonl" base "fixture-base" out "out/train/job-dry-001" backend "http" method "spark_distill_cpu" -> job model status "job-dry-001" -> status expect contains job fixture "examples/fixtures/train/want_accepted.txt" expect contains status fixture "examples/fixtures/train/want_succeeded.txt" ``` ## integration # Integration http, shell, and host embed for Python, JS, and C. Does not: Does not open network in dry-run without fixtures. Verbs: http get, http post, shell Example: examples/dry_run.spark ``` model code model train dataset "examples/fixtures/train/dataset.jsonl" base "fixture-base" out "out/train/job-dry-001" backend "http" method "spark_distill_cpu" -> job model status "job-dry-001" -> status expect contains job fixture "examples/fixtures/train/want_accepted.txt" expect contains status fixture "examples/fixtures/train/want_succeeded.txt" ``` ## voice # Voice Voice verbs for speak and related store-persona work. CallsBack workers are a separate product surface. Does not: Does not ship CallsBack.ai workers from this site. Verbs: speak Example: examples/train_sam_lora.spark ``` # VoiceCore reference — Sam store persona LoRA (redacted for public) # Dataset: #321 mini-freeze 140 rows # sha256: 272b64eb1d40aaf8a186df6a2f6c8e7090a1d69d03ac4928ac75a246f8e439f0 # Live trainer: SPARK_TRAIN_URL (host redacted) # Histogram floors of 20 fail on a thin freeze — that is the gate. model code model train dataset "examples/fixtures/train/dataset.jsonl" base "hf://Qwen/Qwen3-27B" out "out/train/job-lora-001" backend "http" method "lora_bf16" -> job model status "job-lora-001" -> status expect gte status $.metrics.golden_bucket 0.8 expect eq status $.metrics.grounding_facts true expect eq status $.metrics.rachel_bleed 0 expect histogram_min status W2a 20 expect histogram_min status W2b 20 expect histogram_min status W-SNC 20 expect histogram_min status W-TF-RECOVER 20 ``` ## ide # IDE IDE verbs that are verified: new, open, save, run, buffer, ask, show. Does not: Paint is PPM wire only — not a language op. Verbs: ide Example: examples/dry_run.spark ``` model code model train dataset "examples/fixtures/train/dataset.jsonl" base "fixture-base" out "out/train/job-dry-001" backend "http" method "spark_distill_cpu" -> job model status "job-dry-001" -> status expect contains job fixture "examples/fixtures/train/want_accepted.txt" expect contains status fixture "examples/fixtures/train/want_succeeded.txt" ``` ## experimental # Experimental Browser/MITM, engine, network, binary, CUDA/PCIe, OS blueprints, and encrypt gateway — each with a status badge. Does not: Experimental pages do not claim production readiness. decompile and patch stay experimental until probe AUROC is at least 0.85. Verbs: model decompile, model patch Example: examples/dry_run.spark ``` model code model train dataset "examples/fixtures/train/dataset.jsonl" base "fixture-base" out "out/train/job-dry-001" backend "http" method "spark_distill_cpu" -> job model status "job-dry-001" -> status expect contains job fixture "examples/fixtures/train/want_accepted.txt" expect contains status fixture "examples/fixtures/train/want_succeeded.txt" ``` ## conformance # Conformance Statement to example file to last CI run. Proof narration lives here, not in product prose. Does not: Does not replace dry-run CI — it reports it. Example: examples/dry_run.spark ``` model code model train dataset "examples/fixtures/train/dataset.jsonl" base "fixture-base" out "out/train/job-dry-001" backend "http" method "spark_distill_cpu" -> job model status "job-dry-001" -> status expect contains job fixture "examples/fixtures/train/want_accepted.txt" expect contains status fixture "examples/fixtures/train/want_succeeded.txt" ``` ## conformance statement reality since grammar model train real 0.6.0 model train dataset "PATH" base "ID" out "DIR" backend "http" method "METHOD" -> job model status real 0.6.0 model status "JOB_ID" -> status model inspect real 0.8.0 model inspect PATH -> summary (CLI: spark-modelscope) model diff real 0.8.0 model diff A B -> delta (adapter heatmap) model probe real 0.8.0 model probe base symbols "DIR" -> p (AUROC < 0.85 = unusable) model decompile experimental 0.8.0 model decompile contrast→vector — EXPERIMENTAL until probe AUROC ≥ 0.85 model patch experimental 0.8.0 model patch vector|rome|memit + scale 0.4–1.2 — EXPERIMENTAL until probe AUROC ≥ 0.85 model eval real 0.8.0 model eval ARTIFACT suite "PATH" -> e model stage real 0.8.0 model stage ARTIFACT marker "ID" -> staged (serving_loaded: false always) expect contains real 0.6.0 expect contains NAME fixture "PATH" expect gte real 0.7.0 expect gte NAME $.path N expect lte real 0.7.0 expect lte NAME $.path N expect eq real 0.7.0 expect eq NAME $.path V expect histogram_min real 0.7.0 expect histogram_min NAME CLASS N expect score real 0.7.0 expect score NAME $.path using "URL" >= N http get real 0.6.0 http get "URL" fixture "PATH" timeout N -> resp http post real 0.6.0 http post "URL" body "{…}" fixture "PATH" timeout N -> resp spark_distill_cpu real 0.6.0 Trainer method — reply-class student → weights.pt spark_pref_pack real 0.6.0 Trainer method — preference pairs + ranker spark_playbook_fit real 0.6.0 Trainer method — intent→playbook router spark_faq_index real 0.6.0 Trainer method — FAQ dual-encoder lora_bf16 real 0.7.0 Trainer method — Unsloth/PEFT LoRA (GPU) or fixture hf:// real 0.7.0 hf://org/name on dataset/base/out (hf_resolve.py) GitHub Action dry-run real 0.7.0 uses: Michael20251/sparklang/.github/actions/dry-run ## grammar.ebnf (* SparkLang homepage verbs — generated from status.py *) program = { statement } ; statement = model_stmt | expect_stmt | http_stmt ; model_stmt = train | status | inspect | diff | probe | decompile | patch | eval | stage ; train = "model", "train", "dataset", string, "base", string, "out", string, "backend", string, [ "method", string ], [ "->", ident ] ; status = "model", "status", string, [ "->", ident ] ; inspect = "model", "inspect", path, [ "->", ident ] ; diff = "model", "diff", path, path, [ "->", ident ] ; probe = "model", "probe", "base", "symbols", string, [ "->", ident ] ; decompile = "model", "decompile", { token } ; (* experimental *) patch = "model", "patch", { token } ; (* experimental *) eval = "model", "eval", ident, "suite", string, [ "->", ident ] ; stage = "model", "stage", ident, "marker", string, [ "->", ident ] ; expect_stmt = contains | gte | lte | eq | histogram_min | score ; contains = "expect", "contains", ident, "fixture", string ; gte = "expect", "gte", ident, jsonpath, number ; lte = "expect", "lte", ident, jsonpath, number ; eq = "expect", "eq", ident, jsonpath, value ; histogram_min = "expect", "histogram_min", ident, ident, number ; score = "expect", "score", ident, jsonpath, "using", string, ">=", number ; http_stmt = http_get | http_post ; http_get = "http", "get", string, [ "fixture", string ], [ "timeout", number ], [ "->", ident ] ; http_post = "http", "post", string, [ "body", string ], [ "fixture", string ], [ "timeout", number ], [ "->", ident ] ; string = '"', { char }, '"' ; ident = letter, { letter | digit | "_" | "-" } ; jsonpath = "$", { ".", ident | "[" , digit, "]" } ; path = string | ident ; value = string | number | "true" | "false" ;