Show HN: Antfly: Distributed, Multimodal Search and Memory and Graphs in Go

Introduction to Antfly

As a developer, I'm always on the lookout for innovative solutions that can simplify my workflow and improve the performance of my applications. Recently, I came across Antfly, a distributed document database and search engine written in Go that combines full-text, vector, and graph search. In this post, I'll dive into the features and capabilities of Antfly and explore how it can be used for distributed multimodal search and memory.

Why this matters

Antfly is designed to provide a single-binary deployment with native ML inference, eliminating the need for external API calls for vector search. This is a significant advantage, as it reduces the complexity and latency associated with external API calls. With Antfly, you can perform multimodal indexing on images, audio, and video, making it an ideal solution for applications that require advanced search capabilities.

Key Features of Antfly

Some of the key features of Antfly include:

  • Multimodal indexing: Support for indexing images, audio, and video
  • MongoDB-style in-place updates: Efficient updates and modifications to documents
  • Streaming RAG: Real-time graph updates and processing
  • Distributed systems: Multi-Raft setup built on etcd's library, backed by Pebble (CockroachDB's storage engine)
  • Single binary deployment: Easy to deploy and manage, with a single-process deployment option
  • Native ML inference: Built-in Termite service for ML inference, eliminating the need for external API calls

How to install and use Antfly

To get started with Antfly, you can use the antfly swarm command to deploy a single-process instance. This is ideal for local development and small deployments. As your application grows, you can scale out by adding nodes to your deployment. Antfly also ships with a Kubernetes operator and an MCP server for LLM tool use, making it easy to integrate with your existing infrastructure.

Distributed Systems and Architecture

Antfly's distributed system is built on a multi-Raft setup, with metadata and data shards getting their own Raft groups. This provides a high degree of fault tolerance and scalability, ensuring that your application remains available even in the event of node failures. The use of Pebble, CockroachDB's storage engine, provides a robust and reliable storage solution.

Native ML Inference with Termite

One of the most interesting features of Antfly is its native ML inference capability, provided by the built-in Termite service. Termite is designed to work with non-generative models, including embeddings, reranking, chunking, and text generation. This means that you can perform ML inference tasks without the need for external API calls, reducing latency and improving performance.

Licensing and Sustainability

Antfly is licensed under the Elastic License v2, which allows you to use, modify, and self-host the software, as well as build products on top of it. However, it does not allow you to offer Antfly itself as a managed service. This licensing model is designed to promote sustainability while still making the source code available to the community.

Code Example

To give you a better idea of how Antfly works, here's an example of how you might use the antfly command to deploy a single-process instance:

antfly swarm --config=/path/to/config.yaml

This command will deploy an Antfly instance with the specified configuration, including the number of nodes, storage engine, and ML inference settings.

Verdict

So, who is Antfly for? I believe that Antfly is an ideal solution for developers who need advanced search capabilities, including multimodal indexing and native ML inference. It's particularly well-suited for applications that require low-latency and high-throughput search, such as e-commerce platforms, social media networks, and content management systems.

What do you think about Antfly's approach to distributed search and ML inference? Do you have any experience with similar solutions, and how do you think Antfly compares? Share your thoughts and questions in the comments below!

🚀 Global, automated cloud infrastructure

Oracle Cloud is hard to get. I recommend Vultr for instant setup.

Get $100 in free server credit on Vultr →