@botpress/cognitive 0.3.0 → 0.3.2
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/.turbo/turbo-build.log +7 -7
- package/dist/index.cjs +19 -9
- package/dist/index.cjs.map +2 -2
- package/dist/index.d.ts +232 -27
- package/dist/index.mjs +19 -9
- package/dist/index.mjs.map +2 -2
- package/package.json +3 -2
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,28 +1,28 @@
|
|
|
1
1
|
|
|
2
|
-
> @botpress/cognitive@0.3.
|
|
2
|
+
> @botpress/cognitive@0.3.2 build /home/runner/work/botpress/botpress/packages/cognitive
|
|
3
3
|
> pnpm build:type && pnpm build:neutral && size-limit
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
> @botpress/cognitive@0.3.
|
|
6
|
+
> @botpress/cognitive@0.3.2 build:type /home/runner/work/botpress/botpress/packages/cognitive
|
|
7
7
|
> tsup --tsconfig tsconfig.build.json ./src/index.ts --dts-resolve --dts-only --clean
|
|
8
8
|
|
|
9
9
|
CLI Building entry: ./src/index.ts
|
|
10
10
|
CLI Using tsconfig: tsconfig.build.json
|
|
11
11
|
CLI tsup v8.0.2
|
|
12
12
|
DTS Build start
|
|
13
|
-
DTS ⚡️ Build success in
|
|
14
|
-
DTS dist/index.d.ts
|
|
13
|
+
DTS ⚡️ Build success in 6790ms
|
|
14
|
+
DTS dist/index.d.ts 650.29 KB
|
|
15
15
|
|
|
16
|
-
> @botpress/cognitive@0.3.
|
|
16
|
+
> @botpress/cognitive@0.3.2 build:neutral /home/runner/work/botpress/botpress/packages/cognitive
|
|
17
17
|
> ts-node -T ./build.ts --neutral
|
|
18
18
|
|
|
19
19
|
Done
|
|
20
20
|
|
|
21
21
|
[1mdist/index.cjs[22m
|
|
22
22
|
Size limit: [32m[1m50 kB[22m[39m
|
|
23
|
-
Size: [32m[1m15.
|
|
23
|
+
Size: [32m[1m15.26 kB[22m[39m [90mbrotlied[39m
|
|
24
24
|
|
|
25
25
|
[1mdist/index.mjs[22m
|
|
26
26
|
Size limit: [32m[1m50 kB[22m[39m
|
|
27
|
-
Size: [32m[1m15.
|
|
27
|
+
Size: [32m[1m15.12 kB[22m[39m [90mbrotlied[39m
|
|
28
28
|
|
package/dist/index.cjs
CHANGED
|
@@ -621,10 +621,6 @@ var getExtendedClient = (_client) => {
|
|
|
621
621
|
if (typeof client.constructor !== "function" || typeof client.callAction !== "function" || !client.config || typeof client.config !== "object" || !client.config.headers) {
|
|
622
622
|
throw new Error("Client must be a valid instance of a Botpress client (@botpress/client)");
|
|
623
623
|
}
|
|
624
|
-
const botId = client.config.headers["x-bot-id"];
|
|
625
|
-
if (!botId?.length) {
|
|
626
|
-
throw new Error("Client must be instanciated with Bot ID");
|
|
627
|
-
}
|
|
628
624
|
const clone = () => {
|
|
629
625
|
const c = client;
|
|
630
626
|
if (c.clone && typeof c.clone === "function") {
|
|
@@ -634,7 +630,6 @@ var getExtendedClient = (_client) => {
|
|
|
634
630
|
};
|
|
635
631
|
return {
|
|
636
632
|
...client,
|
|
637
|
-
botId,
|
|
638
633
|
axios: client.axiosInstance,
|
|
639
634
|
clone,
|
|
640
635
|
abortable: (signal) => {
|
|
@@ -652,6 +647,21 @@ var import_exponential_backoff = __toESM(require_backoff());
|
|
|
652
647
|
|
|
653
648
|
// src/cognitive-v2/models.ts
|
|
654
649
|
var models = {
|
|
650
|
+
"openai:gpt-5.2-2025-12-11": {
|
|
651
|
+
id: "openai:gpt-5.2-2025-12-11",
|
|
652
|
+
name: "GPT-5.2",
|
|
653
|
+
description: "GPT-5.2 is the latest frontier-grade model in the GPT-5 series, offering stronger agentic and long context perfomance compared to GPT-5.1. It uses adaptive reasoning to allocate computation dynamically, responding quickly to simple queries while spending more depth on complex tasks.",
|
|
654
|
+
input: {
|
|
655
|
+
maxTokens: 4e5,
|
|
656
|
+
costPer1MTokens: 1.75
|
|
657
|
+
},
|
|
658
|
+
output: {
|
|
659
|
+
maxTokens: 128e3,
|
|
660
|
+
costPer1MTokens: 14
|
|
661
|
+
},
|
|
662
|
+
tags: ["recommended", "reasoning", "general-purpose", "vision"],
|
|
663
|
+
lifecycle: "production"
|
|
664
|
+
},
|
|
655
665
|
"openai:gpt-5.1-2025-11-13": {
|
|
656
666
|
id: "openai:gpt-5.1-2025-11-13",
|
|
657
667
|
name: "GPT-5.1",
|
|
@@ -664,7 +674,7 @@ var models = {
|
|
|
664
674
|
maxTokens: 128e3,
|
|
665
675
|
costPer1MTokens: 10
|
|
666
676
|
},
|
|
667
|
-
tags: ["recommended", "reasoning", "general-purpose"],
|
|
677
|
+
tags: ["recommended", "reasoning", "general-purpose", "vision"],
|
|
668
678
|
lifecycle: "production"
|
|
669
679
|
},
|
|
670
680
|
"openai:gpt-5-2025-08-07": {
|
|
@@ -679,7 +689,7 @@ var models = {
|
|
|
679
689
|
maxTokens: 128e3,
|
|
680
690
|
costPer1MTokens: 10
|
|
681
691
|
},
|
|
682
|
-
tags: ["reasoning", "general-purpose"],
|
|
692
|
+
tags: ["reasoning", "general-purpose", "vision"],
|
|
683
693
|
lifecycle: "production",
|
|
684
694
|
aliases: ["gpt-5"]
|
|
685
695
|
},
|
|
@@ -695,7 +705,7 @@ var models = {
|
|
|
695
705
|
maxTokens: 128e3,
|
|
696
706
|
costPer1MTokens: 2
|
|
697
707
|
},
|
|
698
|
-
tags: ["recommended", "reasoning", "general-purpose"],
|
|
708
|
+
tags: ["recommended", "reasoning", "general-purpose", "vision"],
|
|
699
709
|
lifecycle: "production",
|
|
700
710
|
aliases: ["gpt-5-mini"]
|
|
701
711
|
},
|
|
@@ -711,7 +721,7 @@ var models = {
|
|
|
711
721
|
maxTokens: 128e3,
|
|
712
722
|
costPer1MTokens: 0.4
|
|
713
723
|
},
|
|
714
|
-
tags: ["low-cost", "reasoning", "general-purpose"],
|
|
724
|
+
tags: ["low-cost", "reasoning", "general-purpose", "vision"],
|
|
715
725
|
lifecycle: "production",
|
|
716
726
|
aliases: ["gpt-5-nano"]
|
|
717
727
|
},
|