Add searx_host parameter to SearxSearchWrapperComponent
This commit is contained in:
parent
01b386fe5b
commit
e7899480af
1 changed files with 9 additions and 2 deletions
|
|
@ -19,11 +19,18 @@ class SearxSearchWrapperComponent(CustomComponent):
|
||||||
"field_type": "int",
|
"field_type": "int",
|
||||||
"value": 10
|
"value": 10
|
||||||
},
|
},
|
||||||
|
"searx_host": {
|
||||||
|
"display_name": "Searx Host",
|
||||||
|
"field_type": "str",
|
||||||
|
"value": "https://searx.example.com",
|
||||||
|
"advanced": True,
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
def build(
|
def build(
|
||||||
self,
|
self,
|
||||||
k: Optional[int] = 10,
|
k: Optional[int] = 10,
|
||||||
headers: Optional[Dict[str, str]] = None,
|
headers: Optional[Dict[str, str]] = None,
|
||||||
):
|
searx_host: Optional[str] = None,
|
||||||
return SearxSearchWrapper(headers=headers,k=k)
|
)->SearxSearchWrapper:
|
||||||
|
return SearxSearchWrapper(headers=headers,k=k,searx_host=searx_host)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue