New: add new plugin hermes_agent_chat-0.0.1.difypkg【Interact with your Hermes Agent】#2399
Open
sawyer-shi wants to merge 2 commits into
Open
New: add new plugin hermes_agent_chat-0.0.1.difypkg【Interact with your Hermes Agent】#2399sawyer-shi wants to merge 2 commits into
sawyer-shi wants to merge 2 commits into
Conversation
Contributor
Author
|
@crazywoola Please help to check it, Thansk a lot ! People truly need this type of plugins to extend and enhance the capabilities of the Dify platform. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hermes Agent Chat
A Dify tool plugin that connects Dify to a self-hosted Hermes Agent API Server through Hermes' OpenAI-compatible HTTP API. It supports text chat, conversation-level and user-level context retention, Dify uploaded image inputs, and interaction with Hermes Agent skills and tools.
Simplified Chinese documentation is provided through Dify Marketplace multilingual README support.
Version Information
Version History
GET /v1/models/v1/responsestool invocationinput_imageQuick Start
Edit
~/.hermes/.envand add or merge the following API Server configuration. ReplaceYOUR_HERMES_API_SERVER_KEYwith your own token:Start Hermes Gateway:
You should see a message similar to:
Install the plugin package in Dify.
Configure provider credentials in Dify:
Base URL: Hermes API Server base URL 【defaulthttp://127.0.0.1:8642/v1,orhttp://host.docker.internal:8642/v1】API Key: HermesAPI_SERVER_KEYModel: Hermes API Server model name, usuallyhermes-agentTimeout: optional request timeout, default600Choose a tool:
hermes_chat: conversation-level contexthermes_user_chat: user-level contextSend text, optionally with Dify uploaded image files.
Key Features
POST /v1/responsesto interact with Hermes Agent.GET /v1/models.filesimage objects and forwards them as base64input_imageinputs.session_key,conversation_id, oruser_idas LLM-controllable tool parameters.Core Features
1) Hermes Chat (
hermes_chat)Conversation-level Hermes context retention.
messageupload_filesfor images only2) Hermes User Chat (
hermes_user_chat)User-level Hermes context retention across Dify conversations.
messageupload_filesfor images onlyShared Input Support
input_textinput_imageHermes API Server Configuration
Before using this plugin, enable Hermes Agent API Server.
Required endpoint:
POST /v1/responsesRequired endpoint for Dify credential validation:
GET /v1/modelsOptional compatibility endpoint, not used by this plugin:
POST /v1/chat/completionsRecommended
.envfor Docker Desktop or controlled private-network access:If Dify and Hermes run in the same host process environment, loopback is enough:
Bind Address Notes
Use
API_SERVER_HOST=127.0.0.1when only local access is needed.Use
API_SERVER_HOST=0.0.0.0or a private interface address only when Docker, LAN, VPN, tailnet, or another private ingress needs to reach Hermes.Do not expose Hermes API Server directly to the public internet. The API server can access the agent's tools, so protect it with a strong
API_SERVER_KEYand private networking.Dify Provider Configuration
Base URLhttp://127.0.0.1:8642/v1/v1; the plugin normalizes it internally.API KeyYOUR_HERMES_API_SERVER_KEYAPI_SERVER_KEY.Modelhermes-agent/v1/models.Timeout6001-600; invalid values fall back to600.Base URL examples by deployment:
Base URLhttp://127.0.0.1:8642/v1API_SERVER_HOST=127.0.0.1http://host.docker.internal:8642/v1API_SERVER_HOST=0.0.0.0or host LAN/private addresshttp://<Hermes-host-LAN-IP>:8642/v1API_SERVER_HOST=0.0.0.0or Hermes host LAN IPhttp://<Hermes-private-name-or-IP>:8642/v1http://127.0.0.1:<local-port>/v1API_SERVER_HOST=127.0.0.1If Dify reports
Failed to establish a new connection,Connection refused, or provider validation timeout, the Dify plugin runtime cannot reach the configuredBase URL. The most common cause is usinghttp://127.0.0.1:8642/v1inside Docker while Hermes is running on the host loopback address.Tool Parameters
Both tools expose the same parameters.
messagellmSummarize this project.upload_filesllminput_imageResponses parts.The plugin does not expose session routing parameters as tool inputs. Hermes conversation keys are derived from Dify runtime metadata and sent through the Hermes Responses API
conversationfield withstore=true.Supported File Types
Supported uploaded image MIME types:
image/jpegimage/pngimage/gifimage/webpimage/heicimage/heifUnsupported in this version:
Safety Limits
Uploaded image validation before forwarding to Hermes:
8uploaded images per tool call.10MB.12MB.Usage Examples
Text:
Direct Dify image upload:
Requirements
requirements.txtNotes
stream=falsethrough the Responses API.Developer Information
https://github.com/sawyer-shihttps://github.com/sawyer-shi/dify-plugins-hermes_agent_chatLicense Notice
This project is licensed under Apache License 2.0. See LICENSE file for full license text.
Ready to connect Dify with Hermes Agent?
Plugin Submission Form
1. Metadata
2. Submission Type
3. Description
4. Checklist
5. Documentation Checklist
Please confirm that your plugin README includes all necessary information:
6. Privacy Protection Information
Based on Dify Plugin Privacy Protection Guidelines:
Data Collection
Privacy Policy