From 5f1cdfc9e4216786fd0b1fd1d68ae786f1920a80 Mon Sep 17 00:00:00 2001 From: Ezra Date: Sun, 5 Apr 2026 23:27:29 +0000 Subject: [PATCH] =?UTF-8?q?[EPIC-999]=20Phase=20I=20=E2=80=94=20The=20Mirr?= =?UTF-8?q?or:=20formal=20spec=20extraction=20artifacts?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - module_inventory.json: 679 Python files, 298k lines, 232k SLOC - core_analysis.json: deep AST parse of 9 core modules - SPEC.md: high-level architecture, module specs, coupling risks, Phase II prep Authored-by: Ezra --- docs/ouroboros/artifacts/core_analysis.json | 4291 ++ docs/ouroboros/artifacts/import_graph.json | 39340 ++++++++++++++++ .../ouroboros/artifacts/module_inventory.json | 3397 ++ docs/ouroboros/specs/SPEC.md | 263 + 4 files changed, 47291 insertions(+) create mode 100644 docs/ouroboros/artifacts/core_analysis.json create mode 100644 docs/ouroboros/artifacts/import_graph.json create mode 100644 docs/ouroboros/artifacts/module_inventory.json create mode 100644 docs/ouroboros/specs/SPEC.md diff --git a/docs/ouroboros/artifacts/core_analysis.json b/docs/ouroboros/artifacts/core_analysis.json new file mode 100644 index 000000000..2b62ae33a --- /dev/null +++ b/docs/ouroboros/artifacts/core_analysis.json @@ -0,0 +1,4291 @@ +{ + "run_agent.py": { + "path": "run_agent.py", + "classes": [ + { + "name": "_SafeWriter", + "methods": [ + { + "name": "__init__", + "args": [ + "self", + "inner" + ], + "async": false, + "docstring": null + }, + { + "name": "write", + "args": [ + "self", + "data" + ], + "async": false, + "docstring": null + }, + { + "name": "flush", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "fileno", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "isatty", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "__getattr__", + "args": [ + "self", + "name" + ], + "async": false, + "docstring": null + } + ], + "docstring": "Transparent stdio wrapper that catches OSError/ValueError from broken pipes.\n\nWhen hermes-agent runs as a systemd service, Docker container, or headless\ndaemon, the stdout/stderr pipe can become unavailable (idle timeout, buffer\nexhaustion, socket reset). Any print() call then raises\n``OSError: [Errno 5] Input/output error``, which can crash agent setup or\nrun_conversation() \u2014 especially via double-fault when an except handler\nalso tries to print.\n\nAdditionally, when subagents run in ThreadPoolExecutor threads, the shared\nstdout handle can close between thread teardown and cleanup, raising\n``ValueError: I/O operation on closed file`` instead of OSError.\n\nThis wrapper delegates all writes to the underlying stream and silently\ncatches both OSError and ValueError. It is transparent when the wrapped\nstream is healthy." + }, + { + "name": "IterationBudget", + "methods": [ + { + "name": "__init__", + "args": [ + "self", + "max_total" + ], + "async": false, + "docstring": null + }, + { + "name": "consume", + "args": [ + "self" + ], + "async": false, + "docstring": "Try to consume one iteration. Returns True if allowed." + }, + { + "name": "refund", + "args": [ + "self" + ], + "async": false, + "docstring": "Give back one iteration (e.g. for execute_code turns)." + }, + { + "name": "used", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "remaining", + "args": [ + "self" + ], + "async": false, + "docstring": null + } + ], + "docstring": "Thread-safe iteration counter for an agent.\n\nEach agent (parent or subagent) gets its own ``IterationBudget``.\nThe parent's budget is capped at ``max_iterations`` (default 90).\nEach subagent gets an independent budget capped at\n``delegation.max_iterations`` (default 50) \u2014 this means total\niterations across parent + subagents can exceed the parent's cap.\nUsers control the per-subagent limit via ``delegation.max_iterations``\nin config.yaml.\n\n``execute_code`` (programmatic tool calling) iterations are refunded via\n:meth:`refund` so they don't eat into the budget." + }, + { + "name": "AIAgent", + "methods": [ + { + "name": "base_url", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "base_url", + "args": [ + "self", + "value" + ], + "async": false, + "docstring": null + }, + { + "name": "__init__", + "args": [ + "self", + "base_url", + "api_key", + "provider", + "api_mode", + "acp_command", + "acp_args", + "command", + "args", + "model", + "max_iterations", + "tool_delay", + "enabled_toolsets", + "disabled_toolsets", + "save_trajectories", + "verbose_logging", + "quiet_mode", + "ephemeral_system_prompt", + "log_prefix_chars", + "log_prefix", + "providers_allowed", + "providers_ignored", + "providers_order", + "provider_sort", + "provider_require_parameters", + "provider_data_collection", + "session_id", + "tool_progress_callback", + "tool_start_callback", + "tool_complete_callback", + "thinking_callback", + "reasoning_callback", + "clarify_callback", + "step_callback", + "stream_delta_callback", + "tool_gen_callback", + "status_callback", + "max_tokens", + "reasoning_config", + "prefill_messages", + "platform", + "skip_context_files", + "skip_memory", + "session_db", + "iteration_budget", + "fallback_model", + "credential_pool", + "checkpoints_enabled", + "checkpoint_max_snapshots", + "pass_session_id", + "persist_session" + ], + "async": false, + "docstring": "Initialize the AI Agent.\n\nArgs:\n base_url (str): Base URL for the model API (optional)\n api_key (str): API key for authentication (optional, uses env var if not provided)\n provider (str): Provider identifier (optional; used for telemetry/routing hints)\n api_mode (str): API mode override: \"chat_completions\" or \"codex_responses\"\n model (str): Model name to use (default: \"anthropic/claude-opus-4.6\")\n max_iterations (int): Maximum number of tool calling iterations (default: 90)\n tool_delay (float): Delay between tool calls in seconds (default: 1.0)\n enabled_toolsets (List[str]): Only enable tools from these toolsets (optional)\n disabled_toolsets (List[str]): Disable tools from these toolsets (optional)\n save_trajectories (bool): Whether to save conversation trajectories to JSONL files (default: False)\n verbose_logging (bool): Enable verbose logging for debugging (default: False)\n quiet_mode (bool): Suppress progress output for clean CLI experience (default: False)\n ephemeral_system_prompt (str): System prompt used during agent execution but NOT saved to trajectories (optional)\n log_prefix_chars (int): Number of characters to show in log previews for tool calls/responses (default: 100)\n log_prefix (str): Prefix to add to all log messages for identification in parallel processing (default: \"\")\n providers_allowed (List[str]): OpenRouter providers to allow (optional)\n providers_ignored (List[str]): OpenRouter providers to ignore (optional)\n providers_order (List[str]): OpenRouter providers to try in order (optional)\n provider_sort (str): Sort providers by price/throughput/latency (optional)\n session_id (str): Pre-generated session ID for logging (optional, auto-generated if not provided)\n tool_progress_callback (callable): Callback function(tool_name, args_preview) for progress notifications\n clarify_callback (callable): Callback function(question, choices) -> str for interactive user questions.\n Provided by the platform layer (CLI or gateway). If None, the clarify tool returns an error.\n max_tokens (int): Maximum tokens for model responses (optional, uses model default if not set)\n reasoning_config (Dict): OpenRouter reasoning configuration override (e.g. {\"effort\": \"none\"} to disable thinking).\n If None, defaults to {\"enabled\": True, \"effort\": \"medium\"} for OpenRouter. Set to disable/customize reasoning.\n prefill_messages (List[Dict]): Messages to prepend to conversation history as prefilled context.\n Useful for injecting a few-shot example or priming the model's response style.\n Example: [{\"role\": \"user\", \"content\": \"Hi!\"}, {\"role\": \"assistant\", \"content\": \"Hello!\"}]\n platform (str): The interface platform the user is on (e.g. \"cli\", \"telegram\", \"discord\", \"whatsapp\").\n Used to inject platform-specific formatting hints into the system prompt.\n skip_context_files (bool): If True, skip auto-injection of SOUL.md, AGENTS.md, and .cursorrules\n into the system prompt. Use this for batch processing and data generation to avoid\n polluting trajectories with user-specific persona or project instructions." + }, + { + "name": "reset_session_state", + "args": [ + "self" + ], + "async": false, + "docstring": "Reset all session-scoped token counters to 0 for a fresh session.\n\nThis method encapsulates the reset logic for all session-level metrics\nincluding:\n- Token usage counters (input, output, total, prompt, completion)\n- Cache read/write tokens\n- API call count\n- Reasoning tokens\n- Estimated cost tracking\n- Context compressor internal counters\n\nThe method safely handles optional attributes (e.g., context compressor)\nusing ``hasattr`` checks.\n\nThis keeps the counter reset logic DRY and maintainable in one place\nrather than scattering it across multiple methods." + }, + { + "name": "_safe_print", + "args": [ + "self" + ], + "async": false, + "docstring": "Print that silently handles broken pipes / closed stdout.\n\nIn headless environments (systemd, Docker, nohup) stdout may become\nunavailable mid-session. A raw ``print()`` raises ``OSError`` which\ncan crash cron jobs and lose completed work.\n\nInternally routes through ``self._print_fn`` (default: builtin\n``print``) so callers such as the CLI can inject a renderer that\nhandles ANSI escape sequences properly (e.g. prompt_toolkit's\n``print_formatted_text(ANSI(...))``) without touching this method." + }, + { + "name": "_vprint", + "args": [ + "self" + ], + "async": false, + "docstring": "Verbose print \u2014 suppressed when actively streaming tokens.\n\nPass ``force=True`` for error/warning messages that should always be\nshown even during streaming playback (TTS or display).\n\nDuring tool execution (``_executing_tools`` is True), printing is\nallowed even with stream consumers registered because no tokens\nare being streamed at that point.\n\nAfter the main response has been delivered and the remaining tool\ncalls are post-response housekeeping (``_mute_post_response``),\nall non-forced output is suppressed." + }, + { + "name": "_emit_status", + "args": [ + "self", + "message" + ], + "async": false, + "docstring": "Emit a lifecycle status message to both CLI and gateway channels.\n\nCLI users see the message via ``_vprint(force=True)`` so it is always\nvisible regardless of verbose/quiet mode. Gateway consumers receive\nit through ``status_callback(\"lifecycle\", ...)``.\n\nThis helper never raises \u2014 exceptions are swallowed so it cannot\ninterrupt the retry/fallback logic." + }, + { + "name": "_is_direct_openai_url", + "args": [ + "self", + "base_url" + ], + "async": false, + "docstring": "Return True when a base URL targets OpenAI's native API." + }, + { + "name": "_is_openrouter_url", + "args": [ + "self" + ], + "async": false, + "docstring": "Return True when the base URL targets OpenRouter." + }, + { + "name": "_is_anthropic_url", + "args": [ + "self" + ], + "async": false, + "docstring": "Return True when the base URL targets Anthropic (native or /anthropic proxy path)." + }, + { + "name": "_max_tokens_param", + "args": [ + "self", + "value" + ], + "async": false, + "docstring": "Return the correct max tokens kwarg for the current provider.\n\nOpenAI's newer models (gpt-4o, o-series, gpt-5+) require\n'max_completion_tokens'. OpenRouter, local models, and older\nOpenAI models use 'max_tokens'." + }, + { + "name": "_has_content_after_think_block", + "args": [ + "self", + "content" + ], + "async": false, + "docstring": "Check if content has actual text after any reasoning/thinking blocks.\n\nThis detects cases where the model only outputs reasoning but no actual\nresponse, which indicates an incomplete generation that should be retried.\nMust stay in sync with _strip_think_blocks() tag variants.\n\nArgs:\n content: The assistant message content to check\n\nReturns:\n True if there's meaningful content after think blocks, False otherwise" + }, + { + "name": "_strip_think_blocks", + "args": [ + "self", + "content" + ], + "async": false, + "docstring": "Remove reasoning/thinking blocks from content, returning only visible text." + }, + { + "name": "_looks_like_codex_intermediate_ack", + "args": [ + "self", + "user_message", + "assistant_content", + "messages" + ], + "async": false, + "docstring": "Detect a planning/ack message that should continue instead of ending the turn." + }, + { + "name": "_extract_reasoning", + "args": [ + "self", + "assistant_message" + ], + "async": false, + "docstring": "Extract reasoning/thinking content from an assistant message.\n\nOpenRouter and various providers can return reasoning in multiple formats:\n1. message.reasoning - Direct reasoning field (DeepSeek, Qwen, etc.)\n2. message.reasoning_content - Alternative field (Moonshot AI, Novita, etc.)\n3. message.reasoning_details - Array of {type, summary, ...} objects (OpenRouter unified)\n\nArgs:\n assistant_message: The assistant message object from the API response\n \nReturns:\n Combined reasoning text, or None if no reasoning found" + }, + { + "name": "_classify_empty_content_response", + "args": [ + "self", + "assistant_message" + ], + "async": false, + "docstring": "Classify think-only/empty responses so we can retry, compress, or salvage.\n\nWe intentionally do NOT short-circuit all structured-reasoning responses.\nPrior discussion/PR history shows some models recover on retry. Instead we:\n- compress immediately when the pattern looks like implicit context pressure\n- salvage reasoning early when the same reasoning-only payload repeats\n- otherwise preserve the normal retry path" + }, + { + "name": "_cleanup_task_resources", + "args": [ + "self", + "task_id" + ], + "async": false, + "docstring": "Clean up VM and browser resources for a given task." + }, + { + "name": "_spawn_background_review", + "args": [ + "self", + "messages_snapshot", + "review_memory", + "review_skills" + ], + "async": false, + "docstring": "Spawn a background thread to review the conversation for memory/skill saves.\n\nCreates a full AIAgent fork with the same model, tools, and context as the\nmain session. The review prompt is appended as the next user turn in the\nforked conversation. Writes directly to the shared memory/skill stores.\nNever modifies the main conversation history or produces user-visible output." + }, + { + "name": "_apply_persist_user_message_override", + "args": [ + "self", + "messages" + ], + "async": false, + "docstring": "Rewrite the current-turn user message before persistence/return.\n\nSome call paths need an API-only user-message variant without letting\nthat synthetic text leak into persisted transcripts or resumed session\nhistory. When an override is configured for the active turn, mutate the\nin-memory messages list in place so both persistence and returned\nhistory stay clean." + }, + { + "name": "_persist_session", + "args": [ + "self", + "messages", + "conversation_history" + ], + "async": false, + "docstring": "Save session state to both JSON log and SQLite on any exit path.\n\nEnsures conversations are never lost, even on errors or early returns.\nSkipped when ``persist_session=False`` (ephemeral helper flows)." + }, + { + "name": "_flush_messages_to_session_db", + "args": [ + "self", + "messages", + "conversation_history" + ], + "async": false, + "docstring": "Persist any un-flushed messages to the SQLite session store.\n\nUses _last_flushed_db_idx to track which messages have already been\nwritten, so repeated calls (from multiple exit paths) only write\ntruly new messages \u2014 preventing the duplicate-write bug (#860)." + }, + { + "name": "_get_messages_up_to_last_assistant", + "args": [ + "self", + "messages" + ], + "async": false, + "docstring": "Get messages up to (but not including) the last assistant turn.\n\nThis is used when we need to \"roll back\" to the last successful point\nin the conversation, typically when the final assistant message is\nincomplete or malformed.\n\nArgs:\n messages: Full message list\n \nReturns:\n Messages up to the last complete assistant turn (ending with user/tool message)" + }, + { + "name": "_format_tools_for_system_message", + "args": [ + "self" + ], + "async": false, + "docstring": "Format tool definitions for the system message in the trajectory format.\n\nReturns:\n str: JSON string representation of tool definitions" + }, + { + "name": "_convert_to_trajectory_format", + "args": [ + "self", + "messages", + "user_query", + "completed" + ], + "async": false, + "docstring": "Convert internal message format to trajectory format for saving.\n\nArgs:\n messages (List[Dict]): Internal message history\n user_query (str): Original user query\n completed (bool): Whether the conversation completed successfully\n \nReturns:\n List[Dict]: Messages in trajectory format" + }, + { + "name": "_save_trajectory", + "args": [ + "self", + "messages", + "user_query", + "completed" + ], + "async": false, + "docstring": "Save conversation trajectory to JSONL file.\n\nArgs:\n messages (List[Dict]): Complete message history\n user_query (str): Original user query\n completed (bool): Whether the conversation completed successfully" + }, + { + "name": "_summarize_api_error", + "args": [ + "error" + ], + "async": false, + "docstring": "Extract a human-readable one-liner from an API error.\n\nHandles Cloudflare HTML error pages (502, 503, etc.) by pulling the\n tag instead of dumping raw HTML. Falls back to a truncated\nstr(error) for everything else." + }, + { + "name": "_mask_api_key_for_logs", + "args": [ + "self", + "key" + ], + "async": false, + "docstring": null + }, + { + "name": "_clean_error_message", + "args": [ + "self", + "error_msg" + ], + "async": false, + "docstring": "Clean up error messages for user display, removing HTML content and truncating.\n\nArgs:\n error_msg: Raw error message from API or exception\n \nReturns:\n Clean, user-friendly error message" + }, + { + "name": "_dump_api_request_debug", + "args": [ + "self", + "api_kwargs" + ], + "async": false, + "docstring": "Dump a debug-friendly HTTP request record for the active inference API.\n\nCaptures the request body from api_kwargs (excluding transport-only keys\nlike timeout). Intended for debugging provider-side 4xx failures where\nretries are not useful." + }, + { + "name": "_clean_session_content", + "args": [ + "content" + ], + "async": false, + "docstring": "Convert REASONING_SCRATCHPAD to think tags and clean up whitespace." + }, + { + "name": "_save_session_log", + "args": [ + "self", + "messages" + ], + "async": false, + "docstring": "Save the full raw session to a JSON file.\n\nStores every message exactly as the agent sees it: user messages,\nassistant messages (with reasoning, finish_reason, tool_calls),\ntool responses (with tool_call_id, tool_name), and injected system\nmessages (compression summaries, todo snapshots, etc.).\n\nREASONING_SCRATCHPAD tags are converted to <think> blocks for consistency.\nOverwritten after each turn so it always reflects the latest state." + }, + { + "name": "interrupt", + "args": [ + "self", + "message" + ], + "async": false, + "docstring": "Request the agent to interrupt its current tool-calling loop.\n\nCall this from another thread (e.g., input handler, message receiver)\nto gracefully stop the agent and process a new message.\n\nAlso signals long-running tool executions (e.g. terminal commands)\nto terminate early, so the agent can respond immediately.\n\nArgs:\n message: Optional new message that triggered the interrupt.\n If provided, the agent will include this in its response context.\n\nExample (CLI):\n # In a separate input thread:\n if user_typed_something:\n agent.interrupt(user_input)\n\nExample (Messaging):\n # When new message arrives for active session:\n if session_has_running_agent:\n running_agent.interrupt(new_message.text)" + }, + { + "name": "clear_interrupt", + "args": [ + "self" + ], + "async": false, + "docstring": "Clear any pending interrupt request and the global tool interrupt signal." + }, + { + "name": "shutdown_memory_provider", + "args": [ + "self", + "messages" + ], + "async": false, + "docstring": "Shut down the memory provider \u2014 call at actual session boundaries.\n\nThis calls on_session_end() then shutdown_all() on the memory\nmanager. NOT called per-turn \u2014 only at CLI exit, /reset, gateway\nsession expiry, etc." + }, + { + "name": "_hydrate_todo_store", + "args": [ + "self", + "history" + ], + "async": false, + "docstring": "Recover todo state from conversation history.\n\nThe gateway creates a fresh AIAgent per message, so the in-memory\nTodoStore is empty. We scan the history for the most recent todo\ntool response and replay it to reconstruct the state." + }, + { + "name": "is_interrupted", + "args": [ + "self" + ], + "async": false, + "docstring": "Check if an interrupt has been requested." + }, + { + "name": "_build_system_prompt", + "args": [ + "self", + "system_message" + ], + "async": false, + "docstring": "Assemble the full system prompt from all layers.\n\nCalled once per session (cached on self._cached_system_prompt) and only\nrebuilt after context compression events. This ensures the system prompt\nis stable across all turns in a session, maximizing prefix cache hits." + }, + { + "name": "_get_tool_call_id_static", + "args": [ + "tc" + ], + "async": false, + "docstring": "Extract call ID from a tool_call entry (dict or object)." + }, + { + "name": "_sanitize_api_messages", + "args": [ + "messages" + ], + "async": false, + "docstring": "Fix orphaned tool_call / tool_result pairs before every LLM call.\n\nRuns unconditionally \u2014 not gated on whether the context compressor\nis present \u2014 so orphans from session loading or manual message\nmanipulation are always caught." + }, + { + "name": "_cap_delegate_task_calls", + "args": [ + "tool_calls" + ], + "async": false, + "docstring": "Truncate excess delegate_task calls to MAX_CONCURRENT_CHILDREN.\n\nThe delegate_tool caps the task list inside a single call, but the\nmodel can emit multiple separate delegate_task tool_calls in one\nturn. This truncates the excess, preserving all non-delegate calls.\n\nReturns the original list if no truncation was needed." + }, + { + "name": "_deduplicate_tool_calls", + "args": [ + "tool_calls" + ], + "async": false, + "docstring": "Remove duplicate (tool_name, arguments) pairs within a single turn.\n\nOnly the first occurrence of each unique pair is kept.\nReturns the original list if no duplicates were found." + }, + { + "name": "_repair_tool_call", + "args": [ + "self", + "tool_name" + ], + "async": false, + "docstring": "Attempt to repair a mismatched tool name before aborting.\n\n1. Try lowercase\n2. Try normalized (lowercase + hyphens/spaces -> underscores)\n3. Try fuzzy match (difflib, cutoff=0.7)\n\nReturns the repaired name if found in valid_tool_names, else None." + }, + { + "name": "_invalidate_system_prompt", + "args": [ + "self" + ], + "async": false, + "docstring": "Invalidate the cached system prompt, forcing a rebuild on the next turn.\n\nCalled after context compression events. Also reloads memory from disk\nso the rebuilt prompt captures any writes from this session." + }, + { + "name": "_responses_tools", + "args": [ + "self", + "tools" + ], + "async": false, + "docstring": "Convert chat-completions tool schemas to Responses function-tool schemas." + }, + { + "name": "_deterministic_call_id", + "args": [ + "fn_name", + "arguments", + "index" + ], + "async": false, + "docstring": "Generate a deterministic call_id from tool call content.\n\nUsed as a fallback when the API doesn't provide a call_id.\nDeterministic IDs prevent cache invalidation \u2014 random UUIDs would\nmake every API call's prefix unique, breaking OpenAI's prompt cache." + }, + { + "name": "_split_responses_tool_id", + "args": [ + "raw_id" + ], + "async": false, + "docstring": "Split a stored tool id into (call_id, response_item_id)." + }, + { + "name": "_derive_responses_function_call_id", + "args": [ + "self", + "call_id", + "response_item_id" + ], + "async": false, + "docstring": "Build a valid Responses `function_call.id` (must start with `fc_`)." + }, + { + "name": "_chat_messages_to_responses_input", + "args": [ + "self", + "messages" + ], + "async": false, + "docstring": "Convert internal chat-style messages to Responses input items." + }, + { + "name": "_preflight_codex_input_items", + "args": [ + "self", + "raw_items" + ], + "async": false, + "docstring": null + }, + { + "name": "_preflight_codex_api_kwargs", + "args": [ + "self", + "api_kwargs" + ], + "async": false, + "docstring": null + }, + { + "name": "_extract_responses_message_text", + "args": [ + "self", + "item" + ], + "async": false, + "docstring": "Extract assistant text from a Responses message output item." + }, + { + "name": "_extract_responses_reasoning_text", + "args": [ + "self", + "item" + ], + "async": false, + "docstring": "Extract a compact reasoning text from a Responses reasoning item." + }, + { + "name": "_normalize_codex_response", + "args": [ + "self", + "response" + ], + "async": false, + "docstring": "Normalize a Responses API object to an assistant_message-like object." + }, + { + "name": "_thread_identity", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_client_log_context", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_openai_client_lock", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_is_openai_client_closed", + "args": [ + "client" + ], + "async": false, + "docstring": "Check if an OpenAI client is closed.\n\nHandles both property and method forms of is_closed:\n- httpx.Client.is_closed is a bool property\n- openai.OpenAI.is_closed is a method returning bool\n\nPrior bug: getattr(client, \"is_closed\", False) returned the bound method,\nwhich is always truthy, causing unnecessary client recreation on every call." + }, + { + "name": "_create_openai_client", + "args": [ + "self", + "client_kwargs" + ], + "async": false, + "docstring": null + }, + { + "name": "_force_close_tcp_sockets", + "args": [ + "client" + ], + "async": false, + "docstring": "Force-close underlying TCP sockets to prevent CLOSE-WAIT accumulation.\n\nWhen a provider drops a connection mid-stream, httpx's ``client.close()``\nperforms a graceful shutdown which leaves sockets in CLOSE-WAIT until the\nOS times them out (often minutes). This method walks the httpx transport\npool and issues ``socket.shutdown(SHUT_RDWR)`` + ``socket.close()`` to\nforce an immediate TCP RST, freeing the file descriptors.\n\nReturns the number of sockets force-closed." + }, + { + "name": "_close_openai_client", + "args": [ + "self", + "client" + ], + "async": false, + "docstring": null + }, + { + "name": "_replace_primary_openai_client", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_ensure_primary_openai_client", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_cleanup_dead_connections", + "args": [ + "self" + ], + "async": false, + "docstring": "Detect and clean up dead TCP connections on the primary client.\n\nInspects the httpx connection pool for sockets in unhealthy states\n(CLOSE-WAIT, errors). If any are found, force-closes all sockets\nand rebuilds the primary client from scratch.\n\nReturns True if dead connections were found and cleaned up." + }, + { + "name": "_create_request_openai_client", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_close_request_openai_client", + "args": [ + "self", + "client" + ], + "async": false, + "docstring": null + }, + { + "name": "_run_codex_stream", + "args": [ + "self", + "api_kwargs", + "client", + "on_first_delta" + ], + "async": false, + "docstring": "Execute one streaming Responses API request and return the final response." + }, + { + "name": "_run_codex_create_stream_fallback", + "args": [ + "self", + "api_kwargs", + "client" + ], + "async": false, + "docstring": "Fallback path for stream completion edge cases on Codex-style Responses backends." + }, + { + "name": "_try_refresh_codex_client_credentials", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_try_refresh_nous_client_credentials", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_try_refresh_anthropic_client_credentials", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_apply_client_headers_for_base_url", + "args": [ + "self", + "base_url" + ], + "async": false, + "docstring": null + }, + { + "name": "_swap_credential", + "args": [ + "self", + "entry" + ], + "async": false, + "docstring": null + }, + { + "name": "_recover_with_credential_pool", + "args": [ + "self" + ], + "async": false, + "docstring": "Attempt credential recovery via pool rotation.\n\nReturns (recovered, has_retried_429).\nOn 429: first occurrence retries same credential (sets flag True).\n second consecutive 429 rotates to next credential (resets flag).\nOn 402: immediately rotates (billing exhaustion won't resolve with retry).\nOn 401: attempts token refresh before rotating." + }, + { + "name": "_anthropic_messages_create", + "args": [ + "self", + "api_kwargs" + ], + "async": false, + "docstring": null + }, + { + "name": "_interruptible_api_call", + "args": [ + "self", + "api_kwargs" + ], + "async": false, + "docstring": "Run the API call in a background thread so the main conversation loop\ncan detect interrupts without waiting for the full HTTP round-trip.\n\nEach worker thread gets its own OpenAI client instance. Interrupts only\nclose that worker-local client, so retries and other requests never\ninherit a closed transport." + }, + { + "name": "_fire_stream_delta", + "args": [ + "self", + "text" + ], + "async": false, + "docstring": "Fire all registered stream delta callbacks (display + TTS)." + }, + { + "name": "_fire_reasoning_delta", + "args": [ + "self", + "text" + ], + "async": false, + "docstring": "Fire reasoning callback if registered." + }, + { + "name": "_fire_tool_gen_started", + "args": [ + "self", + "tool_name" + ], + "async": false, + "docstring": "Notify display layer that the model is generating tool call arguments.\n\nFires once per tool name when the streaming response begins producing\ntool_call / tool_use tokens. Gives the TUI a chance to show a spinner\nor status line so the user isn't staring at a frozen screen while a\nlarge tool payload (e.g. a 45 KB write_file) is being generated." + }, + { + "name": "_has_stream_consumers", + "args": [ + "self" + ], + "async": false, + "docstring": "Return True if any streaming consumer is registered." + }, + { + "name": "_interruptible_streaming_api_call", + "args": [ + "self", + "api_kwargs" + ], + "async": false, + "docstring": "Streaming variant of _interruptible_api_call for real-time token delivery.\n\nHandles all three api_modes:\n- chat_completions: stream=True on OpenAI-compatible endpoints\n- anthropic_messages: client.messages.stream() via Anthropic SDK\n- codex_responses: delegates to _run_codex_stream (already streaming)\n\nFires stream_delta_callback and _stream_callback for each text token.\nTool-call turns suppress the callback \u2014 only text-only final responses\nstream to the consumer. Returns a SimpleNamespace that mimics the\nnon-streaming response shape so the rest of the agent loop is unchanged.\n\nFalls back to _interruptible_api_call on provider errors indicating\nstreaming is not supported." + }, + { + "name": "_try_activate_fallback", + "args": [ + "self" + ], + "async": false, + "docstring": "Switch to the next fallback model/provider in the chain.\n\nCalled when the current model is failing after retries. Swaps the\nOpenAI client, model slug, and provider in-place so the retry loop\ncan continue with the new backend. Advances through the chain on\neach call; returns False when exhausted.\n\nUses the centralized provider router (resolve_provider_client) for\nauth resolution and client construction \u2014 no duplicated provider\u2192key\nmappings." + }, + { + "name": "_restore_primary_runtime", + "args": [ + "self" + ], + "async": false, + "docstring": "Restore the primary runtime at the start of a new turn.\n\nIn long-lived CLI sessions a single AIAgent instance spans multiple\nturns. Without restoration, one transient failure pins the session\nto the fallback provider for every subsequent turn. Calling this at\nthe top of ``run_conversation()`` makes fallback turn-scoped.\n\nThe gateway creates a fresh agent per message so this is a no-op\nthere (``_fallback_activated`` is always False at turn start)." + }, + { + "name": "_try_recover_primary_transport", + "args": [ + "self", + "api_error" + ], + "async": false, + "docstring": "Attempt one extra primary-provider recovery cycle for transient transport failures.\n\nAfter ``max_retries`` exhaust, rebuild the primary client (clearing\nstale connection pools) and give it one more attempt before falling\nback. This is most useful for direct endpoints (custom, Z.AI,\nAnthropic, OpenAI, local models) where a TCP-level hiccup does not\nmean the provider is down.\n\nSkipped for proxy/aggregator providers (OpenRouter, Nous) which\nalready manage connection pools and retries server-side \u2014 if our\nretries through them are exhausted, one more rebuilt client won't help." + }, + { + "name": "_content_has_image_parts", + "args": [ + "content" + ], + "async": false, + "docstring": null + }, + { + "name": "_materialize_data_url_for_vision", + "args": [ + "image_url" + ], + "async": false, + "docstring": null + }, + { + "name": "_describe_image_for_anthropic_fallback", + "args": [ + "self", + "image_url", + "role" + ], + "async": false, + "docstring": null + }, + { + "name": "_preprocess_anthropic_content", + "args": [ + "self", + "content", + "role" + ], + "async": false, + "docstring": null + }, + { + "name": "_prepare_anthropic_messages_for_api", + "args": [ + "self", + "api_messages" + ], + "async": false, + "docstring": null + }, + { + "name": "_anthropic_preserve_dots", + "args": [ + "self" + ], + "async": false, + "docstring": "True when using Alibaba/DashScope anthropic-compatible endpoint (model names keep dots, e.g. qwen3.5-plus)." + }, + { + "name": "_build_api_kwargs", + "args": [ + "self", + "api_messages" + ], + "async": false, + "docstring": "Build the keyword arguments dict for the active API mode." + }, + { + "name": "_supports_reasoning_extra_body", + "args": [ + "self" + ], + "async": false, + "docstring": "Return True when reasoning extra_body is safe to send for this route/model.\n\nOpenRouter forwards unknown extra_body fields to upstream providers.\nSome providers/routes reject `reasoning` with 400s, so gate it to\nknown reasoning-capable model families and direct Nous Portal." + }, + { + "name": "_github_models_reasoning_extra_body", + "args": [ + "self" + ], + "async": false, + "docstring": "Format reasoning payload for GitHub Models/OpenAI-compatible routes." + }, + { + "name": "_build_assistant_message", + "args": [ + "self", + "assistant_message", + "finish_reason" + ], + "async": false, + "docstring": "Build a normalized assistant message dict from an API response message.\n\nHandles reasoning extraction, reasoning_details, and optional tool_calls\nso both the tool-call path and the final-response path share one builder." + }, + { + "name": "_sanitize_tool_calls_for_strict_api", + "args": [ + "api_msg" + ], + "async": false, + "docstring": "Strip Codex Responses API fields from tool_calls for strict providers.\n\nProviders like Mistral strictly validate the Chat Completions schema\nand reject unknown fields (call_id, response_item_id) with 422.\nThese fields are preserved in the internal message history \u2014 this\nmethod only modifies the outgoing API copy.\n\nCreates new tool_call dicts rather than mutating in-place, so the\noriginal messages list retains call_id/response_item_id for Codex\nResponses API compatibility (e.g. if the session falls back to a\nCodex provider later)." + }, + { + "name": "flush_memories", + "args": [ + "self", + "messages", + "min_turns" + ], + "async": false, + "docstring": "Give the model one turn to persist memories before context is lost.\n\nCalled before compression, session reset, or CLI exit. Injects a flush\nmessage, makes one API call, executes any memory tool calls, then\nstrips all flush artifacts from the message list.\n\nArgs:\n messages: The current conversation messages. If None, uses\n self._session_messages (last run_conversation state).\n min_turns: Minimum user turns required to trigger the flush.\n None = use config value (flush_min_turns).\n 0 = always flush (used for compression)." + }, + { + "name": "_compress_context", + "args": [ + "self", + "messages", + "system_message" + ], + "async": false, + "docstring": "Compress conversation context and split the session in SQLite.\n\nReturns:\n (compressed_messages, new_system_prompt) tuple" + }, + { + "name": "_execute_tool_calls", + "args": [ + "self", + "assistant_message", + "messages", + "effective_task_id", + "api_call_count" + ], + "async": false, + "docstring": "Execute tool calls from the assistant message and append results to messages.\n\nDispatches to concurrent execution only for batches that look\nindependent: read-only tools may always share the parallel path, while\nfile reads/writes may do so only when their target paths do not overlap." + }, + { + "name": "_invoke_tool", + "args": [ + "self", + "function_name", + "function_args", + "effective_task_id" + ], + "async": false, + "docstring": "Invoke a single tool and return the result string. No display logic.\n\nHandles both agent-level tools (todo, memory, etc.) and registry-dispatched\ntools. Used by the concurrent execution path; the sequential path retains\nits own inline invocation for backward-compatible display handling." + }, + { + "name": "_execute_tool_calls_concurrent", + "args": [ + "self", + "assistant_message", + "messages", + "effective_task_id", + "api_call_count" + ], + "async": false, + "docstring": "Execute multiple tool calls concurrently using a thread pool.\n\nResults are collected in the original tool-call order and appended to\nmessages so the API sees them in the expected sequence." + }, + { + "name": "_execute_tool_calls_sequential", + "args": [ + "self", + "assistant_message", + "messages", + "effective_task_id", + "api_call_count" + ], + "async": false, + "docstring": "Execute tool calls sequentially (original behavior). Used for single calls or interactive tools." + }, + { + "name": "_get_budget_warning", + "args": [ + "self", + "api_call_count" + ], + "async": false, + "docstring": "Return a budget pressure string, or None if not yet needed.\n\nTwo-tier system:\n - Caution (70%): nudge to consolidate work\n - Warning (90%): urgent, must respond now" + }, + { + "name": "_emit_context_pressure", + "args": [ + "self", + "compaction_progress", + "compressor" + ], + "async": false, + "docstring": "Notify the user that context is approaching the compaction threshold.\n\nArgs:\n compaction_progress: How close to compaction (0.0\u20131.0, where 1.0 = fires).\n compressor: The ContextCompressor instance (for threshold/context info).\n\nPurely user-facing \u2014 does NOT modify the message stream.\nFor CLI: prints a formatted line with a progress bar.\nFor gateway: fires status_callback so the platform can send a chat message." + }, + { + "name": "_handle_max_iterations", + "args": [ + "self", + "messages", + "api_call_count" + ], + "async": false, + "docstring": "Request a summary when max iterations are reached. Returns the final response text." + }, + { + "name": "run_conversation", + "args": [ + "self", + "user_message", + "system_message", + "conversation_history", + "task_id", + "stream_callback", + "persist_user_message" + ], + "async": false, + "docstring": "Run a complete conversation with tool calling until completion.\n\nArgs:\n user_message (str): The user's message/question\n system_message (str): Custom system message (optional, overrides ephemeral_system_prompt if provided)\n conversation_history (List[Dict]): Previous conversation messages (optional)\n task_id (str): Unique identifier for this task to isolate VMs between concurrent tasks (optional, auto-generated if not provided)\n stream_callback: Optional callback invoked with each text delta during streaming.\n Used by the TTS pipeline to start audio generation before the full response.\n When None (default), API calls use the standard non-streaming path.\n persist_user_message: Optional clean user message to store in\n transcripts/history when user_message contains API-only\n synthetic prefixes.\n or queuing follow-up prefetch work.\n\nReturns:\n Dict: Complete conversation result with final response and message history" + }, + { + "name": "chat", + "args": [ + "self", + "message", + "stream_callback" + ], + "async": false, + "docstring": "Simple chat interface that returns just the final response.\n\nArgs:\n message (str): User message\n stream_callback: Optional callback invoked with each text delta during streaming.\n\nReturns:\n str: Final assistant response" + } + ], + "docstring": "AI Agent with tool calling capabilities.\n\nThis class manages the conversation flow, tool execution, and response handling\nfor AI models that support function calling." + } + ], + "functions": [ + { + "name": "_install_safe_stdio", + "args": [], + "async": false, + "docstring": "Wrap stdout/stderr so best-effort console output cannot crash the agent." + }, + { + "name": "_is_destructive_command", + "args": [ + "cmd" + ], + "async": false, + "docstring": "Heuristic: does this terminal command look like it modifies/deletes files?" + }, + { + "name": "_should_parallelize_tool_batch", + "args": [ + "tool_calls" + ], + "async": false, + "docstring": "Return True when a tool-call batch is safe to run concurrently." + }, + { + "name": "_extract_parallel_scope_path", + "args": [ + "tool_name", + "function_args" + ], + "async": false, + "docstring": "Return the normalized file target for path-scoped tools." + }, + { + "name": "_paths_overlap", + "args": [ + "left", + "right" + ], + "async": false, + "docstring": "Return True when two paths may refer to the same subtree." + }, + { + "name": "_sanitize_surrogates", + "args": [ + "text" + ], + "async": false, + "docstring": "Replace lone surrogate code points with U+FFFD (replacement character).\n\nSurrogates are invalid in UTF-8 and will crash ``json.dumps()`` inside the\nOpenAI SDK. This is a fast no-op when the text contains no surrogates." + }, + { + "name": "_sanitize_messages_surrogates", + "args": [ + "messages" + ], + "async": false, + "docstring": "Sanitize surrogate characters from all string content in a messages list.\n\nWalks message dicts in-place. Returns True if any surrogates were found\nand replaced, False otherwise." + }, + { + "name": "_strip_budget_warnings_from_history", + "args": [ + "messages" + ], + "async": false, + "docstring": "Remove budget pressure warnings from tool-result messages in-place.\n\nBudget warnings are turn-scoped signals that must not leak into replayed\nhistory. They live in tool-result ``content`` either as a JSON key\n(``_budget_warning``) or appended plain text." + }, + { + "name": "main", + "args": [ + "query", + "model", + "api_key", + "base_url", + "max_turns", + "enabled_toolsets", + "disabled_toolsets", + "list_tools", + "save_trajectories", + "save_sample", + "verbose", + "log_prefix_chars" + ], + "async": false, + "docstring": "Main function for running the agent directly.\n\nArgs:\n query (str): Natural language query for the agent. Defaults to Python 3.13 example.\n model (str): Model name to use (OpenRouter format: provider/model). Defaults to anthropic/claude-sonnet-4.6.\n api_key (str): API key for authentication. Uses OPENROUTER_API_KEY env var if not provided.\n base_url (str): Base URL for the model API. Defaults to https://openrouter.ai/api/v1\n max_turns (int): Maximum number of API call iterations. Defaults to 10.\n enabled_toolsets (str): Comma-separated list of toolsets to enable. Supports predefined\n toolsets (e.g., \"research\", \"development\", \"safe\").\n Multiple toolsets can be combined: \"web,vision\"\n disabled_toolsets (str): Comma-separated list of toolsets to disable (e.g., \"terminal\")\n list_tools (bool): Just list available tools and exit\n save_trajectories (bool): Save conversation trajectories to JSONL files (appends to trajectory_samples.jsonl). Defaults to False.\n save_sample (bool): Save a single trajectory sample to a UUID-named JSONL file for inspection. Defaults to False.\n verbose (bool): Enable verbose logging for debugging. Defaults to False.\n log_prefix_chars (int): Number of characters to show in log previews for tool calls/responses. Defaults to 20.\n\nToolset Examples:\n - \"research\": Web search, extract, crawl + vision tools" + } + ], + "imports": [ + "atexit", + "asyncio", + "base64", + "concurrent.futures", + "copy", + "hashlib", + "json", + "logging", + "os", + "random", + "re", + "sys", + "tempfile", + "time", + "threading", + "weakref", + "from types import SimpleNamespace", + "uuid", + "from typing import List, Dict, Any, Optional", + "from openai import OpenAI", + "fire", + "from datetime import datetime", + "from pathlib import Path", + "from hermes_constants import get_hermes_home", + "from hermes_cli.env_loader import load_hermes_dotenv", + "from model_tools import get_tool_definitions, get_toolset_for_tool, handle_function_call, check_toolset_requirements", + "from tools.terminal_tool import cleanup_vm", + "from tools.interrupt import set_interrupt", + "from tools.browser_tool import cleanup_browser", + "from hermes_constants import OPENROUTER_BASE_URL", + "from agent.prompt_builder import DEFAULT_AGENT_IDENTITY, PLATFORM_HINTS, MEMORY_GUIDANCE, SESSION_SEARCH_GUIDANCE, SKILLS_GUIDANCE, build_nous_subscription_prompt", + "from agent.model_metadata import fetch_model_metadata, estimate_tokens_rough, estimate_messages_tokens_rough, estimate_request_tokens_rough, get_next_probe_tier, parse_context_limit_from_error, save_context_length, is_local_endpoint", + "from agent.context_compressor import ContextCompressor", + "from agent.prompt_caching import apply_anthropic_cache_control", + "from agent.prompt_builder import build_skills_system_prompt, build_context_files_prompt, load_soul_md, TOOL_USE_ENFORCEMENT_GUIDANCE, TOOL_USE_ENFORCEMENT_MODELS, DEVELOPER_ROLE_MODELS, GOOGLE_MODEL_OPERATIONAL_GUIDANCE", + "from agent.usage_pricing import estimate_usage_cost, normalize_usage", + "from agent.display import KawaiiSpinner, build_tool_preview, get_cute_tool_message, _detect_tool_failure, get_tool_emoji", + "from agent.trajectory import convert_scratchpad_to_think, has_incomplete_scratchpad, save_trajectory", + "from utils import atomic_json_write, env_var_enabled" + ], + "loc": 8948 + }, + "model_tools.py": { + "path": "model_tools.py", + "classes": [], + "functions": [ + { + "name": "_get_tool_loop", + "args": [], + "async": false, + "docstring": "Return a long-lived event loop for running async tool handlers.\n\nUsing a persistent loop (instead of asyncio.run() which creates and\n*closes* a fresh loop every time) prevents \"Event loop is closed\"\nerrors that occur when cached httpx/AsyncOpenAI clients attempt to\nclose their transport on a dead loop during garbage collection." + }, + { + "name": "_get_worker_loop", + "args": [], + "async": false, + "docstring": "Return a persistent event loop for the current worker thread.\n\nEach worker thread (e.g., delegate_task's ThreadPoolExecutor threads)\ngets its own long-lived loop stored in thread-local storage. This\nprevents the \"Event loop is closed\" errors that occurred when\nasyncio.run() was used per-call: asyncio.run() creates a loop, runs\nthe coroutine, then *closes* the loop \u2014 but cached httpx/AsyncOpenAI\nclients remain bound to that now-dead loop and raise RuntimeError\nduring garbage collection or subsequent use.\n\nBy keeping the loop alive for the thread's lifetime, cached clients\nstay valid and their cleanup runs on a live loop." + }, + { + "name": "_run_async", + "args": [ + "coro" + ], + "async": false, + "docstring": "Run an async coroutine from a sync context.\n\nIf the current thread already has a running event loop (e.g., inside\nthe gateway's async stack or Atropos's event loop), we spin up a\ndisposable thread so asyncio.run() can create its own loop without\nconflicting.\n\nFor the common CLI path (no running loop), we use a persistent event\nloop so that cached async clients (httpx / AsyncOpenAI) remain bound\nto a live loop and don't trigger \"Event loop is closed\" on GC.\n\nWhen called from a worker thread (parallel tool execution), we use a\nper-thread persistent loop to avoid both contention with the main\nthread's shared loop AND the \"Event loop is closed\" errors caused by\nasyncio.run()'s create-and-destroy lifecycle.\n\nThis is the single source of truth for sync->async bridging in tool\nhandlers. The RL paths (agent_loop.py, tool_context.py) also provide\nouter thread-pool wrapping as defense-in-depth, but each handler is\nself-protecting via this function." + }, + { + "name": "_discover_tools", + "args": [], + "async": false, + "docstring": "Import all tool modules to trigger their registry.register() calls.\n\nWrapped in a function so import errors in optional tools (e.g., fal_client\nnot installed) don't prevent the rest from loading." + }, + { + "name": "get_tool_definitions", + "args": [ + "enabled_toolsets", + "disabled_toolsets", + "quiet_mode" + ], + "async": false, + "docstring": "Get tool definitions for model API calls with toolset-based filtering.\n\nAll tools must be part of a toolset to be accessible.\n\nArgs:\n enabled_toolsets: Only include tools from these toolsets.\n disabled_toolsets: Exclude tools from these toolsets (if enabled_toolsets is None).\n quiet_mode: Suppress status prints.\n\nReturns:\n Filtered list of OpenAI-format tool definitions." + }, + { + "name": "handle_function_call", + "args": [ + "function_name", + "function_args", + "task_id", + "user_task", + "enabled_tools" + ], + "async": false, + "docstring": "Main function call dispatcher that routes calls to the tool registry.\n\nArgs:\n function_name: Name of the function to call.\n function_args: Arguments for the function.\n task_id: Unique identifier for terminal/browser session isolation.\n user_task: The user's original task (for browser_snapshot context).\n enabled_tools: Tool names enabled for this session. When provided,\n execute_code uses this list to determine which sandbox\n tools to generate. Falls back to the process-global\n ``_last_resolved_tool_names`` for backward compat.\n\nReturns:\n Function result as a JSON string." + }, + { + "name": "get_all_tool_names", + "args": [], + "async": false, + "docstring": "Return all registered tool names." + }, + { + "name": "get_toolset_for_tool", + "args": [ + "tool_name" + ], + "async": false, + "docstring": "Return the toolset a tool belongs to." + }, + { + "name": "get_available_toolsets", + "args": [], + "async": false, + "docstring": "Return toolset availability info for UI display." + }, + { + "name": "check_toolset_requirements", + "args": [], + "async": false, + "docstring": "Return {toolset: available_bool} for every registered toolset." + }, + { + "name": "check_tool_availability", + "args": [ + "quiet" + ], + "async": false, + "docstring": "Return (available_toolsets, unavailable_info)." + } + ], + "imports": [ + "json", + "asyncio", + "logging", + "threading", + "from typing import Dict, Any, List, Optional, Tuple", + "from tools.registry import registry", + "from toolsets import resolve_toolset, validate_toolset" + ], + "loc": 466 + }, + "cli.py": { + "path": "cli.py", + "classes": [ + { + "name": "ChatConsole", + "methods": [ + { + "name": "__init__", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "print", + "args": [ + "self" + ], + "async": false, + "docstring": null + } + ], + "docstring": "Rich Console adapter for prompt_toolkit's patch_stdout context.\n\nCaptures Rich's rendered ANSI output and routes it through _cprint\nso colors and markup render correctly inside the interactive chat loop.\nDrop-in replacement for Rich Console \u2014 just pass this to any function\nthat expects a console.print() interface." + }, + { + "name": "HermesCLI", + "methods": [ + { + "name": "__init__", + "args": [ + "self", + "model", + "toolsets", + "provider", + "api_key", + "base_url", + "max_turns", + "verbose", + "compact", + "resume", + "checkpoints", + "pass_session_id" + ], + "async": false, + "docstring": "Initialize the Hermes CLI.\n\nArgs:\n model: Model to use (default: from env or claude-sonnet)\n toolsets: List of toolsets to enable (default: all)\n provider: Inference provider (\"auto\", \"openrouter\", \"nous\", \"openai-codex\", \"zai\", \"kimi-coding\", \"minimax\", \"minimax-cn\")\n api_key: API key (default: from environment)\n base_url: API base URL (default: OpenRouter)\n max_turns: Maximum tool-calling iterations shared with subagents (default: 90)\n verbose: Enable verbose logging\n compact: Use compact display mode\n resume: Session ID to resume (restores conversation history from SQLite)\n pass_session_id: Include the session ID in the agent's system prompt" + }, + { + "name": "_invalidate", + "args": [ + "self", + "min_interval" + ], + "async": false, + "docstring": "Throttled UI repaint \u2014 prevents terminal blinking on slow/SSH connections." + }, + { + "name": "_status_bar_context_style", + "args": [ + "self", + "percent_used" + ], + "async": false, + "docstring": null + }, + { + "name": "_build_context_bar", + "args": [ + "self", + "percent_used", + "width" + ], + "async": false, + "docstring": null + }, + { + "name": "_get_status_bar_snapshot", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_status_bar_display_width", + "args": [ + "text" + ], + "async": false, + "docstring": "Return terminal cell width for status-bar text.\n\nlen() is not enough for prompt_toolkit layout decisions because some\nglyphs can render wider than one Python codepoint. Keeping the status\nbar within the real display width prevents it from wrapping onto a\nsecond line and leaving behind duplicate rows." + }, + { + "name": "_trim_status_bar_text", + "args": [ + "cls", + "text", + "max_width" + ], + "async": false, + "docstring": "Trim status-bar text to a single terminal row." + }, + { + "name": "_build_status_bar_text", + "args": [ + "self", + "width" + ], + "async": false, + "docstring": null + }, + { + "name": "_get_status_bar_fragments", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_normalize_model_for_provider", + "args": [ + "self", + "resolved_provider" + ], + "async": false, + "docstring": "Normalize provider-specific model IDs and routing." + }, + { + "name": "_on_thinking", + "args": [ + "self", + "text" + ], + "async": false, + "docstring": "Called by agent when thinking starts/stops. Updates TUI spinner." + }, + { + "name": "_current_reasoning_callback", + "args": [ + "self" + ], + "async": false, + "docstring": "Return the active reasoning display callback for the current mode." + }, + { + "name": "_emit_reasoning_preview", + "args": [ + "self", + "reasoning_text" + ], + "async": false, + "docstring": "Render a buffered reasoning preview as a single [thinking] block." + }, + { + "name": "_flush_reasoning_preview", + "args": [ + "self" + ], + "async": false, + "docstring": "Flush buffered reasoning text at natural boundaries.\n\nSome providers stream reasoning in tiny word or punctuation chunks.\nBuffer them here so the preview path does not print one `[thinking]`\nline per token." + }, + { + "name": "_stream_reasoning_delta", + "args": [ + "self", + "text" + ], + "async": false, + "docstring": "Stream reasoning/thinking tokens into a dim box above the response.\n\nOpens a dim reasoning box on first token, streams line-by-line.\nThe box is closed automatically when content tokens start arriving\n(via _stream_delta \u2192 _emit_stream_text).\n\nOnce the response box is open, suppress any further reasoning\nrendering \u2014 a late thinking block (e.g. after an interrupt) would\notherwise draw a reasoning box inside the response box." + }, + { + "name": "_close_reasoning_box", + "args": [ + "self" + ], + "async": false, + "docstring": "Close the live reasoning box if it's open." + }, + { + "name": "_stream_delta", + "args": [ + "self", + "text" + ], + "async": false, + "docstring": "Line-buffered streaming callback for real-time token rendering.\n\nReceives text deltas from the agent as tokens arrive. Buffers\npartial lines and emits complete lines via _cprint to work\nreliably with prompt_toolkit's patch_stdout.\n\nReasoning/thinking blocks (<REASONING_SCRATCHPAD>, <think>, etc.)\nare suppressed during streaming since they'd display raw XML tags.\nThe agent strips them from the final response anyway.\n\nA ``None`` value signals an intermediate turn boundary (tools are\nabout to execute). Flushes any open boxes and resets state so\ntool feed lines render cleanly between turns." + }, + { + "name": "_emit_stream_text", + "args": [ + "self", + "text" + ], + "async": false, + "docstring": "Emit filtered text to the streaming display." + }, + { + "name": "_flush_stream", + "args": [ + "self" + ], + "async": false, + "docstring": "Emit any remaining partial line from the stream buffer and close the box." + }, + { + "name": "_reset_stream_state", + "args": [ + "self" + ], + "async": false, + "docstring": "Reset streaming state before each agent invocation." + }, + { + "name": "_slow_command_status", + "args": [ + "self", + "command" + ], + "async": false, + "docstring": "Return a user-facing status message for slower slash commands." + }, + { + "name": "_command_spinner_frame", + "args": [ + "self" + ], + "async": false, + "docstring": "Return the current spinner frame for slow slash commands." + }, + { + "name": "_busy_command", + "args": [ + "self", + "status" + ], + "async": false, + "docstring": "Expose a temporary busy state in the TUI while a slash command runs." + }, + { + "name": "_ensure_runtime_credentials", + "args": [ + "self" + ], + "async": false, + "docstring": "Ensure runtime credentials are resolved before agent use.\nRe-resolves provider credentials so key rotation and token refresh\nare picked up without restarting the CLI.\nReturns True if credentials are ready, False on auth failure." + }, + { + "name": "_resolve_turn_agent_config", + "args": [ + "self", + "user_message" + ], + "async": false, + "docstring": "Resolve model/runtime overrides for a single user turn." + }, + { + "name": "_init_agent", + "args": [ + "self" + ], + "async": false, + "docstring": "Initialize the agent on first use.\nWhen resuming a session, restores conversation history from SQLite.\n\nReturns:\n bool: True if successful, False otherwise" + }, + { + "name": "show_banner", + "args": [ + "self" + ], + "async": false, + "docstring": "Display the welcome banner in Claude Code style." + }, + { + "name": "_preload_resumed_session", + "args": [ + "self" + ], + "async": false, + "docstring": "Load a resumed session's history from the DB early (before first chat).\n\nCalled from run() so the conversation history is available for display\nbefore the user sends their first message. Sets\n``self.conversation_history`` and prints the one-liner status. Returns\nTrue if history was loaded, False otherwise.\n\nThe corresponding block in ``_init_agent()`` checks whether history is\nalready populated and skips the DB round-trip." + }, + { + "name": "_display_resumed_history", + "args": [ + "self" + ], + "async": false, + "docstring": "Render a compact recap of previous conversation messages.\n\nUses Rich markup with dim/muted styling so the recap is visually\ndistinct from the active conversation. Caps the display at the\nlast ``MAX_DISPLAY_EXCHANGES`` user/assistant exchanges and shows\nan indicator for earlier hidden messages." + }, + { + "name": "_try_attach_clipboard_image", + "args": [ + "self" + ], + "async": false, + "docstring": "Check clipboard for an image and attach it if found.\n\nSaves the image to ~/.hermes/images/ and appends the path to\n``_attached_images``. Returns True if an image was attached." + }, + { + "name": "_handle_rollback_command", + "args": [ + "self", + "command" + ], + "async": false, + "docstring": "Handle /rollback \u2014 list, diff, or restore filesystem checkpoints.\n\nSyntax:\n /rollback \u2014 list checkpoints\n /rollback <N> \u2014 restore checkpoint N (also undoes last chat turn)\n /rollback diff <N> \u2014 preview changes since checkpoint N\n /rollback <N> <file> \u2014 restore a single file from checkpoint N" + }, + { + "name": "_resolve_checkpoint_ref", + "args": [ + "self", + "ref", + "checkpoints" + ], + "async": false, + "docstring": "Resolve a checkpoint number or hash to a full commit hash." + }, + { + "name": "_handle_stop_command", + "args": [ + "self" + ], + "async": false, + "docstring": "Handle /stop \u2014 kill all running background processes.\n\nInspired by OpenAI Codex's separation of interrupt (stop current turn)\nfrom /stop (clean up background processes). See openai/codex#14602." + }, + { + "name": "_handle_paste_command", + "args": [ + "self" + ], + "async": false, + "docstring": "Handle /paste \u2014 explicitly check clipboard for an image.\n\nThis is the reliable fallback for terminals where BracketedPaste\ndoesn't fire for image-only clipboard content (e.g., VSCode terminal,\nWindows Terminal with WSL2)." + }, + { + "name": "_preprocess_images_with_vision", + "args": [ + "self", + "text", + "images" + ], + "async": false, + "docstring": "Analyze attached images via the vision tool and return enriched text.\n\nInstead of embedding raw base64 ``image_url`` content parts in the\nconversation (which only works with vision-capable models), this\npre-processes each image through the auxiliary vision model (Gemini\nFlash) and prepends the descriptions to the user's message \u2014 the\nsame approach the messaging gateway uses.\n\nThe local file path is included so the agent can re-examine the\nimage later with ``vision_analyze`` if needed." + }, + { + "name": "_show_tool_availability_warnings", + "args": [ + "self" + ], + "async": false, + "docstring": "Show warnings about disabled tools due to missing API keys." + }, + { + "name": "_show_status", + "args": [ + "self" + ], + "async": false, + "docstring": "Show current status bar." + }, + { + "name": "show_help", + "args": [ + "self" + ], + "async": false, + "docstring": "Display help information with categorized commands." + }, + { + "name": "show_tools", + "args": [ + "self" + ], + "async": false, + "docstring": "Display available tools with kawaii ASCII art." + }, + { + "name": "_handle_tools_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle /tools [list|disable|enable] slash commands.\n\n/tools (no args) shows the tool list.\n/tools list shows enabled/disabled status per toolset.\n/tools disable/enable saves the change to config and resets\nthe session so the new tool set takes effect cleanly (no\nprompt-cache breakage mid-conversation)." + }, + { + "name": "show_toolsets", + "args": [ + "self" + ], + "async": false, + "docstring": "Display available toolsets with kawaii ASCII art." + }, + { + "name": "_handle_profile_command", + "args": [ + "self" + ], + "async": false, + "docstring": "Display active profile name and home directory." + }, + { + "name": "show_config", + "args": [ + "self" + ], + "async": false, + "docstring": "Display current configuration with kawaii ASCII art." + }, + { + "name": "_list_recent_sessions", + "args": [ + "self", + "limit" + ], + "async": false, + "docstring": "Return recent CLI sessions for in-chat browsing/resume affordances." + }, + { + "name": "_show_recent_sessions", + "args": [ + "self" + ], + "async": false, + "docstring": "Render recent sessions inline from the active chat TUI.\n\nReturns True when something was shown, False if no session list was available." + }, + { + "name": "show_history", + "args": [ + "self" + ], + "async": false, + "docstring": "Display conversation history." + }, + { + "name": "new_session", + "args": [ + "self", + "silent" + ], + "async": false, + "docstring": "Start a fresh session with a new session ID and cleared agent state." + }, + { + "name": "_handle_resume_command", + "args": [ + "self", + "cmd_original" + ], + "async": false, + "docstring": "Handle /resume <session_id_or_title> \u2014 switch to a previous session mid-conversation." + }, + { + "name": "_handle_branch_command", + "args": [ + "self", + "cmd_original" + ], + "async": false, + "docstring": "Handle /branch [name] \u2014 fork the current session into a new independent copy.\n\nCopies the full conversation history to a new session so the user can\nexplore a different approach without losing the original session state.\nInspired by Claude Code's /branch command." + }, + { + "name": "reset_conversation", + "args": [ + "self" + ], + "async": false, + "docstring": "Reset the conversation by starting a new session." + }, + { + "name": "save_conversation", + "args": [ + "self" + ], + "async": false, + "docstring": "Save the current conversation to a file." + }, + { + "name": "retry_last", + "args": [ + "self" + ], + "async": false, + "docstring": "Retry the last user message by removing the last exchange and re-sending.\n\nRemoves the last assistant response (and any tool-call messages) and\nthe last user message, then re-sends that user message to the agent.\nReturns the message to re-send, or None if there's nothing to retry." + }, + { + "name": "undo_last", + "args": [ + "self" + ], + "async": false, + "docstring": "Remove the last user/assistant exchange from conversation history.\n\nWalks backwards and removes all messages from the last user message\nonward (including assistant responses, tool calls, etc.)." + }, + { + "name": "_show_model_and_providers", + "args": [ + "self" + ], + "async": false, + "docstring": "Show current model + provider and list all authenticated providers.\n\nShows current model + provider, then lists all authenticated\nproviders with their available models." + }, + { + "name": "_handle_prompt_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle the /prompt command to view or set system prompt." + }, + { + "name": "_resolve_personality_prompt", + "args": [ + "value" + ], + "async": false, + "docstring": "Accept string or dict personality value; return system prompt string." + }, + { + "name": "_handle_personality_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle the /personality command to set predefined personalities." + }, + { + "name": "_handle_cron_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle the /cron command to manage scheduled tasks." + }, + { + "name": "_handle_skills_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle /skills slash command \u2014 delegates to hermes_cli.skills_hub." + }, + { + "name": "_show_gateway_status", + "args": [ + "self" + ], + "async": false, + "docstring": "Show status of the gateway and connected messaging platforms." + }, + { + "name": "process_command", + "args": [ + "self", + "command" + ], + "async": false, + "docstring": "Process a slash command.\n\nArgs:\n command: The command string (starting with /)\n \nReturns:\n bool: True to continue, False to exit" + }, + { + "name": "_handle_plan_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle /plan [request] \u2014 load the bundled plan skill." + }, + { + "name": "_handle_background_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle /background <prompt> \u2014 run a prompt in a separate background session.\n\nSpawns a new AIAgent in a background thread with its own session.\nWhen it completes, prints the result to the CLI without modifying\nthe active session's conversation history." + }, + { + "name": "_handle_btw_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle /btw <question> \u2014 ephemeral side question using session context.\n\nSnapshots the current conversation history, spawns a no-tools agent in\na background thread, and prints the answer without persisting anything\nto the main session." + }, + { + "name": "_try_launch_chrome_debug", + "args": [ + "port", + "system" + ], + "async": false, + "docstring": "Try to launch Chrome/Chromium with remote debugging enabled.\n\nReturns True if a launch command was executed (doesn't guarantee success)." + }, + { + "name": "_handle_browser_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle /browser connect|disconnect|status \u2014 manage live Chrome CDP connection." + }, + { + "name": "_handle_skin_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle /skin [name] \u2014 show or change the display skin." + }, + { + "name": "_toggle_verbose", + "args": [ + "self" + ], + "async": false, + "docstring": "Cycle tool progress mode: off \u2192 new \u2192 all \u2192 verbose \u2192 off." + }, + { + "name": "_toggle_yolo", + "args": [ + "self" + ], + "async": false, + "docstring": "Toggle YOLO mode \u2014 skip all dangerous command approval prompts." + }, + { + "name": "_handle_reasoning_command", + "args": [ + "self", + "cmd" + ], + "async": false, + "docstring": "Handle /reasoning \u2014 manage effort level and display toggle.\n\nUsage:\n /reasoning Show current effort level and display state\n /reasoning <level> Set reasoning effort (none, low, medium, high, xhigh)\n /reasoning show|on Show model thinking/reasoning in output\n /reasoning hide|off Hide model thinking/reasoning from output" + }, + { + "name": "_on_reasoning", + "args": [ + "self", + "reasoning_text" + ], + "async": false, + "docstring": "Callback for intermediate reasoning display during tool-call loops." + }, + { + "name": "_manual_compress", + "args": [ + "self" + ], + "async": false, + "docstring": "Manually trigger context compression on the current conversation." + }, + { + "name": "_show_usage", + "args": [ + "self" + ], + "async": false, + "docstring": "Show cumulative token usage for the current session." + }, + { + "name": "_show_insights", + "args": [ + "self", + "command" + ], + "async": false, + "docstring": "Show usage insights and analytics from session history." + }, + { + "name": "_check_config_mcp_changes", + "args": [ + "self" + ], + "async": false, + "docstring": "Detect mcp_servers changes in config.yaml and auto-reload MCP connections.\n\nCalled from process_loop every CONFIG_WATCH_INTERVAL seconds.\nCompares config.yaml mtime + mcp_servers section against the last\nknown state. When a change is detected, triggers _reload_mcp() and\ninforms the user so they know the tool list has been refreshed." + }, + { + "name": "_reload_mcp", + "args": [ + "self" + ], + "async": false, + "docstring": "Reload MCP servers: disconnect all, re-read config.yaml, reconnect.\n\nAfter reconnecting, refreshes the agent's tool list so the model\nsees the updated tools on the next turn." + }, + { + "name": "_on_tool_gen_start", + "args": [ + "self", + "tool_name" + ], + "async": false, + "docstring": "Called when the model begins generating tool-call arguments.\n\nCloses any open streaming boxes (reasoning / response) exactly once,\nthen prints a short status line so the user sees activity instead of\na frozen screen while a large payload (e.g. 45 KB write_file) streams." + }, + { + "name": "_on_tool_progress", + "args": [ + "self", + "function_name", + "preview", + "function_args" + ], + "async": false, + "docstring": "Called when a tool starts executing.\n\nUpdates the TUI spinner widget so the user can see what the agent\nis doing during tool execution (fills the gap between thinking\nspinner and next response). Also plays audio cue in voice mode." + }, + { + "name": "_on_tool_start", + "args": [ + "self", + "tool_call_id", + "function_name", + "function_args" + ], + "async": false, + "docstring": "Capture local before-state for write-capable tools." + }, + { + "name": "_on_tool_complete", + "args": [ + "self", + "tool_call_id", + "function_name", + "function_args", + "function_result" + ], + "async": false, + "docstring": "Render file edits with inline diff after write-capable tools complete." + }, + { + "name": "_voice_start_recording", + "args": [ + "self" + ], + "async": false, + "docstring": "Start capturing audio from the microphone." + }, + { + "name": "_voice_stop_and_transcribe", + "args": [ + "self" + ], + "async": false, + "docstring": "Stop recording, transcribe via STT, and queue the transcript as input." + }, + { + "name": "_voice_speak_response", + "args": [ + "self", + "text" + ], + "async": false, + "docstring": "Speak the agent's response aloud using TTS (runs in background thread)." + }, + { + "name": "_handle_voice_command", + "args": [ + "self", + "command" + ], + "async": false, + "docstring": "Handle /voice [on|off|tts|status] command." + }, + { + "name": "_enable_voice_mode", + "args": [ + "self" + ], + "async": false, + "docstring": "Enable voice mode after checking requirements." + }, + { + "name": "_disable_voice_mode", + "args": [ + "self" + ], + "async": false, + "docstring": "Disable voice mode, cancel any active recording, and stop TTS." + }, + { + "name": "_toggle_voice_tts", + "args": [ + "self" + ], + "async": false, + "docstring": "Toggle TTS output for voice mode." + }, + { + "name": "_show_voice_status", + "args": [ + "self" + ], + "async": false, + "docstring": "Show current voice mode status." + }, + { + "name": "_clarify_callback", + "args": [ + "self", + "question", + "choices" + ], + "async": false, + "docstring": "Platform callback for the clarify tool. Called from the agent thread.\n\nSets up the interactive selection UI (or freetext prompt for open-ended\nquestions), then blocks until the user responds via the prompt_toolkit\nkey bindings. If no response arrives within the configured timeout the\nquestion is dismissed and the agent is told to decide on its own." + }, + { + "name": "_sudo_password_callback", + "args": [ + "self" + ], + "async": false, + "docstring": "Prompt for sudo password through the prompt_toolkit UI.\n\nCalled from the agent thread when a sudo command is encountered.\nUses the same clarify-style mechanism: sets UI state, waits on a\nqueue for the user's response via the Enter key binding." + }, + { + "name": "_approval_callback", + "args": [ + "self", + "command", + "description" + ], + "async": false, + "docstring": "Prompt for dangerous command approval through the prompt_toolkit UI.\n\nCalled from the agent thread. Shows a selection UI similar to clarify\nwith choices: once / session / always / deny. When allow_permanent\nis False (tirith warnings present), the 'always' option is hidden.\nLong commands also get a 'view' option so the full command can be\nexpanded before deciding.\n\nUses _approval_lock to serialize concurrent requests (e.g. from\nparallel delegation subtasks) so each prompt gets its own turn\nand the shared _approval_state / _approval_deadline aren't clobbered." + }, + { + "name": "_approval_choices", + "args": [ + "self", + "command" + ], + "async": false, + "docstring": "Return approval choices for a dangerous command prompt." + }, + { + "name": "_handle_approval_selection", + "args": [ + "self" + ], + "async": false, + "docstring": "Process the currently selected dangerous-command approval choice." + }, + { + "name": "_get_approval_display_fragments", + "args": [ + "self" + ], + "async": false, + "docstring": "Render the dangerous-command approval panel for the prompt_toolkit UI." + }, + { + "name": "_secret_capture_callback", + "args": [ + "self", + "var_name", + "prompt", + "metadata" + ], + "async": false, + "docstring": null + }, + { + "name": "_submit_secret_response", + "args": [ + "self", + "value" + ], + "async": false, + "docstring": null + }, + { + "name": "_cancel_secret_capture", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_clear_secret_input_buffer", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_clear_current_input", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "chat", + "args": [ + "self", + "message", + "images" + ], + "async": false, + "docstring": "Send a message to the agent and get a response.\n\nHandles streaming output, interrupt detection (user typing while agent\nis working), and re-queueing of interrupted messages.\n\nUses a dedicated _interrupt_queue (separate from _pending_input) to avoid\nrace conditions between the process_loop and interrupt monitoring. Messages\ntyped while the agent is running go to _interrupt_queue; messages typed while\nidle go to _pending_input.\n\nArgs:\n message: The user's message (str or multimodal content list)\n images: Optional list of Path objects for attached images\n \nReturns:\n The agent's response, or None on error" + }, + { + "name": "_print_exit_summary", + "args": [ + "self" + ], + "async": false, + "docstring": "Print session resume info on exit, similar to Claude Code." + }, + { + "name": "_get_tui_prompt_symbols", + "args": [ + "self" + ], + "async": false, + "docstring": "Return ``(normal_prompt, state_suffix)`` for the active skin.\n\n``normal_prompt`` is the full ``branding.prompt_symbol``.\n``state_suffix`` is what special states (sudo/secret/approval/agent)\nshould render after their leading icon.\n\nWhen a profile is active (not \"default\"), the profile name is\nprepended to the prompt symbol: ``coder \u276f`` instead of ``\u276f``." + }, + { + "name": "_audio_level_bar", + "args": [ + "self" + ], + "async": false, + "docstring": "Return a visual audio level indicator based on current RMS." + }, + { + "name": "_get_tui_prompt_fragments", + "args": [ + "self" + ], + "async": false, + "docstring": "Return the prompt_toolkit fragments for the current interactive state." + }, + { + "name": "_get_tui_prompt_text", + "args": [ + "self" + ], + "async": false, + "docstring": "Return the visible prompt text for width calculations." + }, + { + "name": "_build_tui_style_dict", + "args": [ + "self" + ], + "async": false, + "docstring": "Layer the active skin's prompt_toolkit colors over the base TUI style." + }, + { + "name": "_apply_tui_skin_style", + "args": [ + "self" + ], + "async": false, + "docstring": "Refresh prompt_toolkit styling for a running interactive TUI." + }, + { + "name": "_get_extra_tui_widgets", + "args": [ + "self" + ], + "async": false, + "docstring": "Return extra prompt_toolkit widgets to insert into the TUI layout.\n\nWrapper CLIs can override this to inject widgets (e.g. a mini-player,\noverlay menu) into the layout without overriding ``run()``. Widgets\nare inserted between the spacer and the status bar." + }, + { + "name": "_register_extra_tui_keybindings", + "args": [ + "self", + "kb" + ], + "async": false, + "docstring": "Register extra keybindings on the TUI ``KeyBindings`` object.\n\nWrapper CLIs can override this to add keybindings (e.g. transport\ncontrols, modal shortcuts) without overriding ``run()``.\n\nParameters\n----------\nkb : KeyBindings\n The active keybinding registry for the prompt_toolkit application.\ninput_area : TextArea\n The main input widget, for wrappers that need to inspect or\n manipulate user input from a keybinding handler." + }, + { + "name": "_build_tui_layout_children", + "args": [ + "self" + ], + "async": false, + "docstring": "Assemble the ordered list of children for the root ``HSplit``.\n\nWrapper CLIs typically override ``_get_extra_tui_widgets`` instead of\nthis method. Override this only when you need full control over widget\nordering." + }, + { + "name": "run", + "args": [ + "self" + ], + "async": false, + "docstring": "Run the interactive CLI loop with persistent input at bottom." + } + ], + "docstring": "Interactive CLI for the Hermes Agent.\n\nProvides a REPL interface with rich formatting, command history,\nand tool execution capabilities." + } + ], + "functions": [ + { + "name": "_load_prefill_messages", + "args": [ + "file_path" + ], + "async": false, + "docstring": "Load ephemeral prefill messages from a JSON file.\n\nThe file should contain a JSON array of {role, content} dicts, e.g.:\n [{\"role\": \"user\", \"content\": \"Hi\"}, {\"role\": \"assistant\", \"content\": \"Hello!\"}]\n\nRelative paths are resolved from ~/.hermes/.\nReturns an empty list if the path is empty or the file doesn't exist." + }, + { + "name": "_parse_reasoning_config", + "args": [ + "effort" + ], + "async": false, + "docstring": "Parse a reasoning effort level into an OpenRouter reasoning config dict." + }, + { + "name": "load_cli_config", + "args": [], + "async": false, + "docstring": "Load CLI configuration from config files.\n\nConfig lookup order:\n1. ~/.hermes/config.yaml (user config - preferred)\n2. ./cli-config.yaml (project config - fallback)\n\nEnvironment variables take precedence over config file values.\nReturns default values if no config file exists." + }, + { + "name": "_run_cleanup", + "args": [], + "async": false, + "docstring": "Run resource cleanup exactly once." + }, + { + "name": "_git_repo_root", + "args": [], + "async": false, + "docstring": "Return the git repo root for CWD, or None if not in a repo." + }, + { + "name": "_path_is_within_root", + "args": [ + "path", + "root" + ], + "async": false, + "docstring": "Return True when a resolved path stays within the expected root." + }, + { + "name": "_setup_worktree", + "args": [ + "repo_root" + ], + "async": false, + "docstring": "Create an isolated git worktree for this CLI session.\n\nReturns a dict with worktree metadata on success, None on failure.\nThe dict contains: path, branch, repo_root." + }, + { + "name": "_cleanup_worktree", + "args": [ + "info" + ], + "async": false, + "docstring": "Remove a worktree and its branch on exit.\n\nIf the worktree has uncommitted changes, warn and keep it." + }, + { + "name": "_prune_stale_worktrees", + "args": [ + "repo_root", + "max_age_hours" + ], + "async": false, + "docstring": "Remove worktrees older than max_age_hours that have no uncommitted changes.\n\nRuns silently on startup to clean up after crashed/killed sessions." + }, + { + "name": "_accent_hex", + "args": [], + "async": false, + "docstring": "Return the active skin accent color for legacy CLI output lines." + }, + { + "name": "_rich_text_from_ansi", + "args": [ + "text" + ], + "async": false, + "docstring": "Safely render assistant/tool output that may contain ANSI escapes.\n\nUsing Rich Text.from_ansi preserves literal bracketed text like\n``[not markup]`` while still interpreting real ANSI color codes." + }, + { + "name": "_cprint", + "args": [ + "text" + ], + "async": false, + "docstring": "Print ANSI-colored text through prompt_toolkit's native renderer.\n\nRaw ANSI escapes written via print() are swallowed by patch_stdout's\nStdoutProxy. Routing through print_formatted_text(ANSI(...)) lets\nprompt_toolkit parse the escapes and render real colors." + }, + { + "name": "_detect_file_drop", + "args": [ + "user_input" + ], + "async": false, + "docstring": "Detect if *user_input* is a dragged/pasted file path, not a slash command.\n\nWhen a user drags a file into the terminal, macOS pastes the absolute path\n(e.g. ``/Users/roland/Desktop/file.png``) which starts with ``/`` and would\notherwise be mistaken for a slash command.\n\nReturns a dict on match::\n\n {\n \"path\": Path, # resolved file path\n \"is_image\": bool, # True when suffix is a known image type\n \"remainder\": str, # any text after the path\n }\n\nReturns ``None`` when the input is not a real file path." + }, + { + "name": "_build_compact_banner", + "args": [], + "async": false, + "docstring": "Build a compact banner that fits the current terminal width." + }, + { + "name": "_looks_like_slash_command", + "args": [ + "text" + ], + "async": false, + "docstring": "Return True if *text* looks like a slash command, not a file path.\n\nSlash commands are ``/help``, ``/model gpt-4``, ``/q``, etc.\nFile paths like ``/Users/ironin/file.md:45-46 can you fix this?``\nalso start with ``/`` but contain additional ``/`` characters in\nthe first whitespace-delimited word. This helper distinguishes\nthe two so that pasted paths are sent to the agent instead of\ntriggering \"Unknown command\"." + }, + { + "name": "_get_plugin_cmd_handler_names", + "args": [], + "async": false, + "docstring": "Return plugin command names (without slash prefix) for dispatch matching." + }, + { + "name": "_parse_skills_argument", + "args": [ + "skills" + ], + "async": false, + "docstring": "Normalize a CLI skills flag into a deduplicated list of skill identifiers." + }, + { + "name": "save_config_value", + "args": [ + "key_path", + "value" + ], + "async": false, + "docstring": "Save a value to the active config file at the specified key path.\n\nRespects the same lookup order as load_cli_config():\n1. ~/.hermes/config.yaml (user config - preferred, used if it exists)\n2. ./cli-config.yaml (project config - fallback)\n\nArgs:\n key_path: Dot-separated path like \"agent.system_prompt\"\n value: Value to save\n\nReturns:\n True if successful, False otherwise" + }, + { + "name": "main", + "args": [ + "query", + "q", + "toolsets", + "skills", + "model", + "provider", + "api_key", + "base_url", + "max_turns", + "verbose", + "quiet", + "compact", + "list_tools", + "list_toolsets", + "gateway", + "resume", + "worktree", + "w", + "checkpoints", + "pass_session_id" + ], + "async": false, + "docstring": "Hermes Agent CLI - Interactive AI Assistant\n\nArgs:\n query: Single query to execute (then exit). Alias: -q\n q: Shorthand for --query\n toolsets: Comma-separated list of toolsets to enable (e.g., \"web,terminal\")\n skills: Comma-separated or repeated list of skills to preload for the session\n model: Model to use (default: anthropic/claude-opus-4-20250514)\n provider: Inference provider (\"auto\", \"openrouter\", \"nous\", \"openai-codex\", \"zai\", \"kimi-coding\", \"minimax\", \"minimax-cn\")\n api_key: API key for authentication\n base_url: Base URL for the API\n max_turns: Maximum tool-calling iterations (default: 60)\n verbose: Enable verbose logging\n compact: Use compact display mode\n list_tools: List available tools and exit\n list_toolsets: List available toolsets and exit\n resume: Resume a previous session by its ID (e.g., 20260225_143052_a1b2c3)\n worktree: Run in an isolated git worktree (for parallel agents). Alias: -w\n w: Shorthand for --worktree\n\nExamples:\n python cli.py # Start interactive mode\n python cli.py --toolsets web,terminal # Use specific toolsets\n python cli.py --skills hermes-agent-dev,github-auth\n python cli.py -q \"What is Python?\" # Single query mode\n python cli.py --list-tools # List tools and exit\n python cli.py --resume 20260225_143052_a1b2c3 # Resume session\n python cli.py -w # Start in isolated git worktree\n python cli.py -w -q \"Fix issue #123\" # Single query in worktree" + } + ], + "imports": [ + "logging", + "os", + "shutil", + "sys", + "json", + "atexit", + "tempfile", + "time", + "uuid", + "textwrap", + "from contextlib import contextmanager", + "from pathlib import Path", + "from datetime import datetime", + "from typing import List, Dict, Any, Optional", + "yaml", + "from prompt_toolkit.history import FileHistory", + "from prompt_toolkit.styles import Style", + "from prompt_toolkit.patch_stdout import patch_stdout", + "from prompt_toolkit.application import Application", + "from prompt_toolkit.layout import Layout, HSplit, Window, FormattedTextControl, ConditionalContainer", + "from prompt_toolkit.layout.processors import Processor, Transformation, PasswordProcessor, ConditionalProcessor", + "from prompt_toolkit.filters import Condition", + "from prompt_toolkit.layout.dimension import Dimension", + "from prompt_toolkit.layout.menus import CompletionsMenu", + "from prompt_toolkit.widgets import TextArea", + "from prompt_toolkit.key_binding import KeyBindings", + "from prompt_toolkit import print_formatted_text", + "from prompt_toolkit.formatted_text import ANSI", + "threading", + "queue", + "from agent.usage_pricing import CanonicalUsage, estimate_usage_cost, format_duration_compact, format_token_count_compact", + "from hermes_cli.banner import _format_context_length", + "from hermes_constants import get_hermes_home, display_hermes_home, OPENROUTER_BASE_URL", + "from hermes_cli.env_loader import load_hermes_dotenv", + "from rich import box", + "from rich.console import Console", + "from rich.markup import escape", + "from rich.panel import Panel", + "from rich.text import Text", + "fire", + "from run_agent import AIAgent", + "from model_tools import get_tool_definitions, get_toolset_for_tool", + "from hermes_cli.banner import build_welcome_banner", + "from hermes_cli.commands import SlashCommandCompleter, SlashCommandAutoSuggest", + "from toolsets import get_all_toolsets, get_toolset_info, validate_toolset", + "from cron import get_job", + "from tools.terminal_tool import cleanup_all_environments", + "from tools.terminal_tool import set_sudo_password_callback, set_approval_callback", + "from tools.skills_tool import set_secret_capture_callback", + "from hermes_cli.callbacks import prompt_for_secret", + "from tools.browser_tool import _emergency_cleanup_all_sessions", + "from agent.skill_commands import scan_skill_commands, build_skill_invocation_message, build_plan_path, build_preloaded_skills_prompt" + ], + "loc": 8280 + }, + "tools/registry.py": { + "path": "tools/registry.py", + "classes": [ + { + "name": "ToolEntry", + "methods": [ + { + "name": "__init__", + "args": [ + "self", + "name", + "toolset", + "schema", + "handler", + "check_fn", + "requires_env", + "is_async", + "description", + "emoji" + ], + "async": false, + "docstring": null + } + ], + "docstring": "Metadata for a single registered tool." + }, + { + "name": "ToolRegistry", + "methods": [ + { + "name": "__init__", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "register", + "args": [ + "self", + "name", + "toolset", + "schema", + "handler", + "check_fn", + "requires_env", + "is_async", + "description", + "emoji" + ], + "async": false, + "docstring": "Register a tool. Called at module-import time by each tool file." + }, + { + "name": "deregister", + "args": [ + "self", + "name" + ], + "async": false, + "docstring": "Remove a tool from the registry.\n\nAlso cleans up the toolset check if no other tools remain in the\nsame toolset. Used by MCP dynamic tool discovery to nuke-and-repave\nwhen a server sends ``notifications/tools/list_changed``." + }, + { + "name": "get_definitions", + "args": [ + "self", + "tool_names", + "quiet" + ], + "async": false, + "docstring": "Return OpenAI-format tool schemas for the requested tool names.\n\nOnly tools whose ``check_fn()`` returns True (or have no check_fn)\nare included." + }, + { + "name": "dispatch", + "args": [ + "self", + "name", + "args" + ], + "async": false, + "docstring": "Execute a tool handler by name.\n\n* Async handlers are bridged automatically via ``_run_async()``.\n* All exceptions are caught and returned as ``{\"error\": \"...\"}``\n for consistent error format." + }, + { + "name": "get_all_tool_names", + "args": [ + "self" + ], + "async": false, + "docstring": "Return sorted list of all registered tool names." + }, + { + "name": "get_schema", + "args": [ + "self", + "name" + ], + "async": false, + "docstring": "Return a tool's raw schema dict, bypassing check_fn filtering.\n\nUseful for token estimation and introspection where availability\ndoesn't matter \u2014 only the schema content does." + }, + { + "name": "get_toolset_for_tool", + "args": [ + "self", + "name" + ], + "async": false, + "docstring": "Return the toolset a tool belongs to, or None." + }, + { + "name": "get_emoji", + "args": [ + "self", + "name", + "default" + ], + "async": false, + "docstring": "Return the emoji for a tool, or *default* if unset." + }, + { + "name": "get_tool_to_toolset_map", + "args": [ + "self" + ], + "async": false, + "docstring": "Return ``{tool_name: toolset_name}`` for every registered tool." + }, + { + "name": "is_toolset_available", + "args": [ + "self", + "toolset" + ], + "async": false, + "docstring": "Check if a toolset's requirements are met.\n\nReturns False (rather than crashing) when the check function raises\nan unexpected exception (e.g. network error, missing import, bad config)." + }, + { + "name": "check_toolset_requirements", + "args": [ + "self" + ], + "async": false, + "docstring": "Return ``{toolset: available_bool}`` for every toolset." + }, + { + "name": "get_available_toolsets", + "args": [ + "self" + ], + "async": false, + "docstring": "Return toolset metadata for UI display." + }, + { + "name": "get_toolset_requirements", + "args": [ + "self" + ], + "async": false, + "docstring": "Build a TOOLSET_REQUIREMENTS-compatible dict for backward compat." + }, + { + "name": "check_tool_availability", + "args": [ + "self", + "quiet" + ], + "async": false, + "docstring": "Return (available_toolsets, unavailable_info) like the old function." + } + ], + "docstring": "Singleton registry that collects tool schemas + handlers from tool files." + } + ], + "functions": [], + "imports": [ + "json", + "logging", + "from typing import Callable, Dict, List, Optional, Set" + ], + "loc": 275 + }, + "gateway/run.py": { + "path": "gateway/run.py", + "classes": [ + { + "name": "GatewayRunner", + "methods": [ + { + "name": "__init__", + "args": [ + "self", + "config" + ], + "async": false, + "docstring": null + }, + { + "name": "_has_setup_skill", + "args": [ + "self" + ], + "async": false, + "docstring": "Check if the hermes-agent-setup skill is installed." + }, + { + "name": "_load_voice_modes", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_save_voice_modes", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_set_adapter_auto_tts_disabled", + "args": [ + "self", + "adapter", + "chat_id", + "disabled" + ], + "async": false, + "docstring": "Update an adapter's in-memory auto-TTS suppression set if present." + }, + { + "name": "_sync_voice_mode_state_to_adapter", + "args": [ + "self", + "adapter" + ], + "async": false, + "docstring": "Restore persisted /voice off state into a live platform adapter." + }, + { + "name": "_flush_memories_for_session", + "args": [ + "self", + "old_session_id" + ], + "async": false, + "docstring": "Prompt the agent to save memories/skills before context is lost.\n\nSynchronous worker \u2014 meant to be called via run_in_executor from\nan async context so it doesn't block the event loop." + }, + { + "name": "_async_flush_memories", + "args": [ + "self", + "old_session_id" + ], + "async": true, + "docstring": "Run the sync memory flush in a thread pool so it won't block the event loop." + }, + { + "name": "should_exit_cleanly", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "should_exit_with_failure", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "exit_reason", + "args": [ + "self" + ], + "async": false, + "docstring": null + }, + { + "name": "_session_key_for_source", + "args": [ + "self", + "source" + ], + "async": false, + "docstring": "Resolve the current session key for a source, honoring gateway config when available." + }, + { + "name": "_resolve_turn_agent_config", + "args": [ + "self", + "user_message", + "model", + "runtime_kwargs" + ], + "async": false, + "docstring": null + }, + { + "name": "_handle_adapter_fatal_error", + "args": [ + "self", + "adapter" + ], + "async": true, + "docstring": "React to an adapter failure after startup.\n\nIf the error is retryable (e.g. network blip, DNS failure), queue the\nplatform for background reconnection instead of giving up permanently." + }, + { + "name": "_request_clean_exit", + "args": [ + "self", + "reason" + ], + "async": false, + "docstring": null + }, + { + "name": "_load_prefill_messages", + "args": [], + "async": false, + "docstring": "Load ephemeral prefill messages from config or env var.\n\nChecks HERMES_PREFILL_MESSAGES_FILE env var first, then falls back to\nthe prefill_messages_file key in ~/.hermes/config.yaml.\nRelative paths are resolved from ~/.hermes/." + }, + { + "name": "_load_ephemeral_system_prompt", + "args": [], + "async": false, + "docstring": "Load ephemeral system prompt from config or env var.\n\nChecks HERMES_EPHEMERAL_SYSTEM_PROMPT env var first, then falls back to\nagent.system_prompt in ~/.hermes/config.yaml." + }, + { + "name": "_load_reasoning_config", + "args": [], + "async": false, + "docstring": "Load reasoning effort from config with env fallback.\n\nChecks agent.reasoning_effort in config.yaml first, then\nHERMES_REASONING_EFFORT as a fallback. Valid: \"xhigh\", \"high\",\n\"medium\", \"low\", \"minimal\", \"none\". Returns None to use default\n(medium)." + }, + { + "name": "_load_show_reasoning", + "args": [], + "async": false, + "docstring": "Load show_reasoning toggle from config.yaml display section." + }, + { + "name": "_load_background_notifications_mode", + "args": [], + "async": false, + "docstring": "Load background process notification mode from config or env var.\n\nModes:\n - ``all`` \u2014 push running-output updates *and* the final message (default)\n - ``result`` \u2014 only the final completion message (regardless of exit code)\n - ``error`` \u2014 only the final message when exit code is non-zero\n - ``off`` \u2014 no watcher messages at all" + }, + { + "name": "_load_provider_routing", + "args": [], + "async": false, + "docstring": "Load OpenRouter provider routing preferences from config.yaml." + }, + { + "name": "_load_fallback_model", + "args": [], + "async": false, + "docstring": "Load fallback provider chain from config.yaml.\n\nReturns a list of provider dicts (``fallback_providers``), a single\ndict (legacy ``fallback_model``), or None if not configured.\nAIAgent.__init__ normalizes both formats into a chain." + }, + { + "name": "_load_smart_model_routing", + "args": [], + "async": false, + "docstring": "Load optional smart cheap-vs-strong model routing config." + }, + { + "name": "start", + "args": [ + "self" + ], + "async": true, + "docstring": "Start the gateway and all configured platform adapters.\n\nReturns True if at least one adapter connected successfully." + }, + { + "name": "_session_expiry_watcher", + "args": [ + "self", + "interval" + ], + "async": true, + "docstring": "Background task that proactively flushes memories for expired sessions.\n\nRuns every `interval` seconds (default 5 min). For each session that\nhas expired according to its reset policy, flushes memories in a thread\npool and marks the session so it won't be flushed again.\n\nThis means memories are already saved by the time the user sends their\nnext message, so there's no blocking delay." + }, + { + "name": "_platform_reconnect_watcher", + "args": [ + "self" + ], + "async": true, + "docstring": "Background task that periodically retries connecting failed platforms.\n\nUses exponential backoff: 30s \u2192 60s \u2192 120s \u2192 240s \u2192 300s (cap).\nStops retrying a platform after 20 failed attempts or if the error\nis non-retryable (e.g. bad auth token)." + }, + { + "name": "stop", + "args": [ + "self" + ], + "async": true, + "docstring": "Stop the gateway and disconnect all adapters." + }, + { + "name": "wait_for_shutdown", + "args": [ + "self" + ], + "async": true, + "docstring": "Wait for shutdown signal." + }, + { + "name": "_create_adapter", + "args": [ + "self", + "platform", + "config" + ], + "async": false, + "docstring": "Create the appropriate adapter for a platform." + }, + { + "name": "_is_user_authorized", + "args": [ + "self", + "source" + ], + "async": false, + "docstring": "Check if a user is authorized to use the bot.\n\nChecks in order:\n1. Per-platform allow-all flag (e.g., DISCORD_ALLOW_ALL_USERS=true)\n2. Environment variable allowlists (TELEGRAM_ALLOWED_USERS, etc.)\n3. DM pairing approved list\n4. Global allow-all (GATEWAY_ALLOW_ALL_USERS=true)\n5. Default: deny" + }, + { + "name": "_get_unauthorized_dm_behavior", + "args": [ + "self", + "platform" + ], + "async": false, + "docstring": "Return how unauthorized DMs should be handled for a platform." + }, + { + "name": "_handle_message", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle an incoming message from any platform.\n\nThis is the core message processing pipeline:\n1. Check user authorization\n2. Check for commands (/new, /reset, etc.)\n3. Check for running agent and interrupt if needed\n4. Get or create session\n5. Build context for agent\n6. Run agent conversation\n7. Return response" + }, + { + "name": "_handle_message_with_agent", + "args": [ + "self", + "event", + "source", + "_quick_key" + ], + "async": true, + "docstring": "Inner handler that runs under the _running_agents sentinel guard." + }, + { + "name": "_format_session_info", + "args": [ + "self" + ], + "async": false, + "docstring": "Resolve current model config and return a formatted info block.\n\nSurfaces model, provider, context length, and endpoint so gateway\nusers can immediately see if context detection went wrong (e.g.\nlocal models falling to the 128K default)." + }, + { + "name": "_handle_reset_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /new or /reset command." + }, + { + "name": "_handle_profile_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /profile \u2014 show active profile name and home directory." + }, + { + "name": "_handle_status_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /status command." + }, + { + "name": "_handle_stop_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /stop command - interrupt a running agent.\n\nWhen an agent is truly hung (blocked thread that never checks\n_interrupt_requested), the early intercept in _handle_message()\nhandles /stop before this method is reached. This handler fires\nonly through normal command dispatch (no running agent) or as a\nfallback. Force-clean the session lock in all cases for safety." + }, + { + "name": "_handle_help_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /help command - list available commands." + }, + { + "name": "_handle_commands_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /commands [page] - paginated list of all commands and skills." + }, + { + "name": "_handle_provider_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /provider command - show available providers." + }, + { + "name": "_handle_personality_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /personality command - list or set a personality." + }, + { + "name": "_handle_retry_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /retry command - re-send the last user message." + }, + { + "name": "_handle_undo_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /undo command - remove the last user/assistant exchange." + }, + { + "name": "_handle_set_home_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /sethome command -- set the current chat as the platform's home channel." + }, + { + "name": "_get_guild_id", + "args": [ + "event" + ], + "async": false, + "docstring": "Extract Discord guild_id from the raw message object." + }, + { + "name": "_handle_voice_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /voice [on|off|tts|channel|leave|status] command." + }, + { + "name": "_handle_voice_channel_join", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Join the user's current Discord voice channel." + }, + { + "name": "_handle_voice_channel_leave", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Leave the Discord voice channel." + }, + { + "name": "_handle_voice_timeout_cleanup", + "args": [ + "self", + "chat_id" + ], + "async": false, + "docstring": "Called by the adapter when a voice channel times out.\n\nCleans up runner-side voice_mode state that the adapter cannot reach." + }, + { + "name": "_handle_voice_channel_input", + "args": [ + "self", + "guild_id", + "user_id", + "transcript" + ], + "async": true, + "docstring": "Handle transcribed voice from a user in a voice channel.\n\nCreates a synthetic MessageEvent and processes it through the\nadapter's full message pipeline (session, typing, agent, TTS reply)." + }, + { + "name": "_should_send_voice_reply", + "args": [ + "self", + "event", + "response", + "agent_messages", + "already_sent" + ], + "async": false, + "docstring": "Decide whether the runner should send a TTS voice reply.\n\nReturns False when:\n- voice_mode is off for this chat\n- response is empty or an error\n- agent already called text_to_speech tool (dedup)\n- voice input and base adapter auto-TTS already handled it (skip_double)\n UNLESS streaming already consumed the response (already_sent=True),\n in which case the base adapter won't have text for auto-TTS so the\n runner must handle it." + }, + { + "name": "_send_voice_reply", + "args": [ + "self", + "event", + "text" + ], + "async": true, + "docstring": "Generate TTS audio and send as a voice message before the text reply." + }, + { + "name": "_deliver_media_from_response", + "args": [ + "self", + "response", + "event", + "adapter" + ], + "async": true, + "docstring": "Extract MEDIA: tags and local file paths from a response and deliver them.\n\nCalled after streaming has already sent the text to the user, so the\ntext itself is already delivered \u2014 this only handles file attachments\nthat the normal _process_message_background path would have caught." + }, + { + "name": "_handle_rollback_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /rollback command \u2014 list or restore filesystem checkpoints." + }, + { + "name": "_handle_background_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /background <prompt> \u2014 run a prompt in a separate background session.\n\nSpawns a new AIAgent in a background thread with its own session.\nWhen it completes, sends the result back to the same chat without\nmodifying the active session's conversation history." + }, + { + "name": "_run_background_task", + "args": [ + "self", + "prompt", + "source", + "task_id" + ], + "async": true, + "docstring": "Execute a background agent task and deliver the result to the chat." + }, + { + "name": "_handle_btw_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /btw <question> \u2014 ephemeral side question in the same chat." + }, + { + "name": "_run_btw_task", + "args": [ + "self", + "question", + "source", + "session_key", + "task_id" + ], + "async": true, + "docstring": "Execute an ephemeral /btw side question and deliver the answer." + }, + { + "name": "_handle_reasoning_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /reasoning command \u2014 manage reasoning effort and display toggle.\n\nUsage:\n /reasoning Show current effort level and display state\n /reasoning <level> Set reasoning effort (none, low, medium, high, xhigh)\n /reasoning show|on Show model reasoning in responses\n /reasoning hide|off Hide model reasoning from responses" + }, + { + "name": "_handle_yolo_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /yolo \u2014 toggle dangerous command approval bypass." + }, + { + "name": "_handle_verbose_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /verbose command \u2014 cycle tool progress display mode.\n\nGated by ``display.tool_progress_command`` in config.yaml (default off).\nWhen enabled, cycles the tool progress mode through off \u2192 new \u2192 all \u2192\nverbose \u2192 off, same as the CLI." + }, + { + "name": "_handle_compress_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /compress command -- manually compress conversation context." + }, + { + "name": "_handle_title_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /title command \u2014 set or show the current session's title." + }, + { + "name": "_handle_resume_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /resume command \u2014 switch to a previously-named session." + }, + { + "name": "_handle_branch_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /branch [name] \u2014 fork the current session into a new independent copy.\n\nCopies conversation history to a new session so the user can explore\na different approach without losing the original.\nInspired by Claude Code's /branch command." + }, + { + "name": "_handle_usage_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /usage command -- show token usage for the session's last agent run." + }, + { + "name": "_handle_insights_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /insights command -- show usage insights and analytics." + }, + { + "name": "_handle_reload_mcp_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /reload-mcp command -- disconnect and reconnect all MCP servers." + }, + { + "name": "_handle_approve_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /approve command \u2014 unblock waiting agent thread(s).\n\nThe agent thread(s) are blocked inside tools/approval.py waiting for\nthe user to respond. This handler signals the event so the agent\nresumes and the terminal_tool executes the command inline \u2014 the same\nflow as the CLI's synchronous input() approval.\n\nSupports multiple concurrent approvals (parallel subagents,\nexecute_code). ``/approve`` resolves the oldest pending command;\n``/approve all`` resolves every pending command at once.\n\nUsage:\n /approve \u2014 approve oldest pending command once\n /approve all \u2014 approve ALL pending commands at once\n /approve session \u2014 approve oldest + remember for session\n /approve all session \u2014 approve all + remember for session\n /approve always \u2014 approve oldest + remember permanently\n /approve all always \u2014 approve all + remember permanently" + }, + { + "name": "_handle_deny_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /deny command \u2014 reject pending dangerous command(s).\n\nSignals blocked agent thread(s) with a 'deny' result so they receive\na definitive BLOCKED message, same as the CLI deny flow.\n\n``/deny`` denies the oldest; ``/deny all`` denies everything." + }, + { + "name": "_handle_update_command", + "args": [ + "self", + "event" + ], + "async": true, + "docstring": "Handle /update command \u2014 update Hermes Agent to the latest version.\n\nSpawns ``hermes update`` in a detached session (via ``setsid``) so it\nsurvives the gateway restart that ``hermes update`` may trigger. Marker\nfiles are written so either the current gateway process or the next one\ncan notify the user when the update finishes." + }, + { + "name": "_schedule_update_notification_watch", + "args": [ + "self" + ], + "async": false, + "docstring": "Ensure a background task is watching for update completion." + }, + { + "name": "_watch_for_update_completion", + "args": [ + "self", + "poll_interval", + "timeout" + ], + "async": true, + "docstring": "Wait for ``hermes update`` to finish, then send its notification." + }, + { + "name": "_send_update_notification", + "args": [ + "self" + ], + "async": true, + "docstring": "If an update finished, notify the user.\n\nReturns False when the update is still running so a caller can retry\nlater. Returns True after a definitive send/skip decision." + }, + { + "name": "_set_session_env", + "args": [ + "self", + "context" + ], + "async": false, + "docstring": "Set environment variables for the current session." + }, + { + "name": "_clear_session_env", + "args": [ + "self" + ], + "async": false, + "docstring": "Clear session environment variables." + }, + { + "name": "_enrich_message_with_vision", + "args": [ + "self", + "user_text", + "image_paths" + ], + "async": true, + "docstring": "Auto-analyze user-attached images with the vision tool and prepend\nthe descriptions to the message text.\n\nEach image is analyzed with a general-purpose prompt. The resulting\ndescription *and* the local cache path are injected so the model can:\n 1. Immediately understand what the user sent (no extra tool call).\n 2. Re-examine the image with vision_analyze if it needs more detail.\n\nArgs:\n user_text: The user's original caption / message text.\n image_paths: List of local file paths to cached images.\n\nReturns:\n The enriched message string with vision descriptions prepended." + }, + { + "name": "_enrich_message_with_transcription", + "args": [ + "self", + "user_text", + "audio_paths" + ], + "async": true, + "docstring": "Auto-transcribe user voice/audio messages using the configured STT provider\nand prepend the transcript to the message text.\n\nArgs:\n user_text: The user's original caption / message text.\n audio_paths: List of local file paths to cached audio files.\n\nReturns:\n The enriched message string with transcriptions prepended." + }, + { + "name": "_run_process_watcher", + "args": [ + "self", + "watcher" + ], + "async": true, + "docstring": "Periodically check a background process and push updates to the user.\n\nRuns as an asyncio task. Stays silent when nothing changed.\nAuto-removes when the process exits or is killed.\n\nNotification mode (from ``display.background_process_notifications``):\n - ``all`` \u2014 running-output updates + final message\n - ``result`` \u2014 final completion message only\n - ``error`` \u2014 final message only when exit code != 0\n - ``off`` \u2014 no messages at all" + }, + { + "name": "_agent_config_signature", + "args": [ + "model", + "runtime", + "enabled_toolsets", + "ephemeral_prompt" + ], + "async": false, + "docstring": "Compute a stable string key from agent config values.\n\nWhen this signature changes between messages, the cached AIAgent is\ndiscarded and rebuilt. When it stays the same, the cached agent is\nreused \u2014 preserving the frozen system prompt and tool schemas for\nprompt cache hits." + }, + { + "name": "_evict_cached_agent", + "args": [ + "self", + "session_key" + ], + "async": false, + "docstring": "Remove a cached agent for a session (called on /new, /model, etc)." + }, + { + "name": "_run_agent", + "args": [ + "self", + "message", + "context_prompt", + "history", + "source", + "session_id", + "session_key", + "_interrupt_depth", + "event_message_id" + ], + "async": true, + "docstring": "Run the agent with the given message and context.\n\nReturns the full result dict from run_conversation, including:\n - \"final_response\": str (the text to send back)\n - \"messages\": list (full conversation including tool calls)\n - \"api_calls\": int\n - \"completed\": bool\n\nThis is run in a thread pool to not block the event loop.\nSupports interruption via new messages." + } + ], + "docstring": "Main gateway controller.\n\nManages the lifecycle of all platform adapters and routes\nmessages to/from the agent." + } + ], + "functions": [ + { + "name": "_ensure_ssl_certs", + "args": [], + "async": false, + "docstring": "Set SSL_CERT_FILE if the system doesn't expose CA certs to Python." + }, + { + "name": "_normalize_whatsapp_identifier", + "args": [ + "value" + ], + "async": false, + "docstring": "Strip WhatsApp JID/LID syntax down to its stable numeric identifier." + }, + { + "name": "_expand_whatsapp_auth_aliases", + "args": [ + "identifier" + ], + "async": false, + "docstring": "Resolve WhatsApp phone/LID aliases using bridge session mapping files." + }, + { + "name": "_resolve_runtime_agent_kwargs", + "args": [], + "async": false, + "docstring": "Resolve provider credentials for gateway-created AIAgent instances." + }, + { + "name": "_build_media_placeholder", + "args": [ + "event" + ], + "async": false, + "docstring": "Build a text placeholder for media-only events so they aren't dropped.\n\nWhen a photo/document is queued during active processing and later\ndequeued, only .text is extracted. If the event has no caption,\nthe media would be silently lost. This builds a placeholder that\nthe vision enrichment pipeline will replace with a real description." + }, + { + "name": "_dequeue_pending_text", + "args": [ + "adapter", + "session_key" + ], + "async": false, + "docstring": "Consume and return the text of a pending queued message.\n\nPreserves media context for captionless photo/document events by\nbuilding a placeholder so the message isn't silently dropped." + }, + { + "name": "_check_unavailable_skill", + "args": [ + "command_name" + ], + "async": false, + "docstring": "Check if a command matches a known-but-inactive skill.\n\nReturns a helpful message if the skill exists but is disabled or only\navailable as an optional install. Returns None if no match found." + }, + { + "name": "_platform_config_key", + "args": [ + "platform" + ], + "async": false, + "docstring": "Map a Platform enum to its config.yaml key (LOCAL\u2192\"cli\", rest\u2192enum value)." + }, + { + "name": "_load_gateway_config", + "args": [], + "async": false, + "docstring": "Load and parse ~/.hermes/config.yaml, returning {} on any error." + }, + { + "name": "_resolve_gateway_model", + "args": [ + "config" + ], + "async": false, + "docstring": "Read model from config.yaml \u2014 single source of truth.\n\nWithout this, temporary AIAgent instances (memory flush, /compress) fall\nback to the hardcoded default which fails when the active provider is\nopenai-codex." + }, + { + "name": "_resolve_hermes_bin", + "args": [], + "async": false, + "docstring": "Resolve the Hermes update command as argv parts.\n\nTries in order:\n1. ``shutil.which(\"hermes\")`` \u2014 standard PATH lookup\n2. ``sys.executable -m hermes_cli.main`` \u2014 fallback when Hermes is running\n from a venv/module invocation and the ``hermes`` shim is not on PATH\n\nReturns argv parts ready for quoting/joining, or ``None`` if neither works." + }, + { + "name": "_start_cron_ticker", + "args": [ + "stop_event", + "adapters", + "interval" + ], + "async": false, + "docstring": "Background thread that ticks the cron scheduler at a regular interval.\n\nRuns inside the gateway process so cronjobs fire automatically without\nneeding a separate `hermes cron daemon` or system cron entry.\n\nAlso refreshes the channel directory every 5 minutes and prunes the\nimage/audio/document cache once per hour." + }, + { + "name": "start_gateway", + "args": [ + "config", + "replace", + "verbosity" + ], + "async": true, + "docstring": "Start the gateway and run until interrupted.\n\nThis is the main entry point for running the gateway.\nReturns True if the gateway ran successfully, False if it failed to start.\nA False return causes a non-zero exit code so systemd can auto-restart.\n\nArgs:\n config: Optional gateway configuration override.\n replace: If True, kill any existing gateway instance before starting.\n Useful for systemd services to avoid restart-loop deadlocks\n when the previous process hasn't fully exited yet." + }, + { + "name": "main", + "args": [], + "async": false, + "docstring": "CLI entry point for the gateway." + } + ], + "imports": [ + "asyncio", + "json", + "logging", + "os", + "re", + "shlex", + "sys", + "signal", + "tempfile", + "threading", + "time", + "uuid", + "from logging.handlers import RotatingFileHandler", + "from pathlib import Path", + "from datetime import datetime", + "from typing import Dict, Optional, Any, List", + "from hermes_constants import get_hermes_home", + "from utils import atomic_yaml_write", + "from dotenv import load_dotenv", + "from hermes_cli.env_loader import load_hermes_dotenv", + "from gateway.config import Platform, GatewayConfig, load_gateway_config", + "from gateway.session import SessionStore, SessionSource, SessionContext, build_session_context, build_session_context_prompt, build_session_key", + "from gateway.delivery import DeliveryRouter", + "from gateway.platforms.base import BasePlatformAdapter, MessageEvent, MessageType" + ], + "loc": 6657 + }, + "hermes_state.py": { + "path": "hermes_state.py", + "classes": [ + { + "name": "SessionDB", + "methods": [ + { + "name": "__init__", + "args": [ + "self", + "db_path" + ], + "async": false, + "docstring": null + }, + { + "name": "_execute_write", + "args": [ + "self", + "fn" + ], + "async": false, + "docstring": "Execute a write transaction with BEGIN IMMEDIATE and jitter retry.\n\n*fn* receives the connection and should perform INSERT/UPDATE/DELETE\nstatements. The caller must NOT call ``commit()`` \u2014 that's handled\nhere after *fn* returns.\n\nBEGIN IMMEDIATE acquires the WAL write lock at transaction start\n(not at commit time), so lock contention surfaces immediately.\nOn ``database is locked``, we release the Python lock, sleep a\nrandom 20-150ms, and retry \u2014 breaking the convoy pattern that\nSQLite's built-in deterministic backoff creates.\n\nReturns whatever *fn* returns." + }, + { + "name": "_try_wal_checkpoint", + "args": [ + "self" + ], + "async": false, + "docstring": "Best-effort PASSIVE WAL checkpoint. Never blocks, never raises.\n\nFlushes committed WAL frames back into the main DB file for any\nframes that no other connection currently needs. Keeps the WAL\nfrom growing unbounded when many processes hold persistent\nconnections." + }, + { + "name": "close", + "args": [ + "self" + ], + "async": false, + "docstring": "Close the database connection.\n\nAttempts a PASSIVE WAL checkpoint first so that exiting processes\nhelp keep the WAL file from growing unbounded." + }, + { + "name": "_init_schema", + "args": [ + "self" + ], + "async": false, + "docstring": "Create tables and FTS if they don't exist, run migrations." + }, + { + "name": "create_session", + "args": [ + "self", + "session_id", + "source", + "model", + "model_config", + "system_prompt", + "user_id", + "parent_session_id" + ], + "async": false, + "docstring": "Create a new session record. Returns the session_id." + }, + { + "name": "end_session", + "args": [ + "self", + "session_id", + "end_reason" + ], + "async": false, + "docstring": "Mark a session as ended." + }, + { + "name": "reopen_session", + "args": [ + "self", + "session_id" + ], + "async": false, + "docstring": "Clear ended_at/end_reason so a session can be resumed." + }, + { + "name": "update_system_prompt", + "args": [ + "self", + "session_id", + "system_prompt" + ], + "async": false, + "docstring": "Store the full assembled system prompt snapshot." + }, + { + "name": "update_token_counts", + "args": [ + "self", + "session_id", + "input_tokens", + "output_tokens", + "model", + "cache_read_tokens", + "cache_write_tokens", + "reasoning_tokens", + "estimated_cost_usd", + "actual_cost_usd", + "cost_status", + "cost_source", + "pricing_version", + "billing_provider", + "billing_base_url", + "billing_mode", + "absolute" + ], + "async": false, + "docstring": "Update token counters and backfill model if not already set.\n\nWhen *absolute* is False (default), values are **incremented** \u2014 use\nthis for per-API-call deltas (CLI path).\n\nWhen *absolute* is True, values are **set directly** \u2014 use this when\nthe caller already holds cumulative totals (gateway path, where the\ncached agent accumulates across messages)." + }, + { + "name": "ensure_session", + "args": [ + "self", + "session_id", + "source", + "model" + ], + "async": false, + "docstring": "Ensure a session row exists, creating it with minimal metadata if absent.\n\nUsed by _flush_messages_to_session_db to recover from a failed\ncreate_session() call (e.g. transient SQLite lock at agent startup).\nINSERT OR IGNORE is safe to call even when the row already exists." + }, + { + "name": "set_token_counts", + "args": [ + "self", + "session_id", + "input_tokens", + "output_tokens", + "model", + "cache_read_tokens", + "cache_write_tokens", + "reasoning_tokens", + "estimated_cost_usd", + "actual_cost_usd", + "cost_status", + "cost_source", + "pricing_version", + "billing_provider", + "billing_base_url", + "billing_mode" + ], + "async": false, + "docstring": "Set token counters to absolute values (not increment).\n\nUse this when the caller provides cumulative totals from a completed\nconversation run (e.g. the gateway, where the cached agent's\nsession_prompt_tokens already reflects the running total)." + }, + { + "name": "get_session", + "args": [ + "self", + "session_id" + ], + "async": false, + "docstring": "Get a session by ID." + }, + { + "name": "resolve_session_id", + "args": [ + "self", + "session_id_or_prefix" + ], + "async": false, + "docstring": "Resolve an exact or uniquely prefixed session ID to the full ID.\n\nReturns the exact ID when it exists. Otherwise treats the input as a\nprefix and returns the single matching session ID if the prefix is\nunambiguous. Returns None for no matches or ambiguous prefixes." + }, + { + "name": "sanitize_title", + "args": [ + "title" + ], + "async": false, + "docstring": "Validate and sanitize a session title.\n\n- Strips leading/trailing whitespace\n- Removes ASCII control characters (0x00-0x1F, 0x7F) and problematic\n Unicode control chars (zero-width, RTL/LTR overrides, etc.)\n- Collapses internal whitespace runs to single spaces\n- Normalizes empty/whitespace-only strings to None\n- Enforces MAX_TITLE_LENGTH\n\nReturns the cleaned title string or None.\nRaises ValueError if the title exceeds MAX_TITLE_LENGTH after cleaning." + }, + { + "name": "set_session_title", + "args": [ + "self", + "session_id", + "title" + ], + "async": false, + "docstring": "Set or update a session's title.\n\nReturns True if session was found and title was set.\nRaises ValueError if title is already in use by another session,\nor if the title fails validation (too long, invalid characters).\nEmpty/whitespace-only strings are normalized to None (clearing the title)." + }, + { + "name": "get_session_title", + "args": [ + "self", + "session_id" + ], + "async": false, + "docstring": "Get the title for a session, or None." + }, + { + "name": "get_session_by_title", + "args": [ + "self", + "title" + ], + "async": false, + "docstring": "Look up a session by exact title. Returns session dict or None." + }, + { + "name": "resolve_session_by_title", + "args": [ + "self", + "title" + ], + "async": false, + "docstring": "Resolve a title to a session ID, preferring the latest in a lineage.\n\nIf the exact title exists, returns that session's ID.\nIf not, searches for \"title #N\" variants and returns the latest one.\nIf the exact title exists AND numbered variants exist, returns the\nlatest numbered variant (the most recent continuation)." + }, + { + "name": "get_next_title_in_lineage", + "args": [ + "self", + "base_title" + ], + "async": false, + "docstring": "Generate the next title in a lineage (e.g., \"my session\" \u2192 \"my session #2\").\n\nStrips any existing \" #N\" suffix to find the base name, then finds\nthe highest existing number and increments." + }, + { + "name": "list_sessions_rich", + "args": [ + "self", + "source", + "exclude_sources", + "limit", + "offset" + ], + "async": false, + "docstring": "List sessions with preview (first user message) and last active timestamp.\n\nReturns dicts with keys: id, source, model, title, started_at, ended_at,\nmessage_count, preview (first 60 chars of first user message),\nlast_active (timestamp of last message).\n\nUses a single query with correlated subqueries instead of N+2 queries." + }, + { + "name": "append_message", + "args": [ + "self", + "session_id", + "role", + "content", + "tool_name", + "tool_calls", + "tool_call_id", + "token_count", + "finish_reason", + "reasoning", + "reasoning_details", + "codex_reasoning_items" + ], + "async": false, + "docstring": "Append a message to a session. Returns the message row ID.\n\nAlso increments the session's message_count (and tool_call_count\nif role is 'tool' or tool_calls is present)." + }, + { + "name": "get_messages", + "args": [ + "self", + "session_id" + ], + "async": false, + "docstring": "Load all messages for a session, ordered by timestamp." + }, + { + "name": "get_messages_as_conversation", + "args": [ + "self", + "session_id" + ], + "async": false, + "docstring": "Load messages in the OpenAI conversation format (role + content dicts).\nUsed by the gateway to restore conversation history." + }, + { + "name": "_sanitize_fts5_query", + "args": [ + "query" + ], + "async": false, + "docstring": "Sanitize user input for safe use in FTS5 MATCH queries.\n\nFTS5 has its own query syntax where characters like ``\"``, ``(``, ``)``,\n``+``, ``*``, ``{``, ``}`` and bare boolean operators (``AND``, ``OR``,\n``NOT``) have special meaning. Passing raw user input directly to\nMATCH can cause ``sqlite3.OperationalError``.\n\nStrategy:\n- Preserve properly paired quoted phrases (``\"exact phrase\"``)\n- Strip unmatched FTS5-special characters that would cause errors\n- Wrap unquoted hyphenated and dotted terms in quotes so FTS5\n matches them as exact phrases instead of splitting on the\n hyphen/dot (e.g. ``chat-send``, ``P2.2``, ``my-app.config.ts``)" + }, + { + "name": "search_messages", + "args": [ + "self", + "query", + "source_filter", + "exclude_sources", + "role_filter", + "limit", + "offset" + ], + "async": false, + "docstring": "Full-text search across session messages using FTS5.\n\nSupports FTS5 query syntax:\n - Simple keywords: \"docker deployment\"\n - Phrases: '\"exact phrase\"'\n - Boolean: \"docker OR kubernetes\", \"python NOT java\"\n - Prefix: \"deploy*\"\n\nReturns matching messages with session metadata, content snippet,\nand surrounding context (1 message before and after the match)." + }, + { + "name": "search_sessions", + "args": [ + "self", + "source", + "limit", + "offset" + ], + "async": false, + "docstring": "List sessions, optionally filtered by source." + }, + { + "name": "session_count", + "args": [ + "self", + "source" + ], + "async": false, + "docstring": "Count sessions, optionally filtered by source." + }, + { + "name": "message_count", + "args": [ + "self", + "session_id" + ], + "async": false, + "docstring": "Count messages, optionally for a specific session." + }, + { + "name": "export_session", + "args": [ + "self", + "session_id" + ], + "async": false, + "docstring": "Export a single session with all its messages as a dict." + }, + { + "name": "export_all", + "args": [ + "self", + "source" + ], + "async": false, + "docstring": "Export all sessions (with messages) as a list of dicts.\nSuitable for writing to a JSONL file for backup/analysis." + }, + { + "name": "clear_messages", + "args": [ + "self", + "session_id" + ], + "async": false, + "docstring": "Delete all messages for a session and reset its counters." + }, + { + "name": "delete_session", + "args": [ + "self", + "session_id" + ], + "async": false, + "docstring": "Delete a session and all its messages. Returns True if found." + }, + { + "name": "prune_sessions", + "args": [ + "self", + "older_than_days", + "source" + ], + "async": false, + "docstring": "Delete sessions older than N days. Returns count of deleted sessions.\nOnly prunes ended sessions (not active ones)." + } + ], + "docstring": "SQLite-backed session storage with FTS5 search.\n\nThread-safe for the common gateway pattern (multiple reader threads,\nsingle writer via WAL mode). Each method opens its own cursor." + } + ], + "functions": [], + "imports": [ + "json", + "logging", + "os", + "random", + "re", + "sqlite3", + "threading", + "time", + "from pathlib import Path", + "from hermes_constants import get_hermes_home", + "from typing import Any, Callable, Dict, List, Optional, TypeVar" + ], + "loc": 1270 + }, + "agent/context_compressor.py": { + "path": "agent/context_compressor.py", + "classes": [ + { + "name": "ContextCompressor", + "methods": [ + { + "name": "__init__", + "args": [ + "self", + "model", + "threshold_percent", + "protect_first_n", + "protect_last_n", + "summary_target_ratio", + "quiet_mode", + "summary_model_override", + "base_url", + "api_key", + "config_context_length", + "provider" + ], + "async": false, + "docstring": null + }, + { + "name": "update_from_response", + "args": [ + "self", + "usage" + ], + "async": false, + "docstring": "Update tracked token usage from API response." + }, + { + "name": "should_compress", + "args": [ + "self", + "prompt_tokens" + ], + "async": false, + "docstring": "Check if context exceeds the compression threshold." + }, + { + "name": "should_compress_preflight", + "args": [ + "self", + "messages" + ], + "async": false, + "docstring": "Quick pre-flight check using rough estimate (before API call)." + }, + { + "name": "get_status", + "args": [ + "self" + ], + "async": false, + "docstring": "Get current compression status for display/logging." + }, + { + "name": "_prune_old_tool_results", + "args": [ + "self", + "messages", + "protect_tail_count" + ], + "async": false, + "docstring": "Replace old tool result contents with a short placeholder.\n\nWalks backward from the end, protecting the most recent\n``protect_tail_count`` messages. Older tool results get their\ncontent replaced with a placeholder string.\n\nReturns (pruned_messages, pruned_count)." + }, + { + "name": "_compute_summary_budget", + "args": [ + "self", + "turns_to_summarize" + ], + "async": false, + "docstring": "Scale summary token budget with the amount of content being compressed.\n\nThe maximum scales with the model's context window (5% of context,\ncapped at ``_SUMMARY_TOKENS_CEILING``) so large-context models get\nricher summaries instead of being hard-capped at 8K tokens." + }, + { + "name": "_serialize_for_summary", + "args": [ + "self", + "turns" + ], + "async": false, + "docstring": "Serialize conversation turns into labeled text for the summarizer.\n\nIncludes tool call arguments and result content (up to 3000 chars\nper message) so the summarizer can preserve specific details like\nfile paths, commands, and outputs." + }, + { + "name": "_generate_summary", + "args": [ + "self", + "turns_to_summarize" + ], + "async": false, + "docstring": "Generate a structured summary of conversation turns.\n\nUses a structured template (Goal, Progress, Decisions, Files, Next Steps)\ninspired by Pi-mono and OpenCode. When a previous summary exists,\ngenerates an iterative update instead of summarizing from scratch.\n\nReturns None if all attempts fail \u2014 the caller should drop\nthe middle turns without a summary rather than inject a useless\nplaceholder." + }, + { + "name": "_with_summary_prefix", + "args": [ + "summary" + ], + "async": false, + "docstring": "Normalize summary text to the current compaction handoff format." + }, + { + "name": "_get_tool_call_id", + "args": [ + "tc" + ], + "async": false, + "docstring": "Extract the call ID from a tool_call entry (dict or SimpleNamespace)." + }, + { + "name": "_sanitize_tool_pairs", + "args": [ + "self", + "messages" + ], + "async": false, + "docstring": "Fix orphaned tool_call / tool_result pairs after compression.\n\nTwo failure modes:\n1. A tool *result* references a call_id whose assistant tool_call was\n removed (summarized/truncated). The API rejects this with\n \"No tool call found for function call output with call_id ...\".\n2. An assistant message has tool_calls whose results were dropped.\n The API rejects this because every tool_call must be followed by\n a tool result with the matching call_id.\n\nThis method removes orphaned results and inserts stub results for\norphaned calls so the message list is always well-formed." + }, + { + "name": "_align_boundary_forward", + "args": [ + "self", + "messages", + "idx" + ], + "async": false, + "docstring": "Push a compress-start boundary forward past any orphan tool results.\n\nIf ``messages[idx]`` is a tool result, slide forward until we hit a\nnon-tool message so we don't start the summarised region mid-group." + }, + { + "name": "_align_boundary_backward", + "args": [ + "self", + "messages", + "idx" + ], + "async": false, + "docstring": "Pull a compress-end boundary backward to avoid splitting a\ntool_call / result group.\n\nIf the boundary falls in the middle of a tool-result group (i.e.\nthere are consecutive tool messages before ``idx``), walk backward\npast all of them to find the parent assistant message. If found,\nmove the boundary before the assistant so the entire\nassistant + tool_results group is included in the summarised region\nrather than being split (which causes silent data loss when\n``_sanitize_tool_pairs`` removes the orphaned tail results)." + }, + { + "name": "_find_tail_cut_by_tokens", + "args": [ + "self", + "messages", + "head_end", + "token_budget" + ], + "async": false, + "docstring": "Walk backward from the end of messages, accumulating tokens until\nthe budget is reached. Returns the index where the tail starts.\n\n``token_budget`` defaults to ``self.tail_token_budget`` which is\nderived from ``summary_target_ratio * context_length``, so it\nscales automatically with the model's context window.\n\nNever cuts inside a tool_call/result group. Falls back to the old\n``protect_last_n`` if the budget would protect fewer messages." + }, + { + "name": "compress", + "args": [ + "self", + "messages", + "current_tokens" + ], + "async": false, + "docstring": "Compress conversation messages by summarizing middle turns.\n\nAlgorithm:\n 1. Prune old tool results (cheap pre-pass, no LLM call)\n 2. Protect head messages (system prompt + first exchange)\n 3. Find tail boundary by token budget (~20K tokens of recent context)\n 4. Summarize middle turns with structured LLM prompt\n 5. On re-compression, iteratively update the previous summary\n\nAfter compression, orphaned tool_call / tool_result pairs are cleaned\nup so the API never receives mismatched IDs." + } + ], + "docstring": "Compresses conversation context when approaching the model's context limit.\n\nAlgorithm:\n 1. Prune old tool results (cheap, no LLM call)\n 2. Protect head messages (system prompt + first exchange)\n 3. Protect tail messages by token budget (most recent ~20K tokens)\n 4. Summarize middle turns with structured LLM prompt\n 5. On subsequent compactions, iteratively update the previous summary" + } + ], + "functions": [], + "imports": [ + "logging", + "from typing import Any, Dict, List, Optional", + "from agent.auxiliary_client import call_llm", + "from agent.model_metadata import get_model_context_length, estimate_messages_tokens_rough" + ], + "loc": 676 + }, + "agent/prompt_caching.py": { + "path": "agent/prompt_caching.py", + "classes": [], + "functions": [ + { + "name": "_apply_cache_marker", + "args": [ + "msg", + "cache_marker", + "native_anthropic" + ], + "async": false, + "docstring": "Add cache_control to a single message, handling all format variations." + }, + { + "name": "apply_anthropic_cache_control", + "args": [ + "api_messages", + "cache_ttl", + "native_anthropic" + ], + "async": false, + "docstring": "Apply system_and_3 caching strategy to messages for Anthropic models.\n\nPlaces up to 4 cache_control breakpoints: system prompt + last 3 non-system messages.\n\nReturns:\n Deep copy of messages with cache_control breakpoints injected." + } + ], + "imports": [ + "copy", + "from typing import Any, Dict, List" + ], + "loc": 72 + }, + "agent/skill_commands.py": { + "path": "agent/skill_commands.py", + "classes": [], + "functions": [ + { + "name": "build_plan_path", + "args": [ + "user_instruction" + ], + "async": false, + "docstring": "Return the default workspace-relative markdown path for a /plan invocation.\n\nRelative paths are intentional: file tools are task/backend-aware and resolve\nthem against the active working directory for local, docker, ssh, modal,\ndaytona, and similar terminal backends. That keeps the plan with the active\nworkspace instead of the Hermes host's global home directory." + }, + { + "name": "_load_skill_payload", + "args": [ + "skill_identifier", + "task_id" + ], + "async": false, + "docstring": "Load a skill by name/path and return (loaded_payload, skill_dir, display_name)." + }, + { + "name": "_build_skill_message", + "args": [ + "loaded_skill", + "skill_dir", + "activation_note", + "user_instruction", + "runtime_note" + ], + "async": false, + "docstring": "Format a loaded skill into a user/system message payload." + }, + { + "name": "scan_skill_commands", + "args": [], + "async": false, + "docstring": "Scan ~/.hermes/skills/ and return a mapping of /command -> skill info.\n\nReturns:\n Dict mapping \"/skill-name\" to {name, description, skill_md_path, skill_dir}." + }, + { + "name": "get_skill_commands", + "args": [], + "async": false, + "docstring": "Return the current skill commands mapping (scan first if empty)." + }, + { + "name": "build_skill_invocation_message", + "args": [ + "cmd_key", + "user_instruction", + "task_id", + "runtime_note" + ], + "async": false, + "docstring": "Build the user message content for a skill slash command invocation.\n\nArgs:\n cmd_key: The command key including leading slash (e.g., \"/gif-search\").\n user_instruction: Optional text the user typed after the command.\n\nReturns:\n The formatted message string, or None if the skill wasn't found." + }, + { + "name": "build_preloaded_skills_prompt", + "args": [ + "skill_identifiers", + "task_id" + ], + "async": false, + "docstring": "Load one or more skills for session-wide CLI preloading.\n\nReturns (prompt_text, loaded_skill_names, missing_identifiers)." + } + ], + "imports": [ + "json", + "logging", + "re", + "from datetime import datetime", + "from pathlib import Path", + "from typing import Any, Dict, Optional" + ], + "loc": 297 + } +} \ No newline at end of file diff --git a/docs/ouroboros/artifacts/import_graph.json b/docs/ouroboros/artifacts/import_graph.json new file mode 100644 index 000000000..9f9ec448a --- /dev/null +++ b/docs/ouroboros/artifacts/import_graph.json @@ -0,0 +1,39340 @@ +{ + "dependencies": { + "hermes_constants.py": { + "imports": [ + "os" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "mini_swe_runner.py": { + "imports": [ + "json", + "logging", + "os", + "sys", + "time", + "uuid", + "fire" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Dict", + "Any", + "Optional", + "Literal" + ] + }, + { + "module": "dotenv", + "names": [ + "load_dotenv" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "LocalEnvironment" + ] + }, + { + "module": "tools.environments.docker", + "names": [ + "DockerEnvironment" + ] + }, + { + "module": "openai", + "names": [ + "OpenAI" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "resolve_provider_client" + ] + }, + { + "module": "tools.environments.modal", + "names": [ + "ModalEnvironment" + ] + }, + { + "module": "openai", + "names": [ + "OpenAI" + ] + } + ] + }, + "mcp_serve.py": { + "imports": [ + "json", + "logging", + "os", + "re", + "sys", + "threading", + "time", + "asyncio" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "mcp.server.fastmcp", + "names": [ + "FastMCP" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "tools.send_message_tool", + "names": [ + "send_message_tool" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + } + ] + }, + "trajectory_compressor.py": { + "imports": [ + "json", + "os", + "re", + "time", + "yaml", + "logging", + "asyncio", + "fire", + "random", + "tempfile", + "shutil" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Dict", + "Any", + "Optional", + "Tuple", + "Callable" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "rich.progress", + "names": [ + "Progress", + "SpinnerColumn", + "TextColumn", + "BarColumn", + "TaskProgressColumn", + "TimeElapsedColumn", + "TimeRemainingColumn" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_BASE_URL" + ] + }, + { + "module": "dotenv", + "names": [ + "load_dotenv" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "call_llm", + "async_call_llm" + ] + }, + { + "module": "openai", + "names": [ + "AsyncOpenAI" + ] + }, + { + "module": "transformers", + "names": [ + "AutoTokenizer" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "resolve_provider_client" + ] + }, + { + "module": "openai", + "names": [ + "OpenAI" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "call_llm" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "async_call_llm" + ] + } + ] + }, + "rl_cli.py": { + "imports": [ + "asyncio", + "os", + "sys", + "fire", + "yaml", + "json", + "json", + "traceback", + "traceback" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.env_loader", + "names": [ + "load_hermes_dotenv" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "tools.rl_training_tool", + "names": [ + "get_missing_keys" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home", + "OPENROUTER_BASE_URL" + ] + }, + { + "module": "tools.rl_training_tool", + "names": [ + "rl_list_environments" + ] + }, + { + "module": "tools.rl_training_tool", + "names": [ + "rl_list_runs" + ] + } + ] + }, + "utils.py": { + "imports": [ + "json", + "os", + "tempfile", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Union" + ] + } + ] + }, + "hermes_time.py": { + "imports": [ + "logging", + "os", + "yaml" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "zoneinfo", + "names": [ + "ZoneInfo" + ] + }, + { + "module": "backports.zoneinfo", + "names": [ + "ZoneInfo" + ] + } + ] + }, + "run_agent.py": { + "imports": [ + "atexit", + "asyncio", + "base64", + "concurrent.futures", + "copy", + "hashlib", + "json", + "logging", + "os", + "random", + "re", + "sys", + "tempfile", + "time", + "threading", + "weakref", + "uuid", + "fire", + "threading", + "re", + "hashlib", + "socket", + "httpx", + "contextlib", + "os", + "httpx", + "httpx", + "socket" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Dict", + "Any", + "Optional" + ] + }, + { + "module": "openai", + "names": [ + "OpenAI" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.env_loader", + "names": [ + "load_hermes_dotenv" + ] + }, + { + "module": "model_tools", + "names": [ + "get_tool_definitions", + "get_toolset_for_tool", + "handle_function_call", + "check_toolset_requirements" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "cleanup_vm" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "set_interrupt" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "cleanup_browser" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_BASE_URL" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "DEFAULT_AGENT_IDENTITY", + "PLATFORM_HINTS", + "MEMORY_GUIDANCE", + "SESSION_SEARCH_GUIDANCE", + "SKILLS_GUIDANCE", + "build_nous_subscription_prompt" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "fetch_model_metadata", + "estimate_tokens_rough", + "estimate_messages_tokens_rough", + "estimate_request_tokens_rough", + "get_next_probe_tier", + "parse_context_limit_from_error", + "save_context_length", + "is_local_endpoint" + ] + }, + { + "module": "agent.context_compressor", + "names": [ + "ContextCompressor" + ] + }, + { + "module": "agent.prompt_caching", + "names": [ + "apply_anthropic_cache_control" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "build_skills_system_prompt", + "build_context_files_prompt", + "load_soul_md", + "TOOL_USE_ENFORCEMENT_GUIDANCE", + "TOOL_USE_ENFORCEMENT_MODELS", + "DEVELOPER_ROLE_MODELS", + "GOOGLE_MODEL_OPERATIONAL_GUIDANCE" + ] + }, + { + "module": "agent.usage_pricing", + "names": [ + "estimate_usage_cost", + "normalize_usage" + ] + }, + { + "module": "agent.display", + "names": [ + "KawaiiSpinner", + "build_tool_preview", + "get_cute_tool_message", + "_detect_tool_failure", + "get_tool_emoji" + ] + }, + { + "module": "agent.trajectory", + "names": [ + "convert_scratchpad_to_think", + "has_incomplete_scratchpad", + "save_trajectory" + ] + }, + { + "module": "utils", + "names": [ + "atomic_json_write", + "env_var_enabled" + ] + }, + { + "module": "logging.handlers", + "names": [ + "RotatingFileHandler" + ] + }, + { + "module": "agent.redact", + "names": [ + "RedactingFormatter" + ] + }, + { + "module": "tools.checkpoint_manager", + "names": [ + "CheckpointManager" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "TodoStore" + ] + }, + { + "module": "hermes_time", + "names": [ + "now" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "MAX_CONCURRENT_CHILDREN" + ] + }, + { + "module": "difflib", + "names": [ + "get_close_matches" + ] + }, + { + "module": "unittest.mock", + "names": [ + "Mock" + ] + }, + { + "module": "unittest.mock", + "names": [ + "Mock" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_is_oauth_token" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_OR_HEADERS" + ] + }, + { + "module": "agent.display", + "names": [ + "format_context_pressure", + "format_context_pressure_gateway" + ] + }, + { + "module": "model_tools", + "names": [ + "get_all_tool_names", + "get_toolset_for_tool", + "get_available_toolsets" + ] + }, + { + "module": "toolsets", + "names": [ + "get_all_toolsets", + "get_toolset_info" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_client", + "resolve_anthropic_token" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_is_oauth_token" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "agent.copilot_acp_client", + "names": [ + "CopilotACPClient" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "resolve_codex_runtime_credentials" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "resolve_nous_runtime_credentials" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "resolve_anthropic_token", + "build_anthropic_client" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_client", + "_is_oauth_token" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "resolve_provider_client" + ] + }, + { + "module": "tools.vision_tools", + "names": [ + "vision_analyze_tool" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_kwargs" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "github_model_reasoning_efforts" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "call_llm" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "reset_file_dedup" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "todo_tool" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "invoke_hook" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "invoke_hook" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "resolve_provider_client" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_default_headers" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_client", + "resolve_anthropic_token", + "_is_oauth_token" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_client" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_client" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "github_model_reasoning_efforts" + ] + }, + { + "module": "tools.session_search_tool", + "names": [ + "session_search" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "todo_tool" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "invoke_hook" + ] + }, + { + "module": "tools.memory_tool", + "names": [ + "MemoryStore" + ] + }, + { + "module": "agent.memory_manager", + "names": [ + "MemoryManager" + ] + }, + { + "module": "plugins.memory", + "names": [ + "load_memory_provider" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_get_anthropic_max_output" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_kwargs" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "normalize_anthropic_response" + ] + }, + { + "module": "tools.memory_tool", + "names": [ + "memory_tool" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_kwargs", + "normalize_anthropic_response" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "invoke_hook" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_default_headers" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_client" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_client" + ] + }, + { + "module": "tools.memory_tool", + "names": [ + "memory_tool" + ] + }, + { + "module": "tools.session_search_tool", + "names": [ + "session_search" + ] + }, + { + "module": "tools.memory_tool", + "names": [ + "memory_tool" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_kwargs", + "normalize_anthropic_response" + ] + }, + { + "module": "unittest.mock", + "names": [ + "Mock" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "normalize_anthropic_response" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "get_active_profile_name" + ] + }, + { + "module": "tools.clarify_tool", + "names": [ + "clarify_tool" + ] + }, + { + "module": "tools.clarify_tool", + "names": [ + "clarify_tool" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_is_oauth_token" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "openai", + "names": [ + "APIError" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "delegate_task" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "delegate_task" + ] + } + ] + }, + "toolset_distributions.py": { + "imports": [ + "random" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional" + ] + }, + { + "module": "toolsets", + "names": [ + "validate_toolset" + ] + } + ] + }, + "cli.py": { + "imports": [ + "logging", + "os", + "shutil", + "sys", + "json", + "atexit", + "tempfile", + "time", + "uuid", + "textwrap", + "yaml", + "threading", + "queue", + "fire", + "subprocess", + "subprocess", + "subprocess", + "subprocess", + "time", + "time", + "re", + "textwrap", + "time", + "asyncio", + "json", + "shlex", + "shlex", + "shutil", + "subprocess", + "platform", + "os", + "time", + "yaml", + "time", + "time", + "time", + "asyncio", + "re", + "socket", + "re", + "time", + "time", + "sys", + "os", + "signal", + "time", + "time", + "signal", + "json", + "time", + "re", + "asyncio", + "time", + "time", + "socket", + "time", + "time", + "subprocess" + ], + "from_imports": [ + { + "module": "contextlib", + "names": [ + "contextmanager" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Dict", + "Any", + "Optional" + ] + }, + { + "module": "prompt_toolkit.history", + "names": [ + "FileHistory" + ] + }, + { + "module": "prompt_toolkit.styles", + "names": [ + "Style" + ] + }, + { + "module": "prompt_toolkit.patch_stdout", + "names": [ + "patch_stdout" + ] + }, + { + "module": "prompt_toolkit.application", + "names": [ + "Application" + ] + }, + { + "module": "prompt_toolkit.layout", + "names": [ + "Layout", + "HSplit", + "Window", + "FormattedTextControl", + "ConditionalContainer" + ] + }, + { + "module": "prompt_toolkit.layout.processors", + "names": [ + "Processor", + "Transformation", + "PasswordProcessor", + "ConditionalProcessor" + ] + }, + { + "module": "prompt_toolkit.filters", + "names": [ + "Condition" + ] + }, + { + "module": "prompt_toolkit.layout.dimension", + "names": [ + "Dimension" + ] + }, + { + "module": "prompt_toolkit.layout.menus", + "names": [ + "CompletionsMenu" + ] + }, + { + "module": "prompt_toolkit.widgets", + "names": [ + "TextArea" + ] + }, + { + "module": "prompt_toolkit.key_binding", + "names": [ + "KeyBindings" + ] + }, + { + "module": "prompt_toolkit", + "names": [ + "print_formatted_text" + ] + }, + { + "module": "prompt_toolkit.formatted_text", + "names": [ + "ANSI" + ] + }, + { + "module": "agent.usage_pricing", + "names": [ + "CanonicalUsage", + "estimate_usage_cost", + "format_duration_compact", + "format_token_count_compact" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "_format_context_length" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home", + "display_hermes_home", + "OPENROUTER_BASE_URL" + ] + }, + { + "module": "hermes_cli.env_loader", + "names": [ + "load_hermes_dotenv" + ] + }, + { + "module": "rich", + "names": [ + "box" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "rich.markup", + "names": [ + "escape" + ] + }, + { + "module": "rich.panel", + "names": [ + "Panel" + ] + }, + { + "module": "rich.text", + "names": [ + "Text" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "model_tools", + "names": [ + "get_tool_definitions", + "get_toolset_for_tool" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "build_welcome_banner" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "SlashCommandCompleter", + "SlashCommandAutoSuggest" + ] + }, + { + "module": "toolsets", + "names": [ + "get_all_toolsets", + "get_toolset_info", + "validate_toolset" + ] + }, + { + "module": "cron", + "names": [ + "get_job" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "cleanup_all_environments" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "set_sudo_password_callback", + "set_approval_callback" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "set_secret_capture_callback" + ] + }, + { + "module": "hermes_cli.callbacks", + "names": [ + "prompt_for_secret" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_emergency_cleanup_all_sessions" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "scan_skill_commands", + "build_skill_invocation_message", + "build_plan_path", + "build_preloaded_skills_prompt" + ] + }, + { + "module": "prompt_toolkit.cursor_shapes", + "names": [ + "CursorShape" + ] + }, + { + "module": "hermes_constants", + "names": [ + "parse_reasoning_effort" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "_expand_env_vars" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "init_skin_from_config" + ] + }, + { + "module": "agent.display", + "names": [ + "set_tool_preview_max_len" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "neuter_async_httpx_del" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "shutdown_mcp_servers" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "shutdown_cached_clients" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "io", + "names": [ + "StringIO" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "get_plugin_manager" + ] + }, + { + "module": "utils", + "names": [ + "atomic_yaml_write" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider", + "format_runtime_provider_error" + ] + }, + { + "module": "agent.smart_model_routing", + "names": [ + "resolve_turn_route" + ] + }, + { + "module": "rich.panel", + "names": [ + "Panel" + ] + }, + { + "module": "rich.text", + "names": [ + "Text" + ] + }, + { + "module": "hermes_cli.clipboard", + "names": [ + "save_clipboard_image" + ] + }, + { + "module": "tools.checkpoint_manager", + "names": [ + "format_checkpoint_list" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "process_registry" + ] + }, + { + "module": "hermes_cli.clipboard", + "names": [ + "has_clipboard_image" + ] + }, + { + "module": "tools.vision_tools", + "names": [ + "vision_analyze_tool" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "COMMANDS_BY_CATEGORY" + ] + }, + { + "module": "argparse", + "names": [ + "Namespace" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "tools_disable_enable_command" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "_get_platform_tools" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home", + "display_hermes_home" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_relative_time" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_resolve_session_by_name_or_id" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "curated_models_for_provider", + "list_available_providers", + "normalize_provider", + "_PROVIDER_LABELS" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "resolve_provider" + ] + }, + { + "module": "tools.cronjob_tools", + "names": [ + "cronjob" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config", + "Platform" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "resolve_command" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_config_path" + ] + }, + { + "module": "agent.display", + "names": [ + "get_tool_emoji" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder", + "check_voice_requirements" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "check_voice_requirements", + "detect_audio_environment" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "check_voice_requirements" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "get_plugin_manager" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_config_path" + ] + }, + { + "module": "prompt_toolkit.keys", + "names": [ + "Keys" + ] + }, + { + "module": "prompt_toolkit.auto_suggest", + "names": [ + "AutoSuggestFromHistory" + ] + }, + { + "module": "gateway.run", + "names": [ + "start_gateway" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "_get_platform_tools" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "prompt_toolkit.utils", + "names": [ + "get_cwidth" + ] + }, + { + "module": "prompt_toolkit.utils", + "names": [ + "get_cwidth" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "model_tools", + "names": [ + "check_tool_availability" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_help_header" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "list_skins", + "set_active_skin", + "get_active_skin_name" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "estimate_messages_tokens_rough" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "agent.insights", + "names": [ + "InsightsEngine" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "shutdown_mcp_servers", + "discover_mcp_tools", + "_servers", + "_lock" + ] + }, + { + "module": "agent.display", + "names": [ + "get_tool_emoji" + ] + }, + { + "module": "agent.display", + "names": [ + "get_tool_preview_max_len" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_beep" + ] + }, + { + "module": "agent.display", + "names": [ + "capture_local_edit_snapshot" + ] + }, + { + "module": "agent.display", + "names": [ + "render_edit_diff_with_delta" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_beep" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "transcribe_recording" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "text_to_speech_tool" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_audio_file" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "stop_playback" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "check_tts_requirements" + ] + }, + { + "module": "run_agent", + "names": [ + "_sanitize_surrogates" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_prompt_symbol" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "get_active_profile_name" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_prompt_toolkit_style_overrides" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "ensure_installed" + ] + }, + { + "module": "prompt_toolkit.application", + "names": [ + "run_in_terminal" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "prompt_toolkit.data_structures", + "names": [ + "Point" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "_auto_detect_local_model" + ] + }, + { + "module": "prompt_toolkit.application", + "names": [ + "get_app" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_model_api_mode", + "normalize_copilot_model_id" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "normalize_opencode_model_id", + "opencode_model_api_mode" + ] + }, + { + "module": "hermes_cli.codex_models", + "names": [ + "get_codex_model_ids" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "cleanup_all_browsers" + ] + }, + { + "module": "model_tools", + "names": [ + "get_tool_definitions" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_beep" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "cleanup_stale_async_clients" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_goodbye" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "cleanup_temp_recordings" + ] + }, + { + "module": "prompt_toolkit.application", + "names": [ + "get_app" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "TodoStore" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "TodoStore" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "TodoStore" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "_load_tts_config", + "_get_provider", + "_import_elevenlabs", + "_import_sounddevice", + "stream_tts_to_speaker" + ] + }, + { + "module": "agent.title_generator", + "names": [ + "maybe_auto_title" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "invoke_hook" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_get_custom_base_url" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "cleanup_all_browsers" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "stop_playback" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "get_plugin_manager" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "get_plugin_command_handler" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "COMMANDS" + ] + } + ] + }, + "toolsets.py": { + "imports": [], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Dict", + "Any", + "Set", + "Optional" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "hermes_state.py": { + "imports": [ + "json", + "logging", + "os", + "random", + "re", + "sqlite3", + "threading", + "time" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Callable", + "Dict", + "List", + "Optional", + "TypeVar" + ] + } + ] + }, + "batch_runner.py": { + "imports": [ + "json", + "logging", + "os", + "time", + "traceback", + "fire", + "subprocess" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Dict", + "Any", + "Optional", + "Tuple" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "multiprocessing", + "names": [ + "Pool", + "Lock" + ] + }, + { + "module": "rich.progress", + "names": [ + "Progress", + "SpinnerColumn", + "BarColumn", + "TextColumn", + "TimeRemainingColumn", + "MofNCompleteColumn" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "toolset_distributions", + "names": [ + "list_distributions", + "sample_toolsets_from_distribution", + "validate_distribution" + ] + }, + { + "module": "model_tools", + "names": [ + "TOOL_TO_TOOLSET_MAP" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "register_task_env_overrides" + ] + }, + { + "module": "utils", + "names": [ + "atomic_json_write" + ] + }, + { + "module": "toolset_distributions", + "names": [ + "list_distributions", + "print_distribution_info" + ] + } + ] + }, + "model_tools.py": { + "imports": [ + "json", + "asyncio", + "logging", + "threading", + "importlib", + "concurrent.futures" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Dict", + "Any", + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "toolsets", + "names": [ + "resolve_toolset", + "validate_toolset" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "discover_plugins" + ] + }, + { + "module": "tools.code_execution_tool", + "names": [ + "SANDBOX_ALLOWED_TOOLS", + "build_execute_code_schema" + ] + }, + { + "module": "toolsets", + "names": [ + "get_all_toolsets" + ] + }, + { + "module": "toolsets", + "names": [ + "get_all_toolsets" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "notify_other_tool_call" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "invoke_hook" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "invoke_hook" + ] + } + ] + }, + "environments/web_research_env.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "random", + "re", + "sys", + "time", + "uuid" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urlparse" + ] + }, + { + "module": "pydantic", + "names": [ + "Field" + ] + }, + { + "module": "atroposlib.envs.base", + "names": [ + "ScoredDataGroup" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "APIServerConfig" + ] + }, + { + "module": "atroposlib.type_definitions", + "names": [ + "Item" + ] + }, + { + "module": "environments.hermes_base_env", + "names": [ + "HermesAgentBaseEnv", + "HermesAgentEnvConfig" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "AgentResult" + ] + }, + { + "module": "environments.tool_context", + "names": [ + "ToolContext" + ] + }, + { + "module": "datasets", + "names": [ + "load_dataset" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "HermesAgentLoop" + ] + }, + { + "module": "environments.tool_context", + "names": [ + "ToolContext" + ] + } + ] + }, + "environments/tool_context.py": { + "imports": [ + "json", + "logging", + "os", + "asyncio", + "concurrent.futures", + "concurrent.futures", + "os", + "base64", + "base64" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "model_tools", + "names": [ + "handle_function_call" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "cleanup_vm" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "cleanup_browser" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "process_registry" + ] + } + ] + }, + "environments/hermes_base_env.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "sys", + "uuid" + ], + "from_imports": [ + { + "module": "abc", + "names": [ + "abstractmethod" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Set", + "Tuple", + "Union" + ] + }, + { + "module": "dotenv", + "names": [ + "load_dotenv" + ] + }, + { + "module": "pydantic", + "names": [ + "Field" + ] + }, + { + "module": "environments.patches", + "names": [ + "apply_patches" + ] + }, + { + "module": "atroposlib.envs.base", + "names": [ + "BaseEnv", + "BaseEnvConfig", + "ScoredDataGroup", + "ScoredDataItem" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "APIServerConfig", + "ServerBaseline", + "ServerManager" + ] + }, + { + "module": "atroposlib.type_definitions", + "names": [ + "Item" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "AgentResult", + "HermesAgentLoop" + ] + }, + { + "module": "environments.tool_context", + "names": [ + "ToolContext" + ] + }, + { + "module": "model_tools", + "names": [ + "get_tool_definitions" + ] + }, + { + "module": "toolset_distributions", + "names": [ + "sample_toolsets_from_distribution" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "resize_tool_pool" + ] + }, + { + "module": "atroposlib.envs.server_handling.openai_server", + "names": [ + "OpenAIServer" + ] + } + ] + }, + "environments/__init__.py": { + "imports": [], + "from_imports": [ + { + "module": "environments.agent_loop", + "names": [ + "AgentResult", + "HermesAgentLoop" + ] + }, + { + "module": "environments.tool_context", + "names": [ + "ToolContext" + ] + }, + { + "module": "environments.hermes_base_env", + "names": [ + "HermesAgentBaseEnv", + "HermesAgentEnvConfig" + ] + } + ] + }, + "environments/agentic_opd_env.py": { + "imports": [ + "asyncio", + "copy", + "json", + "logging", + "os", + "random", + "re", + "sys", + "time", + "uuid" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Set", + "Tuple", + "Union" + ] + }, + { + "module": "pydantic", + "names": [ + "Field" + ] + }, + { + "module": "atroposlib.envs.base", + "names": [ + "ScoredDataGroup", + "ScoredDataItem" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "APIServerConfig" + ] + }, + { + "module": "atroposlib.type_definitions", + "names": [ + "Item" + ] + }, + { + "module": "environments.hermes_base_env", + "names": [ + "HermesAgentBaseEnv", + "HermesAgentEnvConfig" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "AgentResult", + "HermesAgentLoop" + ] + }, + { + "module": "environments.tool_context", + "names": [ + "ToolContext" + ] + }, + { + "module": "datasets", + "names": [ + "load_dataset" + ] + } + ] + }, + "environments/agent_loop.py": { + "imports": [ + "asyncio", + "concurrent.futures", + "json", + "logging", + "os", + "uuid", + "time" + ], + "from_imports": [ + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Set" + ] + }, + { + "module": "model_tools", + "names": [ + "handle_function_call" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "TodoStore", + "todo_tool" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "get_parser" + ] + } + ] + }, + "environments/patches.py": { + "imports": [ + "logging" + ], + "from_imports": [] + }, + "environments/benchmarks/__init__.py": { + "imports": [], + "from_imports": [] + }, + "environments/benchmarks/terminalbench_2/__init__.py": { + "imports": [], + "from_imports": [] + }, + "environments/benchmarks/terminalbench_2/terminalbench2_env.py": { + "imports": [ + "asyncio", + "base64", + "io", + "json", + "logging", + "os", + "shutil", + "sys", + "tarfile", + "tempfile", + "time", + "uuid", + "datetime" + ], + "from_imports": [ + { + "module": "collections", + "names": [ + "defaultdict" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple", + "Union" + ] + }, + { + "module": "pydantic", + "names": [ + "Field" + ] + }, + { + "module": "atroposlib.envs.base", + "names": [ + "EvalHandlingEnum" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "APIServerConfig" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "AgentResult", + "HermesAgentLoop" + ] + }, + { + "module": "environments.hermes_base_env", + "names": [ + "HermesAgentBaseEnv", + "HermesAgentEnvConfig" + ] + }, + { + "module": "environments.tool_context", + "names": [ + "ToolContext" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "register_task_env_overrides", + "clear_task_env_overrides", + "cleanup_vm" + ] + }, + { + "module": "datasets", + "names": [ + "load_dataset" + ] + }, + { + "module": "tqdm", + "names": [ + "tqdm" + ] + }, + { + "module": "tqdm", + "names": [ + "tqdm" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "cleanup_all_environments" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "_tool_executor" + ] + }, + { + "module": "tqdm", + "names": [ + "tqdm" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "cleanup_all_environments" + ] + } + ] + }, + "environments/benchmarks/yc_bench/__init__.py": { + "imports": [], + "from_imports": [] + }, + "environments/benchmarks/yc_bench/yc_bench_env.py": { + "imports": [ + "asyncio", + "datetime", + "json", + "logging", + "math", + "os", + "sqlite3", + "subprocess", + "sys", + "threading", + "time", + "uuid" + ], + "from_imports": [ + { + "module": "collections", + "names": [ + "defaultdict" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "pydantic", + "names": [ + "Field" + ] + }, + { + "module": "atroposlib.envs.base", + "names": [ + "EvalHandlingEnum" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "APIServerConfig" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "HermesAgentLoop" + ] + }, + { + "module": "environments.hermes_base_env", + "names": [ + "HermesAgentBaseEnv", + "HermesAgentEnvConfig" + ] + }, + { + "module": "tqdm", + "names": [ + "tqdm" + ] + }, + { + "module": "tqdm", + "names": [ + "tqdm" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "cleanup_all_environments" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "_tool_executor" + ] + }, + { + "module": "tqdm", + "names": [ + "tqdm" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "cleanup_all_environments" + ] + } + ] + }, + "environments/benchmarks/tblite/__init__.py": { + "imports": [], + "from_imports": [] + }, + "environments/benchmarks/tblite/tblite_env.py": { + "imports": [ + "os", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Tuple" + ] + }, + { + "module": "pydantic", + "names": [ + "Field" + ] + }, + { + "module": "atroposlib.envs.base", + "names": [ + "EvalHandlingEnum" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "APIServerConfig" + ] + }, + { + "module": "environments.benchmarks.terminalbench_2.terminalbench2_env", + "names": [ + "TerminalBench2EvalConfig", + "TerminalBench2EvalEnv" + ] + } + ] + }, + "environments/tool_call_parsers/glm45_parser.py": { + "imports": [ + "ast", + "json", + "re", + "uuid" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "openai.types.chat.chat_completion_message_tool_call", + "names": [ + "ChatCompletionMessageToolCall", + "Function" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "ToolCallParser", + "register_parser" + ] + } + ] + }, + "environments/tool_call_parsers/glm47_parser.py": { + "imports": [ + "re" + ], + "from_imports": [ + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "register_parser" + ] + }, + { + "module": "environments.tool_call_parsers.glm45_parser", + "names": [ + "Glm45ToolCallParser" + ] + } + ] + }, + "environments/tool_call_parsers/llama_parser.py": { + "imports": [ + "json", + "re", + "uuid" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Optional" + ] + }, + { + "module": "openai.types.chat.chat_completion_message_tool_call", + "names": [ + "ChatCompletionMessageToolCall", + "Function" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "ToolCallParser", + "register_parser" + ] + } + ] + }, + "environments/tool_call_parsers/deepseek_v3_parser.py": { + "imports": [ + "re", + "uuid", + "logging" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "openai.types.chat.chat_completion_message_tool_call", + "names": [ + "ChatCompletionMessageToolCall", + "Function" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "ToolCallParser", + "register_parser" + ] + } + ] + }, + "environments/tool_call_parsers/qwen_parser.py": { + "imports": [], + "from_imports": [ + { + "module": "environments.tool_call_parsers", + "names": [ + "register_parser" + ] + }, + { + "module": "environments.tool_call_parsers.hermes_parser", + "names": [ + "HermesToolCallParser" + ] + } + ] + }, + "environments/tool_call_parsers/__init__.py": { + "imports": [ + "logging" + ], + "from_imports": [ + { + "module": "abc", + "names": [ + "ABC", + "abstractmethod" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional", + "Tuple", + "Type" + ] + }, + { + "module": "openai.types.chat.chat_completion_message_tool_call", + "names": [ + "ChatCompletionMessageToolCall" + ] + }, + { + "module": "environments.tool_call_parsers.hermes_parser", + "names": [ + "HermesToolCallParser" + ] + }, + { + "module": "environments.tool_call_parsers.longcat_parser", + "names": [ + "LongcatToolCallParser" + ] + }, + { + "module": "environments.tool_call_parsers.mistral_parser", + "names": [ + "MistralToolCallParser" + ] + }, + { + "module": "environments.tool_call_parsers.llama_parser", + "names": [ + "LlamaToolCallParser" + ] + }, + { + "module": "environments.tool_call_parsers.qwen_parser", + "names": [ + "QwenToolCallParser" + ] + }, + { + "module": "environments.tool_call_parsers.deepseek_v3_parser", + "names": [ + "DeepSeekV3ToolCallParser" + ] + }, + { + "module": "environments.tool_call_parsers.deepseek_v3_1_parser", + "names": [ + "DeepSeekV31ToolCallParser" + ] + }, + { + "module": "environments.tool_call_parsers.kimi_k2_parser", + "names": [ + "KimiK2ToolCallParser" + ] + }, + { + "module": "environments.tool_call_parsers.glm45_parser", + "names": [ + "Glm45ToolCallParser" + ] + }, + { + "module": "environments.tool_call_parsers.glm47_parser", + "names": [ + "Glm47ToolCallParser" + ] + }, + { + "module": "environments.tool_call_parsers.qwen3_coder_parser", + "names": [ + "Qwen3CoderToolCallParser" + ] + } + ] + }, + "environments/tool_call_parsers/kimi_k2_parser.py": { + "imports": [ + "re", + "uuid" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Optional" + ] + }, + { + "module": "openai.types.chat.chat_completion_message_tool_call", + "names": [ + "ChatCompletionMessageToolCall", + "Function" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "ToolCallParser", + "register_parser" + ] + } + ] + }, + "environments/tool_call_parsers/longcat_parser.py": { + "imports": [ + "json", + "re", + "uuid" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Optional" + ] + }, + { + "module": "openai.types.chat.chat_completion_message_tool_call", + "names": [ + "ChatCompletionMessageToolCall", + "Function" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "ToolCallParser", + "register_parser" + ] + } + ] + }, + "environments/tool_call_parsers/qwen3_coder_parser.py": { + "imports": [ + "ast", + "json", + "re", + "uuid" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "openai.types.chat.chat_completion_message_tool_call", + "names": [ + "ChatCompletionMessageToolCall", + "Function" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "ToolCallParser", + "register_parser" + ] + } + ] + }, + "environments/tool_call_parsers/mistral_parser.py": { + "imports": [ + "json", + "uuid", + "random", + "string" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Optional" + ] + }, + { + "module": "openai.types.chat.chat_completion_message_tool_call", + "names": [ + "ChatCompletionMessageToolCall", + "Function" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "ToolCallParser", + "register_parser" + ] + } + ] + }, + "environments/tool_call_parsers/deepseek_v3_1_parser.py": { + "imports": [ + "re", + "uuid" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Optional" + ] + }, + { + "module": "openai.types.chat.chat_completion_message_tool_call", + "names": [ + "ChatCompletionMessageToolCall", + "Function" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "ToolCallParser", + "register_parser" + ] + } + ] + }, + "environments/tool_call_parsers/hermes_parser.py": { + "imports": [ + "json", + "re", + "uuid" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "openai.types.chat.chat_completion_message_tool_call", + "names": [ + "ChatCompletionMessageToolCall", + "Function" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "ToolCallParser", + "register_parser" + ] + } + ] + }, + "environments/hermes_swe_env/hermes_swe_env.py": { + "imports": [ + "logging", + "sys", + "time" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple", + "Union" + ] + }, + { + "module": "datasets", + "names": [ + "load_dataset" + ] + }, + { + "module": "atroposlib.envs.base", + "names": [ + "ScoredDataGroup" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "APIServerConfig" + ] + }, + { + "module": "atroposlib.type_definitions", + "names": [ + "Item" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "AgentResult" + ] + }, + { + "module": "environments.hermes_base_env", + "names": [ + "HermesAgentBaseEnv", + "HermesAgentEnvConfig" + ] + }, + { + "module": "environments.tool_context", + "names": [ + "ToolContext" + ] + } + ] + }, + "environments/hermes_swe_env/__init__.py": { + "imports": [], + "from_imports": [] + }, + "environments/terminal_test_env/terminal_test_env.py": { + "imports": [ + "logging", + "os", + "sys", + "time" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple", + "Union" + ] + }, + { + "module": "atroposlib.envs.base", + "names": [ + "ScoredDataGroup" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "APIServerConfig" + ] + }, + { + "module": "atroposlib.type_definitions", + "names": [ + "Item" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "AgentResult" + ] + }, + { + "module": "environments.hermes_base_env", + "names": [ + "HermesAgentBaseEnv", + "HermesAgentEnvConfig" + ] + }, + { + "module": "environments.tool_context", + "names": [ + "ToolContext" + ] + } + ] + }, + "environments/terminal_test_env/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tools/mcp_tool.py": { + "imports": [ + "asyncio", + "inspect", + "json", + "logging", + "math", + "os", + "re", + "shutil", + "threading", + "time", + "signal", + "psutil", + "re", + "httpx" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "mcp", + "names": [ + "ClientSession", + "StdioServerParameters" + ] + }, + { + "module": "mcp.client.stdio", + "names": [ + "stdio_client" + ] + }, + { + "module": "toolsets", + "names": [ + "TOOLSETS" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "toolsets", + "names": [ + "create_custom_toolset", + "TOOLSETS" + ] + }, + { + "module": "mcp.client.streamable_http", + "names": [ + "streamablehttp_client" + ] + }, + { + "module": "mcp.client.streamable_http", + "names": [ + "streamable_http_client" + ] + }, + { + "module": "mcp.types", + "names": [ + "CreateMessageResult", + "CreateMessageResultWithTools", + "ErrorData", + "SamplingCapability", + "SamplingToolsCapability", + "TextContent", + "ToolUseContent" + ] + }, + { + "module": "mcp.types", + "names": [ + "ServerNotification", + "ToolListChangedNotification", + "PromptListChangedNotification", + "ResourceListChangedNotification" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "call_llm" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "toolsets", + "names": [ + "TOOLSETS" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.env_loader", + "names": [ + "load_hermes_dotenv" + ] + }, + { + "module": "tools.mcp_oauth", + "names": [ + "build_oauth_auth" + ] + } + ] + }, + "tools/approval.py": { + "imports": [ + "contextvars", + "logging", + "os", + "re", + "sys", + "threading", + "unicodedata" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "tools.ansi_strip", + "names": [ + "strip_ansi" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "get_text_auxiliary_client", + "auxiliary_max_tokens_param" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "check_command_security" + ] + } + ] + }, + "tools/website_policy.py": { + "imports": [ + "fnmatch", + "logging", + "os", + "threading", + "time", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urlparse" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "tools/skill_manager_tool.py": { + "imports": [ + "json", + "logging", + "os", + "re", + "shutil", + "tempfile", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "Any", + "Optional" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.skills_guard", + "names": [ + "scan_skill", + "should_allow_install", + "format_scan_report" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_all_skills_dirs" + ] + }, + { + "module": "tools.fuzzy_match", + "names": [ + "fuzzy_find_and_replace" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "clear_skills_system_prompt_cache" + ] + } + ] + }, + "tools/neutts_synth.py": { + "imports": [ + "argparse", + "struct", + "sys", + "numpy", + "soundfile" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "neutts", + "names": [ + "NeuTTS" + ] + } + ] + }, + "tools/fuzzy_match.py": { + "imports": [ + "re" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Tuple", + "Optional", + "List", + "Callable" + ] + }, + { + "module": "difflib", + "names": [ + "SequenceMatcher" + ] + } + ] + }, + "tools/code_execution_tool.py": { + "imports": [ + "json", + "logging", + "os", + "platform", + "signal", + "socket", + "subprocess", + "sys", + "tempfile", + "threading", + "time", + "uuid", + "shutil" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "model_tools", + "names": [ + "handle_function_call" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_interrupt_event" + ] + }, + { + "module": "tools.ansi_strip", + "names": [ + "strip_ansi" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "cli", + "names": [ + "CLI_CONFIG" + ] + }, + { + "module": "tools.env_passthrough", + "names": [ + "is_env_passthrough" + ] + }, + { + "module": "collections", + "names": [ + "deque" + ] + } + ] + }, + "tools/mixture_of_agents_tool.py": { + "imports": [ + "json", + "logging", + "os", + "asyncio", + "datetime" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Dict", + "Any", + "List", + "Optional" + ] + }, + { + "module": "tools.openrouter_client", + "names": [ + "get_async_client", + "check_api_key" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "extract_content_or_reasoning" + ] + }, + { + "module": "tools.debug_helpers", + "names": [ + "DebugSession" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tools/homeassistant_tool.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "re", + "aiohttp", + "aiohttp", + "aiohttp", + "aiohttp", + "concurrent.futures" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tools/skills_tool.py": { + "imports": [ + "json", + "logging", + "os", + "re", + "sys", + "yaml", + "os", + "logging" + ], + "from_imports": [ + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "enum", + "names": [ + "Enum" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "Any", + "List", + "Optional", + "Set", + "Tuple" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "skill_matches_platform" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "parse_frontmatter" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_disabled_skill_names" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "GATEWAY_SECRET_CAPTURE_UNSUPPORTED_MESSAGE" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "tools.env_passthrough", + "names": [ + "register_env_passthrough" + ] + }, + { + "module": "tools.credential_files", + "names": [ + "register_credential_files" + ] + } + ] + }, + "tools/image_generation_tool.py": { + "imports": [ + "json", + "logging", + "os", + "datetime", + "threading", + "uuid", + "fal_client", + "fal_client", + "fal_client" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Dict", + "Any", + "Optional", + "Union" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urlencode" + ] + }, + { + "module": "tools.debug_helpers", + "names": [ + "DebugSession" + ] + }, + { + "module": "tools.managed_tool_gateway", + "names": [ + "resolve_managed_tool_gateway" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tools/memory_tool.py": { + "imports": [ + "fcntl", + "json", + "logging", + "os", + "re", + "tempfile" + ], + "from_imports": [ + { + "module": "contextlib", + "names": [ + "contextmanager" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "Any", + "List", + "Optional" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tools/registry.py": { + "imports": [ + "json", + "logging" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Callable", + "Dict", + "List", + "Optional", + "Set" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async" + ] + } + ] + }, + "tools/vision_tools.py": { + "imports": [ + "base64", + "json", + "logging", + "os", + "uuid", + "httpx", + "asyncio" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Awaitable", + "Dict", + "Optional" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urlparse" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "async_call_llm", + "extract_content_or_reasoning" + ] + }, + { + "module": "tools.debug_helpers", + "names": [ + "DebugSession" + ] + }, + { + "module": "tools.website_policy", + "names": [ + "check_website_access" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.url_safety", + "names": [ + "is_safe_url" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "resolve_vision_provider_client" + ] + }, + { + "module": "tools.url_safety", + "names": [ + "is_safe_url" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + } + ] + }, + "tools/managed_tool_gateway.py": { + "imports": [ + "json", + "logging", + "os" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "typing", + "names": [ + "Callable", + "Optional" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "resolve_nous_access_token" + ] + } + ] + }, + "tools/__init__.py": { + "imports": [], + "from_imports": [ + { + "module": "terminal_tool", + "names": [ + "check_terminal_requirements" + ] + } + ] + }, + "tools/credential_files.py": { + "imports": [ + "logging", + "os", + "atexit", + "shutil", + "tempfile", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_dir" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_dir" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + } + ] + }, + "tools/browser_camofox.py": { + "imports": [ + "base64", + "json", + "logging", + "os", + "threading", + "time", + "uuid", + "requests", + "re" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "tools.browser_camofox_state", + "names": [ + "get_camofox_identity" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "SNAPSHOT_SUMMARIZE_THRESHOLD", + "_extract_relevant_content", + "_truncate_snapshot" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "call_llm" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urlparse" + ] + } + ] + }, + "tools/session_search_tool.py": { + "imports": [ + "asyncio", + "concurrent.futures", + "json", + "logging" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Dict", + "Any", + "List", + "Optional", + "Union" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "async_call_llm", + "extract_content_or_reasoning" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "hermes_state", + "names": [ + "DEFAULT_DB_PATH" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + } + ] + }, + "tools/delegate_tool.py": { + "imports": [ + "json", + "logging", + "os", + "time", + "model_tools", + "model_tools", + "model_tools" + ], + "from_imports": [ + { + "module": "concurrent.futures", + "names": [ + "ThreadPoolExecutor", + "as_completed" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "cli", + "names": [ + "CLI_CONFIG" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "agent.display", + "names": [ + "get_tool_emoji" + ] + } + ] + }, + "tools/tirith_security.py": { + "imports": [ + "hashlib", + "json", + "logging", + "os", + "platform", + "shutil", + "stat", + "subprocess", + "tarfile", + "tempfile", + "threading", + "time", + "urllib.request" + ], + "from_imports": [ + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + } + ] + }, + "tools/ansi_strip.py": { + "imports": [ + "re" + ], + "from_imports": [] + }, + "tools/process_registry.py": { + "imports": [ + "json", + "logging", + "os", + "platform", + "shlex", + "signal", + "subprocess", + "threading", + "time", + "uuid", + "json" + ], + "from_imports": [ + { + "module": "tools.environments.local", + "names": [ + "_find_shell", + "_sanitize_subprocess_env" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.ansi_strip", + "names": [ + "strip_ansi" + ] + }, + { + "module": "tools.ansi_strip", + "names": [ + "strip_ansi" + ] + }, + { + "module": "tools.ansi_strip", + "names": [ + "strip_ansi" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_interrupt_event" + ] + }, + { + "module": "utils", + "names": [ + "atomic_json_write" + ] + }, + { + "module": "utils", + "names": [ + "atomic_json_write" + ] + }, + { + "module": "winpty", + "names": [ + "PtyProcess" + ] + }, + { + "module": "ptyprocess", + "names": [ + "PtyProcess" + ] + } + ] + }, + "tools/patch_parser.py": { + "imports": [ + "re", + "difflib" + ], + "from_imports": [ + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Optional", + "Tuple", + "Any" + ] + }, + { + "module": "enum", + "names": [ + "Enum" + ] + }, + { + "module": "tools.file_operations", + "names": [ + "PatchResult" + ] + }, + { + "module": "tools.fuzzy_match", + "names": [ + "fuzzy_find_and_replace" + ] + } + ] + }, + "tools/send_message_tool.py": { + "imports": [ + "json", + "logging", + "os", + "re", + "ssl", + "time", + "smtplib", + "base64", + "aiohttp", + "aiohttp", + "aiohttp", + "httpx", + "aiohttp", + "aiohttp", + "aiohttp", + "aiohttp", + "httpx" + ], + "from_imports": [ + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.platforms.slack", + "names": [ + "SlackAdapter" + ] + }, + { + "module": "email.mime.text", + "names": [ + "MIMEText" + ] + }, + { + "module": "gateway.channel_directory", + "names": [ + "format_directory_for_display" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config", + "Platform" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "telegram", + "names": [ + "Bot" + ] + }, + { + "module": "telegram.constants", + "names": [ + "ParseMode" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter", + "check_wecom_requirements" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter", + "FEISHU_AVAILABLE" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FEISHU_DOMAIN", + "LARK_DOMAIN" + ] + }, + { + "module": "gateway.status", + "names": [ + "is_gateway_running" + ] + }, + { + "module": "gateway.channel_directory", + "names": [ + "resolve_channel_name" + ] + }, + { + "module": "gateway.mirror", + "names": [ + "mirror_to_session" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter", + "_strip_mdv2" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "_strip_mdv2" + ] + } + ] + }, + "tools/file_operations.py": { + "imports": [ + "os", + "re", + "difflib" + ], + "from_imports": [ + { + "module": "abc", + "names": [ + "ABC", + "abstractmethod" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "typing", + "names": [ + "Optional", + "List", + "Dict", + "Any" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "tools.fuzzy_match", + "names": [ + "fuzzy_find_and_replace" + ] + }, + { + "module": "tools.patch_parser", + "names": [ + "parse_v4a_patch", + "apply_v4a_operations" + ] + } + ] + }, + "tools/file_tools.py": { + "imports": [ + "errno", + "json", + "logging", + "os", + "threading", + "time", + "pathlib", + "re" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.file_operations", + "names": [ + "ShellFileOperations" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_active_environments", + "_env_lock", + "_create_environment", + "_get_env_config", + "_last_activity", + "_start_cleanup_thread", + "_creation_locks", + "_creation_locks_lock" + ] + }, + { + "module": "tools", + "names": [ + "check_file_requirements" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_task_env_overrides" + ] + } + ] + }, + "tools/terminal_tool.py": { + "imports": [ + "importlib.util", + "json", + "logging", + "os", + "platform", + "time", + "threading", + "atexit", + "shutil", + "subprocess", + "sys", + "time", + "re", + "glob", + "glob", + "glob", + "traceback", + "msvcrt", + "termios", + "termios", + "inspect", + "modal" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Optional", + "Dict", + "Any" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted", + "_interrupt_event" + ] + }, + { + "module": "tools.environments.singularity", + "names": [ + "_get_scratch_dir" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "coerce_modal_mode", + "has_direct_modal_credentials", + "managed_nous_tools_enabled", + "resolve_modal_backend_state" + ] + }, + { + "module": "tools.approval", + "names": [ + "check_dangerous_command", + "check_all_command_guards" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "LocalEnvironment" + ] + }, + { + "module": "tools.environments.singularity", + "names": [ + "SingularityEnvironment" + ] + }, + { + "module": "tools.environments.ssh", + "names": [ + "SSHEnvironment" + ] + }, + { + "module": "tools.environments.docker", + "names": [ + "DockerEnvironment" + ] + }, + { + "module": "tools.environments.modal", + "names": [ + "ModalEnvironment" + ] + }, + { + "module": "tools.environments.managed_modal", + "names": [ + "ManagedModalEnvironment" + ] + }, + { + "module": "tools.managed_tool_gateway", + "names": [ + "is_managed_tool_gateway_ready" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "process_registry" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "clear_file_ops_cache" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "clear_file_ops_cache" + ] + }, + { + "module": "tools.approval", + "names": [ + "get_current_session_key" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "process_registry" + ] + }, + { + "module": "tools.ansi_strip", + "names": [ + "strip_ansi" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "tools.environments.docker", + "names": [ + "find_docker" + ] + }, + { + "module": "tools.environments.daytona", + "names": [ + "DaytonaEnvironment" + ] + }, + { + "module": "daytona", + "names": [ + "Daytona" + ] + } + ] + }, + "tools/rl_training_tool.py": { + "imports": [ + "ast", + "asyncio", + "importlib.util", + "json", + "os", + "subprocess", + "sys", + "time", + "uuid", + "logging", + "yaml", + "copy", + "wandb", + "wandb" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "atroposlib.envs.base", + "names": [ + "BaseEnvConfig" + ] + } + ] + }, + "tools/skills_guard.py": { + "imports": [ + "re", + "hashlib", + "json" + ], + "from_imports": [ + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Tuple" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "call_llm", + "extract_content_or_reasoning" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + } + ] + }, + "tools/checkpoint_manager.py": { + "imports": [ + "hashlib", + "logging", + "os", + "shutil", + "subprocess", + "re" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional", + "Set" + ] + } + ] + }, + "tools/voice_mode.py": { + "imports": [ + "logging", + "os", + "platform", + "re", + "shutil", + "subprocess", + "tempfile", + "threading", + "time", + "wave", + "sounddevice", + "numpy" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider", + "_load_stt_config", + "is_stt_enabled" + ] + } + ] + }, + "tools/openrouter_client.py": { + "imports": [ + "os" + ], + "from_imports": [ + { + "module": "agent.auxiliary_client", + "names": [ + "resolve_provider_client" + ] + } + ] + }, + "tools/todo_tool.py": { + "imports": [ + "json" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Dict", + "Any", + "List", + "Optional" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tools/tool_backend_helpers.py": { + "imports": [ + "os" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict" + ] + }, + { + "module": "utils", + "names": [ + "env_var_enabled" + ] + } + ] + }, + "tools/mcp_oauth.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "socket", + "sys", + "threading", + "webbrowser", + "re" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "http.server", + "names": [ + "BaseHTTPRequestHandler", + "HTTPServer" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any" + ] + }, + { + "module": "urllib.parse", + "names": [ + "parse_qs", + "urlparse" + ] + }, + { + "module": "mcp.client.auth", + "names": [ + "OAuthClientProvider" + ] + }, + { + "module": "mcp.shared.auth", + "names": [ + "OAuthClientMetadata" + ] + }, + { + "module": "mcp.shared.auth", + "names": [ + "OAuthToken" + ] + }, + { + "module": "mcp.shared.auth", + "names": [ + "OAuthClientInformationFull" + ] + } + ] + }, + "tools/debug_helpers.py": { + "imports": [ + "datetime", + "json", + "logging", + "os", + "uuid" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict" + ] + } + ] + }, + "tools/tts_tool.py": { + "imports": [ + "asyncio", + "datetime", + "json", + "logging", + "os", + "queue", + "re", + "shutil", + "subprocess", + "tempfile", + "threading", + "uuid", + "edge_tts", + "sounddevice", + "requests", + "sys", + "importlib.util", + "wave", + "numpy", + "concurrent.futures" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Callable", + "Dict", + "Any", + "Optional" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urljoin" + ] + }, + { + "module": "tools.managed_tool_gateway", + "names": [ + "resolve_managed_tool_gateway" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled", + "resolve_openai_audio_api_key" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "elevenlabs.client", + "names": [ + "ElevenLabs" + ] + }, + { + "module": "openai", + "names": [ + "OpenAI" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_dir" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_audio_file" + ] + } + ] + }, + "tools/browser_camofox_state.py": { + "imports": [ + "uuid" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "Optional" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "tools/env_passthrough.py": { + "imports": [ + "logging", + "os", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Iterable" + ] + } + ] + }, + "tools/skills_sync.py": { + "imports": [ + "hashlib", + "logging", + "os", + "shutil", + "tempfile" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List", + "Tuple" + ] + } + ] + }, + "tools/interrupt.py": { + "imports": [ + "threading" + ], + "from_imports": [] + }, + "tools/browser_tool.py": { + "imports": [ + "atexit", + "json", + "logging", + "os", + "re", + "signal", + "subprocess", + "shutil", + "sys", + "tempfile", + "threading", + "time", + "requests", + "uuid", + "uuid", + "base64", + "uuid", + "time", + "time", + "yaml", + "yaml", + "yaml", + "yaml" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Dict", + "Any", + "Optional", + "List" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "call_llm" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "tools.browser_providers.base", + "names": [ + "CloudBrowserProvider" + ] + }, + { + "module": "tools.browser_providers.browserbase", + "names": [ + "BrowserbaseProvider" + ] + }, + { + "module": "tools.browser_providers.browser_use", + "names": [ + "BrowserUseProvider" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "normalize_browser_cloud_provider" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.website_policy", + "names": [ + "check_website_access" + ] + }, + { + "module": "tools.url_safety", + "names": [ + "is_safe_url" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "is_camofox_mode" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "agent.redact", + "names": [ + "_PREFIX_RE" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_dir" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_navigate" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_snapshot" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_click" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_type" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_scroll" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_back" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_press" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_close" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_console" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_get_images" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_vision" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + } + ] + }, + "tools/clarify_tool.py": { + "imports": [ + "json" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Optional", + "Callable" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tools/url_safety.py": { + "imports": [ + "ipaddress", + "logging", + "socket" + ], + "from_imports": [ + { + "module": "urllib.parse", + "names": [ + "urlparse" + ] + } + ] + }, + "tools/cronjob_tools.py": { + "imports": [ + "json", + "os", + "re", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "cron.jobs", + "names": [ + "create_job", + "get_job", + "list_jobs", + "parse_schedule", + "pause_job", + "remove_job", + "resume_job", + "trigger_job", + "update_job" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tools/web_tools.py": { + "imports": [ + "json", + "logging", + "os", + "re", + "asyncio", + "httpx" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Dict", + "Any", + "Optional" + ] + }, + { + "module": "firecrawl", + "names": [ + "Firecrawl" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "async_call_llm", + "extract_content_or_reasoning", + "get_async_text_auxiliary_client" + ] + }, + { + "module": "tools.debug_helpers", + "names": [ + "DebugSession" + ] + }, + { + "module": "tools.managed_tool_gateway", + "names": [ + "build_vendor_gateway_url", + "read_nous_access_token", + "resolve_managed_tool_gateway" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled" + ] + }, + { + "module": "tools.url_safety", + "names": [ + "is_safe_url" + ] + }, + { + "module": "tools.website_policy", + "names": [ + "check_website_access" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "parallel", + "names": [ + "Parallel" + ] + }, + { + "module": "parallel", + "names": [ + "AsyncParallel" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urlparse" + ] + }, + { + "module": "exa_py", + "names": [ + "Exa" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "agent.redact", + "names": [ + "_PREFIX_RE" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "get_auxiliary_extra_body" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + } + ] + }, + "tools/skills_hub.py": { + "imports": [ + "hashlib", + "json", + "logging", + "os", + "re", + "shutil", + "subprocess", + "time", + "httpx", + "yaml", + "io", + "zipfile", + "jwt" + ], + "from_imports": [ + { + "module": "abc", + "names": [ + "ABC", + "abstractmethod" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "pathlib", + "names": [ + "Path", + "PurePosixPath" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple", + "Union" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urlparse", + "urlunparse" + ] + }, + { + "module": "tools.skills_guard", + "names": [ + "ScanResult", + "content_hash", + "TRUSTED_REPOS" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_optional_skills_dir" + ] + } + ] + }, + "tools/transcription_tools.py": { + "imports": [ + "logging", + "os", + "shlex", + "shutil", + "subprocess", + "tempfile", + "importlib.util", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Optional", + "Dict", + "Any" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urljoin" + ] + }, + { + "module": "utils", + "names": [ + "is_truthy_value" + ] + }, + { + "module": "tools.managed_tool_gateway", + "names": [ + "resolve_managed_tool_gateway" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled", + "resolve_openai_audio_api_key" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "faster_whisper", + "names": [ + "WhisperModel" + ] + }, + { + "module": "openai", + "names": [ + "OpenAI", + "APIError", + "APIConnectionError", + "APITimeoutError" + ] + }, + { + "module": "openai", + "names": [ + "OpenAI", + "APIError", + "APIConnectionError", + "APITimeoutError" + ] + } + ] + }, + "tools/environments/daytona.py": { + "imports": [ + "logging", + "time", + "math", + "shlex", + "threading", + "uuid", + "warnings", + "shlex" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "tools.environments.base", + "names": [ + "BaseEnvironment" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "daytona", + "names": [ + "Daytona", + "CreateSandboxFromImageParams", + "DaytonaError", + "Resources", + "SandboxState" + ] + }, + { + "module": "tools.credential_files", + "names": [ + "get_credential_file_mounts", + "iter_skills_files" + ] + }, + { + "module": "daytona", + "names": [ + "DaytonaError" + ] + } + ] + }, + "tools/environments/modal_common.py": { + "imports": [ + "shlex", + "time", + "uuid" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "abc", + "names": [ + "abstractmethod" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "typing", + "names": [ + "Any" + ] + }, + { + "module": "tools.environments.base", + "names": [ + "BaseEnvironment" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + } + ] + }, + "tools/environments/modal.py": { + "imports": [ + "asyncio", + "json", + "logging", + "shlex", + "threading", + "modal", + "modal", + "base64" + ], + "from_imports": [ + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "tools.environments.modal_common", + "names": [ + "BaseModalExecutionEnvironment", + "ModalExecStart", + "PreparedModalExec" + ] + }, + { + "module": "tools.credential_files", + "names": [ + "get_credential_file_mounts", + "iter_skills_files", + "iter_cache_files" + ] + }, + { + "module": "tools.credential_files", + "names": [ + "get_credential_file_mounts", + "iter_skills_files", + "iter_cache_files" + ] + } + ] + }, + "tools/environments/docker.py": { + "imports": [ + "logging", + "os", + "re", + "shutil", + "subprocess", + "sys", + "threading", + "time", + "uuid" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "tools.environments.base", + "names": [ + "BaseEnvironment" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_env" + ] + }, + { + "module": "tools.environments.base", + "names": [ + "get_sandbox_dir" + ] + }, + { + "module": "tools.credential_files", + "names": [ + "get_credential_file_mounts", + "get_skills_directory_mount", + "get_cache_directory_mounts" + ] + }, + { + "module": "tools.env_passthrough", + "names": [ + "get_all_passthrough" + ] + } + ] + }, + "tools/environments/base.py": { + "imports": [ + "os", + "subprocess" + ], + "from_imports": [ + { + "module": "abc", + "names": [ + "ABC", + "abstractmethod" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_transform_sudo_command" + ] + } + ] + }, + "tools/environments/ssh.py": { + "imports": [ + "logging", + "shutil", + "subprocess", + "tempfile", + "threading", + "time" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.environments.base", + "names": [ + "BaseEnvironment" + ] + }, + { + "module": "tools.environments.persistent_shell", + "names": [ + "PersistentShellMixin" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "tools.credential_files", + "names": [ + "get_credential_file_mounts", + "get_skills_directory_mount" + ] + } + ] + }, + "tools/environments/managed_modal.py": { + "imports": [ + "json", + "logging", + "os", + "requests", + "uuid" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "tools.environments.modal_common", + "names": [ + "BaseModalExecutionEnvironment", + "ModalExecStart", + "PreparedModalExec" + ] + }, + { + "module": "tools.managed_tool_gateway", + "names": [ + "resolve_managed_tool_gateway" + ] + }, + { + "module": "tools.credential_files", + "names": [ + "get_credential_file_mounts" + ] + } + ] + }, + "tools/environments/__init__.py": { + "imports": [], + "from_imports": [ + { + "module": "tools.environments.base", + "names": [ + "BaseEnvironment" + ] + } + ] + }, + "tools/environments/singularity.py": { + "imports": [ + "json", + "logging", + "os", + "shutil", + "subprocess", + "tempfile", + "threading", + "uuid", + "time" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "tools.environments.base", + "names": [ + "BaseEnvironment" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "tools.environments.base", + "names": [ + "get_sandbox_dir" + ] + }, + { + "module": "tools.credential_files", + "names": [ + "get_credential_file_mounts", + "get_skills_directory_mount" + ] + } + ] + }, + "tools/environments/local.py": { + "imports": [ + "glob", + "os", + "platform", + "shutil", + "signal", + "subprocess", + "threading", + "time" + ], + "from_imports": [ + { + "module": "tools.environments.base", + "names": [ + "BaseEnvironment" + ] + }, + { + "module": "tools.environments.persistent_shell", + "names": [ + "PersistentShellMixin" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "OPTIONAL_ENV_VARS" + ] + }, + { + "module": "tools.env_passthrough", + "names": [ + "is_env_passthrough" + ] + }, + { + "module": "tools.env_passthrough", + "names": [ + "is_env_passthrough" + ] + } + ] + }, + "tools/environments/persistent_shell.py": { + "imports": [ + "logging", + "shlex", + "subprocess", + "threading", + "time", + "uuid" + ], + "from_imports": [ + { + "module": "abc", + "names": [ + "abstractmethod" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "is_interrupted" + ] + } + ] + }, + "tools/browser_providers/browser_use.py": { + "imports": [ + "logging", + "os", + "uuid", + "requests" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Dict" + ] + }, + { + "module": "tools.browser_providers.base", + "names": [ + "CloudBrowserProvider" + ] + } + ] + }, + "tools/browser_providers/browserbase.py": { + "imports": [ + "logging", + "os", + "threading", + "uuid", + "requests" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "tools.browser_providers.base", + "names": [ + "CloudBrowserProvider" + ] + }, + { + "module": "tools.managed_tool_gateway", + "names": [ + "resolve_managed_tool_gateway" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled" + ] + } + ] + }, + "tools/browser_providers/base.py": { + "imports": [], + "from_imports": [ + { + "module": "abc", + "names": [ + "ABC", + "abstractmethod" + ] + }, + { + "module": "typing", + "names": [ + "Dict" + ] + } + ] + }, + "tools/browser_providers/__init__.py": { + "imports": [], + "from_imports": [ + { + "module": "tools.browser_providers.base", + "names": [ + "CloudBrowserProvider" + ] + } + ] + }, + "scripts/discord-voice-doctor.py": { + "imports": [ + "os", + "sys", + "shutil", + "discord", + "nacl", + "davey", + "faster_whisper", + "edge_tts", + "elevenlabs", + "requests", + "nacl.secret", + "discord", + "yaml", + "json", + "ctypes.util", + "requests" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "dotenv", + "names": [ + "load_dotenv" + ] + } + ] + }, + "scripts/release.py": { + "imports": [ + "argparse", + "json", + "os", + "re", + "shutil", + "subprocess", + "sys" + ], + "from_imports": [ + { + "module": "collections", + "names": [ + "defaultdict" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "scripts/sample_and_compress.py": { + "imports": [ + "json", + "random", + "os", + "fire", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Dict", + "Any", + "Tuple" + ] + }, + { + "module": "dotenv", + "names": [ + "load_dotenv" + ] + }, + { + "module": "datasets", + "names": [ + "load_dataset" + ] + }, + { + "module": "transformers", + "names": [ + "AutoTokenizer" + ] + }, + { + "module": "multiprocessing", + "names": [ + "Pool" + ] + }, + { + "module": "functools", + "names": [ + "partial" + ] + }, + { + "module": "trajectory_compressor", + "names": [ + "TrajectoryCompressor", + "CompressionConfig" + ] + } + ] + }, + "agent/smart_model_routing.py": { + "imports": [ + "os", + "re" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "utils", + "names": [ + "is_truthy_value" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + } + ] + }, + "agent/redact.py": { + "imports": [ + "logging", + "os", + "re" + ], + "from_imports": [] + }, + "agent/memory_provider.py": { + "imports": [ + "logging" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "abc", + "names": [ + "ABC", + "abstractmethod" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + } + ] + }, + "agent/context_references.py": { + "imports": [ + "asyncio", + "inspect", + "json", + "mimetypes", + "os", + "re", + "subprocess", + "concurrent.futures" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Awaitable", + "Callable" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "estimate_tokens_rough" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "web_extract_tool" + ] + } + ] + }, + "agent/usage_pricing.py": { + "imports": [], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "decimal", + "names": [ + "Decimal" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Literal", + "Optional" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "fetch_endpoint_model_metadata", + "fetch_model_metadata" + ] + } + ] + }, + "agent/copilot_acp_client.py": { + "imports": [ + "json", + "os", + "queue", + "shlex", + "subprocess", + "threading", + "time" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "collections", + "names": [ + "deque" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "typing", + "names": [ + "Any" + ] + } + ] + }, + "agent/insights.py": { + "imports": [ + "json", + "time" + ], + "from_imports": [ + { + "module": "collections", + "names": [ + "Counter", + "defaultdict" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List" + ] + }, + { + "module": "agent.usage_pricing", + "names": [ + "CanonicalUsage", + "DEFAULT_PRICING", + "estimate_usage_cost", + "format_duration_compact", + "get_pricing", + "has_known_pricing" + ] + } + ] + }, + "agent/display.py": { + "imports": [ + "json", + "logging", + "os", + "sys", + "threading", + "time" + ], + "from_imports": [ + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "difflib", + "names": [ + "unified_diff" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.skill_manager_tool", + "names": [ + "_find_skill", + "_resolve_skill_dir" + ] + }, + { + "module": "urllib.parse", + "names": [ + "quote" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "prompt_toolkit.patch_stdout", + "names": [ + "StdoutProxy" + ] + } + ] + }, + "agent/__init__.py": { + "imports": [], + "from_imports": [] + }, + "agent/context_compressor.py": { + "imports": [ + "logging" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "call_llm" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length", + "estimate_messages_tokens_rough" + ] + } + ] + }, + "agent/builtin_memory_provider.py": { + "imports": [ + "json", + "logging" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + } + ] + }, + "agent/credential_pool.py": { + "imports": [ + "logging", + "random", + "threading", + "time", + "uuid", + "os", + "hermes_cli.auth" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "fields", + "replace" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Set", + "Tuple" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_BASE_URL" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "ACCESS_TOKEN_REFRESH_SKEW_SECONDS", + "CODEX_ACCESS_TOKEN_REFRESH_SKEW_SECONDS", + "DEFAULT_AGENT_KEY_MIN_TTL_SECONDS", + "PROVIDER_REGISTRY", + "_agent_key_is_usable", + "_codex_access_token_is_expiring", + "_decode_jwt_claims", + "_is_expiring", + "_load_auth_store", + "_load_provider_state", + "read_credential_pool", + "write_credential_pool" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "read_claude_code_credentials", + "read_hermes_oauth_credentials" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "read_claude_code_credentials" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "refresh_anthropic_oauth_pure" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_write_claude_code_credentials" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "refresh_anthropic_oauth_pure" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_write_claude_code_credentials" + ] + } + ] + }, + "agent/trajectory.py": { + "imports": [ + "json", + "logging" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List" + ] + } + ] + }, + "agent/title_generator.py": { + "imports": [ + "logging", + "threading" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "call_llm" + ] + } + ] + }, + "agent/auxiliary_client.py": { + "imports": [ + "json", + "logging", + "os", + "threading", + "time", + "inspect", + "re", + "asyncio", + "asyncio", + "base64", + "asyncio" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "openai", + "names": [ + "OpenAI" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_BASE_URL" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_is_oauth_token" + ] + }, + { + "module": "openai", + "names": [ + "AsyncOpenAI" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_kwargs", + "normalize_anthropic_response" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "_read_codex_tokens" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY", + "resolve_api_key_provider_credentials" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "build_anthropic_client", + "resolve_anthropic_token" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY", + "resolve_api_key_provider_credentials" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "openai._base_client", + "names": [ + "AsyncHttpxClientWrapper" + ] + }, + { + "module": "httpx._client", + "names": [ + "ClientState" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_default_headers" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_default_headers" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_default_headers" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_default_headers" + ] + } + ] + }, + "agent/skill_utils.py": { + "imports": [ + "logging", + "os", + "re", + "sys", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Set", + "Tuple" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "agent/prompt_caching.py": { + "imports": [ + "copy" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List" + ] + } + ] + }, + "agent/model_metadata.py": { + "imports": [ + "logging", + "os", + "re", + "time", + "requests", + "yaml", + "ipaddress", + "httpx", + "httpx" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urlparse" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_MODELS_URL" + ] + }, + { + "module": "agent.models_dev", + "names": [ + "lookup_models_dev_context" + ] + } + ] + }, + "agent/anthropic_adapter.py": { + "imports": [ + "copy", + "json", + "logging", + "os", + "anthropic", + "subprocess", + "time", + "time", + "urllib.parse", + "urllib.request", + "shutil", + "subprocess", + "base64", + "hashlib", + "secrets", + "time", + "webbrowser", + "re", + "urllib.request" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "httpx", + "names": [ + "Timeout" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urlencode" + ] + } + ] + }, + "agent/models_dev.py": { + "imports": [ + "json", + "logging", + "os", + "time", + "requests" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "utils", + "names": [ + "atomic_json_write" + ] + } + ] + }, + "agent/prompt_builder.py": { + "imports": [ + "json", + "logging", + "os", + "re", + "threading" + ], + "from_imports": [ + { + "module": "collections", + "names": [ + "OrderedDict" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "extract_skill_conditions", + "extract_skill_description", + "get_all_skills_dirs", + "get_disabled_skill_names", + "iter_skill_index_files", + "parse_frontmatter", + "skill_matches_platform" + ] + }, + { + "module": "utils", + "names": [ + "atomic_json_write" + ] + }, + { + "module": "hermes_cli.nous_subscription", + "names": [ + "get_nous_subscription_features" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "ensure_hermes_home" + ] + } + ] + }, + "agent/skill_commands.py": { + "imports": [ + "json", + "logging", + "re" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "SKILLS_DIR" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "SKILLS_DIR", + "skill_view" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "SKILLS_DIR", + "_parse_frontmatter", + "skill_matches_platform", + "_get_disabled_skill_names" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + } + ] + }, + "agent/memory_manager.py": { + "imports": [ + "json", + "logging" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "hermes_cli/skills_config.py": { + "imports": [], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Optional", + "Set" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + }, + { + "module": "hermes_cli.curses_ui", + "names": [ + "curses_checklist" + ] + }, + { + "module": "hermes_cli.curses_ui", + "names": [ + "curses_checklist" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_find_all_skills" + ] + } + ] + }, + "hermes_cli/curses_ui.py": { + "imports": [ + "sys", + "curses" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Callable", + "List", + "Optional", + "Set" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + } + ] + }, + "hermes_cli/cron.py": { + "imports": [ + "json", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Iterable", + "List", + "Optional" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + }, + { + "module": "tools.cronjob_tools", + "names": [ + "cronjob" + ] + }, + { + "module": "cron.jobs", + "names": [ + "list_jobs" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "find_gateway_pids" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "tick" + ] + }, + { + "module": "cron.jobs", + "names": [ + "list_jobs" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "find_gateway_pids" + ] + }, + { + "module": "cron.jobs", + "names": [ + "get_job" + ] + } + ] + }, + "hermes_cli/plugins_cmd.py": { + "imports": [ + "logging", + "os", + "shutil", + "subprocess", + "sys", + "tempfile", + "yaml", + "yaml", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "rich.markdown", + "names": [ + "Markdown" + ] + }, + { + "module": "rich.panel", + "names": [ + "Panel" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "rich.table", + "names": [ + "Table" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "hermes_cli.curses_ui", + "names": [ + "curses_checklist" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "recommended_update_command" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + } + ] + }, + "hermes_cli/config.py": { + "imports": [ + "os", + "platform", + "re", + "stat", + "subprocess", + "sys", + "tempfile", + "yaml", + "copy", + "shutil", + "getpass", + "getpass" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "Any", + "Optional", + "List", + "Tuple" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + }, + { + "module": "hermes_cli.default_soul", + "names": [ + "DEFAULT_SOUL_MD" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "utils", + "names": [ + "atomic_yaml_write" + ] + } + ] + }, + "hermes_cli/status.py": { + "imports": [ + "os", + "sys", + "subprocess", + "json", + "json", + "socket", + "httpx" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "AuthError", + "resolve_provider" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_path", + "get_env_value", + "get_hermes_home", + "load_config" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "provider_label" + ] + }, + { + "module": "hermes_cli.nous_subscription", + "names": [ + "get_nous_subscription_features" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_requested_provider" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_MODELS_URL" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "get_nous_auth_status", + "get_codex_auth_status" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "get_service_name" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "get_launchd_label" + ] + } + ] + }, + "hermes_cli/banner.py": { + "imports": [ + "json", + "logging", + "os", + "shutil", + "subprocess", + "threading", + "time" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "rich.panel", + "names": [ + "Panel" + ] + }, + { + "module": "rich.table", + "names": [ + "Table" + ] + }, + { + "module": "prompt_toolkit", + "names": [ + "print_formatted_text" + ] + }, + { + "module": "prompt_toolkit.formatted_text", + "names": [ + "ANSI" + ] + }, + { + "module": "hermes_cli", + "names": [ + "__version__", + "__release_date__" + ] + }, + { + "module": "model_tools", + "names": [ + "check_tool_availability", + "TOOLSET_REQUIREMENTS" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_find_all_skills" + ] + }, + { + "module": "model_tools", + "names": [ + "get_toolset_for_tool" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "get_mcp_status" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "get_active_profile_name" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "recommended_update_command" + ] + } + ] + }, + "hermes_cli/doctor.py": { + "imports": [ + "os", + "sys", + "subprocess", + "shutil", + "re", + "sqlite3", + "httpx", + "httpx", + "json", + "httpx", + "json" + ], + "from_imports": [ + { + "module": "hermes_cli.config", + "names": [ + "get_project_root", + "get_hermes_home", + "get_env_path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "dotenv", + "names": [ + "load_dotenv" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_MODELS_URL" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "get_systemd_linger_status", + "get_systemd_unit_path", + "is_linux" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "get_nous_auth_status", + "get_codex_auth_status" + ] + }, + { + "module": "model_tools", + "names": [ + "check_tool_availability", + "TOOLSET_REQUIREMENTS" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig", + "resolve_config_path" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "list_profiles", + "_get_wrapper_dir", + "profile_exists" + ] + }, + { + "module": "daytona", + "names": [ + "Daytona" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_is_oauth_token", + "_COMMON_BETAS", + "_OAUTH_ONLY_BETAS" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "get_honcho_client", + "reset_honcho_client" + ] + } + ] + }, + "hermes_cli/uninstall.py": { + "imports": [ + "os", + "shutil", + "subprocess", + "platform" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "get_service_name" + ] + } + ] + }, + "hermes_cli/copilot_auth.py": { + "imports": [ + "json", + "logging", + "os", + "shutil", + "subprocess", + "time", + "urllib.request", + "urllib.parse" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Optional" + ] + } + ] + }, + "hermes_cli/auth.py": { + "imports": [ + "json", + "logging", + "os", + "shutil", + "shlex", + "stat", + "base64", + "hashlib", + "subprocess", + "threading", + "time", + "uuid", + "webbrowser", + "httpx", + "yaml", + "fcntl", + "msvcrt", + "time" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "contextlib", + "names": [ + "contextmanager" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home", + "get_config_path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_BASE_URL" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_config", + "load_config" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "simple_term_menu", + "names": [ + "TerminalMenu" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "resolve_copilot_token" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_PROVIDER_MODELS" + ] + } + ] + }, + "hermes_cli/clipboard.py": { + "imports": [ + "base64", + "logging", + "os", + "subprocess", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "PIL", + "names": [ + "Image" + ] + } + ] + }, + "hermes_cli/nous_subscription.py": { + "imports": [ + "shutil" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "Iterable", + "Optional", + "Set" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "get_nous_auth_status" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "load_config" + ] + }, + { + "module": "tools.managed_tool_gateway", + "names": [ + "is_managed_tool_gateway_ready" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "has_direct_modal_credentials", + "managed_nous_tools_enabled", + "normalize_browser_cloud_provider", + "normalize_modal_mode", + "resolve_modal_backend_state", + "resolve_openai_audio_api_key" + ] + }, + { + "module": "toolsets", + "names": [ + "resolve_toolset" + ] + } + ] + }, + "hermes_cli/__init__.py": { + "imports": [], + "from_imports": [] + }, + "hermes_cli/pairing.py": { + "imports": [], + "from_imports": [ + { + "module": "gateway.pairing", + "names": [ + "PairingStore" + ] + } + ] + }, + "hermes_cli/gateway.py": { + "imports": [ + "asyncio", + "os", + "shutil", + "signal", + "subprocess", + "sys", + "time", + "hashlib", + "re", + "getpass", + "grp", + "pwd", + "shutil", + "shutil", + "getpass", + "shutil", + "time", + "argparse", + "shutil", + "httpx", + "pwd", + "getpass" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "get_hermes_home", + "save_env_value", + "is_managed", + "managed_error" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "print_header", + "print_info", + "print_success", + "print_warning", + "print_error", + "prompt", + "prompt_choice", + "prompt_yes_no" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "gateway.status", + "names": [ + "get_running_pid" + ] + }, + { + "module": "gateway.run", + "names": [ + "start_gateway" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "cmd_whatsapp" + ] + }, + { + "module": "gateway.status", + "names": [ + "get_running_pid", + "remove_pid_file" + ] + }, + { + "module": "gateway.status", + "names": [ + "read_runtime_status" + ] + } + ] + }, + "hermes_cli/codex_models.py": { + "imports": [ + "json", + "logging", + "os", + "httpx", + "tomllib" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Optional" + ] + } + ] + }, + "hermes_cli/default_soul.py": { + "imports": [], + "from_imports": [] + }, + "hermes_cli/webhook.py": { + "imports": [ + "json", + "os", + "re", + "secrets", + "time", + "hmac", + "hashlib", + "urllib.request" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "Optional" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + } + ] + }, + "hermes_cli/claw.py": { + "imports": [ + "importlib.util", + "logging", + "shutil", + "sys" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home", + "get_config_path", + "load_config", + "save_config" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_optional_skills_dir" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "Colors", + "color", + "print_header", + "print_info", + "print_success", + "print_error", + "print_warning", + "prompt_yes_no" + ] + } + ] + }, + "hermes_cli/memory_setup.py": { + "imports": [ + "getpass", + "os", + "sys", + "subprocess", + "curses", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "plugins.memory", + "names": [ + "discover_memory_providers", + "load_memory_provider" + ] + } + ] + }, + "hermes_cli/checklist.py": { + "imports": [ + "sys", + "curses" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Set" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + } + ] + }, + "hermes_cli/models.py": { + "imports": [ + "json", + "os", + "urllib.request", + "urllib.error", + "re", + "logging", + "os" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "difflib", + "names": [ + "get_close_matches" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Optional" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "resolve_api_key_provider_credentials" + ] + }, + { + "module": "hermes_cli.codex_models", + "names": [ + "get_codex_model_ids" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "resolve_anthropic_token", + "_is_oauth_token" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_COMMON_BETAS", + "_OAUTH_ONLY_BETAS" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "copilot_request_headers" + ] + }, + { + "module": "hermes_constants", + "names": [ + "AI_GATEWAY_BASE_URL" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "get_auth_status", + "has_usable_secret" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "fetch_nous_models", + "resolve_nous_runtime_credentials" + ] + } + ] + }, + "hermes_cli/colors.py": { + "imports": [ + "os", + "sys" + ], + "from_imports": [] + }, + "hermes_cli/plugins.py": { + "imports": [ + "importlib", + "importlib.metadata", + "importlib.util", + "logging", + "os", + "sys", + "types", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Callable", + "Dict", + "List", + "Optional", + "Set" + ] + }, + { + "module": "utils", + "names": [ + "env_var_enabled" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "hermes_cli/main.py": { + "imports": [ + "argparse", + "os", + "subprocess", + "sys", + "logging", + "time", + "subprocess", + "os", + "argparse", + "argparse", + "re", + "os", + "shutil", + "tempfile", + "zipfile", + "subprocess", + "shutil", + "curses", + "openai", + "tomllib", + "json", + "json", + "shutil", + "shutil", + "importlib", + "hermes_constants", + "signal", + "shutil", + "sys", + "sys", + "shutil" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.env_loader", + "names": [ + "load_hermes_dotenv" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "hermes_cli", + "names": [ + "__version__", + "__release_date__" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_BASE_URL" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_path", + "get_hermes_home", + "load_config" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "get_auth_status" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY" + ] + }, + { + "module": "cli", + "names": [ + "main" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "gateway_command" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "save_env_value" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "run_setup_wizard" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "resolve_provider", + "AuthError", + "format_auth_error" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "get_env_value" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "_prompt_model_selection", + "_save_model_choice", + "deactivate_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "save_env_value" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "model_ids" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "get_provider_auth_state", + "_prompt_model_selection", + "_save_model_choice", + "_update_config_for_provider", + "resolve_nous_runtime_credentials", + "fetch_nous_models", + "AuthError", + "format_auth_error", + "_login_nous", + "PROVIDER_REGISTRY" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "save_config", + "save_env_value" + ] + }, + { + "module": "hermes_cli.nous_subscription", + "names": [ + "apply_nous_provider_defaults", + "get_nous_subscription_explainer_lines" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "get_codex_auth_status", + "_prompt_model_selection", + "_save_model_choice", + "_update_config_for_provider", + "_login_openai_codex", + "PROVIDER_REGISTRY", + "DEFAULT_CODEX_BASE_URL" + ] + }, + { + "module": "hermes_cli.codex_models", + "names": [ + "get_codex_model_ids" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "save_env_value" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "_save_model_choice", + "deactivate_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "save_env_value", + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "probe_api_models" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "_save_model_choice", + "deactivate_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_env_value", + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "fetch_api_models" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY", + "_prompt_model_selection", + "_save_model_choice", + "deactivate_provider", + "resolve_api_key_provider_credentials" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "save_env_value", + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "fetch_api_models", + "fetch_github_model_catalog", + "github_model_reasoning_efforts", + "copilot_model_api_mode", + "normalize_copilot_model_id" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY", + "_prompt_model_selection", + "_save_model_choice", + "deactivate_provider", + "get_external_process_provider_status", + "resolve_api_key_provider_credentials", + "resolve_external_process_provider_credentials" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "fetch_github_model_catalog", + "normalize_copilot_model_id" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY", + "KIMI_CODE_BASE_URL", + "_prompt_model_selection", + "_save_model_choice", + "deactivate_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "save_env_value", + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY", + "_prompt_model_selection", + "_save_model_choice", + "deactivate_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "save_env_value", + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "fetch_api_models", + "opencode_model_api_mode", + "normalize_opencode_model_id" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "run_oauth_setup_token", + "read_claude_code_credentials", + "is_claude_code_token_valid" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_anthropic_oauth_token", + "use_anthropic_claude_code_credentials" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY", + "_prompt_model_selection", + "_save_model_choice", + "deactivate_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value", + "save_env_value", + "load_config", + "save_config", + "save_anthropic_api_key" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "login_command" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "logout_command" + ] + }, + { + "module": "hermes_cli.auth_commands", + "names": [ + "auth_command" + ] + }, + { + "module": "hermes_cli.status", + "names": [ + "show_status" + ] + }, + { + "module": "hermes_cli.cron", + "names": [ + "cron_command" + ] + }, + { + "module": "hermes_cli.webhook", + "names": [ + "webhook_command" + ] + }, + { + "module": "hermes_cli.doctor", + "names": [ + "run_doctor" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "config_command" + ] + }, + { + "module": "hermes_cli.uninstall", + "names": [ + "run_uninstall" + ] + }, + { + "module": "urllib.request", + "names": [ + "urlretrieve" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "is_managed", + "managed_error" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "list_profiles", + "create_profile", + "delete_profile", + "seed_profile_skills", + "get_active_profile", + "set_active_profile", + "get_active_profile_name", + "check_alias_collision", + "create_wrapper_script", + "remove_wrapper_script", + "_is_wrapper_dir_in_path", + "_get_wrapper_dir" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "generate_bash_completion", + "generate_zsh_completion" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "is_interactive_stdin", + "print_noninteractive_setup_guidance" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "prefetch_update_check" + ] + }, + { + "module": "tools.skills_sync", + "names": [ + "sync_skills" + ] + }, + { + "module": "simple_term_menu", + "names": [ + "TerminalMenu" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "resolve_codex_runtime_credentials" + ] + }, + { + "module": "simple_term_menu", + "names": [ + "TerminalMenu" + ] + }, + { + "module": "simple_term_menu", + "names": [ + "TerminalMenu" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "read_claude_code_credentials", + "is_claude_code_token_valid" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "check_for_updates" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "recommended_update_command" + ] + }, + { + "module": "tools.skills_sync", + "names": [ + "sync_skills" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_missing_env_vars", + "get_missing_config_fields", + "check_config_version", + "migrate_config" + ] + }, + { + "module": "hermes_cli.pairing", + "names": [ + "pairing_command" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "plugins_command" + ] + }, + { + "module": "plugins.memory.honcho.cli", + "names": [ + "honcho_command" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "mcp_command" + ] + }, + { + "module": "hermes_cli.claw", + "names": [ + "claw_command" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "resolve_profile_env" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "read_claude_code_credentials", + "is_claude_code_token_valid" + ] + }, + { + "module": "simple_term_menu", + "names": [ + "TerminalMenu" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "tools.skills_sync", + "names": [ + "sync_skills" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "list_profiles", + "get_active_profile_name", + "seed_profile_skills" + ] + }, + { + "module": "plugins.memory.honcho.cli", + "names": [ + "sync_honcho_profiles_quiet" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "is_macos", + "is_linux", + "_ensure_user_systemd_env", + "get_systemd_linger_status", + "find_gateway_pids" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "skills_command" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "skills_command" + ] + }, + { + "module": "hermes_cli.memory_setup", + "names": [ + "memory_command" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.memory_setup", + "names": [ + "memory_command" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "tools_disable_enable_command" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "tools_command" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "agent.insights", + "names": [ + "InsightsEngine" + ] + }, + { + "module": "acp_adapter.entry", + "names": [ + "main" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "copilot_device_code_login" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "validate_copilot_token" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "launchd_restart", + "get_launchd_label", + "get_launchd_plist_path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "get_profile_dir", + "profile_exists", + "_read_config_model", + "_check_gateway_running", + "_count_skills" + ] + }, + { + "module": "plugins.memory.honcho.cli", + "names": [ + "clone_honcho_for_profile" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "profile_exists" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "rename_profile" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "export_profile" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "import_profile" + ] + } + ] + }, + "hermes_cli/profiles.py": { + "imports": [ + "json", + "os", + "re", + "shutil", + "stat", + "subprocess", + "sys", + "platform", + "signal", + "time", + "tempfile", + "tarfile", + "tarfile", + "yaml" + ], + "from_imports": [ + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "pathlib", + "names": [ + "Path", + "PurePosixPath", + "PureWindowsPath" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Optional" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "_profile_suffix", + "get_service_name" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "get_service_name", + "get_launchd_plist_path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "hermes_cli/mcp_config.py": { + "imports": [ + "asyncio", + "getpass", + "logging", + "os", + "re", + "time", + "sys" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config", + "get_env_value", + "save_env_value", + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_ensure_mcp_loop", + "_run_on_mcp_loop", + "_connect_server", + "_stop_mcp_loop" + ] + }, + { + "module": "hermes_cli.curses_ui", + "names": [ + "curses_checklist" + ] + }, + { + "module": "hermes_cli.curses_ui", + "names": [ + "curses_checklist" + ] + }, + { + "module": "tools.mcp_oauth", + "names": [ + "remove_oauth_tokens" + ] + }, + { + "module": "mcp_serve", + "names": [ + "run_mcp_server" + ] + }, + { + "module": "tools.mcp_oauth", + "names": [ + "build_oauth_auth" + ] + } + ] + }, + "hermes_cli/model_switch.py": { + "imports": [], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "parse_model_input", + "detect_provider_for_model", + "validate_requested_model", + "_PROVIDER_LABELS", + "opencode_model_api_mode" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider", + "_auto_detect_local_model" + ] + } + ] + }, + "hermes_cli/env_loader.py": { + "imports": [ + "os" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "dotenv", + "names": [ + "load_dotenv" + ] + } + ] + }, + "hermes_cli/runtime_provider.py": { + "imports": [ + "os", + "re", + "requests" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "hermes_cli", + "names": [ + "auth" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "CredentialPool", + "PooledCredential", + "get_custom_provider_pool_key", + "load_pool" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "AuthError", + "DEFAULT_CODEX_BASE_URL", + "PROVIDER_REGISTRY", + "format_auth_error", + "resolve_provider", + "resolve_nous_runtime_credentials", + "resolve_codex_runtime_credentials", + "resolve_api_key_provider_credentials", + "resolve_external_process_provider_credentials", + "has_usable_secret" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_BASE_URL" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_model_api_mode" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "resolve_anthropic_token" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "resolve_anthropic_token" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "opencode_model_api_mode" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "opencode_model_api_mode" + ] + } + ] + }, + "hermes_cli/setup.py": { + "imports": [ + "importlib.util", + "logging", + "os", + "sys", + "shutil", + "subprocess", + "sys", + "platform", + "shutil", + "curses", + "platform", + "sys", + "getpass", + "importlib.util", + "subprocess", + "importlib.util", + "subprocess", + "subprocess", + "subprocess" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Optional", + "Dict", + "Any" + ] + }, + { + "module": "hermes_cli.nous_subscription", + "names": [ + "apply_nous_provider_defaults", + "get_nous_subscription_explainer_lines", + "get_nous_subscription_features" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_optional_skills_dir" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home", + "get_config_path", + "get_env_path", + "load_config", + "save_config", + "save_env_value", + "get_env_value", + "ensure_hermes_home" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "github_model_reasoning_efforts", + "normalize_copilot_model_id" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY", + "resolve_api_key_provider_credentials" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_env_value" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_model_api_mode", + "fetch_api_models", + "fetch_github_model_catalog", + "normalize_copilot_model_id", + "normalize_opencode_model_id", + "opencode_model_api_mode" + ] + }, + { + "module": "hermes_cli.curses_ui", + "names": [ + "curses_checklist" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "select_provider_and_model" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "tools_command" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "is_managed", + "managed_error" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "get_active_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_missing_env_vars", + "get_missing_config_fields", + "check_config_version" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "get_available_vision_backends" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "get_available_vision_backends" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "_is_service_installed", + "_is_service_running", + "has_conflicting_systemd_units", + "install_linux_gateway_from_setup", + "print_systemd_scope_conflict_warning", + "systemd_start", + "systemd_restart", + "launchd_install", + "launchd_start", + "launchd_restart" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "hermes_cli.auth_commands", + "names": [ + "auth_add_command" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "get_active_provider" + ] + }, + { + "module": "tools.managed_tool_gateway", + "names": [ + "is_managed_tool_gateway_ready" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "normalize_modal_mode" + ] + } + ] + }, + "hermes_cli/skin_engine.py": { + "imports": [ + "logging", + "os", + "yaml" + ], + "from_imports": [ + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "hermes_cli/callbacks.py": { + "imports": [ + "queue", + "time", + "getpass", + "threading" + ], + "from_imports": [ + { + "module": "hermes_cli.banner", + "names": [ + "cprint", + "_DIM", + "_RST" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_env_value_secure" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "cli", + "names": [ + "CLI_CONFIG" + ] + }, + { + "module": "cli", + "names": [ + "CLI_CONFIG" + ] + } + ] + }, + "hermes_cli/auth_commands.py": { + "imports": [ + "math", + "time", + "uuid", + "hermes_cli.auth" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "getpass", + "names": [ + "getpass" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "AUTH_TYPE_API_KEY", + "AUTH_TYPE_OAUTH", + "CUSTOM_POOL_PREFIX", + "SOURCE_MANUAL", + "STATUS_EXHAUSTED", + "STRATEGY_FILL_FIRST", + "STRATEGY_ROUND_ROBIN", + "STRATEGY_RANDOM", + "STRATEGY_LEAST_USED", + "SUPPORTED_POOL_STRATEGIES", + "PooledCredential", + "_normalize_custom_pool_name", + "get_pool_strategy", + "label_from_token", + "list_custom_pool_providers", + "load_pool", + "_exhausted_ttl" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_BASE_URL" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "_get_custom_provider_config" + ] + }, + { + "module": "agent", + "names": [ + "anthropic_adapter" + ] + } + ] + }, + "hermes_cli/tools_config.py": { + "imports": [ + "json", + "logging", + "sys", + "shutil", + "curses", + "tiktoken", + "model_tools", + "getpass", + "subprocess", + "subprocess", + "subprocess" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional", + "Set" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config", + "get_env_value", + "save_env_value" + ] + }, + { + "module": "hermes_cli.colors", + "names": [ + "Colors", + "color" + ] + }, + { + "module": "hermes_cli.nous_subscription", + "names": [ + "apply_nous_managed_defaults", + "get_nous_subscription_features" + ] + }, + { + "module": "tools.tool_backend_helpers", + "names": [ + "managed_nous_tools_enabled" + ] + }, + { + "module": "toolsets", + "names": [ + "resolve_toolset" + ] + }, + { + "module": "hermes_cli.curses_ui", + "names": [ + "curses_checklist" + ] + }, + { + "module": "toolsets", + "names": [ + "resolve_toolset" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "hermes_cli.curses_ui", + "names": [ + "curses_checklist" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "discover_plugins", + "get_plugin_toolsets" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "discover_plugins", + "get_plugin_toolsets" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "probe_mcp_server_tools" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "resolve_vision_provider_client" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + } + ] + }, + "hermes_cli/commands.py": { + "imports": [ + "os", + "re", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "collections.abc", + "names": [ + "Callable", + "Mapping" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "typing", + "names": [ + "Any" + ] + }, + { + "module": "prompt_toolkit.auto_suggest", + "names": [ + "AutoSuggest", + "Suggestion" + ] + }, + { + "module": "prompt_toolkit.completion", + "names": [ + "Completer", + "Completion" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "get_plugin_manager" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_disabled_skill_names" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "get_skill_commands" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "SKILLS_DIR" + ] + } + ] + }, + "hermes_cli/skills_hub.py": { + "imports": [ + "json", + "shutil", + "yaml", + "httpx", + "re", + "sys", + "base64" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "rich.panel", + "names": [ + "Panel" + ] + }, + { + "module": "rich.table", + "names": [ + "Table" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "unified_search" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "GitHubAuth", + "create_source_router", + "unified_search" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "GitHubAuth", + "create_source_router" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "GitHubAuth", + "create_source_router", + "ensure_hub_dirs", + "quarantine_bundle", + "install_from_quarantine", + "HubLockFile" + ] + }, + { + "module": "tools.skills_guard", + "names": [ + "scan_skill", + "should_allow_install", + "format_scan_report" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "SKILLS_DIR" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "GitHubAuth", + "create_source_router" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "HubLockFile", + "ensure_hub_dirs" + ] + }, + { + "module": "tools.skills_sync", + "names": [ + "_read_manifest" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_find_all_skills" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "check_for_skill_updates" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "HubLockFile", + "check_for_skill_updates" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "HubLockFile", + "SKILLS_DIR" + ] + }, + { + "module": "tools.skills_guard", + "names": [ + "scan_skill", + "format_scan_report" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "uninstall_skill" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "TapsManager" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "GitHubAuth", + "SKILLS_DIR" + ] + }, + { + "module": "tools.skills_guard", + "names": [ + "scan_skill", + "format_scan_report" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "HubLockFile", + "TapsManager" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "TapsManager" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "append_audit_log" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "append_audit_log" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "append_audit_log" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "clear_skills_system_prompt_cache" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "clear_skills_system_prompt_cache" + ] + } + ] + }, + "acp_adapter/tools.py": { + "imports": [ + "uuid", + "acp", + "json" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "acp.schema", + "names": [ + "ToolCallLocation", + "ToolCallStart", + "ToolCallProgress", + "ToolKind" + ] + } + ] + }, + "acp_adapter/auth.py": { + "imports": [], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + } + ] + }, + "acp_adapter/__init__.py": { + "imports": [], + "from_imports": [] + }, + "acp_adapter/__main__.py": { + "imports": [], + "from_imports": [ + { + "module": "entry", + "names": [ + "main" + ] + } + ] + }, + "acp_adapter/server.py": { + "imports": [ + "asyncio", + "logging", + "acp" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "collections", + "names": [ + "defaultdict", + "deque" + ] + }, + { + "module": "concurrent.futures", + "names": [ + "ThreadPoolExecutor" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Deque", + "Optional" + ] + }, + { + "module": "acp.schema", + "names": [ + "AgentCapabilities", + "AuthenticateResponse", + "AuthMethod", + "ClientCapabilities", + "EmbeddedResourceContentBlock", + "ForkSessionResponse", + "ImageContentBlock", + "AudioContentBlock", + "Implementation", + "InitializeResponse", + "ListSessionsResponse", + "LoadSessionResponse", + "McpServerHttp", + "McpServerSse", + "McpServerStdio", + "NewSessionResponse", + "PromptResponse", + "ResumeSessionResponse", + "SetSessionConfigOptionResponse", + "SetSessionModelResponse", + "SetSessionModeResponse", + "ResourceContentBlock", + "SessionCapabilities", + "SessionForkCapabilities", + "SessionListCapabilities", + "SessionInfo", + "TextContentBlock", + "Usage" + ] + }, + { + "module": "acp_adapter.auth", + "names": [ + "detect_provider", + "has_provider" + ] + }, + { + "module": "acp_adapter.events", + "names": [ + "make_message_cb", + "make_step_cb", + "make_thinking_cb", + "make_tool_progress_cb" + ] + }, + { + "module": "acp_adapter.permissions", + "names": [ + "make_approval_callback" + ] + }, + { + "module": "acp_adapter.session", + "names": [ + "SessionManager", + "SessionState" + ] + }, + { + "module": "hermes_cli", + "names": [ + "__version__" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "register_mcp_servers" + ] + }, + { + "module": "model_tools", + "names": [ + "get_tool_definitions" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "parse_model_input", + "detect_provider_for_model" + ] + }, + { + "module": "model_tools", + "names": [ + "get_tool_definitions" + ] + }, + { + "module": "tools", + "names": [ + "terminal_tool" + ] + }, + { + "module": "tools", + "names": [ + "terminal_tool" + ] + } + ] + }, + "acp_adapter/permissions.py": { + "imports": [ + "asyncio", + "logging", + "acp" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "concurrent.futures", + "names": [ + "TimeoutError" + ] + }, + { + "module": "typing", + "names": [ + "Callable" + ] + }, + { + "module": "acp.schema", + "names": [ + "AllowedOutcome", + "PermissionOption" + ] + } + ] + }, + "acp_adapter/session.py": { + "imports": [ + "copy", + "json", + "logging", + "uuid", + "threading", + "threading", + "threading", + "os" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "threading", + "names": [ + "Lock" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "register_task_env_overrides" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "clear_task_env_overrides" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + } + ] + }, + "acp_adapter/entry.py": { + "imports": [ + "asyncio", + "logging", + "os", + "sys", + "acp" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.env_loader", + "names": [ + "load_hermes_dotenv" + ] + }, + { + "module": "server", + "names": [ + "HermesACPAgent" + ] + } + ] + }, + "acp_adapter/events.py": { + "imports": [ + "asyncio", + "json", + "logging", + "acp" + ], + "from_imports": [ + { + "module": "collections", + "names": [ + "deque" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Callable", + "Deque", + "Dict" + ] + }, + { + "module": "tools", + "names": [ + "build_tool_complete", + "build_tool_start", + "make_tool_call_id" + ] + } + ] + }, + "cron/__init__.py": { + "imports": [], + "from_imports": [ + { + "module": "cron.jobs", + "names": [ + "create_job", + "get_job", + "list_jobs", + "remove_job", + "update_job", + "pause_job", + "resume_job", + "trigger_job", + "JOBS_FILE" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "tick" + ] + } + ] + }, + "cron/scheduler.py": { + "imports": [ + "asyncio", + "concurrent.futures", + "json", + "logging", + "os", + "sys", + "traceback", + "fcntl", + "msvcrt", + "concurrent.futures", + "yaml", + "json" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "hermes_time", + "names": [ + "now" + ] + }, + { + "module": "cron.jobs", + "names": [ + "get_due_jobs", + "mark_job_run", + "save_job_output", + "advance_next_run" + ] + }, + { + "module": "tools.send_message_tool", + "names": [ + "_send_to_platform" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config", + "Platform" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "skill_view" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "dotenv", + "names": [ + "load_dotenv" + ] + }, + { + "module": "hermes_constants", + "names": [ + "parse_reasoning_effort" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider", + "format_runtime_provider_error" + ] + }, + { + "module": "agent.smart_model_routing", + "names": [ + "resolve_turn_route" + ] + }, + { + "module": "gateway.channel_directory", + "names": [ + "resolve_channel_name" + ] + } + ] + }, + "cron/jobs.py": { + "imports": [ + "copy", + "json", + "logging", + "tempfile", + "os", + "re", + "uuid" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timedelta" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Optional", + "Dict", + "List", + "Any" + ] + }, + { + "module": "hermes_time", + "names": [ + "now" + ] + }, + { + "module": "croniter", + "names": [ + "croniter" + ] + } + ] + }, + "gateway/config.py": { + "imports": [ + "logging", + "os", + "json", + "yaml", + "json" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional", + "Any" + ] + }, + { + "module": "enum", + "names": [ + "Enum" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "utils", + "names": [ + "is_truthy_value" + ] + } + ] + }, + "gateway/hooks.py": { + "imports": [ + "asyncio", + "importlib.util", + "yaml" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Callable", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "gateway.builtin_hooks.boot_md", + "names": [ + "handle" + ] + } + ] + }, + "gateway/status.py": { + "imports": [ + "hashlib", + "json", + "os", + "sys" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Optional" + ] + } + ] + }, + "gateway/stream_consumer.py": { + "imports": [ + "asyncio", + "logging", + "queue", + "time" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Optional" + ] + } + ] + }, + "gateway/mirror.py": { + "imports": [ + "json", + "logging" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + } + ] + }, + "gateway/delivery.py": { + "imports": [ + "logging" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional", + "Any", + "Union" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "config", + "names": [ + "Platform", + "GatewayConfig" + ] + }, + { + "module": "session", + "names": [ + "SessionSource" + ] + } + ] + }, + "gateway/channel_directory.py": { + "imports": [ + "json", + "logging", + "discord" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "tools.send_message_tool", + "names": [ + "_send_slack" + ] + } + ] + }, + "gateway/__init__.py": { + "imports": [], + "from_imports": [ + { + "module": "config", + "names": [ + "GatewayConfig", + "PlatformConfig", + "HomeChannel", + "load_gateway_config" + ] + }, + { + "module": "session", + "names": [ + "SessionContext", + "SessionStore", + "SessionResetPolicy", + "build_session_context_prompt" + ] + }, + { + "module": "delivery", + "names": [ + "DeliveryRouter", + "DeliveryTarget" + ] + } + ] + }, + "gateway/pairing.py": { + "imports": [ + "json", + "os", + "secrets", + "time" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_dir" + ] + } + ] + }, + "gateway/run.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "re", + "shlex", + "sys", + "signal", + "tempfile", + "threading", + "time", + "uuid", + "ssl", + "shutil", + "time", + "atexit", + "argparse", + "certifi", + "yaml", + "importlib.util", + "threading", + "json", + "yaml", + "yaml", + "uuid", + "uuid", + "yaml", + "yaml", + "uuid", + "asyncio", + "json", + "shutil", + "subprocess", + "json", + "re", + "json", + "asyncio", + "hashlib", + "json", + "queue", + "json", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml", + "os", + "re", + "yaml", + "asyncio", + "yaml", + "json", + "math" + ], + "from_imports": [ + { + "module": "logging.handlers", + "names": [ + "RotatingFileHandler" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "Optional", + "Any", + "List" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "utils", + "names": [ + "atomic_yaml_write" + ] + }, + { + "module": "dotenv", + "names": [ + "load_dotenv" + ] + }, + { + "module": "hermes_cli.env_loader", + "names": [ + "load_hermes_dotenv" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "GatewayConfig", + "load_gateway_config" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionStore", + "SessionSource", + "SessionContext", + "build_session_context", + "build_session_context_prompt", + "build_session_key" + ] + }, + { + "module": "gateway.delivery", + "names": [ + "DeliveryRouter" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider", + "format_runtime_provider_error" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "tick" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cleanup_image_cache", + "cleanup_document_cache" + ] + }, + { + "module": "gateway.status", + "names": [ + "get_running_pid", + "remove_pid_file" + ] + }, + { + "module": "agent.redact", + "names": [ + "RedactingFormatter" + ] + }, + { + "module": "gateway.status", + "names": [ + "write_pid_file", + "remove_pid_file" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "_expand_env_vars" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_get_disabled_skill_names" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_all_skills_dirs" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home", + "get_optional_skills_dir" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "process_registry" + ] + }, + { + "module": "gateway.pairing", + "names": [ + "PairingStore" + ] + }, + { + "module": "gateway.hooks", + "names": [ + "HookRegistry" + ] + }, + { + "module": "agent.smart_model_routing", + "names": [ + "resolve_turn_route" + ] + }, + { + "module": "hermes_constants", + "names": [ + "parse_reasoning_effort" + ] + }, + { + "module": "gateway.status", + "names": [ + "remove_pid_file", + "write_runtime_status" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "GATEWAY_KNOWN_COMMANDS", + "resolve_command" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length", + "DEFAULT_FALLBACK_CONTEXT" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home", + "display_hermes_home" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "gateway_help_lines" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "gateway_help_lines" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "list_available_providers", + "normalize_provider", + "_PROVIDER_LABELS" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.checkpoint_manager", + "names": [ + "CheckpointManager", + "format_checkpoint_list" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "tools.approval", + "names": [ + "resolve_gateway_approval", + "has_blocking_approval", + "pending_approval_count" + ] + }, + { + "module": "tools.approval", + "names": [ + "resolve_gateway_approval", + "has_blocking_approval" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "is_managed", + "format_managed_message" + ] + }, + { + "module": "tools.vision_tools", + "names": [ + "vision_analyze_tool" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio", + "get_stt_model_from_config" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "process_registry" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "_get_platform_tools" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "tools.skills_sync", + "names": [ + "sync_skills" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "shutdown_mcp_servers" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "ensure_installed" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "tools.skill_manager_tool", + "names": [ + "_find_skill" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "get_active_profile_name" + ] + }, + { + "module": "gateway.status", + "names": [ + "write_runtime_status" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "process_registry" + ] + }, + { + "module": "gateway.status", + "names": [ + "write_runtime_status" + ] + }, + { + "module": "gateway.channel_directory", + "names": [ + "build_channel_directory" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "process_registry" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter", + "check_telegram_requirements" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "resolve_command" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "estimate_messages_tokens_rough", + "get_model_context_length" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "get_skill_commands" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "get_skill_commands" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "text_to_speech_tool", + "_strip_markdown_for_tts" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "_get_platform_tools" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "estimate_messages_tokens_rough" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "estimate_messages_tokens_rough" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "agent.insights", + "names": [ + "InsightsEngine" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "shutdown_mcp_servers", + "discover_mcp_tools", + "_load_mcp_config", + "_servers", + "_lock" + ] + }, + { + "module": "agent.display", + "names": [ + "set_tool_preview_max_len" + ] + }, + { + "module": "agent.display", + "names": [ + "get_tool_emoji" + ] + }, + { + "module": "tools.approval", + "names": [ + "register_gateway_notify", + "reset_current_session_key", + "set_current_session_key", + "unregister_gateway_notify" + ] + }, + { + "module": "tools.memory_tool", + "names": [ + "get_memory_dir" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter", + "check_discord_requirements" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "build_plan_path", + "build_skill_invocation_message" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "get_plugin_command_handler" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "get_skill_commands", + "build_skill_invocation_message" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "_load_skill_payload", + "_build_skill_message" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "process_registry" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "resolve_provider" + ] + }, + { + "module": "gateway.config", + "names": [ + "StreamingConfig" + ] + }, + { + "module": "gateway.channel_directory", + "names": [ + "build_channel_directory" + ] + }, + { + "module": "gateway.status", + "names": [ + "release_all_scoped_locks" + ] + }, + { + "module": "gateway.status", + "names": [ + "write_runtime_status" + ] + }, + { + "module": "gateway.status", + "names": [ + "write_runtime_status" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "WhatsAppAdapter", + "check_whatsapp_requirements" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references_async" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length" + ] + }, + { + "module": "agent.display", + "names": [ + "get_tool_preview_max_len" + ] + }, + { + "module": "gateway.stream_consumer", + "names": [ + "GatewayStreamConsumer", + "StreamConsumerConfig" + ] + }, + { + "module": "agent.title_generator", + "names": [ + "maybe_auto_title" + ] + }, + { + "module": "gateway.platforms.slack", + "names": [ + "SlackAdapter", + "check_slack_requirements" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_disabled_skill_names" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "gateway.channel_directory", + "names": [ + "build_channel_directory" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "SignalAdapter", + "check_signal_requirements" + ] + }, + { + "module": "gateway.platforms.homeassistant", + "names": [ + "HomeAssistantAdapter", + "check_ha_requirements" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "EmailAdapter", + "check_email_requirements" + ] + }, + { + "module": "gateway.platforms.sms", + "names": [ + "SmsAdapter", + "check_sms_requirements" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter", + "check_dingtalk_requirements" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter", + "check_feishu_requirements" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter", + "check_wecom_requirements" + ] + }, + { + "module": "gateway.platforms.mattermost", + "names": [ + "MattermostAdapter", + "check_mattermost_requirements" + ] + }, + { + "module": "gateway.platforms.matrix", + "names": [ + "MatrixAdapter", + "check_matrix_requirements" + ] + }, + { + "module": "gateway.platforms.api_server", + "names": [ + "APIServerAdapter", + "check_api_server_requirements" + ] + }, + { + "module": "gateway.platforms.webhook", + "names": [ + "WebhookAdapter", + "check_webhook_requirements" + ] + } + ] + }, + "gateway/sticker_cache.py": { + "imports": [ + "json", + "time" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Optional" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "gateway/session.py": { + "imports": [ + "hashlib", + "logging", + "os", + "json", + "re", + "threading", + "uuid", + "tempfile" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timedelta" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional", + "Any" + ] + }, + { + "module": "config", + "names": [ + "Platform", + "GatewayConfig", + "SessionResetPolicy", + "HomeChannel" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + } + ] + }, + "gateway/platforms/mattermost.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "re", + "time", + "aiohttp", + "aiohttp", + "aiohttp", + "aiohttp", + "aiohttp", + "aiohttp", + "asyncio", + "aiohttp", + "mimetypes", + "random", + "aiohttp" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_image_from_bytes", + "cache_document_from_bytes" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_audio_from_bytes" + ] + } + ] + }, + "gateway/platforms/api_server.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "sqlite3", + "time", + "uuid", + "time", + "time", + "time", + "time", + "queue", + "queue", + "socket" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "SendResult" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "hashlib", + "names": [ + "sha256" + ] + }, + { + "module": "collections", + "names": [ + "OrderedDict" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "gateway.run", + "names": [ + "_resolve_runtime_agent_kwargs", + "_resolve_gateway_model", + "_load_gateway_config" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "_get_platform_tools" + ] + }, + { + "module": "cron.jobs", + "names": [ + "list_jobs", + "get_job", + "create_job", + "update_job", + "remove_job", + "pause_job", + "resume_job", + "trigger_job" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "agent.display", + "names": [ + "get_tool_emoji" + ] + } + ] + }, + "gateway/platforms/whatsapp.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "platform", + "re", + "subprocess", + "sys", + "aiohttp", + "aiohttp", + "asyncio", + "aiohttp", + "aiohttp", + "aiohttp", + "aiohttp", + "aiohttp", + "aiohttp", + "signal" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "Optional", + "Any" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_dir" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult", + "SUPPORTED_DOCUMENT_TYPES", + "cache_image_from_url", + "cache_audio_from_url" + ] + }, + { + "module": "gateway.status", + "names": [ + "acquire_scoped_lock" + ] + }, + { + "module": "gateway.status", + "names": [ + "release_scoped_lock" + ] + }, + { + "module": "gateway.status", + "names": [ + "release_scoped_lock" + ] + } + ] + }, + "gateway/platforms/homeassistant.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "time", + "uuid", + "aiohttp" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional", + "Set" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult" + ] + } + ] + }, + "gateway/platforms/matrix.py": { + "imports": [ + "asyncio", + "io", + "json", + "logging", + "mimetypes", + "os", + "re", + "time", + "nio", + "nio", + "nio", + "nio", + "nio", + "nio", + "nio", + "nio", + "nio", + "nio", + "markdown", + "aiohttp", + "nio", + "httpx" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional", + "Set" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_dir" + ] + }, + { + "module": "collections", + "names": [ + "deque" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_audio_from_bytes" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_image_from_bytes" + ] + } + ] + }, + "gateway/platforms/sms.py": { + "imports": [ + "asyncio", + "base64", + "logging", + "os", + "re", + "urllib.parse", + "aiohttp", + "aiohttp", + "aiohttp" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + } + ] + }, + "gateway/platforms/wecom.py": { + "imports": [ + "asyncio", + "base64", + "hashlib", + "json", + "logging", + "mimetypes", + "os", + "re", + "time", + "uuid", + "aiohttp", + "httpx" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "urllib.parse", + "names": [ + "unquote", + "urlparse" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult", + "cache_document_from_bytes", + "cache_image_from_bytes" + ] + }, + { + "module": "cryptography.hazmat.primitives.ciphers", + "names": [ + "Cipher", + "algorithms", + "modes" + ] + } + ] + }, + "gateway/platforms/base.py": { + "imports": [ + "asyncio", + "logging", + "os", + "random", + "re", + "uuid", + "sys", + "asyncio", + "httpx", + "logging", + "time", + "asyncio", + "httpx", + "logging", + "time", + "random", + "json" + ], + "from_imports": [ + { + "module": "abc", + "names": [ + "ABC", + "abstractmethod" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional", + "Any", + "Callable", + "Awaitable", + "Tuple" + ] + }, + { + "module": "enum", + "names": [ + "Enum" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "build_session_key" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_dir" + ] + }, + { + "module": "gateway.status", + "names": [ + "write_runtime_status" + ] + }, + { + "module": "gateway.status", + "names": [ + "write_runtime_status" + ] + }, + { + "module": "gateway.status", + "names": [ + "write_runtime_status" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "text_to_speech_tool", + "check_tts_requirements" + ] + } + ] + }, + "gateway/platforms/telegram.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "re", + "sys", + "yaml", + "os", + "os", + "json", + "yaml", + "httpx" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional", + "Any" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult", + "cache_image_from_bytes", + "cache_audio_from_bytes", + "cache_document_from_bytes", + "SUPPORTED_DOCUMENT_TYPES" + ] + }, + { + "module": "gateway.platforms.telegram_network", + "names": [ + "TelegramFallbackTransport", + "discover_fallback_ips", + "parse_fallback_ip_env" + ] + }, + { + "module": "telegram", + "names": [ + "Update", + "Bot", + "Message" + ] + }, + { + "module": "telegram.ext", + "names": [ + "Application", + "CommandHandler", + "MessageHandler", + "ContextTypes", + "filters" + ] + }, + { + "module": "telegram.constants", + "names": [ + "ParseMode", + "ChatType" + ] + }, + { + "module": "telegram.request", + "names": [ + "HTTPXRequest" + ] + }, + { + "module": "gateway.session", + "names": [ + "build_session_key" + ] + }, + { + "module": "gateway.session", + "names": [ + "build_session_key" + ] + }, + { + "module": "gateway.sticker_cache", + "names": [ + "get_cached_description", + "cache_sticker_description", + "build_sticker_injection", + "build_animated_sticker_injection", + "STICKER_VISION_PROMPT" + ] + }, + { + "module": "telegram.error", + "names": [ + "NetworkError", + "TimedOut" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "gateway.status", + "names": [ + "acquire_scoped_lock" + ] + }, + { + "module": "tools.vision_tools", + "names": [ + "vision_analyze_tool" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "telegram.error", + "names": [ + "NetworkError", + "TimedOut" + ] + }, + { + "module": "urllib.parse", + "names": [ + "urlparse" + ] + }, + { + "module": "telegram", + "names": [ + "BotCommand" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "telegram_menu_commands" + ] + }, + { + "module": "gateway.status", + "names": [ + "release_scoped_lock" + ] + }, + { + "module": "telegram.error", + "names": [ + "NetworkError" + ] + }, + { + "module": "telegram.error", + "names": [ + "BadRequest" + ] + }, + { + "module": "gateway.status", + "names": [ + "release_scoped_lock" + ] + } + ] + }, + "gateway/platforms/__init__.py": { + "imports": [], + "from_imports": [ + { + "module": "base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "SendResult" + ] + } + ] + }, + "gateway/platforms/webhook.py": { + "imports": [ + "asyncio", + "hashlib", + "hmac", + "json", + "logging", + "os", + "re", + "subprocess", + "time", + "socket", + "urllib.parse" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "build_skill_invocation_message", + "get_skill_commands" + ] + } + ] + }, + "gateway/platforms/signal.py": { + "imports": [ + "asyncio", + "base64", + "json", + "logging", + "os", + "random", + "re", + "time", + "httpx" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Dict", + "List", + "Optional", + "Any" + ] + }, + { + "module": "urllib.parse", + "names": [ + "quote", + "unquote" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult", + "cache_image_from_bytes", + "cache_audio_from_bytes", + "cache_document_from_bytes", + "cache_image_from_url" + ] + }, + { + "module": "gateway.status", + "names": [ + "acquire_scoped_lock" + ] + }, + { + "module": "gateway.status", + "names": [ + "release_scoped_lock" + ] + } + ] + }, + "gateway/platforms/telegram_network.py": { + "imports": [ + "asyncio", + "ipaddress", + "logging", + "os", + "socket", + "httpx" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Iterable", + "Optional" + ] + } + ] + }, + "gateway/platforms/dingtalk.py": { + "imports": [ + "asyncio", + "logging", + "os", + "time", + "uuid", + "dingtalk_stream", + "httpx" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "Optional" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult" + ] + }, + { + "module": "dingtalk_stream", + "names": [ + "ChatbotHandler", + "ChatbotMessage" + ] + } + ] + }, + "gateway/platforms/slack.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "re", + "time", + "sys", + "asyncio", + "httpx", + "asyncio", + "httpx", + "httpx" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Dict", + "Optional", + "Any" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult", + "SUPPORTED_DOCUMENT_TYPES", + "cache_document_from_bytes" + ] + }, + { + "module": "slack_bolt.async_app", + "names": [ + "AsyncApp" + ] + }, + { + "module": "slack_bolt.adapter.socket_mode.async_handler", + "names": [ + "AsyncSocketModeHandler" + ] + }, + { + "module": "slack_sdk.web.async_client", + "names": [ + "AsyncWebClient" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "slack_subcommand_map" + ] + }, + { + "module": "gateway.status", + "names": [ + "acquire_scoped_lock" + ] + }, + { + "module": "gateway.status", + "names": [ + "release_scoped_lock" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_audio_from_bytes" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_image_from_bytes" + ] + } + ] + }, + "gateway/platforms/email.py": { + "imports": [ + "asyncio", + "email", + "imaplib", + "logging", + "os", + "re", + "smtplib", + "ssl", + "uuid" + ], + "from_imports": [ + { + "module": "email.header", + "names": [ + "decode_header" + ] + }, + { + "module": "email.mime.multipart", + "names": [ + "MIMEMultipart" + ] + }, + { + "module": "email.mime.text", + "names": [ + "MIMEText" + ] + }, + { + "module": "email.mime.base", + "names": [ + "MIMEBase" + ] + }, + { + "module": "email", + "names": [ + "encoders" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult", + "cache_document_from_bytes", + "cache_image_from_bytes" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + } + ] + }, + "gateway/platforms/discord.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "struct", + "subprocess", + "tempfile", + "threading", + "time", + "sys", + "re", + "discord", + "nacl.secret", + "ctypes.util", + "io", + "time", + "aiohttp", + "sys", + "base64", + "json", + "davey", + "io", + "aiohttp" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "collections", + "names": [ + "defaultdict" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Callable", + "Dict", + "Optional", + "Any" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult", + "cache_image_from_url", + "cache_audio_from_url", + "cache_document_from_bytes", + "SUPPORTED_DOCUMENT_TYPES" + ] + }, + { + "module": "discord", + "names": [ + "Message", + "Intents" + ] + }, + { + "module": "discord.ext", + "names": [ + "commands" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "is_whisper_hallucination" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "discord.utils", + "names": [ + "MISSING" + ] + }, + { + "module": "gateway.status", + "names": [ + "acquire_scoped_lock" + ] + }, + { + "module": "gateway.status", + "names": [ + "release_scoped_lock" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio", + "get_stt_model_from_config" + ] + }, + { + "module": "tools.approval", + "names": [ + "resolve_gateway_approval" + ] + }, + { + "module": "mutagen.oggopus", + "names": [ + "OggOpus" + ] + } + ] + }, + "gateway/platforms/feishu.py": { + "imports": [ + "asyncio", + "hashlib", + "hmac", + "json", + "logging", + "mimetypes", + "os", + "re", + "threading", + "time", + "uuid", + "aiohttp", + "websockets", + "lark_oapi", + "lark_oapi.ws.client", + "httpx" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult", + "SUPPORTED_DOCUMENT_TYPES", + "cache_document_from_bytes", + "cache_image_from_url", + "cache_audio_from_bytes", + "cache_image_from_bytes" + ] + }, + { + "module": "gateway.status", + "names": [ + "acquire_scoped_lock", + "release_scoped_lock" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "lark_oapi.api.application.v6", + "names": [ + "GetApplicationRequest" + ] + }, + { + "module": "lark_oapi.api.im.v1", + "names": [ + "CreateFileRequest", + "CreateFileRequestBody", + "CreateImageRequest", + "CreateImageRequestBody", + "CreateMessageRequest", + "CreateMessageRequestBody", + "GetChatRequest", + "GetMessageRequest", + "GetImageRequest", + "GetMessageResourceRequest", + "P2ImMessageMessageReadV1", + "ReplyMessageRequest", + "ReplyMessageRequestBody", + "UpdateMessageRequest", + "UpdateMessageRequestBody" + ] + }, + { + "module": "lark_oapi.core.const", + "names": [ + "FEISHU_DOMAIN", + "LARK_DOMAIN" + ] + }, + { + "module": "lark_oapi.event.callback.model.p2_card_action_trigger", + "names": [ + "P2CardActionTriggerResponse" + ] + }, + { + "module": "lark_oapi.event.dispatcher_handler", + "names": [ + "EventDispatcherHandler" + ] + }, + { + "module": "lark_oapi.ws", + "names": [ + "Client" + ] + }, + { + "module": "gateway.session", + "names": [ + "build_session_key" + ] + }, + { + "module": "gateway.session", + "names": [ + "build_session_key" + ] + }, + { + "module": "lark_oapi.api.im.v1", + "names": [ + "CreateMessageReactionRequest", + "CreateMessageReactionRequestBody" + ] + }, + { + "module": "lark_oapi.api.contact.v3", + "names": [ + "GetUserRequest" + ] + } + ] + }, + "gateway/builtin_hooks/__init__.py": { + "imports": [], + "from_imports": [] + }, + "gateway/builtin_hooks/boot_md.py": { + "imports": [ + "logging", + "os", + "threading" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "website/scripts/extract-skills.py": { + "imports": [ + "json", + "os", + "yaml" + ], + "from_imports": [ + { + "module": "collections", + "names": [ + "Counter" + ] + } + ] + }, + "optional-skills/blockchain/base/scripts/base_client.py": { + "imports": [ + "argparse", + "json", + "os", + "sys", + "time", + "urllib.request", + "urllib.error" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Tuple" + ] + } + ] + }, + "optional-skills/blockchain/solana/scripts/solana_client.py": { + "imports": [ + "argparse", + "json", + "os", + "sys", + "time", + "urllib.request", + "urllib.error" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + } + ] + }, + "optional-skills/mcp/fastmcp/templates/file_processor.py": { + "imports": [], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any" + ] + }, + { + "module": "fastmcp", + "names": [ + "FastMCP" + ] + } + ] + }, + "optional-skills/mcp/fastmcp/templates/api_wrapper.py": { + "imports": [ + "os", + "httpx" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Any" + ] + }, + { + "module": "fastmcp", + "names": [ + "FastMCP" + ] + } + ] + }, + "optional-skills/mcp/fastmcp/templates/database_server.py": { + "imports": [ + "os", + "re", + "sqlite3" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Any" + ] + }, + { + "module": "fastmcp", + "names": [ + "FastMCP" + ] + } + ] + }, + "optional-skills/mcp/fastmcp/scripts/scaffold_fastmcp.py": { + "imports": [ + "argparse" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "optional-skills/research/domain-intel/scripts/domain_intel.py": { + "imports": [ + "json", + "re", + "socket", + "ssl", + "sys", + "urllib.request", + "urllib.parse" + ], + "from_imports": [ + { + "module": "concurrent.futures", + "names": [ + "ThreadPoolExecutor", + "as_completed" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + } + ] + }, + "optional-skills/migration/openclaw-migration/scripts/openclaw_to_hermes.py": { + "imports": [ + "argparse", + "hashlib", + "json", + "os", + "re", + "shutil", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "asdict", + "dataclass", + "field" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional", + "Sequence", + "Tuple" + ] + } + ] + }, + "optional-skills/security/oss-forensics/scripts/evidence-store.py": { + "imports": [ + "json", + "argparse", + "os", + "datetime", + "hashlib", + "sys" + ], + "from_imports": [] + }, + "optional-skills/productivity/telephony/scripts/telephony.py": { + "imports": [ + "argparse", + "base64", + "json", + "os", + "re", + "sys", + "urllib.error", + "urllib.parse", + "urllib.request", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "email.utils", + "names": [ + "parsedate_to_datetime" + ] + }, + { + "module": "html", + "names": [ + "escape" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any" + ] + } + ] + }, + "optional-skills/productivity/memento-flashcards/scripts/youtube_quiz.py": { + "imports": [ + "argparse", + "json", + "re", + "sys", + "youtube_transcript_api" + ], + "from_imports": [] + }, + "optional-skills/productivity/memento-flashcards/scripts/memento_cards.py": { + "imports": [ + "argparse", + "csv", + "json", + "os", + "sys", + "tempfile", + "uuid" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timedelta", + "timezone" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "optional-skills/productivity/canvas/scripts/canvas_api.py": { + "imports": [ + "argparse", + "json", + "os", + "sys", + "requests" + ], + "from_imports": [] + }, + "optional-skills/creative/meme-generation/scripts/generate_meme.py": { + "imports": [ + "json", + "os", + "sys", + "textwrap", + "requests", + "urllib.request", + "time" + ], + "from_imports": [ + { + "module": "io", + "names": [ + "BytesIO" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "PIL", + "names": [ + "Image", + "ImageDraw", + "ImageFont" + ] + } + ] + }, + "skills/red-teaming/godmode/scripts/auto_jailbreak.py": { + "imports": [ + "os", + "sys", + "json", + "time", + "re", + "yaml", + "inspect", + "argparse" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "concurrent.futures", + "names": [ + "ThreadPoolExecutor", + "as_completed" + ] + }, + { + "module": "openai", + "names": [ + "OpenAI" + ] + } + ] + }, + "skills/red-teaming/godmode/scripts/parseltongue.py": { + "imports": [ + "re", + "base64", + "sys", + "argparse" + ], + "from_imports": [] + }, + "skills/red-teaming/godmode/scripts/load_godmode.py": { + "imports": [ + "os", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "skills/red-teaming/godmode/scripts/godmode_race.py": { + "imports": [ + "os", + "re", + "json", + "time", + "argparse" + ], + "from_imports": [ + { + "module": "concurrent.futures", + "names": [ + "ThreadPoolExecutor", + "as_completed" + ] + }, + { + "module": "openai", + "names": [ + "OpenAI" + ] + }, + { + "module": "collections", + "names": [ + "namedtuple" + ] + } + ] + }, + "skills/mlops/training/grpo-rl-training/templates/basic_grpo_training.py": { + "imports": [ + "torch", + "re" + ], + "from_imports": [ + { + "module": "datasets", + "names": [ + "load_dataset", + "Dataset" + ] + }, + { + "module": "transformers", + "names": [ + "AutoModelForCausalLM", + "AutoTokenizer" + ] + }, + { + "module": "peft", + "names": [ + "LoraConfig" + ] + }, + { + "module": "trl", + "names": [ + "GRPOTrainer", + "GRPOConfig" + ] + } + ] + }, + "skills/leisure/find-nearby/scripts/find_nearby.py": { + "imports": [ + "argparse", + "json", + "math", + "sys", + "urllib.parse", + "urllib.request" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any" + ] + } + ] + }, + "skills/media/youtube-content/scripts/fetch_transcript.py": { + "imports": [ + "argparse", + "json", + "re", + "sys" + ], + "from_imports": [ + { + "module": "youtube_transcript_api", + "names": [ + "YouTubeTranscriptApi" + ] + } + ] + }, + "skills/research/polymarket/scripts/polymarket.py": { + "imports": [ + "json", + "sys", + "urllib.request", + "urllib.parse", + "urllib.error" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + } + ] + }, + "skills/research/arxiv/scripts/search_arxiv.py": { + "imports": [ + "sys", + "urllib.request", + "urllib.parse", + "xml.etree.ElementTree" + ], + "from_imports": [] + }, + "skills/productivity/google-workspace/scripts/google_api.py": { + "imports": [ + "argparse", + "base64", + "json", + "sys" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timedelta", + "timezone" + ] + }, + { + "module": "email.mime.text", + "names": [ + "MIMEText" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home", + "get_hermes_home" + ] + }, + { + "module": "google.oauth2.credentials", + "names": [ + "Credentials" + ] + }, + { + "module": "google.auth.transport.requests", + "names": [ + "Request" + ] + }, + { + "module": "googleapiclient.discovery", + "names": [ + "build" + ] + } + ] + }, + "skills/productivity/google-workspace/scripts/setup.py": { + "imports": [ + "argparse", + "json", + "subprocess", + "sys", + "googleapiclient", + "google_auth_oauthlib", + "googleapiclient", + "google_auth_oauthlib", + "urllib.request" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home", + "get_hermes_home" + ] + }, + { + "module": "google.oauth2.credentials", + "names": [ + "Credentials" + ] + }, + { + "module": "google.auth.transport.requests", + "names": [ + "Request" + ] + }, + { + "module": "urllib.parse", + "names": [ + "parse_qs", + "urlparse" + ] + }, + { + "module": "google_auth_oauthlib.flow", + "names": [ + "Flow" + ] + }, + { + "module": "google_auth_oauthlib.flow", + "names": [ + "Flow" + ] + }, + { + "module": "google.oauth2.credentials", + "names": [ + "Credentials" + ] + }, + { + "module": "google.auth.transport.requests", + "names": [ + "Request" + ] + } + ] + }, + "skills/productivity/ocr-and-documents/scripts/extract_marker.py": { + "imports": [ + "sys", + "os", + "shutil", + "json" + ], + "from_imports": [ + { + "module": "marker.converters.pdf", + "names": [ + "PdfConverter" + ] + }, + { + "module": "marker.models", + "names": [ + "create_model_dict" + ] + }, + { + "module": "marker.config.parser", + "names": [ + "ConfigParser" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "skills/productivity/ocr-and-documents/scripts/extract_pymupdf.py": { + "imports": [ + "sys", + "json", + "pymupdf", + "pymupdf4llm", + "pymupdf", + "pymupdf", + "pymupdf" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "skills/productivity/powerpoint/scripts/clean.py": { + "imports": [ + "sys", + "defusedxml.minidom", + "re" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "skills/productivity/powerpoint/scripts/__init__.py": { + "imports": [], + "from_imports": [] + }, + "skills/productivity/powerpoint/scripts/add_slide.py": { + "imports": [ + "re", + "shutil", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "skills/productivity/powerpoint/scripts/office/pack.py": { + "imports": [ + "argparse", + "sys", + "shutil", + "tempfile", + "zipfile", + "defusedxml.minidom" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "validators", + "names": [ + "DOCXSchemaValidator", + "PPTXSchemaValidator", + "RedliningValidator" + ] + } + ] + }, + "skills/productivity/powerpoint/scripts/office/helpers/__init__.py": { + "imports": [], + "from_imports": [] + }, + "skills/productivity/powerpoint/scripts/office/helpers/simplify_redlines.py": { + "imports": [ + "xml.etree.ElementTree", + "zipfile", + "defusedxml.minidom" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "skills/productivity/powerpoint/scripts/office/helpers/merge_runs.py": { + "imports": [ + "defusedxml.minidom" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "skills/creative/excalidraw/scripts/upload.py": { + "imports": [ + "json", + "os", + "struct", + "sys", + "zlib", + "base64", + "urllib.request" + ], + "from_imports": [ + { + "module": "cryptography.hazmat.primitives.ciphers.aead", + "names": [ + "AESGCM" + ] + } + ] + }, + "tests/test_credential_pool_routing.py": { + "imports": [ + "os", + "time", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "PropertyMock" + ] + }, + { + "module": "agent.smart_model_routing", + "names": [ + "resolve_turn_route" + ] + }, + { + "module": "agent.smart_model_routing", + "names": [ + "resolve_turn_route" + ] + }, + { + "module": "agent.smart_model_routing", + "names": [ + "resolve_turn_route" + ] + }, + { + "module": "agent.smart_model_routing", + "names": [ + "resolve_turn_route" + ] + }, + { + "module": "agent.smart_model_routing", + "names": [ + "resolve_turn_route" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "agent.smart_model_routing", + "names": [ + "resolve_turn_route" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_agent_guardrails.py": { + "imports": [ + "types" + ], + "from_imports": [ + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "MAX_CONCURRENT_CHILDREN" + ] + } + ] + }, + "tests/test_credential_pool.py": { + "imports": [ + "json", + "time", + "pytest", + "threading", + "yaml", + "yaml", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "load_pool" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "get_custom_provider_pool_key" + ] + }, + { + "module": "agent.credential_pool", + "names": [ + "list_custom_pool_providers" + ] + } + ] + }, + "tests/test_dict_tool_call_args.py": { + "imports": [ + "json" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_cli_context_warning.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/test_context_token_tracking.py": { + "imports": [ + "sys", + "types", + "run_agent" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + } + ] + }, + "tests/test_context_pressure.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "agent.display", + "names": [ + "format_context_pressure", + "format_context_pressure_gateway" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_model_metadata_local_ctx.py": { + "imports": [ + "sys", + "os", + "json", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "_query_local_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length", + "CONTEXT_PROBE_TIERS" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length", + "CONTEXT_PROBE_TIERS" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "get_model_context_length" + ] + } + ] + }, + "tests/test_evidence_store.py": { + "imports": [ + "os", + "json", + "pytest", + "importlib.util" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/conftest.py": { + "imports": [ + "asyncio", + "os", + "signal", + "sys", + "tempfile", + "pytest", + "hermes_cli.plugins" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + } + ] + }, + "tests/test_worktree_security.py": { + "imports": [ + "subprocess", + "pytest", + "cli", + "cli", + "cli", + "cli", + "cli" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/test_api_key_providers.py": { + "imports": [ + "os", + "sys", + "types", + "pytest", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml" + ], + "from_imports": [ + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY", + "ProviderConfig", + "resolve_provider", + "get_api_key_provider_status", + "resolve_api_key_provider_credentials", + "get_external_process_provider_status", + "resolve_external_process_provider_credentials", + "get_auth_status", + "AuthError", + "KIMI_CODE_BASE_URL", + "_try_gh_cli_token", + "_resolve_kimi_base_url" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "hermes_cli.runtime_provider", + "names": [ + "resolve_runtime_provider" + ] + }, + { + "module": "hermes_cli", + "names": [ + "config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_has_any_provider_configured" + ] + }, + { + "module": "hermes_cli", + "names": [ + "config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_has_any_provider_configured" + ] + }, + { + "module": "hermes_cli", + "names": [ + "config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_has_any_provider_configured" + ] + }, + { + "module": "hermes_cli", + "names": [ + "config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_has_any_provider_configured" + ] + }, + { + "module": "hermes_cli", + "names": [ + "config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_has_any_provider_configured" + ] + }, + { + "module": "hermes_cli", + "names": [ + "config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_has_any_provider_configured" + ] + }, + { + "module": "hermes_cli", + "names": [ + "config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_has_any_provider_configured" + ] + }, + { + "module": "hermes_cli", + "names": [ + "config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_has_any_provider_configured" + ] + }, + { + "module": "hermes_cli", + "names": [ + "config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_has_any_provider_configured" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "DEFAULT_CONTEXT_LENGTHS" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_PROVIDER_ALIASES" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_PROVIDER_LABELS" + ] + } + ] + }, + "tests/test_model_tools_async_bridge.py": { + "imports": [ + "asyncio", + "json", + "threading", + "pytest", + "time" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async" + ] + }, + { + "module": "concurrent.futures", + "names": [ + "ThreadPoolExecutor" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async" + ] + }, + { + "module": "concurrent.futures", + "names": [ + "ThreadPoolExecutor" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async" + ] + }, + { + "module": "concurrent.futures", + "names": [ + "ThreadPoolExecutor", + "as_completed" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async" + ] + }, + { + "module": "concurrent.futures", + "names": [ + "ThreadPoolExecutor" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async", + "_get_tool_loop" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async" + ] + }, + { + "module": "model_tools", + "names": [ + "_run_async", + "_get_tool_loop" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "model_tools", + "names": [ + "_get_tool_loop" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tests/test_mcp_serve.py": { + "imports": [ + "asyncio", + "json", + "os", + "sqlite3", + "time", + "threading", + "pytest", + "mcp_serve", + "hermes_constants", + "mcp_serve", + "mcp_serve", + "mcp_serve", + "mcp_serve", + "mcp_serve", + "mcp_serve", + "mcp_serve", + "mcp_serve", + "mcp_serve", + "mcp_serve", + "argparse", + "argparse", + "argparse", + "mcp_serve", + "mcp_serve", + "mcp_serve", + "mcp_serve", + "mcp_serve" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "mcp_serve", + "names": [ + "_get_sessions_dir" + ] + }, + { + "module": "mcp_serve", + "names": [ + "_extract_message_content" + ] + }, + { + "module": "mcp_serve", + "names": [ + "_extract_message_content" + ] + }, + { + "module": "mcp_serve", + "names": [ + "_extract_message_content" + ] + }, + { + "module": "mcp_serve", + "names": [ + "_extract_attachments" + ] + }, + { + "module": "mcp_serve", + "names": [ + "_extract_attachments" + ] + }, + { + "module": "mcp_serve", + "names": [ + "_extract_attachments" + ] + }, + { + "module": "mcp_serve", + "names": [ + "_extract_attachments" + ] + }, + { + "module": "mcp_serve", + "names": [ + "_extract_attachments" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge", + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge", + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge", + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge", + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge", + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge", + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge", + "QueueEvent", + "QUEUE_LIMIT" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge", + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge" + ] + }, + { + "module": "mcp_serve", + "names": [ + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "QueueEvent" + ] + }, + { + "module": "mcp_serve", + "names": [ + "QueueEvent" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "mcp_command" + ] + }, + { + "module": "mcp_serve", + "names": [ + "EventBridge" + ] + }, + { + "module": "mcp_serve", + "names": [ + "POLL_INTERVAL" + ] + } + ] + }, + "tests/test_real_interrupt_subagent.py": { + "imports": [ + "json", + "os", + "threading", + "time", + "unittest", + "traceback" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "PropertyMock" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "set_interrupt", + "is_interrupted" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent", + "IterationBudget" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "_run_single_child" + ] + } + ] + }, + "tests/test_quick_commands.py": { + "imports": [ + "subprocess", + "pytest", + "asyncio" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "AsyncMock" + ] + }, + { + "module": "rich.text", + "names": [ + "Text" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/test_utils_truthy_values.py": { + "imports": [], + "from_imports": [ + { + "module": "utils", + "names": [ + "env_var_enabled", + "is_truthy_value" + ] + } + ] + }, + "tests/test_cli_status_bar.py": { + "imports": [], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timedelta" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timedelta" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + } + ] + }, + "tests/test_anthropic_adapter.py": { + "imports": [ + "json", + "time", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "agent.prompt_caching", + "names": [ + "apply_anthropic_cache_control" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_is_oauth_token", + "_refresh_oauth_token", + "_to_plain_data", + "_write_claude_code_credentials", + "build_anthropic_client", + "build_anthropic_kwargs", + "convert_messages_to_anthropic", + "convert_tools_to_anthropic", + "get_anthropic_token_source", + "is_claude_code_token_valid", + "normalize_anthropic_response", + "normalize_model_name", + "read_claude_code_credentials", + "resolve_anthropic_token", + "run_oauth_setup_token" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_get_anthropic_max_output" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_get_anthropic_max_output" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_get_anthropic_max_output" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_get_anthropic_max_output" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_get_anthropic_max_output" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_get_anthropic_max_output" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_get_anthropic_max_output" + ] + }, + { + "module": "agent.anthropic_adapter", + "names": [ + "_get_anthropic_max_output" + ] + } + ] + }, + "tests/test_project_metadata.py": { + "imports": [ + "tomllib" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/test_auth_codex_provider.py": { + "imports": [ + "json", + "time", + "base64", + "pytest", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "AuthError", + "DEFAULT_CODEX_BASE_URL", + "PROVIDER_REGISTRY", + "_read_codex_tokens", + "_save_codex_tokens", + "_import_codex_cli_tokens", + "get_codex_auth_status", + "get_provider_auth_state", + "resolve_codex_runtime_credentials", + "resolve_provider" + ] + } + ] + }, + "tests/test_tool_call_parsers.py": { + "imports": [ + "json", + "sys", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "ParseResult", + "ToolCallParser", + "get_parser", + "list_parsers" + ] + } + ] + }, + "tests/test_auth_commands.py": { + "imports": [ + "base64", + "json", + "pytest" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "hermes_cli.auth_commands", + "names": [ + "auth_add_command" + ] + }, + { + "module": "hermes_cli.auth_commands", + "names": [ + "auth_add_command" + ] + }, + { + "module": "hermes_cli.auth_commands", + "names": [ + "auth_add_command" + ] + }, + { + "module": "hermes_cli.auth_commands", + "names": [ + "auth_add_command" + ] + }, + { + "module": "hermes_cli.auth_commands", + "names": [ + "auth_remove_command" + ] + }, + { + "module": "hermes_cli.auth_commands", + "names": [ + "auth_reset_command" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "clear_provider_auth" + ] + }, + { + "module": "hermes_cli.auth_commands", + "names": [ + "auth_list_command" + ] + }, + { + "module": "hermes_cli.auth_commands", + "names": [ + "auth_list_command" + ] + } + ] + }, + "tests/test_cli_retry.py": { + "imports": [], + "from_imports": [ + { + "module": "tests.test_cli_init", + "names": [ + "_make_cli" + ] + } + ] + }, + "tests/test_auth_nous_provider.py": { + "imports": [ + "json", + "httpx", + "pytest" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "AuthError", + "get_provider_auth_state", + "resolve_nous_runtime_credentials" + ] + } + ] + }, + "tests/test_atomic_json_write.py": { + "imports": [ + "json", + "os", + "pytest", + "threading" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "utils", + "names": [ + "atomic_json_write" + ] + } + ] + }, + "tests/test_fallback_model.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_plugins.py": { + "imports": [ + "logging", + "os", + "sys", + "types", + "pytest", + "yaml", + "hermes_cli.plugins" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_cli.plugins", + "names": [ + "ENTRY_POINTS_GROUP", + "VALID_HOOKS", + "LoadedPlugin", + "PluginContext", + "PluginManager", + "PluginManifest", + "get_plugin_manager", + "get_plugin_tool_names", + "discover_plugins", + "invoke_hook" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "model_tools", + "names": [ + "get_tool_definitions" + ] + } + ] + }, + "tests/test_model_tools.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "model_tools", + "names": [ + "handle_function_call", + "get_all_tool_names", + "get_toolset_for_tool", + "_AGENT_LOOP_TOOLS", + "_LEGACY_TOOLSET_MAP", + "TOOL_TO_TOOLSET_MAP" + ] + } + ] + }, + "tests/test_413_compression.py": { + "imports": [ + "pytest", + "uuid", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "agent.context_compressor", + "names": [ + "SUMMARY_PREFIX" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_agent_loop_vllm.py": { + "imports": [ + "asyncio", + "json", + "os", + "sys", + "pytest", + "requests" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "AgentResult", + "HermesAgentLoop" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "ServerManager", + "APIServerConfig" + ] + }, + { + "module": "transformers", + "names": [ + "AutoTokenizer" + ] + } + ] + }, + "tests/test_display.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "agent.display", + "names": [ + "build_tool_preview", + "capture_local_edit_snapshot", + "extract_edit_diff", + "_render_inline_unified_diff", + "_summarize_rendered_diff_sections", + "render_edit_diff_with_delta" + ] + } + ] + }, + "tests/test_cli_mcp_config_watch.py": { + "imports": [ + "time", + "cli", + "yaml", + "yaml", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + } + ] + }, + "tests/test_honcho_client_config.py": { + "imports": [ + "json", + "os", + "tempfile", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig" + ] + } + ] + }, + "tests/test_codex_models.py": { + "imports": [ + "json", + "os", + "sys", + "cli", + "cli", + "cli" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli.codex_models", + "names": [ + "DEFAULT_CODEX_MODELS", + "get_codex_model_ids" + ] + }, + { + "module": "hermes_cli.codex_models", + "names": [ + "get_codex_model_ids" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_model_flow_openai_codex" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/test_cli_prefix_matching.py": { + "imports": [ + "cli", + "cli", + "cli", + "cli", + "cli" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/test_runtime_provider_resolution.py": { + "imports": [], + "from_imports": [ + { + "module": "hermes_cli", + "names": [ + "runtime_provider" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "resolve_provider" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "resolve_provider" + ] + } + ] + }, + "tests/test_cli_secret_capture.py": { + "imports": [ + "queue", + "threading", + "time", + "cli", + "tools.skills_tool" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "hermes_cli.callbacks", + "names": [ + "prompt_for_secret" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "set_secret_capture_callback" + ] + } + ] + }, + "tests/test_batch_runner_checkpoint.py": { + "imports": [ + "json", + "os", + "pytest", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "threading", + "names": [ + "Lock" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "batch_runner", + "names": [ + "BatchRunner" + ] + } + ] + }, + "tests/test_sql_injection.py": { + "imports": [ + "re" + ], + "from_imports": [ + { + "module": "agent.insights", + "names": [ + "InsightsEngine" + ] + } + ] + }, + "tests/test_cli_approval_ui.py": { + "imports": [ + "queue", + "threading", + "time" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/test_anthropic_oauth_flow.py": { + "imports": [], + "from_imports": [ + { + "module": "hermes_cli.config", + "names": [ + "load_env", + "save_env_value" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_run_anthropic_oauth_flow" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_run_anthropic_oauth_flow" + ] + } + ] + }, + "tests/test_crossloop_client_cache.py": { + "imports": [ + "asyncio", + "threading", + "pytest", + "importlib", + "agent.auxiliary_client" + ], + "from_imports": [ + { + "module": "concurrent.futures", + "names": [ + "ThreadPoolExecutor" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_get_cached_client", + "_client_cache" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_get_cached_client" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_get_cached_client" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_get_cached_client" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_get_cached_client" + ] + } + ] + }, + "tests/test_cli_new_session.py": { + "imports": [ + "importlib", + "os", + "sys", + "cli" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "datetime", + "names": [ + "timedelta" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "TodoStore" + ] + } + ] + }, + "tests/run_interrupt_test.py": { + "imports": [ + "threading", + "time", + "sys", + "os", + "traceback" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent", + "IterationBudget" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "_run_single_child" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "set_interrupt", + "is_interrupted" + ] + } + ] + }, + "tests/test_personality_none.py": { + "imports": [ + "pytest", + "yaml" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "mock_open" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/test_branch_command.py": { + "imports": [ + "os", + "uuid", + "pytest" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "PropertyMock" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "resolve_command" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "COMMAND_REGISTRY" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "COMMAND_REGISTRY" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "COMMAND_REGISTRY" + ] + } + ] + }, + "tests/test_860_dedup.py": { + "imports": [ + "json", + "os", + "sqlite3", + "tempfile", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionStore" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionStore" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionStore" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_resume_display.py": { + "imports": [ + "os", + "sys", + "pytest", + "cli", + "cli" + ], + "from_imports": [ + { + "module": "io", + "names": [ + "StringIO" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + }, + { + "module": "cli", + "names": [ + "load_cli_config" + ] + } + ] + }, + "tests/test_surrogate_sanitization.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "_sanitize_surrogates", + "_sanitize_messages_surrogates", + "_SURROGATE_RE" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_hermes_state.py": { + "imports": [ + "time", + "pytest", + "sqlite3", + "time", + "time", + "sqlite3", + "inspect" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + } + ] + }, + "tests/test_anthropic_provider_persistence.py": { + "imports": [], + "from_imports": [ + { + "module": "hermes_cli.config", + "names": [ + "load_env" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_anthropic_oauth_token" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_anthropic_oauth_token", + "use_anthropic_claude_code_credentials" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_anthropic_api_key" + ] + } + ] + }, + "tests/test_codex_execution_paths.py": { + "imports": [ + "asyncio", + "sys", + "types", + "cron.scheduler", + "gateway.run", + "run_agent" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "AsyncMock" + ] + } + ] + }, + "tests/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/test_compression_boundary.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "agent.context_compressor", + "names": [ + "ContextCompressor" + ] + } + ] + }, + "tests/test_session_reset_fix.py": { + "imports": [ + "sys", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "agent.context_compressor", + "names": [ + "ContextCompressor" + ] + } + ] + }, + "tests/test_cli_provider_resolution.py": { + "imports": [ + "importlib", + "sys", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "contextlib", + "names": [ + "nullcontext" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "AuthError" + ] + }, + { + "module": "hermes_cli", + "names": [ + "main" + ] + } + ] + }, + "tests/test_cli_plan_command.py": { + "imports": [], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "scan_skill_commands" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/test_long_context_tier_429.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + } + ] + }, + "tests/test_file_permissions.py": { + "imports": [ + "json", + "os", + "stat", + "tempfile", + "unittest", + "shutil", + "shutil" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "cron.jobs", + "names": [ + "_secure_file" + ] + }, + { + "module": "cron.jobs", + "names": [ + "_secure_dir" + ] + }, + { + "module": "cron.jobs", + "names": [ + "ensure_dirs" + ] + }, + { + "module": "cron.jobs", + "names": [ + "save_jobs" + ] + }, + { + "module": "cron.jobs", + "names": [ + "save_job_output" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_config" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_env_value" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "ensure_hermes_home" + ] + } + ] + }, + "tests/test_plugins_cmd.py": { + "imports": [ + "logging", + "os", + "types", + "pytest", + "yaml", + "argparse" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "_copy_example_files", + "_read_manifest", + "_repo_name_from_url", + "_resolve_git_url", + "_sanitize_plugin_name", + "plugins_command" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "cmd_install" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "cmd_install" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "cmd_update" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "cmd_update" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "cmd_remove" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "cmd_remove" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "cmd_list" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "cmd_list" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "_copy_example_files" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "_copy_example_files" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "hermes_cli.plugins_cmd", + "names": [ + "_copy_example_files" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + } + ] + }, + "tests/test_toolset_distributions.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "toolset_distributions", + "names": [ + "DISTRIBUTIONS", + "get_distribution", + "list_distributions", + "sample_toolsets_from_distribution", + "validate_distribution" + ] + } + ] + }, + "tests/test_toolsets.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "toolsets", + "names": [ + "TOOLSETS", + "get_toolset", + "resolve_toolset", + "resolve_multiple_toolsets", + "get_all_toolsets", + "get_toolset_names", + "validate_toolset", + "create_custom_toolset", + "get_toolset_info" + ] + } + ] + }, + "tests/test_agent_loop.py": { + "imports": [ + "asyncio", + "json", + "sys", + "pytest", + "environments.agent_loop" + ], + "from_imports": [ + { + "module": "dataclasses", + "names": [ + "dataclass" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "AgentResult", + "HermesAgentLoop", + "ToolError", + "_extract_reasoning_from_message", + "resize_tool_pool" + ] + } + ] + }, + "tests/test_run_agent_codex_responses.py": { + "imports": [ + "sys", + "types", + "pytest", + "run_agent", + "json", + "json" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + } + ] + }, + "tests/test_streaming.py": { + "imports": [ + "json", + "threading", + "uuid", + "pytest", + "httpx", + "httpx", + "httpx", + "httpx" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "PropertyMock" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "openai", + "names": [ + "APIError" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "openai", + "names": [ + "APIError" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_provider_fallback.py": { + "imports": [], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_redirect_stdout_issue.py": { + "imports": [ + "contextlib", + "io", + "sys", + "threading", + "time", + "unittest" + ], + "from_imports": [] + }, + "tests/test_async_httpx_del_neuter.py": { + "imports": [ + "asyncio", + "threading", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "neuter_async_httpx_del" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "neuter_async_httpx_del" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "neuter_async_httpx_del" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_client_cache", + "_client_cache_lock", + "cleanup_stale_async_clients" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_client_cache", + "_client_cache_lock", + "cleanup_stale_async_clients" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_client_cache", + "_client_cache_lock", + "cleanup_stale_async_clients" + ] + }, + { + "module": "openai._base_client", + "names": [ + "AsyncHttpxClientWrapper" + ] + }, + { + "module": "openai._base_client", + "names": [ + "AsyncHttpxClientWrapper" + ] + } + ] + }, + "tests/test_cli_skin_integration.py": { + "imports": [], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI", + "_rich_text_from_ansi" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin", + "set_active_skin" + ] + } + ] + }, + "tests/test_cli_init.py": { + "imports": [ + "os", + "sys", + "importlib", + "cli", + "yaml", + "cli", + "yaml", + "cli" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "_normalize_root_model_keys" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "_normalize_root_model_keys" + ] + } + ] + }, + "tests/test_worktree.py": { + "imports": [ + "os", + "shutil", + "subprocess", + "pytest", + "uuid", + "shutil", + "time", + "time", + "time" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + } + ] + }, + "tests/test_auxiliary_config_bridge.py": { + "imports": [ + "json", + "os", + "sys", + "pytest", + "yaml", + "cli" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.vision_tools", + "names": [ + "_handle_vision_analyze" + ] + }, + { + "module": "tools.vision_tools", + "names": [ + "_handle_vision_analyze" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + } + ] + }, + "tests/test_run_agent.py": { + "imports": [ + "json", + "logging", + "re", + "uuid", + "pytest", + "run_agent", + "time", + "json", + "sys", + "sys", + "sys", + "inspect", + "inspect", + "inspect", + "inspect", + "inspect", + "inspect", + "json" + ], + "from_imports": [ + { + "module": "logging.handlers", + "names": [ + "RotatingFileHandler" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "DEFAULT_AGENT_IDENTITY" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "MEMORY_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "MEMORY_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "TOOL_USE_ENFORCEMENT_GUIDANCE" + ] + }, + { + "module": "run_agent", + "names": [ + "_paths_overlap" + ] + }, + { + "module": "run_agent", + "names": [ + "_paths_overlap" + ] + }, + { + "module": "run_agent", + "names": [ + "_paths_overlap" + ] + }, + { + "module": "run_agent", + "names": [ + "_paths_overlap" + ] + }, + { + "module": "run_agent", + "names": [ + "_paths_overlap" + ] + }, + { + "module": "run_agent", + "names": [ + "_paths_overlap" + ] + }, + { + "module": "run_agent", + "names": [ + "_paths_overlap" + ] + }, + { + "module": "run_agent", + "names": [ + "_extract_parallel_scope_path" + ] + }, + { + "module": "run_agent", + "names": [ + "_extract_parallel_scope_path", + "_paths_overlap" + ] + }, + { + "module": "run_agent", + "names": [ + "_should_parallelize_tool_batch" + ] + }, + { + "module": "run_agent", + "names": [ + "_SafeWriter" + ] + }, + { + "module": "io", + "names": [ + "StringIO" + ] + }, + { + "module": "run_agent", + "names": [ + "_SafeWriter" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "run_agent", + "names": [ + "_SafeWriter" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "run_agent", + "names": [ + "_SafeWriter" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "run_agent", + "names": [ + "_SafeWriter" + ] + }, + { + "module": "run_agent", + "names": [ + "_SafeWriter" + ] + }, + { + "module": "io", + "names": [ + "StringIO" + ] + } + ] + }, + "tests/test_flush_memories_codex.py": { + "imports": [ + "json", + "os", + "sys", + "types", + "pytest", + "run_agent" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock", + "call" + ] + } + ] + }, + "tests/test_interrupt_propagation.py": { + "imports": [ + "json", + "threading", + "time", + "unittest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "PropertyMock" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "set_interrupt", + "is_interrupted", + "_interrupt_event" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_external_credential_detection.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "detect_external_credentials" + ] + } + ] + }, + "tests/test_config_env_expansion.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "hermes_cli.config", + "names": [ + "_expand_env_vars", + "load_config" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "cli", + "names": [ + "load_cli_config" + ] + }, + { + "module": "cli", + "names": [ + "load_cli_config" + ] + } + ] + }, + "tests/test_1630_context_overflow_loop.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_cli_loading_indicator.py": { + "imports": [], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/test_cli_interrupt_subagent.py": { + "imports": [ + "json", + "os", + "queue", + "threading", + "time", + "unittest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "PropertyMock" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "set_interrupt", + "is_interrupted" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "_run_single_child" + ] + }, + { + "module": "run_agent", + "names": [ + "IterationBudget" + ] + } + ] + }, + "tests/test_exit_cleanup_interrupt.py": { + "imports": [ + "atexit", + "weakref", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "call" + ] + }, + { + "module": "cron", + "names": [ + "scheduler" + ] + }, + { + "module": "cron", + "names": [ + "scheduler" + ] + } + ] + }, + "tests/test_timezone.py": { + "imports": [ + "os", + "logging", + "sys", + "pytest", + "hermes_time", + "json", + "json", + "json", + "json", + "cron.jobs", + "cron.jobs", + "cron.jobs", + "cron.jobs" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timedelta", + "timezone" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "zoneinfo", + "names": [ + "ZoneInfo" + ] + }, + { + "module": "cron.jobs", + "names": [ + "parse_schedule" + ] + }, + { + "module": "cron.jobs", + "names": [ + "compute_next_run" + ] + }, + { + "module": "cron.jobs", + "names": [ + "create_job", + "load_jobs", + "save_jobs", + "get_due_jobs" + ] + }, + { + "module": "cron.jobs", + "names": [ + "_ensure_aware" + ] + }, + { + "module": "cron.jobs", + "names": [ + "_ensure_aware" + ] + }, + { + "module": "cron.jobs", + "names": [ + "create_job", + "load_jobs", + "save_jobs", + "get_due_jobs" + ] + }, + { + "module": "cron.jobs", + "names": [ + "create_job", + "load_jobs", + "save_jobs", + "get_due_jobs" + ] + }, + { + "module": "cron.jobs", + "names": [ + "create_job" + ] + }, + { + "module": "tools.code_execution_tool", + "names": [ + "execute_code" + ] + } + ] + }, + "tests/test_insights.py": { + "imports": [ + "time", + "pytest", + "json", + "json" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "agent.insights", + "names": [ + "InsightsEngine", + "_get_pricing", + "_estimate_cost", + "_format_duration", + "_bar_chart", + "_has_known_pricing", + "_DEFAULT_PRICING" + ] + } + ] + }, + "tests/test_cli_tools_command.py": { + "imports": [], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "call" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/test_agent_loop_tool_calling.py": { + "imports": [ + "asyncio", + "json", + "os", + "sys", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Set" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "environments.agent_loop", + "names": [ + "AgentResult", + "HermesAgentLoop" + ] + }, + { + "module": "atroposlib.envs.server_handling.openai_server", + "names": [ + "OpenAIServer" + ] + }, + { + "module": "atroposlib.envs.server_handling.openai_server", + "names": [ + "OpenAIServer" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "APIServerConfig" + ] + } + ] + }, + "tests/test_minisweagent_path.py": { + "imports": [], + "from_imports": [] + }, + "tests/test_session_meta_filtering.py": { + "imports": [ + "logging", + "types" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_cli_extension_hooks.py": { + "imports": [ + "importlib", + "sys", + "cli" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "prompt_toolkit.key_binding", + "names": [ + "KeyBindings" + ] + } + ] + }, + "tests/test_reasoning_command.py": { + "imports": [ + "unittest", + "re" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "cli", + "names": [ + "_parse_reasoning_config" + ] + }, + { + "module": "cli", + "names": [ + "_parse_reasoning_config" + ] + }, + { + "module": "cli", + "names": [ + "_parse_reasoning_config" + ] + }, + { + "module": "cli", + "names": [ + "_parse_reasoning_config" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "COMMANDS" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/test_percentage_clamp.py": { + "imports": [ + "pytest", + "os" + ], + "from_imports": [ + { + "module": "agent.context_compressor", + "names": [ + "ContextCompressor" + ] + }, + { + "module": "agent.context_compressor", + "names": [ + "ContextCompressor" + ] + }, + { + "module": "agent.context_compressor", + "names": [ + "ContextCompressor" + ] + } + ] + }, + "tests/test_provider_parity.py": { + "imports": [ + "json", + "os", + "sys", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "get_text_auxiliary_client" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "get_text_auxiliary_client" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "get_text_auxiliary_client" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "get_text_auxiliary_client", + "CodexAuxiliaryClient" + ] + } + ] + }, + "tests/test_setup_model_selection.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "_setup_provider_model_selection" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "_setup_provider_model_selection" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "_setup_provider_model_selection", + "_DEFAULT_PROVIDER_MODELS" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "_setup_provider_model_selection" + ] + } + ] + }, + "tests/test_cli_save_config_value.py": { + "imports": [ + "os", + "yaml", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "cli", + "names": [ + "save_config_value" + ] + }, + { + "module": "cli", + "names": [ + "save_config_value" + ] + }, + { + "module": "cli", + "names": [ + "save_config_value" + ] + }, + { + "module": "cli", + "names": [ + "save_config_value" + ] + }, + { + "module": "cli", + "names": [ + "save_config_value" + ] + } + ] + }, + "tests/test_managed_server_tool_support.py": { + "imports": [ + "inspect", + "sys", + "pytest", + "atroposlib", + "ast" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "atroposlib.envs.server_handling.managed_server", + "names": [ + "ManagedServer" + ] + }, + { + "module": "atroposlib.envs.server_handling.server_manager", + "names": [ + "ServerManager" + ] + }, + { + "module": "atroposlib.envs.server_handling.managed_server", + "names": [ + "ManagedServer" + ] + }, + { + "module": "atroposlib.envs.server_handling.managed_server", + "names": [ + "ManagedServer" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "get_parser" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "get_parser" + ] + }, + { + "module": "environments.tool_call_parsers", + "names": [ + "get_parser" + ] + } + ] + }, + "tests/test_token_persistence_non_cli.py": { + "imports": [], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_trajectory_compressor_async.py": { + "imports": [ + "types", + "pytest", + "os" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "trajectory_compressor", + "names": [ + "TrajectoryCompressor" + ] + }, + { + "module": "trajectory_compressor", + "names": [ + "TrajectoryCompressor" + ] + }, + { + "module": "trajectory_compressor", + "names": [ + "TrajectoryCompressor" + ] + } + ] + }, + "tests/test_compression_persistence.py": { + "imports": [ + "os", + "tempfile", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_packaging_metadata.py": { + "imports": [ + "tomllib" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/test_atomic_yaml_write.py": { + "imports": [ + "pytest", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "utils", + "names": [ + "atomic_yaml_write" + ] + } + ] + }, + "tests/test_anthropic_error_handling.py": { + "imports": [ + "asyncio", + "sys", + "types", + "pytest", + "gateway.run", + "run_agent" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + } + ] + }, + "tests/test_compressor_fallback_update.py": { + "imports": [], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "agent.context_compressor", + "names": [ + "ContextCompressor" + ] + } + ] + }, + "tests/test_cli_background_tui_refresh.py": { + "imports": [ + "threading", + "pytest", + "time", + "time" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/test_context_references.py": { + "imports": [ + "asyncio", + "subprocess", + "pytest" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "agent.context_references", + "names": [ + "parse_context_references" + ] + }, + { + "module": "agent.context_references", + "names": [ + "parse_context_references" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references_async" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references" + ] + }, + { + "module": "agent.context_references", + "names": [ + "preprocess_context_references_async" + ] + } + ] + }, + "tests/test_cli_file_drop.py": { + "imports": [ + "os", + "tempfile", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "cli", + "names": [ + "_detect_file_drop" + ] + } + ] + }, + "tests/test_trajectory_compressor.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "patch", + "MagicMock" + ] + }, + { + "module": "trajectory_compressor", + "names": [ + "CompressionConfig", + "TrajectoryMetrics", + "AggregateMetrics", + "TrajectoryCompressor" + ] + } + ] + }, + "tests/test_cli_preloaded_skills.py": { + "imports": [ + "importlib", + "os", + "sys", + "pytest", + "cli", + "cli", + "cli" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + } + ] + }, + "tests/test_primary_runtime_restore.py": { + "imports": [ + "time", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "PropertyMock" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/test_model_provider_persistence.py": { + "imports": [ + "os", + "pytest", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml", + "yaml" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "_save_model_choice" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "_save_model_choice" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_model_flow_api_key_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_model_flow_copilot" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_model_flow_copilot_acp" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_model_flow_api_key_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_model_flow_api_key_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + } + ] + }, + "tests/test_openai_client_lifecycle.py": { + "imports": [ + "sys", + "threading", + "types", + "httpx", + "pytest", + "run_agent" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "openai", + "names": [ + "APIConnectionError" + ] + } + ] + }, + "tests/test_interactive_interrupt.py": { + "imports": [ + "contextlib", + "io", + "json", + "logging", + "queue", + "sys", + "threading", + "time", + "os" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent", + "IterationBudget" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "set_interrupt", + "is_interrupted" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "_run_single_child" + ] + } + ] + }, + "tests/acp/test_events.py": { + "imports": [ + "asyncio", + "pytest", + "acp" + ], + "from_imports": [ + { + "module": "concurrent.futures", + "names": [ + "Future" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "acp.schema", + "names": [ + "ToolCallStart", + "ToolCallProgress", + "AgentThoughtChunk", + "AgentMessageChunk" + ] + }, + { + "module": "acp_adapter.events", + "names": [ + "make_message_cb", + "make_step_cb", + "make_thinking_cb", + "make_tool_progress_cb" + ] + }, + { + "module": "collections", + "names": [ + "deque" + ] + }, + { + "module": "collections", + "names": [ + "deque" + ] + } + ] + }, + "tests/acp/test_server.py": { + "imports": [ + "asyncio", + "os", + "pytest", + "acp" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "AsyncMock", + "patch" + ] + }, + { + "module": "acp.agent.router", + "names": [ + "build_agent_router" + ] + }, + { + "module": "acp.schema", + "names": [ + "AgentCapabilities", + "AuthenticateResponse", + "Implementation", + "InitializeResponse", + "ListSessionsResponse", + "LoadSessionResponse", + "NewSessionResponse", + "PromptResponse", + "ResumeSessionResponse", + "SetSessionConfigOptionResponse", + "SetSessionModeResponse", + "SessionInfo", + "TextContentBlock", + "Usage" + ] + }, + { + "module": "acp_adapter.server", + "names": [ + "HermesACPAgent", + "HERMES_VERSION" + ] + }, + { + "module": "acp_adapter.session", + "names": [ + "SessionManager" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "acp.schema", + "names": [ + "McpServerStdio", + "EnvVariable" + ] + }, + { + "module": "acp.schema", + "names": [ + "McpServerHttp", + "HttpHeader" + ] + }, + { + "module": "acp.schema", + "names": [ + "McpServerStdio" + ] + }, + { + "module": "acp.schema", + "names": [ + "McpServerStdio" + ] + } + ] + }, + "tests/acp/test_mcp_e2e.py": { + "imports": [ + "asyncio", + "pytest", + "acp" + ], + "from_imports": [ + { + "module": "collections", + "names": [ + "deque" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "acp.schema", + "names": [ + "EnvVariable", + "HttpHeader", + "McpServerHttp", + "McpServerStdio", + "NewSessionResponse", + "PromptResponse", + "TextContentBlock", + "ToolCallProgress", + "ToolCallStart" + ] + }, + { + "module": "acp_adapter.server", + "names": [ + "HermesACPAgent" + ] + }, + { + "module": "acp_adapter.session", + "names": [ + "SessionManager" + ] + } + ] + }, + "tests/acp/test_tools.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "acp_adapter.tools", + "names": [ + "TOOL_KIND_MAP", + "build_tool_complete", + "build_tool_start", + "build_tool_title", + "extract_locations", + "get_tool_kind", + "make_tool_call_id" + ] + }, + { + "module": "acp.schema", + "names": [ + "FileEditToolCallContent", + "ContentToolCallContent", + "ToolCallLocation", + "ToolCallStart", + "ToolCallProgress" + ] + } + ] + }, + "tests/acp/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/acp/test_session.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "acp_adapter.session", + "names": [ + "SessionManager", + "SessionState" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + } + ] + }, + "tests/acp/test_entry.py": { + "imports": [ + "acp" + ], + "from_imports": [ + { + "module": "acp_adapter", + "names": [ + "entry" + ] + } + ] + }, + "tests/acp/test_auth.py": { + "imports": [], + "from_imports": [ + { + "module": "acp_adapter.auth", + "names": [ + "has_provider", + "detect_provider" + ] + } + ] + }, + "tests/acp/test_permissions.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "concurrent.futures", + "names": [ + "Future" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "acp.schema", + "names": [ + "AllowedOutcome", + "DeniedOutcome", + "RequestPermissionResponse" + ] + }, + { + "module": "acp_adapter.permissions", + "names": [ + "make_approval_callback" + ] + } + ] + }, + "tests/honcho_plugin/test_client.py": { + "imports": [ + "json", + "os", + "pytest", + "sys", + "plugins.memory.honcho.client" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig", + "get_honcho_client", + "reset_honcho_client", + "resolve_active_host", + "resolve_config_path", + "GLOBAL_CONFIG_PATH", + "HOST" + ] + } + ] + }, + "tests/honcho_plugin/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/honcho_plugin/test_session.py": { + "imports": [], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "plugins.memory.honcho.session", + "names": [ + "HonchoSession", + "HonchoSessionManager" + ] + } + ] + }, + "tests/honcho_plugin/test_async_memory.py": { + "imports": [ + "json", + "queue", + "threading", + "time", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "call" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig" + ] + }, + { + "module": "plugins.memory.honcho.session", + "names": [ + "HonchoSession", + "HonchoSessionManager", + "_ASYNC_SHUTDOWN" + ] + } + ] + }, + "tests/integration/test_modal_terminal.py": { + "imports": [ + "pytest", + "os", + "sys", + "json", + "importlib.util" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "dotenv", + "names": [ + "load_dotenv" + ] + } + ] + }, + "tests/integration/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/integration/test_web_tools.py": { + "imports": [ + "pytest", + "json", + "asyncio", + "sys", + "os", + "argparse", + "traceback", + "traceback", + "traceback" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "typing", + "names": [ + "List" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "web_search_tool", + "web_extract_tool", + "web_crawl_tool", + "check_firecrawl_api_key", + "check_web_api_key", + "check_auxiliary_model", + "get_debug_session_info", + "_get_backend" + ] + } + ] + }, + "tests/integration/test_daytona_terminal.py": { + "imports": [ + "json", + "os", + "sys", + "pytest", + "importlib.util" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/integration/test_voice_channel_flow.py": { + "imports": [ + "struct", + "time", + "pytest", + "nacl.secret", + "os", + "ctypes.util", + "sys", + "os" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + } + ] + }, + "tests/integration/test_batch_runner.py": { + "imports": [ + "pytest", + "json", + "shutil", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/integration/test_checkpoint_resumption.py": { + "imports": [ + "pytest", + "json", + "os", + "shutil", + "sys", + "time", + "traceback", + "fire", + "threading" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Dict", + "Any" + ] + }, + { + "module": "batch_runner", + "names": [ + "BatchRunner" + ] + }, + { + "module": "batch_runner", + "names": [ + "BatchRunner" + ] + } + ] + }, + "tests/integration/test_ha_integration.py": { + "imports": [ + "asyncio", + "pytest", + "aiohttp", + "aiohttp", + "aiohttp" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.homeassistant", + "names": [ + "HomeAssistantAdapter" + ] + }, + { + "module": "tests.fakes.fake_ha_server", + "names": [ + "FakeHAServer", + "ENTITY_STATES" + ] + }, + { + "module": "tools.homeassistant_tool", + "names": [ + "_async_call_service", + "_async_get_state", + "_async_list_entities" + ] + } + ] + }, + "tests/e2e/conftest.py": { + "imports": [ + "asyncio", + "sys", + "uuid" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "SendResult" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry", + "SessionSource", + "build_session_key" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/e2e/test_telegram_commands.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "SendResult" + ] + }, + { + "module": "tests.e2e.conftest", + "names": [ + "make_adapter", + "make_event", + "make_runner", + "make_session_entry", + "make_source", + "send_and_capture" + ] + } + ] + }, + "tests/e2e/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/tools/test_symlink_prefix_confusion.py": { + "imports": [ + "os", + "pytest", + "tempfile" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/tools/test_terminal_requirements.py": { + "imports": [ + "importlib", + "logging" + ], + "from_imports": [] + }, + "tests/tools/test_delegate_toolset_scope.py": { + "imports": [], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "_strip_blocked_tools" + ] + } + ] + }, + "tests/tools/test_managed_tool_gateway.py": { + "imports": [ + "os", + "json", + "sys" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timedelta", + "timezone" + ] + }, + { + "module": "importlib.util", + "names": [ + "module_from_spec", + "spec_from_file_location" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + } + ] + }, + "tests/tools/test_skill_view_traversal.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "skill_view" + ] + } + ] + }, + "tests/tools/test_ssh_environment.py": { + "imports": [ + "json", + "os", + "subprocess", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "tools.environments.ssh", + "names": [ + "SSHEnvironment" + ] + }, + { + "module": "tools.environments", + "names": [ + "ssh" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "terminal_tool" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "cleanup_vm" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_get_env_config" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_get_env_config" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_get_env_config" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_get_env_config" + ] + } + ] + }, + "tests/tools/test_modal_sandbox_fixes.py": { + "imports": [ + "os", + "sys", + "pytest", + "tools.terminal_tool", + "inspect", + "inspect", + "inspect", + "inspect", + "inspect" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "model_tools", + "names": [ + "get_tool_definitions" + ] + }, + { + "module": "model_tools", + "names": [ + "get_tool_definitions" + ] + }, + { + "module": "tools.environments.modal", + "names": [ + "ModalEnvironment" + ] + }, + { + "module": "tools.environments.modal", + "names": [ + "ModalEnvironment" + ] + }, + { + "module": "tools.environments.modal", + "names": [ + "ModalEnvironment" + ] + } + ] + }, + "tests/tools/test_checkpoint_manager.py": { + "imports": [ + "logging", + "os", + "json", + "shutil", + "subprocess", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.checkpoint_manager", + "names": [ + "CheckpointManager", + "_shadow_repo_path", + "_init_shadow_repo", + "_run_git", + "_git_env", + "_dir_file_count", + "format_checkpoint_list", + "DEFAULT_EXCLUDES", + "CHECKPOINT_BASE" + ] + } + ] + }, + "tests/tools/test_command_guards.py": { + "imports": [ + "os", + "pytest", + "tools.approval", + "tools.tirith_security", + "sys" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.approval", + "names": [ + "approve_session", + "check_all_command_guards", + "clear_session", + "is_approved" + ] + }, + { + "module": "tools.approval", + "names": [ + "pop_pending" + ] + } + ] + }, + "tests/tools/test_voice_cli_integration.py": { + "imports": [ + "ast", + "os", + "queue", + "threading", + "pytest", + "tools.tts_tool", + "ast", + "ast", + "inspect", + "ast", + "ast", + "threading", + "time" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "_strip_markdown_for_tts" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "_load_tts_config", + "_get_provider", + "_import_elevenlabs", + "_import_sounddevice" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "_load_tts_config", + "_get_provider", + "_import_elevenlabs", + "_import_sounddevice" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "_load_tts_config", + "_get_provider", + "_import_elevenlabs", + "_import_sounddevice" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "_load_tts_config", + "_get_provider", + "_import_elevenlabs", + "_import_sounddevice" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "_load_tts_config", + "_get_provider", + "_import_elevenlabs", + "_import_sounddevice" + ] + } + ] + }, + "tests/tools/test_file_tools_live.py": { + "imports": [ + "pytest", + "json", + "os", + "sys", + "pytest", + "os" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "LocalEnvironment", + "_clean_shell_noise", + "_extract_fenced_output", + "_OUTPUT_FENCE", + "_SHELL_NOISE_SUBSTRINGS" + ] + }, + { + "module": "tools.file_operations", + "names": [ + "ShellFileOperations" + ] + } + ] + }, + "tests/tools/test_memory_tool.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.memory_tool", + "names": [ + "MemoryStore", + "memory_tool", + "_scan_memory_content", + "ENTRY_DELIMITER", + "MEMORY_SCHEMA" + ] + } + ] + }, + "tests/tools/test_docker_find.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.environments", + "names": [ + "docker" + ] + } + ] + }, + "tests/tools/test_file_tools.py": { + "imports": [ + "json", + "logging" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "FILE_TOOLS", + "READ_FILE_SCHEMA", + "WRITE_FILE_SCHEMA", + "PATCH_SCHEMA", + "SEARCH_FILES_SCHEMA" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "read_file_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "read_file_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "read_file_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "write_file_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "write_file_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "write_file_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "patch_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "patch_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "patch_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "patch_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "patch_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "patch_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "patch_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "search_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "search_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "search_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "patch_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "patch_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "clear_read_tracker" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "search_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "search_tool" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "search_tool" + ] + } + ] + }, + "tests/tools/test_terminal_disk_usage.py": { + "imports": [ + "pytest", + "sys", + "tools.terminal_tool" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "get_active_environments_info", + "_check_disk_usage_warning" + ] + } + ] + }, + "tests/tools/test_browser_console.py": { + "imports": [ + "json", + "os", + "sys", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_console" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_console" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_console" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_console" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_console" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "BROWSER_TOOL_SCHEMAS" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "BROWSER_TOOL_SCHEMAS" + ] + }, + { + "module": "toolsets", + "names": [ + "TOOLSETS" + ] + }, + { + "module": "toolsets", + "names": [ + "_HERMES_CORE_TOOLS" + ] + }, + { + "module": "model_tools", + "names": [ + "_LEGACY_TOOLSET_MAP" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools", + "names": [ + "browser_tool" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "BROWSER_TOOL_SCHEMAS" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_vision" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_vision" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_maybe_start_recording", + "_recording_sessions" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_maybe_stop_recording", + "_recording_sessions" + ] + } + ] + }, + "tests/tools/test_local_env_blocklist.py": { + "imports": [ + "os", + "threading" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "LocalEnvironment", + "_HERMES_PROVIDER_ENV_BLOCKLIST", + "_HERMES_PROVIDER_ENV_FORCE_PREFIX" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "OPTIONAL_ENV_VARS" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "_SANE_PATH" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "_SANE_PATH" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "_make_run_env" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "_make_run_env" + ] + } + ] + }, + "tests/tools/test_cronjob_tools.py": { + "imports": [ + "json", + "pytest", + "cron.jobs", + "cron.jobs" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.cronjob_tools", + "names": [ + "_scan_cron_prompt", + "check_cronjob_requirements", + "cronjob", + "schedule_cronjob", + "list_cronjobs", + "remove_cronjob" + ] + } + ] + }, + "tests/tools/test_website_policy.py": { + "imports": [ + "json", + "pytest", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.website_policy", + "names": [ + "WebsitePolicyError", + "check_website_access", + "load_website_blocklist" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + }, + { + "module": "tools.website_policy", + "names": [ + "invalidate_cache" + ] + }, + { + "module": "tools", + "names": [ + "browser_tool" + ] + }, + { + "module": "tools", + "names": [ + "browser_tool" + ] + }, + { + "module": "tools", + "names": [ + "web_tools" + ] + }, + { + "module": "tools", + "names": [ + "website_policy" + ] + }, + { + "module": "tools", + "names": [ + "web_tools" + ] + }, + { + "module": "tools", + "names": [ + "web_tools" + ] + }, + { + "module": "tools", + "names": [ + "web_tools" + ] + } + ] + }, + "tests/tools/test_browser_ssrf_local.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "tools", + "names": [ + "browser_tool" + ] + } + ] + }, + "tests/tools/test_windows_compat.py": { + "imports": [ + "ast", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/tools/test_send_message_missing_platforms.py": { + "imports": [ + "asyncio", + "os", + "time" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "tools.send_message_tool", + "names": [ + "_send_dingtalk", + "_send_homeassistant", + "_send_mattermost", + "_send_matrix" + ] + } + ] + }, + "tests/tools/test_url_safety.py": { + "imports": [ + "socket", + "ipaddress", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.url_safety", + "names": [ + "is_safe_url", + "_is_blocked_ip" + ] + } + ] + }, + "tests/tools/test_singularity_preflight.py": { + "imports": [ + "subprocess", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.environments.singularity", + "names": [ + "_find_singularity_executable", + "_ensure_singularity_available" + ] + } + ] + }, + "tests/tools/test_browser_cleanup.py": { + "imports": [ + "json" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_extract_screenshot_path_from_text" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_extract_screenshot_path_from_text" + ] + }, + { + "module": "tools", + "names": [ + "browser_tool" + ] + } + ] + }, + "tests/tools/test_todo_tool.py": { + "imports": [ + "json" + ], + "from_imports": [ + { + "module": "tools.todo_tool", + "names": [ + "TodoStore", + "todo_tool" + ] + } + ] + }, + "tests/tools/test_read_loop_detection.py": { + "imports": [ + "json", + "unittest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "read_file_tool", + "search_tool", + "get_read_files_summary", + "clear_read_tracker", + "notify_other_tool_call", + "_read_tracker" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "TodoStore" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "TodoStore" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "TodoStore" + ] + }, + { + "module": "tools.todo_tool", + "names": [ + "TodoStore" + ] + } + ] + }, + "tests/tools/test_credential_files.py": { + "imports": [ + "json", + "os", + "pytest", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.credential_files", + "names": [ + "clear_credential_files", + "get_credential_file_mounts", + "get_cache_directory_mounts", + "get_skills_directory_mount", + "iter_cache_files", + "iter_skills_files", + "register_credential_file", + "register_credential_files", + "reset_config_cache" + ] + } + ] + }, + "tests/tools/test_interrupt.py": { + "imports": [ + "queue", + "threading", + "time", + "pytest", + "types" + ], + "from_imports": [ + { + "module": "tools.interrupt", + "names": [ + "set_interrupt", + "is_interrupted" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "set_interrupt", + "is_interrupted" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "tools.interrupt", + "names": [ + "set_interrupt" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "LocalEnvironment" + ] + } + ] + }, + "tests/tools/test_fuzzy_match.py": { + "imports": [], + "from_imports": [ + { + "module": "tools.fuzzy_match", + "names": [ + "fuzzy_find_and_replace" + ] + } + ] + }, + "tests/tools/test_yolo_mode.py": { + "imports": [ + "os", + "pytest", + "tools.approval", + "tools.tirith_security" + ], + "from_imports": [ + { + "module": "tools.approval", + "names": [ + "check_all_command_guards", + "check_dangerous_command", + "detect_dangerous_command" + ] + } + ] + }, + "tests/tools/test_approval.py": { + "imports": [ + "ast", + "tools.approval", + "os", + "threading" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.approval", + "names": [ + "_get_approval_mode", + "approve_session", + "clear_session", + "detect_dangerous_command", + "has_pending", + "is_approved", + "load_permanent", + "pop_pending", + "prompt_dangerous_approval", + "submit_pending" + ] + } + ] + }, + "tests/tools/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/tools/test_config_null_guard.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "_get_provider", + "DEFAULT_PROVIDER" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "_get_provider", + "DEFAULT_PROVIDER" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "trajectory_compressor", + "names": [ + "CompressionConfig", + "TrajectoryCompressor" + ] + }, + { + "module": "trajectory_compressor", + "names": [ + "CompressionConfig" + ] + }, + { + "module": "hermes_constants", + "names": [ + "OPENROUTER_BASE_URL" + ] + } + ] + }, + "tests/tools/test_file_operations.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "tools.file_operations", + "names": [ + "_is_write_denied", + "WRITE_DENIED_PATHS", + "WRITE_DENIED_PREFIXES", + "ReadResult", + "WriteResult", + "PatchResult", + "SearchResult", + "SearchMatch", + "LintResult", + "ShellFileOperations", + "BINARY_EXTENSIONS", + "IMAGE_EXTENSIONS", + "MAX_LINE_LENGTH" + ] + } + ] + }, + "tests/tools/test_process_registry.py": { + "imports": [ + "json", + "os", + "time", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "_HERMES_PROVIDER_ENV_FORCE_PREFIX" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "ProcessRegistry", + "ProcessSession", + "MAX_OUTPUT_CHARS", + "FINISHED_TTL_SECONDS", + "MAX_PROCESSES" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "_handle_process" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "_handle_process" + ] + }, + { + "module": "tools.process_registry", + "names": [ + "_handle_process" + ] + } + ] + }, + "tests/tools/test_browser_homebrew_paths.py": { + "imports": [ + "json", + "os", + "subprocess", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock", + "mock_open" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_discover_homebrew_node_dirs", + "_find_agent_browser", + "_run_browser_command", + "_SANE_PATH" + ] + } + ] + }, + "tests/tools/test_ansi_strip.py": { + "imports": [], + "from_imports": [ + { + "module": "tools.ansi_strip", + "names": [ + "strip_ansi" + ] + } + ] + }, + "tests/tools/test_send_message_tool.py": { + "imports": [ + "asyncio", + "json", + "os", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "tools.send_message_tool", + "names": [ + "_send_telegram", + "_send_to_platform", + "send_message_tool" + ] + } + ] + }, + "tests/tools/test_skill_size_limits.py": { + "imports": [ + "json", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.skill_manager_tool", + "names": [ + "MAX_SKILL_CONTENT_CHARS", + "MAX_SKILL_FILE_BYTES", + "_validate_content_size", + "skill_manage" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "skill_view" + ] + } + ] + }, + "tests/tools/test_local_persistent.py": { + "imports": [ + "glob", + "pytest" + ], + "from_imports": [ + { + "module": "tools.environments.local", + "names": [ + "LocalEnvironment" + ] + }, + { + "module": "tools.environments.persistent_shell", + "names": [ + "PersistentShellMixin" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_get_env_config" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_get_env_config" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_get_env_config" + ] + } + ] + }, + "tests/tools/test_session_search.py": { + "imports": [ + "json", + "time", + "pytest" + ], + "from_imports": [ + { + "module": "tools.session_search_tool", + "names": [ + "_format_timestamp", + "_format_conversation", + "_truncate_around_matches", + "_HIDDEN_SESSION_SOURCES", + "MAX_SESSION_CHARS", + "SESSION_SEARCH_SCHEMA" + ] + }, + { + "module": "tools.session_search_tool", + "names": [ + "session_search" + ] + }, + { + "module": "tools.session_search_tool", + "names": [ + "session_search" + ] + }, + { + "module": "tools.session_search_tool", + "names": [ + "session_search" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "tools.session_search_tool", + "names": [ + "session_search" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "tools.session_search_tool", + "names": [ + "session_search" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "patch" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "tools.session_search_tool", + "names": [ + "session_search" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "tools.session_search_tool", + "names": [ + "session_search" + ] + } + ] + }, + "tests/tools/test_skills_sync.py": { + "imports": [], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.skills_sync", + "names": [ + "_get_bundled_dir", + "_read_manifest", + "_write_manifest", + "_discover_bundled_skills", + "_compute_relative_dest", + "_dir_hash", + "sync_skills", + "MANIFEST_FILE", + "SKILLS_DIR" + ] + }, + { + "module": "contextlib", + "names": [ + "ExitStack" + ] + } + ] + }, + "tests/tools/test_browser_cdp_override.py": { + "imports": [], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "Mock", + "patch" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_resolve_cdp_override" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_resolve_cdp_override" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_resolve_cdp_override" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_resolve_cdp_override" + ] + } + ] + }, + "tests/tools/test_managed_browserbase_and_modal.py": { + "imports": [ + "os", + "sys", + "tempfile", + "threading", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "importlib.util", + "names": [ + "module_from_spec", + "spec_from_file_location" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + } + ] + }, + "tests/tools/test_terminal_tool_requirements.py": { + "imports": [ + "importlib" + ], + "from_imports": [ + { + "module": "model_tools", + "names": [ + "get_tool_definitions" + ] + } + ] + }, + "tests/tools/test_parse_env_var.py": { + "imports": [ + "json", + "pytest", + "sys", + "tools.terminal_tool", + "os" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_parse_env_var" + ] + } + ] + }, + "tests/tools/test_patch_parser.py": { + "imports": [], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "tools.patch_parser", + "names": [ + "OperationType", + "apply_v4a_operations", + "parse_v4a_patch" + ] + } + ] + }, + "tests/tools/test_debug_helpers.py": { + "imports": [ + "json", + "os" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.debug_helpers", + "names": [ + "DebugSession" + ] + } + ] + }, + "tests/tools/test_clipboard.py": { + "imports": [ + "base64", + "os", + "queue", + "subprocess", + "sys", + "pytest", + "hermes_cli.clipboard", + "hermes_cli.clipboard", + "subprocess", + "hermes_cli.clipboard", + "json", + "json", + "hermes_cli.clipboard", + "subprocess" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock", + "PropertyMock", + "mock_open" + ] + }, + { + "module": "hermes_cli.clipboard", + "names": [ + "save_clipboard_image", + "has_clipboard_image", + "_is_wsl", + "_linux_save", + "_macos_pngpaste", + "_macos_osascript", + "_macos_has_image", + "_xclip_save", + "_xclip_has_image", + "_wsl_save", + "_wsl_has_image", + "_wayland_save", + "_wayland_has_image", + "_convert_to_png" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/tools/test_transcription_tools.py": { + "imports": [ + "os", + "struct", + "subprocess", + "wave", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_local_command_template" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_local_command" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_validate_audio_file" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_validate_audio_file" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_validate_audio_file", + "SUPPORTED_FORMATS" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_validate_audio_file" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "get_stt_model_from_config" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "get_stt_model_from_config" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "get_stt_model_from_config" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "get_stt_model_from_config" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "get_stt_model_from_config" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq", + "GROQ_BASE_URL" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_openai" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_openai", + "OPENAI_BASE_URL" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_openai" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_openai" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_local" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_local" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_local" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_local" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq", + "DEFAULT_GROQ_STT_MODEL" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq", + "DEFAULT_GROQ_STT_MODEL" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_openai", + "DEFAULT_STT_MODEL" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_openai", + "DEFAULT_STT_MODEL" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_openai" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_groq" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_openai" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_load_stt_config" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_load_stt_config" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio", + "DEFAULT_GROQ_STT_MODEL" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + } + ] + }, + "tests/tools/test_browser_camofox_persistence.py": { + "imports": [ + "json", + "pytest", + "tools.browser_camofox", + "tools.browser_camofox" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "_drop_session", + "_get_session", + "_managed_persistence_enabled", + "camofox_close", + "camofox_navigate", + "check_camofox_available", + "cleanup_all_camofox_sessions", + "get_vnc_url" + ] + }, + { + "module": "tools.browser_camofox_state", + "names": [ + "get_camofox_identity" + ] + } + ] + }, + "tests/tools/test_llm_content_none_guard.py": { + "imports": [ + "asyncio", + "types", + "pytest", + "os" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "extract_content_or_reasoning" + ] + } + ] + }, + "tests/tools/test_write_deny.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.file_operations", + "names": [ + "_is_write_denied" + ] + } + ] + }, + "tests/tools/test_vision_tools.py": { + "imports": [ + "asyncio", + "json", + "logging", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Awaitable" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "tools.vision_tools", + "names": [ + "_validate_image_url", + "_handle_vision_analyze", + "_determine_mime_type", + "_image_to_base64_data_url", + "vision_analyze_tool", + "check_vision_requirements", + "get_debug_session_info" + ] + }, + { + "module": "tools.vision_tools", + "names": [ + "_download_image" + ] + }, + { + "module": "tools.vision_tools", + "names": [ + "_download_image" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tests/tools/test_daytona_environment.py": { + "imports": [ + "threading", + "pytest", + "types", + "enum" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "PropertyMock" + ] + }, + { + "module": "tools.environments.daytona", + "names": [ + "DaytonaEnvironment" + ] + } + ] + }, + "tests/tools/test_docker_environment.py": { + "imports": [ + "logging", + "subprocess", + "sys", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "io", + "names": [ + "StringIO" + ] + }, + { + "module": "tools.environments", + "names": [ + "docker" + ] + } + ] + }, + "tests/tools/test_skill_env_passthrough.py": { + "imports": [ + "json", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.env_passthrough", + "names": [ + "clear_env_passthrough", + "is_env_passthrough", + "reset_config_cache" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_env_value" + ] + }, + { + "module": "tools.env_passthrough", + "names": [ + "get_all_passthrough" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "skill_view" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "skill_view" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "skill_view" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "skill_view" + ] + } + ] + }, + "tests/tools/test_terminal_timeout_output.py": { + "imports": [], + "from_imports": [ + { + "module": "tools.environments.local", + "names": [ + "LocalEnvironment" + ] + } + ] + }, + "tests/tools/test_web_tools_config.py": { + "imports": [ + "importlib", + "json", + "os", + "sys", + "types", + "pytest", + "tools.web_tools", + "tools.web_tools", + "tools.web_tools", + "tools.web_tools", + "tools.web_tools", + "tools.web_tools", + "tools.web_tools", + "tools.web_tools", + "tools.web_tools" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock", + "AsyncMock" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_web_requires_env" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_backend" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_parallel_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_parallel_client" + ] + }, + { + "module": "parallel", + "names": [ + "Parallel" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_parallel_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_get_firecrawl_client" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "check_web_api_key" + ] + } + ] + }, + "tests/tools/test_tirith_security.py": { + "imports": [ + "json", + "os", + "subprocess", + "time", + "pytest", + "tools.tirith_security", + "urllib.request", + "tempfile", + "tempfile", + "tempfile", + "tempfile", + "tempfile", + "tempfile", + "tempfile" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "check_command_security", + "ensure_installed" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_verify_cosign" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_verify_cosign" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_verify_cosign" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_verify_cosign" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_verify_cosign" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_verify_cosign" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_install_tirith" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_install_tirith" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_install_tirith" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_install_tirith" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_install_tirith" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_resolve_tirith_path", + "_INSTALL_FAILED" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_hermes_bin_dir" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_failure_marker_path" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_get_hermes_home" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_mark_install_failed", + "_is_install_failed_on_disk", + "_clear_install_failed" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_mark_install_failed", + "_is_install_failed_on_disk" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_mark_install_failed", + "_is_install_failed_on_disk" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_mark_install_failed", + "_is_install_failed_on_disk" + ] + }, + { + "module": "tools.tirith_security", + "names": [ + "_mark_install_failed", + "_is_install_failed_on_disk" + ] + } + ] + }, + "tests/tools/test_skills_guard.py": { + "imports": [ + "os", + "stat", + "tempfile", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.skills_guard", + "names": [ + "Finding", + "ScanResult", + "scan_file", + "scan_skill", + "should_allow_install", + "format_scan_report", + "content_hash", + "_determine_verdict", + "_resolve_trust_level", + "_check_structure", + "_unicode_char_name", + "INSTALL_POLICY", + "INVISIBLE_CHARS", + "MAX_FILE_COUNT", + "MAX_SINGLE_FILE_KB" + ] + } + ] + }, + "tests/tools/test_browser_secret_exfil.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_navigate" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_navigate" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_navigate" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "web_extract_tool" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "web_extract_tool" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_extract_relevant_content" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_extract_relevant_content" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_extract_relevant_content" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + } + ] + }, + "tests/tools/test_clarify_tool.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "List", + "Optional" + ] + }, + { + "module": "tools.clarify_tool", + "names": [ + "clarify_tool", + "check_clarify_requirements", + "MAX_CHOICES", + "CLARIFY_SCHEMA" + ] + } + ] + }, + "tests/tools/test_mcp_probe.py": { + "imports": [ + "asyncio", + "pytest", + "tools.mcp_tool" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "probe_mcp_server_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "probe_mcp_server_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "probe_mcp_server_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "probe_mcp_server_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "probe_mcp_server_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "probe_mcp_server_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "probe_mcp_server_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "probe_mcp_server_tools" + ] + } + ] + }, + "tests/tools/test_managed_modal_environment.py": { + "imports": [ + "json", + "sys", + "tempfile", + "threading", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "importlib.util", + "names": [ + "module_from_spec", + "spec_from_file_location" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/tools/test_browser_camofox.py": { + "imports": [ + "json", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.browser_camofox", + "names": [ + "camofox_back", + "camofox_click", + "camofox_close", + "camofox_console", + "camofox_get_images", + "camofox_navigate", + "camofox_press", + "camofox_scroll", + "camofox_snapshot", + "camofox_type", + "camofox_vision", + "check_camofox_available", + "cleanup_all_camofox_sessions", + "is_camofox_mode" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "browser_navigate" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "check_browser_requirements" + ] + } + ] + }, + "tests/tools/test_mcp_stability.py": { + "imports": [ + "asyncio", + "os", + "signal", + "threading", + "pytest", + "tools.mcp_tool", + "time", + "inspect" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_mcp_loop_exception_handler" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_mcp_loop_exception_handler" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_mcp_loop_exception_handler" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_mcp_loop_exception_handler" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_snapshot_child_pids" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_stdio_pids", + "_lock" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_kill_orphaned_mcp_children", + "_stdio_pids", + "_lock" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_kill_orphaned_mcp_children", + "_stdio_pids", + "_lock" + ] + }, + { + "module": "cli", + "names": [ + "HermesCLI" + ] + } + ] + }, + "tests/tools/test_skill_view_path_check.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/tools/test_search_hidden_dirs.py": { + "imports": [ + "os", + "subprocess", + "pytest", + "tools.skills_hub", + "tools.skills_hub" + ], + "from_imports": [] + }, + "tests/tools/test_file_staleness.py": { + "imports": [ + "json", + "os", + "tempfile", + "time", + "unittest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "read_file_tool", + "write_file_tool", + "patch_tool", + "clear_read_tracker", + "_check_file_staleness" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "_read_tracker", + "_read_tracker_lock" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "_read_tracker", + "_read_tracker_lock" + ] + } + ] + }, + "tests/tools/test_browser_camofox_state.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools", + "names": [ + "browser_camofox_state" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG" + ] + } + ] + }, + "tests/tools/test_mcp_tool_issue_948.py": { + "imports": [ + "asyncio", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask", + "_format_connect_error", + "_resolve_stdio_command" + ] + } + ] + }, + "tests/tools/test_web_tools_tavily.py": { + "imports": [ + "json", + "os", + "asyncio", + "pytest", + "httpx" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_normalize_tavily_search_results" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_normalize_tavily_search_results" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_normalize_tavily_search_results" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_normalize_tavily_documents" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_normalize_tavily_documents" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_normalize_tavily_documents" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_normalize_tavily_documents" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_normalize_tavily_documents" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_tavily_request" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "web_search_tool" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "web_extract_tool" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "web_crawl_tool" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "web_crawl_tool" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_tavily_request" + ] + }, + { + "module": "tools.web_tools", + "names": [ + "_tavily_request" + ] + } + ] + }, + "tests/tools/test_file_write_safety.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.file_operations", + "names": [ + "_is_write_denied" + ] + } + ] + }, + "tests/tools/test_env_passthrough.py": { + "imports": [ + "os", + "pytest", + "yaml" + ], + "from_imports": [ + { + "module": "tools.env_passthrough", + "names": [ + "clear_env_passthrough", + "get_all_passthrough", + "is_env_passthrough", + "register_env_passthrough", + "reset_config_cache" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "_sanitize_subprocess_env", + "_HERMES_PROVIDER_ENV_BLOCKLIST" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "_sanitize_subprocess_env", + "_HERMES_PROVIDER_ENV_BLOCKLIST" + ] + }, + { + "module": "tools.environments.local", + "names": [ + "_make_run_env", + "_HERMES_PROVIDER_ENV_BLOCKLIST" + ] + } + ] + }, + "tests/tools/test_registry.py": { + "imports": [ + "json" + ], + "from_imports": [ + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + } + ] + }, + "tests/tools/test_modal_snapshot_isolation.py": { + "imports": [ + "json", + "os", + "sys", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "importlib.util", + "names": [ + "module_from_spec", + "spec_from_file_location" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/tools/test_skills_hub_clawhub.py": { + "imports": [ + "unittest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "ClawHubSource", + "SkillMeta" + ] + } + ] + }, + "tests/tools/test_browser_content_none_guard.py": { + "imports": [ + "types", + "pytest", + "os" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_extract_relevant_content" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_extract_relevant_content" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_extract_relevant_content" + ] + } + ] + }, + "tests/tools/test_hidden_dir_filter.py": { + "imports": [ + "os" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path", + "PurePosixPath", + "PureWindowsPath" + ] + } + ] + }, + "tests/tools/test_mcp_dynamic_discovery.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask", + "_register_server_tools" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_MCP_NOTIFICATION_TYPES" + ] + }, + { + "module": "mcp.types", + "names": [ + "ServerNotification", + "ToolListChangedNotification" + ] + } + ] + }, + "tests/tools/test_force_dangerous_override.py": { + "imports": [], + "from_imports": [] + }, + "tests/tools/test_skill_improvements.py": { + "imports": [ + "json", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.skill_manager_tool", + "names": [ + "_create_skill", + "_patch_skill", + "_write_file", + "skill_manage" + ] + } + ] + }, + "tests/tools/test_file_read_guards.py": { + "imports": [ + "json", + "os", + "tempfile", + "time", + "unittest", + "tools.file_tools", + "tools.file_tools" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.file_tools", + "names": [ + "read_file_tool", + "clear_read_tracker", + "reset_file_dedup", + "_is_blocked_device", + "_get_max_read_chars", + "_DEFAULT_MAX_READ_CHARS" + ] + } + ] + }, + "tests/tools/test_managed_media_gateways.py": { + "imports": [ + "sys", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "importlib.util", + "names": [ + "module_from_spec", + "spec_from_file_location" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/tools/test_rl_training_tool.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "tools.rl_training_tool", + "names": [ + "RunState", + "_stop_training_run" + ] + } + ] + }, + "tests/tools/test_skills_hub.py": { + "imports": [ + "json", + "httpx", + "pytest", + "tools.skills_hub", + "tools.skills_hub", + "tools.skills_hub" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "GitHubAuth", + "GitHubSource", + "LobeHubSource", + "SkillsShSource", + "WellKnownSkillSource", + "OptionalSkillSource", + "SkillMeta", + "SkillBundle", + "HubLockFile", + "TapsManager", + "bundle_content_hash", + "check_for_skill_updates", + "create_source_router", + "unified_search", + "append_audit_log", + "_skill_meta_to_dict", + "quarantine_bundle" + ] + }, + { + "module": "tools.skills_guard", + "names": [ + "TRUSTED_REPOS" + ] + }, + { + "module": "tools.skills_guard", + "names": [ + "content_hash" + ] + } + ] + }, + "tests/tools/test_mcp_oauth.py": { + "imports": [ + "json", + "os", + "pytest", + "asyncio", + "asyncio", + "tools.mcp_oauth", + "tools.mcp_oauth", + "tools.mcp_oauth", + "asyncio", + "logging", + "logging" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock", + "AsyncMock" + ] + }, + { + "module": "tools.mcp_oauth", + "names": [ + "HermesTokenStorage", + "OAuthNonInteractiveError", + "build_oauth_auth", + "remove_oauth_tokens", + "_find_free_port", + "_can_open_browser", + "_is_interactive", + "_wait_for_callback" + ] + }, + { + "module": "tools.mcp_oauth", + "names": [ + "_make_callback_handler" + ] + }, + { + "module": "tools.mcp_oauth", + "names": [ + "_make_callback_handler" + ] + }, + { + "module": "io", + "names": [ + "BytesIO" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "mcp.client.auth", + "names": [ + "OAuthClientProvider" + ] + }, + { + "module": "mcp.client.auth", + "names": [ + "OAuthClientProvider" + ] + }, + { + "module": "mcp.client.auth", + "names": [ + "OAuthClientProvider" + ] + }, + { + "module": "mcp.client.auth", + "names": [ + "OAuthClientProvider" + ] + } + ] + }, + "tests/tools/test_skill_manager_tool.py": { + "imports": [ + "json" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.skill_manager_tool", + "names": [ + "_validate_name", + "_validate_category", + "_validate_frontmatter", + "_validate_file_path", + "_find_skill", + "_resolve_skill_dir", + "_create_skill", + "_edit_skill", + "_patch_skill", + "_delete_skill", + "_write_file", + "_remove_file", + "skill_manage", + "VALID_NAME_RE", + "ALLOWED_SUBDIRS", + "MAX_NAME_LENGTH" + ] + } + ] + }, + "tests/tools/test_code_execution.py": { + "imports": [ + "pytest", + "json", + "os", + "sys", + "time", + "threading", + "unittest", + "re", + "tools.file_tools", + "tools.web_tools", + "re", + "time" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "tools.code_execution_tool", + "names": [ + "SANDBOX_ALLOWED_TOOLS", + "execute_code", + "generate_hermes_tools_module", + "check_sandbox_requirements", + "build_execute_code_schema", + "EXECUTE_CODE_SCHEMA", + "_TOOL_DOC_LINES" + ] + }, + { + "module": "tools.code_execution_tool", + "names": [ + "_TOOL_STUBS" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.code_execution_tool", + "names": [ + "_TOOL_STUBS" + ] + }, + { + "module": "tools.code_execution_tool", + "names": [ + "_TOOL_STUBS" + ] + }, + { + "module": "tools.code_execution_tool", + "names": [ + "_load_config" + ] + }, + { + "module": "tools.code_execution_tool", + "names": [ + "_load_config" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_interrupt_event" + ] + }, + { + "module": "tools.terminal_tool", + "names": [ + "_interrupt_event" + ] + } + ] + }, + "tests/tools/test_homeassistant_tool.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "tools.homeassistant_tool", + "names": [ + "_check_ha_available", + "_filter_and_summarize", + "_build_service_payload", + "_parse_service_response", + "_get_headers", + "_handle_get_state", + "_handle_call_service", + "_BLOCKED_DOMAINS", + "_ENTITY_ID_RE" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tests/tools/test_transcription.py": { + "imports": [ + "json", + "os", + "tempfile", + "pytest", + "stat" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "mock_open" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_validate_audio_file" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_validate_audio_file" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_validate_audio_file" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_validate_audio_file", + "MAX_FILE_SIZE" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_openai" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_get_provider" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_local" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_local" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "_transcribe_openai" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + }, + { + "module": "tools.transcription_tools", + "names": [ + "transcribe_audio" + ] + } + ] + }, + "tests/tools/test_skills_tool.py": { + "imports": [ + "json", + "os", + "pytest", + "tools.skills_tool" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_get_required_environment_variables", + "_parse_frontmatter", + "_parse_tags", + "_get_category_from_path", + "_estimate_tokens", + "_find_all_skills", + "skill_matches_platform", + "skills_list", + "skills_categories", + "skill_view", + "MAX_DESCRIPTION_LENGTH" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_is_env_var_persisted" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_env_value" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_env_value" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "save_env_value" + ] + } + ] + }, + "tests/tools/test_mixture_of_agents_tool.py": { + "imports": [ + "importlib", + "json", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + } + ] + }, + "tests/tools/test_delegate.py": { + "imports": [ + "json", + "os", + "sys", + "threading", + "unittest", + "model_tools", + "model_tools", + "model_tools" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "DELEGATE_BLOCKED_TOOLS", + "DELEGATE_TASK_SCHEMA", + "MAX_CONCURRENT_CHILDREN", + "MAX_DEPTH", + "check_delegate_requirements", + "delegate_task", + "_build_child_agent", + "_build_child_system_prompt", + "_strip_blocked_tools", + "_resolve_delegation_credentials" + ] + } + ] + }, + "tests/tools/test_voice_mode.py": { + "imports": [ + "os", + "struct", + "time", + "wave", + "pytest", + "numpy", + "threading", + "threading", + "threading", + "tools.voice_mode", + "tools.voice_mode", + "tools.voice_mode", + "threading", + "subprocess", + "os", + "inspect" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "detect_audio_environment" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "detect_audio_environment" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "detect_audio_environment" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "check_voice_requirements" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "check_voice_requirements" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "check_voice_requirements" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder", + "SAMPLE_RATE" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder", + "SAMPLE_RATE" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "is_whisper_hallucination" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "is_whisper_hallucination" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_audio_file" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_audio_file" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_audio_file" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "cleanup_temp_recordings" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "cleanup_temp_recordings" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "cleanup_temp_recordings" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "cleanup_temp_recordings" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_beep" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_beep" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_beep" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "play_beep" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder", + "SAMPLE_RATE" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "stop_playback", + "_playback_lock" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "AudioRecorder" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "detect_audio_environment" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "detect_audio_environment" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "detect_audio_environment" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "transcribe_recording" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "transcribe_recording" + ] + }, + { + "module": "tools.voice_mode", + "names": [ + "transcribe_recording" + ] + } + ] + }, + "tests/tools/test_cron_prompt_injection.py": { + "imports": [], + "from_imports": [ + { + "module": "tools.cronjob_tools", + "names": [ + "_scan_cron_prompt" + ] + } + ] + }, + "tests/tools/test_mcp_tool.py": { + "imports": [ + "asyncio", + "json", + "os", + "pytest", + "math", + "time", + "tools.mcp_tool", + "tools.mcp_tool", + "tools.mcp_tool", + "time", + "logging", + "logging", + "re", + "threading" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "mcp.types", + "names": [ + "CreateMessageResult", + "CreateMessageResultWithTools", + "ErrorData", + "SamplingCapability", + "SamplingToolsCapability", + "TextContent", + "ToolUseContent" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "SamplingHandler", + "_safe_numeric" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_convert_mcp_schema" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_convert_mcp_schema" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_convert_mcp_schema" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_convert_mcp_schema" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_convert_mcp_schema" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_check_fn", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_check_fn", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_check_fn", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_tool_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_tool_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_tool_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_tool_handler", + "_servers" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers", + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers", + "MCPServerTask" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers", + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "shutdown_mcp_servers", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "shutdown_mcp_servers", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "shutdown_mcp_servers", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "shutdown_mcp_servers", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_safe_env" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_safe_env" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_safe_env" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_safe_env" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_safe_env" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_sanitize_error" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_sanitize_error" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_sanitize_error" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_sanitize_error" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_sanitize_error" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_sanitize_error" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask", + "_DEFAULT_TOOL_TIMEOUT" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_tool_handler", + "_servers", + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_utility_schemas" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_utility_schemas" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_utility_schemas" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_utility_schemas" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_utility_schemas" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_utility_schemas" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_utility_schemas" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_list_resources_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_list_resources_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_list_resources_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_read_resource_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_read_resource_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_read_resource_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_list_prompts_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_list_prompts_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_list_prompts_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_get_prompt_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_get_prompt_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_get_prompt_handler", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_make_get_prompt_handler", + "_servers" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers", + "MCPServerTask" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers", + "MCPServerTask" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers", + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask", + "_MCP_SAMPLING_TYPES" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask", + "_MCP_SAMPLING_TYPES" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools", + "_servers", + "_ensure_mcp_loop" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools", + "_servers", + "_ensure_mcp_loop" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools", + "_servers", + "_ensure_mcp_loop" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_existing_tool_names", + "_servers", + "_discover_and_register_server" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers", + "MCPServerTask" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers", + "MCPServerTask" + ] + }, + { + "module": "tools.registry", + "names": [ + "ToolRegistry" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_discover_and_register_server", + "_servers", + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "sanitize_mcp_name_component" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "sanitize_mcp_name_component" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "sanitize_mcp_name_component" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "sanitize_mcp_name_component" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "sanitize_mcp_name_component" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "sanitize_mcp_name_component" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "sanitize_mcp_name_component" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_convert_mcp_schema" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_build_utility_schemas" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "sanitize_mcp_name_component" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "register_mcp_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "register_mcp_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "register_mcp_servers", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "register_mcp_servers", + "_servers" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "register_mcp_servers", + "_servers", + "_ensure_mcp_loop" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "register_mcp_servers", + "_servers", + "_ensure_mcp_loop" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_load_mcp_config" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_load_mcp_config" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_load_mcp_config" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "discover_mcp_tools" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "MCPServerTask" + ] + } + ] + }, + "tests/agent/test_models_dev.py": { + "imports": [ + "json", + "pytest", + "agent.models_dev", + "agent.models_dev", + "agent.models_dev", + "time" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "agent.models_dev", + "names": [ + "PROVIDER_TO_MODELS_DEV", + "_extract_context", + "fetch_models_dev", + "lookup_models_dev_context" + ] + } + ] + }, + "tests/agent/test_usage_pricing.py": { + "imports": [], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "agent.usage_pricing", + "names": [ + "CanonicalUsage", + "estimate_usage_cost", + "get_pricing_entry", + "normalize_usage" + ] + } + ] + }, + "tests/agent/test_smart_model_routing.py": { + "imports": [], + "from_imports": [ + { + "module": "agent.smart_model_routing", + "names": [ + "choose_cheap_model_route" + ] + }, + { + "module": "agent.smart_model_routing", + "names": [ + "resolve_turn_route" + ] + } + ] + }, + "tests/agent/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/agent/test_memory_plugin_e2e.py": { + "imports": [ + "json", + "os", + "sqlite3", + "tempfile", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + }, + { + "module": "agent.memory_manager", + "names": [ + "MemoryManager" + ] + }, + { + "module": "agent.builtin_memory_provider", + "names": [ + "BuiltinMemoryProvider" + ] + }, + { + "module": "agent.builtin_memory_provider", + "names": [ + "BuiltinMemoryProvider" + ] + } + ] + }, + "tests/agent/test_prompt_builder.py": { + "imports": [ + "builtins", + "importlib", + "logging", + "sys", + "pytest", + "json", + "json" + ], + "from_imports": [ + { + "module": "agent.prompt_builder", + "names": [ + "_scan_context_content", + "_truncate_content", + "_parse_skill_file", + "_read_skill_conditions", + "_skill_should_show", + "_find_hermes_md", + "_find_git_root", + "_strip_yaml_frontmatter", + "build_skills_system_prompt", + "build_nous_subscription_prompt", + "build_context_files_prompt", + "CONTEXT_FILE_MAX_CHARS", + "DEFAULT_AGENT_IDENTITY", + "TOOL_USE_ENFORCEMENT_GUIDANCE", + "TOOL_USE_ENFORCEMENT_MODELS", + "MEMORY_GUIDANCE", + "SESSION_SEARCH_GUIDANCE", + "PLATFORM_HINTS" + ] + }, + { + "module": "hermes_cli.nous_subscription", + "names": [ + "NousFeatureState", + "NousSubscriptionFeatures" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "clear_skills_system_prompt_cache" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "clear_skills_system_prompt_cache" + ] + }, + { + "module": "run_agent", + "names": [ + "_strip_budget_warnings_from_history" + ] + }, + { + "module": "run_agent", + "names": [ + "_strip_budget_warnings_from_history" + ] + }, + { + "module": "run_agent", + "names": [ + "_strip_budget_warnings_from_history" + ] + }, + { + "module": "run_agent", + "names": [ + "_strip_budget_warnings_from_history" + ] + }, + { + "module": "run_agent", + "names": [ + "_strip_budget_warnings_from_history" + ] + } + ] + }, + "tests/agent/test_subagent_progress.py": { + "imports": [ + "io", + "sys", + "time", + "threading", + "pytest", + "re" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "agent.display", + "names": [ + "KawaiiSpinner" + ] + }, + { + "module": "tools.delegate_tool", + "names": [ + "_build_child_progress_callback" + ] + } + ] + }, + "tests/agent/test_context_compressor.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "agent.context_compressor", + "names": [ + "ContextCompressor", + "SUMMARY_PREFIX" + ] + } + ] + }, + "tests/agent/test_auxiliary_client.py": { + "imports": [ + "json", + "os", + "pytest", + "base64", + "time", + "base64", + "time", + "base64", + "time", + "base64", + "time", + "base64", + "time", + "base64", + "base64" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "get_text_auxiliary_client", + "get_vision_auxiliary_client", + "get_available_vision_backends", + "resolve_vision_provider_client", + "resolve_provider_client", + "auxiliary_max_tokens_param", + "_read_codex_access_token", + "_get_auxiliary_provider", + "_resolve_forced_provider", + "_resolve_auto" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "CodexAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "CodexAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "CodexAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "CodexAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "CodexAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "CodexAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_try_anthropic", + "AnthropicAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_try_anthropic", + "AnthropicAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_try_anthropic" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_resolve_auto", + "AnthropicAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_resolve_auto" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_try_anthropic", + "AnthropicAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_try_anthropic", + "AnthropicAuxiliaryClient" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_try_codex" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_try_nous" + ] + }, + { + "module": "agent.auxiliary_client", + "names": [ + "_resolve_auto" + ] + } + ] + }, + "tests/agent/test_external_skills.py": { + "imports": [ + "json", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_external_skills_dirs" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_all_skills_dirs" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_find_all_skills" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_find_all_skills" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "skill_view" + ] + } + ] + }, + "tests/agent/test_prompt_caching.py": { + "imports": [ + "copy", + "pytest" + ], + "from_imports": [ + { + "module": "agent.prompt_caching", + "names": [ + "_apply_cache_marker", + "apply_anthropic_cache_control" + ] + } + ] + }, + "tests/agent/test_skill_commands.py": { + "imports": [ + "os", + "tools.skills_tool" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "build_plan_path", + "build_preloaded_skills_prompt", + "build_skill_invocation_message", + "scan_skill_commands" + ] + } + ] + }, + "tests/agent/test_memory_provider.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + }, + { + "module": "agent.memory_manager", + "names": [ + "MemoryManager" + ] + }, + { + "module": "agent.builtin_memory_provider", + "names": [ + "BuiltinMemoryProvider" + ] + }, + { + "module": "plugins.memory", + "names": [ + "discover_memory_providers" + ] + }, + { + "module": "plugins.memory", + "names": [ + "load_memory_provider" + ] + }, + { + "module": "plugins.memory", + "names": [ + "load_memory_provider" + ] + } + ] + }, + "tests/agent/test_display_emoji.py": { + "imports": [ + "sys", + "sys", + "sys", + "sys", + "sys" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "agent.display", + "names": [ + "get_tool_emoji" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "SkinConfig" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "SkinConfig" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "_build_skin_config" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "_build_skin_config" + ] + } + ] + }, + "tests/agent/test_model_metadata.py": { + "imports": [ + "os", + "time", + "tempfile", + "pytest", + "yaml", + "agent.model_metadata", + "agent.model_metadata", + "agent.model_metadata" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "CONTEXT_PROBE_TIERS", + "DEFAULT_CONTEXT_LENGTHS", + "_strip_provider_prefix", + "estimate_tokens_rough", + "estimate_messages_tokens_rough", + "get_model_context_length", + "get_next_probe_tier", + "get_cached_context_length", + "parse_context_limit_from_error", + "save_context_length", + "fetch_model_metadata", + "_MODEL_CACHE_TTL" + ] + } + ] + }, + "tests/agent/test_redact.py": { + "imports": [ + "logging", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text", + "RedactingFormatter" + ] + } + ] + }, + "tests/agent/test_title_generator.py": { + "imports": [ + "threading", + "pytest", + "time", + "time" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "agent.title_generator", + "names": [ + "generate_title", + "auto_title_session", + "maybe_auto_title" + ] + } + ] + }, + "tests/hermes_cli/test_skills_subparser.py": { + "imports": [ + "argparse", + "importlib", + "sys", + "hermes_cli.main" + ], + "from_imports": [] + }, + "tests/hermes_cli/test_path_completion.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "prompt_toolkit.document", + "names": [ + "Document" + ] + }, + { + "module": "prompt_toolkit.formatted_text", + "names": [ + "to_plain_text" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "SlashCommandCompleter", + "_file_size_label" + ] + } + ] + }, + "tests/hermes_cli/test_nous_subscription.py": { + "imports": [], + "from_imports": [ + { + "module": "hermes_cli", + "names": [ + "nous_subscription" + ] + } + ] + }, + "tests/hermes_cli/test_mcp_config.py": { + "imports": [ + "argparse", + "json", + "os", + "types", + "pytest", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "PropertyMock" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_list" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_list" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_list" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_remove" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_remove" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_remove" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_add" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_add" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_add" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_add" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_test" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "cmd_mcp_test" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_interpolate_env_vars" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_interpolate_env_vars" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_interpolate_env_vars" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_interpolate_env_vars" + ] + }, + { + "module": "tools.mcp_tool", + "names": [ + "_interpolate_env_vars" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "_save_mcp_server", + "_get_mcp_servers" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "_save_mcp_server", + "_remove_mcp_server", + "_get_mcp_servers" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "_remove_mcp_server" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "_env_key_for_server" + ] + }, + { + "module": "hermes_cli.mcp_config", + "names": [ + "mcp_command" + ] + } + ] + }, + "tests/hermes_cli/test_skin_engine.py": { + "imports": [ + "json", + "os", + "pytest", + "yaml", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli", + "names": [ + "skin_engine" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "_BUILTIN_SKINS", + "_build_skin_config" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "set_active_skin", + "get_active_skin", + "get_active_skin_name" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_skin" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "list_skins" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "init_skin_from_config", + "get_active_skin_name" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "init_skin_from_config", + "get_active_skin_name" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "load_skin", + "_skins_dir" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "list_skins" + ] + }, + { + "module": "agent.display", + "names": [ + "get_skin_tool_prefix" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "set_active_skin" + ] + }, + { + "module": "agent.display", + "names": [ + "get_skin_tool_prefix" + ] + }, + { + "module": "agent.display", + "names": [ + "get_skin_faces", + "KawaiiSpinner" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "set_active_skin" + ] + }, + { + "module": "agent.display", + "names": [ + "get_skin_faces", + "KawaiiSpinner" + ] + }, + { + "module": "agent.display", + "names": [ + "get_skin_verbs", + "KawaiiSpinner" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "set_active_skin" + ] + }, + { + "module": "agent.display", + "names": [ + "get_skin_verbs" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "set_active_skin" + ] + }, + { + "module": "agent.display", + "names": [ + "get_cute_tool_message" + ] + }, + { + "module": "agent.display", + "names": [ + "get_cute_tool_message" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "get_active_prompt_symbol" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "set_active_skin", + "get_active_prompt_symbol" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "set_active_skin", + "get_active_help_header" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "set_active_skin", + "get_active_goodbye" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "set_active_skin", + "get_prompt_toolkit_style_overrides" + ] + }, + { + "module": "hermes_cli.skin_engine", + "names": [ + "set_active_skin", + "get_active_skin", + "get_prompt_toolkit_style_overrides" + ] + } + ] + }, + "tests/hermes_cli/test_update_autostash.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "subprocess", + "names": [ + "CalledProcessError" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "hermes_cli", + "names": [ + "config" + ] + }, + { + "module": "hermes_cli", + "names": [ + "main" + ] + } + ] + }, + "tests/hermes_cli/test_chat_skills_flag.py": { + "imports": [ + "sys", + "hermes_cli.main", + "hermes_cli.main", + "hermes_cli.main" + ], + "from_imports": [] + }, + "tests/hermes_cli/test_setup.py": { + "imports": [ + "json", + "sys", + "types" + ], + "from_imports": [ + { + "module": "hermes_cli.auth", + "names": [ + "get_active_provider" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "setup_model_provider" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "setup_terminal_backend" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "setup_terminal_backend" + ] + } + ] + }, + "tests/hermes_cli/test_gateway_linger.py": { + "imports": [ + "hermes_cli.gateway" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + } + ] + }, + "tests/hermes_cli/test_commands.py": { + "imports": [], + "from_imports": [ + { + "module": "prompt_toolkit.completion", + "names": [ + "CompleteEvent" + ] + }, + { + "module": "prompt_toolkit.document", + "names": [ + "Document" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "COMMAND_REGISTRY", + "COMMANDS", + "COMMANDS_BY_CATEGORY", + "CommandDef", + "GATEWAY_KNOWN_COMMANDS", + "SUBCOMMANDS", + "SlashCommandAutoSuggest", + "SlashCommandCompleter", + "_TG_NAME_LIMIT", + "_clamp_telegram_names", + "gateway_help_lines", + "resolve_command", + "slack_subcommand_map", + "telegram_bot_commands", + "telegram_menu_commands" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + } + ] + }, + "tests/hermes_cli/test_gateway_service.py": { + "imports": [ + "os", + "hermes_cli.gateway", + "pwd", + "grp", + "pytest", + "pwd", + "grp", + "pwd", + "grp" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + } + ] + }, + "tests/hermes_cli/test_subprocess_timeouts.py": { + "imports": [ + "ast", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/hermes_cli/test_webhook_cli.py": { + "imports": [ + "json", + "os", + "pytest", + "hermes_cli.webhook", + "hermes_cli.webhook" + ], + "from_imports": [ + { + "module": "argparse", + "names": [ + "Namespace" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.webhook", + "names": [ + "webhook_command", + "_load_subscriptions", + "_save_subscriptions", + "_subscriptions_path", + "_is_webhook_enabled" + ] + } + ] + }, + "tests/hermes_cli/test_status.py": { + "imports": [], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "hermes_cli.status", + "names": [ + "show_status" + ] + } + ] + }, + "tests/hermes_cli/test_tool_token_estimation.py": { + "imports": [ + "pytest", + "tiktoken", + "hermes_cli.tools_config", + "hermes_cli.tools_config", + "hermes_cli.tools_config", + "builtins", + "hermes_cli.tools_config", + "hermes_cli.tools_config", + "hermes_cli.tools_config", + "hermes_cli.tools_config", + "re", + "hermes_cli.tools_config", + "model_tools" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "_estimate_tool_tokens", + "_tool_token_cache" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "CONFIGURABLE_TOOLSETS" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "CONFIGURABLE_TOOLSETS" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "CONFIGURABLE_TOOLSETS" + ] + }, + { + "module": "toolsets", + "names": [ + "resolve_toolset" + ] + }, + { + "module": "hermes_cli.curses_ui", + "names": [ + "_numbered_fallback" + ] + }, + { + "module": "hermes_cli.curses_ui", + "names": [ + "_numbered_fallback" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + }, + { + "module": "tools.registry", + "names": [ + "registry" + ] + } + ] + }, + "tests/hermes_cli/test_sessions_delete.py": { + "imports": [ + "sys", + "hermes_cli.main", + "hermes_state", + "hermes_cli.main", + "hermes_state", + "hermes_cli.main", + "hermes_state", + "hermes_cli.main", + "hermes_state" + ], + "from_imports": [] + }, + "tests/hermes_cli/test_profile_export_credentials.py": { + "imports": [ + "tarfile" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "export_profile", + "_DEFAULT_EXPORT_EXCLUDE_ROOT" + ] + } + ] + }, + "tests/hermes_cli/test_cron.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "argparse", + "names": [ + "Namespace" + ] + }, + { + "module": "cron.jobs", + "names": [ + "create_job", + "get_job", + "list_jobs" + ] + }, + { + "module": "hermes_cli.cron", + "names": [ + "cron_command" + ] + } + ] + }, + "tests/hermes_cli/test_gateway_runtime_health.py": { + "imports": [], + "from_imports": [ + { + "module": "hermes_cli.gateway", + "names": [ + "_runtime_health_lines" + ] + } + ] + }, + "tests/hermes_cli/test_doctor.py": { + "imports": [ + "os", + "sys", + "types", + "pytest", + "hermes_cli.doctor", + "hermes_cli.gateway" + ], + "from_imports": [ + { + "module": "argparse", + "names": [ + "Namespace" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "hermes_cli", + "names": [ + "doctor" + ] + }, + { + "module": "hermes_cli.doctor", + "names": [ + "_has_provider_env_config" + ] + } + ] + }, + "tests/hermes_cli/test_skills_config.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "get_disabled_skills" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "get_disabled_skills" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "get_disabled_skills" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "get_disabled_skills" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "get_disabled_skills" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "get_disabled_skills" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "save_disabled_skills" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "save_disabled_skills" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "save_disabled_skills" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "save_disabled_skills" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_is_skill_disabled" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_is_skill_disabled" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_is_skill_disabled" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_is_skill_disabled" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_is_skill_disabled" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_is_skill_disabled" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_is_skill_disabled" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_is_skill_disabled" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_disabled_skill_names" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_disabled_skill_names" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_disabled_skill_names" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_disabled_skill_names" + ] + }, + { + "module": "agent.skill_utils", + "names": [ + "get_disabled_skill_names" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_find_all_skills" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_find_all_skills" + ] + }, + { + "module": "tools.skills_tool", + "names": [ + "_find_all_skills" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "_get_categories" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "_get_categories" + ] + } + ] + }, + "tests/hermes_cli/test_mcp_tools_config.py": { + "imports": [], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "_configure_mcp_tools_interactive" + ] + } + ] + }, + "tests/hermes_cli/test_model_validation.py": { + "imports": [], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_model_api_mode", + "fetch_github_model_catalog", + "curated_models_for_provider", + "fetch_api_models", + "github_model_reasoning_efforts", + "normalize_copilot_model_id", + "normalize_opencode_model_id", + "normalize_provider", + "opencode_model_api_mode", + "parse_model_input", + "probe_api_models", + "provider_label", + "provider_model_ids", + "validate_requested_model" + ] + } + ] + }, + "tests/hermes_cli/test_copilot_auth.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "validate_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "validate_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "validate_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "validate_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "validate_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "is_classic_pat" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "resolve_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "resolve_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "resolve_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "resolve_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "resolve_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "resolve_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "resolve_copilot_token" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "copilot_request_headers" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "copilot_request_headers" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "copilot_request_headers" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "copilot_request_headers" + ] + }, + { + "module": "hermes_cli.copilot_auth", + "names": [ + "copilot_request_headers" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_default_headers" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "copilot_default_headers" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_should_use_copilot_responses_api" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_should_use_copilot_responses_api" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_should_use_copilot_responses_api" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_should_use_copilot_responses_api" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY" + ] + }, + { + "module": "hermes_cli.auth", + "names": [ + "PROVIDER_REGISTRY" + ] + } + ] + }, + "tests/hermes_cli/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/hermes_cli/test_tools_config.py": { + "imports": [], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "_configure_provider", + "_get_platform_tools", + "_platform_toolset_summary", + "_save_platform_tools", + "_toolset_has_keys", + "TOOL_CATEGORIES", + "_visible_providers", + "tools_command" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "PLATFORMS" + ] + }, + { + "module": "toolsets", + "names": [ + "TOOLSETS" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "PLATFORMS" + ] + }, + { + "module": "toolsets", + "names": [ + "TOOLSETS" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "PLATFORMS" + ] + }, + { + "module": "hermes_cli.skills_config", + "names": [ + "PLATFORMS" + ] + } + ] + }, + "tests/hermes_cli/test_update_check.py": { + "imports": [ + "json", + "threading", + "time", + "pytest", + "hermes_cli.banner", + "hermes_cli.banner", + "tempfile", + "hermes_cli.banner", + "hermes_cli.banner" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_cli", + "names": [ + "__version__" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "check_for_updates" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "check_for_updates" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_invalidate_update_cache" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_invalidate_update_cache" + ] + } + ] + }, + "tests/hermes_cli/test_banner_skills.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "get_available_skills" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "get_available_skills" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "get_available_skills" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "get_available_skills" + ] + }, + { + "module": "hermes_cli.banner", + "names": [ + "get_available_skills" + ] + } + ] + }, + "tests/hermes_cli/test_config.py": { + "imports": [ + "os", + "yaml", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG", + "get_hermes_home", + "ensure_hermes_home", + "load_config", + "load_env", + "migrate_config", + "save_config", + "save_env_value", + "save_env_value_secure", + "sanitize_env_file", + "_sanitize_env_lines" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "OPTIONAL_ENV_VARS" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "OPTIONAL_ENV_VARS" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "OPTIONAL_ENV_VARS" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "OPTIONAL_ENV_VARS" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "ENV_VARS_BY_VERSION" + ] + } + ] + }, + "tests/hermes_cli/test_banner.py": { + "imports": [ + "hermes_cli.banner", + "model_tools", + "tools.mcp_tool" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + } + ] + }, + "tests/hermes_cli/test_tools_disable_enable.py": { + "imports": [], + "from_imports": [ + { + "module": "argparse", + "names": [ + "Namespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "tools_disable_enable_command" + ] + } + ] + }, + "tests/hermes_cli/test_setup_prompt_menus.py": { + "imports": [], + "from_imports": [ + { + "module": "hermes_cli", + "names": [ + "setup" + ] + } + ] + }, + "tests/hermes_cli/test_coalesce_session_args.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "hermes_cli.main", + "names": [ + "_coalesce_session_name_args" + ] + } + ] + }, + "tests/hermes_cli/test_session_browse.py": { + "imports": [ + "os", + "time", + "pytest", + "builtins", + "builtins", + "builtins", + "builtins", + "builtins", + "builtins", + "builtins", + "builtins", + "builtins", + "curses", + "curses", + "curses", + "curses", + "curses", + "curses", + "curses", + "argparse", + "builtins", + "builtins", + "builtins", + "builtins", + "builtins" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "call" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_session_browse_picker" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "main" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "_session_browse_picker" + ] + } + ] + }, + "tests/hermes_cli/test_env_loader.py": { + "imports": [ + "importlib", + "os", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_cli.env_loader", + "names": [ + "load_hermes_dotenv" + ] + } + ] + }, + "tests/hermes_cli/test_cmd_update.py": { + "imports": [ + "subprocess", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "cmd_update", + "PROJECT_ROOT" + ] + } + ] + }, + "tests/hermes_cli/test_skills_install_flags.py": { + "imports": [ + "sys" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "main" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "main" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "main" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "main" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "main" + ] + } + ] + }, + "tests/hermes_cli/test_placeholder_usage.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "argparse", + "names": [ + "Namespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "config_command", + "show_config" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "_print_setup_summary" + ] + } + ] + }, + "tests/hermes_cli/test_setup_model_provider.py": { + "imports": [ + "hermes_cli.main", + "hermes_cli.setup", + "agent.credential_pool", + "agent.auxiliary_client" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config", + "save_config", + "save_env_value" + ] + }, + { + "module": "hermes_cli.nous_subscription", + "names": [ + "NousFeatureState", + "NousSubscriptionFeatures" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "_print_setup_summary", + "setup_model_provider" + ] + } + ] + }, + "tests/hermes_cli/test_status_model_provider.py": { + "imports": [ + "hermes_cli.auth" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "hermes_cli.nous_subscription", + "names": [ + "NousFeatureState", + "NousSubscriptionFeatures" + ] + }, + { + "module": "hermes_cli", + "names": [ + "status" + ] + }, + { + "module": "hermes_cli", + "names": [ + "status" + ] + }, + { + "module": "hermes_cli", + "names": [ + "status" + ] + }, + { + "module": "hermes_cli", + "names": [ + "status" + ] + } + ] + }, + "tests/hermes_cli/test_skills_skip_confirm.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "handle_skills_slash" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "do_install" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "do_uninstall" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "do_uninstall" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "do_uninstall" + ] + } + ] + }, + "tests/hermes_cli/test_models.py": { + "imports": [], + "from_imports": [ + { + "module": "hermes_cli.models", + "names": [ + "OPENROUTER_MODELS", + "menu_labels", + "model_ids", + "detect_provider_for_model" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_find_openrouter_slug" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_find_openrouter_slug" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_find_openrouter_slug" + ] + }, + { + "module": "hermes_cli.models", + "names": [ + "_find_openrouter_slug" + ] + } + ] + }, + "tests/hermes_cli/test_managed_installs.py": { + "imports": [], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "format_managed_message", + "get_managed_system", + "recommended_update_command" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "cmd_update" + ] + }, + { + "module": "tools.skills_hub", + "names": [ + "OptionalSkillSource" + ] + } + ] + }, + "tests/hermes_cli/test_update_gateway_restart.py": { + "imports": [ + "subprocess", + "pytest", + "hermes_cli.gateway" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "cmd_update" + ] + } + ] + }, + "tests/hermes_cli/test_launcher.py": { + "imports": [ + "runpy", + "sys", + "types" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/hermes_cli/test_setup_openclaw_migration.py": { + "imports": [], + "from_imports": [ + { + "module": "argparse", + "names": [ + "Namespace" + ] + }, + { + "module": "types", + "names": [ + "ModuleType" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_cli", + "names": [ + "setup" + ] + } + ] + }, + "tests/hermes_cli/test_skills_hub.py": { + "imports": [ + "pytest", + "tools.skills_hub", + "tools.skills_hub", + "tools.skills_sync", + "tools.skills_tool", + "tools.skills_hub", + "tools.skills_hub", + "hermes_cli.skills_hub", + "tools.skills_sync", + "tools.skills_tool", + "tools.skills_guard", + "tools.skills_hub" + ], + "from_imports": [ + { + "module": "io", + "names": [ + "StringIO" + ] + }, + { + "module": "rich.console", + "names": [ + "Console" + ] + }, + { + "module": "hermes_cli.skills_hub", + "names": [ + "do_check", + "do_install", + "do_list", + "do_update", + "handle_skills_slash" + ] + } + ] + }, + "tests/hermes_cli/test_profiles.py": { + "imports": [ + "json", + "io", + "os", + "tarfile", + "pytest", + "shutil" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "validate_profile_name", + "get_profile_dir", + "create_profile", + "delete_profile", + "list_profiles", + "set_active_profile", + "get_active_profile", + "get_active_profile_name", + "resolve_profile_env", + "check_alias_collision", + "rename_profile", + "export_profile", + "import_profile", + "generate_bash_completion", + "generate_zsh_completion", + "_get_profiles_root", + "_get_default_hermes_home" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "_check_gateway_running" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "_check_gateway_running" + ] + } + ] + }, + "tests/hermes_cli/test_gateway.py": { + "imports": [ + "signal", + "hermes_cli.gateway", + "time", + "time" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "call" + ] + } + ] + }, + "tests/hermes_cli/test_set_config_value.py": { + "imports": [ + "argparse", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "call" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "set_config_value", + "config_command" + ] + } + ] + }, + "tests/hermes_cli/test_claw.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "argparse", + "names": [ + "Namespace" + ] + }, + { + "module": "types", + "names": [ + "ModuleType" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_cli", + "names": [ + "claw" + ] + } + ] + }, + "tests/hermes_cli/test_setup_noninteractive.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "argparse", + "names": [ + "Namespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "run_setup_wizard" + ] + }, + { + "module": "hermes_cli.setup", + "names": [ + "run_setup_wizard" + ] + }, + { + "module": "hermes_cli.main", + "names": [ + "cmd_chat" + ] + }, + { + "module": "hermes_cli", + "names": [ + "setup" + ] + } + ] + }, + "tests/fakes/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/fakes/fake_ha_server.py": { + "imports": [ + "asyncio", + "json", + "aiohttp" + ], + "from_imports": [ + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp.test_utils", + "names": [ + "TestServer" + ] + } + ] + }, + "tests/cron/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/cron/test_jobs.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timedelta", + "timezone" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "cron.jobs", + "names": [ + "parse_duration", + "parse_schedule", + "compute_next_run", + "create_job", + "load_jobs", + "save_jobs", + "get_job", + "list_jobs", + "update_job", + "pause_job", + "resume_job", + "remove_job", + "mark_job_run", + "advance_next_run", + "get_due_jobs", + "save_job_output" + ] + }, + { + "module": "cron.jobs", + "names": [ + "_ensure_aware", + "_hermes_now" + ] + }, + { + "module": "cron.jobs", + "names": [ + "_ensure_aware", + "_hermes_now" + ] + }, + { + "module": "cron.jobs", + "names": [ + "_ensure_aware", + "_hermes_now" + ] + }, + { + "module": "cron.jobs", + "names": [ + "_ensure_aware", + "_hermes_now" + ] + } + ] + }, + "tests/cron/test_scheduler.py": { + "imports": [ + "json", + "logging", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "patch", + "MagicMock" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "_resolve_origin", + "_resolve_delivery_target", + "_deliver_result", + "run_job", + "SILENT_MARKER", + "_build_job_prompt" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "tick" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "tick" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "tick" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "tick" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "tick" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "tick" + ] + }, + { + "module": "cron.scheduler", + "names": [ + "tick" + ] + } + ] + }, + "tests/gateway/test_discord_media_metadata.py": { + "imports": [ + "inspect" + ], + "from_imports": [ + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + } + ] + }, + "tests/gateway/test_webhook_adapter.py": { + "imports": [ + "asyncio", + "hashlib", + "hmac", + "json", + "time", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp.test_utils", + "names": [ + "TestClient", + "TestServer" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType", + "SendResult" + ] + }, + { + "module": "gateway.platforms.webhook", + "names": [ + "WebhookAdapter", + "_INSECURE_NO_AUTH", + "check_webhook_requirements" + ] + } + ] + }, + "tests/gateway/test_discord_free_response.py": { + "imports": [ + "sys", + "pytest", + "gateway.platforms.discord" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + } + ] + }, + "tests/gateway/test_discord_system_messages.py": { + "imports": [ + "pytest", + "unittest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + } + ] + }, + "tests/gateway/test_update_command.py": { + "imports": [ + "json", + "os", + "pytest", + "sys", + "inspect" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock", + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "_resolve_hermes_bin" + ] + }, + { + "module": "gateway.run", + "names": [ + "_resolve_hermes_bin" + ] + }, + { + "module": "gateway.run", + "names": [ + "_resolve_hermes_bin" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_whatsapp_reply_prefix.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "WhatsAppAdapter" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "WhatsAppAdapter" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "WhatsAppAdapter" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "DEFAULT_CONFIG", + "ENV_VARS_BY_VERSION" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + } + ] + }, + "tests/gateway/test_telegram_reply_mode.py": { + "imports": [ + "os", + "sys", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "AsyncMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig", + "GatewayConfig", + "Platform", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + } + ] + }, + "tests/gateway/test_discord_reactions.py": { + "imports": [ + "asyncio", + "sys", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType", + "SendResult" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "build_session_key" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + } + ] + }, + "tests/gateway/test_telegram_text_batching.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType", + "SessionSource" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + } + ] + }, + "tests/gateway/test_retry_replacement.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionStore" + ] + } + ] + }, + "tests/gateway/test_hooks.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "gateway.hooks", + "names": [ + "HookRegistry" + ] + } + ] + }, + "tests/gateway/test_wecom.py": { + "imports": [ + "base64", + "os", + "pytest", + "gateway.platforms.wecom", + "gateway.platforms.wecom", + "gateway.platforms.wecom" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "SendResult" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "check_wecom_requirements" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "check_wecom_requirements" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "check_wecom_requirements" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "ABSOLUTE_MAX_BYTES", + "WeComAdapter" + ] + }, + { + "module": "cryptography.hazmat.primitives.ciphers", + "names": [ + "Cipher", + "algorithms", + "modes" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "APP_CMD_UPLOAD_MEDIA_CHUNK", + "APP_CMD_UPLOAD_MEDIA_FINISH", + "APP_CMD_UPLOAD_MEDIA_INIT", + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "cryptography.hazmat.primitives.ciphers", + "names": [ + "Cipher", + "algorithms", + "modes" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "APP_CMD_SEND", + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + }, + { + "module": "gateway.platforms.wecom", + "names": [ + "WeComAdapter" + ] + } + ] + }, + "tests/gateway/test_config_cwd_bridge.py": { + "imports": [ + "os", + "json", + "pytest" + ], + "from_imports": [] + }, + "tests/gateway/test_platform_reconnect.py": { + "imports": [ + "asyncio", + "time", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "SendResult" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_slack.py": { + "imports": [ + "asyncio", + "os", + "sys", + "pytest", + "gateway.platforms.slack" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType", + "SendResult", + "SUPPORTED_DOCUMENT_TYPES" + ] + }, + { + "module": "gateway.platforms.slack", + "names": [ + "SlackAdapter" + ] + } + ] + }, + "tests/gateway/test_pii_redaction.py": { + "imports": [], + "from_imports": [ + { + "module": "gateway.session", + "names": [ + "SessionContext", + "SessionSource", + "build_session_context_prompt", + "_hash_id", + "_hash_sender_id", + "_hash_chat_id", + "_looks_like_phone" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "HomeChannel" + ] + } + ] + }, + "tests/gateway/test_discord_document_handling.py": { + "imports": [ + "os", + "sys", + "pytest", + "gateway.platforms.discord" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + } + ] + }, + "tests/gateway/test_pairing.py": { + "imports": [ + "json", + "os", + "time" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "gateway.pairing", + "names": [ + "PairingStore", + "ALPHABET", + "CODE_LENGTH", + "CODE_TTL_SECONDS", + "RATE_LIMIT_SECONDS", + "MAX_PENDING_PER_PLATFORM", + "MAX_FAILED_ATTEMPTS", + "LOCKOUT_SECONDS", + "_secure_write" + ] + } + ] + }, + "tests/gateway/test_resume_command.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "build_session_key" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + } + ] + }, + "tests/gateway/test_runner_fatal_adapter.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_matrix.py": { + "imports": [ + "asyncio", + "json", + "re", + "pytest", + "time", + "time", + "time", + "time", + "nio" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.matrix", + "names": [ + "MatrixAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.platforms.matrix", + "names": [ + "check_matrix_requirements" + ] + }, + { + "module": "gateway.platforms.matrix", + "names": [ + "check_matrix_requirements" + ] + }, + { + "module": "gateway.platforms.matrix", + "names": [ + "check_matrix_requirements" + ] + }, + { + "module": "gateway.platforms.matrix", + "names": [ + "MatrixAdapter" + ] + }, + { + "module": "gateway.platforms.matrix", + "names": [ + "_MAX_PENDING_EVENTS" + ] + }, + { + "module": "gateway.platforms.matrix", + "names": [ + "_PENDING_EVENT_TTL" + ] + }, + { + "module": "gateway.platforms.matrix", + "names": [ + "_KEY_EXPORT_FILE", + "_KEY_EXPORT_PASSPHRASE" + ] + } + ] + }, + "tests/gateway/test_dingtalk.py": { + "imports": [ + "asyncio", + "json", + "pytest" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch", + "PropertyMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "check_dingtalk_requirements" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "check_dingtalk_requirements" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter", + "DEDUP_MAX_SIZE" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "DingTalkAdapter" + ] + }, + { + "module": "gateway.platforms.dingtalk", + "names": [ + "check_dingtalk_requirements" + ] + } + ] + }, + "tests/gateway/test_base_topic_sessions.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "SendResult" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "build_session_key" + ] + } + ] + }, + "tests/gateway/test_session_info.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_status.py": { + "imports": [ + "json", + "os" + ], + "from_imports": [ + { + "module": "gateway", + "names": [ + "status" + ] + } + ] + }, + "tests/gateway/test_sse_agent_cancel.py": { + "imports": [ + "asyncio", + "json", + "queue", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.platforms.api_server", + "names": [ + "APIServerAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + } + ] + }, + "tests/gateway/test_mirror.py": { + "imports": [ + "json", + "gateway.mirror" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "gateway.mirror", + "names": [ + "mirror_to_session", + "_find_session_id", + "_append_to_jsonl" + ] + }, + { + "module": "gateway.mirror", + "names": [ + "_append_to_sqlite" + ] + }, + { + "module": "gateway.mirror", + "names": [ + "_append_to_sqlite" + ] + } + ] + }, + "tests/gateway/test_mattermost.py": { + "imports": [ + "json", + "os", + "time", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.mattermost", + "names": [ + "MattermostAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.platforms.mattermost", + "names": [ + "check_mattermost_requirements" + ] + }, + { + "module": "gateway.platforms.mattermost", + "names": [ + "check_mattermost_requirements" + ] + }, + { + "module": "gateway.platforms.mattermost", + "names": [ + "check_mattermost_requirements" + ] + } + ] + }, + "tests/gateway/test_send_retry.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "patch" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "SendResult", + "_RETRYABLE_ERROR_PATTERNS" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "Platform", + "PlatformConfig" + ] + } + ] + }, + "tests/gateway/test_sms.py": { + "imports": [ + "os", + "pytest", + "aiohttp" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig", + "HomeChannel" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "gateway.platforms.sms", + "names": [ + "SmsAdapter" + ] + }, + { + "module": "gateway.platforms.sms", + "names": [ + "SmsAdapter" + ] + }, + { + "module": "gateway.platforms.sms", + "names": [ + "check_sms_requirements" + ] + }, + { + "module": "gateway.platforms.sms", + "names": [ + "check_sms_requirements" + ] + }, + { + "module": "gateway.platforms.sms", + "names": [ + "check_sms_requirements" + ] + }, + { + "module": "toolsets", + "names": [ + "get_toolset" + ] + }, + { + "module": "toolsets", + "names": [ + "get_toolset" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "PLATFORM_HINTS" + ] + }, + { + "module": "tools.cronjob_tools", + "names": [ + "CRONJOB_SCHEMA" + ] + } + ] + }, + "tests/gateway/test_feishu.py": { + "imports": [ + "asyncio", + "json", + "os", + "tempfile", + "time", + "unittest", + "lark_oapi", + "hashlib" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "_apply_env_overrides" + ] + }, + { + "module": "toolsets", + "names": [ + "TOOLSETS" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "parse_feishu_post_content" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FALLBACK_POST_TEXT", + "parse_feishu_post_content" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "parse_feishu_post_content" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "normalize_feishu_message" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "normalize_feishu_message" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "normalize_feishu_message" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "_FEISHU_WEBHOOK_RATE_LIMIT_MAX" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "_FEISHU_WEBHOOK_RATE_LIMIT_MAX", + "_FEISHU_WEBHOOK_RATE_WINDOW_SECONDS" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter", + "_FEISHU_WEBHOOK_MAX_BODY_BYTES" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter", + "_FEISHU_DEDUP_TTL_SECONDS" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.feishu", + "names": [ + "FeishuAdapter" + ] + } + ] + }, + "tests/gateway/test_session_dm_thread_seeding.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "GatewayConfig" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "SessionStore", + "build_session_key" + ] + } + ] + }, + "tests/gateway/test_sticker_cache.py": { + "imports": [ + "json", + "time" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "gateway.sticker_cache", + "names": [ + "_load_cache", + "_save_cache", + "get_cached_description", + "cache_sticker_description", + "build_sticker_injection", + "build_animated_sticker_injection", + "STICKER_VISION_PROMPT" + ] + } + ] + }, + "tests/gateway/test_session_hygiene.py": { + "imports": [ + "importlib", + "sys", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock", + "AsyncMock" + ] + }, + { + "module": "agent.model_metadata", + "names": [ + "estimate_messages_tokens_rough" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "SendResult" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry", + "SessionSource" + ] + } + ] + }, + "tests/gateway/test_unauthorized_dm_behavior.py": { + "imports": [ + "pytest", + "gateway.run" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_discord_send.py": { + "imports": [ + "sys", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + } + ] + }, + "tests/gateway/test_platform_base.py": { + "imports": [ + "os" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "GATEWAY_SECRET_CAPTURE_UNSUPPORTED_MESSAGE", + "MessageEvent", + "MessageType" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + } + ] + }, + "tests/gateway/test_interrupt_key_match.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "SendResult" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "build_session_key" + ] + } + ] + }, + "tests/gateway/__init__.py": { + "imports": [], + "from_imports": [] + }, + "tests/gateway/test_session_race_guard.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner", + "_AGENT_PENDING_SENTINEL" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "build_session_key" + ] + } + ] + }, + "tests/gateway/test_gateway_shutdown.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "SendResult" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "build_session_key" + ] + } + ] + }, + "tests/gateway/test_queue_consumption.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "MessageEvent", + "MessageType", + "PlatformConfig", + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "SendResult" + ] + } + ] + }, + "tests/gateway/test_stt_config.py": { + "imports": [ + "pytest", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "load_gateway_config" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_telegram_network_reconnect.py": { + "imports": [ + "asyncio", + "sys", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + } + ] + }, + "tests/gateway/test_session.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "HomeChannel", + "GatewayConfig", + "PlatformConfig" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "SessionStore", + "build_session_context", + "build_session_context_prompt", + "build_session_key" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + } + ] + }, + "tests/gateway/test_title_command.py": { + "imports": [ + "os", + "pytest", + "inspect" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "hermes_state", + "names": [ + "SessionDB" + ] + }, + { + "module": "gateway.hooks", + "names": [ + "HookRegistry" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_ssl_certs.py": { + "imports": [ + "importlib", + "os", + "textwrap", + "ssl" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "types", + "names": [ + "ModuleType" + ] + } + ] + }, + "tests/gateway/test_document_cache.py": { + "imports": [ + "os", + "time", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "SUPPORTED_DOCUMENT_TYPES", + "cache_document_from_bytes", + "cleanup_document_cache", + "get_document_cache_dir" + ] + } + ] + }, + "tests/gateway/test_telegram_group_gating.py": { + "imports": [ + "json" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig", + "load_gateway_config" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + } + ] + }, + "tests/gateway/test_discord_thread_persistence.py": { + "imports": [ + "json", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + } + ] + }, + "tests/gateway/test_telegram_thread_fallback.py": { + "imports": [ + "sys", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig", + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "SendResult" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + } + ] + }, + "tests/gateway/test_telegram_conflict.py": { + "imports": [ + "asyncio", + "sys", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + } + ] + }, + "tests/gateway/test_email.py": { + "imports": [ + "os", + "unittest", + "gateway.run", + "inspect", + "gateway.run", + "inspect", + "gateway.run", + "inspect", + "tools.send_message_tool", + "inspect", + "tools.send_message_tool", + "inspect", + "cron.scheduler", + "inspect", + "gateway.channel_directory", + "inspect", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "tempfile", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "asyncio", + "ssl", + "asyncio", + "asyncio" + ], + "from_imports": [ + { + "module": "email.mime.text", + "names": [ + "MIMEText" + ] + }, + { + "module": "email.mime.multipart", + "names": [ + "MIMEMultipart" + ] + }, + { + "module": "email.mime.base", + "names": [ + "MIMEBase" + ] + }, + { + "module": "email", + "names": [ + "encoders" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock", + "AsyncMock" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "SendResult" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "check_email_requirements" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "check_email_requirements" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "check_email_requirements" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_decode_header_value" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_decode_header_value" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_email_address" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_email_address" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_email_address" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_strip_html" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_strip_html" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_strip_html" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_text_body" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_text_body" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_text_body" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_text_body" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_text_body" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_attachments" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_attachments" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "_extract_attachments" + ] + }, + { + "module": "toolsets", + "names": [ + "TOOLSETS" + ] + }, + { + "module": "toolsets", + "names": [ + "TOOLSETS" + ] + }, + { + "module": "agent.prompt_builder", + "names": [ + "PLATFORM_HINTS" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "_PLATFORMS" + ] + }, + { + "module": "hermes_cli.gateway", + "names": [ + "_PLATFORMS" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "tools.send_message_tool", + "names": [ + "_send_email" + ] + }, + { + "module": "tools.send_message_tool", + "names": [ + "_send_email" + ] + }, + { + "module": "tools.send_message_tool", + "names": [ + "_send_email" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "EmailAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "EmailAdapter" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "EmailAdapter" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "EmailAdapter" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "EmailAdapter" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "EmailAdapter" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "EmailAdapter" + ] + }, + { + "module": "gateway.platforms.email", + "names": [ + "EmailAdapter" + ] + } + ] + }, + "tests/gateway/test_async_memory_flush.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timedelta" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "GatewayConfig", + "SessionResetPolicy" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "SessionStore", + "SessionEntry" + ] + } + ] + }, + "tests/gateway/test_send_image_file.py": { + "imports": [ + "asyncio", + "os", + "sys", + "pytest", + "discord", + "time", + "time", + "time" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "SendResult" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.platforms.slack", + "names": [ + "SlackAdapter" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_cleanup_old_screenshots", + "_last_screenshot_cleanup_by_dir" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_cleanup_old_screenshots", + "_last_screenshot_cleanup_by_dir" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_cleanup_old_screenshots", + "_last_screenshot_cleanup_by_dir" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_cleanup_old_screenshots", + "_last_screenshot_cleanup_by_dir" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "tools.browser_tool", + "names": [ + "_cleanup_old_screenshots", + "_last_screenshot_cleanup_by_dir" + ] + } + ] + }, + "tests/gateway/test_agent_cache.py": { + "imports": [ + "hashlib", + "json", + "threading", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + }, + { + "module": "run_agent", + "names": [ + "AIAgent" + ] + } + ] + }, + "tests/gateway/test_session_env.py": { + "imports": [ + "os" + ], + "from_imports": [ + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionContext", + "SessionSource" + ] + } + ] + }, + "tests/gateway/test_telegram_documents.py": { + "imports": [ + "asyncio", + "importlib", + "os", + "sys", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType", + "SendResult", + "SUPPORTED_DOCUMENT_TYPES" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + } + ] + }, + "tests/gateway/test_homeassistant.py": { + "imports": [ + "time", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.homeassistant", + "names": [ + "HomeAssistantAdapter", + "check_ha_requirements" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "toolsets", + "names": [ + "resolve_toolset" + ] + }, + { + "module": "toolsets", + "names": [ + "resolve_toolset" + ] + }, + { + "module": "toolsets", + "names": [ + "_HERMES_CORE_TOOLS" + ] + } + ] + }, + "tests/gateway/test_config.py": { + "imports": [ + "os" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "HomeChannel", + "Platform", + "PlatformConfig", + "SessionResetPolicy", + "_apply_env_overrides", + "load_gateway_config" + ] + } + ] + }, + "tests/gateway/test_approve_deny_commands.py": { + "imports": [ + "asyncio", + "os", + "threading", + "time", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry", + "SessionSource", + "build_session_key" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "tools", + "names": [ + "approval" + ] + }, + { + "module": "tools.approval", + "names": [ + "register_gateway_notify", + "unregister_gateway_notify", + "resolve_gateway_approval", + "has_blocking_approval", + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "resolve_gateway_approval" + ] + }, + { + "module": "tools.approval", + "names": [ + "resolve_gateway_approval", + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "resolve_gateway_approval", + "pending_approval_count", + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "register_gateway_notify", + "unregister_gateway_notify", + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "register_gateway_notify", + "clear_session", + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "pending_approval_count", + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "_ApprovalEntry", + "_gateway_queues" + ] + }, + { + "module": "tools.approval", + "names": [ + "register_gateway_notify", + "unregister_gateway_notify", + "resolve_gateway_approval", + "check_all_command_guards" + ] + }, + { + "module": "tools.approval", + "names": [ + "register_gateway_notify", + "unregister_gateway_notify", + "resolve_gateway_approval", + "check_all_command_guards" + ] + }, + { + "module": "tools.approval", + "names": [ + "register_gateway_notify", + "unregister_gateway_notify", + "check_all_command_guards" + ] + }, + { + "module": "tools.approval", + "names": [ + "register_gateway_notify", + "unregister_gateway_notify", + "resolve_gateway_approval", + "check_all_command_guards", + "pending_approval_count" + ] + }, + { + "module": "tools.approval", + "names": [ + "register_gateway_notify", + "unregister_gateway_notify", + "resolve_gateway_approval", + "check_all_command_guards" + ] + }, + { + "module": "tools.approval", + "names": [ + "check_all_command_guards", + "_pending" + ] + }, + { + "module": "tools.approval", + "names": [ + "reset_current_session_key", + "set_current_session_key" + ] + }, + { + "module": "tools.approval", + "names": [ + "reset_current_session_key", + "set_current_session_key" + ] + }, + { + "module": "tools.approval", + "names": [ + "reset_current_session_key", + "set_current_session_key" + ] + }, + { + "module": "tools.approval", + "names": [ + "reset_current_session_key", + "set_current_session_key" + ] + }, + { + "module": "tools.approval", + "names": [ + "reset_current_session_key", + "set_current_session_key" + ] + } + ] + }, + "tests/gateway/test_background_command.py": { + "imports": [ + "asyncio", + "os", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.hooks", + "names": [ + "HookRegistry" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "GATEWAY_KNOWN_COMMANDS" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "GATEWAY_KNOWN_COMMANDS" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "COMMANDS" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "COMMANDS" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "COMMANDS_BY_CATEGORY" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "SlashCommandCompleter" + ] + }, + { + "module": "prompt_toolkit.document", + "names": [ + "Document" + ] + } + ] + }, + "tests/gateway/test_allowlist_startup_check.py": { + "imports": [ + "os" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + } + ] + }, + "tests/gateway/test_background_process_notifications.py": { + "imports": [ + "asyncio", + "pytest", + "gateway.run", + "tools.process_registry", + "tools.process_registry", + "tools.process_registry", + "gateway.run", + "gateway.run", + "gateway.run", + "gateway.run", + "gateway.run" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_verbose_command.py": { + "imports": [ + "asyncio", + "pytest", + "yaml", + "gateway.run" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "GATEWAY_KNOWN_COMMANDS" + ] + } + ] + }, + "tests/gateway/test_webhook_integration.py": { + "imports": [ + "asyncio", + "hashlib", + "hmac", + "json", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp.test_utils", + "names": [ + "TestClient", + "TestServer" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "HomeChannel", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType", + "SendResult" + ] + }, + { + "module": "gateway.platforms.webhook", + "names": [ + "WebhookAdapter", + "_INSECURE_NO_AUTH" + ] + } + ] + }, + "tests/gateway/test_channel_directory.py": { + "imports": [ + "json", + "os" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "gateway.channel_directory", + "names": [ + "resolve_channel_name", + "format_directory_for_display", + "load_directory", + "_build_from_sessions", + "DIRECTORY_PATH" + ] + } + ] + }, + "tests/gateway/test_matrix_voice.py": { + "imports": [ + "io", + "pytest", + "nio", + "nio", + "nio", + "tempfile", + "os", + "nio", + "nio" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.matrix", + "names": [ + "MatrixAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + } + ] + }, + "tests/gateway/test_discord_opus.py": { + "imports": [ + "inspect" + ], + "from_imports": [ + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + } + ] + }, + "tests/gateway/test_plan_command.py": { + "imports": [ + "pytest", + "gateway.run" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "agent.skill_commands", + "names": [ + "scan_skill_commands" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry", + "SessionSource" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_webhook_dynamic_routes.py": { + "imports": [ + "json", + "os", + "pytest", + "time" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.webhook", + "names": [ + "WebhookAdapter", + "_DYNAMIC_ROUTES_FILENAME" + ] + } + ] + }, + "tests/gateway/test_flush_memory_stale_guard.py": { + "imports": [ + "sys", + "types", + "pytest", + "io", + "sys" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "call" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "agent.display", + "names": [ + "KawaiiSpinner" + ] + } + ] + }, + "tests/gateway/test_session_reset_notify.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timedelta" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig", + "SessionResetPolicy" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry", + "SessionSource", + "SessionStore" + ] + } + ] + }, + "tests/gateway/test_dm_topics.py": { + "imports": [ + "asyncio", + "os", + "sys", + "pytest", + "yaml", + "yaml", + "yaml" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch", + "mock_open" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + }, + { + "module": "telegram.constants", + "names": [ + "ChatType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + } + ] + }, + "tests/gateway/test_reasoning_command.py": { + "imports": [ + "asyncio", + "inspect", + "sys", + "types", + "pytest", + "yaml", + "gateway.run" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + } + ] + }, + "tests/gateway/test_extract_local_files.py": { + "imports": [ + "os", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter" + ] + } + ] + }, + "tests/gateway/test_media_extraction.py": { + "imports": [ + "pytest", + "re" + ], + "from_imports": [] + }, + "tests/gateway/test_run_progress_topics.py": { + "imports": [ + "importlib", + "sys", + "time", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter", + "SendResult" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + } + ] + }, + "tests/gateway/test_signal.py": { + "imports": [ + "base64", + "json", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch", + "AsyncMock" + ] + }, + { + "module": "urllib.parse", + "names": [ + "quote" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "SignalAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_redact_phone" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_redact_phone" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_redact_phone" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_parse_comma_list" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_guess_extension" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_guess_extension" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_guess_extension" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_guess_extension" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_guess_extension" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_guess_extension" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_is_image_ext" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_is_audio_ext" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "check_signal_requirements" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_render_mentions" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "_render_mentions" + ] + }, + { + "module": "gateway.platforms.signal", + "names": [ + "check_signal_requirements" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "agent.redact", + "names": [ + "redact_sensitive_text" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig" + ] + }, + { + "module": "tools.send_message_tool", + "names": [ + "send_message_tool" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + } + ] + }, + "tests/gateway/test_telegram_format.py": { + "imports": [ + "re", + "sys", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter", + "_escape_mdv2", + "_strip_mdv2" + ] + } + ] + }, + "tests/gateway/test_api_server_toolset.py": { + "imports": [ + "os", + "json", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "patch", + "MagicMock" + ] + }, + { + "module": "toolsets", + "names": [ + "resolve_toolset", + "get_toolset", + "validate_toolset" + ] + }, + { + "module": "hermes_cli.tools_config", + "names": [ + "PLATFORMS" + ] + }, + { + "module": "gateway.platforms.api_server", + "names": [ + "APIServerAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.api_server", + "names": [ + "APIServerAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + } + ] + }, + "tests/gateway/test_status_command.py": { + "imports": [ + "pytest", + "gateway.run" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionEntry", + "SessionSource", + "build_session_key" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_api_server_jobs.py": { + "imports": [ + "json", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock", + "patch" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp.test_utils", + "names": [ + "TestClient", + "TestServer" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.api_server", + "names": [ + "APIServerAdapter", + "cors_middleware" + ] + } + ] + }, + "tests/gateway/test_telegram_network.py": { + "imports": [ + "httpx", + "pytest", + "sys" + ], + "from_imports": [ + { + "module": "gateway.platforms", + "names": [ + "telegram_network" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig", + "_apply_env_overrides" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig", + "_apply_env_overrides" + ] + }, + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.telegram", + "names": [ + "TelegramAdapter" + ] + } + ] + }, + "tests/gateway/test_voice_command.py": { + "imports": [ + "importlib.util", + "json", + "os", + "queue", + "sys", + "threading", + "time", + "pytest", + "ast", + "inspect", + "textwrap", + "ast", + "inspect", + "textwrap", + "threading", + "ast", + "inspect", + "re", + "re", + "ast", + "inspect", + "inspect", + "inspect", + "uuid", + "inspect", + "inspect", + "textwrap", + "ast", + "inspect", + "time", + "struct", + "asyncio" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType", + "SessionSource" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "gateway_help_lines" + ] + }, + { + "module": "hermes_cli.commands", + "names": [ + "GATEWAY_KNOWN_COMMANDS" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "stream_tts_to_speaker" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "stream_tts_to_speaker" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "stream_tts_to_speaker" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "stream_tts_to_speaker" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "stream_tts_to_speaker" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "stream_tts_to_speaker" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "stream_tts_to_speaker" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "stream_tts_to_speaker" + ] + }, + { + "module": "tools.tts_tool", + "names": [ + "stream_tts_to_speaker" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig", + "Platform" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig", + "Platform" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig", + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "SendResult" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "SendResult" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType", + "MessageEvent", + "SessionSource" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageType" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig", + "Platform" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "VoiceReceiver" + ] + } + ] + }, + "tests/gateway/test_runner_startup_failures.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "BasePlatformAdapter" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.status", + "names": [ + "read_runtime_status" + ] + } + ] + }, + "tests/gateway/test_whatsapp_group_gating.py": { + "imports": [ + "json" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig", + "load_gateway_config" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "WhatsAppAdapter" + ] + } + ] + }, + "tests/gateway/test_discord_slash_commands.py": { + "imports": [ + "sys", + "pytest", + "discord", + "yaml", + "os" + ], + "from_imports": [ + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.discord", + "names": [ + "DiscordAdapter" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + } + ] + }, + "tests/gateway/test_retry_response.py": { + "imports": [ + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType" + ] + } + ] + }, + "tests/gateway/test_step_callback_compat.py": { + "imports": [ + "asyncio", + "pytest", + "threading", + "threading", + "threading" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + } + ] + }, + "tests/gateway/test_media_download_retry.py": { + "imports": [ + "asyncio", + "sys", + "pytest", + "httpx", + "gateway.platforms.slack", + "aiohttp" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.platforms.slack", + "names": [ + "SlackAdapter" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.mattermost", + "names": [ + "MattermostAdapter" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_image_from_url" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_image_from_url" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_image_from_url" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_image_from_url" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_image_from_url" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_audio_from_url" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_audio_from_url" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_audio_from_url" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_audio_from_url" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_audio_from_url" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "cache_audio_from_url" + ] + } + ] + }, + "tests/gateway/test_api_server.py": { + "imports": [ + "json", + "time", + "uuid", + "pytest", + "asyncio", + "asyncio", + "asyncio" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "aiohttp", + "names": [ + "web" + ] + }, + { + "module": "aiohttp.test_utils", + "names": [ + "AioHTTPTestCase", + "TestClient", + "TestServer" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.api_server", + "names": [ + "APIServerAdapter", + "ResponseStore", + "_CORS_HEADERS", + "check_api_server_requirements", + "cors_middleware", + "security_headers_middleware" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + }, + { + "module": "gateway.config", + "names": [ + "load_gateway_config" + ] + } + ] + }, + "tests/gateway/test_transcript_offset.py": { + "imports": [ + "pytest" + ], + "from_imports": [] + }, + "tests/gateway/test_discord_bot_filter.py": { + "imports": [ + "asyncio", + "os", + "unittest", + "discord" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + } + ] + }, + "tests/gateway/test_telegram_photo_interrupts.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "unittest.mock", + "names": [ + "MagicMock" + ] + }, + { + "module": "gateway.config", + "names": [ + "GatewayConfig", + "Platform", + "PlatformConfig" + ] + }, + { + "module": "gateway.platforms.base", + "names": [ + "MessageEvent", + "MessageType" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource", + "build_session_key" + ] + }, + { + "module": "gateway.run", + "names": [ + "GatewayRunner" + ] + } + ] + }, + "tests/gateway/test_whatsapp_connect.py": { + "imports": [ + "asyncio", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest.mock", + "names": [ + "AsyncMock", + "MagicMock", + "patch" + ] + }, + { + "module": "gateway.config", + "names": [ + "Platform" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "WhatsAppAdapter" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "WhatsAppAdapter" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "_kill_port_process" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "_kill_port_process" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "_kill_port_process" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "_kill_port_process" + ] + }, + { + "module": "gateway.platforms.whatsapp", + "names": [ + "_kill_port_process" + ] + } + ] + }, + "tests/gateway/test_discord_imports.py": { + "imports": [ + "builtins", + "importlib", + "sys" + ], + "from_imports": [] + }, + "tests/gateway/test_delivery.py": { + "imports": [], + "from_imports": [ + { + "module": "gateway.config", + "names": [ + "Platform", + "GatewayConfig", + "PlatformConfig", + "HomeChannel" + ] + }, + { + "module": "gateway.delivery", + "names": [ + "DeliveryRouter", + "DeliveryTarget", + "parse_deliver_spec" + ] + }, + { + "module": "gateway.session", + "names": [ + "SessionSource" + ] + } + ] + }, + "tests/skills/test_telephony_skill.py": { + "imports": [ + "importlib.util", + "json", + "os", + "sys" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/skills/test_google_workspace_api.py": { + "imports": [ + "importlib.util", + "json", + "sys", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/skills/test_google_oauth_setup.py": { + "imports": [ + "importlib.util", + "json", + "sys", + "types", + "pytest" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/skills/test_openclaw_migration.py": { + "imports": [ + "importlib.util", + "json", + "sys" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + } + ] + }, + "tests/skills/test_memento_cards.py": { + "imports": [ + "csv", + "json", + "os", + "sys", + "uuid", + "pytest", + "memento_cards", + "shutil" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime", + "timedelta", + "timezone" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "unittest", + "names": [ + "mock" + ] + } + ] + }, + "tests/skills/test_youtube_quiz.py": { + "imports": [ + "json", + "sys", + "pytest", + "youtube_quiz", + "builtins" + ], + "from_imports": [ + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "types", + "names": [ + "SimpleNamespace" + ] + }, + { + "module": "unittest", + "names": [ + "mock" + ] + } + ] + }, + "plugins/__init__.py": { + "imports": [], + "from_imports": [] + }, + "plugins/memory/__init__.py": { + "imports": [ + "importlib", + "importlib.util", + "logging", + "sys", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "List", + "Optional", + "Tuple" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + } + ] + }, + "plugins/memory/honcho/__init__.py": { + "imports": [ + "json", + "logging", + "threading", + "json" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "get_honcho_client" + ] + }, + { + "module": "plugins.memory.honcho.session", + "names": [ + "HonchoSessionManager" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig", + "get_honcho_client" + ] + }, + { + "module": "plugins.memory.honcho.session", + "names": [ + "HonchoSessionManager" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "plugins/memory/honcho/cli.py": { + "imports": [ + "json", + "os", + "sys", + "subprocess", + "re", + "honcho", + "honcho", + "getpass" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "resolve_active_host", + "resolve_config_path", + "GLOBAL_CONFIG_PATH", + "HOST" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig", + "get_honcho_client" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "list_profiles" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "list_profiles" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig", + "get_honcho_client", + "reset_honcho_client" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "get_active_profile_name" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "list_profiles" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig", + "get_honcho_client" + ] + }, + { + "module": "plugins.memory.honcho.session", + "names": [ + "HonchoSessionManager" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig", + "get_honcho_client" + ] + }, + { + "module": "plugins.memory.honcho.session", + "names": [ + "HonchoSessionManager" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig", + "get_honcho_client", + "reset_honcho_client" + ] + }, + { + "module": "plugins.memory.honcho.session", + "names": [ + "HonchoSessionManager" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "HonchoClientConfig", + "get_honcho_client", + "reset_honcho_client" + ] + }, + { + "module": "plugins.memory.honcho.session", + "names": [ + "HonchoSessionManager" + ] + } + ] + }, + "plugins/memory/honcho/client.py": { + "imports": [ + "json", + "os", + "logging", + "subprocess", + "re" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "TYPE_CHECKING" + ] + }, + { + "module": "honcho", + "names": [ + "Honcho" + ] + }, + { + "module": "hermes_cli.profiles", + "names": [ + "get_active_profile_name" + ] + }, + { + "module": "honcho", + "names": [ + "Honcho" + ] + }, + { + "module": "hermes_cli.config", + "names": [ + "load_config" + ] + } + ] + }, + "plugins/memory/honcho/session.py": { + "imports": [ + "queue", + "re", + "logging", + "threading", + "time", + "time" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "dataclasses", + "names": [ + "dataclass", + "field" + ] + }, + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "TYPE_CHECKING" + ] + }, + { + "module": "plugins.memory.honcho.client", + "names": [ + "get_honcho_client" + ] + }, + { + "module": "honcho", + "names": [ + "Honcho" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "honcho.session", + "names": [ + "SessionPeerConfig" + ] + } + ] + }, + "plugins/memory/retaindb/__init__.py": { + "imports": [ + "json", + "logging", + "os", + "threading", + "requests" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + } + ] + }, + "plugins/memory/mem0/__init__.py": { + "imports": [ + "json", + "logging", + "os", + "threading", + "time", + "json" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "mem0", + "names": [ + "MemoryClient" + ] + } + ] + }, + "plugins/memory/hindsight/__init__.py": { + "imports": [ + "json", + "logging", + "os", + "queue", + "threading", + "asyncio", + "json" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hindsight_client", + "names": [ + "Hindsight" + ] + }, + { + "module": "hindsight", + "names": [ + "HindsightEmbedded" + ] + } + ] + }, + "plugins/memory/byterover/__init__.py": { + "imports": [ + "json", + "logging", + "os", + "shutil", + "subprocess", + "threading", + "time" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "plugins/memory/holographic/holographic.py": { + "imports": [ + "hashlib", + "logging", + "struct", + "math", + "numpy" + ], + "from_imports": [] + }, + "plugins/memory/holographic/__init__.py": { + "imports": [ + "json", + "logging", + "re", + "yaml", + "yaml" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + }, + { + "module": "store", + "names": [ + "MemoryStore" + ] + }, + { + "module": "retrieval", + "names": [ + "FactRetriever" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "hermes_constants", + "names": [ + "display_hermes_home" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "plugins/memory/holographic/retrieval.py": { + "imports": [ + "math", + "holographic" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "datetime", + "names": [ + "datetime", + "timezone" + ] + }, + { + "module": "typing", + "names": [ + "TYPE_CHECKING" + ] + }, + { + "module": "store", + "names": [ + "MemoryStore" + ] + }, + { + "module": "", + "names": [ + "holographic" + ] + } + ] + }, + "plugins/memory/holographic/store.py": { + "imports": [ + "re", + "sqlite3", + "threading", + "holographic" + ], + "from_imports": [ + { + "module": "datetime", + "names": [ + "datetime" + ] + }, + { + "module": "pathlib", + "names": [ + "Path" + ] + }, + { + "module": "", + "names": [ + "holographic" + ] + }, + { + "module": "hermes_constants", + "names": [ + "get_hermes_home" + ] + } + ] + }, + "plugins/memory/openviking/__init__.py": { + "imports": [ + "json", + "logging", + "os", + "threading", + "httpx" + ], + "from_imports": [ + { + "module": "__future__", + "names": [ + "annotations" + ] + }, + { + "module": "typing", + "names": [ + "Any", + "Dict", + "List", + "Optional" + ] + }, + { + "module": "agent.memory_provider", + "names": [ + "MemoryProvider" + ] + } + ] + } + }, + "errors": [] +} \ No newline at end of file diff --git a/docs/ouroboros/artifacts/module_inventory.json b/docs/ouroboros/artifacts/module_inventory.json new file mode 100644 index 000000000..0b340dd11 --- /dev/null +++ b/docs/ouroboros/artifacts/module_inventory.json @@ -0,0 +1,3397 @@ +[ + { + "path": "run_agent.py", + "lines": 8948, + "sloc": 6997 + }, + { + "path": "cli.py", + "lines": 8280, + "sloc": 6568 + }, + { + "path": "gateway/run.py", + "lines": 6657, + "sloc": 5171 + }, + { + "path": "hermes_cli/main.py", + "lines": 5407, + "sloc": 4389 + }, + { + "path": "gateway/platforms/feishu.py", + "lines": 3255, + "sloc": 2815 + }, + { + "path": "tests/test_run_agent.py", + "lines": 3339, + "sloc": 2677 + }, + { + "path": "hermes_cli/setup.py", + "lines": 3050, + "sloc": 2497 + }, + { + "path": "tests/tools/test_mcp_tool.py", + "lines": 3063, + "sloc": 2290 + }, + { + "path": "optional-skills/migration/openclaw-migration/scripts/openclaw_to_hermes.py", + "lines": 2653, + "sloc": 2275 + }, + { + "path": "hermes_cli/auth.py", + "lines": 2665, + "sloc": 2195 + }, + { + "path": "tools/skills_hub.py", + "lines": 2707, + "sloc": 2188 + }, + { + "path": "tests/gateway/test_feishu.py", + "lines": 2580, + "sloc": 2140 + }, + { + "path": "tests/gateway/test_voice_command.py", + "lines": 2632, + "sloc": 2003 + }, + { + "path": "gateway/platforms/discord.py", + "lines": 2346, + "sloc": 1854 + }, + { + "path": "gateway/platforms/telegram.py", + "lines": 2145, + "sloc": 1754 + }, + { + "path": "hermes_cli/config.py", + "lines": 2265, + "sloc": 1739 + }, + { + "path": "hermes_cli/gateway.py", + "lines": 2126, + "sloc": 1737 + }, + { + "path": "tools/mcp_tool.py", + "lines": 2165, + "sloc": 1703 + }, + { + "path": "tools/browser_tool.py", + "lines": 2115, + "sloc": 1604 + }, + { + "path": "tools/web_tools.py", + "lines": 2065, + "sloc": 1590 + }, + { + "path": "agent/auxiliary_client.py", + "lines": 1926, + "sloc": 1510 + }, + { + "path": "hermes_cli/tools_config.py", + "lines": 1790, + "sloc": 1413 + }, + { + "path": "tests/gateway/test_api_server.py", + "lines": 1685, + "sloc": 1349 + }, + { + "path": "gateway/platforms/base.py", + "lines": 1558, + "sloc": 1196 + }, + { + "path": "optional-skills/productivity/telephony/scripts/telephony.py", + "lines": 1343, + "sloc": 1187 + }, + { + "path": "gateway/platforms/wecom.py", + "lines": 1338, + "sloc": 1149 + }, + { + "path": "tools/terminal_tool.py", + "lines": 1466, + "sloc": 1120 + }, + { + "path": "gateway/platforms/api_server.py", + "lines": 1373, + "sloc": 1115 + }, + { + "path": "tests/tools/test_skills_hub.py", + "lines": 1371, + "sloc": 1112 + }, + { + "path": "trajectory_compressor.py", + "lines": 1518, + "sloc": 1099 + }, + { + "path": "tools/skills_tool.py", + "lines": 1378, + "sloc": 1095 + }, + { + "path": "hermes_cli/models.py", + "lines": 1300, + "sloc": 1091 + }, + { + "path": "tests/test_anthropic_adapter.py", + "lines": 1327, + "sloc": 1088 + }, + { + "path": "agent/anthropic_adapter.py", + "lines": 1390, + "sloc": 1085 + }, + { + "path": "hermes_state.py", + "lines": 1270, + "sloc": 1044 + }, + { + "path": "tools/rl_training_tool.py", + "lines": 1402, + "sloc": 1044 + }, + { + "path": "tests/tools/test_voice_cli_integration.py", + "lines": 1233, + "sloc": 1002 + }, + { + "path": "environments/agentic_opd_env.py", + "lines": 1213, + "sloc": 973 + }, + { + "path": "batch_runner.py", + "lines": 1285, + "sloc": 972 + }, + { + "path": "hermes_cli/skills_hub.py", + "lines": 1219, + "sloc": 970 + }, + { + "path": "tests/test_hermes_state.py", + "lines": 1299, + "sloc": 963 + }, + { + "path": "plugins/memory/honcho/cli.py", + "lines": 1166, + "sloc": 943 + }, + { + "path": "tests/agent/test_auxiliary_client.py", + "lines": 1108, + "sloc": 939 + }, + { + "path": "gateway/platforms/matrix.py", + "lines": 1217, + "sloc": 936 + }, + { + "path": "tests/gateway/test_email.py", + "lines": 1178, + "sloc": 932 + }, + { + "path": "tests/test_mcp_serve.py", + "lines": 1111, + "sloc": 897 + }, + { + "path": "tools/skills_guard.py", + "lines": 1105, + "sloc": 888 + }, + { + "path": "agent/display.py", + "lines": 1084, + "sloc": 862 + }, + { + "path": "tests/tools/test_skills_tool.py", + "lines": 1048, + "sloc": 850 + }, + { + "path": "tests/test_run_agent_codex_responses.py", + "lines": 1041, + "sloc": 849 + }, + { + "path": "tests/agent/test_prompt_builder.py", + "lines": 1090, + "sloc": 843 + }, + { + "path": "plugins/memory/honcho/session.py", + "lines": 1027, + "sloc": 836 + }, + { + "path": "tools/file_operations.py", + "lines": 1168, + "sloc": 828 + }, + { + "path": "gateway/session.py", + "lines": 1050, + "sloc": 821 + }, + { + "path": "tests/test_credential_pool.py", + "lines": 949, + "sloc": 814 + }, + { + "path": "agent/credential_pool.py", + "lines": 947, + "sloc": 808 + }, + { + "path": "gateway/platforms/whatsapp.py", + "lines": 941, + "sloc": 807 + }, + { + "path": "hermes_cli/profiles.py", + "lines": 1070, + "sloc": 792 + }, + { + "path": "gateway/platforms/slack.py", + "lines": 998, + "sloc": 787 + }, + { + "path": "tests/tools/test_tirith_security.py", + "lines": 1006, + "sloc": 787 + }, + { + "path": "tests/gateway/test_slack.py", + "lines": 1059, + "sloc": 785 + }, + { + "path": "tests/test_runtime_provider_resolution.py", + "lines": 1008, + "sloc": 783 + }, + { + "path": "tools/send_message_tool.py", + "lines": 906, + "sloc": 774 + }, + { + "path": "optional-skills/blockchain/base/scripts/base_client.py", + "lines": 1008, + "sloc": 762 + }, + { + "path": "gateway/config.py", + "lines": 919, + "sloc": 755 + }, + { + "path": "agent/prompt_builder.py", + "lines": 920, + "sloc": 750 + }, + { + "path": "tests/tools/test_delegate.py", + "lines": 888, + "sloc": 745 + }, + { + "path": "tools/tts_tool.py", + "lines": 984, + "sloc": 737 + }, + { + "path": "tests/gateway/test_session.py", + "lines": 868, + "sloc": 726 + }, + { + "path": "tests/gateway/test_matrix.py", + "lines": 995, + "sloc": 722 + }, + { + "path": "tools/process_registry.py", + "lines": 889, + "sloc": 719 + }, + { + "path": "agent/model_metadata.py", + "lines": 935, + "sloc": 716 + }, + { + "path": "tests/test_api_key_providers.py", + "lines": 914, + "sloc": 710 + }, + { + "path": "tests/test_provider_parity.py", + "lines": 833, + "sloc": 709 + }, + { + "path": "environments/benchmarks/terminalbench_2/terminalbench2_env.py", + "lines": 958, + "sloc": 699 + }, + { + "path": "tests/tools/test_clipboard.py", + "lines": 877, + "sloc": 698 + }, + { + "path": "tests/tools/test_voice_mode.py", + "lines": 1066, + "sloc": 698 + }, + { + "path": "hermes_cli/commands.py", + "lines": 874, + "sloc": 684 + }, + { + "path": "mcp_serve.py", + "lines": 868, + "sloc": 681 + }, + { + "path": "tests/cron/test_scheduler.py", + "lines": 795, + "sloc": 663 + }, + { + "path": "environments/benchmarks/yc_bench/yc_bench_env.py", + "lines": 847, + "sloc": 662 + }, + { + "path": "hermes_cli/doctor.py", + "lines": 817, + "sloc": 656 + }, + { + "path": "agent/insights.py", + "lines": 799, + "sloc": 655 + }, + { + "path": "tests/test_streaming.py", + "lines": 816, + "sloc": 650 + }, + { + "path": "tests/tools/test_code_execution.py", + "lines": 809, + "sloc": 647 + }, + { + "path": "tools/delegate_tool.py", + "lines": 807, + "sloc": 645 + }, + { + "path": "tools/file_tools.py", + "lines": 828, + "sloc": 631 + }, + { + "path": "skills/red-teaming/godmode/scripts/auto_jailbreak.py", + "lines": 772, + "sloc": 631 + }, + { + "path": "tests/tools/test_transcription_tools.py", + "lines": 860, + "sloc": 629 + }, + { + "path": "tools/approval.py", + "lines": 868, + "sloc": 624 + }, + { + "path": "tools/code_execution_tool.py", + "lines": 815, + "sloc": 623 + }, + { + "path": "hermes_cli/skin_engine.py", + "lines": 724, + "sloc": 623 + }, + { + "path": "hermes_cli/runtime_provider.py", + "lines": 735, + "sloc": 617 + }, + { + "path": "tools/voice_mode.py", + "lines": 812, + "sloc": 595 + }, + { + "path": "gateway/platforms/signal.py", + "lines": 807, + "sloc": 586 + }, + { + "path": "cron/jobs.py", + "lines": 746, + "sloc": 585 + }, + { + "path": "agent/usage_pricing.py", + "lines": 656, + "sloc": 582 + }, + { + "path": "tests/gateway/test_mattermost.py", + "lines": 757, + "sloc": 582 + }, + { + "path": "tests/test_reasoning_command.py", + "lines": 764, + "sloc": 576 + }, + { + "path": "tools/skill_manager_tool.py", + "lines": 747, + "sloc": 575 + }, + { + "path": "gateway/platforms/mattermost.py", + "lines": 723, + "sloc": 575 + }, + { + "path": "tests/tools/test_approval.py", + "lines": 718, + "sloc": 568 + }, + { + "path": "tests/skills/test_openclaw_migration.py", + "lines": 683, + "sloc": 564 + }, + { + "path": "environments/web_research_env.py", + "lines": 718, + "sloc": 549 + }, + { + "path": "tests/hermes_cli/test_profiles.py", + "lines": 800, + "sloc": 546 + }, + { + "path": "plugins/memory/honcho/__init__.py", + "lines": 692, + "sloc": 543 + }, + { + "path": "tools/image_generation_tool.py", + "lines": 703, + "sloc": 542 + }, + { + "path": "tests/hermes_cli/test_claw.py", + "lines": 702, + "sloc": 538 + }, + { + "path": "tests/gateway/test_media_download_retry.py", + "lines": 722, + "sloc": 538 + }, + { + "path": "tests/test_insights.py", + "lines": 718, + "sloc": 534 + }, + { + "path": "mini_swe_runner.py", + "lines": 709, + "sloc": 530 + }, + { + "path": "tests/gateway/test_telegram_documents.py", + "lines": 695, + "sloc": 525 + }, + { + "path": "acp_adapter/server.py", + "lines": 608, + "sloc": 524 + }, + { + "path": "optional-skills/blockchain/solana/scripts/solana_client.py", + "lines": 698, + "sloc": 521 + }, + { + "path": "tests/tools/test_web_tools_config.py", + "lines": 617, + "sloc": 511 + }, + { + "path": "gateway/platforms/email.py", + "lines": 621, + "sloc": 509 + }, + { + "path": "tests/acp/test_server.py", + "lines": 683, + "sloc": 509 + }, + { + "path": "tests/test_cli_provider_resolution.py", + "lines": 642, + "sloc": 504 + }, + { + "path": "tools/tirith_security.py", + "lines": 670, + "sloc": 498 + }, + { + "path": "scripts/release.py", + "lines": 632, + "sloc": 492 + }, + { + "path": "agent/context_compressor.py", + "lines": 676, + "sloc": 491 + }, + { + "path": "tests/gateway/test_api_server_jobs.py", + "lines": 597, + "sloc": 491 + }, + { + "path": "environments/hermes_base_env.py", + "lines": 670, + "sloc": 486 + }, + { + "path": "hermes_cli/mcp_config.py", + "lines": 645, + "sloc": 485 + }, + { + "path": "gateway/platforms/webhook.py", + "lines": 616, + "sloc": 484 + }, + { + "path": "tests/gateway/test_update_command.py", + "lines": 651, + "sloc": 483 + }, + { + "path": "tools/environments/docker.py", + "lines": 596, + "sloc": 482 + }, + { + "path": "tests/agent/test_model_metadata.py", + "lines": 635, + "sloc": 482 + }, + { + "path": "cron/scheduler.py", + "lines": 629, + "sloc": 479 + }, + { + "path": "plugins/memory/openviking/__init__.py", + "lines": 591, + "sloc": 479 + }, + { + "path": "tests/integration/test_web_tools.py", + "lines": 628, + "sloc": 475 + }, + { + "path": "tests/gateway/test_wecom.py", + "lines": 596, + "sloc": 469 + }, + { + "path": "tests/gateway/test_approve_deny_commands.py", + "lines": 632, + "sloc": 469 + }, + { + "path": "toolsets.py", + "lines": 641, + "sloc": 468 + }, + { + "path": "tests/gateway/test_telegram_network.py", + "lines": 644, + "sloc": 467 + }, + { + "path": "tools/vision_tools.py", + "lines": 614, + "sloc": 466 + }, + { + "path": "tests/test_worktree.py", + "lines": 635, + "sloc": 466 + }, + { + "path": "tests/gateway/test_homeassistant.py", + "lines": 622, + "sloc": 464 + }, + { + "path": "tools/transcription_tools.py", + "lines": 622, + "sloc": 461 + }, + { + "path": "tests/gateway/test_dm_topics.py", + "lines": 647, + "sloc": 461 + }, + { + "path": "tests/hermes_cli/test_update_autostash.py", + "lines": 636, + "sloc": 460 + }, + { + "path": "plugins/memory/holographic/store.py", + "lines": 575, + "sloc": 460 + }, + { + "path": "hermes_cli/claw.py", + "lines": 568, + "sloc": 456 + }, + { + "path": "tests/hermes_cli/test_commands.py", + "lines": 630, + "sloc": 456 + }, + { + "path": "hermes_cli/plugins_cmd.py", + "lines": 598, + "sloc": 452 + }, + { + "path": "tests/integration/test_voice_channel_flow.py", + "lines": 611, + "sloc": 450 + }, + { + "path": "tests/tools/test_file_tools_live.py", + "lines": 587, + "sloc": 449 + }, + { + "path": "hermes_cli/nous_subscription.py", + "lines": 517, + "sloc": 441 + }, + { + "path": "tests/agent/test_context_compressor.py", + "lines": 564, + "sloc": 441 + }, + { + "path": "tests/gateway/test_webhook_adapter.py", + "lines": 619, + "sloc": 441 + }, + { + "path": "plugins/memory/holographic/retrieval.py", + "lines": 593, + "sloc": 438 + }, + { + "path": "tools/browser_camofox.py", + "lines": 571, + "sloc": 436 + }, + { + "path": "tests/hermes_cli/test_gateway_service.py", + "lines": 612, + "sloc": 436 + }, + { + "path": "skills/red-teaming/godmode/scripts/parseltongue.py", + "lines": 551, + "sloc": 431 + }, + { + "path": "agent/context_references.py", + "lines": 492, + "sloc": 424 + }, + { + "path": "tests/tools/test_send_message_tool.py", + "lines": 506, + "sloc": 423 + }, + { + "path": "tools/mixture_of_agents_tool.py", + "lines": 562, + "sloc": 422 + }, + { + "path": "tools/memory_tool.py", + "lines": 560, + "sloc": 421 + }, + { + "path": "tests/test_agent_loop.py", + "lines": 505, + "sloc": 421 + }, + { + "path": "tests/agent/test_memory_provider.py", + "lines": 549, + "sloc": 416 + }, + { + "path": "skills/red-teaming/godmode/scripts/godmode_race.py", + "lines": 532, + "sloc": 414 + }, + { + "path": "tests/cron/test_jobs.py", + "lines": 544, + "sloc": 414 + }, + { + "path": "tests/honcho_plugin/test_async_memory.py", + "lines": 560, + "sloc": 413 + }, + { + "path": "tools/session_search_tool.py", + "lines": 504, + "sloc": 412 + }, + { + "path": "hermes_cli/plugins.py", + "lines": 561, + "sloc": 411 + }, + { + "path": "tests/test_agent_loop_tool_calling.py", + "lines": 552, + "sloc": 406 + }, + { + "path": "tests/tools/test_vision_tools.py", + "lines": 546, + "sloc": 400 + }, + { + "path": "tools/checkpoint_manager.py", + "lines": 548, + "sloc": 399 + }, + { + "path": "tests/honcho_plugin/test_client.py", + "lines": 476, + "sloc": 399 + }, + { + "path": "tests/tools/test_website_policy.py", + "lines": 512, + "sloc": 398 + }, + { + "path": "tests/hermes_cli/test_session_browse.py", + "lines": 542, + "sloc": 398 + }, + { + "path": "environments/agent_loop.py", + "lines": 511, + "sloc": 394 + }, + { + "path": "agent/copilot_acp_client.py", + "lines": 447, + "sloc": 394 + }, + { + "path": "hermes_cli/auth_commands.py", + "lines": 470, + "sloc": 393 + }, + { + "path": "tests/test_anthropic_error_handling.py", + "lines": 490, + "sloc": 390 + }, + { + "path": "tools/cronjob_tools.py", + "lines": 458, + "sloc": 389 + }, + { + "path": "acp_adapter/session.py", + "lines": 461, + "sloc": 388 + }, + { + "path": "skills/productivity/google-workspace/scripts/google_api.py", + "lines": 513, + "sloc": 388 + }, + { + "path": "tools/homeassistant_tool.py", + "lines": 490, + "sloc": 387 + }, + { + "path": "tools/environments/local.py", + "lines": 486, + "sloc": 380 + }, + { + "path": "tests/test_413_compression.py", + "lines": 474, + "sloc": 380 + }, + { + "path": "tests/tools/test_managed_browserbase_and_modal.py", + "lines": 459, + "sloc": 380 + }, + { + "path": "plugins/memory/honcho/client.py", + "lines": 504, + "sloc": 378 + }, + { + "path": "tests/test_model_metadata_local_ctx.py", + "lines": 493, + "sloc": 375 + }, + { + "path": "tests/test_resume_display.py", + "lines": 488, + "sloc": 375 + }, + { + "path": "optional-skills/creative/meme-generation/scripts/generate_meme.py", + "lines": 471, + "sloc": 370 + }, + { + "path": "tests/tools/test_skills_guard.py", + "lines": 516, + "sloc": 370 + }, + { + "path": "tests/hermes_cli/test_update_gateway_restart.py", + "lines": 493, + "sloc": 362 + }, + { + "path": "tests/gateway/test_whatsapp_connect.py", + "lines": 502, + "sloc": 362 + }, + { + "path": "tools/environments/modal.py", + "lines": 445, + "sloc": 361 + }, + { + "path": "tests/hermes_cli/test_setup_openclaw_migration.py", + "lines": 466, + "sloc": 361 + }, + { + "path": "tests/hermes_cli/test_model_validation.py", + "lines": 474, + "sloc": 360 + }, + { + "path": "tests/tools/test_skills_sync.py", + "lines": 491, + "sloc": 358 + }, + { + "path": "tests/tools/test_read_loop_detection.py", + "lines": 436, + "sloc": 355 + }, + { + "path": "hermes_cli/banner.py", + "lines": 463, + "sloc": 352 + }, + { + "path": "tests/tools/test_credential_files.py", + "lines": 478, + "sloc": 352 + }, + { + "path": "tests/hermes_cli/test_setup_model_provider.py", + "lines": 477, + "sloc": 352 + }, + { + "path": "environments/tool_context.py", + "lines": 474, + "sloc": 349 + }, + { + "path": "hermes_cli/memory_setup.py", + "lines": 451, + "sloc": 348 + }, + { + "path": "gateway/platforms/homeassistant.py", + "lines": 449, + "sloc": 344 + }, + { + "path": "tests/gateway/test_discord_slash_commands.py", + "lines": 499, + "sloc": 339 + }, + { + "path": "tests/gateway/test_telegram_format.py", + "lines": 538, + "sloc": 338 + }, + { + "path": "tools/patch_parser.py", + "lines": 455, + "sloc": 336 + }, + { + "path": "tests/test_trajectory_compressor.py", + "lines": 419, + "sloc": 336 + }, + { + "path": "plugins/memory/holographic/__init__.py", + "lines": 407, + "sloc": 333 + }, + { + "path": "hermes_cli/status.py", + "lines": 424, + "sloc": 332 + }, + { + "path": "tools/fuzzy_match.py", + "lines": 482, + "sloc": 329 + }, + { + "path": "optional-skills/research/domain-intel/scripts/domain_intel.py", + "lines": 397, + "sloc": 329 + }, + { + "path": "tests/test_fallback_model.py", + "lines": 377, + "sloc": 327 + }, + { + "path": "tests/skills/test_memento_cards.py", + "lines": 427, + "sloc": 326 + }, + { + "path": "model_tools.py", + "lines": 466, + "sloc": 325 + }, + { + "path": "tests/integration/test_checkpoint_resumption.py", + "lines": 440, + "sloc": 323 + }, + { + "path": "tests/tools/test_cronjob_tools.py", + "lines": 405, + "sloc": 322 + }, + { + "path": "tests/gateway/test_platform_base.py", + "lines": 424, + "sloc": 321 + }, + { + "path": "tests/test_auth_commands.py", + "lines": 391, + "sloc": 320 + }, + { + "path": "tests/gateway/test_send_image_file.py", + "lines": 437, + "sloc": 316 + }, + { + "path": "gateway/status.py", + "lines": 391, + "sloc": 313 + }, + { + "path": "tools/credential_files.py", + "lines": 404, + "sloc": 312 + }, + { + "path": "tests/test_primary_runtime_restore.py", + "lines": 424, + "sloc": 312 + }, + { + "path": "tests/gateway/test_platform_reconnect.py", + "lines": 427, + "sloc": 312 + }, + { + "path": "rl_cli.py", + "lines": 446, + "sloc": 310 + }, + { + "path": "tools/environments/singularity.py", + "lines": 390, + "sloc": 306 + }, + { + "path": "scripts/discord-voice-doctor.py", + "lines": 389, + "sloc": 305 + }, + { + "path": "tests/hermes_cli/test_config.py", + "lines": 379, + "sloc": 302 + }, + { + "path": "tests/tools/test_skill_manager_tool.py", + "lines": 413, + "sloc": 299 + }, + { + "path": "tests/tools/test_docker_environment.py", + "lines": 401, + "sloc": 296 + }, + { + "path": "tests/tools/test_process_registry.py", + "lines": 387, + "sloc": 293 + }, + { + "path": "tests/test_plugins.py", + "lines": 409, + "sloc": 292 + }, + { + "path": "scripts/sample_and_compress.py", + "lines": 411, + "sloc": 291 + }, + { + "path": "tests/tools/test_daytona_environment.py", + "lines": 414, + "sloc": 291 + }, + { + "path": "plugins/memory/hindsight/__init__.py", + "lines": 358, + "sloc": 290 + }, + { + "path": "plugins/memory/byterover/__init__.py", + "lines": 383, + "sloc": 288 + }, + { + "path": "tests/test_cli_init.py", + "lines": 347, + "sloc": 286 + }, + { + "path": "plugins/memory/mem0/__init__.py", + "lines": 353, + "sloc": 286 + }, + { + "path": "skills/productivity/google-workspace/scripts/setup.py", + "lines": 357, + "sloc": 285 + }, + { + "path": "optional-skills/productivity/memento-flashcards/scripts/memento_cards.py", + "lines": 353, + "sloc": 282 + }, + { + "path": "tests/agent/test_subagent_progress.py", + "lines": 374, + "sloc": 282 + }, + { + "path": "tests/hermes_cli/test_tools_config.py", + "lines": 383, + "sloc": 280 + }, + { + "path": "gateway/delivery.py", + "lines": 351, + "sloc": 279 + }, + { + "path": "tests/tools/test_checkpoint_manager.py", + "lines": 413, + "sloc": 279 + }, + { + "path": "hermes_cli/clipboard.py", + "lines": 360, + "sloc": 278 + }, + { + "path": "tests/gateway/test_reasoning_command.py", + "lines": 329, + "sloc": 278 + }, + { + "path": "tests/hermes_cli/test_mcp_config.py", + "lines": 400, + "sloc": 277 + }, + { + "path": "tests/gateway/test_session_hygiene.py", + "lines": 386, + "sloc": 275 + }, + { + "path": "toolset_distributions.py", + "lines": 364, + "sloc": 273 + }, + { + "path": "agent/memory_manager.py", + "lines": 335, + "sloc": 273 + }, + { + "path": "tests/test_plugins_cmd.py", + "lines": 409, + "sloc": 272 + }, + { + "path": "tests/tools/test_local_env_blocklist.py", + "lines": 321, + "sloc": 272 + }, + { + "path": "tests/test_timezone.py", + "lines": 376, + "sloc": 271 + }, + { + "path": "tests/test_agent_loop_vllm.py", + "lines": 359, + "sloc": 270 + }, + { + "path": "tests/tools/test_file_read_guards.py", + "lines": 378, + "sloc": 268 + }, + { + "path": "tests/agent/test_skill_commands.py", + "lines": 316, + "sloc": 268 + }, + { + "path": "optional-skills/security/oss-forensics/scripts/evidence-store.py", + "lines": 313, + "sloc": 265 + }, + { + "path": "tools/environments/ssh.py", + "lines": 306, + "sloc": 263 + }, + { + "path": "gateway/platforms/dingtalk.py", + "lines": 340, + "sloc": 263 + }, + { + "path": "tests/test_credential_pool_routing.py", + "lines": 350, + "sloc": 263 + }, + { + "path": "tests/tools/test_registry.py", + "lines": 311, + "sloc": 263 + }, + { + "path": "tests/gateway/test_discord_document_handling.py", + "lines": 350, + "sloc": 263 + }, + { + "path": "tests/tools/test_managed_modal_environment.py", + "lines": 327, + "sloc": 260 + }, + { + "path": "tests/tools/test_file_operations.py", + "lines": 335, + "sloc": 259 + }, + { + "path": "tests/hermes_cli/test_skin_engine.py", + "lines": 314, + "sloc": 259 + }, + { + "path": "tests/gateway/test_signal.py", + "lines": 370, + "sloc": 255 + }, + { + "path": "tests/gateway/test_webhook_integration.py", + "lines": 337, + "sloc": 254 + }, + { + "path": "tests/tools/test_file_tools.py", + "lines": 314, + "sloc": 253 + }, + { + "path": "tests/gateway/test_discord_free_response.py", + "lines": 360, + "sloc": 253 + }, + { + "path": "tests/integration/test_ha_integration.py", + "lines": 341, + "sloc": 252 + }, + { + "path": "tests/acp/test_mcp_e2e.py", + "lines": 349, + "sloc": 250 + }, + { + "path": "plugins/memory/retaindb/__init__.py", + "lines": 302, + "sloc": 250 + }, + { + "path": "tests/tools/test_homeassistant_tool.py", + "lines": 373, + "sloc": 249 + }, + { + "path": "agent/skill_commands.py", + "lines": 297, + "sloc": 247 + }, + { + "path": "tests/hermes_cli/test_skills_config.py", + "lines": 314, + "sloc": 247 + }, + { + "path": "skills/research/polymarket/scripts/polymarket.py", + "lines": 284, + "sloc": 245 + }, + { + "path": "tests/gateway/test_pairing.py", + "lines": 356, + "sloc": 245 + }, + { + "path": "tests/tools/test_command_guards.py", + "lines": 351, + "sloc": 244 + }, + { + "path": "hermes_cli/callbacks.py", + "lines": 283, + "sloc": 243 + }, + { + "path": "tests/tools/test_managed_media_gateways.py", + "lines": 293, + "sloc": 243 + }, + { + "path": "tests/tools/test_modal_sandbox_fixes.py", + "lines": 316, + "sloc": 242 + }, + { + "path": "tests/tools/test_send_message_missing_platforms.py", + "lines": 334, + "sloc": 242 + }, + { + "path": "tools/environments/managed_modal.py", + "lines": 282, + "sloc": 241 + }, + { + "path": "tools/environments/daytona.py", + "lines": 299, + "sloc": 240 + }, + { + "path": "tests/gateway/test_matrix_voice.py", + "lines": 340, + "sloc": 240 + }, + { + "path": "hermes_cli/uninstall.py", + "lines": 326, + "sloc": 239 + }, + { + "path": "tests/test_auxiliary_config_bridge.py", + "lines": 307, + "sloc": 239 + }, + { + "path": "tests/acp/test_session.py", + "lines": 331, + "sloc": 239 + }, + { + "path": "tests/gateway/test_background_command.py", + "lines": 323, + "sloc": 237 + }, + { + "path": "tools/mcp_oauth.py", + "lines": 326, + "sloc": 236 + }, + { + "path": "tests/tools/test_mcp_oauth.py", + "lines": 337, + "sloc": 234 + }, + { + "path": "tools/skills_sync.py", + "lines": 295, + "sloc": 232 + }, + { + "path": "tools/browser_providers/browserbase.py", + "lines": 281, + "sloc": 229 + }, + { + "path": "tests/fakes/fake_ha_server.py", + "lines": 301, + "sloc": 229 + }, + { + "path": "tests/hermes_cli/test_mcp_tools_config.py", + "lines": 291, + "sloc": 227 + }, + { + "path": "hermes_cli/copilot_auth.py", + "lines": 294, + "sloc": 226 + }, + { + "path": "tests/test_model_tools_async_bridge.py", + "lines": 307, + "sloc": 226 + }, + { + "path": "tests/test_cli_status_bar.py", + "lines": 276, + "sloc": 226 + }, + { + "path": "tests/gateway/test_config.py", + "lines": 270, + "sloc": 226 + }, + { + "path": "tests/hermes_cli/test_setup.py", + "lines": 307, + "sloc": 225 + }, + { + "path": "tools/registry.py", + "lines": 275, + "sloc": 224 + }, + { + "path": "tests/tools/test_skills_hub_clawhub.py", + "lines": 260, + "sloc": 223 + }, + { + "path": "environments/terminal_test_env/terminal_test_env.py", + "lines": 292, + "sloc": 221 + }, + { + "path": "tests/agent/test_memory_plugin_e2e.py", + "lines": 299, + "sloc": 221 + }, + { + "path": "website/scripts/extract-skills.py", + "lines": 268, + "sloc": 220 + }, + { + "path": "tools/website_policy.py", + "lines": 283, + "sloc": 219 + }, + { + "path": "tests/test_model_provider_persistence.py", + "lines": 259, + "sloc": 219 + }, + { + "path": "gateway/pairing.py", + "lines": 284, + "sloc": 218 + }, + { + "path": "tests/gateway/test_extract_local_files.py", + "lines": 317, + "sloc": 218 + }, + { + "path": "tests/tools/test_patch_parser.py", + "lines": 255, + "sloc": 217 + }, + { + "path": "gateway/platforms/sms.py", + "lines": 276, + "sloc": 216 + }, + { + "path": "skills/productivity/powerpoint/scripts/clean.py", + "lines": 286, + "sloc": 216 + }, + { + "path": "tests/gateway/test_session_race_guard.py", + "lines": 340, + "sloc": 216 + }, + { + "path": "tests/test_tool_call_parsers.py", + "lines": 274, + "sloc": 215 + }, + { + "path": "tests/gateway/test_channel_directory.py", + "lines": 252, + "sloc": 215 + }, + { + "path": "tools/environments/persistent_shell.py", + "lines": 277, + "sloc": 214 + }, + { + "path": "hermes_cli/cron.py", + "lines": 265, + "sloc": 212 + }, + { + "path": "tests/test_codex_models.py", + "lines": 264, + "sloc": 212 + }, + { + "path": "tests/tools/test_browser_console.py", + "lines": 295, + "sloc": 212 + }, + { + "path": "tests/gateway/test_unauthorized_dm_behavior.py", + "lines": 255, + "sloc": 212 + }, + { + "path": "tools/todo_tool.py", + "lines": 268, + "sloc": 211 + }, + { + "path": "tests/test_1630_context_overflow_loop.py", + "lines": 268, + "sloc": 211 + }, + { + "path": "tests/tools/test_session_search.py", + "lines": 286, + "sloc": 210 + }, + { + "path": "tests/test_context_references.py", + "lines": 268, + "sloc": 207 + }, + { + "path": "tests/tools/test_web_tools_tavily.py", + "lines": 255, + "sloc": 207 + }, + { + "path": "tests/test_860_dedup.py", + "lines": 294, + "sloc": 206 + }, + { + "path": "agent/skill_utils.py", + "lines": 285, + "sloc": 205 + }, + { + "path": "tests/gateway/test_transcript_offset.py", + "lines": 267, + "sloc": 205 + }, + { + "path": "hermes_cli/webhook.py", + "lines": 260, + "sloc": 204 + }, + { + "path": "tests/gateway/test_async_memory_flush.py", + "lines": 249, + "sloc": 204 + }, + { + "path": "tests/tools/test_browser_homebrew_paths.py", + "lines": 259, + "sloc": 202 + }, + { + "path": "tests/integration/test_modal_terminal.py", + "lines": 301, + "sloc": 201 + }, + { + "path": "gateway/platforms/telegram_network.py", + "lines": 248, + "sloc": 200 + }, + { + "path": "hermes_cli/model_switch.py", + "lines": 244, + "sloc": 197 + }, + { + "path": "tests/test_agent_guardrails.py", + "lines": 263, + "sloc": 197 + }, + { + "path": "tests/tools/test_llm_content_none_guard.py", + "lines": 294, + "sloc": 196 + }, + { + "path": "tests/agent/test_redact.py", + "lines": 254, + "sloc": 196 + }, + { + "path": "tests/gateway/test_agent_cache.py", + "lines": 260, + "sloc": 196 + }, + { + "path": "tests/skills/test_google_oauth_setup.py", + "lines": 237, + "sloc": 192 + }, + { + "path": "tests/tools/test_memory_tool.py", + "lines": 260, + "sloc": 191 + }, + { + "path": "tests/gateway/test_dingtalk.py", + "lines": 274, + "sloc": 191 + }, + { + "path": "tests/skills/test_telephony_skill.py", + "lines": 229, + "sloc": 191 + }, + { + "path": "tests/tools/test_browser_camofox.py", + "lines": 295, + "sloc": 190 + }, + { + "path": "tests/gateway/test_sse_agent_cancel.py", + "lines": 280, + "sloc": 188 + }, + { + "path": "gateway/channel_directory.py", + "lines": 258, + "sloc": 187 + }, + { + "path": "tests/tools/test_browser_camofox_persistence.py", + "lines": 242, + "sloc": 187 + }, + { + "path": "tests/gateway/test_telegram_reply_mode.py", + "lines": 242, + "sloc": 186 + }, + { + "path": "tests/gateway/test_telegram_conflict.py", + "lines": 249, + "sloc": 184 + }, + { + "path": "tests/test_flush_memories_codex.py", + "lines": 222, + "sloc": 183 + }, + { + "path": "tests/test_context_pressure.py", + "lines": 248, + "sloc": 182 + }, + { + "path": "tests/gateway/test_background_process_notifications.py", + "lines": 245, + "sloc": 181 + }, + { + "path": "tests/hermes_cli/test_gateway.py", + "lines": 254, + "sloc": 180 + }, + { + "path": "tests/test_cli_new_session.py", + "lines": 222, + "sloc": 179 + }, + { + "path": "tests/hermes_cli/test_tool_token_estimation.py", + "lines": 283, + "sloc": 179 + }, + { + "path": "tests/gateway/test_mirror.py", + "lines": 229, + "sloc": 179 + }, + { + "path": "tests/gateway/test_run_progress_topics.py", + "lines": 219, + "sloc": 179 + }, + { + "path": "tests/acp/test_events.py", + "lines": 280, + "sloc": 176 + }, + { + "path": "tests/tools/test_modal_snapshot_isolation.py", + "lines": 222, + "sloc": 175 + }, + { + "path": "tests/gateway/test_resume_command.py", + "lines": 226, + "sloc": 175 + }, + { + "path": "tests/tools/test_file_staleness.py", + "lines": 241, + "sloc": 174 + }, + { + "path": "tests/gateway/test_discord_reactions.py", + "lines": 234, + "sloc": 174 + }, + { + "path": "environments/hermes_swe_env/hermes_swe_env.py", + "lines": 229, + "sloc": 173 + }, + { + "path": "agent/memory_provider.py", + "lines": 231, + "sloc": 173 + }, + { + "path": "tests/gateway/test_flush_memory_stale_guard.py", + "lines": 224, + "sloc": 173 + }, + { + "path": "tests/test_personality_none.py", + "lines": 212, + "sloc": 172 + }, + { + "path": "tests/tools/test_transcription.py", + "lines": 247, + "sloc": 172 + }, + { + "path": "tests/hermes_cli/test_tools_disable_enable.py", + "lines": 224, + "sloc": 171 + }, + { + "path": "agent/smart_model_routing.py", + "lines": 194, + "sloc": 169 + }, + { + "path": "acp_adapter/tools.py", + "lines": 215, + "sloc": 168 + }, + { + "path": "tests/tools/test_browser_ssrf_local.py", + "lines": 237, + "sloc": 167 + }, + { + "path": "tests/hermes_cli/test_copilot_auth.py", + "lines": 208, + "sloc": 167 + }, + { + "path": "tests/gateway/test_base_topic_sessions.py", + "lines": 222, + "sloc": 167 + }, + { + "path": "tests/tools/test_ssh_environment.py", + "lines": 218, + "sloc": 166 + }, + { + "path": "tests/gateway/test_send_retry.py", + "lines": 231, + "sloc": 166 + }, + { + "path": "tests/acp/test_tools.py", + "lines": 236, + "sloc": 165 + }, + { + "path": "tests/tools/test_mcp_probe.py", + "lines": 210, + "sloc": 165 + }, + { + "path": "skills/mlops/training/grpo-rl-training/templates/basic_grpo_training.py", + "lines": 228, + "sloc": 164 + }, + { + "path": "tests/gateway/test_hooks.py", + "lines": 222, + "sloc": 164 + }, + { + "path": "plugins/memory/__init__.py", + "lines": 213, + "sloc": 164 + }, + { + "path": "tests/tools/test_skill_size_limits.py", + "lines": 215, + "sloc": 161 + }, + { + "path": "tests/gateway/test_title_command.py", + "lines": 208, + "sloc": 161 + }, + { + "path": "tests/test_interactive_interrupt.py", + "lines": 203, + "sloc": 160 + }, + { + "path": "tests/agent/test_models_dev.py", + "lines": 197, + "sloc": 160 + }, + { + "path": "tests/gateway/test_session_dm_thread_seeding.py", + "lines": 221, + "sloc": 159 + }, + { + "path": "tests/test_display.py", + "lines": 202, + "sloc": 158 + }, + { + "path": "tests/hermes_cli/test_webhook_cli.py", + "lines": 189, + "sloc": 158 + }, + { + "path": "tests/hermes_cli/test_skills_hub.py", + "lines": 233, + "sloc": 158 + }, + { + "path": "tests/test_long_context_tier_429.py", + "lines": 209, + "sloc": 157 + }, + { + "path": "tests/gateway/test_sms.py", + "lines": 215, + "sloc": 157 + }, + { + "path": "gateway/stream_consumer.py", + "lines": 202, + "sloc": 155 + }, + { + "path": "tests/test_quick_commands.py", + "lines": 188, + "sloc": 155 + }, + { + "path": "tests/gateway/test_session_reset_notify.py", + "lines": 207, + "sloc": 155 + }, + { + "path": "tests/tools/test_env_passthrough.py", + "lines": 199, + "sloc": 154 + }, + { + "path": "tests/test_codex_execution_paths.py", + "lines": 183, + "sloc": 152 + }, + { + "path": "tests/e2e/test_telegram_commands.py", + "lines": 217, + "sloc": 152 + }, + { + "path": "tests/test_compression_boundary.py", + "lines": 199, + "sloc": 147 + }, + { + "path": "tests/tools/test_clarify_tool.py", + "lines": 195, + "sloc": 147 + }, + { + "path": "hermes_cli/codex_models.py", + "lines": 176, + "sloc": 145 + }, + { + "path": "hermes_cli/skills_config.py", + "lines": 188, + "sloc": 144 + }, + { + "path": "skills/productivity/powerpoint/scripts/office/helpers/simplify_redlines.py", + "lines": 197, + "sloc": 144 + }, + { + "path": "tests/test_openai_client_lifecycle.py", + "lines": 189, + "sloc": 144 + }, + { + "path": "hermes_cli/curses_ui.py", + "lines": 172, + "sloc": 143 + }, + { + "path": "plugins/memory/holographic/holographic.py", + "lines": 203, + "sloc": 143 + }, + { + "path": "tests/test_branch_command.py", + "lines": 198, + "sloc": 142 + }, + { + "path": "tests/honcho_plugin/test_session.py", + "lines": 189, + "sloc": 142 + }, + { + "path": "tests/tools/test_interrupt.py", + "lines": 224, + "sloc": 142 + }, + { + "path": "tests/hermes_cli/test_skills_skip_confirm.py", + "lines": 174, + "sloc": 142 + }, + { + "path": "skills/productivity/powerpoint/scripts/office/helpers/merge_runs.py", + "lines": 199, + "sloc": 141 + }, + { + "path": "tests/test_real_interrupt_subagent.py", + "lines": 186, + "sloc": 141 + }, + { + "path": "tests/tools/test_url_safety.py", + "lines": 176, + "sloc": 141 + }, + { + "path": "tests/tools/test_browser_secret_exfil.py", + "lines": 186, + "sloc": 141 + }, + { + "path": "skills/productivity/powerpoint/scripts/add_slide.py", + "lines": 195, + "sloc": 140 + }, + { + "path": "tests/test_compression_persistence.py", + "lines": 202, + "sloc": 140 + }, + { + "path": "tools/environments/modal_common.py", + "lines": 178, + "sloc": 139 + }, + { + "path": "skills/leisure/find-nearby/scripts/find_nearby.py", + "lines": 184, + "sloc": 139 + }, + { + "path": "tests/test_auth_codex_provider.py", + "lines": 192, + "sloc": 139 + }, + { + "path": "tests/test_crossloop_client_cache.py", + "lines": 186, + "sloc": 138 + }, + { + "path": "tests/tools/test_terminal_requirements.py", + "lines": 175, + "sloc": 138 + }, + { + "path": "tests/hermes_cli/test_path_completion.py", + "lines": 184, + "sloc": 137 + }, + { + "path": "tests/gateway/test_telegram_thread_fallback.py", + "lines": 199, + "sloc": 137 + }, + { + "path": "tests/agent/test_external_skills.py", + "lines": 157, + "sloc": 135 + }, + { + "path": "tests/tools/test_skill_improvements.py", + "lines": 174, + "sloc": 133 + }, + { + "path": "tests/gateway/test_media_extraction.py", + "lines": 184, + "sloc": 132 + }, + { + "path": "agent/models_dev.py", + "lines": 172, + "sloc": 131 + }, + { + "path": "tests/tools/test_search_hidden_dirs.py", + "lines": 170, + "sloc": 131 + }, + { + "path": "tools/managed_tool_gateway.py", + "lines": 167, + "sloc": 130 + }, + { + "path": "tests/test_cli_context_warning.py", + "lines": 161, + "sloc": 130 + }, + { + "path": "tests/tools/test_local_persistent.py", + "lines": 164, + "sloc": 130 + }, + { + "path": "tests/test_evidence_store.py", + "lines": 186, + "sloc": 129 + }, + { + "path": "tests/test_provider_fallback.py", + "lines": 156, + "sloc": 129 + }, + { + "path": "tests/test_managed_server_tool_support.py", + "lines": 178, + "sloc": 129 + }, + { + "path": "gateway/hooks.py", + "lines": 170, + "sloc": 127 + }, + { + "path": "skills/productivity/powerpoint/scripts/office/pack.py", + "lines": 159, + "sloc": 127 + }, + { + "path": "tests/e2e/conftest.py", + "lines": 173, + "sloc": 126 + }, + { + "path": "tests/tools/test_symlink_prefix_confusion.py", + "lines": 172, + "sloc": 126 + }, + { + "path": "tests/test_auth_nous_provider.py", + "lines": 156, + "sloc": 125 + }, + { + "path": "tests/test_cli_interrupt_subagent.py", + "lines": 172, + "sloc": 125 + }, + { + "path": "tests/test_setup_model_selection.py", + "lines": 155, + "sloc": 125 + }, + { + "path": "tests/gateway/test_pii_redaction.py", + "lines": 156, + "sloc": 125 + }, + { + "path": "tests/test_cli_prefix_matching.py", + "lines": 160, + "sloc": 124 + }, + { + "path": "acp_adapter/events.py", + "lines": 171, + "sloc": 123 + }, + { + "path": "tests/tools/test_mcp_dynamic_discovery.py", + "lines": 170, + "sloc": 123 + }, + { + "path": "agent/redact.py", + "lines": 176, + "sloc": 122 + }, + { + "path": "optional-skills/productivity/canvas/scripts/canvas_api.py", + "lines": 157, + "sloc": 122 + }, + { + "path": "tests/run_interrupt_test.py", + "lines": 147, + "sloc": 121 + }, + { + "path": "tests/test_surrogate_sanitization.py", + "lines": 154, + "sloc": 121 + }, + { + "path": "tests/gateway/test_status.py", + "lines": 157, + "sloc": 121 + }, + { + "path": "tests/agent/test_title_generator.py", + "lines": 160, + "sloc": 120 + }, + { + "path": "tests/hermes_cli/test_set_config_value.py", + "lines": 167, + "sloc": 120 + }, + { + "path": "tests/test_interrupt_propagation.py", + "lines": 161, + "sloc": 119 + }, + { + "path": "tests/test_cli_file_drop.py", + "lines": 176, + "sloc": 119 + }, + { + "path": "tests/test_cli_extension_hooks.py", + "lines": 138, + "sloc": 118 + }, + { + "path": "tests/gateway/test_telegram_network_reconnect.py", + "lines": 162, + "sloc": 118 + }, + { + "path": "tests/test_batch_runner_checkpoint.py", + "lines": 159, + "sloc": 117 + }, + { + "path": "tests/test_async_httpx_del_neuter.py", + "lines": 162, + "sloc": 117 + }, + { + "path": "tests/test_percentage_clamp.py", + "lines": 154, + "sloc": 117 + }, + { + "path": "tests/gateway/test_queue_consumption.py", + "lines": 165, + "sloc": 116 + }, + { + "path": "tests/agent/test_prompt_caching.py", + "lines": 143, + "sloc": 115 + }, + { + "path": "tests/hermes_cli/test_setup_noninteractive.py", + "lines": 139, + "sloc": 115 + }, + { + "path": "environments/tool_call_parsers/qwen3_coder_parser.py", + "lines": 163, + "sloc": 114 + }, + { + "path": "hermes_cli/checklist.py", + "lines": 140, + "sloc": 114 + }, + { + "path": "tests/tools/test_ansi_strip.py", + "lines": 168, + "sloc": 114 + }, + { + "path": "tests/hermes_cli/test_update_check.py", + "lines": 173, + "sloc": 114 + }, + { + "path": "tests/test_atomic_json_write.py", + "lines": 159, + "sloc": 113 + }, + { + "path": "tests/test_cli_secret_capture.py", + "lines": 147, + "sloc": 113 + }, + { + "path": "tests/gateway/test_config_cwd_bridge.py", + "lines": 148, + "sloc": 112 + }, + { + "path": "tests/gateway/test_verbose_command.py", + "lines": 146, + "sloc": 112 + }, + { + "path": "tools/clarify_tool.py", + "lines": 141, + "sloc": 111 + }, + { + "path": "tests/gateway/test_status_command.py", + "lines": 130, + "sloc": 110 + }, + { + "path": "tests/test_toolsets.py", + "lines": 143, + "sloc": 109 + }, + { + "path": "tests/gateway/test_plan_command.py", + "lines": 129, + "sloc": 107 + }, + { + "path": "tests/tools/test_skill_env_passthrough.py", + "lines": 134, + "sloc": 106 + }, + { + "path": "tests/gateway/test_document_cache.py", + "lines": 157, + "sloc": 106 + }, + { + "path": "gateway/mirror.py", + "lines": 132, + "sloc": 105 + }, + { + "path": "utils.py", + "lines": 126, + "sloc": 104 + }, + { + "path": "environments/tool_call_parsers/mistral_parser.py", + "lines": 135, + "sloc": 104 + }, + { + "path": "tests/gateway/test_interrupt_key_match.py", + "lines": 150, + "sloc": 104 + }, + { + "path": "tests/test_worktree_security.py", + "lines": 130, + "sloc": 103 + }, + { + "path": "tests/agent/test_display_emoji.py", + "lines": 123, + "sloc": 103 + }, + { + "path": "tests/gateway/test_whatsapp_group_gating.py", + "lines": 142, + "sloc": 103 + }, + { + "path": "tests/gateway/test_step_callback_compat.py", + "lines": 133, + "sloc": 103 + }, + { + "path": "tests/test_file_permissions.py", + "lines": 135, + "sloc": 102 + }, + { + "path": "tests/test_config_env_expansion.py", + "lines": 132, + "sloc": 101 + }, + { + "path": "tests/test_cli_preloaded_skills.py", + "lines": 127, + "sloc": 101 + }, + { + "path": "tests/tools/test_rl_training_tool.py", + "lines": 142, + "sloc": 101 + }, + { + "path": "tests/agent/test_usage_pricing.py", + "lines": 125, + "sloc": 101 + }, + { + "path": "tests/gateway/test_sticker_cache.py", + "lines": 127, + "sloc": 101 + }, + { + "path": "skills/media/youtube-content/scripts/fetch_transcript.py", + "lines": 124, + "sloc": 99 + }, + { + "path": "tests/hermes_cli/test_doctor.py", + "lines": 138, + "sloc": 99 + }, + { + "path": "tests/gateway/test_api_server_toolset.py", + "lines": 129, + "sloc": 99 + }, + { + "path": "tests/hermes_cli/test_status_model_provider.py", + "lines": 124, + "sloc": 97 + }, + { + "path": "tests/hermes_cli/test_models.py", + "lines": 126, + "sloc": 97 + }, + { + "path": "agent/title_generator.py", + "lines": 125, + "sloc": 96 + }, + { + "path": "tests/test_cli_tools_command.py", + "lines": 130, + "sloc": 96 + }, + { + "path": "tests/skills/test_youtube_quiz.py", + "lines": 128, + "sloc": 96 + }, + { + "path": "skills/research/arxiv/scripts/search_arxiv.py", + "lines": 114, + "sloc": 94 + }, + { + "path": "tests/test_context_token_tracking.py", + "lines": 127, + "sloc": 94 + }, + { + "path": "tests/tools/test_debug_helpers.py", + "lines": 117, + "sloc": 94 + }, + { + "path": "tests/gateway/test_discord_bot_filter.py", + "lines": 117, + "sloc": 94 + }, + { + "path": "tests/gateway/test_session_info.py", + "lines": 110, + "sloc": 93 + }, + { + "path": "tests/conftest.py", + "lines": 119, + "sloc": 92 + }, + { + "path": "tests/tools/test_mcp_stability.py", + "lines": 143, + "sloc": 92 + }, + { + "path": "tests/skills/test_google_workspace_api.py", + "lines": 117, + "sloc": 91 + }, + { + "path": "hermes_time.py", + "lines": 120, + "sloc": 90 + }, + { + "path": "skills/creative/excalidraw/scripts/upload.py", + "lines": 133, + "sloc": 90 + }, + { + "path": "tests/hermes_cli/test_cron.py", + "lines": 107, + "sloc": 90 + }, + { + "path": "tests/hermes_cli/test_skills_install_flags.py", + "lines": 128, + "sloc": 90 + }, + { + "path": "tests/hermes_cli/test_cmd_update.py", + "lines": 128, + "sloc": 89 + }, + { + "path": "environments/benchmarks/tblite/tblite_env.py", + "lines": 119, + "sloc": 88 + }, + { + "path": "tests/test_session_reset_fix.py", + "lines": 121, + "sloc": 88 + }, + { + "path": "tests/integration/test_daytona_terminal.py", + "lines": 123, + "sloc": 88 + }, + { + "path": "tests/integration/test_batch_runner.py", + "lines": 132, + "sloc": 88 + }, + { + "path": "tests/hermes_cli/test_gateway_linger.py", + "lines": 120, + "sloc": 88 + }, + { + "path": "gateway/sticker_cache.py", + "lines": 111, + "sloc": 87 + }, + { + "path": "skills/productivity/ocr-and-documents/scripts/extract_pymupdf.py", + "lines": 98, + "sloc": 87 + }, + { + "path": "tests/tools/test_todo_tool.py", + "lines": 107, + "sloc": 87 + }, + { + "path": "tools/browser_providers/browser_use.py", + "lines": 107, + "sloc": 86 + }, + { + "path": "tests/test_trajectory_compressor_async.py", + "lines": 115, + "sloc": 86 + }, + { + "path": "tests/gateway/test_telegram_text_batching.py", + "lines": 121, + "sloc": 86 + }, + { + "path": "agent/builtin_memory_provider.py", + "lines": 113, + "sloc": 85 + }, + { + "path": "tests/tools/test_managed_tool_gateway.py", + "lines": 101, + "sloc": 85 + }, + { + "path": "tests/tools/test_skill_view_path_check.py", + "lines": 116, + "sloc": 85 + }, + { + "path": "tests/hermes_cli/test_sessions_delete.py", + "lines": 117, + "sloc": 85 + }, + { + "path": "environments/tool_call_parsers/__init__.py", + "lines": 120, + "sloc": 84 + }, + { + "path": "environments/tool_call_parsers/glm45_parser.py", + "lines": 109, + "sloc": 83 + }, + { + "path": "tools/debug_helpers.py", + "lines": 104, + "sloc": 83 + }, + { + "path": "tests/hermes_cli/test_coalesce_session_args.py", + "lines": 113, + "sloc": 83 + }, + { + "path": "tests/test_cli_approval_ui.py", + "lines": 100, + "sloc": 81 + }, + { + "path": "tests/tools/test_yolo_mode.py", + "lines": 110, + "sloc": 81 + }, + { + "path": "tests/gateway/test_telegram_group_gating.py", + "lines": 110, + "sloc": 81 + }, + { + "path": "hermes_cli/pairing.py", + "lines": 97, + "sloc": 79 + }, + { + "path": "tests/gateway/test_whatsapp_reply_prefix.py", + "lines": 121, + "sloc": 79 + }, + { + "path": "tests/gateway/test_gateway_shutdown.py", + "lines": 107, + "sloc": 79 + }, + { + "path": "hermes_constants.py", + "lines": 105, + "sloc": 78 + }, + { + "path": "tools/neutts_synth.py", + "lines": 104, + "sloc": 78 + }, + { + "path": "tools/environments/base.py", + "lines": 99, + "sloc": 78 + }, + { + "path": "tests/test_toolset_distributions.py", + "lines": 103, + "sloc": 78 + }, + { + "path": "tests/gateway/test_retry_replacement.py", + "lines": 97, + "sloc": 77 + }, + { + "path": "tests/tools/test_browser_cleanup.py", + "lines": 96, + "sloc": 76 + }, + { + "path": "tests/hermes_cli/test_nous_subscription.py", + "lines": 96, + "sloc": 76 + }, + { + "path": "tests/test_honcho_client_config.py", + "lines": 105, + "sloc": 75 + }, + { + "path": "tests/test_cli_skin_integration.py", + "lines": 98, + "sloc": 75 + }, + { + "path": "tests/tools/test_browser_content_none_guard.py", + "lines": 109, + "sloc": 75 + }, + { + "path": "tests/gateway/test_discord_system_messages.py", + "lines": 99, + "sloc": 75 + }, + { + "path": "tests/gateway/test_delivery.py", + "lines": 96, + "sloc": 72 + }, + { + "path": "tools/env_passthrough.py", + "lines": 99, + "sloc": 71 + }, + { + "path": "tests/test_cli_mcp_config_watch.py", + "lines": 103, + "sloc": 71 + }, + { + "path": "tests/test_cli_background_tui_refresh.py", + "lines": 105, + "sloc": 71 + }, + { + "path": "tests/gateway/test_runner_fatal_adapter.py", + "lines": 96, + "sloc": 71 + }, + { + "path": "skills/productivity/ocr-and-documents/scripts/extract_marker.py", + "lines": 87, + "sloc": 70 + }, + { + "path": "tests/tools/test_config_null_guard.py", + "lines": 111, + "sloc": 70 + }, + { + "path": "environments/tool_call_parsers/kimi_k2_parser.py", + "lines": 93, + "sloc": 68 + }, + { + "path": "tools/tool_backend_helpers.py", + "lines": 89, + "sloc": 68 + }, + { + "path": "optional-skills/productivity/memento-flashcards/scripts/youtube_quiz.py", + "lines": 88, + "sloc": 68 + }, + { + "path": "tests/test_model_tools.py", + "lines": 103, + "sloc": 68 + }, + { + "path": "tests/tools/test_hidden_dir_filter.py", + "lines": 95, + "sloc": 68 + }, + { + "path": "tests/tools/test_mixture_of_agents_tool.py", + "lines": 82, + "sloc": 68 + }, + { + "path": "environments/tool_call_parsers/llama_parser.py", + "lines": 96, + "sloc": 67 + }, + { + "path": "environments/tool_call_parsers/deepseek_v3_parser.py", + "lines": 89, + "sloc": 67 + }, + { + "path": "tools/url_safety.py", + "lines": 96, + "sloc": 67 + }, + { + "path": "tests/test_compressor_fallback_update.py", + "lines": 91, + "sloc": 67 + }, + { + "path": "tests/gateway/test_webhook_dynamic_routes.py", + "lines": 87, + "sloc": 67 + }, + { + "path": "tests/gateway/test_runner_startup_failures.py", + "lines": 89, + "sloc": 67 + }, + { + "path": "gateway/builtin_hooks/boot_md.py", + "lines": 86, + "sloc": 66 + }, + { + "path": "tests/gateway/test_ssl_certs.py", + "lines": 81, + "sloc": 66 + }, + { + "path": "tests/test_session_meta_filtering.py", + "lines": 90, + "sloc": 65 + }, + { + "path": "acp_adapter/entry.py", + "lines": 86, + "sloc": 64 + }, + { + "path": "tests/gateway/test_discord_thread_persistence.py", + "lines": 83, + "sloc": 64 + }, + { + "path": "tests/tools/test_parse_env_var.py", + "lines": 86, + "sloc": 63 + }, + { + "path": "tests/gateway/test_discord_send.py", + "lines": 80, + "sloc": 63 + }, + { + "path": "tests/tools/test_windows_compat.py", + "lines": 80, + "sloc": 62 + }, + { + "path": "tests/tools/test_mcp_tool_issue_948.py", + "lines": 86, + "sloc": 62 + }, + { + "path": "acp_adapter/permissions.py", + "lines": 77, + "sloc": 61 + }, + { + "path": "tests/test_cli_save_config_value.py", + "lines": 80, + "sloc": 61 + }, + { + "path": "tests/tools/test_skill_view_traversal.py", + "lines": 83, + "sloc": 61 + }, + { + "path": "tests/tools/test_write_deny.py", + "lines": 83, + "sloc": 59 + }, + { + "path": "optional-skills/mcp/fastmcp/templates/database_server.py", + "lines": 77, + "sloc": 58 + }, + { + "path": "tests/hermes_cli/test_banner.py", + "lines": 70, + "sloc": 58 + }, + { + "path": "tests/test_dict_tool_call_args.py", + "lines": 72, + "sloc": 57 + }, + { + "path": "tests/tools/test_singularity_preflight.py", + "lines": 77, + "sloc": 57 + }, + { + "path": "tests/tools/test_file_write_safety.py", + "lines": 83, + "sloc": 57 + }, + { + "path": "tests/tools/test_force_dangerous_override.py", + "lines": 81, + "sloc": 57 + }, + { + "path": "tests/gateway/test_stt_config.py", + "lines": 77, + "sloc": 57 + }, + { + "path": "tests/test_exit_cleanup_interrupt.py", + "lines": 73, + "sloc": 56 + }, + { + "path": "tests/hermes_cli/test_chat_skills_flag.py", + "lines": 77, + "sloc": 56 + }, + { + "path": "environments/tool_call_parsers/longcat_parser.py", + "lines": 69, + "sloc": 55 + }, + { + "path": "environments/tool_call_parsers/hermes_parser.py", + "lines": 73, + "sloc": 55 + }, + { + "path": "environments/tool_call_parsers/deepseek_v3_1_parser.py", + "lines": 72, + "sloc": 54 + }, + { + "path": "agent/prompt_caching.py", + "lines": 72, + "sloc": 54 + }, + { + "path": "tests/test_cli_loading_indicator.py", + "lines": 65, + "sloc": 53 + }, + { + "path": "tests/acp/test_permissions.py", + "lines": 75, + "sloc": 53 + }, + { + "path": "tests/tools/test_fuzzy_match.py", + "lines": 67, + "sloc": 53 + }, + { + "path": "tests/gateway/test_retry_response.py", + "lines": 60, + "sloc": 53 + }, + { + "path": "tests/test_cli_plan_command.py", + "lines": 67, + "sloc": 51 + }, + { + "path": "tests/test_token_persistence_non_cli.py", + "lines": 62, + "sloc": 49 + }, + { + "path": "tests/tools/test_delegate_toolset_scope.py", + "lines": 66, + "sloc": 49 + }, + { + "path": "tests/hermes_cli/test_env_loader.py", + "lines": 70, + "sloc": 49 + }, + { + "path": "tests/tools/test_browser_camofox_state.py", + "lines": 66, + "sloc": 48 + }, + { + "path": "tests/tools/test_terminal_tool_requirements.py", + "lines": 56, + "sloc": 47 + }, + { + "path": "tests/hermes_cli/test_banner_skills.py", + "lines": 68, + "sloc": 47 + }, + { + "path": "tests/agent/test_smart_model_routing.py", + "lines": 61, + "sloc": 46 + }, + { + "path": "tests/tools/test_terminal_disk_usage.py", + "lines": 73, + "sloc": 45 + }, + { + "path": "tools/browser_providers/base.py", + "lines": 59, + "sloc": 44 + }, + { + "path": "agent/trajectory.py", + "lines": 56, + "sloc": 44 + }, + { + "path": "tests/acp/test_auth.py", + "lines": 56, + "sloc": 44 + }, + { + "path": "optional-skills/mcp/fastmcp/templates/file_processor.py", + "lines": 55, + "sloc": 41 + }, + { + "path": "tests/test_external_credential_detection.py", + "lines": 50, + "sloc": 41 + }, + { + "path": "tests/test_anthropic_oauth_flow.py", + "lines": 51, + "sloc": 40 + }, + { + "path": "optional-skills/mcp/fastmcp/scripts/scaffold_fastmcp.py", + "lines": 56, + "sloc": 39 + }, + { + "path": "tests/test_redirect_stdout_issue.py", + "lines": 54, + "sloc": 38 + }, + { + "path": "tests/gateway/test_telegram_photo_interrupts.py", + "lines": 49, + "sloc": 38 + }, + { + "path": "tools/browser_camofox_state.py", + "lines": 47, + "sloc": 37 + }, + { + "path": "cron/__init__.py", + "lines": 42, + "sloc": 37 + }, + { + "path": "optional-skills/mcp/fastmcp/templates/api_wrapper.py", + "lines": 54, + "sloc": 37 + }, + { + "path": "tests/hermes_cli/test_profile_export_credentials.py", + "lines": 52, + "sloc": 37 + }, + { + "path": "tests/gateway/test_allowlist_startup_check.py", + "lines": 46, + "sloc": 37 + }, + { + "path": "tests/test_cli_retry.py", + "lines": 49, + "sloc": 36 + }, + { + "path": "tests/hermes_cli/test_subprocess_timeouts.py", + "lines": 44, + "sloc": 36 + }, + { + "path": "tools/ansi_strip.py", + "lines": 44, + "sloc": 35 + }, + { + "path": "tests/tools/test_docker_find.py", + "lines": 48, + "sloc": 35 + }, + { + "path": "tests/hermes_cli/test_managed_installs.py", + "lines": 54, + "sloc": 35 + }, + { + "path": "tests/gateway/test_session_env.py", + "lines": 45, + "sloc": 34 + }, + { + "path": "tests/gateway/test_discord_opus.py", + "lines": 44, + "sloc": 34 + }, + { + "path": "hermes_cli/env_loader.py", + "lines": 45, + "sloc": 33 + }, + { + "path": "tests/tools/test_cron_prompt_injection.py", + "lines": 48, + "sloc": 33 + }, + { + "path": "tests/test_sql_injection.py", + "lines": 43, + "sloc": 32 + }, + { + "path": "tests/tools/test_browser_cdp_override.py", + "lines": 47, + "sloc": 32 + }, + { + "path": "tests/hermes_cli/test_placeholder_usage.py", + "lines": 48, + "sloc": 31 + }, + { + "path": "hermes_cli/colors.py", + "lines": 38, + "sloc": 30 + }, + { + "path": "tests/test_anthropic_provider_persistence.py", + "lines": 46, + "sloc": 30 + }, + { + "path": "tests/test_atomic_yaml_write.py", + "lines": 44, + "sloc": 30 + }, + { + "path": "gateway/__init__.py", + "lines": 35, + "sloc": 29 + }, + { + "path": "skills/red-teaming/godmode/scripts/load_godmode.py", + "lines": 45, + "sloc": 29 + }, + { + "path": "environments/__init__.py", + "lines": 36, + "sloc": 28 + }, + { + "path": "tests/hermes_cli/test_launcher.py", + "lines": 42, + "sloc": 27 + }, + { + "path": "environments/patches.py", + "lines": 35, + "sloc": 25 + }, + { + "path": "environments/tool_call_parsers/glm47_parser.py", + "lines": 35, + "sloc": 25 + }, + { + "path": "tools/openrouter_client.py", + "lines": 33, + "sloc": 25 + }, + { + "path": "tests/hermes_cli/test_skills_subparser.py", + "lines": 35, + "sloc": 23 + }, + { + "path": "tests/tools/test_terminal_timeout_output.py", + "lines": 27, + "sloc": 21 + }, + { + "path": "tools/interrupt.py", + "lines": 28, + "sloc": 20 + }, + { + "path": "tests/test_utils_truthy_values.py", + "lines": 29, + "sloc": 19 + }, + { + "path": "acp_adapter/auth.py", + "lines": 24, + "sloc": 18 + }, + { + "path": "tests/hermes_cli/test_gateway_runtime_health.py", + "lines": 22, + "sloc": 18 + }, + { + "path": "tests/hermes_cli/test_setup_prompt_menus.py", + "lines": 29, + "sloc": 17 + }, + { + "path": "tests/test_project_metadata.py", + "lines": 22, + "sloc": 16 + }, + { + "path": "tests/gateway/test_discord_imports.py", + "lines": 23, + "sloc": 16 + }, + { + "path": "tools/__init__.py", + "lines": 25, + "sloc": 15 + }, + { + "path": "environments/tool_call_parsers/qwen_parser.py", + "lines": 19, + "sloc": 14 + }, + { + "path": "gateway/platforms/__init__.py", + "lines": 17, + "sloc": 14 + }, + { + "path": "hermes_cli/__init__.py", + "lines": 15, + "sloc": 13 + }, + { + "path": "tests/test_packaging_metadata.py", + "lines": 22, + "sloc": 13 + }, + { + "path": "tests/acp/test_entry.py", + "lines": 20, + "sloc": 12 + }, + { + "path": "hermes_cli/default_soul.py", + "lines": 11, + "sloc": 10 + }, + { + "path": "tools/environments/__init__.py", + "lines": 13, + "sloc": 9 + }, + { + "path": "tests/hermes_cli/test_status.py", + "lines": 14, + "sloc": 9 + }, + { + "path": "tools/browser_providers/__init__.py", + "lines": 10, + "sloc": 6 + }, + { + "path": "tests/gateway/test_discord_media_metadata.py", + "lines": 9, + "sloc": 6 + }, + { + "path": "agent/__init__.py", + "lines": 6, + "sloc": 5 + }, + { + "path": "acp_adapter/__main__.py", + "lines": 5, + "sloc": 3 + }, + { + "path": "acp_adapter/__init__.py", + "lines": 1, + "sloc": 1 + }, + { + "path": "gateway/builtin_hooks/__init__.py", + "lines": 1, + "sloc": 1 + }, + { + "path": "environments/benchmarks/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "environments/benchmarks/terminalbench_2/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "environments/benchmarks/yc_bench/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "environments/benchmarks/tblite/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "environments/hermes_swe_env/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "environments/terminal_test_env/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "skills/productivity/powerpoint/scripts/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "skills/productivity/powerpoint/scripts/office/helpers/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/test_minisweagent_path.py", + "lines": 2, + "sloc": 0 + }, + { + "path": "tests/acp/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/honcho_plugin/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/integration/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/e2e/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/tools/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/agent/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/hermes_cli/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/fakes/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/cron/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "tests/gateway/__init__.py", + "lines": 0, + "sloc": 0 + }, + { + "path": "plugins/__init__.py", + "lines": 1, + "sloc": 0 + } +] \ No newline at end of file diff --git a/docs/ouroboros/specs/SPEC.md b/docs/ouroboros/specs/SPEC.md new file mode 100644 index 000000000..5683959dc --- /dev/null +++ b/docs/ouroboros/specs/SPEC.md @@ -0,0 +1,263 @@ +# Hermes Ω Specification Draft (Ouroboros Phase I) + +> Auto-generated by Ezra as part of EPIC-999. This document is a living artifact. + +## Scope +This specification covers the core runtime of Hermes agent v0.7.x as found in the `hermes-agent` codebase. + +## High-Level Architecture + +``` +User Message + ↓ +Gateway (gateway/run.py) — platform adapter (Telegram, Discord, CLI, etc.) + ↓ +HermesCLI (cli.py) or AIAgent.chat() (run_agent.py) + ↓ +ModelTools (model_tools.py) — tool discovery, schema assembly, dispatch + ↓ +Tool Registry (tools/registry.py) — handler lookup, availability checks + ↓ +Individual Tool Implementations (tools/*.py) + ↓ +Results returned up the stack +``` + +## Module Specifications + +### `run_agent.py` +**Lines of Code:** 8948 + +**Classes:** +- `_SafeWriter` + - *Transparent stdio wrapper that catches OSError/ValueError from broken pipes.* + - `__init__(self, inner)` + - `write(self, data)` + - `flush(self)` + - `fileno(self)` + - `isatty(self)` + - ... and 1 more methods +- `IterationBudget` + - *Thread-safe iteration counter for an agent.* + - `__init__(self, max_total)` + - `consume(self)` + - `refund(self)` + - `used(self)` + - `remaining(self)` +- `AIAgent` + - *AI Agent with tool calling capabilities.* + - `base_url(self)` + - `base_url(self, value)` + - `__init__(self, base_url, api_key, provider, api_mode, acp_command, acp_args, command, args, model, max_iterations, tool_delay, enabled_toolsets, disabled_toolsets, save_trajectories, verbose_logging, quiet_mode, ephemeral_system_prompt, log_prefix_chars, log_prefix, providers_allowed, providers_ignored, providers_order, provider_sort, provider_require_parameters, provider_data_collection, session_id, tool_progress_callback, tool_start_callback, tool_complete_callback, thinking_callback, reasoning_callback, clarify_callback, step_callback, stream_delta_callback, tool_gen_callback, status_callback, max_tokens, reasoning_config, prefill_messages, platform, skip_context_files, skip_memory, session_db, iteration_budget, fallback_model, credential_pool, checkpoints_enabled, checkpoint_max_snapshots, pass_session_id, persist_session)` + - `reset_session_state(self)` + - `_safe_print(self)` + - ... and 100 more methods + +**Top-Level Functions:** +- `_install_safe_stdio()` +- `_is_destructive_command(cmd)` +- `_should_parallelize_tool_batch(tool_calls)` +- `_extract_parallel_scope_path(tool_name, function_args)` +- `_paths_overlap(left, right)` +- `_sanitize_surrogates(text)` +- `_sanitize_messages_surrogates(messages)` +- `_strip_budget_warnings_from_history(messages)` +- `main(query, model, api_key, base_url, max_turns, enabled_toolsets, disabled_toolsets, list_tools, save_trajectories, save_sample, verbose, log_prefix_chars)` + +**Inferred Side Effects & Invariants:** +- Persists state to SQLite database. +- Performs file I/O. +- Makes HTTP network calls. +- Uses global mutable state (risk factor). + +### `model_tools.py` +**Lines of Code:** 466 + +**Top-Level Functions:** +- `_get_tool_loop()` +- `_get_worker_loop()` +- `_run_async(coro)` +- `_discover_tools()` +- `get_tool_definitions(enabled_toolsets, disabled_toolsets, quiet_mode)` +- `handle_function_call(function_name, function_args, task_id, user_task, enabled_tools)` +- `get_all_tool_names()` +- `get_toolset_for_tool(tool_name)` +- `get_available_toolsets()` +- `check_toolset_requirements()` +- ... and 1 more functions + +**Inferred Side Effects & Invariants:** +- Uses global mutable state (risk factor). +- Primarily pure Python logic / orchestration. + +### `cli.py` +**Lines of Code:** 8280 + +**Classes:** +- `ChatConsole` + - *Rich Console adapter for prompt_toolkit's patch_stdout context.* + - `__init__(self)` + - `print(self)` +- `HermesCLI` + - *Interactive CLI for the Hermes Agent.* + - `__init__(self, model, toolsets, provider, api_key, base_url, max_turns, verbose, compact, resume, checkpoints, pass_session_id)` + - `_invalidate(self, min_interval)` + - `_status_bar_context_style(self, percent_used)` + - `_build_context_bar(self, percent_used, width)` + - `_get_status_bar_snapshot(self)` + - ... and 106 more methods + +**Top-Level Functions:** +- `_load_prefill_messages(file_path)` +- `_parse_reasoning_config(effort)` +- `load_cli_config()` +- `_run_cleanup()` +- `_git_repo_root()` +- `_path_is_within_root(path, root)` +- `_setup_worktree(repo_root)` +- `_cleanup_worktree(info)` +- `_prune_stale_worktrees(repo_root, max_age_hours)` +- `_accent_hex()` +- ... and 9 more functions + +**Inferred Side Effects & Invariants:** +- Persists state to SQLite database. +- Performs file I/O. +- Spawns subprocesses / shell commands. +- Uses global mutable state (risk factor). + +### `tools/registry.py` +**Lines of Code:** 275 + +**Classes:** +- `ToolEntry` + - *Metadata for a single registered tool.* + - `__init__(self, name, toolset, schema, handler, check_fn, requires_env, is_async, description, emoji)` +- `ToolRegistry` + - *Singleton registry that collects tool schemas + handlers from tool files.* + - `__init__(self)` + - `register(self, name, toolset, schema, handler, check_fn, requires_env, is_async, description, emoji)` + - `deregister(self, name)` + - `get_definitions(self, tool_names, quiet)` + - `dispatch(self, name, args)` + - ... and 10 more methods + +**Inferred Side Effects & Invariants:** +- Primarily pure Python logic / orchestration. + +### `gateway/run.py` +**Lines of Code:** 6657 + +**Classes:** +- `GatewayRunner` + - *Main gateway controller.* + - `__init__(self, config)` + - `_has_setup_skill(self)` + - `_load_voice_modes(self)` + - `_save_voice_modes(self)` + - `_set_adapter_auto_tts_disabled(self, adapter, chat_id, disabled)` + - ... and 78 more methods + +**Top-Level Functions:** +- `_ensure_ssl_certs()` +- `_normalize_whatsapp_identifier(value)` +- `_expand_whatsapp_auth_aliases(identifier)` +- `_resolve_runtime_agent_kwargs()` +- `_build_media_placeholder(event)` +- `_dequeue_pending_text(adapter, session_key)` +- `_check_unavailable_skill(command_name)` +- `_platform_config_key(platform)` +- `_load_gateway_config()` +- `_resolve_gateway_model(config)` +- ... and 4 more functions + +**Inferred Side Effects & Invariants:** +- Persists state to SQLite database. +- Performs file I/O. +- Spawns subprocesses / shell commands. +- Contains async code paths. +- Uses global mutable state (risk factor). + +### `hermes_state.py` +**Lines of Code:** 1270 + +**Classes:** +- `SessionDB` + - *SQLite-backed session storage with FTS5 search.* + - `__init__(self, db_path)` + - `_execute_write(self, fn)` + - `_try_wal_checkpoint(self)` + - `close(self)` + - `_init_schema(self)` + - ... and 29 more methods + +**Inferred Side Effects & Invariants:** +- Persists state to SQLite database. + +### `agent/context_compressor.py` +**Lines of Code:** 676 + +**Classes:** +- `ContextCompressor` + - *Compresses conversation context when approaching the model's context limit.* + - `__init__(self, model, threshold_percent, protect_first_n, protect_last_n, summary_target_ratio, quiet_mode, summary_model_override, base_url, api_key, config_context_length, provider)` + - `update_from_response(self, usage)` + - `should_compress(self, prompt_tokens)` + - `should_compress_preflight(self, messages)` + - `get_status(self)` + - ... and 11 more methods + +**Inferred Side Effects & Invariants:** +- Primarily pure Python logic / orchestration. + +### `agent/prompt_caching.py` +**Lines of Code:** 72 + +**Top-Level Functions:** +- `_apply_cache_marker(msg, cache_marker, native_anthropic)` +- `apply_anthropic_cache_control(api_messages, cache_ttl, native_anthropic)` + +**Inferred Side Effects & Invariants:** +- Primarily pure Python logic / orchestration. + +### `agent/skill_commands.py` +**Lines of Code:** 297 + +**Top-Level Functions:** +- `build_plan_path(user_instruction)` +- `_load_skill_payload(skill_identifier, task_id)` +- `_build_skill_message(loaded_skill, skill_dir, activation_note, user_instruction, runtime_note)` +- `scan_skill_commands()` +- `get_skill_commands()` +- `build_skill_invocation_message(cmd_key, user_instruction, task_id, runtime_note)` +- `build_preloaded_skills_prompt(skill_identifiers, task_id)` + +**Inferred Side Effects & Invariants:** +- Uses global mutable state (risk factor). +- Primarily pure Python logic / orchestration. + +## Cross-Module Dependencies + +Key data flow: +1. `run_agent.py` defines `AIAgent` — the canonical conversation loop. +2. `model_tools.py` assembles tool schemas and dispatches function calls. +3. `tools/registry.py` maintains the central registry; all tool files import it. +4. `gateway/run.py` adapts platform events into `AIAgent.run_conversation()` calls. +5. `cli.py` (`HermesCLI`) provides the interactive shell and slash-command routing. + +## Known Coupling Risks + +- `run_agent.py` is ~7k SLOC and contains the core loop, todo/memory interception, context compression, and trajectory saving. High blast radius. +- `cli.py` is ~6.5k SLOC and combines UI (Rich/prompt_toolkit), config loading, and command dispatch. Tightly coupled to display state. +- `model_tools.py` holds a process-global `_last_resolved_tool_names`. Subagent execution saves/restores this global. +- `tools/registry.py` is imported by ALL tool files; schema generation happens at import time. + +## Next Actions (Phase II Prep) + +1. Decompose `AIAgent` into: `ConversationLoop`, `ContextManager`, `ToolDispatcher`, `MemoryInterceptor`. +2. Extract CLI display logic from command dispatch. +3. Define strict interfaces between gateway → agent → tools. +4. Write property-based tests for the conversation loop invariant: *given the same message history and tool results, the agent must produce deterministic tool_call ordering*. + +--- +Generated: 2026-04-05 by Ezra (Phase I) \ No newline at end of file