newo-dsl-data
v1.0.0
Published
Runtime data (actions, builtins, validation rules, string similarity) for the Newo DSL toolchain.
Readme
newo-dsl-data
Runtime data for the Newo DSL toolchain: the built-in ACTIONS catalog, Jinja builtin list, validation rules, and string-similarity helpers used for "Did you mean?" suggestions.
When to use this package
You rarely need to install this directly. It is a transitive dependency of newo-dsl-analyzer and newo-dsl-lsp.
Install directly only if you need programmatic access to the NSL action catalog outside the analyzer - for example, generating documentation or building a VS Code completion provider by hand.
Install
npm install newo-dsl-dataExports
ACTIONS-Record<string, ActionDefinition>of the 76 built-in NSL actions (SendMessage, Set, GetCustomerAttribute, ...) with parameter schemas, descriptions, categories, and usage examples.JINJA_BUILTINS- Map of 80+ Jinja/Python builtins and filters.VALIDATION_RULES- Per-action required-parameter and constraint metadata.OBJECT_SHAPES- Type-inference shapes for common NSL return values (User, Actor, ChatHistory, ...).levenshteinDistance(a, b),findSimilar(target, candidates, maxDistance?),findSimilarVariable(...)- string-similarity helpers for typo suggestions.
Example
import { ACTIONS, findSimilar } from 'newo-dsl-data';
console.log(ACTIONS.SendMessage.description);
// "Send direct messages to specific actors across all communication channels..."
const suggestions = findSimilar('SndMessage', Object.keys(ACTIONS));
// ['SendMessage', 'SendCommand', ...]Source of truth
ACTIONS is hand-curated in TypeScript (src/actions.ts) and re-exported as actions.schema.yaml for inspection. The TypeScript file is authoritative.
License
Proprietary - Newo AI. All rights reserved.
