jsfe 1.77.0 → 1.77.1
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.
|
@@ -369,7 +369,7 @@ export function groundAmount(utterance, value) {
|
|
|
369
369
|
return null;
|
|
370
370
|
else { /* said whole */ }
|
|
371
371
|
const [a, b] = spans[0];
|
|
372
|
-
const tail = (raw.slice(b).match(/^\s*(?:cents?|centavos?|dollars?|d[oó]lares?|d[oó]lar|pesos?|bucks?)\b/i) || [''])[0];
|
|
372
|
+
const tail = (raw.slice(b).match(/^\s*(?:(?:cents?|centavos?|dollars?|d[oó]lares?|d[oó]lar|pesos?|bucks?)\b|\$)/i) || [''])[0];
|
|
373
373
|
const head = (raw.slice(0, a).match(/[$]\s*$/) || [''])[0];
|
|
374
374
|
return { text: raw.slice(a - head.length, b + tail.length), start: a - head.length, end: b + tail.length };
|
|
375
375
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"money.d.ts","sourceRoot":"","sources":["../../src/helpers/money.js"],"names":[],"mappings":"AAIA,gHAAgH;AAChH,wDAGC;
|
|
1
|
+
{"version":3,"file":"money.d.ts","sourceRoot":"","sources":["../../src/helpers/money.js"],"names":[],"mappings":"AAIA,gHAAgH;AAChH,wDAGC;AAuBD;8FAC8F;AAC9F,oEAIC;AACD,+FAA+F;AAC/F,0DAEC;AACD;oGACoG;AACpG,4DAGC;AAWD;;;GAGG;AACH,+DAYC;AACD,4FAA4F;AAC5F,iEAAsG"}
|
package/dist/helpers/money.js
CHANGED
|
@@ -11,7 +11,9 @@ export function validateMoneyOptions(options) {
|
|
|
11
11
|
// monetary answer belongs to DISPATCH, including refusals, corrections with context and reports. "157 95" is dollars and
|
|
12
12
|
// cents said with no word between them (owner 2026-10-29); "95 52" is not (a card's last four read in pairs).
|
|
13
13
|
const NUMERIC_MONEY = /^(?:\$\s*)?(?:\d{1,3}(?:[,.]\d{3})+|\d+)(?:[.,]\d{1,2})?(?:\s*(?:dollars?|d[oó]lar(?:es)?|bucks?|\$))?(?:\s*(?:and|con|y)\s*(?:un\s*)?\d{1,2}(?:\s*(?:cents?|centavos?))?)?$|^\d{1,2}\s*(?:cents?|centavos?)$|^(?:\$\s*)?(?:\d{1,3}(?:[,.]\d{3})+|\d+)[.,]\d{2}\s*(?:cents?|centavos?)$|^(?:\$\s*)?(?:\d|\d{3,})\s+\d{2}$/i;
|
|
14
|
-
|
|
14
|
+
// A payment said as a noun is the same instruction: 'pago de 100 dólares', 'un pago de', 'a payment of' (owner 2026-11-18: at the
|
|
15
|
+
// recovery offer 'Pago de 100 dólares.' was asked whether 100 was the card's expiration date).
|
|
16
|
+
const PAYMENT_PREFIX = /^(?:(?:(?:i (?:want to|would like to|will) |i['’]d like to |i['’]ll )?make )?(?:a )?payment(?: of)?|(?:i (?:want to|would like to|can|am able to|will) |i['’]d like to )?pay|(?:quiero |quisiera |puedo |s[ií] puedo |voy a )?(?:pagar|abonar)|(?:no,?\s+)?make it|(?:(?:quiero |quisiera |voy a )?hacer )?(?:un )?(?:pago|abono)(?: de)?)\s*(?=\$|\d|[a-záéíóúüñ])/i;
|
|
15
17
|
// The field named with its value ("100 amount", "the amount is 100", "monto 100"): the amount, said as such.
|
|
16
18
|
const AMOUNT_LABEL_PREFIX = /^(?:(?:the|el|la)\s+)?(?:amount|monto|cantidad)(?:\s+(?:is|of|es|de))?[:\s]+(?=\$|\d)/i;
|
|
17
19
|
const AMOUNT_LABEL_SUFFIX = /(?<=\d|\$)\s+(?:(?:as\s+)?(?:the\s+)?amount|(?:de\s+|el\s+)?monto|(?:de\s+|la\s+)?cantidad)$/i;
|
package/dist/runtime-identity.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const JSFE_RUNTIME_FINGERPRINT = "sha256:
|
|
1
|
+
export const JSFE_RUNTIME_FINGERPRINT = "sha256:5952a21d21b84e435055f844f125e5be9493ab861df9d24284436b8eae1be834";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "jsfe",
|
|
3
|
-
"version": "1.77.
|
|
3
|
+
"version": "1.77.1",
|
|
4
4
|
"description": "TypeScript workflow engine for conversational/automation apps: multi-flow orchestration, interrupt/resume, stack-based control, robust errors, and flexible tool/REST integration.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Ron Pinkas",
|