Skip to content

Support additional contexts for ProgramSynthesis #427

@datvo06

Description

@datvo06

In some component-based synthesis settings, it is useful to provide LLMs with functions that the resulting program can use.
While currently the tools are provided via tools parameters in the Template, we lack support for the resulting programs to import these modules automatically.
Example usage:

Template.define(ctxs=[functionA, functionB])
def generate_new_function() -> Callable[[a,b],c]:
       """generate this function that do x,y,z"""

Can reuse the type importing logic in #422

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions