Skip to main content

Flumes – unified memory infrastructure SDK for AI agents (Python)

Project description

Flumes AI – Python SDK

PyPI License Open In Colab

Flumes AI is a unified memory infrastructure for LLM-powered agents and applications. This SDK lets any Python or LangChain stack plug into the Flumes Memory API in three lines of code.

👉 Learn more at https://www.flumes.ai/ – full docs at https://docs.flumes.ai/.


🚀 Installation

pip install flumes-ai  # includes the OpenAI client by default

Python ≥3.8. No system packages or C-extensions required.


🔑 Configuration

Environment variables (preferred):

Service Variable Example
Flumes FLUMES_API_KEY export FLUMES_API_KEY=sk_live_…
OpenAI OPENAI_API_KEY export OPENAI_API_KEY=sk-…

You can also pass api_key="…" directly to MemoryClient.


⚡ Quick-start (entity-first; no summarize route)

from flumes import MemoryClient

client = MemoryClient(api_key="YOUR_KEY", agent_id="travel-bot")
u = client.for_entity("user_001", namespace="prod")

res = u.add("Planning a trip to France. Like wine, cheese and calm places.")
print(res.get("context", {}).get("summary"))

hits = u.search("trip recommendations", top_k=24)
print(len(hits.get("matches", [])))

Behind the scenes Flumes:

  1. Adds the fact to long-term memory (summarised + deduplicated).
  2. Retrieves relevant memories with semantic search.
  3. Injects them into the LLM prompt (OpenAI by default).
  4. Stores the assistant response for future context.

🛠️ Advanced (thin pass-through)

from flumes import MemoryClient

mc = MemoryClient(api_key="YOUR_KEY")
mc.search("wine", entity_id="user_42")
mc.get_all(entity_id="user_42", limit=50)

All endpoints map 1-to-1 with the REST reference.


✨ Key features

  • Semantic search & vector similarity out-of-the-box.
  • Automatic summarisation & deduplication (infer=True by default).
  • Pluggable LLM backend – OpenAI today, Claude/Mistral coming.
  • Structured logging – JSON events (memory.add.request, llm.called) for easy observability.
  • Timeout & retry helpers – avoid first-call latency issues.

🗺 Roadmap

  • Async transport with httpx.AsyncClient
  • CLI: flumes chat, flumes memories list
  • Policy plug-ins: custom summariser / retention strategies
  • Local in-process transport (flumes-core) for offline testing

🤝 Contributing

  1. Fork the repo and create a feature branch.
  2. make install && make test
  3. Open a PR – we ❤️ community help!

Please see LICENSE (MIT).


Made with 🧠 by the Flumes team – join us on the journey to give every agent a memory!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

flumes_ai-0.2.1.tar.gz (118.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

flumes_ai-0.2.1-py3-none-any.whl (16.0 kB view details)

Uploaded Python 3

File details

Details for the file flumes_ai-0.2.1.tar.gz.

File metadata

  • Download URL: flumes_ai-0.2.1.tar.gz
  • Upload date:
  • Size: 118.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.6

File hashes

Hashes for flumes_ai-0.2.1.tar.gz
Algorithm Hash digest
SHA256 e6a3f2d65b92a05962dd874112e5d3d053c36578c10dabd42fece74139ace297
MD5 270ab87218c3b73a0b7f404b2aefa7ad
BLAKE2b-256 ce9f5f8e75ff10fce104a9de1f918568987dd28970e0de53a9430ed44f5f7d72

See more details on using hashes here.

File details

Details for the file flumes_ai-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: flumes_ai-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 16.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.6

File hashes

Hashes for flumes_ai-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 86def993f59f15822cecc91f021afc1adf4093690b55d1b8bfe300ee69ca8a5c
MD5 1909a67647e6aa1582a01db0d3843b2c
BLAKE2b-256 5b96192518e89d7279fd9919c44e1d8d22de309ed10b6ee4121436c50d401b63

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page