Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions crates/vfs_cli_app/src/plugin_payload.rs
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,11 @@ pub const CLAUDE_PLUGIN_FILES: &[PayloadFile] = &[
];

pub const HERMES_PLUGIN_FILES: &[PayloadFile] = &[
PayloadFile {
path: "__init__.py",
content: include_str!("../../../plugins/hermes/__init__.py"),
executable: false,
},
PayloadFile {
path: "plugin.yaml",
content: include_str!("../../../plugins/hermes/plugin.yaml"),
Expand Down
8 changes: 8 additions & 0 deletions plugins/hermes/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
"""Where: plugins/hermes/__init__.py
What: Hermes plugin entrypoint shim for the Kinic adapter package.
Why: Hermes loads register(ctx) from the plugin root __init__.py.
"""

from .kinic_hermes import register

__all__ = ["register"]
3 changes: 2 additions & 1 deletion plugins/hermes/kinic_hermes/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@ def post_tool_call(self, tool_name: str, args: Any = None, result: Any = None, d
if skill_id:
self.buffer.skill_candidates.add(skill_id)

def transform_llm_output(self, output: str, **_: Any) -> str:
def transform_llm_output(self, response_text: str = "", **kwargs: Any) -> str:
output = response_text or str(kwargs.get("output", ""))
self.buffer.final_response = output
return output

Expand Down
7 changes: 7 additions & 0 deletions plugins/hermes/tests/test_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,13 @@ def test_skill_view_and_usage_diff_record_one_run(self) -> None:
self.assertEqual(records[0][1]["agent_outcome"], "unknown")
plugin.client.create_ready_jobs.assert_not_called()

def test_transform_llm_output_accepts_hermes_response_text_keyword(self) -> None:
import kinic_hermes as plugin_module

plugin = plugin_module.KinicPlugin()
self.assertEqual(plugin.transform_llm_output(response_text="done"), "done")
self.assertEqual(plugin.buffer.final_response, "done")

def test_register_tool_uses_hermes_keyword_api(self) -> None:
import kinic_hermes as plugin_module

Expand Down