-
Notifications
You must be signed in to change notification settings - Fork 112
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
Enable a GenAIScript to be packaged as a JavaScript/TypeScript function #450
Comments
basically, I want an in-memory way to call genaiscript. I want to supply a function type signature to genai that tells it the input types (rather than input files) and output type (rather than a file/files). I also supply a "function body" that uses genaiscript to implement the body, referring to the typed input params. genaiscript provides all the plumbing to convert from (typed) input values into prompt, and back out again. Not clear what this actually looks like in code, yet. |
Do you have a sketch of your idea? Is this function meant to be called by another script or is it still a GenAI.js script?
…________________________________
From: Tom Ball ***@***.***>
Sent: Tuesday, May 14, 2024 2:24:34 PM
To: microsoft/genaiscript ***@***.***>
Cc: Subscribed ***@***.***>
Subject: Re: [microsoft/genaiscript] Enable a GenAIScript to be packaged as a JavaScript/TypeScript function (Issue #450)
basically, I want an in-memory way to call genaiscript. I want to supply a function type signature to genai that tells it the input types (rather than input files) and output type (rather than a file/files). I also supply a "function body" that uses genaiscript to implement the body, referring to the typed input params. genaiscript provides all the plumbing to convert from (typed) input values into prompt, and back out again.
Not clear what this actually looks like in code, yet.
—
Reply to this email directly, view it on GitHub<#450 (comment)> or unsubscribe<https://github.com/notifications/unsubscribe-auth/AA73QKOKOIG36YVIISC4WQDZCJ6JHBFKMF2HI4TJMJ2XIZLTSSBKK5TBNR2WLJDUOJ2WLJDOMFWWLO3UNBZGKYLEL5YGC4TUNFRWS4DBNZ2F6YLDORUXM2LUPGBKK5TBNR2WLJDUOJ2WLJDOMFWWLLTXMF2GG2C7MFRXI2LWNF2HTAVFOZQWY5LFUVUXG43VMWSG4YLNMWVXI2DSMVQWIX3UPFYGLAVFOZQWY5LFVI2TQNJWGQ2DIOJXGGSG4YLNMWUWQYLTL5WGCYTFNSWHG5LCNJSWG5C7OR4XAZNMJFZXG5LFINXW23LFNZ2KM5DPOBUWG44TQKSHI6LQMWVHEZLQN5ZWS5DPOJ42K5TBNR2WLKJWG44TOOBUGM3DRAVEOR4XAZNFNFZXG5LFUV3GC3DVMWVDEMRZGY2DENZQGU2IFJDUPFYGLJLMMFRGK3FFOZQWY5LFVI2TQNJWGQ2DIOJXGGTXI4TJM5TWK4VGMNZGKYLUMU>.
You are receiving this email because you are subscribed to this thread.
Triage notifications on the go with GitHub Mobile for iOS<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675> or Android<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
|
Note that scripts can have typed parameters so we already have parts of what you want. https://microsoft.github.io/genaiscript/reference/scripts/variables/#script-parameters |
one solution would be to drop a .ts file (or .py) that wraps a call to the CLI using the parameters and returning the full output. might be overkill |
Currently input and output of GenAIScript is via creating files, etc. We could support the ability to have a wrapper for a script that would use a TypeScript signature to define the inputs and outputs and allow the script to be called as a normal function within other JavaScript/TypeScript code.
The text was updated successfully, but these errors were encountered: