-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Dynamic template system with editable system prompt fields. #895
Closed
Maximilian-Winter
wants to merge
38
commits into
letta-ai:895-staging
from
Maximilian-Winter:DynamicTemplateSystem
Closed
Changes from 17 commits
Commits
Show all changes
38 commits
Select commit
Hold shift + click to select a range
19dcede
System message template system
Maximilian-Winter de15d3c
Update formatting
Maximilian-Winter c05c77e
Merge remote-tracking branch 'upstream/main' into DynamicTemplateSystem
Maximilian-Winter 7c328e7
Merge remote-tracking branch 'upstream/main' into DynamicTemplateSystem
Maximilian-Winter e431af4
Implemented Dynamic Runtime Template system.
Maximilian-Winter 9b0751a
Merge remote-tracking branch 'upstream/main' into DynamicTemplateSystem
Maximilian-Winter 2a152c8
Update agent.py
Maximilian-Winter be2f8f0
Merge remote-tracking branch 'upstream/main' into DynamicTemplateSystem
Maximilian-Winter c5eb200
Added customizable core memory
Maximilian-Winter 655045b
Update memory.py
Maximilian-Winter 5855915
Update memory.py
Maximilian-Winter 5ae2ae1
Merge remote-tracking branch 'upstream/main' into DynamicTemplateSystem
Maximilian-Winter 6f19dda
Integrated customizable core memory into memgpt
Maximilian-Winter f7042fb
Update main.py
Maximilian-Winter 1fc609d
Templated everything in the system message.
Maximilian-Winter 85f0981
Update agent.py
Maximilian-Winter 35716a4
Update prompt_template.py
Maximilian-Winter 4a97eee
Merge remote-tracking branch 'upstream/main' into DynamicTemplateSystem
Maximilian-Winter 7c1a2ca
Merge remote-tracking branch 'upstream/main' into DynamicTemplateSystem
Maximilian-Winter 182e8f2
Try to make it work again
Maximilian-Winter 5ac23fa
Update agent.py
Maximilian-Winter 99eb353
Fixed formatting
Maximilian-Winter eb3e8a2
Update agent.py
Maximilian-Winter 3b34123
Update presets.py
Maximilian-Winter 250cb73
Update presets.py
Maximilian-Winter b52a0c5
Update generate_default_template_fields_yaml.py
Maximilian-Winter 95b642d
Update presets.py
Maximilian-Winter f5cd107
Update default_templates.py
Maximilian-Winter bbf9ed7
Update initial_core_memory.yaml
Maximilian-Winter e141322
Update metadata.py
Maximilian-Winter 2394371
Update data_types.py
Maximilian-Winter ca82ddd
Update agent.py
Maximilian-Winter e248945
Update default_templates.py
Maximilian-Winter e870ca0
Update presets.py
Maximilian-Winter cd98228
Update metadata.py
Maximilian-Winter c831c73
Update data_types.py
Maximilian-Winter bc07052
Update agent.py
Maximilian-Winter a4cbac3
Update presets.py
Maximilian-Winter File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this feels to me like an increase in complexity to a very core component of the overall agent.
I think the templated core memory feature is a cool idea, but I think the templating handling should be encapsulated into a class and then passed into this function.
Something like
def construct_system_with_memory(system: SystemPromptHandler, ...
then the full system message gets handled via
system.get_message()
or something similar.This way if someone wants to experiment with a different approach, they can simply swap out the SystemHandler class, rather than needing to work around the templating system here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you are right about that. I wrote the code after I hadn't slept for a night. 😄 And it was a wild idea.