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
We need to support structured outputs, streaming, tools, and everything exposed via the completions API. But we want to follow a few principles:
Transparency of the underlying API: don't hide or simplify the underlying OpenAI API types - get access to the raw ChatCompletion input and outputs so that you don't outgrow the abstraction, miss features, etc.
Separation of concerns through composition: separate layers like tools, structured outputs, and providers so that they can be used independently or together.
Progressive disclosure of complexity: simple use cases like sync or streaming completions are simple. complex features like tools are opt in.
Escape hatches all the way down: If you outgrow any part of the abstraction, you should be able to easily replace it, and continue using the useful bits it is composed of independently.
Right level of abstraction: Handle tedious parts like translating tools, but don't be too smart or make too many assumptions.
Lean core OpenAI compatability: stay away from non-standard APIs like response format and auto-running tools that might not play well with other providers.
In summary, the abstraction should give structure and eliminate boilerplate, but stay out of the way and let you evolve patterns over time without topping out.
Related issues:
We need to support structured outputs, streaming, tools, and everything exposed via the completions API. But we want to follow a few principles:
ChatCompletion
input and outputs so that you don't outgrow the abstraction, miss features, etc.In summary, the abstraction should give structure and eliminate boilerplate, but stay out of the way and let you evolve patterns over time without topping out.
TODO:
gsx.workflow
top level to execute in new contextsgsx.workflow("name", <Component>).run();
gsx.execute
to throw error when called outside of a workflow context / component #222generateText
method to replace the currentChatCompletion
generateText
The text was updated successfully, but these errors were encountered: