From 937ff4ebe380739101a3d483234eab8bc5cdcaf3 Mon Sep 17 00:00:00 2001 From: octo-patch Date: Sun, 19 Apr 2026 11:32:40 +0800 Subject: [PATCH] refactor: remove empty bot constructors that only call super() Removes unnecessary boilerplate constructors across 78 bot files where the constructor only calls super() with no additional initialization. JavaScript classes automatically invoke the parent constructor when no constructor is defined, so these are redundant. Closes #1008 --- src/bots/CharacterAIBot.js | 4 ---- src/bots/ClaudeAIBot.js | 4 ---- src/bots/DevBot.js | 4 ---- src/bots/LangChainBot.js | 4 ---- src/bots/MOSSBot.js | 4 ---- src/bots/MistralBot.js | 4 ---- src/bots/PerplexityBot.js | 4 ---- src/bots/PhindBot.js | 4 ---- src/bots/PiBot.js | 4 ---- src/bots/QianWenBot.js | 4 ---- src/bots/Qihoo360AIBrainBot.js | 4 ---- src/bots/SkyWorkBot.js | 4 ---- src/bots/SparkBot.js | 4 ---- src/bots/TemplateBot.js | 4 ---- src/bots/YouChatBot.js | 4 ---- src/bots/anthropic/ClaudeAPI20Bot.js | 3 --- src/bots/anthropic/ClaudeAPI21Bot.js | 3 --- src/bots/anthropic/ClaudeAPI37SonnetBot.js | 3 --- src/bots/anthropic/ClaudeAPIBot.js | 4 ---- src/bots/anthropic/ClaudeAPIHaikuBot.js | 3 --- src/bots/anthropic/ClaudeAPIOpusBot.js | 3 --- src/bots/anthropic/ClaudeAPISonnetBot.js | 3 --- src/bots/baidu/ERNIEBot.js | 4 ---- src/bots/baidu/WenxinQianfan4Bot.js | 4 ---- src/bots/baidu/WenxinQianfanBot.js | 4 ---- src/bots/baidu/WenxinQianfanTurboBot.js | 4 ---- src/bots/cohere/CohereAPIAya23Bot.js | 3 --- src/bots/cohere/CohereAPIBot.js | 4 ---- src/bots/cohere/CohereAPICommandBot.js | 3 --- src/bots/cohere/CohereAPICommandLightBot.js | 3 --- src/bots/cohere/CohereAPICommandRBot.js | 3 --- src/bots/cohere/CohereAPICommandRPlusBot.js | 3 --- src/bots/google/BardBot.js | 4 ---- src/bots/google/Gemini15FlashAPIBot.js | 4 ---- src/bots/google/Gemini15ProAPIBot.js | 4 ---- src/bots/google/Gemini20FlashAPIBot.js | 4 ---- src/bots/google/Gemini20FlashLiteAPIBot.js | 4 ---- src/bots/google/GeminiAPIBot.js | 4 ---- src/bots/google/GeminiAdvBot.js | 4 ---- src/bots/groq/Gemma29bGroqAPIBot.js | 3 --- src/bots/groq/Gemma7bGroqAPIBot.js | 3 --- src/bots/groq/GroqAPIBot.js | 4 ---- src/bots/groq/Llama370bGroqAPIBot.js | 3 --- src/bots/groq/Llama38bGroqAPIBot.js | 3 --- src/bots/groq/Llama4MaverickGroqAPIBot.js | 3 --- src/bots/groq/Llama4ScoutGroqAPIBot.js | 3 --- src/bots/huggingface/GradioBot.js | 4 ---- src/bots/huggingface/HuggingChatBot.js | 4 ---- src/bots/lmsys/LMSYSBot.js | 4 ---- src/bots/microsoft/AzureOpenAIAPIBot.js | 4 ---- src/bots/microsoft/BingChatBalancedBot.js | 4 ---- src/bots/microsoft/BingChatBot.js | 4 ---- src/bots/microsoft/BingChatCreativeBot.js | 4 ---- src/bots/microsoft/BingChatPreciseBot.js | 4 ---- src/bots/moonshot/KimiBot.js | 4 ---- src/bots/openai/ChatGPT4Bot.js | 4 ---- src/bots/openai/OpenAIAPI35Bot.js | 4 ---- src/bots/openai/OpenAIAPI4128KBot.js | 4 ---- src/bots/openai/OpenAIAPI41Bot.js | 4 ---- src/bots/openai/OpenAIAPI41MiniBot.js | 4 ---- src/bots/openai/OpenAIAPI41NanoBot.js | 4 ---- src/bots/openai/OpenAIAPI45Bot.js | 4 ---- src/bots/openai/OpenAIAPI4Bot.js | 4 ---- src/bots/openai/OpenAIAPI4oBot.js | 4 ---- src/bots/openai/OpenAIAPI4oMiniBot.js | 4 ---- src/bots/openai/OpenAIAPIBot.js | 4 ---- src/bots/openai/OpenAIAPIo1Bot.js | 4 ---- src/bots/openai/OpenAIAPIo1MiniBot.js | 4 ---- src/bots/openai/OpenAIAPIo3Bot.js | 4 ---- src/bots/openai/OpenAIAPIo3MiniBot.js | 4 ---- src/bots/openai/OpenAIAPIo4MiniBot.js | 4 ---- src/bots/poe/PoeBot.js | 4 ---- src/bots/xai/Grok2APIBot.js | 3 --- src/bots/xai/Grok3APIBot.js | 3 --- src/bots/xai/Grok3MiniAPIBot.js | 3 --- src/bots/xai/xAIAPIBot.js | 4 ---- src/bots/zhipu/ChatGLM4Bot.js | 4 ---- src/bots/zhipu/ChatGLMBot.js | 4 ---- 78 files changed, 292 deletions(-) diff --git a/src/bots/CharacterAIBot.js b/src/bots/CharacterAIBot.js index 92c06b6dee..5fa41b93c1 100644 --- a/src/bots/CharacterAIBot.js +++ b/src/bots/CharacterAIBot.js @@ -18,10 +18,6 @@ export default class CharacterAIBot extends Bot { return uuidv4().split("-").fill("vhj9cXafWcF8", 4, 5).join("-"); } - constructor() { - super(); - } - /** * Check whether the bot is logged in, settings are correct, etc. * @returns {boolean} - true if the bot is available, false otherwise. diff --git a/src/bots/ClaudeAIBot.js b/src/bots/ClaudeAIBot.js index 97fc5062b6..45f6efbec0 100644 --- a/src/bots/ClaudeAIBot.js +++ b/src/bots/ClaudeAIBot.js @@ -13,10 +13,6 @@ export default class ClaudeAIBot extends Bot { static _loginUrl = "https://claude.ai/"; static _lock = new AsyncLock(); // AsyncLock for prompt requests - constructor() { - super(); - } - /** * Check whether the bot is logged in, settings are correct, etc. * @returns {boolean} - true if the bot is available, false otherwise. diff --git a/src/bots/DevBot.js b/src/bots/DevBot.js index 080fe9da91..3068f4a4a2 100644 --- a/src/bots/DevBot.js +++ b/src/bots/DevBot.js @@ -8,10 +8,6 @@ export default class DevBot extends Bot { static _loginUrl = "http://chatall.ai"; static _isAvailable = true; - constructor() { - super(); - } - /** * Check whether the bot is logged in, settings are correct, etc. * @returns {boolean} - true if the bot is available, false otherwise. diff --git a/src/bots/LangChainBot.js b/src/bots/LangChainBot.js index 0ecba51be6..95be79ac8e 100644 --- a/src/bots/LangChainBot.js +++ b/src/bots/LangChainBot.js @@ -5,10 +5,6 @@ export default class LangChainBot extends Bot { static _brandId = "langChainBot"; static _chatModel = undefined; // ChatModel instance - constructor() { - super(); - } - async _sendPrompt(prompt, onUpdateResponse, callbackParam) { let messages = await this.getChatContext(); let bufferMemory = new BufferMemory(); diff --git a/src/bots/MOSSBot.js b/src/bots/MOSSBot.js index 3c9989be40..93d1344ae2 100644 --- a/src/bots/MOSSBot.js +++ b/src/bots/MOSSBot.js @@ -13,10 +13,6 @@ export default class MOSSBot extends Bot { static _loginUrl = "https://moss.fastnlp.top/moss/"; static _lock = new AsyncLock(); - constructor() { - super(); - } - getAuthHeader() { const token = store.state.moss?.token?.refresh; return { diff --git a/src/bots/MistralBot.js b/src/bots/MistralBot.js index 1a74579bc1..d4d791c10b 100644 --- a/src/bots/MistralBot.js +++ b/src/bots/MistralBot.js @@ -9,10 +9,6 @@ export default class MistralBot extends Bot { static _logoFilename = "mistral-logo.png"; // Place it in public/bots/ static _loginUrl = "https://chat.mistral.ai/login"; - constructor() { - super(); - } - async _checkAvailability() { let available = false; try { diff --git a/src/bots/PerplexityBot.js b/src/bots/PerplexityBot.js index 62e7aee945..5d575b407b 100644 --- a/src/bots/PerplexityBot.js +++ b/src/bots/PerplexityBot.js @@ -11,10 +11,6 @@ export default class PerplexityBot extends Bot { static _isDarkLogo = true; // True if the main color of logo is dark static _loginUrl = "https://www.perplexity.ai"; - constructor() { - super(); - } - async _checkAvailability() { let available = false; try { diff --git a/src/bots/PhindBot.js b/src/bots/PhindBot.js index e9614bba24..0ea74cc491 100644 --- a/src/bots/PhindBot.js +++ b/src/bots/PhindBot.js @@ -13,10 +13,6 @@ export default class PhindBot extends Bot { static _loginUrl = "https://www.phind.com"; static _lock = new AsyncLock(); // AsyncLock for prompt requests - constructor() { - super(); - } - /** * Check whether the bot is logged in, settings are correct, etc. * @returns {boolean} - true if the bot is available, false otherwise. diff --git a/src/bots/PiBot.js b/src/bots/PiBot.js index 8199e33c41..e72b85d3dd 100644 --- a/src/bots/PiBot.js +++ b/src/bots/PiBot.js @@ -10,10 +10,6 @@ export default class PiBot extends Bot { static _loginUrl = "https://pi.ai/"; static _lock = new AsyncLock(); // AsyncLock for prompt requests - constructor() { - super(); - } - /** * Check whether the bot is logged in, settings are correct, etc. * @returns {boolean} - true if the bot is available, false otherwise. diff --git a/src/bots/QianWenBot.js b/src/bots/QianWenBot.js index 815f1ac554..c76728f5f8 100644 --- a/src/bots/QianWenBot.js +++ b/src/bots/QianWenBot.js @@ -19,10 +19,6 @@ export default class QianWenBot extends Bot { static _loginUrl = "https://qianwen.aliyun.com/"; static _lock = new AsyncLock(); // AsyncLock for prompt requests - constructor() { - super(); - } - getRequestHeaders() { return { "x-xsrf-token": store.state.qianWen?.xsrfToken, diff --git a/src/bots/Qihoo360AIBrainBot.js b/src/bots/Qihoo360AIBrainBot.js index eb4891e32f..b710ff1b20 100644 --- a/src/bots/Qihoo360AIBrainBot.js +++ b/src/bots/Qihoo360AIBrainBot.js @@ -8,10 +8,6 @@ export default class Qihoo360AIBrainBot extends Bot { static _logoFilename = "360-ai-brain-logo.png"; static _loginUrl = "https://chat.360.com/"; - constructor() { - super(); - } - async _checkAvailability() { let available = false; diff --git a/src/bots/SkyWorkBot.js b/src/bots/SkyWorkBot.js index fef82dbb4a..c299cf0cab 100644 --- a/src/bots/SkyWorkBot.js +++ b/src/bots/SkyWorkBot.js @@ -14,10 +14,6 @@ export default class SkyWorkBot extends Bot { currentPrompt = ""; // Used by createChatContext() only - constructor() { - super(); - } - getAuthHeaders() { return { headers: { diff --git a/src/bots/SparkBot.js b/src/bots/SparkBot.js index 39baba07f8..fb6d476bea 100644 --- a/src/bots/SparkBot.js +++ b/src/bots/SparkBot.js @@ -12,10 +12,6 @@ export default class SparkBot extends Bot { static _loginUrl = "https://xinghuo.xfyun.cn/"; static _lock = new AsyncLock(); // All Spark bots share the same lock - constructor() { - super(); - } - async _checkAvailability() { let available = false; try { diff --git a/src/bots/TemplateBot.js b/src/bots/TemplateBot.js index 5545f1dd3c..4237477db0 100644 --- a/src/bots/TemplateBot.js +++ b/src/bots/TemplateBot.js @@ -8,10 +8,6 @@ export default class YourAIBot extends Bot { static _loginUrl = "https://example.com/"; static _lock = new AsyncLock(); // AsyncLock for prompt requests - constructor() { - super(); - } - /** * Check whether the bot is logged in, settings are correct, etc. * @returns {boolean} - true if the bot is available, false otherwise. diff --git a/src/bots/YouChatBot.js b/src/bots/YouChatBot.js index 4befdf0bac..a780ce5602 100644 --- a/src/bots/YouChatBot.js +++ b/src/bots/YouChatBot.js @@ -11,10 +11,6 @@ export default class YouChatBot extends Bot { static _loginUrl = "https://you.com/"; static _lock = new AsyncLock(); // AsyncLock for prompt requests - constructor() { - super(); - } - /** * Check whether the bot is logged in, settings are correct, etc. * @returns {boolean} - true if the bot is available, false otherwise. diff --git a/src/bots/anthropic/ClaudeAPI20Bot.js b/src/bots/anthropic/ClaudeAPI20Bot.js index 03ed2046bd..3563ffc9d3 100644 --- a/src/bots/anthropic/ClaudeAPI20Bot.js +++ b/src/bots/anthropic/ClaudeAPI20Bot.js @@ -4,7 +4,4 @@ export default class ClaudeAPI20Bot extends ClaudeAPIBot { static _className = "ClaudeAPI20Bot"; static _logoFilename = "claudeapi-20-logo.png"; static _model = "claude-2.0"; - constructor() { - super(); - } } diff --git a/src/bots/anthropic/ClaudeAPI21Bot.js b/src/bots/anthropic/ClaudeAPI21Bot.js index 34544fa7a3..036d6d8209 100644 --- a/src/bots/anthropic/ClaudeAPI21Bot.js +++ b/src/bots/anthropic/ClaudeAPI21Bot.js @@ -4,7 +4,4 @@ export default class ClaudeAPI21Bot extends ClaudeAPIBot { static _className = "ClaudeAPI21Bot"; static _logoFilename = "claudeapi-21-logo.png"; static _model = "claude-2.1"; - constructor() { - super(); - } } diff --git a/src/bots/anthropic/ClaudeAPI37SonnetBot.js b/src/bots/anthropic/ClaudeAPI37SonnetBot.js index 8d6b844078..3191225ccb 100644 --- a/src/bots/anthropic/ClaudeAPI37SonnetBot.js +++ b/src/bots/anthropic/ClaudeAPI37SonnetBot.js @@ -4,7 +4,4 @@ export default class ClaudeAPI37SonnetBot extends ClaudeAPIBot { static _className = "ClaudeAPI37SonnetBot"; static _logoFilename = "claudeapi-37-sonnet-logo.png"; static _model = "claude-3-7-sonnet-latest"; - constructor() { - super(); - } } diff --git a/src/bots/anthropic/ClaudeAPIBot.js b/src/bots/anthropic/ClaudeAPIBot.js index 9fbf17ecae..763f1be956 100644 --- a/src/bots/anthropic/ClaudeAPIBot.js +++ b/src/bots/anthropic/ClaudeAPIBot.js @@ -6,10 +6,6 @@ export default class ClaudeAPIBot extends LangChainBot { static _brandId = "claudeApi"; static _className = "ClaudeAPIBot"; - constructor() { - super(); - } - async _checkAvailability() { let available = false; diff --git a/src/bots/anthropic/ClaudeAPIHaikuBot.js b/src/bots/anthropic/ClaudeAPIHaikuBot.js index 2bca9b3885..78dcf8fe9c 100644 --- a/src/bots/anthropic/ClaudeAPIHaikuBot.js +++ b/src/bots/anthropic/ClaudeAPIHaikuBot.js @@ -4,7 +4,4 @@ export default class ClaudeAPIHaikuBot extends ClaudeAPIBot { static _className = "ClaudeAPIHaikuBot"; static _logoFilename = "claudeapi-haiku-logo.png"; static _model = "claude-3-5-haiku-latest"; - constructor() { - super(); - } } diff --git a/src/bots/anthropic/ClaudeAPIOpusBot.js b/src/bots/anthropic/ClaudeAPIOpusBot.js index 8c5b74cfba..0d198f4ce6 100644 --- a/src/bots/anthropic/ClaudeAPIOpusBot.js +++ b/src/bots/anthropic/ClaudeAPIOpusBot.js @@ -4,7 +4,4 @@ export default class ClaudeAPIOpusBot extends ClaudeAPIBot { static _className = "ClaudeAPIOpusBot"; static _logoFilename = "claudeapi-opus-logo.png"; static _model = "claude-3-opus-20240229"; - constructor() { - super(); - } } diff --git a/src/bots/anthropic/ClaudeAPISonnetBot.js b/src/bots/anthropic/ClaudeAPISonnetBot.js index d204d743c7..26fc5a8a48 100644 --- a/src/bots/anthropic/ClaudeAPISonnetBot.js +++ b/src/bots/anthropic/ClaudeAPISonnetBot.js @@ -4,7 +4,4 @@ export default class ClaudeAPISonnetBot extends ClaudeAPIBot { static _className = "ClaudeAPISonnetBot"; static _logoFilename = "claudeapi-sonnet-logo.png"; static _model = "claude-3-5-sonnet-latest"; - constructor() { - super(); - } } diff --git a/src/bots/baidu/ERNIEBot.js b/src/bots/baidu/ERNIEBot.js index 1f92502f48..cf4dc3f41b 100644 --- a/src/bots/baidu/ERNIEBot.js +++ b/src/bots/baidu/ERNIEBot.js @@ -7,10 +7,6 @@ export default class ERNIEBot extends Bot { static _logoFilename = "ernie-logo.png"; // Place it in public/bots/ static _loginUrl = "https://yiyan.baidu.com/"; - constructor() { - super(); - } - async _checkAvailability() { let available = false; diff --git a/src/bots/baidu/WenxinQianfan4Bot.js b/src/bots/baidu/WenxinQianfan4Bot.js index 1a40655f11..c00342b2e9 100644 --- a/src/bots/baidu/WenxinQianfan4Bot.js +++ b/src/bots/baidu/WenxinQianfan4Bot.js @@ -6,8 +6,4 @@ export default class WenxinQianfan4Bot extends WenxinQianfanBot { static _logoFilename = "wenxin-qianfan-4-logo.png"; // Place it in public/bots/ static _model = "ERNIE-Bot-4"; // Model name static _lock = new AsyncLock(); - - constructor() { - super(); - } } diff --git a/src/bots/baidu/WenxinQianfanBot.js b/src/bots/baidu/WenxinQianfanBot.js index b65d9e5141..9278f41c7e 100644 --- a/src/bots/baidu/WenxinQianfanBot.js +++ b/src/bots/baidu/WenxinQianfanBot.js @@ -10,10 +10,6 @@ export default class WenxinQianfanBot extends LangChainBot { static _model = "ERNIE-Bot"; // Model name static _lock = new AsyncLock(); - constructor() { - super(); - } - async _checkAvailability() { let available = false; const { apiKey, secretKey } = store.state.wenxinQianfan; diff --git a/src/bots/baidu/WenxinQianfanTurboBot.js b/src/bots/baidu/WenxinQianfanTurboBot.js index 4fff067e17..c2cc5a13f5 100644 --- a/src/bots/baidu/WenxinQianfanTurboBot.js +++ b/src/bots/baidu/WenxinQianfanTurboBot.js @@ -6,8 +6,4 @@ export default class WenxinQianfanTurboBot extends WenxinQianfanBot { static _logoFilename = "wenxin-qianfan-turbo-logo.png"; // Place it in public/bots/ static _model = "ERNIE-Bot-turbo"; // Model name static _lock = new AsyncLock(); - - constructor() { - super(); - } } diff --git a/src/bots/cohere/CohereAPIAya23Bot.js b/src/bots/cohere/CohereAPIAya23Bot.js index e4b53c126b..a21e1dbf1f 100644 --- a/src/bots/cohere/CohereAPIAya23Bot.js +++ b/src/bots/cohere/CohereAPIAya23Bot.js @@ -4,7 +4,4 @@ export default class CohereAPIAya23Bot extends CohereAPIBot { static _className = "CohereAPIAya23Bot"; static _logoFilename = "cohere-logo.png"; static _model = "c4ai-aya-23"; - constructor() { - super(); - } } diff --git a/src/bots/cohere/CohereAPIBot.js b/src/bots/cohere/CohereAPIBot.js index fb454d3455..b2b05bf202 100644 --- a/src/bots/cohere/CohereAPIBot.js +++ b/src/bots/cohere/CohereAPIBot.js @@ -6,10 +6,6 @@ export default class CohereAPIBot extends LangChainBot { static _brandId = "cohereApi"; static _className = "CohereAPIBot"; - constructor() { - super(); - } - async _checkAvailability() { let available = false; diff --git a/src/bots/cohere/CohereAPICommandBot.js b/src/bots/cohere/CohereAPICommandBot.js index 72d47502e8..b27c2ced2a 100644 --- a/src/bots/cohere/CohereAPICommandBot.js +++ b/src/bots/cohere/CohereAPICommandBot.js @@ -4,7 +4,4 @@ export default class CohereAPICommandBot extends CohereAPIBot { static _className = "CohereAPICommandBot"; static _logoFilename = "cohere-logo.png"; static _model = "command"; - constructor() { - super(); - } } diff --git a/src/bots/cohere/CohereAPICommandLightBot.js b/src/bots/cohere/CohereAPICommandLightBot.js index fada955f77..dc0ad6081a 100644 --- a/src/bots/cohere/CohereAPICommandLightBot.js +++ b/src/bots/cohere/CohereAPICommandLightBot.js @@ -4,7 +4,4 @@ export default class CohereAPICommandLightBot extends CohereAPIBot { static _className = "CohereAPICommandLightBot"; static _logoFilename = "cohere-logo.png"; static _model = "command-light"; - constructor() { - super(); - } } diff --git a/src/bots/cohere/CohereAPICommandRBot.js b/src/bots/cohere/CohereAPICommandRBot.js index 90dbb0fb2a..f4acc04148 100644 --- a/src/bots/cohere/CohereAPICommandRBot.js +++ b/src/bots/cohere/CohereAPICommandRBot.js @@ -4,7 +4,4 @@ export default class CohereAPICommandRBot extends CohereAPIBot { static _className = "CohereAPICommandRBot"; static _logoFilename = "cohere-logo.png"; static _model = "command-r"; - constructor() { - super(); - } } diff --git a/src/bots/cohere/CohereAPICommandRPlusBot.js b/src/bots/cohere/CohereAPICommandRPlusBot.js index c940296508..32e8624105 100644 --- a/src/bots/cohere/CohereAPICommandRPlusBot.js +++ b/src/bots/cohere/CohereAPICommandRPlusBot.js @@ -4,7 +4,4 @@ export default class CohereAPICommandRPlusBot extends CohereAPIBot { static _className = "CohereAPICommandRPlusBot"; static _logoFilename = "cohere-logo.png"; static _model = "command-r-plus"; - constructor() { - super(); - } } diff --git a/src/bots/google/BardBot.js b/src/bots/google/BardBot.js index 57ac5014cc..41e670a29c 100644 --- a/src/bots/google/BardBot.js +++ b/src/bots/google/BardBot.js @@ -149,10 +149,6 @@ export default class BardBot extends Bot { "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) chatall/1.29.40 Chrome/114.0.5735.134 Safari/537.36"; static _lock = new AsyncLock(); - constructor() { - super(); - } - async _checkAvailability() { const context = await this.getChatContext(); let available = false; diff --git a/src/bots/google/Gemini15FlashAPIBot.js b/src/bots/google/Gemini15FlashAPIBot.js index 799d4f50f1..d62472a34e 100644 --- a/src/bots/google/Gemini15FlashAPIBot.js +++ b/src/bots/google/Gemini15FlashAPIBot.js @@ -4,8 +4,4 @@ export default class Gemini15FlashAPIBot extends GeminiAPIBot { static _className = "Gemini15FlashAPIBot"; static _logoFilename = "gemini-1.5-flash-logo.png"; static _model = "gemini-1.5-flash-latest"; - - constructor() { - super(); - } } diff --git a/src/bots/google/Gemini15ProAPIBot.js b/src/bots/google/Gemini15ProAPIBot.js index 149d2994e1..191752e8e1 100644 --- a/src/bots/google/Gemini15ProAPIBot.js +++ b/src/bots/google/Gemini15ProAPIBot.js @@ -4,8 +4,4 @@ export default class Gemini15ProAPIBot extends GeminiAPIBot { static _className = "Gemini15ProAPIBot"; static _logoFilename = "gemini-1.5-logo.png"; // Place it in public/bots/ static _model = "gemini-1.5-pro-latest"; - - constructor() { - super(); - } } diff --git a/src/bots/google/Gemini20FlashAPIBot.js b/src/bots/google/Gemini20FlashAPIBot.js index 004246019b..8298a3a4fb 100644 --- a/src/bots/google/Gemini20FlashAPIBot.js +++ b/src/bots/google/Gemini20FlashAPIBot.js @@ -4,8 +4,4 @@ export default class Gemini20FlashAPIBot extends GeminiAPIBot { static _className = "Gemini20FlashAPIBot"; static _logoFilename = "gemini-2.0-flash-logo.png"; static _model = "gemini-2.0-flash-001"; - - constructor() { - super(); - } } diff --git a/src/bots/google/Gemini20FlashLiteAPIBot.js b/src/bots/google/Gemini20FlashLiteAPIBot.js index cc359034fc..a434975d65 100644 --- a/src/bots/google/Gemini20FlashLiteAPIBot.js +++ b/src/bots/google/Gemini20FlashLiteAPIBot.js @@ -4,8 +4,4 @@ export default class Gemini20FlashLiteAPIBot extends GeminiAPIBot { static _className = "Gemini20FlashLiteAPIBot"; static _logoFilename = "gemini-2.0-flash-lite-logo.png"; static _model = "gemini-2.0-flash-lite"; - - constructor() { - super(); - } } diff --git a/src/bots/google/GeminiAPIBot.js b/src/bots/google/GeminiAPIBot.js index d7a4db667a..64c4d7cf13 100644 --- a/src/bots/google/GeminiAPIBot.js +++ b/src/bots/google/GeminiAPIBot.js @@ -8,10 +8,6 @@ export default class GeminiAPIBot extends LangChainBot { static _logoFilename = "gemini-1.0-logo.png"; // Place it in public/bots/ static _model = "gemini-pro"; - constructor() { - super(); - } - async _checkAvailability() { let available = false; diff --git a/src/bots/google/GeminiAdvBot.js b/src/bots/google/GeminiAdvBot.js index 93aba4d92d..d2ea67e27e 100644 --- a/src/bots/google/GeminiAdvBot.js +++ b/src/bots/google/GeminiAdvBot.js @@ -5,8 +5,4 @@ export default class GeminiAdvBot extends BardBot { static _className = "GeminiAdvBot"; // Class name of the bot static _model = "gemini-ultra"; // gemini-pro or gemini-ultra static _logoFilename = "gemini-chat-adv-logo.svg"; // Place it in public/bots/ - - constructor() { - super(); - } } diff --git a/src/bots/groq/Gemma29bGroqAPIBot.js b/src/bots/groq/Gemma29bGroqAPIBot.js index beff135867..0999fe4640 100644 --- a/src/bots/groq/Gemma29bGroqAPIBot.js +++ b/src/bots/groq/Gemma29bGroqAPIBot.js @@ -4,7 +4,4 @@ export default class Gemma29bGroqAPIBot extends GroqAPIBot { static _className = "Gemma29bGroqAPIBot"; static _logoFilename = "gemma2-9b-it-groq-logo.png"; static _model = "gemma2-9b-it"; - constructor() { - super(); - } } diff --git a/src/bots/groq/Gemma7bGroqAPIBot.js b/src/bots/groq/Gemma7bGroqAPIBot.js index fe4ae799ed..f398f2570e 100644 --- a/src/bots/groq/Gemma7bGroqAPIBot.js +++ b/src/bots/groq/Gemma7bGroqAPIBot.js @@ -4,7 +4,4 @@ export default class Gemma7bGroqAPIBot extends GroqAPIBot { static _className = "Gemma7bGroqAPIBot"; static _logoFilename = "gemma-7b-it-groq-logo.png"; static _model = "gemma-7b-it"; - constructor() { - super(); - } } diff --git a/src/bots/groq/GroqAPIBot.js b/src/bots/groq/GroqAPIBot.js index fa25c1f6e7..3bfa1a1b35 100644 --- a/src/bots/groq/GroqAPIBot.js +++ b/src/bots/groq/GroqAPIBot.js @@ -6,10 +6,6 @@ export default class GroqAPIBot extends LangChainBot { static _brandId = "groqApi"; static _className = "GroqAPIBot"; - constructor() { - super(); - } - async _checkAvailability() { let available = false; diff --git a/src/bots/groq/Llama370bGroqAPIBot.js b/src/bots/groq/Llama370bGroqAPIBot.js index c084d615b1..ed4146cfeb 100644 --- a/src/bots/groq/Llama370bGroqAPIBot.js +++ b/src/bots/groq/Llama370bGroqAPIBot.js @@ -4,7 +4,4 @@ export default class Llama370bGroqAPIBot extends GroqAPIBot { static _className = "Llama370bGroqAPIBot"; static _logoFilename = "llama-3-70b-groq-logo.png"; static _model = "llama3-70b-8192"; - constructor() { - super(); - } } diff --git a/src/bots/groq/Llama38bGroqAPIBot.js b/src/bots/groq/Llama38bGroqAPIBot.js index a0a4044e1b..cd115d432d 100644 --- a/src/bots/groq/Llama38bGroqAPIBot.js +++ b/src/bots/groq/Llama38bGroqAPIBot.js @@ -4,7 +4,4 @@ export default class Llama38bGroqAPIBot extends GroqAPIBot { static _className = "Llama38bGroqAPIBot"; static _logoFilename = "llama-3-8b-groq-logo.png"; static _model = "llama3-8b-8192"; - constructor() { - super(); - } } diff --git a/src/bots/groq/Llama4MaverickGroqAPIBot.js b/src/bots/groq/Llama4MaverickGroqAPIBot.js index 02bd44140b..6a572738ca 100644 --- a/src/bots/groq/Llama4MaverickGroqAPIBot.js +++ b/src/bots/groq/Llama4MaverickGroqAPIBot.js @@ -4,7 +4,4 @@ export default class Llama4MaverickGroqAPIBot extends GroqAPIBot { static _className = "Llama4MaverickGroqAPIBot"; static _logoFilename = "llama-4-maverick-groq-logo.png"; static _model = "meta-llama/llama-4-maverick-17b-128e-instruct"; - constructor() { - super(); - } } diff --git a/src/bots/groq/Llama4ScoutGroqAPIBot.js b/src/bots/groq/Llama4ScoutGroqAPIBot.js index 6437d03db2..6992c54eee 100644 --- a/src/bots/groq/Llama4ScoutGroqAPIBot.js +++ b/src/bots/groq/Llama4ScoutGroqAPIBot.js @@ -4,7 +4,4 @@ export default class Llama4ScoutGroqAPIBot extends GroqAPIBot { static _className = "Llama4ScoutGroqAPIBot"; static _logoFilename = "llama-4-scout-groq-logo.png"; static _model = "meta-llama/llama-4-scout-17b-16e-instruct"; - constructor() { - super(); - } } diff --git a/src/bots/huggingface/GradioBot.js b/src/bots/huggingface/GradioBot.js index 3014ec5d3f..0035d53a05 100644 --- a/src/bots/huggingface/GradioBot.js +++ b/src/bots/huggingface/GradioBot.js @@ -13,10 +13,6 @@ export default class GradioBot extends Bot { config = {}; eventListeners = new Map(); - constructor() { - super(); - } - /** * Check whether the bot is logged in, settings are correct, etc. * @returns {boolean} - true if the bot is available, false otherwise. diff --git a/src/bots/huggingface/HuggingChatBot.js b/src/bots/huggingface/HuggingChatBot.js index cdd2815518..56c37ae907 100644 --- a/src/bots/huggingface/HuggingChatBot.js +++ b/src/bots/huggingface/HuggingChatBot.js @@ -12,10 +12,6 @@ export default class HuggingChatBot extends Bot { static _model = "OpenAssistant/oasst-sft-6-llama-30b-xor"; static _lock = new AsyncLock(); // AsyncLock for prompt requests - constructor() { - super(); - } - /** * Check whether the bot is logged in, settings are correct, etc. * @returns {boolean} - true if the bot is available, false otherwise. diff --git a/src/bots/lmsys/LMSYSBot.js b/src/bots/lmsys/LMSYSBot.js index 6f838cc785..bc29019349 100644 --- a/src/bots/lmsys/LMSYSBot.js +++ b/src/bots/lmsys/LMSYSBot.js @@ -14,10 +14,6 @@ export default class LMSYSBot extends GradioBot { static _fnIndexes = [41, 42]; // Indexes of the APIs to call in order. Sniffer it by devtools. _triggerId = 93; // From devtools - constructor() { - super(); - } - async _checkAvailability() { let available = await super._checkAvailability(); if (available) { diff --git a/src/bots/microsoft/AzureOpenAIAPIBot.js b/src/bots/microsoft/AzureOpenAIAPIBot.js index a803f3e5fd..7737195859 100644 --- a/src/bots/microsoft/AzureOpenAIAPIBot.js +++ b/src/bots/microsoft/AzureOpenAIAPIBot.js @@ -8,10 +8,6 @@ export default class AzureOpenAIAPIBot extends LangChainBot { static _logoFilename = "azure-openai-logo.png"; static _isDarkLogo = true; // The main color of logo is dark - constructor() { - super(); - } - async _checkAvailability() { let available = false; if ( diff --git a/src/bots/microsoft/BingChatBalancedBot.js b/src/bots/microsoft/BingChatBalancedBot.js index a84d88167c..c4a9fc92b7 100644 --- a/src/bots/microsoft/BingChatBalancedBot.js +++ b/src/bots/microsoft/BingChatBalancedBot.js @@ -26,8 +26,4 @@ export default class BingChatBalancedBot extends BingChatBot { "saharagenconv5", ]; static _tone = "Balanced"; - - constructor() { - super(); - } } diff --git a/src/bots/microsoft/BingChatBot.js b/src/bots/microsoft/BingChatBot.js index ede550b93a..91a7b61b63 100644 --- a/src/bots/microsoft/BingChatBot.js +++ b/src/bots/microsoft/BingChatBot.js @@ -13,10 +13,6 @@ export default class BingChatBot extends Bot { static _optionsSets = null; // Set by the subclass static _tone = ""; // Set by the subclass - constructor() { - super(); - } - async createChatContext() { const headers = { "x-ms-client-request-id": uuidv4(), diff --git a/src/bots/microsoft/BingChatCreativeBot.js b/src/bots/microsoft/BingChatCreativeBot.js index 4d14783652..a25aca0de2 100644 --- a/src/bots/microsoft/BingChatCreativeBot.js +++ b/src/bots/microsoft/BingChatCreativeBot.js @@ -29,8 +29,4 @@ export default class BingChatCreativeBot extends BingChatBot { "gencontentv3", ]; static _tone = "Creative"; - - constructor() { - super(); - } } diff --git a/src/bots/microsoft/BingChatPreciseBot.js b/src/bots/microsoft/BingChatPreciseBot.js index ee05cd946e..a237b28710 100644 --- a/src/bots/microsoft/BingChatPreciseBot.js +++ b/src/bots/microsoft/BingChatPreciseBot.js @@ -29,8 +29,4 @@ export default class BingChatPreciseBot extends BingChatBot { "enable_user_consent", ]; static _tone = "Precise"; - - constructor() { - super(); - } } diff --git a/src/bots/moonshot/KimiBot.js b/src/bots/moonshot/KimiBot.js index 1e8bc13a1e..0c0ede84c3 100644 --- a/src/bots/moonshot/KimiBot.js +++ b/src/bots/moonshot/KimiBot.js @@ -12,10 +12,6 @@ export default class KimiBot extends Bot { static _loginUrl = "https://kimi.moonshot.cn/"; static _lock = new AsyncLock(); // AsyncLock for prompt requests - constructor() { - super(); - } - getAuthHeader() { return { headers: { diff --git a/src/bots/openai/ChatGPT4Bot.js b/src/bots/openai/ChatGPT4Bot.js index 4acc65329f..f626cd4bc5 100644 --- a/src/bots/openai/ChatGPT4Bot.js +++ b/src/bots/openai/ChatGPT4Bot.js @@ -6,10 +6,6 @@ export default class ChatGPT4Bot extends ChatGPTBot { static _logoFilename = "chatgpt-4-logo.png"; // Place it in public/bots/ static _model = "gpt-4"; - constructor() { - super(); - } - async _checkAvailability() { let available = await super._checkAvailability(); diff --git a/src/bots/openai/OpenAIAPI35Bot.js b/src/bots/openai/OpenAIAPI35Bot.js index ba127985f8..53b29c1d24 100644 --- a/src/bots/openai/OpenAIAPI35Bot.js +++ b/src/bots/openai/OpenAIAPI35Bot.js @@ -5,8 +5,4 @@ export default class OpenAIAPI35Bot extends OpenAIAPIBot { static _logoFilename = "openai-35-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "gpt-3.5-turbo"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPI4128KBot.js b/src/bots/openai/OpenAIAPI4128KBot.js index ce61e69f3e..21b0078639 100644 --- a/src/bots/openai/OpenAIAPI4128KBot.js +++ b/src/bots/openai/OpenAIAPI4128KBot.js @@ -5,8 +5,4 @@ export default class OpenAIAPI4128KBot extends OpenAIAPIBot { static _logoFilename = "openai-4-128k-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "gpt-4-turbo"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPI41Bot.js b/src/bots/openai/OpenAIAPI41Bot.js index 987071f52f..31a381f43a 100644 --- a/src/bots/openai/OpenAIAPI41Bot.js +++ b/src/bots/openai/OpenAIAPI41Bot.js @@ -5,8 +5,4 @@ export default class OpenAIAPI41Bot extends OpenAIAPIBot { static _logoFilename = "openai-41-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "gpt-4.1"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPI41MiniBot.js b/src/bots/openai/OpenAIAPI41MiniBot.js index d99a0190fc..0d0da851da 100644 --- a/src/bots/openai/OpenAIAPI41MiniBot.js +++ b/src/bots/openai/OpenAIAPI41MiniBot.js @@ -5,8 +5,4 @@ export default class OpenAIAPI41MiniBot extends OpenAIAPIBot { static _logoFilename = "openai-41-mini-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "gpt-4.1-mini"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPI41NanoBot.js b/src/bots/openai/OpenAIAPI41NanoBot.js index 7a6873e0c5..b77c7510da 100644 --- a/src/bots/openai/OpenAIAPI41NanoBot.js +++ b/src/bots/openai/OpenAIAPI41NanoBot.js @@ -5,8 +5,4 @@ export default class OpenAIAPI41NanoBot extends OpenAIAPIBot { static _logoFilename = "openai-41-nano-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "gpt-4.1-nano"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPI45Bot.js b/src/bots/openai/OpenAIAPI45Bot.js index 2799e3ff34..cde76ddb39 100644 --- a/src/bots/openai/OpenAIAPI45Bot.js +++ b/src/bots/openai/OpenAIAPI45Bot.js @@ -5,8 +5,4 @@ export default class OpenAIAPI45Bot extends OpenAIAPIBot { static _logoFilename = "openai-45-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "gpt-4.5-preview"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPI4Bot.js b/src/bots/openai/OpenAIAPI4Bot.js index 404658a74a..704c50f28d 100644 --- a/src/bots/openai/OpenAIAPI4Bot.js +++ b/src/bots/openai/OpenAIAPI4Bot.js @@ -5,8 +5,4 @@ export default class OpenAIAPI4Bot extends OpenAIAPIBot { static _logoFilename = "openai-4-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "gpt-4"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPI4oBot.js b/src/bots/openai/OpenAIAPI4oBot.js index ef0ff2f00b..e20f911b51 100644 --- a/src/bots/openai/OpenAIAPI4oBot.js +++ b/src/bots/openai/OpenAIAPI4oBot.js @@ -5,8 +5,4 @@ export default class OpenAIAPI4oBot extends OpenAIAPIBot { static _logoFilename = "openai-4o-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "gpt-4o"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPI4oMiniBot.js b/src/bots/openai/OpenAIAPI4oMiniBot.js index 66cfa1d315..2183ba7bb8 100644 --- a/src/bots/openai/OpenAIAPI4oMiniBot.js +++ b/src/bots/openai/OpenAIAPI4oMiniBot.js @@ -5,8 +5,4 @@ export default class OpenAIAPI4oMiniBot extends OpenAIAPIBot { static _logoFilename = "openai-4o-mini-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "gpt-4o-mini"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPIBot.js b/src/bots/openai/OpenAIAPIBot.js index 62b173899d..ad7c2e4fb4 100644 --- a/src/bots/openai/OpenAIAPIBot.js +++ b/src/bots/openai/OpenAIAPIBot.js @@ -6,10 +6,6 @@ export default class OpenAIAPIBot extends LangChainBot { static _brandId = "openaiApi"; static _className = "OpenAIAPIBot"; - constructor() { - super(); - } - async _checkAvailability() { let available = false; diff --git a/src/bots/openai/OpenAIAPIo1Bot.js b/src/bots/openai/OpenAIAPIo1Bot.js index ef31d744e9..25ee1c1373 100644 --- a/src/bots/openai/OpenAIAPIo1Bot.js +++ b/src/bots/openai/OpenAIAPIo1Bot.js @@ -5,8 +5,4 @@ export default class OpenAIAPIo1Bot extends OpenAIAPIBot { static _logoFilename = "openai-o1-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "o1"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPIo1MiniBot.js b/src/bots/openai/OpenAIAPIo1MiniBot.js index a865700a2d..66ccf7a816 100644 --- a/src/bots/openai/OpenAIAPIo1MiniBot.js +++ b/src/bots/openai/OpenAIAPIo1MiniBot.js @@ -5,8 +5,4 @@ export default class OpenAIAPIo1MiniBot extends OpenAIAPIBot { static _logoFilename = "openai-o1-mini-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "o1-mini"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPIo3Bot.js b/src/bots/openai/OpenAIAPIo3Bot.js index 60ae739198..1b2ff80e64 100644 --- a/src/bots/openai/OpenAIAPIo3Bot.js +++ b/src/bots/openai/OpenAIAPIo3Bot.js @@ -5,8 +5,4 @@ export default class OpenAIAPIo3Bot extends OpenAIAPIBot { static _logoFilename = "openai-o3-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "o3"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPIo3MiniBot.js b/src/bots/openai/OpenAIAPIo3MiniBot.js index f848137b8c..eb8272eaf8 100644 --- a/src/bots/openai/OpenAIAPIo3MiniBot.js +++ b/src/bots/openai/OpenAIAPIo3MiniBot.js @@ -5,8 +5,4 @@ export default class OpenAIAPIo3MiniBot extends OpenAIAPIBot { static _logoFilename = "openai-o3-mini-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "o3-mini"; - - constructor() { - super(); - } } diff --git a/src/bots/openai/OpenAIAPIo4MiniBot.js b/src/bots/openai/OpenAIAPIo4MiniBot.js index bc56c79b34..c69aa5ee65 100644 --- a/src/bots/openai/OpenAIAPIo4MiniBot.js +++ b/src/bots/openai/OpenAIAPIo4MiniBot.js @@ -5,8 +5,4 @@ export default class OpenAIAPIo4MiniBot extends OpenAIAPIBot { static _logoFilename = "openai-o4-mini-logo.png"; // Place it in public/bots/ static _isDarkLogo = true; // The main color of logo is dark static _model = "o4-mini"; - - constructor() { - super(); - } } diff --git a/src/bots/poe/PoeBot.js b/src/bots/poe/PoeBot.js index 358bed728b..1e9930eb81 100644 --- a/src/bots/poe/PoeBot.js +++ b/src/bots/poe/PoeBot.js @@ -19,10 +19,6 @@ export default class PoeBot extends Bot { lastMessageId: 0, }; - constructor() { - super(); - } - async gqlPost(queryName, variables) { const { settings } = this.context; const formkey = store.state.poe.formkey; diff --git a/src/bots/xai/Grok2APIBot.js b/src/bots/xai/Grok2APIBot.js index 9385b97797..6b1d19518c 100644 --- a/src/bots/xai/Grok2APIBot.js +++ b/src/bots/xai/Grok2APIBot.js @@ -4,7 +4,4 @@ export default class Grok2APIBot extends xAIAPIBot { static _className = "Grok2APIBot"; static _logoFilename = "grok-2-logo.png"; static _model = "grok-2-latest"; - constructor() { - super(); - } } diff --git a/src/bots/xai/Grok3APIBot.js b/src/bots/xai/Grok3APIBot.js index 6c071b8e38..16430823e9 100644 --- a/src/bots/xai/Grok3APIBot.js +++ b/src/bots/xai/Grok3APIBot.js @@ -4,7 +4,4 @@ export default class Grok3APIBot extends xAIAPIBot { static _className = "Grok3APIBot"; static _logoFilename = "grok-3-logo.png"; static _model = "grok-3"; - constructor() { - super(); - } } diff --git a/src/bots/xai/Grok3MiniAPIBot.js b/src/bots/xai/Grok3MiniAPIBot.js index 59dd3c16e9..1a003b34c5 100644 --- a/src/bots/xai/Grok3MiniAPIBot.js +++ b/src/bots/xai/Grok3MiniAPIBot.js @@ -4,7 +4,4 @@ export default class Grok3MiniAPIBot extends xAIAPIBot { static _className = "Grok3MiniAPIBot"; static _logoFilename = "grok-3-mini-logo.png"; static _model = "grok-3-mini"; - constructor() { - super(); - } } diff --git a/src/bots/xai/xAIAPIBot.js b/src/bots/xai/xAIAPIBot.js index 3858becbc5..01ecbb0ec6 100644 --- a/src/bots/xai/xAIAPIBot.js +++ b/src/bots/xai/xAIAPIBot.js @@ -6,10 +6,6 @@ export default class xAIAPIBot extends LangChainBot { static _brandId = "xaiApi"; static _className = "xAIAPIBot"; - constructor() { - super(); - } - async _checkAvailability() { let available = false; diff --git a/src/bots/zhipu/ChatGLM4Bot.js b/src/bots/zhipu/ChatGLM4Bot.js index 45a05686fb..5595d02ae8 100644 --- a/src/bots/zhipu/ChatGLM4Bot.js +++ b/src/bots/zhipu/ChatGLM4Bot.js @@ -7,10 +7,6 @@ export default class ChatGLM4Bot extends ChatGLMBot { static _logoFilename = "chatglm-4-logo.png"; // Place it in public/bots/ static _model = "GLM-4"; // Model name - constructor() { - super(); - } - /** * Send a prompt to the bot and call onResponse(response, callbackParam) * when the response is ready. diff --git a/src/bots/zhipu/ChatGLMBot.js b/src/bots/zhipu/ChatGLMBot.js index 79c9477c6f..27418e6076 100644 --- a/src/bots/zhipu/ChatGLMBot.js +++ b/src/bots/zhipu/ChatGLMBot.js @@ -13,10 +13,6 @@ export default class ChatGLMBot extends Bot { static _model = "GLM-3"; // Model name static _lock = new AsyncLock(); // AsyncLock for prompt requests - constructor() { - super(); - } - getAuthHeader() { return { headers: {