aotrautils 0.0.1976 → 0.0.1978

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.
@@ -1,6 +1,6 @@
1
1
 
2
2
 
3
- /*utils COMMONS library associated with aotra version : «1_29072022-2359 (09/09/2026-00:40:27)»*/
3
+ /*utils COMMONS library associated with aotra version : «1_29072022-2359 (09/09/2026-01:11:21)»*/
4
4
  /*-----------------------------------------------------------------------------*/
5
5
 
6
6
 
@@ -5475,7 +5475,7 @@ window.AOTRAUTILS_LIB_IS_LOADED=true;
5475
5475
 
5476
5476
 
5477
5477
 
5478
- /*utils CLIENT library associated with aotra version : «1_29072022-2359 (09/09/2026-00:40:27)»*/
5478
+ /*utils CLIENT library associated with aotra version : «1_29072022-2359 (09/09/2026-01:11:21)»*/
5479
5479
  /*-----------------------------------------------------------------------------*/
5480
5480
  /* ## Utility global methods in a browser (htmljs) client environment.
5481
5481
  *
@@ -12990,7 +12990,7 @@ window.createOritaMicroClient=function(url, port, isNode=false, staticMicroClien
12990
12990
 
12991
12991
 
12992
12992
 
12993
- /*utils GEOMETRY library associated with aotra version : «1_29072022-2359 (09/09/2026-00:40:27)»*/
12993
+ /*utils GEOMETRY library associated with aotra version : «1_29072022-2359 (09/09/2026-01:11:21)»*/
12994
12994
  /*-----------------------------------------------------------------------------*/
12995
12995
 
12996
12996
 
@@ -14052,10 +14052,10 @@ function rayVsUnitSphereClosestPoint(p, r) {
14052
14052
  // MUST REMAIN AT THE END OF THIS LIBRARY FILE !
14053
14053
 
14054
14054
  window.AOTRAUTILS_GEOMETRY_LIB_IS_LOADED=true;
14055
- /*utils 3D library associated with aotra version : «1_29072022-2359 (09/09/2026-00:40:27)»*/
14055
+ /*utils 3D library associated with aotra version : «1_29072022-2359 (09/09/2026-01:11:21)»*/
14056
14056
  /*-----------------------------------------------------------------------------*/
14057
14057
 
14058
- /*utils AI library associated with aotra version : «1_29072022-2359 (09/09/2026-00:40:27)»*/
14058
+ /*utils AI library associated with aotra version : «1_29072022-2359 (09/09/2026-01:11:21)»*/
14059
14059
  /*-----------------------------------------------------------------------------*/
14060
14060
 
14061
14061
 
@@ -14133,9 +14133,15 @@ window.LLMAPIClient=class LLMAPIClient{
14133
14133
 
14134
14134
  const messages=this.getMessages(newDefaultPrompt, userPrompt);
14135
14135
 
14136
- const result=await this.launchRequest(AIAPIKey, messages);
14136
+ try{
14137
+ const result=await this.launchLLMRequest(AIAPIKey, messages);
14138
+ return result;
14139
+ }catch(error){
14140
+ // TRACE
14141
+ lognow("ERROR : LLM provider returned an error when prompted, returning error object, wrapped : ",error);
14142
+ return {error:error};
14143
+ }
14137
14144
 
14138
- return result;
14139
14145
  }
14140
14146
 
14141
14147
 
@@ -14148,7 +14154,7 @@ window.LLMAPIClient=class LLMAPIClient{
14148
14154
  }
14149
14155
 
14150
14156
 
14151
- /*private*/launchRequest(AIAPIKey, messages){
14157
+ /*private*/launchLLMRequest(AIAPIKey, messages){
14152
14158
 
14153
14159
  const self=this;
14154
14160
 
@@ -14167,9 +14173,10 @@ window.LLMAPIClient=class LLMAPIClient{
14167
14173
 
14168
14174
  if(data.error){
14169
14175
  const error=data.error;
14176
+
14170
14177
  // TRACE
14171
- console.error("Error:", error);
14172
- reject(new Error(`${error}`));
14178
+ lognow("ERROR:", error);
14179
+ reject(error);
14173
14180
  }
14174
14181
 
14175
14182
  const assistantReply=self.getAssistantReply(data);
@@ -14178,6 +14185,7 @@ window.LLMAPIClient=class LLMAPIClient{
14178
14185
  }).catch(errorObj=>{
14179
14186
  const error=errorObj.error;
14180
14187
  const httpStatus=errorObj.httpStatus;
14188
+
14181
14189
  // TRACE
14182
14190
  lognow("ERROR:", error);
14183
14191
  reject(error);
@@ -14315,7 +14323,7 @@ window.getLLMAPIClient=(modelName, apiURL, agentRole, defaultPrompt, llmProvider
14315
14323
 
14316
14324
 
14317
14325
 
14318
- /*utils CONSOLE library associated with aotra version : «1_29072022-2359 (09/09/2026-00:40:27)»*/
14326
+ /*utils CONSOLE library associated with aotra version : «1_29072022-2359 (09/09/2026-01:11:21)»*/
14319
14327
  /*-----------------------------------------------------------------------------*/
14320
14328
 
14321
14329
 
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "aotrautils",
3
- "version": "0.0.1976",
3
+ "version": "0.0.1978",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "aotrautils",
9
- "version": "0.0.1976",
9
+ "version": "0.0.1978",
10
10
  "license": "HGPL-1.0",
11
11
  "dependencies": {
12
12
  "atob": "^2.1.2",
aotrautils/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aotrautils",
3
- "version": "0.0.1976",
3
+ "version": "0.0.1978",
4
4
  "main": "aotrautils.build.js",
5
5
  "description": "A library for vanilla javascript utils (client-side) used in aotra javascript CMS",
6
6
  "author": "Jeremie Ratomposon <info@alqemia.com> (https://alqemia.com)",