HuggingFace has developed Moon Bot, a Slack-native coding assistant that centralizes access to internal tools and data sources. The bot allows engineers to query Elasticsearch logs, MongoDB databases, and codebases directly from Slack threads, eliminating the need for context-switching. By leveraging HuggingFace's own infrastructure, Moon Bot provides a seamless experience for teams working within the company's ecosystem. The bot's ability to persist memory across sessions ensures continuity and efficiency in daily tasks. It also supports features such as opening GitHub PRs and retrieving metrics without requiring users to navigate multiple interfaces. This integration aims to enhance productivity by keeping all necessary tools and data accessible in one place. Source: huggingface
Moon Bot is built using the Pi coding agent SDK and runs in a Kubernetes pod with privileged internal network access. It utilizes HuggingFace Buckets as its persistent memory store, allowing sessions to be resumed after restarts or crashes. Each Slack thread gets its own independent Pi agent session, which includes a stateful conversation with the LLM and a full tool-call history. The bot can respond to mentions in channels or direct messages without requiring explicit triggers, ensuring it is always available for user interaction. This architecture enables Moon Bot to maintain context and provide accurate, up-to-date information across multiple threads and sessions. Source: huggingface
The architecture of Moon Bot includes three key files stored in a private HuggingFace Bucket: sessions/.jsonl, thread-map.json, and memory.json. These files help the bot reconnect to active threads and maintain a rolling log of interactions. The session files are append-only JSONL files that track user messages, tool calls, and results, enabling the bot to resume conversations after restarts. The memory.json file provides a history of the last 200 interactions, accessible to the LLM as a memory tool. This ensures that Moon Bot can reference past interactions to provide context-aware responses, enhancing its utility for engineering teams. Source: huggingface