-
Notifications
You must be signed in to change notification settings - Fork 668
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: get and set prompts mixin #1391
Conversation
shahules786
commented
Oct 1, 2024
•
edited
Loading
edited
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 should be a mixin because we are using this in 3 places in total.
take a look at this to see it in action: https://www.perplexity.ai/search/write-me-a-tutorial-on-python-Bxu55LqmS1ivIV8pRW8TSw
if you make it a mixin, add it to metrics too |
I see, thanks I didn't know that this is the use of Mixins. |
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.
have to remove transforms/base.py
```python from ragas.experimental.testset.simulators import AbstractQuestionSimulator simulator = AbstractQuestionSimulator() prompts = simulator.get_prompts() prompts['common_theme_prompt'].instruction += "\n Ouptut only JSON" simulator.set_prompts(common_theme_prompt=prompts['common_theme_prompt'])```