Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

®️ feat: Support Rscript for Code Interpreter & recursionLimit for Agents #5170

Merged
merged 11 commits into from
Jan 3, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@
"@keyv/redis": "^2.8.1",
"@langchain/community": "^0.3.14",
"@langchain/core": "^0.3.18",
"@langchain/google-genai": "^0.1.4",
"@langchain/google-vertexai": "^0.1.4",
"@langchain/google-genai": "^0.1.6",
"@langchain/google-vertexai": "^0.1.6",
"@langchain/textsplitters": "^0.1.0",
"@librechat/agents": "^1.9.7",
"@librechat/agents": "^1.9.92",
"axios": "^1.7.7",
"bcryptjs": "^2.4.3",
"cheerio": "^1.0.0-rc.12",
Expand Down
1 change: 1 addition & 0 deletions api/server/controllers/agents/client.js
Original file line number Diff line number Diff line change
Expand Up @@ -494,6 +494,7 @@ class AgentClient extends BaseClient {
last_agent_index: this.agentConfigs?.size ?? 0,
hide_sequential_outputs: this.options.agent.hide_sequential_outputs,
},
recursionLimit: this.options.req.app.locals[EModelEndpoint.agents]?.recursionLimit,
signal: abortController.signal,
streamMode: 'values',
version: 'v2',
Expand Down
2 changes: 1 addition & 1 deletion api/server/services/Files/Code/crud.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ const axios = require('axios');
const FormData = require('form-data');
const { getCodeBaseURL } = require('@librechat/agents');

const MAX_FILE_SIZE = 25 * 1024 * 1024;
const MAX_FILE_SIZE = 150 * 1024 * 1024;

/**
* Retrieves a download stream for a specified file.
Expand Down
1 change: 1 addition & 0 deletions client/public/assets/r.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ export default function ApiKeyDialog({
'cplusplus.svg',
'php.svg',
'fortran.svg',
'r.svg',
];

return (
Expand Down
5 changes: 4 additions & 1 deletion librechat.example.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# https://www.librechat.ai/docs/configuration/librechat_yaml

# Configuration version (required)
version: 1.2.0
version: 1.2.1

# Cache settings: Set to true to enable caching
cache: true
Expand Down Expand Up @@ -149,6 +149,9 @@ endpoints:
# # (optional) Assistant Capabilities available to all users. Omit the ones you wish to exclude. Defaults to list below.
# capabilities: ["code_interpreter", "retrieval", "actions", "tools", "image_vision"]
# agents:
# (optional) Maximum recursion depth for agents, defaults to 25
# recursionLimit: 50
# (optional) Disable the builder interface for agents
# disableBuilder: false
# (optional) Agent Capabilities available to all users. Omit the ones you wish to exclude. Defaults to list below.
# capabilities: ["execute_code", "file_search", "actions", "tools"]
Expand Down
103 changes: 30 additions & 73 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/data-provider/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "librechat-data-provider",
"version": "0.7.67",
"version": "0.7.68",
"description": "data services for librechat apps",
"main": "dist/index.js",
"module": "dist/index.es.js",
Expand Down
6 changes: 4 additions & 2 deletions packages/data-provider/src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,7 @@ export type TAssistantEndpoint = z.infer<typeof assistantEndpointSchema>;
export const agentsEndpointSChema = baseEndpointSchema.merge(
z.object({
/* agents specific */
recursionLimit: z.number().optional(),
disableBuilder: z.boolean().optional(),
capabilities: z
.array(z.nativeEnum(AgentCapabilities))
Expand Down Expand Up @@ -739,6 +740,7 @@ export const supportsBalanceCheck = {
};

export const visionModels = [
'o1',
'gpt-4o',
'gpt-4o-mini',
'gpt-4-turbo',
Expand Down Expand Up @@ -775,7 +777,7 @@ export function validateVisionModel({
return false;
}

if (model === 'gpt-4-turbo-preview') {
if (model.includes('gpt-4-turbo-preview') || model.includes('o1-mini')) {
return false;
}

Expand Down Expand Up @@ -1088,7 +1090,7 @@ export enum Constants {
/** Key for the app's version. */
VERSION = 'v0.7.6',
/** Key for the Custom Config's version (librechat.yaml). */
CONFIG_VERSION = '1.2.0',
CONFIG_VERSION = '1.2.1',
/** Standard value for the first message's `parentMessageId` value, to indicate no parent exists. */
NO_PARENT = '00000000-0000-0000-0000-000000000000',
/** Standard value for the initial conversationId before a request is sent */
Expand Down
Loading