mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-16 16:30:15 +01:00
* adding youtube tool * refactor: use short `url` param instead of `videoUrl` * refactor: move API key retrieval to a separate credentials module * refactor: remove unnecessary `isEdited` message property * refactor: remove unnecessary `isEdited` message property pt. 2 * refactor: YouTube Tool with new `tool()` generator, handle tools already created by new `tool` generator * fix: only reset request data for multi-convo messages * refactor: enhance YouTube tool by adding transcript parsing and returning structured JSON responses * refactor: update transcript parsing to handle raw response and clean up text output * feat: support toolkits and refactor YouTube tool as a toolkit for better LLM usage * refactor: remove unused OpenAPI specs and streamline tools transformation in loadAsyncEndpoints * refactor: implement manifestToolMap for better tool management and streamline authentication handling * feat: support toolkits for assistants * refactor: rename loadedTools to toolDefinitions for clarity in PluginController and assistant controllers * feat: complete support of toolkits for assistants --------- Co-authored-by: Danilo Pejakovic <danilo.pejakovic@leoninestudios.com>
41 lines
1.1 KiB
JavaScript
41 lines
1.1 KiB
JavaScript
const availableTools = require('./manifest.json');
|
|
|
|
// Structured Tools
|
|
const DALLE3 = require('./structured/DALLE3');
|
|
const OpenWeather = require('./structured/OpenWeather');
|
|
const createYouTubeTools = require('./structured/YouTube');
|
|
const StructuredWolfram = require('./structured/Wolfram');
|
|
const StructuredACS = require('./structured/AzureAISearch');
|
|
const StructuredSD = require('./structured/StableDiffusion');
|
|
const GoogleSearchAPI = require('./structured/GoogleSearch');
|
|
const TraversaalSearch = require('./structured/TraversaalSearch');
|
|
const TavilySearchResults = require('./structured/TavilySearchResults');
|
|
|
|
/** @type {Record<string, TPlugin | undefined>} */
|
|
const manifestToolMap = {};
|
|
|
|
/** @type {Array<TPlugin>} */
|
|
const toolkits = [];
|
|
|
|
availableTools.forEach((tool) => {
|
|
manifestToolMap[tool.pluginKey] = tool;
|
|
if (tool.toolkit === true) {
|
|
toolkits.push(tool);
|
|
}
|
|
});
|
|
|
|
module.exports = {
|
|
toolkits,
|
|
availableTools,
|
|
manifestToolMap,
|
|
// Structured Tools
|
|
DALLE3,
|
|
OpenWeather,
|
|
StructuredSD,
|
|
StructuredACS,
|
|
GoogleSearchAPI,
|
|
TraversaalSearch,
|
|
StructuredWolfram,
|
|
createYouTubeTools,
|
|
TavilySearchResults,
|
|
};
|