@lokascript/domain-learn 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/dist/generators/gloss-generator.d.ts +18 -0
  2. package/dist/generators/learn-renderer.d.ts +13 -0
  3. package/dist/generators/sentence-generator.d.ts +34 -0
  4. package/dist/index.cjs +6116 -0
  5. package/dist/index.cjs.map +1 -0
  6. package/dist/index.d.cts +441 -0
  7. package/dist/index.d.ts +55 -0
  8. package/dist/index.js +6056 -0
  9. package/dist/index.js.map +1 -0
  10. package/dist/profiles/ar.d.ts +2 -0
  11. package/dist/profiles/de.d.ts +2 -0
  12. package/dist/profiles/en.d.ts +2 -0
  13. package/dist/profiles/es.d.ts +2 -0
  14. package/dist/profiles/fr.d.ts +2 -0
  15. package/dist/profiles/index.d.ts +20 -0
  16. package/dist/profiles/ja.d.ts +2 -0
  17. package/dist/profiles/ko.d.ts +2 -0
  18. package/dist/profiles/pt.d.ts +2 -0
  19. package/dist/profiles/tr.d.ts +2 -0
  20. package/dist/profiles/zh.d.ts +2 -0
  21. package/dist/schemas/index.d.ts +31 -0
  22. package/dist/tokenizers/index.d.ts +23 -0
  23. package/dist/types.d.ts +266 -0
  24. package/package.json +63 -0
  25. package/src/__tests__/schemas.test.ts +145 -0
  26. package/src/__tests__/sentence-generation.test.ts +189 -0
  27. package/src/generators/gloss-generator.ts +145 -0
  28. package/src/generators/learn-renderer.ts +291 -0
  29. package/src/generators/sentence-generator.ts +501 -0
  30. package/src/index.ts +237 -0
  31. package/src/profiles/ar.ts +526 -0
  32. package/src/profiles/de.ts +481 -0
  33. package/src/profiles/en.ts +181 -0
  34. package/src/profiles/es.ts +829 -0
  35. package/src/profiles/fr.ts +466 -0
  36. package/src/profiles/index.ts +34 -0
  37. package/src/profiles/ja.ts +301 -0
  38. package/src/profiles/ko.ts +286 -0
  39. package/src/profiles/pt.ts +484 -0
  40. package/src/profiles/tr.ts +511 -0
  41. package/src/profiles/zh.ts +256 -0
  42. package/src/schemas/index.ts +576 -0
  43. package/src/tokenizers/index.ts +409 -0
  44. package/src/types.ts +321 -0
@@ -0,0 +1,2 @@
1
+ import type { LearnLanguageProfile } from '../types';
2
+ export declare const arProfile: LearnLanguageProfile;
@@ -0,0 +1,2 @@
1
+ import type { LearnLanguageProfile } from '../types';
2
+ export declare const deProfile: LearnLanguageProfile;
@@ -0,0 +1,2 @@
1
+ import type { LearnLanguageProfile } from '../types';
2
+ export declare const enProfile: LearnLanguageProfile;
@@ -0,0 +1,2 @@
1
+ import type { LearnLanguageProfile } from '../types';
2
+ export declare const esProfile: LearnLanguageProfile;
@@ -0,0 +1,2 @@
1
+ import type { LearnLanguageProfile } from '../types';
2
+ export declare const frProfile: LearnLanguageProfile;
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Language Profiles Index
3
+ *
4
+ * Re-exports all 10 language profiles and provides a registry lookup.
5
+ */
6
+ import type { LearnLanguageProfile } from '../types';
7
+ import { enProfile } from './en';
8
+ import { jaProfile } from './ja';
9
+ import { esProfile } from './es';
10
+ import { arProfile } from './ar';
11
+ import { zhProfile } from './zh';
12
+ import { koProfile } from './ko';
13
+ import { frProfile } from './fr';
14
+ import { trProfile } from './tr';
15
+ import { deProfile } from './de';
16
+ import { ptProfile } from './pt';
17
+ export { enProfile, jaProfile, esProfile, arProfile, zhProfile };
18
+ export { koProfile, frProfile, trProfile, deProfile, ptProfile };
19
+ /** All profiles indexed by language code */
20
+ export declare const ALL_PROFILES: Record<string, LearnLanguageProfile>;
@@ -0,0 +1,2 @@
1
+ import type { LearnLanguageProfile } from '../types';
2
+ export declare const jaProfile: LearnLanguageProfile;
@@ -0,0 +1,2 @@
1
+ import type { LearnLanguageProfile } from '../types';
2
+ export declare const koProfile: LearnLanguageProfile;
@@ -0,0 +1,2 @@
1
+ import type { LearnLanguageProfile } from '../types';
2
+ export declare const ptProfile: LearnLanguageProfile;
@@ -0,0 +1,2 @@
1
+ import type { LearnLanguageProfile } from '../types';
2
+ export declare const trProfile: LearnLanguageProfile;
@@ -0,0 +1,2 @@
1
+ import type { LearnLanguageProfile } from '../types';
2
+ export declare const zhProfile: LearnLanguageProfile;
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Learn Domain Command Schemas
3
+ *
4
+ * 15 core verbs formalized as CommandSchemas using the framework's
5
+ * defineCommand/defineRole helpers. Each schema defines the semantic
6
+ * roles and per-language marker overrides for sentence rendering.
7
+ *
8
+ * Role markers are the RESOLVED values combining:
9
+ * - @lokascript/semantic schema markerOverrides (Tiers 1-2)
10
+ * - lokascript-learn LEARNING_OVERRIDES (Tier 3)
11
+ * - LANGUAGE_RENDERING_OVERRIDES (Tier 4)
12
+ * - Profile defaults (Tier 5)
13
+ *
14
+ * This collapses the 5-tier resolution into flat markerOverride maps.
15
+ */
16
+ export declare const addSchema: import("@lokascript/framework").CommandSchema;
17
+ export declare const removeSchema: import("@lokascript/framework").CommandSchema;
18
+ export declare const toggleSchema: import("@lokascript/framework").CommandSchema;
19
+ export declare const putSchema: import("@lokascript/framework").CommandSchema;
20
+ export declare const setSchema: import("@lokascript/framework").CommandSchema;
21
+ export declare const showSchema: import("@lokascript/framework").CommandSchema;
22
+ export declare const hideSchema: import("@lokascript/framework").CommandSchema;
23
+ export declare const getSchema: import("@lokascript/framework").CommandSchema;
24
+ export declare const waitSchema: import("@lokascript/framework").CommandSchema;
25
+ export declare const fetchSchema: import("@lokascript/framework").CommandSchema;
26
+ export declare const sendSchema: import("@lokascript/framework").CommandSchema;
27
+ export declare const goSchema: import("@lokascript/framework").CommandSchema;
28
+ export declare const incrementSchema: import("@lokascript/framework").CommandSchema;
29
+ export declare const decrementSchema: import("@lokascript/framework").CommandSchema;
30
+ export declare const takeSchema: import("@lokascript/framework").CommandSchema;
31
+ export declare const allSchemas: import("@lokascript/framework").CommandSchema[];
@@ -0,0 +1,23 @@
1
+ /**
2
+ * Learn Domain Tokenizers
3
+ *
4
+ * Language-specific tokenizers for learning domain input (10 languages).
5
+ * Created via the framework's createSimpleTokenizer factory.
6
+ *
7
+ * These tokenizers handle:
8
+ * - Command verb keyword classification
9
+ * - Role marker particle/preposition classification
10
+ * - CSS selector recognition (#id, .class)
11
+ * - Non-Latin script handling (Japanese, Arabic, Korean, Chinese)
12
+ */
13
+ import type { LanguageTokenizer } from '@lokascript/framework';
14
+ export declare const EnglishLearnTokenizer: LanguageTokenizer;
15
+ export declare const JapaneseLearnTokenizer: LanguageTokenizer;
16
+ export declare const SpanishLearnTokenizer: LanguageTokenizer;
17
+ export declare const ArabicLearnTokenizer: LanguageTokenizer;
18
+ export declare const ChineseLearnTokenizer: LanguageTokenizer;
19
+ export declare const KoreanLearnTokenizer: LanguageTokenizer;
20
+ export declare const FrenchLearnTokenizer: LanguageTokenizer;
21
+ export declare const TurkishLearnTokenizer: LanguageTokenizer;
22
+ export declare const GermanLearnTokenizer: LanguageTokenizer;
23
+ export declare const PortugueseLearnTokenizer: LanguageTokenizer;
@@ -0,0 +1,266 @@
1
+ /**
2
+ * Domain-Learn Types
3
+ *
4
+ * Types for the learning domain DSL, extending the framework with
5
+ * communicative functions, morphology tables, and sentence rendering.
6
+ */
7
+ /** The 7 communicative functions that exercises can target */
8
+ export type CommunicativeFunction = 'commanding' | 'describing' | 'narrating' | 'questioning' | 'negating' | 'planning' | 'progressing';
9
+ export declare const ALL_FUNCTIONS: readonly CommunicativeFunction[];
10
+ /** The 15 core verbs in the learning domain */
11
+ export type CoreVerb = 'add' | 'remove' | 'toggle' | 'put' | 'set' | 'show' | 'hide' | 'get' | 'wait' | 'fetch' | 'send' | 'go' | 'increment' | 'decrement' | 'take';
12
+ export declare const ALL_VERBS: readonly CoreVerb[];
13
+ export type SemanticRole = 'patient' | 'destination' | 'source' | 'instrument' | 'possessive' | 'manner' | 'style';
14
+ export type VerbValence = 'intransitive' | 'transitive' | 'ditransitive';
15
+ export interface CommandProfile {
16
+ verb: CoreVerb;
17
+ valence: VerbValence;
18
+ targetRole: SemanticRole | null;
19
+ hasPatient: boolean;
20
+ }
21
+ export interface SentenceFrame {
22
+ function: CommunicativeFunction;
23
+ template: string;
24
+ verbForm: string;
25
+ example: string;
26
+ }
27
+ export interface LanguageFrames {
28
+ code: string;
29
+ wordOrder: 'SVO' | 'SOV' | 'VSO';
30
+ frames: SentenceFrame[];
31
+ }
32
+ export interface RenderedSentence {
33
+ language: string;
34
+ function: CommunicativeFunction;
35
+ sentence: string;
36
+ verbForm: string;
37
+ verbValue: string;
38
+ }
39
+ export interface InterlinearGloss {
40
+ tokens: string[];
41
+ roles: string[];
42
+ english: string[];
43
+ }
44
+ export interface EnglishForms {
45
+ base: string;
46
+ thirdPerson: string;
47
+ past: string;
48
+ pastParticiple: string;
49
+ presentParticiple: string;
50
+ }
51
+ export interface JapaneseForms {
52
+ dictionary: string;
53
+ verbClass: 'godan' | 'ichidan' | 'suru' | 'kuru' | 'special';
54
+ stem: string;
55
+ masu: string;
56
+ mashita: string;
57
+ ta: string;
58
+ te: string;
59
+ nai: string;
60
+ masen: string;
61
+ potential: string;
62
+ volitional: string;
63
+ ba: string;
64
+ tara: string;
65
+ }
66
+ export interface SpanishPersonForms {
67
+ yo: string;
68
+ tu: string;
69
+ el: string;
70
+ nosotros: string;
71
+ vosotros: string;
72
+ ellos: string;
73
+ }
74
+ export interface SpanishForms {
75
+ infinitive: string;
76
+ verbClass: 'ar' | 'er' | 'ir';
77
+ irregular: boolean;
78
+ present: SpanishPersonForms;
79
+ preterite: SpanishPersonForms;
80
+ imperfect: SpanishPersonForms;
81
+ future: SpanishPersonForms;
82
+ imperative: {
83
+ tu: string;
84
+ usted: string;
85
+ ustedes: string;
86
+ };
87
+ gerund: string;
88
+ pastParticiple: {
89
+ ms: string;
90
+ fs: string;
91
+ mp: string;
92
+ fp: string;
93
+ };
94
+ }
95
+ export interface ArabicPersonForms {
96
+ howa: string;
97
+ hiya: string;
98
+ anta: string;
99
+ anti: string;
100
+ ana: string;
101
+ hum: string;
102
+ nahnu: string;
103
+ }
104
+ export interface ArabicForms {
105
+ root: string;
106
+ form: 'I' | 'II' | 'III' | 'IV' | 'V' | 'VI' | 'VII' | 'VIII' | 'X';
107
+ past: ArabicPersonForms;
108
+ present: ArabicPersonForms;
109
+ imperative: {
110
+ ms: string;
111
+ fs: string;
112
+ mp: string;
113
+ };
114
+ activeParticiple: string;
115
+ passiveParticiple: string;
116
+ masdar: string;
117
+ }
118
+ export interface ChineseForms {
119
+ base: string;
120
+ pinyin: string;
121
+ patterns: {
122
+ completed: string;
123
+ experience: string;
124
+ progressive: string;
125
+ future: string;
126
+ negPresent: string;
127
+ negPast: string;
128
+ };
129
+ }
130
+ export interface KoreanForms {
131
+ dictionary: string;
132
+ verbClass: 'hada' | 'native' | 'special';
133
+ stem: string;
134
+ hapnida: string;
135
+ haesseumnida: string;
136
+ haeyo: string;
137
+ haesseoyo: string;
138
+ imperative: string;
139
+ past: string;
140
+ negative: string;
141
+ progressive: string;
142
+ future: string;
143
+ }
144
+ export interface FrenchPersonForms {
145
+ je: string;
146
+ tu: string;
147
+ il: string;
148
+ nous: string;
149
+ vous: string;
150
+ ils: string;
151
+ }
152
+ export interface FrenchForms {
153
+ infinitive: string;
154
+ imperative: {
155
+ tu: string;
156
+ vous: string;
157
+ };
158
+ present: FrenchPersonForms;
159
+ passeCompose: {
160
+ il: string;
161
+ je: string;
162
+ };
163
+ imparfait: {
164
+ il: string;
165
+ };
166
+ futur: {
167
+ il: string;
168
+ };
169
+ gerondif: string;
170
+ }
171
+ export interface TurkishForms {
172
+ dictionary: string;
173
+ imperative: {
174
+ sen: string;
175
+ siz: string;
176
+ };
177
+ present: {
178
+ ben: string;
179
+ sen: string;
180
+ o: string;
181
+ biz: string;
182
+ siz: string;
183
+ onlar: string;
184
+ };
185
+ past: {
186
+ o: string;
187
+ ben: string;
188
+ };
189
+ future: {
190
+ o: string;
191
+ };
192
+ negative: {
193
+ o: string;
194
+ };
195
+ progressive: {
196
+ o: string;
197
+ };
198
+ gerund: string;
199
+ }
200
+ export interface GermanPersonForms {
201
+ ich: string;
202
+ du: string;
203
+ er: string;
204
+ wir: string;
205
+ ihr: string;
206
+ sie: string;
207
+ }
208
+ export interface GermanForms {
209
+ infinitive: string;
210
+ separablePrefix: string;
211
+ imperative: {
212
+ du: string;
213
+ Sie: string;
214
+ };
215
+ present: GermanPersonForms;
216
+ past: {
217
+ ich: string;
218
+ er: string;
219
+ };
220
+ perfect: {
221
+ er: string;
222
+ };
223
+ future: {
224
+ er: string;
225
+ };
226
+ presentParticiple: string;
227
+ }
228
+ export interface PortuguesePersonForms {
229
+ eu: string;
230
+ voce: string;
231
+ ele: string;
232
+ nos: string;
233
+ voces: string;
234
+ eles: string;
235
+ }
236
+ export interface PortugueseForms {
237
+ infinitive: string;
238
+ imperative: {
239
+ voce: string;
240
+ voces: string;
241
+ };
242
+ present: PortuguesePersonForms;
243
+ preterite: {
244
+ ele: string;
245
+ eu: string;
246
+ };
247
+ imperfect: {
248
+ ele: string;
249
+ };
250
+ future: {
251
+ ele: string;
252
+ };
253
+ gerund: string;
254
+ }
255
+ export type AnyForms = EnglishForms | JapaneseForms | SpanishForms | ArabicForms | ChineseForms | KoreanForms | FrenchForms | TurkishForms | GermanForms | PortugueseForms;
256
+ import type { PatternGenLanguageProfile } from '@lokascript/framework';
257
+ export interface LearnLanguageProfile {
258
+ /** Base framework profile for pattern generation */
259
+ patternProfile: PatternGenLanguageProfile;
260
+ /** Morphology table: verb → conjugation forms */
261
+ morphologyTable: Record<string, AnyForms>;
262
+ /** Sentence frames per communicative function */
263
+ frames: LanguageFrames;
264
+ /** Default sentence subject */
265
+ defaultSubject: string;
266
+ }
package/package.json ADDED
@@ -0,0 +1,63 @@
1
+ {
2
+ "name": "@lokascript/domain-learn",
3
+ "version": "2.1.0",
4
+ "description": "Multilingual learning domain DSL — morphology, sentence generation, and exercise support for 15 verbs × 10 languages × 7 communicative functions",
5
+ "type": "module",
6
+ "sideEffects": false,
7
+ "main": "dist/index.cjs",
8
+ "module": "dist/index.js",
9
+ "types": "dist/index.d.ts",
10
+ "exports": {
11
+ ".": {
12
+ "types": "./dist/index.d.ts",
13
+ "import": "./dist/index.js",
14
+ "require": "./dist/index.cjs"
15
+ }
16
+ },
17
+ "scripts": {
18
+ "build": "tsup && npm run build:types",
19
+ "build:types": "tsc --emitDeclarationOnly --outDir dist --noEmit false",
20
+ "test": "vitest",
21
+ "test:run": "vitest run",
22
+ "test:check": "vitest run --reporter=dot 2>&1 | tail -5",
23
+ "typecheck": "tsc --noEmit"
24
+ },
25
+ "dependencies": {
26
+ "@lokascript/framework": "*"
27
+ },
28
+ "devDependencies": {
29
+ "@types/node": "^20.0.0",
30
+ "tsup": "^8.0.0",
31
+ "typescript": "^5.0.0",
32
+ "vitest": "^4.0.0"
33
+ },
34
+ "files": [
35
+ "dist",
36
+ "src",
37
+ "LICENSE"
38
+ ],
39
+ "keywords": [
40
+ "learning",
41
+ "morphology",
42
+ "multilingual",
43
+ "dsl",
44
+ "i18n",
45
+ "exercises",
46
+ "conjugation",
47
+ "lokascript",
48
+ "framework"
49
+ ],
50
+ "author": "LokaScript Contributors",
51
+ "license": "MIT",
52
+ "repository": {
53
+ "type": "git",
54
+ "url": "git+https://github.com/codetalcott/hyperfixi.git",
55
+ "directory": "packages/domain-learn"
56
+ },
57
+ "engines": {
58
+ "node": ">=18.0.0"
59
+ },
60
+ "publishConfig": {
61
+ "access": "public"
62
+ }
63
+ }
@@ -0,0 +1,145 @@
1
+ /**
2
+ * Schema Tests — Verify all 15 verbs parse in all 10 languages
3
+ */
4
+
5
+ import { describe, it, expect, beforeAll } from 'vitest';
6
+ import { createLearnDSL, ALL_VERBS } from '../index';
7
+ import type { MultilingualDSL } from '@lokascript/framework';
8
+ import { extractRoleValue } from '@lokascript/framework';
9
+
10
+ describe('Learn Domain Schemas', () => {
11
+ let learn: MultilingualDSL;
12
+
13
+ beforeAll(() => {
14
+ learn = createLearnDSL();
15
+ });
16
+
17
+ describe('Language Support', () => {
18
+ it('should support 10 languages', () => {
19
+ const languages = learn.getSupportedLanguages();
20
+ expect(languages).toHaveLength(10);
21
+ expect(languages).toContain('en');
22
+ expect(languages).toContain('ja');
23
+ expect(languages).toContain('es');
24
+ expect(languages).toContain('ar');
25
+ expect(languages).toContain('zh');
26
+ expect(languages).toContain('ko');
27
+ expect(languages).toContain('fr');
28
+ expect(languages).toContain('tr');
29
+ expect(languages).toContain('de');
30
+ expect(languages).toContain('pt');
31
+ });
32
+
33
+ it('should have all 15 verbs defined', () => {
34
+ expect(ALL_VERBS).toHaveLength(15);
35
+ });
36
+ });
37
+
38
+ describe('English Parsing (SVO)', () => {
39
+ it('should parse "add active to button"', () => {
40
+ const node = learn.parse('add active to button', 'en');
41
+ expect(node.action).toBe('add');
42
+ });
43
+
44
+ it('should parse "remove active from button"', () => {
45
+ const node = learn.parse('remove active from button', 'en');
46
+ expect(node.action).toBe('remove');
47
+ });
48
+
49
+ it('should parse "toggle active on button"', () => {
50
+ const node = learn.parse('toggle active on button', 'en');
51
+ expect(node.action).toBe('toggle');
52
+ });
53
+
54
+ it('should parse "show message"', () => {
55
+ const node = learn.parse('show message', 'en');
56
+ expect(node.action).toBe('show');
57
+ });
58
+
59
+ it('should parse "hide menu"', () => {
60
+ const node = learn.parse('hide menu', 'en');
61
+ expect(node.action).toBe('hide');
62
+ });
63
+
64
+ it('should parse "get data"', () => {
65
+ const node = learn.parse('get data', 'en');
66
+ expect(node.action).toBe('get');
67
+ });
68
+
69
+ it('should parse "send event to target"', () => {
70
+ const node = learn.parse('send event to target', 'en');
71
+ expect(node.action).toBe('send');
72
+ });
73
+
74
+ it('should parse "increment counter"', () => {
75
+ const node = learn.parse('increment counter', 'en');
76
+ expect(node.action).toBe('increment');
77
+ });
78
+ });
79
+
80
+ describe('Explicit Syntax', () => {
81
+ it('should parse explicit syntax for add', () => {
82
+ const node = learn.parse('[add patient:.active destination:#button]', 'explicit');
83
+ expect(node.action).toBe('add');
84
+ expect(extractRoleValue(node, 'patient')).toBe('.active');
85
+ expect(extractRoleValue(node, 'destination')).toBe('#button');
86
+ });
87
+
88
+ it('should parse explicit syntax for ditransitive verbs', () => {
89
+ const ditransitive = [
90
+ { verb: 'add', roles: 'patient:.active destination:#btn' },
91
+ { verb: 'remove', roles: 'patient:.active source:#btn' },
92
+ { verb: 'toggle', roles: 'patient:.active destination:#btn' },
93
+ { verb: 'put', roles: 'patient:.item destination:#box' },
94
+ { verb: 'set', roles: 'destination:#prop patient:value' },
95
+ { verb: 'send', roles: 'patient:.event destination:#target' },
96
+ { verb: 'take', roles: 'patient:.item source:#shelf' },
97
+ ];
98
+ for (const { verb, roles } of ditransitive) {
99
+ const node = learn.parse(`[${verb} ${roles}]`, 'explicit');
100
+ expect(node.action).toBe(verb);
101
+ }
102
+ });
103
+
104
+ it('should parse explicit syntax for transitive verbs', () => {
105
+ const transitive = [
106
+ { verb: 'show', roles: 'patient:.msg' },
107
+ { verb: 'hide', roles: 'patient:.msg' },
108
+ { verb: 'get', roles: 'source:#data' },
109
+ { verb: 'wait', roles: 'patient:1000' },
110
+ { verb: 'fetch', roles: 'source:#api' },
111
+ { verb: 'go', roles: 'destination:#page' },
112
+ { verb: 'increment', roles: 'patient:.counter' },
113
+ { verb: 'decrement', roles: 'patient:.counter' },
114
+ ];
115
+ for (const { verb, roles } of transitive) {
116
+ const node = learn.parse(`[${verb} ${roles}]`, 'explicit');
117
+ expect(node.action).toBe(verb);
118
+ }
119
+ });
120
+ });
121
+
122
+ describe('Code Generation', () => {
123
+ it('should generate English commanding form', () => {
124
+ const result = learn.compile('[add patient:.active destination:#button]', 'explicit');
125
+ expect(result.ok).toBe(true);
126
+ expect(result.code).toContain('add');
127
+ });
128
+
129
+ it('should compile all verbs from explicit syntax', () => {
130
+ const testCases = [
131
+ '[add patient:.active destination:#button]',
132
+ '[remove patient:.active source:#button]',
133
+ '[show patient:.message]',
134
+ '[hide patient:.menu]',
135
+ '[get source:#data]',
136
+ '[go destination:#page]',
137
+ '[increment patient:.counter]',
138
+ ];
139
+ for (const input of testCases) {
140
+ const result = learn.compile(input, 'explicit');
141
+ expect(result.ok).toBe(true);
142
+ }
143
+ });
144
+ });
145
+ });