Skip to content

Enhanced ChatGPT Clone: Features Agents, MCP, Skills, DeepSeek, Anthropic, AWS, OpenAI, Responses API, Azure, Groq, o1, GPT-5, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, Code Interpreter, langchain, DALL-E-3, OpenAPI Actions, Functions, Secure Multi-User Auth, Presets, open-source for self-hosting. Active

chore: unplug meilisearch, add leading option to throttle

Daniel Avilab0936fa32213
diff --git a/api/models/Conversation.js b/api/models/Conversation.js
index a2a4d2fa82..2b786c9726 100644
--- a/api/models/Conversation.js
+++ b/api/models/Conversation.js
@@ -55,12 +55,12 @@ const convoSchema = mongoose.Schema(
{ timestamps: true }
);
-convoSchema.plugin(mongoMeili, {
- host: process.env.MEILI_HOST,
- apiKey: process.env.MEILI_KEY,
- indexName: 'convos', // Will get created automatically if it doesn't exist already
- primaryKey: 'conversationId'
-});
+// convoSchema.plugin(mongoMeili, {
+// host: process.env.MEILI_HOST,
+// apiKey: process.env.MEILI_KEY,
+// indexName: 'convos', // Will get created automatically if it doesn't exist already
+// primaryKey: 'conversationId'
+// });
const Conversation =
mongoose.models.Conversation || mongoose.model('Conversation', convoSchema);
diff --git a/api/models/Message.js b/api/models/Message.js
index 70e82dfb73..288a03ee7e 100644
--- a/api/models/Message.js
+++ b/api/models/Message.js
@@ -55,12 +55,12 @@ const messageSchema = mongoose.Schema({
}
}, { timestamps: true });
-messageSchema.plugin(mongoMeili, {
- host: process.env.MEILI_HOST,
- apiKey: process.env.MEILI_KEY,
- indexName: 'messages', // Will get created automatically if it doesn't exist already
- primaryKey: 'messageId',
-});
+// messageSchema.plugin(mongoMeili, {
+// host: process.env.MEILI_HOST,
+// apiKey: process.env.MEILI_KEY,
+// indexName: 'messages', // Will get created automatically if it doesn't exist already
+// primaryKey: 'messageId',
+// });
const Message = mongoose.models.Message || mongoose.model('Message', messageSchema);
diff --git a/client/src/components/Messages/index.jsx b/client/src/components/Messages/index.jsx
index f734e58cdf..e38daa679a 100644
--- a/client/src/components/Messages/index.jsx
+++ b/client/src/components/Messages/index.jsx
@@ -39,7 +39,7 @@ export default function Messages({ messages, messageTree }) {
console.log('scrollToBottom');
messagesEndRef.current?.scrollIntoView({ behavior: 'smooth' });
setShowScrollButton(false);
- }, 750), [messagesEndRef]);
+ }, 750, { leading: true }), [messagesEndRef]);
const handleScroll = () => {
const { scrollTop, scrollHeight, clientHeight } = scrollableRef.current;
diff --git a/client/src/components/Nav/NavLinks.jsx b/client/src/components/Nav/NavLinks.jsx
index 010256de78..0adb3e739a 100644
--- a/client/src/components/Nav/NavLinks.jsx
+++ b/client/src/components/Nav/NavLinks.jsx
@@ -9,7 +9,7 @@ import Logout from './Logout';
export default function NavLinks({ fetch, onSearchSuccess, clearSearch }) {
return (
<>
- <SearchBar fetch={fetch} onSuccess={onSearchSuccess} clearSearch={clearSearch}/>
+ {/* <SearchBar fetch={fetch} onSuccess={onSearchSuccess} clearSearch={clearSearch}/> */}
<ClearConvos />
<DarkMode />
<Logout />