STL Documentation

Welcome to the documentation for Semantic Tension Language (STL) and its Python toolkit stl-parser.

STL is a calculable, universal standard for structuring knowledge through directional semantic relations. It introduces a tension-path model where knowledge flows directionally from source to target, carrying semantic magnitude and type information.

[Theory_Relativity] -> [Prediction_TimeDilation] ::mod(
  rule="logical",
  confidence=0.99,
  source="doi:10.1002/andp.19053221004",
  author="Einstein"
)

Unlike JSON or plain text, STL statements are traceable, verifiable, and inference-ready.


Where to Start

New to STL?

  1. Installation — Install stl-parser in under a minute
  2. Quickstart — Parse, build, and validate your first STL statements
  3. Key Concepts — Understand anchors, paths, modifiers, and the tension-path model

Learning STL

Step-by-step tutorials covering every capability:

#TutorialWhat You’ll Learn
01ParsingParse STL text and files, inspect results
02BuildingBuild statements programmatically
03Schema ValidationValidate documents against domain schemas
04LLM PipelineClean and repair LLM-generated output
05QueryingQuery, filter, and select statements
06Streaming I/ORead and write STL streams
07Diff & PatchCompare and patch documents
08CLI ToolsCommand-line workflows

Looking Something Up?

Solving a Specific Problem?


Specifications

Project