tml 5.2.7 → 5.4.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,34 +1,49 @@
1
- {"locale":"en",
2
- "name":"English",
3
- "flag_url": "https://translationexchange.com/media/7/55/1/27/c9262c9538cda82c6.png",
4
- "contexts":{
5
- "date":{
6
- "keyword":"date",
7
- "keys":[
8
- "past",
9
- "present",
10
- "future"
1
+ {
2
+ "id": 64,
3
+ "locale": "en",
4
+ "english_name": "English",
5
+ "native_name": "English",
6
+ "right_to_left": false,
7
+ "flag_url": "https://cdn.translationexchange.com/flags/default/languages/16/en.png",
8
+ "contexts": {
9
+ "list": {
10
+ "rules": {
11
+ "one": {
12
+ "description": "{token} contains 1 element",
13
+ "conditions": "(= 1 @count)",
14
+ "conditions_expression": [
15
+ "=",
16
+ 1,
17
+ "@count"
18
+ ]
19
+ },
20
+ "other": {
21
+ "description": "{token} contains at least 2 elements"
22
+ }
23
+ },
24
+ "keys": [
25
+ "one",
26
+ "other"
11
27
  ],
12
- "default_key":"present",
13
- "token_expression":"/.*(date|time)(\\d)*$/",
14
- "variables":[
15
- "@date"
28
+ "default_key": "other",
29
+ "token_expression": "/.*(items|list)(\\d)*$/",
30
+ "variables": [
31
+ "@count"
16
32
  ],
17
- "token_mapping":[
18
- "unsupported",
33
+ "token_mapping": [
19
34
  "unsupported",
20
35
  {
21
- "past":"{$0}",
22
- "present":"{$1}",
23
- "future":"{$2}"
36
+ "one": "{$0}",
37
+ "other": "{$1}"
24
38
  }
25
- ],
26
- "rules":{
27
- "future":{
28
- "keyword":"future",
29
- "description":"{token} is in the past",
30
- "conditions":"(< @date (today))",
31
- "conditions_expression":[
39
+ ]
40
+ },
41
+ "date": {
42
+ "rules": {
43
+ "future": {
44
+ "description": "{token} is in the past",
45
+ "conditions": "(< @date (today))",
46
+ "conditions_expression": [
32
47
  "<",
33
48
  "@date",
34
49
  [
@@ -36,127 +51,142 @@
36
51
  ]
37
52
  ]
38
53
  },
39
- "past":{
40
- "keyword":"past",
41
- "description":"{token} is in the future",
42
- "conditions":"(> @date (today))",
43
- "conditions_expression":[
44
- ">",
54
+ "present": {
55
+ "description": "{token} is in the present",
56
+ "conditions": "(= @date (today))",
57
+ "conditions_expression": [
58
+ "=",
45
59
  "@date",
46
60
  [
47
61
  "today"
48
62
  ]
49
63
  ]
50
64
  },
51
- "present":{
52
- "keyword":"present",
53
- "description":"{token} is in the present",
54
- "conditions":"(= @date (today))",
55
- "conditions_expression":[
56
- "=",
65
+ "past": {
66
+ "description": "{token} is in the future",
67
+ "conditions": "(> @date (today))",
68
+ "conditions_expression": [
69
+ ">",
57
70
  "@date",
58
71
  [
59
72
  "today"
60
73
  ]
61
74
  ]
62
75
  }
63
- }
64
- },
65
- "gender":{
66
- "keyword":"gender",
67
- "keys":[
68
- "male",
69
- "female",
70
- "other"
76
+ },
77
+ "keys": [
78
+ "past",
79
+ "present",
80
+ "future"
71
81
  ],
72
- "default_key":"other",
73
- "token_expression":"/.*(user|translator|profile|actor|target)(\\d)*$/",
74
- "variables":[
75
- "@gender"
82
+ "default_key": "present",
83
+ "token_expression": "/.*(date|time)(\\d)*$/",
84
+ "variables": [
85
+ "@date"
76
86
  ],
77
- "token_mapping":[
87
+ "token_mapping": [
88
+ "unsupported",
89
+ "unsupported",
78
90
  {
79
- "other":"{$0}"
91
+ "past": "{$0}",
92
+ "present": "{$1}",
93
+ "future": "{$2}"
94
+ }
95
+ ]
96
+ },
97
+ "number": {
98
+ "rules": {
99
+ "one": {
100
+ "description": "{token} is 1",
101
+ "examples": "1",
102
+ "conditions": "(= @n 1)",
103
+ "conditions_expression": [
104
+ "=",
105
+ "@n",
106
+ 1
107
+ ]
80
108
  },
109
+ "other": {
110
+ "description": "{token} is not 1",
111
+ "examples": "0, 2-999; 1.2, 2.07..."
112
+ }
113
+ },
114
+ "keys": [
115
+ "one",
116
+ "other"
117
+ ],
118
+ "default_key": "other",
119
+ "token_expression": "/.*(count|num|minutes|seconds|hours|sum|total)(\\d)*$/",
120
+ "variables": [
121
+ "@n"
122
+ ],
123
+ "token_mapping": [
81
124
  {
82
- "male":"{$0}",
83
- "female":"{$1}",
84
- "other":"{$0}/{$1}"
125
+ "one": "{$0}",
126
+ "other": "{$0::plural}"
85
127
  },
86
128
  {
87
- "male":"{$0}",
88
- "female":"{$1}",
89
- "other":"{$2}"
129
+ "one": "{$0}",
130
+ "other": "{$1}"
90
131
  }
91
- ],
92
- "rules":{
93
- "male":{
94
- "keyword":"male",
95
- "description":"{token} is a male",
96
- "conditions":"(= 'male' @gender)",
97
- "conditions_expression":[
132
+ ]
133
+ },
134
+ "gender": {
135
+ "rules": {
136
+ "female": {
137
+ "description": "{token} is a female",
138
+ "conditions": "(= 'female' @gender)",
139
+ "conditions_expression": [
98
140
  "=",
99
- "male",
141
+ "female",
100
142
  "@gender"
101
143
  ]
102
144
  },
103
- "female":{
104
- "keyword":"female",
105
- "description":"{token} is a female",
106
- "conditions":"(= 'female' @gender)",
107
- "conditions_expression":[
145
+ "male": {
146
+ "description": "{token} is a male",
147
+ "conditions": "(= 'male' @gender)",
148
+ "conditions_expression": [
108
149
  "=",
109
- "female",
150
+ "male",
110
151
  "@gender"
111
152
  ]
112
153
  },
113
- "other":{
114
- "keyword":"other",
115
- "description":"{token}'s gender is unknown"
154
+ "other": {
155
+ "description": "{token}'s gender is unknown"
116
156
  }
117
- }
118
- },
119
- "genders":{
120
- "keyword":"genders",
121
- "description":"",
122
- "keys":[
157
+ },
158
+ "keys": [
123
159
  "male",
124
160
  "female",
125
- "unknown",
126
161
  "other"
127
162
  ],
128
- "default_key":"other",
129
- "token_expression":"/.*(users|profiles|actors|targets)(\\d)*$/",
130
- "variables":[
131
- "@genders"
163
+ "default_key": "other",
164
+ "token_expression": "/.*(user|translator|profile|actor|target)(\\d)*$/",
165
+ "variables": [
166
+ "@gender"
132
167
  ],
133
- "token_mapping":[
134
- "unsupported",
168
+ "token_mapping": [
135
169
  {
136
- "male":"{$0}",
137
- "female":"{$0}",
138
- "unknown":"{$1}",
139
- "other":"{$1}"
170
+ "other": "{$0}"
140
171
  },
141
172
  {
142
- "male":"{$0}",
143
- "female":"{$1}",
144
- "unknown":"{$1}",
145
- "other":"{$2}"
173
+ "male": "{$0}",
174
+ "female": "{$1}",
175
+ "other": "{$0}/{$1}"
146
176
  },
147
177
  {
148
- "male":"{$0}",
149
- "female":"{$1}",
150
- "unknown":"{$2}",
151
- "other":"{$3}"
178
+ "male": "{$0}",
179
+ "female": "{$1}",
180
+ "other": "{$2}"
152
181
  }
153
- ],
154
- "rules":{
155
- "male":{
156
- "keyword":"male",
157
- "description":"{token} contains 1 male",
158
- "conditions":"(&& (= 1 (count @genders)) (all @genders 'male'))",
159
- "conditions_expression":[
182
+ ]
183
+ },
184
+ "genders": {
185
+ "rules": {
186
+ "female": {
187
+ "description": "{token} contains 1 female",
188
+ "conditions": "(&& (= 1 (count @genders)) (all @genders 'female'))",
189
+ "conditions_expression": [
160
190
  "&&",
161
191
  [
162
192
  "=",
@@ -169,15 +199,14 @@
169
199
  [
170
200
  "all",
171
201
  "@genders",
172
- "male"
202
+ "female"
173
203
  ]
174
204
  ]
175
205
  },
176
- "female":{
177
- "keyword":"female",
178
- "description":"{token} contains 1 female",
179
- "conditions":"(&& (= 1 (count @genders)) (all @genders 'female'))",
180
- "conditions_expression":[
206
+ "male": {
207
+ "description": "{token} contains 1 male",
208
+ "conditions": "(&& (= 1 (count @genders)) (all @genders 'male'))",
209
+ "conditions_expression": [
181
210
  "&&",
182
211
  [
183
212
  "=",
@@ -190,15 +219,17 @@
190
219
  [
191
220
  "all",
192
221
  "@genders",
193
- "female"
222
+ "male"
194
223
  ]
195
224
  ]
196
225
  },
197
- "unknown":{
198
- "keyword":"unknown",
199
- "description":"{token} contains 1 person with unknown gender",
200
- "conditions":"(&& (= 1 (count @genders)) (all @genders 'unknown'))",
201
- "conditions_expression":[
226
+ "other": {
227
+ "description": "{token} contains at least 2 people"
228
+ },
229
+ "unknown": {
230
+ "description": "{token} contains 1 person with unknown gender",
231
+ "conditions": "(&& (= 1 (count @genders)) (all @genders 'unknown'))",
232
+ "conditions_expression": [
202
233
  "&&",
203
234
  [
204
235
  "=",
@@ -214,172 +245,178 @@
214
245
  "unknown"
215
246
  ]
216
247
  ]
217
- },
218
- "other":{
219
- "keyword":"other",
220
- "description":"{token} contains at least 2 people"
221
248
  }
222
- }
223
- },
224
- "list":{
225
- "keyword":"list",
226
- "keys":[
227
- "one",
249
+ },
250
+ "keys": [
251
+ "male",
252
+ "female",
253
+ "unknown",
228
254
  "other"
229
255
  ],
230
- "default_key":"other",
231
- "token_expression":"/.*(items|list)(\\d)*$/",
232
- "variables":[
233
- "@count"
256
+ "default_key": "other",
257
+ "token_expression": "/.*(users|profiles|actors|targets)(\\d)*$/",
258
+ "variables": [
259
+ "@genders"
234
260
  ],
235
- "token_mapping":[
236
- "unsupported",
261
+ "token_mapping": [
262
+ {
263
+ "male": "{$0}",
264
+ "female": "{$0}",
265
+ "unknown": "{$0}",
266
+ "other": "{$0}"
267
+ },
268
+ {
269
+ "male": "{$0}",
270
+ "female": "{$0}",
271
+ "unknown": "{$0}",
272
+ "other": "{$1}"
273
+ },
237
274
  {
238
- "one":"{$0}",
239
- "other":"{$1}"
275
+ "male": "{$0}",
276
+ "female": "{$1}",
277
+ "unknown": "{$0}/{$1}",
278
+ "other": "{$2}"
279
+ },
280
+ {
281
+ "male": "{$0}",
282
+ "female": "{$1}",
283
+ "unknown": "{$2}",
284
+ "other": "{$3}"
240
285
  }
241
- ],
242
- "rules":{
243
- "one":{
244
- "keyword":"one",
245
- "description":"{token} contains 1 element",
246
- "conditions":"(= 1 @count)",
247
- "conditions_expression":[
286
+ ]
287
+ }
288
+ },
289
+ "cases": {
290
+ "times": {
291
+ "rules": [
292
+ {
293
+ "description": "replace '1' with 'once'",
294
+ "conditions": "(= 1 @value)",
295
+ "conditions_expression": [
248
296
  "=",
249
297
  1,
250
- "@count"
298
+ "@value"
299
+ ],
300
+ "operations": "(replace '1' 'once' @value)",
301
+ "operations_expression": [
302
+ "replace",
303
+ "1",
304
+ "once",
305
+ "@value"
251
306
  ]
252
307
  },
253
- "other":{
254
- "keyword":"other",
255
- "description":"{token} contains at least 2 elements"
256
- }
257
- }
258
- },
259
- "number":{
260
- "keyword":"number",
261
- "keys":[
262
- "one",
263
- "other"
264
- ],
265
- "default_key":"other",
266
- "token_expression":"/.*(count|num|minutes|seconds|hours|sum|total)(\\d)*$/",
267
- "variables":[
268
- "@n"
269
- ],
270
- "token_mapping":[
271
- {
272
- "one":"{$0}",
273
- "other":"{$0::plural}"
274
- },
275
308
  {
276
- "one":"{$0}",
277
- "other":"{$1}"
278
- }
279
- ],
280
- "rules":{
281
- "one":{
282
- "keyword":"one",
283
- "description":"{token} is 1",
284
- "examples":"1",
285
- "conditions":"(= @n 1)",
286
- "conditions_expression":[
309
+ "description": "replace '2' with 'twice'",
310
+ "conditions": "(= 2 @value)",
311
+ "conditions_expression": [
287
312
  "=",
288
- "@n",
289
- 1
313
+ 2,
314
+ "@value"
315
+ ],
316
+ "operations": "(replace '2' 'twice' @value)",
317
+ "operations_expression": [
318
+ "replace",
319
+ "2",
320
+ "twice",
321
+ "@value"
290
322
  ]
291
323
  },
292
- "other":{
293
- "keyword":"other",
294
- "description":"{token} is not 1",
295
- "examples":"0, 2-999; 1.2, 2.07..."
324
+ {
325
+ "description": "in all other cases, append x times",
326
+ "conditions": "(true)",
327
+ "conditions_expression": [
328
+ "true"
329
+ ],
330
+ "operations": "(append ' times' @value)",
331
+ "operations_expression": [
332
+ "append",
333
+ " times",
334
+ "@value"
335
+ ]
296
336
  }
297
- }
298
- }
299
- },
300
- "cases":{
301
- "plural":{
302
- "keyword":"plural",
303
- "latin_name":"Plural",
304
- "description":"Converts singular form to plural",
305
- "application":"phrase",
306
- "rules":[
307
- {
308
- "description":"Uncountable word",
309
- "conditions":"(in 'sheep,fish,series,species,money,rice,information,equipment' @value)",
310
- "conditions_expression":[
337
+ ],
338
+ "latin_name": "Iteration",
339
+ "description": "The iteration form of the cardinal numbers",
340
+ "application": "phrase"
341
+ },
342
+ "plural": {
343
+ "rules": [
344
+ {
345
+ "description": "Uncountable word",
346
+ "conditions": "(in 'sheep,fish,series,species,money,rice,information,equipment' @value)",
347
+ "conditions_expression": [
311
348
  "in",
312
349
  "sheep,fish,series,species,money,rice,information,equipment",
313
350
  "@value"
314
351
  ],
315
- "operations":"@value",
316
- "operations_expression":"@value"
352
+ "operations": "@value",
353
+ "operations_expression": "@value"
317
354
  },
318
355
  {
319
- "description":"Irregular word",
320
- "conditions":"(= 'move' @value)",
321
- "conditions_expression":[
356
+ "description": "Irregular word",
357
+ "conditions": "(= 'move' @value)",
358
+ "conditions_expression": [
322
359
  "=",
323
360
  "move",
324
361
  "@value"
325
362
  ],
326
- "operations":"(quote 'moves')",
327
- "operations_expression":[
363
+ "operations": "(quote 'moves')",
364
+ "operations_expression": [
328
365
  "quote",
329
366
  "moves"
330
367
  ]
331
368
  },
332
369
  {
333
- "description":"Irregular word",
334
- "conditions":"(= 'sex' @value)",
335
- "conditions_expression":[
370
+ "description": "Irregular word",
371
+ "conditions": "(= 'sex' @value)",
372
+ "conditions_expression": [
336
373
  "=",
337
374
  "sex",
338
375
  "@value"
339
376
  ],
340
- "operations":"(quote 'sexes')",
341
- "operations_expression":[
377
+ "operations": "(quote 'sexes')",
378
+ "operations_expression": [
342
379
  "quote",
343
380
  "sexes"
344
381
  ]
345
382
  },
346
383
  {
347
- "description":"Irregular word",
348
- "conditions":"(= 'child' @value)",
349
- "conditions_expression":[
384
+ "description": "Irregular word",
385
+ "conditions": "(= 'child' @value)",
386
+ "conditions_expression": [
350
387
  "=",
351
388
  "child",
352
389
  "@value"
353
390
  ],
354
- "operations":"(quote 'children')",
355
- "operations_expression":[
391
+ "operations": "(quote 'children')",
392
+ "operations_expression": [
356
393
  "quote",
357
394
  "children"
358
395
  ]
359
396
  },
360
397
  {
361
- "description":"Irregular word",
362
- "conditions":"(= 'person' @value)",
363
- "conditions_expression":[
398
+ "description": "Irregular word",
399
+ "conditions": "(= 'person' @value)",
400
+ "conditions_expression": [
364
401
  "=",
365
402
  "person",
366
403
  "@value"
367
404
  ],
368
- "operations":"(quote 'people')",
369
- "operations_expression":[
405
+ "operations": "(quote 'people')",
406
+ "operations_expression": [
370
407
  "quote",
371
408
  "people"
372
409
  ]
373
410
  },
374
411
  {
375
- "conditions":"(match '/(quiz)$/i' @value)",
376
- "conditions_expression":[
412
+ "conditions": "(match '/(quiz)$/i' @value)",
413
+ "conditions_expression": [
377
414
  "match",
378
415
  "/(quiz)$/i",
379
416
  "@value"
380
417
  ],
381
- "operations":"(replace '/(quiz)$/i' '$1zes' @value)",
382
- "operations_expression":[
418
+ "operations": "(replace '/(quiz)$/i' '$1zes' @value)",
419
+ "operations_expression": [
383
420
  "replace",
384
421
  "/(quiz)$/i",
385
422
  "$1zes",
@@ -387,14 +424,14 @@
387
424
  ]
388
425
  },
389
426
  {
390
- "conditions":"(match '/^(ox)$/i' @value)",
391
- "conditions_expression":[
427
+ "conditions": "(match '/^(ox)$/i' @value)",
428
+ "conditions_expression": [
392
429
  "match",
393
430
  "/^(ox)$/i",
394
431
  "@value"
395
432
  ],
396
- "operations":"(replace '/^(ox)$/i' '$1en' @value)",
397
- "operations_expression":[
433
+ "operations": "(replace '/^(ox)$/i' '$1en' @value)",
434
+ "operations_expression": [
398
435
  "replace",
399
436
  "/^(ox)$/i",
400
437
  "$1en",
@@ -402,14 +439,14 @@
402
439
  ]
403
440
  },
404
441
  {
405
- "conditions":"(match '/([m|l])ouse$/i' @value)",
406
- "conditions_expression":[
442
+ "conditions": "(match '/([m|l])ouse$/i' @value)",
443
+ "conditions_expression": [
407
444
  "match",
408
445
  "/([m|l])ouse$/i",
409
446
  "@value"
410
447
  ],
411
- "operations":"(replace '/([m|l])ouse$/i' '$1ice' @value)",
412
- "operations_expression":[
448
+ "operations": "(replace '/([m|l])ouse$/i' '$1ice' @value)",
449
+ "operations_expression": [
413
450
  "replace",
414
451
  "/([m|l])ouse$/i",
415
452
  "$1ice",
@@ -417,14 +454,14 @@
417
454
  ]
418
455
  },
419
456
  {
420
- "conditions":"(match '/(matr|vert|ind)ix|ex$/i' @value)",
421
- "conditions_expression":[
457
+ "conditions": "(match '/(matr|vert|ind)ix|ex$/i' @value)",
458
+ "conditions_expression": [
422
459
  "match",
423
460
  "/(matr|vert|ind)ix|ex$/i",
424
461
  "@value"
425
462
  ],
426
- "operations":"(replace '/(matr|vert|ind)ix|ex$/i' '$1ices' @value)",
427
- "operations_expression":[
463
+ "operations": "(replace '/(matr|vert|ind)ix|ex$/i' '$1ices' @value)",
464
+ "operations_expression": [
428
465
  "replace",
429
466
  "/(matr|vert|ind)ix|ex$/i",
430
467
  "$1ices",
@@ -432,14 +469,14 @@
432
469
  ]
433
470
  },
434
471
  {
435
- "conditions":"(match '/(x|ch|ss|sh)$/i' @value)",
436
- "conditions_expression":[
472
+ "conditions": "(match '/(x|ch|ss|sh)$/i' @value)",
473
+ "conditions_expression": [
437
474
  "match",
438
475
  "/(x|ch|ss|sh)$/i",
439
476
  "@value"
440
477
  ],
441
- "operations":"(replace '/(x|ch|ss|sh)$/i' '$1es' @value)",
442
- "operations_expression":[
478
+ "operations": "(replace '/(x|ch|ss|sh)$/i' '$1es' @value)",
479
+ "operations_expression": [
443
480
  "replace",
444
481
  "/(x|ch|ss|sh)$/i",
445
482
  "$1es",
@@ -447,14 +484,14 @@
447
484
  ]
448
485
  },
449
486
  {
450
- "conditions":"(match '/([^aeiouy]|qu)y$/i' @value)",
451
- "conditions_expression":[
487
+ "conditions": "(match '/([^aeiouy]|qu)y$/i' @value)",
488
+ "conditions_expression": [
452
489
  "match",
453
490
  "/([^aeiouy]|qu)y$/i",
454
491
  "@value"
455
492
  ],
456
- "operations":"(replace '/([^aeiouy]|qu)y$/i' '$1ies' @value)",
457
- "operations_expression":[
493
+ "operations": "(replace '/([^aeiouy]|qu)y$/i' '$1ies' @value)",
494
+ "operations_expression": [
458
495
  "replace",
459
496
  "/([^aeiouy]|qu)y$/i",
460
497
  "$1ies",
@@ -462,14 +499,14 @@
462
499
  ]
463
500
  },
464
501
  {
465
- "conditions":"(match '/([^aeiouy]|qu)ies$/i' @value)",
466
- "conditions_expression":[
502
+ "conditions": "(match '/([^aeiouy]|qu)ies$/i' @value)",
503
+ "conditions_expression": [
467
504
  "match",
468
505
  "/([^aeiouy]|qu)ies$/i",
469
506
  "@value"
470
507
  ],
471
- "operations":"(replace '/([^aeiouy]|qu)ies$/i' '$1y' @value)",
472
- "operations_expression":[
508
+ "operations": "(replace '/([^aeiouy]|qu)ies$/i' '$1y' @value)",
509
+ "operations_expression": [
473
510
  "replace",
474
511
  "/([^aeiouy]|qu)ies$/i",
475
512
  "$1y",
@@ -477,14 +514,14 @@
477
514
  ]
478
515
  },
479
516
  {
480
- "conditions":"(match '/(hive)$/i' @value)",
481
- "conditions_expression":[
517
+ "conditions": "(match '/(hive)$/i' @value)",
518
+ "conditions_expression": [
482
519
  "match",
483
520
  "/(hive)$/i",
484
521
  "@value"
485
522
  ],
486
- "operations":"(replace '/(hive)$/i' '$1s' @value)",
487
- "operations_expression":[
523
+ "operations": "(replace '/(hive)$/i' '$1s' @value)",
524
+ "operations_expression": [
488
525
  "replace",
489
526
  "/(hive)$/i",
490
527
  "$1s",
@@ -492,14 +529,14 @@
492
529
  ]
493
530
  },
494
531
  {
495
- "conditions":"(match '/(?:([^f])fe|([lr])f)$/i' @value)",
496
- "conditions_expression":[
532
+ "conditions": "(match '/(?:([^f])fe|([lr])f)$/i' @value)",
533
+ "conditions_expression": [
497
534
  "match",
498
535
  "/(?:([^f])fe|([lr])f)$/i",
499
536
  "@value"
500
537
  ],
501
- "operations":"(replace '/(?:([^f])fe|([lr])f)$/i' '$1$2ves' @value)",
502
- "operations_expression":[
538
+ "operations": "(replace '/(?:([^f])fe|([lr])f)$/i' '$1$2ves' @value)",
539
+ "operations_expression": [
503
540
  "replace",
504
541
  "/(?:([^f])fe|([lr])f)$/i",
505
542
  "$1$2ves",
@@ -507,14 +544,14 @@
507
544
  ]
508
545
  },
509
546
  {
510
- "conditions":"(match '/sis$/i' @value)",
511
- "conditions_expression":[
547
+ "conditions": "(match '/sis$/i' @value)",
548
+ "conditions_expression": [
512
549
  "match",
513
550
  "/sis$/i",
514
551
  "@value"
515
552
  ],
516
- "operations":"(replace '/sis$/i' 'ses' @value)",
517
- "operations_expression":[
553
+ "operations": "(replace '/sis$/i' 'ses' @value)",
554
+ "operations_expression": [
518
555
  "replace",
519
556
  "/sis$/i",
520
557
  "ses",
@@ -522,14 +559,14 @@
522
559
  ]
523
560
  },
524
561
  {
525
- "conditions":"(match '/([ti])um$/i' @value)",
526
- "conditions_expression":[
562
+ "conditions": "(match '/([ti])um$/i' @value)",
563
+ "conditions_expression": [
527
564
  "match",
528
565
  "/([ti])um$/i",
529
566
  "@value"
530
567
  ],
531
- "operations":"(replace '/([ti])um$/i' '$1a' @value)",
532
- "operations_expression":[
568
+ "operations": "(replace '/([ti])um$/i' '$1a' @value)",
569
+ "operations_expression": [
533
570
  "replace",
534
571
  "/([ti])um$/i",
535
572
  "$1a",
@@ -537,14 +574,14 @@
537
574
  ]
538
575
  },
539
576
  {
540
- "conditions":"(match '/(buffal|tomat|potat)o$/i' @value)",
541
- "conditions_expression":[
577
+ "conditions": "(match '/(buffal|tomat|potat)o$/i' @value)",
578
+ "conditions_expression": [
542
579
  "match",
543
580
  "/(buffal|tomat|potat)o$/i",
544
581
  "@value"
545
582
  ],
546
- "operations":"(replace '/(buffal|tomat|potat)o$/i' '$1oes' @value)",
547
- "operations_expression":[
583
+ "operations": "(replace '/(buffal|tomat|potat)o$/i' '$1oes' @value)",
584
+ "operations_expression": [
548
585
  "replace",
549
586
  "/(buffal|tomat|potat)o$/i",
550
587
  "$1oes",
@@ -552,14 +589,14 @@
552
589
  ]
553
590
  },
554
591
  {
555
- "conditions":"(match '/(bu)s$/i' @value)",
556
- "conditions_expression":[
592
+ "conditions": "(match '/(bu)s$/i' @value)",
593
+ "conditions_expression": [
557
594
  "match",
558
595
  "/(bu)s$/i",
559
596
  "@value"
560
597
  ],
561
- "operations":"(replace '/(bu)s$/i' '$1ses' @value)",
562
- "operations_expression":[
598
+ "operations": "(replace '/(bu)s$/i' '$1ses' @value)",
599
+ "operations_expression": [
563
600
  "replace",
564
601
  "/(bu)s$/i",
565
602
  "$1ses",
@@ -567,14 +604,14 @@
567
604
  ]
568
605
  },
569
606
  {
570
- "conditions":"(match '/(alias|status)$/i' @value)",
571
- "conditions_expression":[
607
+ "conditions": "(match '/(alias|status)$/i' @value)",
608
+ "conditions_expression": [
572
609
  "match",
573
610
  "/(alias|status)$/i",
574
611
  "@value"
575
612
  ],
576
- "operations":"(replace '/(alias|status)$/i' '$1es' @value)",
577
- "operations_expression":[
613
+ "operations": "(replace '/(alias|status)$/i' '$1es' @value)",
614
+ "operations_expression": [
578
615
  "replace",
579
616
  "/(alias|status)$/i",
580
617
  "$1es",
@@ -582,14 +619,14 @@
582
619
  ]
583
620
  },
584
621
  {
585
- "conditions":"(match '/(octop)us$/i' @value)",
586
- "conditions_expression":[
622
+ "conditions": "(match '/(octop)us$/i' @value)",
623
+ "conditions_expression": [
587
624
  "match",
588
625
  "/(octop)us$/i",
589
626
  "@value"
590
627
  ],
591
- "operations":"(replace '/(octop)us$/i' '$1i' @value)",
592
- "operations_expression":[
628
+ "operations": "(replace '/(octop)us$/i' '$1i' @value)",
629
+ "operations_expression": [
593
630
  "replace",
594
631
  "/(octop)us$/i",
595
632
  "$1i",
@@ -597,14 +634,14 @@
597
634
  ]
598
635
  },
599
636
  {
600
- "conditions":"(match '/(ax|test)is$/i' @value)",
601
- "conditions_expression":[
637
+ "conditions": "(match '/(ax|test)is$/i' @value)",
638
+ "conditions_expression": [
602
639
  "match",
603
640
  "/(ax|test)is$/i",
604
641
  "@value"
605
642
  ],
606
- "operations":"(replace '/(ax|test)is$/i' '$1es' @value)",
607
- "operations_expression":[
643
+ "operations": "(replace '/(ax|test)is$/i' '$1es' @value)",
644
+ "operations_expression": [
608
645
  "replace",
609
646
  "/(ax|test)is$/i",
610
647
  "$1es",
@@ -612,14 +649,14 @@
612
649
  ]
613
650
  },
614
651
  {
615
- "conditions":"(match '/us$/i' @value)",
616
- "conditions_expression":[
652
+ "conditions": "(match '/us$/i' @value)",
653
+ "conditions_expression": [
617
654
  "match",
618
655
  "/us$/i",
619
656
  "@value"
620
657
  ],
621
- "operations":"(replace '/us$/i' '$1es' @value)",
622
- "operations_expression":[
658
+ "operations": "(replace '/us$/i' '$1es' @value)",
659
+ "operations_expression": [
623
660
  "replace",
624
661
  "/us$/i",
625
662
  "$1es",
@@ -627,14 +664,14 @@
627
664
  ]
628
665
  },
629
666
  {
630
- "conditions":"(match '/s$/i' @value)",
631
- "conditions_expression":[
667
+ "conditions": "(match '/s$/i' @value)",
668
+ "conditions_expression": [
632
669
  "match",
633
670
  "/s$/i",
634
671
  "@value"
635
672
  ],
636
- "operations":"(replace '/s$/i' 's' @value)",
637
- "operations_expression":[
673
+ "operations": "(replace '/s$/i' 's' @value)",
674
+ "operations_expression": [
638
675
  "replace",
639
676
  "/s$/i",
640
677
  "s",
@@ -642,104 +679,260 @@
642
679
  ]
643
680
  },
644
681
  {
645
- "conditions":"(match '/$/' @value)",
646
- "conditions_expression":[
682
+ "conditions": "(match '/$/' @value)",
683
+ "conditions_expression": [
647
684
  "match",
648
685
  "/$/",
649
686
  "@value"
650
687
  ],
651
- "operations":"(replace '/$/' 's' @value)",
652
- "operations_expression":[
688
+ "operations": "(replace '/$/' 's' @value)",
689
+ "operations_expression": [
653
690
  "replace",
654
691
  "/$/",
655
692
  "s",
656
693
  "@value"
657
694
  ]
658
695
  }
659
- ]
696
+ ],
697
+ "latin_name": "Plural",
698
+ "description": "Converts singular form to plural",
699
+ "application": "phrase"
700
+ },
701
+ "ordinal": {
702
+ "rules": [
703
+ {
704
+ "description": "replace 1 with 'first'",
705
+ "conditions": "(= 1 @value)",
706
+ "conditions_expression": [
707
+ "=",
708
+ 1,
709
+ "@value"
710
+ ],
711
+ "operations": "(replace 1 'first' @value)",
712
+ "operations_expression": [
713
+ "replace",
714
+ 1,
715
+ "first",
716
+ "@value"
717
+ ]
718
+ },
719
+ {
720
+ "description": "replace 2 with 'second'",
721
+ "conditions": "(= 2 @value)",
722
+ "conditions_expression": [
723
+ "=",
724
+ 2,
725
+ "@value"
726
+ ],
727
+ "operations": "(replace 2 'first' @value)",
728
+ "operations_expression": [
729
+ "replace",
730
+ 2,
731
+ "first",
732
+ "@value"
733
+ ]
734
+ },
735
+ {
736
+ "description": "replace 3 with 'third'",
737
+ "conditions": "(= 3 @value)",
738
+ "conditions_expression": [
739
+ "=",
740
+ 3,
741
+ "@value"
742
+ ],
743
+ "operations": "(replace 3 'third' @value)",
744
+ "operations_expression": [
745
+ "replace",
746
+ 3,
747
+ "third",
748
+ "@value"
749
+ ]
750
+ }
751
+ ],
752
+ "latin_name": "Ordinal",
753
+ "description": "The adjective form of the cardinal numbers",
754
+ "application": "phrase"
660
755
  },
661
- "singular":{
662
- "keyword":"singular",
663
- "latin_name":"Singular",
664
- "description":"Converts plural form to singular",
665
- "application":"phrase",
666
- "rules":[
667
- {
668
- "description":"Uncountable word",
669
- "conditions":"(in 'sheep,fish,series,species,money,rice,information,equipment' @value)",
670
- "conditions_expression":[
756
+ "ord": {
757
+ "rules": [
758
+ {
759
+ "description": "append 'st' if value ends in 1, but not in 11",
760
+ "examples": "1, 21, 31, 41, 101, 121...",
761
+ "conditions": "(&& (match '/1$/' @value) (! (match '/11$/' @value)))",
762
+ "conditions_expression": [
763
+ "&&",
764
+ [
765
+ "match",
766
+ "/1$/",
767
+ "@value"
768
+ ],
769
+ [
770
+ "!",
771
+ [
772
+ "match",
773
+ "/11$/",
774
+ "@value"
775
+ ]
776
+ ]
777
+ ],
778
+ "operations": "(append 'st' @value)",
779
+ "operations_expression": [
780
+ "append",
781
+ "st",
782
+ "@value"
783
+ ]
784
+ },
785
+ {
786
+ "description": "append 'nd' if value ends in 2, but not in 12",
787
+ "examples": "2, 22, 32, 42, 102, 122...",
788
+ "conditions": "(&& (match '/2$/' @value) (! (match '/12$/' @value)))",
789
+ "conditions_expression": [
790
+ "&&",
791
+ [
792
+ "match",
793
+ "/2$/",
794
+ "@value"
795
+ ],
796
+ [
797
+ "!",
798
+ [
799
+ "match",
800
+ "/12$/",
801
+ "@value"
802
+ ]
803
+ ]
804
+ ],
805
+ "operations": "(append 'nd' @value)",
806
+ "operations_expression": [
807
+ "append",
808
+ "nd",
809
+ "@value"
810
+ ]
811
+ },
812
+ {
813
+ "description": "append 'nd' if value ends in 3, but not in 13",
814
+ "examples": "3, 23, 33, 43, 103, 123...",
815
+ "conditions": "(&& (match '/3$/' @value) (! (match '/13$/' @value)))",
816
+ "conditions_expression": [
817
+ "&&",
818
+ [
819
+ "match",
820
+ "/3$/",
821
+ "@value"
822
+ ],
823
+ [
824
+ "!",
825
+ [
826
+ "match",
827
+ "/13$/",
828
+ "@value"
829
+ ]
830
+ ]
831
+ ],
832
+ "operations": "(append 'rd' @value)",
833
+ "operations_expression": [
834
+ "append",
835
+ "rd",
836
+ "@value"
837
+ ]
838
+ },
839
+ {
840
+ "description": "append 'th' in all other cases",
841
+ "examples": "0, 4, 5, 6, 7, 8, 9, 11, 12, 13, 111, 113...",
842
+ "conditions": "(true)",
843
+ "conditions_expression": [
844
+ "true"
845
+ ],
846
+ "operations": "(append 'th' @value)",
847
+ "operations_expression": [
848
+ "append",
849
+ "th",
850
+ "@value"
851
+ ]
852
+ }
853
+ ],
854
+ "latin_name": "Ordinal",
855
+ "description": "The adjective form of the cardinal numbers",
856
+ "application": "phrase"
857
+ },
858
+ "singular": {
859
+ "rules": [
860
+ {
861
+ "description": "Uncountable word",
862
+ "conditions": "(in 'sheep,fish,series,species,money,rice,information,equipment' @value)",
863
+ "conditions_expression": [
671
864
  "in",
672
865
  "sheep,fish,series,species,money,rice,information,equipment",
673
866
  "@value"
674
867
  ],
675
- "operations":"@value",
676
- "operations_expression":"@value"
868
+ "operations": "@value",
869
+ "operations_expression": "@value"
677
870
  },
678
871
  {
679
- "description":"Irregular word",
680
- "conditions":"(= 'moves' @value)",
681
- "conditions_expression":[
872
+ "description": "Irregular word",
873
+ "conditions": "(= 'moves' @value)",
874
+ "conditions_expression": [
682
875
  "=",
683
876
  "moves",
684
877
  "@value"
685
878
  ],
686
- "operations":"(quote 'move')",
687
- "operations_expression":[
879
+ "operations": "(quote 'move')",
880
+ "operations_expression": [
688
881
  "quote",
689
882
  "move"
690
883
  ]
691
884
  },
692
885
  {
693
- "description":"Irregular word",
694
- "conditions":"(= 'sexes' @value)",
695
- "conditions_expression":[
886
+ "description": "Irregular word",
887
+ "conditions": "(= 'sexes' @value)",
888
+ "conditions_expression": [
696
889
  "=",
697
890
  "sexes",
698
891
  "@value"
699
892
  ],
700
- "operations":"(quote 'sex')",
701
- "operations_expression":[
893
+ "operations": "(quote 'sex')",
894
+ "operations_expression": [
702
895
  "quote",
703
896
  "sex"
704
897
  ]
705
898
  },
706
899
  {
707
- "description":"Irregular word",
708
- "conditions":"(= 'children' @value)",
709
- "conditions_expression":[
900
+ "description": "Irregular word",
901
+ "conditions": "(= 'children' @value)",
902
+ "conditions_expression": [
710
903
  "=",
711
904
  "children",
712
905
  "@value"
713
906
  ],
714
- "operations":"(quote 'child')",
715
- "operations_expression":[
907
+ "operations": "(quote 'child')",
908
+ "operations_expression": [
716
909
  "quote",
717
910
  "child"
718
911
  ]
719
912
  },
720
913
  {
721
- "description":"Irregular word",
722
- "conditions":"(= 'people' @value)",
723
- "conditions_expression":[
914
+ "description": "Irregular word",
915
+ "conditions": "(= 'people' @value)",
916
+ "conditions_expression": [
724
917
  "=",
725
918
  "people",
726
919
  "@value"
727
920
  ],
728
- "operations":"(quote 'person')",
729
- "operations_expression":[
921
+ "operations": "(quote 'person')",
922
+ "operations_expression": [
730
923
  "quote",
731
924
  "person"
732
925
  ]
733
926
  },
734
927
  {
735
- "conditions":"(match '/(n)ews$/i' @value)",
736
- "conditions_expression":[
928
+ "conditions": "(match '/(n)ews$/i' @value)",
929
+ "conditions_expression": [
737
930
  "match",
738
931
  "/(n)ews$/i",
739
932
  "@value"
740
933
  ],
741
- "operations":"(replace '/(n)ews$/i' '$1ews' @value)",
742
- "operations_expression":[
934
+ "operations": "(replace '/(n)ews$/i' '$1ews' @value)",
935
+ "operations_expression": [
743
936
  "replace",
744
937
  "/(n)ews$/i",
745
938
  "$1ews",
@@ -747,14 +940,14 @@
747
940
  ]
748
941
  },
749
942
  {
750
- "conditions":"(match '/([ti])a$/i' @value)",
751
- "conditions_expression":[
943
+ "conditions": "(match '/([ti])a$/i' @value)",
944
+ "conditions_expression": [
752
945
  "match",
753
946
  "/([ti])a$/i",
754
947
  "@value"
755
948
  ],
756
- "operations":"(replace '/([ti])a$/i' '$1um' @value)",
757
- "operations_expression":[
949
+ "operations": "(replace '/([ti])a$/i' '$1um' @value)",
950
+ "operations_expression": [
758
951
  "replace",
759
952
  "/([ti])a$/i",
760
953
  "$1um",
@@ -762,14 +955,14 @@
762
955
  ]
763
956
  },
764
957
  {
765
- "conditions":"(match '/((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$/i' @value)",
766
- "conditions_expression":[
958
+ "conditions": "(match '/((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$/i' @value)",
959
+ "conditions_expression": [
767
960
  "match",
768
961
  "/((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$/i",
769
962
  "@value"
770
963
  ],
771
- "operations":"(replace '/((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$/i' '$1$2sis' @value)",
772
- "operations_expression":[
964
+ "operations": "(replace '/((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$/i' '$1$2sis' @value)",
965
+ "operations_expression": [
773
966
  "replace",
774
967
  "/((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$/i",
775
968
  "$1$2sis",
@@ -777,14 +970,14 @@
777
970
  ]
778
971
  },
779
972
  {
780
- "conditions":"(match '/(^analy)ses$/i' @value)",
781
- "conditions_expression":[
973
+ "conditions": "(match '/(^analy)ses$/i' @value)",
974
+ "conditions_expression": [
782
975
  "match",
783
976
  "/(^analy)ses$/i",
784
977
  "@value"
785
978
  ],
786
- "operations":"(replace '/(^analy)ses$/i' '$1sis' @value)",
787
- "operations_expression":[
979
+ "operations": "(replace '/(^analy)ses$/i' '$1sis' @value)",
980
+ "operations_expression": [
788
981
  "replace",
789
982
  "/(^analy)ses$/i",
790
983
  "$1sis",
@@ -792,14 +985,14 @@
792
985
  ]
793
986
  },
794
987
  {
795
- "conditions":"(match '/([^f])ves$/i' @value)",
796
- "conditions_expression":[
988
+ "conditions": "(match '/([^f])ves$/i' @value)",
989
+ "conditions_expression": [
797
990
  "match",
798
991
  "/([^f])ves$/i",
799
992
  "@value"
800
993
  ],
801
- "operations":"(replace '/([^f])ves$/i' '$1fe' @value)",
802
- "operations_expression":[
994
+ "operations": "(replace '/([^f])ves$/i' '$1fe' @value)",
995
+ "operations_expression": [
803
996
  "replace",
804
997
  "/([^f])ves$/i",
805
998
  "$1fe",
@@ -807,14 +1000,14 @@
807
1000
  ]
808
1001
  },
809
1002
  {
810
- "conditions":"(match '/(hive)s$/i' @value)",
811
- "conditions_expression":[
1003
+ "conditions": "(match '/(hive)s$/i' @value)",
1004
+ "conditions_expression": [
812
1005
  "match",
813
1006
  "/(hive)s$/i",
814
1007
  "@value"
815
1008
  ],
816
- "operations":"(replace '/(hive)s$/i' '$1' @value)",
817
- "operations_expression":[
1009
+ "operations": "(replace '/(hive)s$/i' '$1' @value)",
1010
+ "operations_expression": [
818
1011
  "replace",
819
1012
  "/(hive)s$/i",
820
1013
  "$1",
@@ -822,14 +1015,14 @@
822
1015
  ]
823
1016
  },
824
1017
  {
825
- "conditions":"(match '/(tive)s$/i' @value)",
826
- "conditions_expression":[
1018
+ "conditions": "(match '/(tive)s$/i' @value)",
1019
+ "conditions_expression": [
827
1020
  "match",
828
1021
  "/(tive)s$/i",
829
1022
  "@value"
830
1023
  ],
831
- "operations":"(replace '/(tive)s$/i' '$1' @value)",
832
- "operations_expression":[
1024
+ "operations": "(replace '/(tive)s$/i' '$1' @value)",
1025
+ "operations_expression": [
833
1026
  "replace",
834
1027
  "/(tive)s$/i",
835
1028
  "$1",
@@ -837,14 +1030,14 @@
837
1030
  ]
838
1031
  },
839
1032
  {
840
- "conditions":"(match '/([lr])ves$/i' @value)",
841
- "conditions_expression":[
1033
+ "conditions": "(match '/([lr])ves$/i' @value)",
1034
+ "conditions_expression": [
842
1035
  "match",
843
1036
  "/([lr])ves$/i",
844
1037
  "@value"
845
1038
  ],
846
- "operations":"(replace '/([lr])ves$/i' '$1f' @value)",
847
- "operations_expression":[
1039
+ "operations": "(replace '/([lr])ves$/i' '$1f' @value)",
1040
+ "operations_expression": [
848
1041
  "replace",
849
1042
  "/([lr])ves$/i",
850
1043
  "$1f",
@@ -852,14 +1045,14 @@
852
1045
  ]
853
1046
  },
854
1047
  {
855
- "conditions":"(match '/([^aeiouy]|qu)ies$/i' @value)",
856
- "conditions_expression":[
1048
+ "conditions": "(match '/([^aeiouy]|qu)ies$/i' @value)",
1049
+ "conditions_expression": [
857
1050
  "match",
858
1051
  "/([^aeiouy]|qu)ies$/i",
859
1052
  "@value"
860
1053
  ],
861
- "operations":"(replace '/([^aeiouy]|qu)ies$/i' '$1y' @value)",
862
- "operations_expression":[
1054
+ "operations": "(replace '/([^aeiouy]|qu)ies$/i' '$1y' @value)",
1055
+ "operations_expression": [
863
1056
  "replace",
864
1057
  "/([^aeiouy]|qu)ies$/i",
865
1058
  "$1y",
@@ -867,14 +1060,14 @@
867
1060
  ]
868
1061
  },
869
1062
  {
870
- "conditions":"(match '/(s)eries$/i' @value)",
871
- "conditions_expression":[
1063
+ "conditions": "(match '/(s)eries$/i' @value)",
1064
+ "conditions_expression": [
872
1065
  "match",
873
1066
  "/(s)eries$/i",
874
1067
  "@value"
875
1068
  ],
876
- "operations":"(replace '/(s)eries$/i' '$1eries' @value)",
877
- "operations_expression":[
1069
+ "operations": "(replace '/(s)eries$/i' '$1eries' @value)",
1070
+ "operations_expression": [
878
1071
  "replace",
879
1072
  "/(s)eries$/i",
880
1073
  "$1eries",
@@ -882,14 +1075,14 @@
882
1075
  ]
883
1076
  },
884
1077
  {
885
- "conditions":"(match '/(m)ovies$/i' @value)",
886
- "conditions_expression":[
1078
+ "conditions": "(match '/(m)ovies$/i' @value)",
1079
+ "conditions_expression": [
887
1080
  "match",
888
1081
  "/(m)ovies$/i",
889
1082
  "@value"
890
1083
  ],
891
- "operations":"(replace '/(m)ovies$/i' '$1ovie' @value)",
892
- "operations_expression":[
1084
+ "operations": "(replace '/(m)ovies$/i' '$1ovie' @value)",
1085
+ "operations_expression": [
893
1086
  "replace",
894
1087
  "/(m)ovies$/i",
895
1088
  "$1ovie",
@@ -897,14 +1090,14 @@
897
1090
  ]
898
1091
  },
899
1092
  {
900
- "conditions":"(match '/(x|ch|ss|sh)es$/i' @value)",
901
- "conditions_expression":[
1093
+ "conditions": "(match '/(x|ch|ss|sh)es$/i' @value)",
1094
+ "conditions_expression": [
902
1095
  "match",
903
1096
  "/(x|ch|ss|sh)es$/i",
904
1097
  "@value"
905
1098
  ],
906
- "operations":"(replace '/(x|ch|ss|sh)es$/i' '$1' @value)",
907
- "operations_expression":[
1099
+ "operations": "(replace '/(x|ch|ss|sh)es$/i' '$1' @value)",
1100
+ "operations_expression": [
908
1101
  "replace",
909
1102
  "/(x|ch|ss|sh)es$/i",
910
1103
  "$1",
@@ -912,14 +1105,14 @@
912
1105
  ]
913
1106
  },
914
1107
  {
915
- "conditions":"(match '/([m|l])ice$/i' @value)",
916
- "conditions_expression":[
1108
+ "conditions": "(match '/([m|l])ice$/i' @value)",
1109
+ "conditions_expression": [
917
1110
  "match",
918
1111
  "/([m|l])ice$/i",
919
1112
  "@value"
920
1113
  ],
921
- "operations":"(replace '/([m|l])ice$/i' '$1ouse' @value)",
922
- "operations_expression":[
1114
+ "operations": "(replace '/([m|l])ice$/i' '$1ouse' @value)",
1115
+ "operations_expression": [
923
1116
  "replace",
924
1117
  "/([m|l])ice$/i",
925
1118
  "$1ouse",
@@ -927,14 +1120,14 @@
927
1120
  ]
928
1121
  },
929
1122
  {
930
- "conditions":"(match '/(bus)es$/i' @value)",
931
- "conditions_expression":[
1123
+ "conditions": "(match '/(bus)es$/i' @value)",
1124
+ "conditions_expression": [
932
1125
  "match",
933
1126
  "/(bus)es$/i",
934
1127
  "@value"
935
1128
  ],
936
- "operations":"(replace '/(bus)es$/i' '$1' @value)",
937
- "operations_expression":[
1129
+ "operations": "(replace '/(bus)es$/i' '$1' @value)",
1130
+ "operations_expression": [
938
1131
  "replace",
939
1132
  "/(bus)es$/i",
940
1133
  "$1",
@@ -942,14 +1135,14 @@
942
1135
  ]
943
1136
  },
944
1137
  {
945
- "conditions":"(match '/(o)es$/i' @value)",
946
- "conditions_expression":[
1138
+ "conditions": "(match '/(o)es$/i' @value)",
1139
+ "conditions_expression": [
947
1140
  "match",
948
1141
  "/(o)es$/i",
949
1142
  "@value"
950
1143
  ],
951
- "operations":"(replace '/(o)es$/i' '$1' @value)",
952
- "operations_expression":[
1144
+ "operations": "(replace '/(o)es$/i' '$1' @value)",
1145
+ "operations_expression": [
953
1146
  "replace",
954
1147
  "/(o)es$/i",
955
1148
  "$1",
@@ -957,14 +1150,14 @@
957
1150
  ]
958
1151
  },
959
1152
  {
960
- "conditions":"(match '/(shoe)s$/i' @value)",
961
- "conditions_expression":[
1153
+ "conditions": "(match '/(shoe)s$/i' @value)",
1154
+ "conditions_expression": [
962
1155
  "match",
963
1156
  "/(shoe)s$/i",
964
1157
  "@value"
965
1158
  ],
966
- "operations":"(replace '/(shoe)s$/i' '$1' @value)",
967
- "operations_expression":[
1159
+ "operations": "(replace '/(shoe)s$/i' '$1' @value)",
1160
+ "operations_expression": [
968
1161
  "replace",
969
1162
  "/(shoe)s$/i",
970
1163
  "$1",
@@ -972,14 +1165,14 @@
972
1165
  ]
973
1166
  },
974
1167
  {
975
- "conditions":"(match '/(cris|ax|test)es$/i' @value)",
976
- "conditions_expression":[
1168
+ "conditions": "(match '/(cris|ax|test)es$/i' @value)",
1169
+ "conditions_expression": [
977
1170
  "match",
978
1171
  "/(cris|ax|test)es$/i",
979
1172
  "@value"
980
1173
  ],
981
- "operations":"(replace '/(cris|ax|test)es$/i' '$1is' @value)",
982
- "operations_expression":[
1174
+ "operations": "(replace '/(cris|ax|test)es$/i' '$1is' @value)",
1175
+ "operations_expression": [
983
1176
  "replace",
984
1177
  "/(cris|ax|test)es$/i",
985
1178
  "$1is",
@@ -987,14 +1180,14 @@
987
1180
  ]
988
1181
  },
989
1182
  {
990
- "conditions":"(match '/(octop|vir)i$/i' @value)",
991
- "conditions_expression":[
1183
+ "conditions": "(match '/(octop|vir)i$/i' @value)",
1184
+ "conditions_expression": [
992
1185
  "match",
993
1186
  "/(octop|vir)i$/i",
994
1187
  "@value"
995
1188
  ],
996
- "operations":"(replace '/(octop|vir)i$/i' '$1us' @value)",
997
- "operations_expression":[
1189
+ "operations": "(replace '/(octop|vir)i$/i' '$1us' @value)",
1190
+ "operations_expression": [
998
1191
  "replace",
999
1192
  "/(octop|vir)i$/i",
1000
1193
  "$1us",
@@ -1002,14 +1195,14 @@
1002
1195
  ]
1003
1196
  },
1004
1197
  {
1005
- "conditions":"(match '/(alias|status)es$/i' @value)",
1006
- "conditions_expression":[
1198
+ "conditions": "(match '/(alias|status)es$/i' @value)",
1199
+ "conditions_expression": [
1007
1200
  "match",
1008
1201
  "/(alias|status)es$/i",
1009
1202
  "@value"
1010
1203
  ],
1011
- "operations":"(replace '/(alias|status)es$/i' '$1' @value)",
1012
- "operations_expression":[
1204
+ "operations": "(replace '/(alias|status)es$/i' '$1' @value)",
1205
+ "operations_expression": [
1013
1206
  "replace",
1014
1207
  "/(alias|status)es$/i",
1015
1208
  "$1",
@@ -1017,14 +1210,14 @@
1017
1210
  ]
1018
1211
  },
1019
1212
  {
1020
- "conditions":"(match '/^(ox)en$/i' @value)",
1021
- "conditions_expression":[
1213
+ "conditions": "(match '/^(ox)en$/i' @value)",
1214
+ "conditions_expression": [
1022
1215
  "match",
1023
1216
  "/^(ox)en$/i",
1024
1217
  "@value"
1025
1218
  ],
1026
- "operations":"(replace '/^(ox)en$/i' '$1' @value)",
1027
- "operations_expression":[
1219
+ "operations": "(replace '/^(ox)en$/i' '$1' @value)",
1220
+ "operations_expression": [
1028
1221
  "replace",
1029
1222
  "/^(ox)en$/i",
1030
1223
  "$1",
@@ -1032,14 +1225,14 @@
1032
1225
  ]
1033
1226
  },
1034
1227
  {
1035
- "conditions":"(match '/(vert|ind)ices$/i' @value)",
1036
- "conditions_expression":[
1228
+ "conditions": "(match '/(vert|ind)ices$/i' @value)",
1229
+ "conditions_expression": [
1037
1230
  "match",
1038
1231
  "/(vert|ind)ices$/i",
1039
1232
  "@value"
1040
1233
  ],
1041
- "operations":"(replace '/(vert|ind)ices$/i' '$1ex' @value)",
1042
- "operations_expression":[
1234
+ "operations": "(replace '/(vert|ind)ices$/i' '$1ex' @value)",
1235
+ "operations_expression": [
1043
1236
  "replace",
1044
1237
  "/(vert|ind)ices$/i",
1045
1238
  "$1ex",
@@ -1047,14 +1240,14 @@
1047
1240
  ]
1048
1241
  },
1049
1242
  {
1050
- "conditions":"(match '/(matr)ices$/i' @value)",
1051
- "conditions_expression":[
1243
+ "conditions": "(match '/(matr)ices$/i' @value)",
1244
+ "conditions_expression": [
1052
1245
  "match",
1053
1246
  "/(matr)ices$/i",
1054
1247
  "@value"
1055
1248
  ],
1056
- "operations":"(replace '/(matr)ices$/i' '$1ix' @value)",
1057
- "operations_expression":[
1249
+ "operations": "(replace '/(matr)ices$/i' '$1ix' @value)",
1250
+ "operations_expression": [
1058
1251
  "replace",
1059
1252
  "/(matr)ices$/i",
1060
1253
  "$1ix",
@@ -1062,14 +1255,14 @@
1062
1255
  ]
1063
1256
  },
1064
1257
  {
1065
- "conditions":"(match '/(quiz)zes$/i' @value)",
1066
- "conditions_expression":[
1258
+ "conditions": "(match '/(quiz)zes$/i' @value)",
1259
+ "conditions_expression": [
1067
1260
  "match",
1068
1261
  "/(quiz)zes$/i",
1069
1262
  "@value"
1070
1263
  ],
1071
- "operations":"(replace '/(quiz)zes$/i' '$1' @value)",
1072
- "operations_expression":[
1264
+ "operations": "(replace '/(quiz)zes$/i' '$1' @value)",
1265
+ "operations_expression": [
1073
1266
  "replace",
1074
1267
  "/(quiz)zes$/i",
1075
1268
  "$1",
@@ -1077,14 +1270,14 @@
1077
1270
  ]
1078
1271
  },
1079
1272
  {
1080
- "conditions":"(match '/(us)es$/i' @value)",
1081
- "conditions_expression":[
1273
+ "conditions": "(match '/(us)es$/i' @value)",
1274
+ "conditions_expression": [
1082
1275
  "match",
1083
1276
  "/(us)es$/i",
1084
1277
  "@value"
1085
1278
  ],
1086
- "operations":"(replace '/(us)es$/i' '$1' @value)",
1087
- "operations_expression":[
1279
+ "operations": "(replace '/(us)es$/i' '$1' @value)",
1280
+ "operations_expression": [
1088
1281
  "replace",
1089
1282
  "/(us)es$/i",
1090
1283
  "$1",
@@ -1092,272 +1285,59 @@
1092
1285
  ]
1093
1286
  },
1094
1287
  {
1095
- "conditions":"(match '/s$/i' @value)",
1096
- "conditions_expression":[
1288
+ "conditions": "(match '/s$/i' @value)",
1289
+ "conditions_expression": [
1097
1290
  "match",
1098
1291
  "/s$/i",
1099
1292
  "@value"
1100
1293
  ],
1101
- "operations":"(replace '/s$/i' '' @value)",
1102
- "operations_expression":[
1294
+ "operations": "(replace '/s$/i' '' @value)",
1295
+ "operations_expression": [
1103
1296
  "replace",
1104
1297
  "/s$/i",
1105
1298
  "",
1106
1299
  "@value"
1107
1300
  ]
1108
1301
  }
1109
- ]
1302
+ ],
1303
+ "latin_name": "Singular",
1304
+ "description": "Converts plural form to singular",
1305
+ "application": "phrase"
1110
1306
  },
1111
- "pos":{
1112
- "keyword":"pos",
1113
- "latin_name":"Possessive",
1114
- "description":"Used to indicate possession (i.e., ownership). It is usually created by adding 's to the word",
1115
- "application":"phrase",
1116
- "rules":[
1117
- {
1118
- "description":"if value ends in s, append '",
1119
- "conditions":"(match '/s$/' @value)",
1120
- "conditions_expression":[
1307
+ "pos": {
1308
+ "rules": [
1309
+ {
1310
+ "description": "if value ends in s, append '",
1311
+ "conditions": "(match '/s$/' @value)",
1312
+ "conditions_expression": [
1121
1313
  "match",
1122
1314
  "/s$/",
1123
1315
  "@value"
1124
1316
  ],
1125
- "operations":"(append \"'\" @value)",
1126
- "operations_expression":[
1317
+ "operations": "(append \"'\" @value)",
1318
+ "operations_expression": [
1127
1319
  "append",
1128
1320
  "'",
1129
1321
  "@value"
1130
1322
  ]
1131
1323
  },
1132
1324
  {
1133
- "description":"in all other cases, append 's",
1134
- "conditions":"(true)",
1135
- "conditions_expression":[
1325
+ "description": "in all other cases, append 's",
1326
+ "conditions": "(true)",
1327
+ "conditions_expression": [
1136
1328
  "true"
1137
1329
  ],
1138
- "operations":"(append \"'s\" @value)",
1139
- "operations_expression":[
1330
+ "operations": "(append \"'s\" @value)",
1331
+ "operations_expression": [
1140
1332
  "append",
1141
1333
  "'s",
1142
1334
  "@value"
1143
1335
  ]
1144
1336
  }
1145
- ]
1146
- },
1147
- "ord":{
1148
- "keyword":"ord",
1149
- "latin_name":"Ordinal",
1150
- "native_name":"Short Ordinal",
1151
- "description":"The adjective form of the cardinal numbers",
1152
- "application":"phrase",
1153
- "rules":[
1154
- {
1155
- "id":727,
1156
- "description":"append 'st' if value ends in 1, but not in 11",
1157
- "examples":"1, 21, 31, 41, 101, 121...",
1158
- "conditions":"(&& (match '/1$/' @value) (! (match '/11$/' @value)))",
1159
- "conditions_expression":[
1160
- "&&",
1161
- [
1162
- "match",
1163
- "/1$/",
1164
- "@value"
1165
- ],
1166
- [
1167
- "!",
1168
- [
1169
- "match",
1170
- "/11$/",
1171
- "@value"
1172
- ]
1173
- ]
1174
- ],
1175
- "operations":"(append 'st' @value)",
1176
- "operations_expression":[
1177
- "append",
1178
- "st",
1179
- "@value"
1180
- ]
1181
- },
1182
- {
1183
- "description":"append 'nd' if value ends in 2, but not in 12",
1184
- "examples":"2, 22, 32, 42, 102, 122...",
1185
- "conditions":"(&& (match '/2$/' @value) (! (match '/12$/' @value)))",
1186
- "conditions_expression":[
1187
- "&&",
1188
- [
1189
- "match",
1190
- "/2$/",
1191
- "@value"
1192
- ],
1193
- [
1194
- "!",
1195
- [
1196
- "match",
1197
- "/12$/",
1198
- "@value"
1199
- ]
1200
- ]
1201
- ],
1202
- "operations":"(append 'nd' @value)",
1203
- "operations_expression":[
1204
- "append",
1205
- "nd",
1206
- "@value"
1207
- ]
1208
- },
1209
- {
1210
- "description":"append 'nd' if value ends in 3, but not in 13",
1211
- "examples":"3, 23, 33, 43, 103, 123...",
1212
- "conditions":"(&& (match '/3$/' @value) (! (match '/13$/' @value)))",
1213
- "conditions_expression":[
1214
- "&&",
1215
- [
1216
- "match",
1217
- "/3$/",
1218
- "@value"
1219
- ],
1220
- [
1221
- "!",
1222
- [
1223
- "match",
1224
- "/13$/",
1225
- "@value"
1226
- ]
1227
- ]
1228
- ],
1229
- "operations":"(append 'rd' @value)",
1230
- "operations_expression":[
1231
- "append",
1232
- "rd",
1233
- "@value"
1234
- ]
1235
- },
1236
- {
1237
- "description":"append 'th' in all other cases",
1238
- "examples":"0, 4, 5, 6, 7, 8, 9, 11, 12, 13, 111, 113...",
1239
- "conditions":"(true)",
1240
- "conditions_expression":[
1241
- "true"
1242
- ],
1243
- "operations":"(append 'th' @value)",
1244
- "operations_expression":[
1245
- "append",
1246
- "th",
1247
- "@value"
1248
- ]
1249
- }
1250
- ]
1251
- },
1252
- "ordinal":{
1253
- "keyword":"ordinal",
1254
- "latin_name":"Ordinal",
1255
- "native_name":"Full Ordinal",
1256
- "description":"The adjective form of the cardinal numbers",
1257
- "application":"phrase",
1258
- "rules":[
1259
- {
1260
- "description":"replace 1 with 'first'",
1261
- "conditions":"(= 1 @value)",
1262
- "conditions_expression":[
1263
- "=",
1264
- 1,
1265
- "@value"
1266
- ],
1267
- "operations":"(replace 1 'first' @value)",
1268
- "operations_expression":[
1269
- "replace",
1270
- 1,
1271
- "first",
1272
- "@value"
1273
- ]
1274
- },
1275
- {
1276
- "description":"replace 2 with 'second'",
1277
- "conditions":"(= 2 @value)",
1278
- "conditions_expression":[
1279
- "=",
1280
- 2,
1281
- "@value"
1282
- ],
1283
- "operations":"(replace 2 'first' @value)",
1284
- "operations_expression":[
1285
- "replace",
1286
- 2,
1287
- "first",
1288
- "@value"
1289
- ]
1290
- },
1291
- {
1292
- "description":"replace 3 with 'third'",
1293
- "conditions":"(= 3 @value)",
1294
- "conditions_expression":[
1295
- "=",
1296
- 3,
1297
- "@value"
1298
- ],
1299
- "operations":"(replace 3 'third' @value)",
1300
- "operations_expression":[
1301
- "replace",
1302
- 3,
1303
- "third",
1304
- "@value"
1305
- ]
1306
- }
1307
- ]
1308
- },
1309
- "times":{
1310
- "keyword":"times",
1311
- "latin_name":"Iteration",
1312
- "description":"The iteration form of the cardinal numbers",
1313
- "application":"phrase",
1314
- "rules":[
1315
- {
1316
- "description":"replace '1' with 'once'",
1317
- "conditions":"(= 1 @value)",
1318
- "conditions_expression":[
1319
- "=",
1320
- 1,
1321
- "@value"
1322
- ],
1323
- "operations":"(replace '1' 'once' @value)",
1324
- "operations_expression":[
1325
- "replace",
1326
- "1",
1327
- "once",
1328
- "@value"
1329
- ]
1330
- },
1331
- {
1332
- "description":"replace '2' with 'twice'",
1333
- "conditions":"(= 2 @value)",
1334
- "conditions_expression":[
1335
- "=",
1336
- 2,
1337
- "@value"
1338
- ],
1339
- "operations":"(replace '2' 'twice' @value)",
1340
- "operations_expression":[
1341
- "replace",
1342
- "2",
1343
- "twice",
1344
- "@value"
1345
- ]
1346
- },
1347
- {
1348
- "description":"in all other cases, append x times",
1349
- "conditions":"(true)",
1350
- "conditions_expression":[
1351
- "true"
1352
- ],
1353
- "operations":"(append ' times' @value)",
1354
- "operations_expression":[
1355
- "append",
1356
- " times",
1357
- "@value"
1358
- ]
1359
- }
1360
- ]
1337
+ ],
1338
+ "latin_name": "Possessive",
1339
+ "description": "Used to indicate possession (i.e., ownership). It is usually created by adding 's to the word",
1340
+ "application": "phrase"
1361
1341
  }
1362
1342
  }
1363
1343
  }