Saxonberg Server API
    Preparing search index...

    Interface ParseResult

    Result a parser yields. Exactly one of parsed, bound, or error should be set; the dispatcher dispatches on the first non-undefined field.

    • parsed — a tokenized ParsedCommand. The dispatcher runs the full pipeline (match → assemble → resolve → execute). Used by tokenizer-driven parsers (the default msh).
    • bound — a {command, model} pair already chosen by the parser. Dispatcher skips match/assemble and runs only resolve + execute. Used by NL/LLM parsers that decide intent themselves.
    • script — a parsed multi-statement / block-bearing Script AST. The dispatcher routes it to ScriptApi.runAst, which walks it through the interpreter (each command a gated bus dispatch). Produced by the script parser for input msh can't represent (statement separators, standalone { } blocks); a bare single command is delegated to msh and comes back as parsed.
    • error — input couldn't be parsed; the dispatcher emits a command-rejected { reason: 'parse-failed' } note onto the dispatch-response envelope.
    interface ParseResult {
        bound?: { command: CommandDefinition; model: ModelData };
        error?: string;
        parsed?: ParsedCommand;
        script?: { ast: Script };
    }
    Index

    Properties

    bound?: { command: CommandDefinition; model: ModelData }
    error?: string
    parsed?: ParsedCommand
    script?: { ast: Script }