Skip to content
p promptel. github ↗
/// glossary

The vocabulary.

The terms that show up across the docs and DSL, in one place.

.prompt DSL
A small curly-brace domain-specific language for prompts, with the .prompt extension, parsed by a Chevrotain grammar. The human-facing surface: legible in a diff, reviewable block by block.
YAML surface
The equivalent YAML form of a prompt, parsed with js-yaml. Produces the same AST as the DSL and executes identically; preferred by tooling for schema validation and codegen.
PromptAST
The single abstract syntax tree both surfaces parse into: meta, context, params, body, constraints, output, and hooks. Execution runs against the AST, not the source text.
FormatConverter
The utility (promptToYaml / yamlToPrompt) that converts losslessly between the .prompt DSL and YAML, since both map to the same AST.
Typed param
A declared input with a type, optionality, and optional default — e.g. language?: string = "javascript". The executor binds params before dispatch and refuses prompts that do not bind.
Technique block
A node inside body.technique representing a prompt technique. Expanded at execution into concrete instructions while keeping the source legible.
Chain-of-Thought
A technique block (chainOfThought) that structures reasoning into named steps, each with its own text, so the model reasons through a problem in stages.
Few-Shot
A technique block (fewShot) that supplies input/output examples to steer the model by demonstration rather than instruction alone.
ReAct
A technique block (reAct) interleaving reasoning and action steps, used when a prompt needs to alternate between thinking and tool-style operations.
Self-Consistency
A technique block (selfConsistency) that samples multiple completions (samples: N) and reconciles them, trading tokens for robustness.
Tree-of-Thoughts
A technique block (treeOfThoughts) that explores branching reasoning paths rather than a single linear chain.
Harmony Protocol
A harmony block declaring reasoning effort and multi-channel responses (e.g. "final", "analysis", "commentary"), surfaced as structured fields on the result.
Provider abstraction
The createProvider factory over the OpenAI, Anthropic, and Groq SDKs. Selecting a provider at call time swaps the backend without changing the prompt.