You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Current syntax to call flows does not feel ergonomic const response = await runFlow(menuSuggestionFlow, "French");. Flows are just special functions, so I want them to be able to call them more like regular functions.
Being able to call flows like normal functions is a huge ergonomic win - it's qualitatively different than the alternatives because you get all the observability benefits but you use it like you just defined a normal function.
Describe alternatives you've considered
Some alternative ideas
Alternate 1
myFlow.run(...)
myFlow.stream(...)
Alternate 2
myFlow(...)
myFlow.stream(...)
Alternate 3
myFlow().run()
myFlow().runWithStreaming()
Additional context
N/A
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
Current syntax to call flows does not feel ergonomic
const response = await runFlow(menuSuggestionFlow, "French");
. Flows are just special functions, so I want them to be able to call them more like regular functions.Describe the solution you'd like
const myFlow = defineFlow()
->await myFlow()
const myFlow = defineStreamingFlow()
->const {stream, result} = await myFlow()
Being able to call flows like normal functions is a huge ergonomic win - it's qualitatively different than the alternatives because you get all the observability benefits but you use it like you just defined a normal function.
Describe alternatives you've considered
Some alternative ideas
Alternate 1
Alternate 2
Alternate 3
Additional context
N/A
The text was updated successfully, but these errors were encountered: