Commit Graph

28 Commits

Author SHA1 Message Date
amysguan
47b0c87ebe Add modes self and self_sliding_window for prompt caching (#9372)
* add self compaction method with proper caching (pass in tools, don't refresh sys prompt beforehand) + sliding fallback

* updated prompts for self compaction

* add tests for self, self_sliding_window modes and w/o refresh messages before compaction

* add cache logging to summarization

* better handling to prevent agent from continuing convo on self modes

* if mode changes via summarize endpoint, will use default prompt for the new mode

---------

Co-authored-by: Amy Guan <amy@letta.com>
2026-02-24 10:55:26 -08:00
Kian Jones
f5c4ab50f4 chore: add ty + pre-commit hook and repeal even more ruff rules (#9504)
* auto fixes

* auto fix pt2 and transitive deps and undefined var checking locals()

* manual fixes (ignored or letta-code fixed)

* fix circular import

* remove all ignores, add FastAPI rules and Ruff rules

* add ty and precommit

* ruff stuff

* ty check fixes

* ty check fixes pt 2

* error on invalid
2026-02-24 10:55:11 -08:00
Ari Webb
5c6ca705f1 Revert "feat: bring back use message packing for timezone [LET-6846]" (#9302)
Revert "feat: bring back use message packing for timezone [LET-6846] (#9256)"

This reverts commit c5017cccdef95b84fc585b26a0ddc5b7e44eb7c9.
2026-02-24 10:52:06 -08:00
Ari Webb
426f6a8ca4 feat: bring back use message packing for timezone [LET-6846] (#9256)
* feat: bring back use message packing for timezone

* add tests
2026-02-24 10:52:06 -08:00
jnjpng
3f23a23227 feat: add compaction stats (#9219)
* base

* update

* last

* generate

* fix test
2026-02-24 10:52:06 -08:00
cthomas
4c24b4b104 fix: remove noisy log message [LET-2101] (#6394)
fix: remove noisy log message
2025-11-26 14:39:39 -08:00
Ari Webb
ec953d27c0 fix: double escape leads to exponential growth in backslash character [LET-6016] (#6087) 2025-11-24 19:09:33 -08:00
Kian Jones
704d3b2d79 chore: refactor not to use warnings.warn (#5730)
* refactor not to use warnings.warn

* temp circular import fix maybe unecessary/bnad

* fix Deprecation warning

* fix deprecation warning and mcp thing?

* revert changes to mcp server test

* fix deprecation warning
2025-10-24 15:14:31 -07:00
Matthew Zhou
1c285f5170 fix: Fix system init messages and anthropic parsing [LET-5385] (#5339)
* Fix system init messages and anthropic parsing

* Add backwards compat tool call id adding
2025-10-24 15:11:31 -07:00
cthomas
9cb5156ac7 chore: sync 0.12.0 version (#3023)
Co-authored-by: Matthew Zhou <mattzh1314@gmail.com>
Co-authored-by: Kian Jones <11655409+kianjones9@users.noreply.github.com>
Co-authored-by: Sarah Wooders <sarahwooders@gmail.com>
2025-10-08 16:10:51 -07:00
Kian Jones
ca6cfa5914 chore: migrate to ruff (#4305)
* base requirements

* autofix

* Configure ruff for Python linting and formatting

- Set up minimal ruff configuration with basic checks (E, W, F, I)
- Add temporary ignores for common issues during migration
- Configure pre-commit hooks to use ruff with pass_filenames
- This enables gradual migration from black to ruff

* Delete sdj

* autofixed only

* migrate lint action

* more autofixed

* more fixes

* change precommit

* try changing the hook

* try this stuff
2025-08-29 11:11:19 -07:00
jnjpng
de3c99d7f5 fix: lmstudio support for qwen and llama
Co-authored-by: Jin Peng <jinjpeng@Jins-MacBook-Pro.local>
Co-authored-by: Charles Packer <packercharles@gmail.com>
2025-07-29 15:57:20 -07:00
Andy Li
94d10589c8 fix: structured outputs for send_message, LettaMessage 2025-07-24 14:50:52 -07:00
Andy Li
904d9ba5a2 chore: strings lint cleanup (#3374) 2025-07-18 09:20:45 -07:00
Charles Packer
d81382b9fe refactor: revert the default summarizer to the old style (#3168) 2025-07-06 20:15:22 -07:00
Sarah Wooders
10cdbf2ea4 feat: add ability to configure agent timezone (#2978)
Co-authored-by: Kian Jones <kian@letta.com>
2025-06-24 12:57:37 -07:00
Matthew Zhou
54562d88d7 feat: Add required before exit tool rule (#2977) 2025-06-23 17:02:40 -07:00
Andy Li
3e11bb2910 fix: unpacking non json values (#2684) 2025-06-09 11:11:56 -07:00
Matthew Zhou
beed896d60 feat: Support offline memory in voice agent (#1347) 2025-04-28 15:03:02 -07:00
Matthew Zhou
8d765f286e feat: Composio tools execute on-the-fly (#999) 2025-02-13 16:13:29 -08:00
cthomas
50df2ee3c4 fix: protect against nested system message packing (#876) 2025-01-31 12:05:30 -08:00
Shubham Naik
22c4c499a6 Revert "fix: only parse user message" (#851) 2025-01-30 09:43:50 -08:00
cthomas
13917b326e fix: only parse user message (#846) 2025-01-29 20:57:54 -08:00
cthomas
18227a3b06 feat: flatten content field in user message [RETRY] (#809) 2025-01-28 13:41:45 -08:00
cthomas
eccd279b02 revert: "feat: flatten content field in user message" (#808) 2025-01-28 11:06:30 -08:00
cthomas
a4f4db96d7 feat: flatten content field in user message (#781) 2025-01-28 10:32:44 -08:00
Matthew Zhou
1d35a52951 feat: Rework summarizer (#654) 2025-01-22 11:19:26 -08:00
Sarah Wooders
8ae1e64987 chore: migrate package name to letta (#1775)
Co-authored-by: Charles Packer <packercharles@gmail.com>
Co-authored-by: Shubham Naik <shubham.naik10@gmail.com>
Co-authored-by: Shubham Naik <shub@memgpt.ai>
2024-09-23 09:15:18 -07:00