Skip to content

default_name_resolver

autogen.beta.network.views.base.default_name_resolver #

default_name_resolver(agent_id)

Identity NameResolver — returns agent_id verbatim.

Used by call sites that want to invoke a view policy without plumbing a real hub-backed resolver (tests, headless utilities). Production code paths (the default notify handler) always pass a real resolver backed by the hub's passport directory.

Source code in autogen/beta/network/views/base.py
def default_name_resolver(agent_id: str) -> str:
    """Identity ``NameResolver`` — returns ``agent_id`` verbatim.

    Used by call sites that want to invoke a view policy without
    plumbing a real hub-backed resolver (tests, headless utilities).
    Production code paths (the default notify handler) always pass a
    real resolver backed by the hub's passport directory.
    """
    return agent_id