@applitools/core-nlp 0.1.2 → 0.2.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.
- package/CHANGELOG.md +27 -0
- package/dist/nlp.js +13 -0
- package/package.json +3 -3
- package/types/types.d.ts +2 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,32 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.2.0](https://github.com/Applitools-Dev/sdk/compare/js/core-nlp@0.1.2...js/core-nlp@0.2.0) (2026-10-12)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* report NLP step counts per Eyes session | AD-16681 ([#4257](https://github.com/Applitools-Dev/sdk/issues/4257)) ([b84a1cc](https://github.com/Applitools-Dev/sdk/commit/b84a1ccac25c4d61a98ee382a18f54c1011c53e6))
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Dependencies
|
|
12
|
+
|
|
13
|
+
* @applitools/req bumped to 1.11.4
|
|
14
|
+
#### Bug Fixes
|
|
15
|
+
|
|
16
|
+
* version-check/telemetry no longer hold the process — connect deadline + unref | AD-16613 ([#4232](https://github.com/Applitools-Dev/sdk/issues/4232)) ([42bcbb5](https://github.com/Applitools-Dev/sdk/commit/42bcbb5dd8d75ad4aa98c2ec0d284f107fdc98e3))
|
|
17
|
+
* @applitools/core-base bumped to 1.41.0
|
|
18
|
+
#### Features
|
|
19
|
+
|
|
20
|
+
* report NLP step counts per Eyes session | AD-16681 ([#4257](https://github.com/Applitools-Dev/sdk/issues/4257)) ([b84a1cc](https://github.com/Applitools-Dev/sdk/commit/b84a1ccac25c4d61a98ee382a18f54c1011c53e6))
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
#### Bug Fixes
|
|
24
|
+
|
|
25
|
+
* version-check/telemetry no longer hold the process — connect deadline + unref | AD-16613 ([#4232](https://github.com/Applitools-Dev/sdk/issues/4232)) ([42bcbb5](https://github.com/Applitools-Dev/sdk/commit/42bcbb5dd8d75ad4aa98c2ec0d284f107fdc98e3))
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
|
|
3
30
|
## [0.1.2](https://github.com/Applitools-Dev/sdk/compare/js/core-nlp@0.1.1...js/core-nlp@0.1.2) (2026-10-01)
|
|
4
31
|
|
|
5
32
|
|
package/dist/nlp.js
CHANGED
|
@@ -37,6 +37,18 @@ async function loadNlpModules() {
|
|
|
37
37
|
}
|
|
38
38
|
return modulesPromise;
|
|
39
39
|
}
|
|
40
|
+
// The engine bundles its parser and stamps both with the package version, but reports it only in a
|
|
41
|
+
// log event, so the exported `package.json` is the stable source — and reading it never loads the engine.
|
|
42
|
+
function getParserVersion() {
|
|
43
|
+
if (!nodeSupportsNlp())
|
|
44
|
+
return undefined;
|
|
45
|
+
try {
|
|
46
|
+
return require(`${constants_1.NLP_WEB_RUNNER}/package.json`).version;
|
|
47
|
+
}
|
|
48
|
+
catch {
|
|
49
|
+
return undefined;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
40
52
|
function makeNlpLogger(logger) {
|
|
41
53
|
if (!logger)
|
|
42
54
|
return undefined;
|
|
@@ -170,6 +182,7 @@ function makeNlp(adapter, options = {}) {
|
|
|
170
182
|
reportStep(logger, step, result);
|
|
171
183
|
return results;
|
|
172
184
|
},
|
|
185
|
+
getParserVersion,
|
|
173
186
|
async dispose() {
|
|
174
187
|
const activeRunnerPromise = runnerPromise;
|
|
175
188
|
runnerPromise = undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applitools/core-nlp",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"keywords": [
|
|
5
5
|
"nlp",
|
|
6
6
|
"natural language",
|
|
@@ -30,9 +30,9 @@
|
|
|
30
30
|
"test": "run --top-level mocha './test/**/*.spec.ts' --exit"
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@applitools/core-base": "1.
|
|
33
|
+
"@applitools/core-base": "1.41.0",
|
|
34
34
|
"@applitools/logger": "2.3.1",
|
|
35
|
-
"@applitools/req": "1.11.
|
|
35
|
+
"@applitools/req": "1.11.4",
|
|
36
36
|
"@applitools/utils": "1.15.2"
|
|
37
37
|
},
|
|
38
38
|
"optionalDependencies": {
|
package/types/types.d.ts
CHANGED
|
@@ -48,6 +48,8 @@ export interface MakeNlpOptions {
|
|
|
48
48
|
}
|
|
49
49
|
export interface Nlp {
|
|
50
50
|
run(step: string): Promise<StepResult[]>;
|
|
51
|
+
/** Version of the engine's bundled NLP parser; `undefined` when the engine is unavailable. Never throws. */
|
|
52
|
+
getParserVersion(): string | undefined;
|
|
51
53
|
dispose(): Promise<void>;
|
|
52
54
|
}
|
|
53
55
|
export type Browser = {
|