-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Python: Handlebars template support #5466
Python: Handlebars template support #5466
Conversation
Python 3.8 Test Coverage Report •
Python 3.8 Unit Test Overview
|
6db20af
to
44fb45c
Compare
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.
Looking great
python/semantic_kernel/functions/kernel_function_from_prompt.py
Outdated
Show resolved
Hide resolved
python/semantic_kernel/prompt_template/handlebars/function_helpers.py
Outdated
Show resolved
Hide resolved
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.
Looks good, besides @moonbox3 comments I didn't see anything else to change.
0075789
to
01f9230
Compare
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.
Awesome work.
Motivation and Context
Introducing Handlebars templating to the Python Semantic Kernel!
Closes: #5446
Prework for: #4641
Description
Adds HandlebarsPromptTemplate as a subclass of PromptTemplateBase
Adds second literal to the PromptTemplateConfig definition
Adds helpers for Handlebars (system_helpers) and
create_helper_from_function
functionMoves fully_qualified_name into KernelFunctionMetadata instead of in different extensions.
Defaults are still 'semantic-kernel' templates, and without making explicit changes that still is the norm.
Adds a azure_chat_gpt_handlebars.py sample
Contribution Checklist