UNPKG

agentlang

Version:

The easiest way to build the most reliable AI agents - enterprise-grade teams of AI agents that collaborate with each other and humans

20 lines 1.39 kB
import { AstNode, LangiumCoreServices, LangiumDocument } from 'langium'; import { If, ModuleDefinition, Statement, WorkflowDefinition } from './generated/ast.js'; import { BasePattern, IfPattern } from './syntax.js'; export declare function parseHelper<T extends AstNode = AstNode>(services: LangiumCoreServices): (input: string, options?: any) => Promise<LangiumDocument<T>>; export declare const parse: (input: string, options?: any) => Promise<LangiumDocument<ModuleDefinition>>; export declare function parseModule(moduleDef: string): Promise<ModuleDefinition>; export declare function parseStatement(stmt: string): Promise<Statement>; export declare function parseStatements(stmts: string[]): Promise<Statement[]>; export declare function parseWorkflow(workflowDef: string): Promise<WorkflowDefinition>; export declare function maybeGetValidationErrors(document: LangiumDocument, lines?: string[]): string[] | undefined; export declare function maybeRaiseParserErrors(document: LangiumDocument): void; export declare function introspect(s: string): Promise<BasePattern[]>; export declare function introspectIf(ifpat: If): IfPattern; export type CasePattern = { condition: BasePattern; body: BasePattern; }; export declare function introspectCase(caseStr: string): Promise<CasePattern>; export declare function canParse(s: string): boolean; //# sourceMappingURL=parser.d.ts.map