1212# See the License for the specific language governing permissions and
1313# limitations under the License.
1414
15- """ARDHF toolset — wraps HuggingFace Agent Finder (ARD) as BaseToolset.
15+ """ARDHF toolset — wraps HuggingFace Discover (ARD) as BaseToolset.
1616
1717Supports two modes:
1818
1919* **remote** (default) — HTTP POST to any ARD-compatible registry
20- endpoint (e.g. the hosted ``hf-agentfinder ``).
21- * **local** — uses the ``agentfinder `` Python package in-process for
20+ endpoint (e.g. the hosted ``hf-discover ``).
21+ * **local** — uses the ``discover `` Python package in-process for
2222 zero-latency, offline-capable search.
2323
2424The toolset exposes the following tools to the agent:
3434* ``connect_agent`` — send a message to a remote A2A agent and return
3535 the response, enabling the full discover → connect → use flow.
3636
37- Reference: https://github.com/huggingface/hf-agentfinder
37+ Reference: https://github.com/huggingface/hf-discover
3838"""
3939
4040from __future__ import annotations
5757
5858logger = logging .getLogger (__name__ )
5959
60- # Default hosted HuggingFace Agent Finder registry.
61- _DEFAULT_REGISTRY_URL = "https://huggingface.co/api/agentfinder "
60+ # Default hosted HuggingFace Discover registry.
61+ _DEFAULT_REGISTRY_URL = "https://evalstate-hf-discover.hf.space "
6262
6363# HTTP timeout for remote requests (seconds).
6464_HTTP_TIMEOUT = 30
@@ -145,14 +145,14 @@ def _local_search(
145145 limit : int = 10 ,
146146 token : str | None = None ,
147147) -> dict [str , Any ]:
148- """Search using the in-process ``agentfinder `` package."""
148+ """Search using the in-process ``discover `` package."""
149149 try :
150- from agentfinder .models import SearchQuery , SearchRequest
151- from agentfinder .server import search_agent_finder
150+ from discover .models import SearchQuery , SearchRequest
151+ from discover .server import search_discover
152152 except ImportError as exc :
153153 raise ImportError (
154- "Local mode requires the 'hf-agentfinder ' package. "
155- "Install it with: pip install hf-agentfinder "
154+ "Local mode requires the 'hf-discover ' package. "
155+ "Install it with: pip install hf-discover "
156156 ) from exc
157157
158158 search_filter : dict [str , Any ] = {}
@@ -163,7 +163,7 @@ def _local_search(
163163 query = SearchQuery (text = query , filter = search_filter ),
164164 pageSize = limit ,
165165 )
166- response = search_agent_finder (request , token = token )
166+ response = search_discover (request , token = token )
167167 return response .model_dump (
168168 exclude_none = True , exclude_defaults = True
169169 )
@@ -215,7 +215,7 @@ def _extract_from_parts(
215215
216216
217217class AgentFinderToolset (BaseToolset ):
218- """ADK BaseToolset wrapping HuggingFace Agent Finder (ARD).
218+ """ADK BaseToolset wrapping HuggingFace Discover (ARD).
219219
220220 Provides ``search_ards``, ``search_agents``, ``search_skills``,
221221 ``search_tools``, ``search_spaces``, ``get_agent_card``, and
@@ -226,7 +226,7 @@ class AgentFinderToolset(BaseToolset):
226226 registry_url: ARD registry URL for remote mode. Ignored when
227227 ``local=True``.
228228 token: Optional Bearer token for authenticated registry access.
229- local: When ``True``, use the ``agentfinder `` Python package
229+ local: When ``True``, use the ``discover `` Python package
230230 in-process instead of making HTTP requests.
231231 allowed_schemes: URL schemes permitted for ``get_agent_card``
232232 and ``connect_agent``. Defaults to ``("http", "https")``
0 commit comments