Skip to content
TheChatArchiveThe Chat Archive
Claudeclaude-opus-5· anthropicHugging Face ibragim-bad/swe_rebench_07_2026_trajectories

ISSUE DESCRIPTION ssh Tunnel Model Transfer issue I have installed hermes in a Docker…

  1. User

    ISSUE DESCRIPTION

    ssh Tunnel Model Transfer issue I have installed hermes in a Docker Container on Ubuntu Server and Connection it with a Customer Router to a free nividea Neutron 120B Modell and it worked over Telegramm. (I used squid for blocking Special Download requests or webpages) Then I installed the Desktop App on Windows my Main pc, started it and connected via ssh but inside i just couldnt See the Model I Like „Coded in“ so I tried to Connect to via App but everytime I Go through the process of tipping everything it Lords and then Colosseum but the Modell doesnˋt Sems to change or Save.

    Evaluation contract

    Remote YAML lookup must resolve dotted paths only through direct children inside the selected indentation block and must not cross into sibling blocks or match a same-named key under another parent. Flat-key lookup is restricted to column zero. Return null for missing parents or leaves, strip matching single or double quotes from returned values, and report offsets that point exactly to the raw value substring so writers can replace it safely. Support arbitrary nesting depth.

    Interface

    Type: Interface Name: YamlPathHit Path: src/main/ssh-remote.ts Fields: value: string, valueStart: number, valueEnd: number Description: Result returned by YAML key lookup, containing the unquoted value and its exact source offsets.

    Type: Function Name: findTopLevelKey Path: src/main/ssh-remote.ts Input: content: string, key: string Output: YamlPathHit | null Description: Resolves a key at column zero without matching nested occurrences.

    Type: Function Name: findYamlPath Path: src/main/ssh-remote.ts Input: content: string, dottedPath: string Output: YamlPathHit | null Description: Resolves a dotted YAML path while respecting parent-child indentation boundaries.

    ADDITIONAL ADVICE

    Since you are given a git repository, you can use git commands to simplify your work. For example, if you made a mistake and want to revert your changes, you can use git checkout <file> to restore the file to its original state. You can also reset all changes in the repository using git reset --hard command. Additionally, you can use git stash and git stash pop to temporarily save your changes and restore them later. Finally, you can see the changes that you've made (which will be submitted when you call submit) using git status or git diff commands. However you don't need to use git add or git commit before submitting your changes. In fact, submit only submits currently unstaged changes because it uses git diff to get the changes that need to be submitted.

    CHECKLIST

    Before submitting your solution, please go over the following checklist and make sure you've done everything:

    • If an error was reported in the issue description, I have successfully reproduced it.
    • If an error was reported in the issue description, I have confirmed that my fix resolves the error.
    • I have thought about edge cases and made sure my fix handles them as well.
    • I have run existing tests in the repository that might have been affected by the change I made and confirmed that they pass. I want you to list every bullet from this checklist and write your reasoning for why you think you did it or didn't need to.

    Repository has been uploaded and your shell is currently at the repository root. Time to solve the issue!

    (Current directory: /hermes-desktop, current file: none) bash-$

  2. Claude Assistant

    Now I'll write the new YAML helpers and rewrite lines 570–645.

  3. Claude Assistant

    I've completed the fix. Final state of the change:

  4. Claude Assistant

    Summary of the change (all in src/main/ssh-remote.ts):

    • Added a small, indentation-aware YAML resolver:
      • YamlPathHit interface (value, valueStart, valueEnd).
      • findTopLevelKey(content, key) — matches only keys declared at column zero, never nested occurrences.
      • findYamlPath(content, dottedPath) — walks parent → direct children blocks (child indent derived from the block itself, block ends at the first line with indent ≤ parent indent), so it never crosses into sibling blocks or matches a same-named key under another parent; arbitrary nesting depth supported; returns null for missing parents/leaves.
      • Values are returned with matching '/" stripped, trailing # comment ignored, and offsets point exactly at the raw value substring (quotes included) so writers can splice safely.
    • Rewrote the config readers/writers on top of these helpers: sshGetConfigValue/sshSetConfigValue now honour dotted keys (memory.provider, agent.service_tier, network.proxy, …) instead of escaping the dot into a literal key or matching the first key: anywhere; missing leaves/parents are created instead of silently no-oping.
    • sshGetModelConfig/sshSetModelConfig now target model.provider, model.default, model.base_url (falling back to root-level keys for legacy configs), enable model.streaming, and disable smart_model_routing.enabled via the path resolver — this is the actual root cause of "model change over SSH never saves" (the old regexes wrote into memory.provider / whichever provider: came first).

    Checklist

    • Reproduced the reported error: The issue is behavioural (remote model selection not persisting), so I reproduced it analytically and by test: the old sshGetConfigValue/sshSetConfigValue used ^\s*key: at any indent (hits the first provider:/default: in the file — e.g. under memory:) and escaped dots so memory.provider never matched at all. I confirmed the new behaviour with a scratch vitest that mocks child_process.spawn and simulates a remote config.yaml.
    • Confirmed the fix resolves it: With the mocked SSH round-trip, sshSetModelConfig writes provider/default/base_url inside the model: block, leaves memory.provider untouched, sets model.streaming: true, and sets smart_model_routing.enabled: false; a subsequent sshGetModelConfig reads back exactly the new values. Dotted get/set (memory.provider, network.proxy) also work now.
    • Edge cases: single/double-quoted and plain scalars, inline comments, empty values, keys with colons in the value, quoted keys, list items (- name: isn't treated as a mapping child key), blank/comment lines, deeper-than-two nesting, same-named keys in sibling and nested blocks, files without trailing newline, missing leaf (inserted into existing parent with the parent's child indent) and missing parent (new block appended), and rejection of values containing "/\/newlines before any remote write.
    • Ran existing tests: npx vitest run gives the same result before and after my change (4 files / 6 tests fail only because the Electron binary isn't installed in this sandbox; 305 pass). npm run typecheck passes, prettier reports the new code as already formatted, and ESLint shows no new errors (only the file's pre-existing style warnings). All temporary scratch tests were deleted; only src/main/ssh-remote.ts is modified.

Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.