Closed carlosgjs closed 7 months ago
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
61d2480
) 96.57% compared to head (1fdb074
) 97.00%.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
The changes I think are good and I don't have much comment on that. I do have some thoughts on the PromptBuilder
class. Is this serving almost like a template engine thing? Seems like you're trying to pack together some sort of prompt text. My thought is maybe it's worth to create some sort of prompt template say with tools like jinja so that it's easier to see what is actually getting build. At this moment, without actually running the code, I have a hard time understanding what is actually happening... Idk, what do you think?
The changes I think are good and I don't have much comment on that. I do have some thoughts on the
PromptBuilder
class. Is this serving almost like a template engine thing? Seems like you're trying to pack together some sort of prompt text. My thought is maybe it's worth to create some sort of prompt template say with tools like jinja so that it's easier to see what is actually getting build. At this moment, without actually running the code, I have a hard time understanding what is actually happening... Idk, what do you think?
Didn't know about jinja
and it looks pretty powerful. But perhaps its overkill for this scenario? I'm hesitant to add a package dependency for a relatively simple string building.
Didn't know about jinja and it looks pretty powerful. But perhaps its overkill for this scenario? I'm hesitant to add a package dependency for a relatively simple string building.
Okay, I wasn't sure how complex these prompts may be. 😄 I do like what you did in your last commit to at least make the code more readable.
This PR refactors the prompt management to add support for one-shot prediction. Specifically:
PromptBuilder
helper classprompts
module to export full prompt templates, instead of separate sets of system and instruction promptsTest outputs from the
generate.ipynb
notebook: