mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-04-25 00:51:20 +00:00
chore: remove unused imports, dead code, and stale comments
Mechanical cleanup — no behavior changes. Unused imports removed: - model_tools.py: import os - run_agent.py: OPENROUTER_MODELS_URL, get_model_context_length - cli.py: Table, VERSION, RELEASE_DATE, resolve_toolset, get_skill_commands - terminal_tool.py: signal, uuid, tempfile, set_interrupt_event, DANGEROUS_PATTERNS, _load_permanent_allowlist, _detect_dangerous_command Dead code removed: - toolsets.py: print_toolset_tree() (zero callers) - browser_tool.py: _get_session_name() (never called) Stale comments removed: - toolsets.py: duplicated/garbled comment line - web_tools.py: 3 aspirational TODO comments from early development
This commit is contained in:
parent
72a6d7dffe
commit
bfe4baa6ed
7 changed files with 5 additions and 59 deletions
28
toolsets.py
28
toolsets.py
|
|
@ -226,7 +226,6 @@ TOOLSETS = {
|
|||
# ==========================================================================
|
||||
# Full Hermes toolsets (CLI + messaging platforms)
|
||||
#
|
||||
# All platforms share the same core tools. Messaging platforms add
|
||||
# All platforms share the same core tools (including send_message,
|
||||
# which is gated on gateway running via its check_fn).
|
||||
# ==========================================================================
|
||||
|
|
@ -535,33 +534,6 @@ def get_toolset_info(name: str) -> Dict[str, Any]:
|
|||
}
|
||||
|
||||
|
||||
def print_toolset_tree(name: str, indent: int = 0) -> None:
|
||||
"""
|
||||
Print a tree view of a toolset and its composition.
|
||||
|
||||
Args:
|
||||
name (str): Toolset name
|
||||
indent (int): Current indentation level
|
||||
"""
|
||||
prefix = " " * indent
|
||||
toolset = get_toolset(name)
|
||||
|
||||
if not toolset:
|
||||
print(f"{prefix}❌ Unknown toolset: {name}")
|
||||
return
|
||||
|
||||
# Print toolset name and description
|
||||
print(f"{prefix}📦 {name}: {toolset['description']}")
|
||||
|
||||
# Print direct tools
|
||||
if toolset["tools"]:
|
||||
print(f"{prefix} 🔧 Tools: {', '.join(toolset['tools'])}")
|
||||
|
||||
# Print included toolsets
|
||||
if toolset["includes"]:
|
||||
print(f"{prefix} 📂 Includes:")
|
||||
for included in toolset["includes"]:
|
||||
print_toolset_tree(included, indent + 2)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue