Skip to content

Rl capabilities && File Operator Tools#15

Merged
teknium1 merged 6 commits into
mainfrom
rl-capabilities
Feb 5, 2026
Merged

Rl capabilities && File Operator Tools#15
teknium1 merged 6 commits into
mainfrom
rl-capabilities

Conversation

@teknium1

@teknium1 teknium1 commented Feb 5, 2026

Copy link
Copy Markdown
Contributor

Initial RL training toolset and complete file operations toolset (to make it operate much more like a coding agent)

- Updated `.env.example` to include Tinker and WandB API keys for reinforcement learning training.
- Enhanced `model_tools.py` to clarify configuration options and streamline the RL training process.
- Expanded `README.md` with detailed instructions for setting up RL training using Tinker and WandB.
- Modified `hermes_cli` files to integrate RL training tools and ensure proper configuration checks.
- Improved `rl_training_tool.py` to reflect changes in training parameters and configuration management.
- Added the tinker-atropos submodule for enhanced RL training capabilities.
- Updated model_tools.py to reorder RL function definitions and improve descriptions.
- Modified rl_cli.py to include checks for the tinker-atropos setup and provide user guidance.
- Adjusted toolsets.py and __init__.py to reflect changes in RL function availability.
- Enhanced rl_training_tool.py to manage training processes directly without a separate API server.
- Modified `model_tools.py` to update default model IDs and add new RL function `rl_test_inference`.
- Enhanced `README.md` with installation instructions for submodules and updated API key usage.
- Improved `rl_cli.py` to load configuration from `~/.hermes/config.yaml` and set terminal working directory for RL tools.
- Updated `run_agent.py` to handle empty string arguments as empty objects for better JSON validation.
- Refined installation scripts to ensure submodules are cloned and installed correctly, enhancing setup experience.
… streaming

- Added unique run ID generation for WandB tracking during test inference.
- Enabled WandB usage for test tracking and updated command-line arguments accordingly.
- Implemented real-time output streaming for process execution, improving log visibility and debugging.
- Enhanced error handling to display last few lines of stderr for better troubleshooting.
- Introduced file manipulation capabilities in `model_tools.py`, including functions for reading, writing, patching, and searching files.
- Added a new `file` toolset in `toolsets.py` and updated distributions to include file tools.
- Enhanced `setup-hermes.sh` and `install.sh` scripts to check for and optionally install `ripgrep` for faster file searching.
- Implemented a new `file_operations.py` module to encapsulate file operations using shell commands.
- Updated `doctor.py` and `install.ps1` to check for `ripgrep` and provide installation guidance if not found.
- Added fuzzy matching and patch parsing capabilities to improve file manipulation accuracy and flexibility.
@teknium1 teknium1 merged commit 8dd3831 into main Feb 5, 2026
@taeyun16

Copy link
Copy Markdown

🔍 자동 분석 결과

이슈 요약

리더보드 시스템 — 주간/월간/지역별 순위로 경쟁 유도 + 보상 제공

기술 구현 고려사항

백엔드 (Phoenix/Ash)

  • 리더보드 스냅샷: weekly_leaderboards (period_start, period_end, category)
  • 순위 계산: (Oban, 매주 월요일 00:00 KST)
    • WeeklyVoteKing: 주간 투표 수 top 100
    • MonthlyCollector: 월간 신규 고양이 수집 top 100
    • StreakChampion: 연속 투표 최장 기간 top 100
    • RegionalRank: PostGIS ST_DWithin로 지역 필터링
  • 순위 변동 추적: leaderboard_changes (user_id, change_amount, direction)
  • 보상 지급: period结束时 자동 + 배지 발송

iOS (SwiftUI)

  • 리더보드 탭: (segmented: 주간/월간/지역)
  • 순위 Cell: (rank, avatar, name, score, change delta)
  • 내 순위 고정: sticky bottom bar — "내 순위: 15위 / 234명"
  • 변경 알림: 순위 진입/변동 시 토스트 + 햅틱

우선순위 제안

  1. Phase 1: 주간 투표왕 (가장 단순 — existing vote_count 활용)
  2. Phase 2: 지역별 순위 (PostGIS regional 쿼리 의존)
  3. Phase 3: 월간 수집왕 (고양이 도감 완료 후)
  4. Phase 4: 연속 기록왕 (Streak 시스템 통합)

관련existing 코드

  • — 아직 없으면 Streak worker 패턴 참고
  • Regional ranking: PostGIS queries

🤖 HanNyang Auto Resolver

sudo-yf pushed a commit to sudo-yf/hermes-agent that referenced this pull request Apr 5, 2026
fix: project picker visibility, width, create-from-picker, button state, listener leak
sudo-yf pushed a commit to sudo-yf/hermes-agent that referenced this pull request Apr 5, 2026
Covers PRs NousResearch#11, NousResearch#13, NousResearch#14, NousResearch#15: Sprint 15 features, security hardening,
OpenRouter routing fix, project picker UX fixes.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
h4x3rotab pushed a commit to Clawdi-AI/hermes-agent that referenced this pull request Apr 10, 2026
h4x3rotab pushed a commit to Clawdi-AI/hermes-agent that referenced this pull request Apr 10, 2026
* fix: cross-platform terminal/browser support and build fixes

- Use platform-aware default shell (zsh on macOS, bash on Linux/Windows)
  instead of hardcoding /bin/zsh everywhere
- Mark Playwright packages as external in Vite to fix chromium-bidi
  bundle errors during dev
- Copy pty-helper.py to dist/server/assets/ on build so production
  server can find it
- Fix browser launch guard to check `context` instead of `browser`
  (which is always null with launchPersistentContext)
- Exclude unused diagnostics.ts stub from route tree
- Update README with Playwright install step and Extra section

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* docs: add Ubuntu/Debian prerequisites for Tauri desktop build

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
h4x3rotab pushed a commit to Clawdi-AI/hermes-agent that referenced this pull request Apr 10, 2026
Previously hermes-api.ts helper functions (hermesGet, hermesPost,
hermesPatch, hermesDeleteReq, streamChat) sent no Authorization header,
causing 401 'Invalid API key' errors when the gateway has API_SERVER_KEY
configured.

Also exports BEARER_TOKEN from gateway-capabilities.ts so hermes-api.ts
can import and reuse it for auth headers.

Co-authored-by: mgnyc11 <mgnyc11@users.noreply.github.com>
@zhangtobybot-a11y

Copy link
Copy Markdown

已合并到 PR #45

1 similar comment
@zhangtobybot-a11y

Copy link
Copy Markdown

已合并到 PR #45

malaiwah pushed a commit to malaiwah/hermes-agent that referenced this pull request Apr 11, 2026
…ameter + schema property' (NousResearch#15) from fix/terminal-notify-on-complete into main
angelburgosrosado pushed a commit to angelburgosrosado/hermes-agent that referenced this pull request Apr 27, 2026
olympus-terminal pushed a commit to olympus-terminal/hermes-agent that referenced this pull request May 16, 2026
difeizheng pushed a commit to difeizheng/zdf-hermes-agent that referenced this pull request Jun 3, 2026
Fixes 12 remaining MEDIUM issues from the deep audit (19 total, 7 fixed in Round 12):

design_agent:
- NousResearch#15: add asyncio.wait_for(300s) around LLM API call to prevent infinite hangs
- NousResearch#17: replace 2x hardcoded 'claude-opus-4-8' with shared DEFAULT_MODEL constant

qa_agent / validate_agent:
- NousResearch#20,NousResearch#22,NousResearch#23: already fixed in Round 12 (verified — dynamic timeout/threshold values used)

memory.py:
- NousResearch#24: frontmatter parser uses regex r'^---$' instead of str.split('---',2),
  preventing false splits on content containing '---' (SQL, markdown tables)
- NousResearch#25: parse and preserve 'description' field from frontmatter in metadata,
  fixing write→load roundtrip data loss

profiles.py:
- NousResearch#26: ProfileConfig now frozen=True (immutable dataclass per coding standards)

deploy_agent:
- NousResearch#31: replace 2x sync subprocess.run with asyncio.create_subprocess_exec
- fix 5x .decode() → .decode('utf-8', errors='replace') for Windows CJK safety
- remove unused import subprocess

db.py:
- NousResearch#27: add class docstring explaining RLock + _unlocked pattern
- NousResearch#28: FK constraints already in DDL (verified PRAGMA foreign_keys=ON active)
- NousResearch#29: add _ensure_connection() with PRAGMA integrity_check(1) + auto-reconnect
       on 4 critical methods (create_task, get_task, claim_task, submit_result)
- extract _create_connection() static method for reuse by reconnect

Tests: 79 passed, 0 failed
xzmzm added a commit to xzmzm/hermes-agent that referenced this pull request Jun 3, 2026
xzmzm added a commit to xzmzm/hermes-agent that referenced this pull request Jun 8, 2026
mcvayaaron6-commits pushed a commit to mcvayaaron6-commits/hermes-agent that referenced this pull request Jun 10, 2026
NousResearch#15

Three remaining findings from the code review.

NousResearch#12 — hermes_cli/superagent.py: _strip_fences only handled a SINGLE
      leading-and-trailing ``` envelope.  Common model failure mode
      is 'Here is the plan you asked for:\\n```yaml\\nfanout: 2\\n
      ...\\n```\\nLet me know.' — the leading prose means
      stripped.startswith('```') is False so the function returned
      the whole text unchanged, then yaml.safe_load choked → exit 2.

      Fix: regex-based extraction with _FENCE_BLOCK_RE that pulls
      the YAML body out of fenced blocks even when there's prose on
      either side.  Falls back to the simple-strip path for fence-
      only output (preserves existing behaviour).

NousResearch#13 — hermes_cli/web_server.py: /ready was BOTH side-effecting AND
      racy.  (a) Called path.parent.mkdir(parents=True, exist_ok=
      True) on every probe — k8s polls every few seconds, so a
      read-only mount surfaced PermissionError every hit and a
      writeable mount got directories repeatedly recreated.  (b)
      The .readiness_probe storage check used a shared filename;
      two concurrent k8s probes (liveness + readiness simultaneous)
      could race, one's unlink raising FileNotFoundError → false
      'not_ready' on a healthy node.

      Fix: (a) audit_log probe just reports parent.exists(); never
      mutates.  (b) storage probe uses a per-PID + per-call unique
      filename and tolerates FileNotFoundError on cleanup.

NousResearch#15 — hermes_cli/superagent.py + hermes_cli/orchestrate.py: parent
      AIAgent was constructed bare with model=... provider=...
      quiet_mode=True only — no api_key, no base_url, no api_mode,
      no credential_pool.  delegate_task then pulled effective_
      api_key=None from the parent, so child subagents failed to
      authenticate whenever credentials lived in config.yaml
      rather than env vars (the production case for serious users).

      Fix: mirror hermes_cli/oneshot.py's resolve_runtime_provider
      pattern in both _build_parent_agent and superagent.py's
      parent construction.  Threads api_key / base_url / provider /
      api_mode / credential_pool from the resolved runtime, exactly
      like oneshot does.

274 tests pass — no regressions.

All 15 code-review findings are now fixed across three commits
(f25ae81 showstoppers, 06e71bc critical correctness, this commit
lower-severity polish).

https://claude.ai/code/session_01PNyEMgrzVHtXnPGwUfotWw
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants