Replies: 1 comment
-
(Never mind - I am taking another approach, so I just need to get LibreChat working as it is) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I would like to add a hook at a point when a user prompt is already entered but not yet sent to the model. I want to call an API which will modify the prompt. My own use case is for dynamic memory injection, but thus same hook could be used to check for things unsafe to send, such as credit card numbers or personally identifiable information (PII).
However, I am just unable to find where to add this hook. In useSubmitMessage.ts there is a call to ask() and I failed to work out where things go next; I'm not familiar with this front-end architecture and Gemini got confused and hallucinated. Ideally I'd want to add the hook to the backend not to the frontend.
Advice as to where to look would be much appreciated.
Beta Was this translation helpful? Give feedback.
All reactions