The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
docs(parity): a refused Ink subcommand keeps the rest of the command routed
Tekniumbec207e9e4f0
diff --git a/scripts/gen_gateway_command_parity.py b/scripts/gen_gateway_command_parity.pyindex f482fdc2844..e9b90012c18 100755--- a/scripts/gen_gateway_command_parity.py+++ b/scripts/gen_gateway_command_parity.py@@ -113,6 +113,11 @@ def ink_cell(cmd, gateway, ink, served):return "slash.exec" if gateway != "refused" else "slash.exec: refused"_, block = entrymethods = set(re.findall(r"(?:rpc|request)(?:<[^>]*>)?\(\s*'([a-z_]+\.[a-z_.]+)'", block))+ refused = re.findall(r"notAvailable', '([\w-]+) ([\w-]+)'\)", block)+ if refused and "canonical.controls.notAvailable" not in re.sub(r"notAvailable', '[\w-]+ [\w-]+'\)", "", block):+ # Only named subcommands are refused (``/voice tts``); the rest of the command keeps its route.+ cell = _rpc_cell(methods, served) if methods else "local"+ return cell + "; " + ", ".join(f"`{sub}` refused" for _, sub in refused)if "canonical.controls.notAvailable" in block:# The shared gateway refuses it in the client (no owner verb yet), whatever it calls on a# standalone backend; never reported as a working route. A bare form that still reads thediff --git a/tests/hermes_cli/test_gateway_command_parity_live_session.py b/tests/hermes_cli/test_gateway_command_parity_live_session.pyindex 9dccc819d51..601365962fb 100644--- a/tests/hermes_cli/test_gateway_command_parity_live_session.py+++ b/tests/hermes_cli/test_gateway_command_parity_live_session.py@@ -18,3 +18,17 @@ def test_sidecar_live_session_rpc_is_reported_broken_on_the_shared_gateway():assert cell.startswith("**broken**"), cellassert "rollback.diff" in cell and "rollback.list" in cellassert "sidecar:" not in cell+++def test_a_refused_subcommand_keeps_the_rest_of_the_command_routed():+ """``/voice tts`` refuses on the shared gateway; ``/voice on|off|status`` still reach voice.toggle."""+ import sys+ sys.path.insert(0, str(ROOT))+ from hermes_cli.commands import COMMAND_REGISTRY+ spec = importlib.util.spec_from_file_location("gen_gateway_command_parity",+ ROOT / "scripts" / "gen_gateway_command_parity.py")+ gen = importlib.util.module_from_spec(spec)+ spec.loader.exec_module(gen)+ cmd = next(c for c in COMMAND_REGISTRY if c.name == "voice")+ cell = gen.ink_cell(cmd, gen.gateway_cell("voice"), gen._ink_commands(), gen._served_methods())+ assert cell == "sidecar: voice.toggle; `tts` refused"diff --git a/website/docs/developer-guide/gateway-command-parity.md b/website/docs/developer-guide/gateway-command-parity.mdindex c0377840d01..c72f6d5e4dd 100644--- a/website/docs/developer-guide/gateway-command-parity.md+++ b/website/docs/developer-guide/gateway-command-parity.md@@ -123,7 +123,7 @@ policy; `client-local (cli_only)` commands are terminal/UI features of a client.| `/usage` | read (bare only (`reset` refused)) | slash.exec + last-turn receipt | canonical route | slash.exec | refused | || `/verbose` | refused | refused: not available yet | config.set | unavailable: terminal | refused | port: per-session setting || `/version` (/v) | read | slash.exec | slash.exec | slash.exec | refused | |-| `/voice` | refused | refused: not available yet | sidecar: voice.toggle | unavailable: composer-voice | refused | port: per-session setting |+| `/voice` | refused | refused: not available yet | sidecar: voice.toggle; `tts` refused | unavailable: composer-voice | refused | port: per-session setting || `/wake` | refused | refused: not available yet | local | action: wake | refused | client-local (cli_only) || `/whoami` | read | slash.exec | slash.exec | slash.exec | refused | || `/worktree` | refused | refused: not available yet | slash.exec: refused | slash.exec: refused | refused | client-local (cli_only) |