Skip to content
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: replace special variables in instructions presets #4603

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

owengo
Copy link

@owengo owengo commented Oct 31, 2024

Pull Request Template

⚠️ Documentation Updates Notice:

  • Kindly note that documentation updates are managed in this repository: librechat.ai

LibreChat-AI/librechat.ai#132

Summary

Following discussion at: #3713

This is a proposal to replace the specials variable: {{current_date}} and {{current_user}} in the presets before sending the request to backed.
The evaluation is done client-side, by the same function as for the custom prompts.

Change Type

Please delete any irrelevant options.

  • [x ] New feature (non-breaking change which adds functionality)
  • This change requires a documentation update

Testing

Please describe your test process and include instructions so that we can reproduce your test. If there are any important variables for your testing configuration, list them here.

Test Configuration:

Configure a preset with custom instructions like this:

"You are a helpful assistant. Today is {{current_date}}. You are talking with {{current_user}}"

The endpoint will know the current date and the user it's chatting with, like for custom prompts.

Checklist

Please delete any irrelevant options.

  • My code adheres to this project's style guidelines
  • I have performed a self-review of my own code
  • I have made pertinent documentation changes
  • My changes do not introduce new warnings
  • A pull request for updating the documentation has been submitted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants