-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
[llm] Parameter metadata #3404
[llm] Parameter metadata #3404
Conversation
template: | ||
ui_display_name: Template | ||
expected_impact: 3 | ||
component_type: textarea |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So based on a separate conversation with @martindavis and I had earlier today, I would have expected the new component_type
property to appear at the schema level, not in the parameter metadata.
By schema level I mean in the json_schema_type_mapping
for PromptConfigField
. So it would become a "sibling" property of "parameter_metadata" rather than one of the latter's child props.
We can plumb it through either way, but by putting it in parameter metadata the correct thing to do would be to define a default for this prop in the ParameterMetadata
class as well, which I suppose could be null
. But doing so would also imply we're establishing a general standard of tying parameters to their renderable HTML elements.
Up to you guys, I'm fine going either way. I kind of lean in this direction since we are already putting other "UI" focused metadata in their like the "ui_display_name". But maybe we don't want to more strongly tie (quite light) business logic in like this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! I went ahead and added ui_component_type
to ParameterMetadata
, which I feel is consistent with how we handle the display name, etc.
No description provided.