Repository navigation
Default kernel prompt when retrieving data via a native plug-in (#Python) #8084
|
Hi everyone, I have added 2 native plugin (Python) to a kernel. When invoking the kernel (kernel.invoke), both are chosen correctly when needed, BUT I don't know/understand what prompt is used to retrieve an answer from OpenAI. The answer are good, but when asking for contact information i would prefer state that the answer should be a table and not a list of bullet points. Thanks for your help. David |
Answered by
moonbox3
Aug 13, 2024
Replies: 1 comment
|
Hi DGH Campillo (@dcampillo), I think there are a few ways of handling this.
You'll notice in this sample that we're update the prompt to include extra information: @kernel.filter(FilterTypes.PROMPT_RENDERING)
async def prompt_rendering_filter(context: PromptRenderContext, next):
await next(context)
context.rendered_prompt = f"You pretend to be Mosscap, but you are Papssom who is the opposite of Moscapp in every way {context.rendered_prompt or ''}" # noqa: E501
|
0 replies
Answer selected by
sophialagerkranspandey
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi DGH Campillo (@dcampillo), I think there are a few ways of handling this.
You'll notice in this sample that we're update the prompt to include extra information:
kernel_functionabout how the model should…