43e67d872f
Run models locally as a first-class provider. The CLI grows a managed llama.cpp runtime (engine install, model download, server supervision); the desktop app grows the full setup and management story on top of it. GUI surfaces ship behind the desktop --local launch flag (hermes desktop --local, or the flag on the packaged app); backend routes and the CLI are always live. Runtime (hermes_cli/local_runtime/): - curated GGUF catalog with per-machine variant selection: hardware probe (VRAM/RAM/UMA), fit planning with spill accounting, quant choice by context window - derived recommendation: quality-ranked picks gated by a predicted decode-speed floor, bandwidth-aware on unified memory; the decision table is pinned as a test (pick AND reason per memory class), and the Recommended badge explains its pick in a tooltip fed by the resolver's actual branch - engine install + model download with resumable split parts, cumulative plan-level progress, and staged-model integrity (a split GGUF counts only when every part is present) - server supervision: spawn/adopt/stop, router mode with per-model load progress relayed over SSE, abandoned-request cleanup Desktop: - Settings -> Providers -> Local models: one-click quickstart (install engine, download the recommended model, boot) plus per-model download/ activate/eject, fit-ranked catalog with context pills - model pickers (composer dropdown + Cmd+K) show staged local models, in-flight downloads as live progress rows, and load-into-memory bars - local-setup campaign tip for eligible hardware; System resources statusbar widget (GPU/VRAM/RAM); in-chat load progress during sends - friendly dead-server errors, and failed agent builds retry on the next send instead of wedging the session Co-developed with NVIDIA field feedback on RTX 5090 and DGX Spark.
40 lines
1.1 KiB
Python
40 lines
1.1 KiB
Python
"""The desktop subcommand's --local launch flag.
|
|
|
|
Local models ship on main behind this flag: `hermes desktop --local` (or
|
|
`Hermes.exe --local` directly) shows the local-models GUI surfaces; without
|
|
it the desktop hides them all, even when local models are configured. These
|
|
tests pin the argparse contract; the pass-through to the Electron argv lives
|
|
in cmd_gui's launch paths.
|
|
"""
|
|
|
|
import argparse
|
|
|
|
from hermes_cli.subcommands.gui import build_gui_parser
|
|
|
|
|
|
def _parser() -> argparse.ArgumentParser:
|
|
parser = argparse.ArgumentParser(prog="hermes")
|
|
subparsers = parser.add_subparsers(dest="command")
|
|
build_gui_parser(subparsers, cmd_gui=lambda args: None)
|
|
|
|
return parser
|
|
|
|
|
|
def test_local_flag_parses():
|
|
args = _parser().parse_args(["desktop", "--local"])
|
|
|
|
assert args.local is True
|
|
|
|
|
|
def test_local_flag_defaults_off():
|
|
args = _parser().parse_args(["desktop"])
|
|
|
|
assert args.local is False
|
|
|
|
|
|
def test_local_flag_composes_with_build_flags():
|
|
args = _parser().parse_args(["desktop", "--local", "--force-build"])
|
|
|
|
assert args.local is True
|
|
assert args.force_build is True
|