@smartytalent/openai-tools 0.8.13 → 0.8.15
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.
- package/dist/tools.json +18 -2
- package/package.json +1 -1
package/dist/tools.json
CHANGED
|
@@ -8262,16 +8262,24 @@
|
|
|
8262
8262
|
},
|
|
8263
8263
|
"content": {
|
|
8264
8264
|
"type": "string",
|
|
8265
|
-
"description": "The field schema, JSON-encoded: a flat map of `fieldId -> field`.\nA field carries `label` and `description` as locale maps, a\n`type` (text, textarea, select, checkbox, file, email, phone,\ndate, number), `required`, and for a select an `options` list of\n`{value, label}` - the candidate submits `value`, never the\nlocalized label.\n\nA knockout field adds `knockout: true`, `verifies` (the criterion\nit gates on) and `expectedAnswer` (the PASSING answer, matching\none of the option values for a select). The submission gate\nrejects a candidate on a failed knockout without any AI spend, so\na knockout missing `expectedAnswer` is refused: the gate would\nskip it and admit everyone. A knockout on a checkbox is refused\ntoo - a required checkbox renders as must-tick, so \"No\" cannot be\nexpressed and the gate could never fire.\n\nAn apply form (`kind: candidateSubmission`) must keep the\n`fullName`, `email`, `phone` and `cv` fields: the apply page maps\nthem onto first-class submission slots.\n\nRejections come back as one error object per violation, each with\na `source.pointer` at the offending field. Limit: 131072 bytes."
|
|
8265
|
+
"description": "The field schema, JSON-encoded: a flat map of `fieldId -> field`.\nA field carries `label` and `description` as locale maps, a\n`type` (text, textarea, select, checkbox, file, email, phone,\ndate, number), `required`, and for a select an `options` list of\n`{value, label}` - the candidate submits `value`, never the\nlocalized label.\n\nA knockout field adds `knockout: true`, `verifies` (the criterion\nit gates on) and `expectedAnswer` (the PASSING answer, matching\none of the option values for a select). The submission gate\nrejects a candidate on a failed knockout without any AI spend, so\na knockout missing `expectedAnswer` is refused: the gate would\nskip it and admit everyone. A knockout on a checkbox is refused\ntoo - a required checkbox renders as must-tick, so \"No\" cannot be\nexpressed and the gate could never fire.\n\nEvery label and option label must carry text in the form's\n`languageCode` or in `en-US` - the locales the apply page falls\nback to. A label that resolves in neither renders blank for the\ncandidate and is refused.\n\nAn apply form (`kind: candidateSubmission`) must keep the\n`fullName`, `email`, `phone` and `cv` fields: the apply page maps\nthem onto first-class submission slots.\n\nRejections come back as one error object per violation, each with\na `source.pointer` at the offending field. Limit: 131072 bytes."
|
|
8266
8266
|
},
|
|
8267
8267
|
"publish": {
|
|
8268
8268
|
"type": "boolean",
|
|
8269
8269
|
"description": "Publish transition. `true` mirrors `content` to the CDN and flips\nthe form to `active`, the state guest submission intake requires.\nSend it on the same PATCH that carries the edit, or on its own to\nrepublish what is already stored. Needs the recruiting tier or\nabove; publishing a form with no content is a 400."
|
|
8270
8270
|
},
|
|
8271
|
+
"languageCode": {
|
|
8272
|
+
"type": "string",
|
|
8273
|
+
"description": "The form's own language as a BCP-47 tag (e.g. `pl-PL`). Stamped by\nthe build pipeline; settable at create and changeable by PATCH.\n\nIt is part of the RENDER FALLBACK CHAIN: the apply page tries the\ncandidate's locale, then this one, then `en-US`. Every label and\noption label must resolve somewhere in that chain - in this locale\nOR in `en-US`, not necessarily both. A form with no `languageCode`\nis held to `en-US` alone. Change it and the labels in the same\nPATCH; the new text is validated against the new chain."
|
|
8274
|
+
},
|
|
8271
8275
|
"revision": {
|
|
8272
8276
|
"type": "integer",
|
|
8273
8277
|
"description": "Optimistic-concurrency token, bumped atomically on every write.\nSend it back as `If-Match: \"<revision>\"` on PATCH to make the\nwrite conditional; a mismatch is a 409 `SM_FORM_STALE`, meaning\nsomeone else saved since your read. Without the header the write\nis unconditional and the last writer wins - which for a form\nmeans silently replacing the whole field schema."
|
|
8274
8278
|
},
|
|
8279
|
+
"translate": {
|
|
8280
|
+
"type": "boolean",
|
|
8281
|
+
"description": "Fill missing locales on the field schema, asynchronously. Fires\nafter the write lands, so it can ride the same PATCH as an edit or\nbe sent alone. Targets the tenant's active languages plus the\nform's own `languageCode`, translating FROM the `en-US` text - a\nfield with no `en-US` label is skipped rather than invented.\n\nFill-only-missing: text already present in a locale is never\noverwritten, and an operator edit that lands mid-run wins (the\nfill re-merges only what is still missing). Field ids,\n`options[].value`, `knockout`, `verifies` and `expectedAnswer` are\nnever touched, so the tokens the submission gate compares survive.\n\nThe outcome lands in `meta.translation`\n(`status`, `translated`, `locales`, `startedAt`, `finishedAt`);\npoll `showForm` for it. Publishing is separate: the filled text\nreaches the apply page on the next `publish: true`."
|
|
8282
|
+
},
|
|
8275
8283
|
"publishedUrl": {
|
|
8276
8284
|
"type": "string",
|
|
8277
8285
|
"description": "Where the published document lives. Server-managed: the server\nowns the key it wrote, so never compose this URL client-side - a\nURL built from the wrong tenant shortCode is indistinguishable\nfrom a correct one."
|
|
@@ -8390,16 +8398,24 @@
|
|
|
8390
8398
|
},
|
|
8391
8399
|
"content": {
|
|
8392
8400
|
"type": "string",
|
|
8393
|
-
"description": "The field schema, JSON-encoded: a flat map of `fieldId -> field`.\nA field carries `label` and `description` as locale maps, a\n`type` (text, textarea, select, checkbox, file, email, phone,\ndate, number), `required`, and for a select an `options` list of\n`{value, label}` - the candidate submits `value`, never the\nlocalized label.\n\nA knockout field adds `knockout: true`, `verifies` (the criterion\nit gates on) and `expectedAnswer` (the PASSING answer, matching\none of the option values for a select). The submission gate\nrejects a candidate on a failed knockout without any AI spend, so\na knockout missing `expectedAnswer` is refused: the gate would\nskip it and admit everyone. A knockout on a checkbox is refused\ntoo - a required checkbox renders as must-tick, so \"No\" cannot be\nexpressed and the gate could never fire.\n\nAn apply form (`kind: candidateSubmission`) must keep the\n`fullName`, `email`, `phone` and `cv` fields: the apply page maps\nthem onto first-class submission slots.\n\nRejections come back as one error object per violation, each with\na `source.pointer` at the offending field. Limit: 131072 bytes."
|
|
8401
|
+
"description": "The field schema, JSON-encoded: a flat map of `fieldId -> field`.\nA field carries `label` and `description` as locale maps, a\n`type` (text, textarea, select, checkbox, file, email, phone,\ndate, number), `required`, and for a select an `options` list of\n`{value, label}` - the candidate submits `value`, never the\nlocalized label.\n\nA knockout field adds `knockout: true`, `verifies` (the criterion\nit gates on) and `expectedAnswer` (the PASSING answer, matching\none of the option values for a select). The submission gate\nrejects a candidate on a failed knockout without any AI spend, so\na knockout missing `expectedAnswer` is refused: the gate would\nskip it and admit everyone. A knockout on a checkbox is refused\ntoo - a required checkbox renders as must-tick, so \"No\" cannot be\nexpressed and the gate could never fire.\n\nEvery label and option label must carry text in the form's\n`languageCode` or in `en-US` - the locales the apply page falls\nback to. A label that resolves in neither renders blank for the\ncandidate and is refused.\n\nAn apply form (`kind: candidateSubmission`) must keep the\n`fullName`, `email`, `phone` and `cv` fields: the apply page maps\nthem onto first-class submission slots.\n\nRejections come back as one error object per violation, each with\na `source.pointer` at the offending field. Limit: 131072 bytes."
|
|
8394
8402
|
},
|
|
8395
8403
|
"publish": {
|
|
8396
8404
|
"type": "boolean",
|
|
8397
8405
|
"description": "Publish transition. `true` mirrors `content` to the CDN and flips\nthe form to `active`, the state guest submission intake requires.\nSend it on the same PATCH that carries the edit, or on its own to\nrepublish what is already stored. Needs the recruiting tier or\nabove; publishing a form with no content is a 400."
|
|
8398
8406
|
},
|
|
8407
|
+
"languageCode": {
|
|
8408
|
+
"type": "string",
|
|
8409
|
+
"description": "The form's own language as a BCP-47 tag (e.g. `pl-PL`). Stamped by\nthe build pipeline; settable at create and changeable by PATCH.\n\nIt is part of the RENDER FALLBACK CHAIN: the apply page tries the\ncandidate's locale, then this one, then `en-US`. Every label and\noption label must resolve somewhere in that chain - in this locale\nOR in `en-US`, not necessarily both. A form with no `languageCode`\nis held to `en-US` alone. Change it and the labels in the same\nPATCH; the new text is validated against the new chain."
|
|
8410
|
+
},
|
|
8399
8411
|
"revision": {
|
|
8400
8412
|
"type": "integer",
|
|
8401
8413
|
"description": "Optimistic-concurrency token, bumped atomically on every write.\nSend it back as `If-Match: \"<revision>\"` on PATCH to make the\nwrite conditional; a mismatch is a 409 `SM_FORM_STALE`, meaning\nsomeone else saved since your read. Without the header the write\nis unconditional and the last writer wins - which for a form\nmeans silently replacing the whole field schema."
|
|
8402
8414
|
},
|
|
8415
|
+
"translate": {
|
|
8416
|
+
"type": "boolean",
|
|
8417
|
+
"description": "Fill missing locales on the field schema, asynchronously. Fires\nafter the write lands, so it can ride the same PATCH as an edit or\nbe sent alone. Targets the tenant's active languages plus the\nform's own `languageCode`, translating FROM the `en-US` text - a\nfield with no `en-US` label is skipped rather than invented.\n\nFill-only-missing: text already present in a locale is never\noverwritten, and an operator edit that lands mid-run wins (the\nfill re-merges only what is still missing). Field ids,\n`options[].value`, `knockout`, `verifies` and `expectedAnswer` are\nnever touched, so the tokens the submission gate compares survive.\n\nThe outcome lands in `meta.translation`\n(`status`, `translated`, `locales`, `startedAt`, `finishedAt`);\npoll `showForm` for it. Publishing is separate: the filled text\nreaches the apply page on the next `publish: true`."
|
|
8418
|
+
},
|
|
8403
8419
|
"publishedUrl": {
|
|
8404
8420
|
"type": "string",
|
|
8405
8421
|
"description": "Where the published document lives. Server-managed: the server\nowns the key it wrote, so never compose this URL client-side - a\nURL built from the wrong tenant shortCode is indistinguishable\nfrom a correct one."
|