Commit Graph

67 Commits

Author SHA1 Message Date
P2K0 f0d1d2e16c feat: add docker-compose deployment and harden gateway startup
- add docker-compose setup with hermes-agent + hermes-webui

- make runtime config env-driven (compose vars + HERMES_BIN)

- improve gateway startup/restart resilience in docker

- make base image configurable via BASE_IMAGE/HERMES_AGENT_IMAGE

Closes https://github.com/EKKOLearnAI/hermes-web-ui/issues/14
2026-04-17 06:43:42 +08:00
ekko b8d121ed79 Merge branch 'dev'
# Conflicts:
#	package.json
v0.2.9
2026-04-16 15:21:24 +08:00
ekko 26423984d1 fix: profile import file upload, startup health check, sidebar scroll, node-pty fallback
- Change profile import from server path input to browser file upload (multipart)
- Fix startup script to wait for health check before opening browser
- Add overflow scroll with hidden scrollbar to sidebar nav
- Graceful degradation when node-pty fails to load (WSL compatibility)
- Remove rename button from profile cards
- Restrict profile name input to English letters, numbers, hyphens
- Use raw.githubusercontent.com URLs in README setup script

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-16 15:19:05 +08:00
ekko 99a47cf1ad feat: profile-aware routes, provider sync, channel settings improvements
- Add hermes-profile.ts for dynamic profile path resolution (all backend
  routes now read from active profile directory instead of hardcoded ~/.hermes/)
- Add profile switcher dropdown in sidebar, reload page on switch
- Sync PROVIDER_PRESETS with Hermes CLI (fix keys: kimi-coding→kimi-for-coding,
  kilocode→kilo, ai-gateway→vercel, opencode-zen→opencode; remove moonshot)
- Sync PROVIDER_ENV_MAP with Hermes models.dev + overlays (correct env var names)
- Add gateway restart after adding model provider
- Don't write GLM_BASE_URL/KIMI_BASE_URL for zai/kimi (let Hermes auto-detect)
- Write API keys to .env and credential_pool for all providers
- Built-in providers skip custom_providers in config.yaml
- Add debounce + per-field loading state for channel settings inputs
- Run hermes setup --reset for profiles without config.yaml
- Create empty .env for new profiles (not copied from default)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-16 13:51:42 +08:00
ekko 014168864f fix: always overwrite api_server config on startup
Simplify ensureApiServerConfig to unconditionally write default
platforms.api_server values, preventing missing config issues.

Bump version to 0.2.7.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-16 09:59:18 +08:00
ekko 293f36ecac fix: always overwrite api_server config on startup
Simplify ensureApiServerConfig to unconditionally write default
platforms.api_server values, preventing missing config issues.

Bump version to 0.2.7.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
v0.2.7
2026-04-16 09:54:58 +08:00
ekko 04b80a616e feat: add profile management page with full CRUD UI
- Add frontend API layer, Pinia store, and 5 components (ProfileCard, ProfilesPanel, ProfileCreateModal, ProfileRenameModal, ProfileImportModal)
- Add ProfilesView page with card grid layout and expandable details
- Modify export endpoint to stream file as browser download instead of returning server path
- Add sidebar nav entry, router route, and i18n translations (en/zh)
- Support create, rename, delete, switch (with gateway restart), export, and import profiles

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-16 09:40:25 +08:00
ekko 57ef171dda docs: add openapi.json specification
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-16 08:39:53 +08:00
ekko 351c861777 refactor: restructure project for multi-agent extensibility
- Migrate source to packages/client and packages/server directories
- Namespace all Hermes-specific code under hermes/ subdirectories
  (api/hermes/, components/hermes/, views/hermes/, stores/hermes/)
- Add hermes.* route names and /hermes/* path prefixes
- Upgrade @koa/router to v15, adapt path-to-regexp v8 syntax
- Fix proxy path rewriting: /api/hermes/v1/* → /v1/*, /api/hermes/* → /api/*
- Fix frontend API paths to match backend /api/hermes/* routes
- Fix WebSocket terminal path to /api/hermes/terminal
- Add proxyMiddleware for reliable unmatched route proxying
- Add profiles route module and hermes-cli profile commands
- Update CLAUDE.md development guide with new architecture
- Add Chinese README (README_zh.md)
- Add Web Terminal feature to README

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-16 08:38:18 +08:00
ekko 4917242dca fix: add auth to /upload endpoint to resolve 401 on file attachment
Fixes #10

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-15 19:29:44 +08:00
ekko 71c7f25f4b feat: add web terminal, improve README, fix node-pty and i18n issues
- Add web terminal view with xterm.js and node-pty WebSocket backend
- Rewrite README with badges, feature table, mobile demo video
- Add package keywords and improved description for npm/GitHub SEO
- Fix node-pty spawn-helper missing execute permission after npm install -g
- Auto-fix node-pty permissions on CLI startup
- Fix duplicate 'error' key in en.ts and zh.ts i18n files
- Remove nested NSpin in PlatformSettings (causes invisible loading spinner)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-15 16:36:04 +08:00
ekko d258875cef feat: support concurrent session streaming, persist active session, and improve 401 handling
- Refactor streaming to use Map<string, AbortController> for multi-session concurrency
- SSE callbacks capture session ID in closure, no cross-session interference
- messages is now computed from activeSession, no manual sync needed
- Persist active session ID to localStorage, restore on reload
- Auto-expand session group when restoring saved session
- Clear auth key and redirect to login on 401 (skip if already on login page)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
v0.2.5
2026-04-15 11:00:47 +08:00
ekko 2faa6fb95c chore: bump version to 0.2.4
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-15 10:29:36 +08:00
ekko 9eaaa4270d fix: resolve streaming messages splitting into individual bubbles
Simplify addMessage/updateMessage to only write to messages.value,
add syncMessagesToSession() to copy messages back on session switch
and stream completion. Also fix mobile viewport, session list overlay,
hamburger logo, and various responsive improvements.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-15 10:28:53 +08:00
ekko f3927e2990 Merge branch 'dev' into feat/mobile 2026-04-15 09:16:19 +08:00
ekko 62e0d6fbed fix: pass auth token via query param for SSE EventSource
EventSource API doesn't support custom headers, so pass token as
?token= query parameter. Server auth middleware now accepts token
from both Authorization header and query param.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-15 09:13:27 +08:00
ekko 9556db2f90 feat: add mobile responsiveness support
- Hamburger menu + drawer sidebar for mobile navigation
- Auto-collapse chat session list on mobile
- Responsive grids, modals, forms, and settings
- Touch-friendly nav items (44px targets)
- Skills page sidebar toggle on mobile
- Memory sections stack vertically on mobile

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-15 09:12:54 +08:00
ekko 29f19ddb30 fix: unify page header styles across all views
- Extract shared .page-header and .header-title to global.scss
- Standardize padding to 21px 20px matching sidebar logo height
- Fix Usage page layout to flex column with standard header
- Fix Logs page header CSS selector after class rename
- Normalize button sizes to small across all headers

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-15 08:50:10 +08:00
ekko 66cc9a6f1e fix: generate token on start, include token in URL, reset api_server config
- Pre-generate auth token before server start and pass via AUTH_TOKEN env var
- Append token to startup URL for auto-login
- Reset api_server config values to defaults on startup

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
0.2.3
2026-04-15 08:28:36 +08:00
ekko 1f45254dd0 feat: add token auth, login page, skill toggle, and route restructure
- Add token-based authentication with auto-generated token stored in server/data/.token
- Add login page with URL token auto-fill support
- Add route guards requiring auth for all pages except login
- Restructure routes: / for login, /chat for conversations
- Add skill enable/disable toggle via config.yaml skills.disabled
- Unify logo to /logo.png across sidebar, login, messages, and empty state
- Hide sidebar on login page, prevent flash with router.isReady()
- Fix session export JSON parse error when CLI returns non-JSON output
- Display token in CLI on server start

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-14 21:48:53 +08:00
ekko be4624b8b4 Merge branch 'dev' into feat/official-api 2026-04-14 20:19:30 +08:00
ekko c0f1453c62 fix: graceful shutdown for nodemon restart to prevent EADDRINUSE
- Add unified shutdown handler for SIGUSR2/SIGINT/SIGTERM
- Add uncaughtException/unhandledRejection handlers
- Use --signal SIGTERM in nodemon config

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-14 20:17:12 +08:00
ekko 456a7effd0 docs: add official API integration TODO checklist
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-14 19:01:42 +08:00
ekko 2487e147ab fix: prevent Windows terminal popups with windowsHide option
Add windowsHide: true to all spawn/execFile calls in bin and server code
to prevent new console windows from appearing on Windows.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-14 17:17:15 +08:00
ekko 9dd5fca9f9 feat: add usage statistics page, CLI improvements, and UI enhancements
- Add Usage Stats page with token breakdown, model distribution, and 30-day trend
- Pass through cache/cost token fields in BFF (cache_read/write_tokens, reasoning_tokens, actual_cost_usd)
- Add CLI commands: -v/--version, -h/--help, update/upgrade with auto-restart
- Auto-open browser on startup, auto-kill port conflicts (cross-platform)
- Validate all api_server config fields on startup (enabled, host, port, key, cors_origins)
- Add streaming thinking video animation with tool calls panel
- Add context token usage display (used / total) in chat header
- Sidebar: white logo area with shadow, dance video beside logo (canvas seamless loop)
- Fix sidebar nav scroll (app-main overflow-y: auto)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-14 14:48:58 +08:00
ekko f8fc64ff5c fix: remove set -e from setup script to prevent early exit
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-14 10:26:35 +08:00
ekko 8f8cf629bb feat: WSL support, js-yaml migration, and stability improvements
- PID/log files moved to ~/.hermes-web-ui/ for WSL compatibility
- Replace all regex YAML parsing with js-yaml in filesystem.ts
- Auto-detect WSL and use hermes gateway run for background startup
- Stop command: SIGTERM with SIGKILL fallback, clean stale PIDs
- Setup script: auto-install Node.js and hermes-web-ui

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
v0.2.0
2026-04-14 10:22:29 +08:00
ekko 60056e771a feat: auto-install hermes-web-ui via npm in setup script
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-14 09:04:54 +08:00
ekko 91e5f637dc feat: add environment setup script for auto-detecting and installing Node.js
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-14 09:02:49 +08:00
ekko e19b532e47 chore: bump version to 0.2.0-beta.1
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
v0.2.0-beta.1
2026-04-13 20:53:05 +08:00
ekko 0ff04758b6 feat: add gateway auto-start on boot and real health detection
- Auto-detect gateway connectivity on server startup, start gateway if not running
- Fix /health endpoint to actually check gateway reachability instead of just CLI version
- Fix MiniMax CN base_url from /anthropic to /v1
- Frontend connection status now reflects real gateway state

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 20:08:32 +08:00
ekko 5143a264c5 Merge pull request #3 from cl1107/main
feat(chat): 修复输入法回车发送消息的问题
2026-04-13 18:29:46 +08:00
cuiliang 600ec054cb feat(chat): 修复输入法回车发送消息的问题
- 添加 isComposing 状态跟踪输入法组合事件
- 实现 handleCompositionStart 和 handleCompositionEnd 方法
- 新增 isImeEnter 函数判断是否为输入法回车
- 修改 handleKeydown 方法,在输入法状态下阻止回车发送
- 在 textarea 上添加 compositionstart 和 compositionend 事件监听
2026-04-13 17:48:47 +08:00
ekko f22a497115 fix: add missing axios dependency and bump version to 0.1.9
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
v0.1.9
2026-04-13 16:59:17 +08:00
ekko 94329adc4f fix: remove duplicate sourceLabel declaration in ChatPanel
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 15:30:08 +08:00
ekko f828c73a23 Merge branch 'dev' 2026-04-13 15:28:21 +08:00
ekko 4793b919a6 add 2026-04-13 15:27:53 +08:00
ekko 80c9f21be4 Merge branch 'dev' 2026-04-13 15:26:18 +08:00
ekko 32060a530d docs: update demo GIF and link
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 15:26:10 +08:00
ekko f0d2ed7ddd Merge branch 'dev' 2026-04-13 15:22:19 +08:00
ekko cf41d790f4 docs: format README tables and spacing
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 15:22:12 +08:00
ekko 691631084f Merge branch 'dev'
# Conflicts:
#	README.md
#	src/assets/output.gif
2026-04-13 15:19:48 +08:00
ekko 11e0b65934 chore: update demo GIF
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
v0.1.7
2026-04-13 15:18:56 +08:00
ekko e89a240f1d feat: add i18n, platform channels page, and WeChat QR login
- Add vue-i18n with auto-detect browser language and manual toggle (EN/中文)
- Move platform channels to separate page with credential management
- Support Telegram, Discord, Slack, WhatsApp, Matrix, Feishu, Weixin, WeCom
- Add WeChat QR code login (opens in browser, polls status, auto-saves)
- Write platform credentials to ~/.hermes/.env matching hermes gateway setup
- Auto restart gateway after platform config changes
- Add settings store with per-section save for all config categories
- Persist session group collapse state across navigation
- Fix pre-existing TypeScript build errors

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 15:15:14 +08:00
ekko 9e069a20a1 feat: add model management module with provider CRUD
- New /models page with provider list (built-in + custom)
- Add provider via preset selection or custom URL with auto-fetch models
- Delete provider removes from auth.json credential_pool + config.yaml custom_providers
- Auto-switch model on add, fallback switch on delete
- Sync sidebar ModelSelector on all provider changes
- Unified provider presets in shared/providers.ts (frontend + backend)
- Backend uses hardcoded catalog first, live probe as fallback

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 12:15:16 +08:00
ekko 9a3d5ef8d2 docs: fix Hermes Agent repo link
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 09:35:47 +08:00
ekko 3a17d8ac51 docs: fix Hermes Agent repo link
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 09:35:40 +08:00
ekko 7737fe1f66 docs: add demo GIF to README
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 09:34:39 +08:00
ekko 50b9185ece docs: add demo GIF to README
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 09:34:29 +08:00
ekko 48a1c5bf91 chore: add demo GIF
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 09:31:17 +08:00