Skip to content

Commit 81d606e

Browse files
authored
Merge pull request #5 from sscargal/site-updates
Site updates
2 parents 014abcd + 1534e6d commit 81d606e

File tree

7 files changed

+247
-109
lines changed

7 files changed

+247
-109
lines changed

data/faq.yaml

Lines changed: 21 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,29 @@
1-
- question: What is MemMachine?
2-
answer: MemMachine is an open-source, multi-layered memory system for AI agents. It allows developers to give their agents Short-Term, Long-Term, and Personalization memory, enabling them to have stateful, context-aware conversations and recall user-specific facts over time.
1+
- question: What is MemMachine, and what makes it unique?
2+
answer: MemMachine is an open-source, multi-layered memory system for AI agents. It allows you to equip your agents with Short-Term, Long-Term, and Personalization memory. While many AI models offer some form of built-in memory, MemMachine's system is model-agnostic, meaning it can support multiple AI models simultaneously, including specialized models hosted in a private cloud or on-premises data center. This capability enables organizations to maintain full control of their data and work with various models without vendor lock-in.
33

4-
- question: How is this different from standard LangChain or LangGraph memory?
5-
answer: While libraries like LangChain provide excellent memory components, MemMachine focuses on abstracting the complexity of managing different memory types and provides a dedicated Personalization layer that can be easily integrated into any agent framework, including LangChain and LangGraph.
6-
7-
- question: Is the Open Source version ready for production use?
8-
answer: Yes, the open-source version is fully-featured and can be deployed in production environments. It is ideal for developers who are comfortable managing their own infrastructure. Our Pro and Enterprise tiers offer managed hosting, dedicated support, and advanced features for teams that require a higher level of service and security.
4+
- question: Is MemMachine for developers or end users?
5+
answer: MemMachine is primarily designed for Agent developers and organizations building AI applications. It provides a flexible and scalable memory system that can be integrated into various AI models, allowing developers to enhance their applications with advanced memory capabilities.
96

107
- question: Why are these capabilities needed if they're becoming available by frontier labs like OpenAI?
118
answer: Because a frontier lab's memory service keeps the memory, and its memory service does not work with other models. Many organizations work with multiple models, including specialized models deployed in its private environment, including its VPC in the cloud and its own on-prem data center. They desire a memory system that can support all of these models.
129

10+
- question: How does MemMachine handle data privacy and security?
11+
answer: MemMachine is designed with security in mind. The open-source version can be deployed in your private cloud or on-premises environment, giving you full control over your data.
12+
1313
- question: Who is driving development of MemMachine?
14-
answer: MemVerge incubated the project to the current stage, and this project will be community-driven. MemVerge will continue to assign its engineering team to improve the memory system, and contributors of all backgrounds are welcome to join.
14+
answer: The project was initially incubated by MemVerge to its current state. The project is now community-driven, and we welcome contributors of all backgrounds. MemVerge will continue to assign its engineering team to improve the memory system and support community efforts.
1515

1616
- question: How can I get started with MemMachine?
17-
answer: You can get started by visiting our [documentation](https://docs.memmachine.ai)
17+
answer: You can get started by visiting our [documentation](https://docs.memmachine.ai)
18+
19+
- question: Where can I find the source code for MemMachine?
20+
answer: The source code for MemMachine is available on [GitHub](https://github.com/MemMachine/MemMachine)
21+
22+
- question: How can I contribute to the MemMachine project?
23+
answer: We welcome contributions from the community! You can contribute by reporting issues, suggesting features, or submitting pull requests on our [GitHub](https://github.com/MemMachine/MemMachine) repository.
24+
25+
- question: How do I get support for MemMachine?
26+
answer: You can get support through our community channels by joining our [Discord server](https://discord.gg/usydANvKqD) or filing an issue on our [GitHub](https://github.com/MemMachine/MemMachine) repository.
27+
28+
- question: Is there an Enterprise version of MemMachine or support available for MemMachine users?
29+
answer: An Enterprise version of MemMachine with additional features and dedicated support will be available soon.

themes/memmachine/assets/css/styles.css

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ body {
8383
line-height: 1.5;
8484
font-weight: 400;
8585
background: #211334 url(/img/bg.svg) center/cover no-repeat;
86-
color: var(--light-300);
86+
color: var(--light-500);
8787
scroll-behavior: smooth;
8888
}
8989
input:focus {
@@ -447,10 +447,19 @@ header nav ul li a:hover {
447447
display: flex;
448448
align-items: center;
449449
justify-content: center;
450+
background: var(--gradient-lavender-pink-peach);
451+
}
452+
.hero-chat-input button i {
453+
color: white; /* Ensure icons are white */
450454
}
451-
.hero-chat-input button svg {
455+
456+
.hero-chat-input button svg,
457+
.hero-chat-input button i {
452458
width: 24px;
453459
height: 24px;
460+
display: flex;
461+
align-items: center;
462+
justify-content: center;
454463
}
455464
.hero-brand p {
456465
margin-bottom: 32px;
@@ -462,7 +471,7 @@ header nav ul li a:hover {
462471
}
463472

464473
.hero-chat-list::-webkit-scrollbar {
465-
width: 4px;
474+
width: 8px;
466475
}
467476

468477
.hero-chat-list::-webkit-scrollbar-track {

themes/memmachine/assets/js/custom.js

Lines changed: 142 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -87,40 +87,45 @@ document.addEventListener("DOMContentLoaded", function () {
8787
});
8888
});
8989

90+
// Chat Widget
9091
const chatList = document.getElementById("chatList");
9192
const userInput = document.getElementById("userInput");
9293
const sendButton = document.getElementById("sendButton");
94+
const chatInputContainer = document.getElementById("chatInputContainer");
9395

9496
// Check if chatList exists before proceeding
9597
if (chatList) {
96-
const messages = [
98+
// Chat state to manage the conversation flow
99+
let chatState = 0;
100+
101+
// Pre-scripted messages for the chat flow
102+
const scriptedMessages = [
97103
{
98104
sender: "You",
99-
time: "1:17 PM",
100-
text: "What are your thoughts on the latest AI chip manufacturer earnings reports that came out this week?",
105+
text: "How can I manage user-specific data without retraining my model for every user?",
101106
},
102107
{
103108
sender: "MemMachine Agent",
104-
time: "1:17 PM",
105-
text: "The reports show strong growth, particularly in the data center segment. However, I recall you mentioned last month that you're looking to decrease your exposure to hardware manufacturers and focus more on AI software and platform companies. Do you want me to filter these insights based on that strategy?",
109+
text: "That's a key challenge for building personalized agents. MemMachine addresses this with its Personalization memory layer, which stores user-specific data independently of your core model. I recall you were building a financial advice agent for small businesses last month—this is a perfect use case for that.",
106110
},
107111
{
108112
sender: "You",
109-
time: "1:18 PM",
110-
text: "Wow, good memory. Yes, please. Focus on the implications for software companies.",
113+
text: "Wow, you remember that? That's exactly what I'm working on. How does that work under the hood?",
111114
},
112115
{
113116
sender: "MemMachine Agent",
114-
time: "1:18 PM",
115-
text: "Understood. The strong hardware sales signal a surge in demand for advanced AI models, which is a bullish indicator for AI platform companies that leverage this new hardware.",
117+
text: "The core of our memory system is designed to be model-agnostic, giving your agents stateful, context-aware conversations and the ability to recall user-specific facts over time. This is the foundation for building the next generation of AI solutions.",
118+
},
119+
{
120+
sender: "You",
121+
text: "Okay, that's exactly what I need.",
122+
},
123+
{
124+
sender: "MemMachine Agent",
125+
text: "You're welcome! Would you like to know how to get started with this kind of memory system? (Yes/No)",
116126
},
117127
];
118128

119-
// Function to add initial messages to the chat
120-
function loadInitialMessages() {
121-
messages.forEach((message) => addMessage(message));
122-
}
123-
124129
function addMessage(message) {
125130
const chatItem = document.createElement("div");
126131
chatItem.className = "hero-chat-item";
@@ -134,50 +139,148 @@ if (chatList) {
134139
</div>
135140
`;
136141
chatList.appendChild(chatItem);
137-
chatItem.classList.add("fade-in"); // Add fade-in class for animation
138-
chatList.scrollTop = chatList.scrollHeight; // Scroll to the bottom
142+
chatItem.classList.add("fade-in");
143+
chatList.scrollTop = chatList.scrollHeight;
139144
}
140-
141-
// Load initial messages on page load
142-
loadInitialMessages();
143-
144-
sendButton.addEventListener("click", () => {
145-
submitMessage();
146-
});
147-
148-
// Allow submitting message with Enter key
149-
userInput.addEventListener("keypress", (event) => {
150-
if (event.key === "Enter") {
151-
submitMessage();
145+
146+
// New function to load the entire conversation history
147+
function loadConversationHistory() {
148+
let delay = 0;
149+
for (let i = 0; i < scriptedMessages.length; i++) {
150+
setTimeout(() => {
151+
const currentTime = new Date().toLocaleTimeString([], {
152+
hour: "2-digit",
153+
minute: "2-digit",
154+
});
155+
addMessage({
156+
sender: scriptedMessages[i].sender,
157+
time: currentTime,
158+
text: scriptedMessages[i].text,
159+
});
160+
}, delay);
161+
delay += 500; // Reduced delay for a faster feel
152162
}
153-
});
163+
// Set the state to 1 after the initial conversation loads,
164+
// so the next message from the user is a response to the question.
165+
chatState = 1;
166+
}
154167

155168
function submitMessage() {
156-
const userMessage = userInput.value;
157-
if (userMessage) {
158-
const currentTime = new Date().toLocaleTimeString([], {
159-
hour: "2-digit",
160-
minute: "2-digit",
169+
const userMessage = userInput.value.trim().toLowerCase();
170+
const currentTime = new Date().toLocaleTimeString([], {
171+
hour: "2-digit",
172+
minute: "2-digit",
173+
});
174+
175+
// The chat widget is only active for the final response
176+
if (chatState === 1) {
177+
// Post the user's message
178+
addMessage({
179+
sender: "You",
180+
time: currentTime,
181+
text: userInput.value,
161182
});
183+
userInput.value = "";
184+
185+
const positiveResponses = ["yes", "y", "sure", "ok", "of course", "please"];
186+
const negativeResponses = ["no", "n", "nope", "nah"];
187+
const isPositive = positiveResponses.some(response => userMessage.includes(response));
188+
const isNegative = negativeResponses.some(response => userMessage.includes(response));
189+
190+
setTimeout(() => {
191+
if (isPositive) {
192+
addMessage({
193+
sender: "MemMachine Agent",
194+
time: currentTime,
195+
text: `Great! The best way to get started is with our comprehensive <a href="https://docs.memmachine.ai" target="_blank">documentation</a>. You can also <a href="https://discord.memmachine.ai" target="_blank">join our Discord server</a> to collaborate with other developers, or <a href="https://playground.memmachine.ai" target="_blank">try the Playground</a> to see a live demo.`,
196+
});
197+
} else if (isNegative) {
198+
addMessage({
199+
sender: "MemMachine Agent",
200+
time: currentTime,
201+
text: "No problem. If you change your mind, you can find our resources at any time in the navigation bar. We're here to help when you're ready!",
202+
});
203+
} else {
204+
addMessage({
205+
sender: "MemMachine Agent",
206+
time: currentTime,
207+
text: "I'm sorry, but I'm not a full-fledged chat bot (yet)! If you're looking for more information, you can find our resources at any time in the navigation bar. We're here to help when you're ready!",
208+
});
209+
}
210+
chatState = 2; // End of the conversation flow
211+
disableChatInput();
212+
addRestartButton();
213+
}, 500); // Reduced delay
214+
} else {
215+
// Default message for any interaction after the conversation is over
162216
addMessage({
163217
sender: "You",
164218
time: currentTime,
165-
text: userMessage,
219+
text: userInput.value,
166220
});
167-
userInput.value = ""; // Clear input
221+
userInput.value = "";
168222

169-
// Simulate the agent response
170223
setTimeout(() => {
171224
addMessage({
172225
sender: "MemMachine Agent",
173226
time: currentTime,
174-
text: "Free quote limit reached. Please upgrade for unlimited access.",
227+
text: "Thanks for visiting! Please use the links above to learn more about MemMachine."
175228
});
176-
}, 500); // Delay for agent response
229+
}, 500); // Reduced delay
230+
}
231+
}
232+
233+
function disableChatInput() {
234+
userInput.disabled = true;
235+
sendButton.style.display = "none";
236+
userInput.placeholder = "Chat is complete.";
237+
}
238+
239+
function addRestartButton() {
240+
const restartButton = document.createElement("button");
241+
restartButton.id = "restartButton";
242+
restartButton.className = "hero-chat-input-btn";
243+
restartButton.innerHTML = `
244+
<i class="fa-solid fa-rotate-right"></i>
245+
`;
246+
restartButton.addEventListener("click", () => {
247+
chatList.innerHTML = ""; // Clear the chat messages
248+
loadConversationHistory();
249+
enableChatInput();
250+
});
251+
// Append the restart button to the chat input container
252+
chatInputContainer.appendChild(restartButton);
253+
}
254+
255+
function enableChatInput() {
256+
userInput.disabled = false;
257+
sendButton.style.display = "block";
258+
userInput.placeholder = "Type your message";
259+
const restartButton = document.getElementById('restartButton');
260+
if (restartButton) {
261+
restartButton.remove();
177262
}
178263
}
264+
265+
sendButton.addEventListener("click", () => {
266+
submitMessage();
267+
});
268+
269+
userInput.addEventListener("keypress", (event) => {
270+
if (event.key === "Enter") {
271+
submitMessage();
272+
}
273+
});
274+
275+
// Start the conversation history when the page loads
276+
loadConversationHistory();
179277
}
180278

279+
280+
281+
282+
283+
181284
// Initialize Lenis for smooth scrolling
182285
const lenis = new Lenis();
183286

0 commit comments

Comments
 (0)