Hermes Overview: Key Features & Integration Guide
For detailed information about using models with APIpie, check out our Models Overview and Completions Guide.
Description
The Hermes Series represents a collection of advanced large language models, primarily developed by Nous Research and the open-source AI community. These models are fine-tuned versions built on top of powerful base models like Llama, Mistral, and Mixtral. The models leverage state-of-the-art Direct Preference Optimization (DPO) and other advanced training techniques for enhanced performance in natural language processing and instruction-following tasks. You can explore the models' technical details and training methodologies on their Hugging Face model cards. The models are available through various providers integrated with APIpie's routing system.
Key Features
- Extended Token Capacity: Models support context lengths from 4K to 32K tokens for handling various text processing needs, with advanced attention mechanisms for efficient processing.
- Multi-Provider Availability: Accessible across platforms like OpenRouter, Together, and Deepinfra.
- Diverse Applications: Optimized for chat, instruction-following, and vision tasks through specialized multi-task training.
- Advanced Architecture: Built on state-of-the-art base models with specialized fine-tuning using techniques like constitutional AI and RLHF.
Model List in the Hermes Series
Model List updates dynamically please see the Models Route for the up to date list of models
Model Name | Max Tokens | Response Tokens | Provider | Type |
nous-hermes-llama2-13b | 4,096 | 4,096 | openrouter | llm |
nous-hermes-2-mixtral-8x7b-dpo | 32,768 | 32,768 | openrouter | llm |
nous-hermes-2-vision-7b | 4,096 | 4,096 | openrouter | vision |
openhermes-2.5-mistral-7b | 4,096 | 4,096 | openrouter | llm |
chronos-hermes-13b-v2 | 4,096 | 4,096 | deepinfra | llm |
Nous-Hermes-2-Mixtral-8x7B-DPO | 32,768 | 32,768 | together | llm |
For information about model performance and benchmarks, see the Nous Research Blog and explore detailed evaluations on the Open LLM Leaderboard.
Example API Call
Below is an example of how to use the Chat Completions API to interact with a model from the Hermes Series, such as nous-hermes-2-mixtral-8x7b-dpo
.
curl -L -X POST 'https://apipie.ai/v1/chat/completions' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <YOUR_API_KEY>' \
--data-raw '{
"provider": "openrouter",
"model": "nous-hermes-2-mixtral-8x7b-dpo",
"max_tokens": 150,
"messages": [
{
"role": "user",
"content": "Can you explain how photosynthesis works?"
}
]
}'
Response Example
The expected response structure for the Hermes model might look like this:
{
"id": "chatcmpl-12345example12345",
"object": "chat.completion",
"created": 1729535643,
"provider": "openrouter",
"model": "nous-hermes-2-mixtral-8x7b-dpo",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Photosynthesis is the process by which green plants, algae, and some bacteria convert light energy into chemical energy. Here's how it works:\n\n1. **Light Absorption**: Plants capture light energy using a pigment called chlorophyll, which is found in chloroplasts.\n\n2. **Water and Carbon Dioxide**: They absorb water through their roots and carbon dioxide from the air.\n\n3. **Glucose Production**: The light energy is used to convert water and carbon dioxide into glucose (a sugar) and oxygen. The equation is:\n \n 6CO2 + 6H2O + light energy → C6H12O6 + 6O2\n\nThis process provides energy for the plant and releases oxygen into the atmosphere."
},
"logprobs": null,
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 15,
"completion_tokens": 125,
"total_tokens": 140,
"prompt_characters": 45,
"response_characters": 520,
"cost": 0.002250,
"latency_ms": 3100
},
"system_fingerprint": "fp_123abc456def"
}
API Highlights
- Provider: Specify the provider or leave blank for automatic selection.
- Model: Use any model from the Hermes Series, such as
nous-hermes-2-mixtral-8x7b-dpo
or others suited to your task. See Models Guide. - Max Tokens: Set the maximum response token count (e.g., 150 in this example).
- Messages: Format your request with a sequence of messages, including user input and system instructions. See message formatting.
This example demonstrates how to seamlessly query models from the Hermes Series for conversational or instructional tasks.
Applications and Integrations
- Conversational AI: Powering chatbots, virtual assistants, and other dialogue-based systems. Try it with LibreChat, OpenWebUI, or integrate with popular frameworks like LangChain and LlamaIndex.
- Vision Tasks: Using vision-enabled models like
nous-hermes-2-vision-7b
for image understanding and multimodal applications, leveraging advanced vision-language architectures. - Extended Context Tasks: Processing longer documents with models supporting up to 32K tokens, utilizing efficient attention mechanisms. Learn more in our Models Guide.
- Instruction Following: Leveraging advanced fine-tuning techniques like DPO and Constitutional AI for improved task completion and instruction following.
- Research and Development: Contributing to open-source AI development through model merging, knowledge distillation, and other techniques.
Ethical Considerations
The Hermes models are powerful tools that should be used responsibly. Users should implement appropriate safeguards and consider potential biases in model outputs.
Licensing
The Hermes Series models are available under various licenses depending on their base models and providers. For detailed licensing information, consult the respective model repositories on Hugging Face.
Try out the Hermes models in APIpie's various supported integrations.