Skip to content
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(assistants): improve context #2105

Open
3 of 6 tasks
brettc opened this issue Mar 6, 2024 · 0 comments
Open
3 of 6 tasks

feat(assistants): improve context #2105

brettc opened this issue Mar 6, 2024 · 0 comments

Comments

@brettc
Copy link
Collaborator

brettc commented Mar 6, 2024

Originally posted by @nokome in #2096 (comment)

  • Currently, if there is a Jinja syntax error it gets stuffed into the executionMessages of the instruction - in addition this should be tracing::error!-ed so develops can see the issue.
  • Refine the preliminary work on rendering context in CodeChunk e.g.
    • maybe we don't want to fill the prompt will all the packages available, subset somehow?
    • improve rendering of variable hint property
    • handle case where context.code_chunks is empty (i.e. don't print header for these)
  • Add instruction_block and instruction_inline fields to the Context and collect those that have accepted suggestions. The reasoning for this is...We know "few shot in-context learning" - pairs of example instruction / response - is very useful. Our system prompt templates have some in them. But instead of using generic ones, why not use pairs drawn from the current document (and, in the future, from the user's other documents). This is likely to give responses that match the users expectations and style a lot more closely
  • Add a instruction_inline.rs with impl Executable for InstructionInline; this can be based largely on InstructionInline and modify insert-code-expression
  • Improve management of Executor.context. Currently this is cleared each time the document is executed, so that there are not duplicate entries for code chunks. But if Executor.node_ids.is_some() then we don't want to do that. Also we need to think about removing code chunks etc from the context when it the code chunk etc is remove from the document.
  • A lots more examples of documents with varying degrees and types of content. Naming is important here. See examples/kernels for exemplars of setup and naming - trying to provide the same example test examples across different kernels.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant