letta
v0.5.3
主页// Documentation // Letta Cloud
? LETTA是用于构建状态LLM应用程序的开源框架。您可以使用LETTA来构建具有高级推理功能和透明的长期记忆的状态代理。 LETTA框架是白色框和模型不可替代的。
笔记
寻找记忆?你在正确的地方!
Memgpt软件包和Docker映像已重命名为letta
以阐明Memgpt代理与运行LLM代理作为服务的API服务器 /运行时之间的区别。
您使用LETTA框架来创建模因代理。在此处阅读有关Memgpt和Letta之间关系的更多信息。
安装LETTA的两种主要方法是通过PYPI ( pip
)或Docker :
pip
(下面的指南) - 尝试LETTA的最简单方法,默认将使用SQLite和Chromadb用于数据库后端pip
安装Letta $ pip install -U letta
$ export OPENAI_API_KEY=sk-...
对于Ollama(有关如何设置各种提供商的示例,请参见我们的完整文档):
$ export OLLAMA_BASE_URL=http://localhost:11434
您可以通过LETTA CLI工具( letta run
)创建代理并与他们聊天:
$ letta run
? Creating new agent...
? Select LLM model: letta-free [type=openai] [ip=https://inference.memgpt.ai]
? Select embedding model: letta-free [type=hugging-face] [ip=https://embeddings.memgpt.ai]
-> ? Using persona profile: 'sam_pov'
-> ? Using human profile: 'basic'
-> 8 tools: send_message, pause_heartbeats, conversation_search, conversation_search_date, archival_memory_insert, archival_memory_search, core_memory_append, core_memory_replace
? Created new agent 'InspiringSpinach'
Hit enter to begin (will request first Letta message)
? User engaged. Recognize as Chad. Acknowledge presence and establish connection. Explore interests and engage in meaningful discourse.
? Hello, Chad. It's nice to meet you. I am keen on learning and exploring new ideas and concepts. Is there a specific topic you'd like to discuss today?
> Enter your message: my name is Brad, not Chad...
? A discrepancy in identity. Reflect this change in core memory. Apologize for the oversight, and rectify the error.
⚡? [function] updating memory with core_memory_replace
First name: Chad
→ First name: Brad
? Apologize for the mistake in recognizing his name, and begin the conversation anew, addressing him by the correct name this time.
? I apologize for the oversight, Brad. Let's restart. It's a pleasure to meet you, Brad. Is there a specific topic you'd like to discuss today?
> Enter your message:
您可以使用letta server
启动Letta API服务器(请参阅此处的完整API参考):
$ letta server
Initializing database...
Running: uvicorn server:app --host localhost --port 8283
INFO: Started server process [47750]
INFO: Waiting for application startup.
INFO: Application startup complete.
INFO: Uvicorn running on http://localhost:8283 (Press CTRL+C to quit)
启动LETTA API服务器时,ADE(代理开发环境)将在http://localhost:8283
:
在Letta中,所有代理都均存储/持续在同一数据库中,因此您在CLI中创建的代理可通过API和ADE访问,反之亦然。在我们的文档上查看Quickstart指南,以获取一个教程,您可以在Letta CLI中创建代理,并通过Letta API向同一代理发消息。
莱塔(Letta)是一个由一百多名贡献者构建的开源项目。有很多方法可以参与Letta OSS项目!
#support
频道。法律通知:通过使用LETTA和相关的LETTA服务(例如Letta端点或托管服务),您同意我们的隐私政策和服务条款。