fix(go-agent): missing input form for ExeSQL and Browser agent nodes (#16675)

## Summary
- Add Go dynamic input form support for ExeSQL and Browser components.
- Align their input form metadata with the Python implementation.
- Add regression tests for `/components/:component_id/input-form`.
This commit is contained in:
Hz_
2026-07-06 19:15:09 +08:00
committed by GitHub
parent b2e82a42d6
commit 7e0ccee7e2
3 changed files with 139 additions and 1 deletions

View File

@@ -334,6 +334,19 @@ func (b *BrowserComponent) Inputs() map[string]string {
}
}
func (b *BrowserComponent) GetInputForm() map[string]any {
return map[string]any{
"prompts": map[string]any{
"type": "text",
"name": "Prompts",
},
"upload_sources": map[string]any{
"type": "line",
"name": "Upload sources",
},
}
}
// Outputs returns the response surface.
func (b *BrowserComponent) Outputs() map[string]string {
return map[string]string{

View File

@@ -517,6 +517,15 @@ func (c *exesqlComponent) Inputs() map[string]string {
}
}
func (c *exesqlComponent) GetInputForm() map[string]any {
return map[string]any{
"sql": map[string]any{
"name": "SQL",
"type": "line",
},
}
}
func (c *exesqlComponent) Outputs() map[string]string {
return map[string]string{
"columns": "Result-set column names.",