Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

MemGPT logo

MemGPT allows you to build LLM agents with long term memory & custom tools

Discord arxiv 2310.08560 Documentation

MemGPT makes it easy to build and deploy stateful LLM agents with support for:

Installation & Setup

Install MemGPT:

pip install pymemgpt

To use MemGPT with OpenAI, set the enviornemnt variable OPENAI_API_KEY to your OpenAI key then run:

memgpt quickstart --backend openai

To use MemGPT with a free hosted endpoint, you run run:

memgpt quickstart --backend memgpt

For more advanced configuration options or to use a different LLM backend or local LLMs, run memgpt configure.

Quickstart (CLI)

You can create and chat with a MemGPT agent by running memgpt run in your CLI. The run command supports the following optional flags (see the CLI documentation for the full list of flags):

  • --agent: (str) Name of agent to create or to resume chatting with.
  • --first: (str) Allow user to sent the first message.
  • --debug: (bool) Show debug logs (default=False)
  • --no-verify: (bool) Bypass message verification (default=False)
  • --yes/-y: (bool) Skip confirmation prompt and use defaults (default=False)

You can view the list of available in-chat commands (e.g. /memory, /exit) in the CLI documentation.

Quickstart (Server)

You can use MemGPT to depoy agents as a service. The service requires authentication with a MemGPT admin password, which can be set with running export MEMGPT_SERVER_PASS=password. You can start a MemGPT service in two ways:

Option 1 (Recommended): Run with docker compose

  1. Install docker on your system
  2. Clone the repo: git clone git@github.com:cpacker/MemGPT.git
  3. Run docker compose up
  4. Go to memgpt.localhost in the browser to view the developer portal

Option 2: Run with the CLI:

  1. Run memgpt server
  2. Go to localhost:8283 in the browser to view the developer portal

Once the server is running, you can use the Python client or REST API to connect to memgpt.localhost (if you're running with docker compose) or localhost:8283 (if you're running with the CLI) to create users, agents, and more.

Supported Endpoints & Backends

MemGPT is designed to be model and provider agnostic. The following LLM and embedding endpoints are supported:

Provider LLM Endpoint Embedding Endpoint
OpenAI ✅ ✅
Azure OpenAI ✅ ✅
Google AI (Gemini) ✅ ❌
Anthropic (Claude) ✅ ❌
Groq ✅ (alpha release) ❌
Cohere API ✅ ❌
vLLM ✅ ❌
Ollama ✅ ❌
LM Studio ✅ ❌
koboldcpp ✅ ❌
oobabooga web UI ✅ ❌
llama.cpp ✅ ❌
HuggingFace TEI ❌ ✅

When using MemGPT with open LLMs (such as those downloaded from HuggingFace), the performance of MemGPT will be highly dependent on the LLM's function calling ability. You can find a list of LLMs/models that are known to work well with MemGPT on the #model-chat channel on Discord, as well as on this spreadsheet.

Documentation

See full documentation at: https://memgpt.readme.io

Support

For issues and feature requests, please open a GitHub issue or message us on our #support channel on Discord.

By using MemGPT and related MemGPT services (such as the MemGPT endpoint or hosted service), you agree to our privacy policy and terms of service.

Roadmap

You can view (and comment on!) the MemGPT developer roadmap on GitHub: https://github.com/cpacker/MemGPT/issues/1200.

Benchmarking

To evaluate the performance of a model on MemGPT, simply configure the appropriate model settings using memgpt configure, and then initiate the benchmark via memgpt benchmark. The duration will vary depending on your hardware. This will run through a predefined set of prompts through multiple iterations to test the function calling capabilities of a model. You can help track what LLMs work well with MemGPT by contributing your benchmark results via this form, which will be used to update the spreadsheet.

Metadata

Release files for pymemgpt-nightly 0.3.13.dev20240503103853

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pymemgpt-nightly 0.3.13.dev20240503103853
File Size Uploaded Provenance Actions
pymemgpt_nightly-0.3.13.dev20240503103853.tar.gz 563.9 kB Without provenance Details for pymemgpt_nightly-0.3.13.dev20240503103853.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pymemgpt-nightly 0.3.13.dev20240503103853
File Interpreter ABI Platform Actions
pymemgpt_nightly-0.3.13.dev20240503103853-py3-none-any.whl Python 3 none any Details for pymemgpt_nightly-0.3.13.dev20240503103853-py3-none-any.whl

Total release size: 1.2 MB

Release files / pymemgpt_nightly-0.3.13.dev20240503103853.tar.gz

Download URL pymemgpt_nightly-0.3.13.dev20240503103853.tar.gz
Size 563.9 kB
Tags Source
SHA-256 checksum
How to use checksums
a1dba553ab73939d6c3ec83ff6882f2462bd0f377aec4a8ada276e5d06914e42
BLAKE2b-256 checksum
How to use checksums
c2863eba6b075640e7628d3a9f33918488e320fb2e8f6070bce389a2cfac0410
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.7.1 CPython/3.11.9 Linux/6.5.0-1018-azure

Release files / pymemgpt_nightly-0.3.13.dev20240503103853-py3-none-any.whl

Download URL pymemgpt_nightly-0.3.13.dev20240503103853-py3-none-any.whl
Size 642.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
503ae548a97bc1a36e132d6ff0f37cd6e210dfe3d5611c0741c60d7d364dbd16
BLAKE2b-256 checksum
How to use checksums
7cd4f95b4e953b2983067de5f3c9d52f1f4c8e73fe72b0def48537e4edac1075
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.7.1 CPython/3.11.9 Linux/6.5.0-1018-azure

Security for pymemgpt-nightly 0.3.13.dev20240503103853

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page