forked from nexu-io/open-design
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhermes.ts
More file actions
52 lines (51 loc) · 1.97 KB
/
Copy pathhermes.ts
File metadata and controls
52 lines (51 loc) · 1.97 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
import { detectAcpModels, DEFAULT_MODEL_OPTION } from './shared.js';
import type { RuntimeAgentDef } from '../types.js';
export const hermesAgentDef = {
id: 'hermes',
name: 'Hermes',
bin: 'hermes',
versionArgs: ['--version'],
fetchModels: async (resolvedBin, env) =>
detectAcpModels({
bin: resolvedBin,
args: ['acp', '--accept-hooks'],
env,
timeoutMs: 15_000,
defaultModelOption: DEFAULT_MODEL_OPTION,
}),
// Used only when `fetchModels` (which calls `hermes acp` to enumerate
// the user's actually-installed providers) fails — e.g. Hermes isn't on
// PATH yet. The list doubles as discovery hints in the model picker so a
// user who hasn't installed Hermes still sees what becomes available
// after `hermes auth add xai-oauth` (xAI · SuperGrok subscription) or
// `hermes auth add openai` (Codex). Reference: https://x.ai/news/grok-hermes.
fallbackModels: [
DEFAULT_MODEL_OPTION,
// xAI Grok — available via SuperGrok OAuth (`hermes auth add xai-oauth`)
// or XAI_API_KEY in `~/.hermes/.env`.
{ id: 'grok-4.3', label: 'grok-4.3 (xAI · default)' },
{
id: 'grok-4.20-reasoning',
label: 'grok-4.20-reasoning (xAI · deep)',
},
{
id: 'grok-4.20-0309-non-reasoning',
label: 'grok-4.20-non-reasoning (xAI · fast)',
},
{
id: 'grok-4.20-multi-agent-0309',
label: 'grok-4.20-multi-agent (xAI · orchestration)',
},
// OpenAI Codex.
{ id: 'openai-codex:gpt-5.5', label: 'gpt-5.5 (openai-codex:gpt-5.5)' },
{ id: 'openai-codex:gpt-5.4', label: 'gpt-5.4 (openai-codex:gpt-5.4)' },
{
id: 'openai-codex:gpt-5.4-mini',
label: 'gpt-5.4-mini (openai-codex:gpt-5.4-mini)',
},
],
buildArgs: () => ['acp', '--accept-hooks'],
streamFormat: 'acp-json-rpc',
mcpDiscovery: 'mature-acp',
externalMcpInjection: 'acp-merge',
} satisfies RuntimeAgentDef;