mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-02-11 20:14:24 +01:00
Release: 0.5.3 (#599)
* release: 0.5.3, add extra linting rule and minor fix for EndpointDialog * chore: revert to deprecated Message Classes as weird behavior seen in linux * chore(api): remove unused test scripts chore(package.json): remove unused langchain dependency * chore(.gitignore): add /images directory to the ignore list
This commit is contained in:
parent
69d192bac3
commit
2607f157d3
10 changed files with 19 additions and 289 deletions
|
|
@ -245,7 +245,7 @@ class OpenAIClient extends BaseClient {
|
|||
// TODO: need to handle interleaving instructions better
|
||||
if (this.contextStrategy) {
|
||||
({ payload, tokenCountMap, promptTokens, messages } =
|
||||
await this.handleContextStrategy({instructions, orderedMessages, formattedMessages}));
|
||||
await this.handleContextStrategy({ instructions, orderedMessages, formattedMessages }));
|
||||
}
|
||||
|
||||
const result = {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ const { CallbackManager } = require('langchain/callbacks');
|
|||
const { initializeCustomAgent, initializeFunctionsAgent } = require('./agents/');
|
||||
const { loadTools } = require('./tools/util');
|
||||
const { SelfReflectionTool } = require('./tools/');
|
||||
const { HumanMessage, AIMessage } = require('langchain/schema');
|
||||
const { HumanChatMessage, AIChatMessage } = require('langchain/schema');
|
||||
const {
|
||||
instructions,
|
||||
imageInstructions,
|
||||
|
|
@ -237,8 +237,8 @@ Only respond with your conversational reply to the following User Message:
|
|||
// Map Messages to Langchain format
|
||||
const pastMessages = this.currentMessages.slice(0, -1).map(
|
||||
msg => msg?.isCreatedByUser || msg?.role?.toLowerCase() === 'user'
|
||||
? new HumanMessage(msg.text)
|
||||
: new AIMessage(msg.text));
|
||||
? new HumanChatMessage(msg.text)
|
||||
: new AIChatMessage(msg.text));
|
||||
|
||||
// initialize agent
|
||||
const initializer = this.functionsAgent ? initializeFunctionsAgent : initializeCustomAgent;
|
||||
|
|
|
|||
|
|
@ -1,18 +1,12 @@
|
|||
{
|
||||
"name": "@librechat/backend",
|
||||
"version": "0.5.2",
|
||||
"version": "0.5.3",
|
||||
"description": "",
|
||||
"scripts": {
|
||||
"start": "echo 'please run this from the root directory'",
|
||||
"server-dev": "echo 'please run this from the root directory'",
|
||||
"test": "cross-env NODE_ENV=test jest",
|
||||
"test:ci": "jest --ci",
|
||||
"test2": "node --inspect app/langchain/test2.js",
|
||||
"test3": "node --inspect app/langchain/test3.js",
|
||||
"test4": "node --inspect app/langchain/test4.js",
|
||||
"test5": "node --inspect app/langchain/test5.js",
|
||||
"test8": "node --inspect app/langchain/test8.js",
|
||||
"langchain": "node app/langchain/test2.js"
|
||||
"test:ci": "jest --ci"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue