Skip to main content

hugpy_core

hugpy central, minimal. Workers (hugpy_worker, one per box, over fitevict) register and heartbeat here; the registry is live in memory. /v1/chat/completions picks an online worker that has the model (resident first; alloc.worker pins one) and relays to its /infer/stream. No evict-to-fit, discovery, admission or DB state — each box's fitevict owns placement and the call log.

hugpy-core --host 127.0.0.1 --port 7020

Benchmark call-log history

POST /llm/benchmark/run opens a core call-log row before validation or planning. Accepted runs keep that row pending until their asynchronous outcome is known. Rejected plans retain their constraint reasons in the core response and error. The response and X-Hugpy-Request-Id expose its request ID.

Benchmark history/status read call_log; the JSON state and run archives are no longer read or written. Existing files are left intact as legacy evidence and are not converted into invented historical call records. Grading entries store call pointers and verdicts. History resolves answers and measurements from the referenced execution records. Each benchmark inference core row points back to the orchestration row, and its execution pointer identifies the wrapper row. Pending benchmark rows from a previous core process are marked interrupted.

The brain (failure auto-evaluation)

Ruling: toolserver instructions/hugpy/brain/brain-established-2026-10-06. A brain lives in core: always present, callable, and it evaluates every model-load failure automatically. hugpy-agent, when installed, adds features and access on top (the agent-station TUI); without it, this brain does the work.

  • Event: a hugpy_wrapper.residents row whose load_error changes fires pg_notify('model_rows'); brain.ensure() (started by app.main) listens and evaluates it. No polling.
  • Classify: rules first, from the legacy taxonomy (hard_load_failure, vram_fit, engine_unavailable, unreachable, vision_needs_slot, missing_dependency, other), plus pip-shaped signals (pip install X, No module named 'x', transformers' "requires the following packages").
  • Infer: the brain model is asked only when the rules leave something open (class other, or an import name with no package name, e.g. cv2 → opencv-python). The call goes through core's own /v1/chat/completions with metadata.intent = "brain-evaluate", so it is a call_log row. The brain never overrules a class the rules determined.
  • Record: every evaluation is a Help ticket (help_tickets, kind load-failure), de-duplicated per model/worker/error via occurrences.
  • Call it: POST /llm/brain/evaluate {error, worker?, model_key?, file?}; GET /llm/brain shows the model, policy and listener state.

Settings → Policies → Brain (settings_policies):

key meaning
brain.model the brain's model (fallback HUGPY_BRAIN_MODEL, then the help agent's model)
brain.auto auto-evaluate load failures (default on)
brain.auto_grade_min grader score (0–100) a fix must reach to apply without approval; unset = every fix needs approval

Not automated yet (same ruling, next step): the venv ladder for missing_dependency — existing env profiles → a new overlay profile → an isolated profile — each candidate test-loaded and graded, then designated (model_workers.env_profile) only when the grade meets brain.auto_grade_min. Never pip-install into a shared venv.

Verdicts priced at the pair's ctx and KV type

planner.refresh_worker passes each pair's user_settings to measured_verdict.price: the verdict is priced at the pair's ctx_pct (k% of the trained window, floored to 1024) and kv_cache_type (f16 / q8_0 / q4_0). A knob write that touches either re-plans that worker at once (modeldb.pair_knobs → planner.replan), so the console's Memory distribution follows the knobs.

Metadata

Release files for hugpy-core 0.1.49

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for hugpy-core 0.1.49
File Size Uploaded
hugpy_core-0.1.49.tar.gz 163.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for hugpy-core 0.1.49
File Interpreter ABI Platform
hugpy_core-0.1.49-py3-none-any.whl Python 3 none any Details

Total release size: 332.1 kB

Release files / hugpy_core-0.1.49.tar.gz

Download URL hugpy_core-0.1.49.tar.gz
Size 163.5 kB
Tags Source
SHA-256 checksum
How to use checksums
4239c99f3112814477fc67053a14cb5e58e91eb92461e08018d9a6cb40f242f7
BLAKE2b-256 checksum
How to use checksums
fb40cd51a17b23f48a8d91bce31327e91adc884a3e06e0435f03d5fca6db2b02
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.3

Release files / hugpy_core-0.1.49-py3-none-any.whl

Download URL hugpy_core-0.1.49-py3-none-any.whl
Size 168.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3bac05e92c78689c3ca2fdd3e19c7077a0866c2ea64e1c4f810856d764ce0aed
BLAKE2b-256 checksum
How to use checksums
dfe5d4899467bcfdf66a7a7d913a6a5161bcec13af60b95d9f508d8e817db567
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.3

Release history Release notifications | RSS feed

0.4.46

2 release files

0.4.45

2 release files

0.4.44

2 release files

0.4.43

2 release files

0.4.42

2 release files

0.4.41

2 release files

0.4.28

2 release files

0.4.27

2 release files

0.4.26

2 release files

This release

0.1.49 This release

2 release files

0.1.9

1 release file

0.1.8

2 release files

0.1.7

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page