diff --git a/package-lock.json b/package-lock.json index 9238dc0a9..d93e262d0 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,9 +1,12 @@ { "name": "TavernAI", + "version": "1.2.6", "lockfileVersion": 2, "requires": true, "packages": { "": { + "name": "TavernAI", + "version": "1.2.6", "dependencies": { "express": "^4.18.2", "multer": "^1.4.5-lts.1", @@ -14,6 +17,9 @@ "png-chunks-extract": "^1.0.0", "rimraf": "^3.0.2", "sharp": "^0.31.3" + }, + "bin": { + "TavernAI": "server.js" } }, "node_modules/accepts": { diff --git a/package.json b/package.json index 13d9f6ce9..d21e9d783 100644 --- a/package.json +++ b/package.json @@ -1,18 +1,32 @@ { - "dependencies": { - "express": "^4.18.2", - "multer": "^1.4.5-lts.1", - "node-rest-client": "^3.1.1", - "open": "^8.4.0", - "png-chunk-text": "^1.0.0", - "png-chunks-encode": "^1.0.0", - "png-chunks-extract": "^1.0.0", - "rimraf": "^3.0.2", - "sharp": "^0.31.3" - }, - "name": "TavernAI", - "version": "1.2.6", - "bin": { - "TavernAI": "server.js" - } + "dependencies": { + "express": "^4.18.2", + "multer": "^1.4.5-lts.1", + "node-rest-client": "^3.1.1", + "open": "^8.4.0", + "png-chunk-text": "^1.0.0", + "png-chunks-encode": "^1.0.0", + "png-chunks-extract": "^1.0.0", + "rimraf": "^3.0.2", + "sharp": "^0.31.3" + }, + "name": "TavernAI", + "version": "1.2.6", + "bin": { + "TavernAI": "server.js" + }, + "rules":{ + "no-path-concat":"off", + "no-var":"off" + + }, + "pkg":{ + "assets":[ + "node_modules/sharp/build/Release/**/*", + "node_modules/sharp/vendor/lib/**/*", + "node_modules/open/xdg-open/", + "public", + "uploads" + ] + } } \ No newline at end of file diff --git a/public/index.html b/public/index.html index bd3ce58b8..6dba50e47 100644 --- a/public/index.html +++ b/public/index.html @@ -589,6 +589,8 @@ if(mesExamples.length > 0){ mesExamples = mesExamples.replace(/{{user}}/gi, name1); mesExamples = mesExamples.replace(/{{char}}/gi, name2); + mesExamples = mesExamples.replace(//gi, name1); + mesExamples = mesExamples.replace(//gi, name2); //mesExamples = mesExamples.replaceAll('', '[An example of how '+name2+' responds]'); let blocks = mesExamples.split(//gi); mesExamplesArray = blocks.slice(1).map(block => `\n${block.trim()}\n`); @@ -2675,7 +2677,7 @@

Scenario

Circumstances and context of the dialogue
- +
diff --git a/public/notes/11.html b/public/notes/11.html index 3f6fd4843..ee7403547 100644 --- a/public/notes/11.html +++ b/public/notes/11.html @@ -18,6 +18,9 @@

<START>
{{user}}: Hello
{{char}}: *excitedly* Hello there, dear! Are you new to Axel? Don't worry, I, Aqua the goddess of water, am here to help you! Do you need any assistance? And may I say, I look simply radiant today! *strikes a pose and looks at you with puppy eyes*

+

A list of tags that are replaced when sending AI examples of dialogs:

+ {{user}} and <USER> are replaced by username
+ {{char}} and <BOT> are replaced by character name
diff --git a/server.js b/server.js index 9c55c51a5..f35e034ae 100644 --- a/server.js +++ b/server.js @@ -249,8 +249,8 @@ app.post("/getchat", jsonParser, function(request, response){ }); app.post("/getstatus", jsonParser, function(request, response_getstatus = response){ if(!request.body) return response_getstatus.sendStatus(400); - if(is_colab === true){ - api_server = '127.0.0.1:5000'; + if(is_colab == true){ + api_server = String(process.env.colaburl).trim(); }else{ api_server = request.body.api_server; }