[proxy] Simplify claude-proxy implementation and shrink the file.
Replace the proxy-wrapper launch wrapper with with-extensions on the
program-file: gexp->script then emits an expansion-time prologue that
puts the off-prefix (gnutls) and (json) module directories on the load
paths, so the generated script runs with no GUILE_LOAD_PATH plumbing.
Read all configuration from the environment in one block at the top of
the script body, hoisting the orphan-watchdog interval next to the
port, upstream and timeout reads, and document the contract in the
header.
Fold duplicated idioms without changing behavior: req-log via log, a
deadline-ms helper, one select in wait!, flat put-strings in
send-simple, a regex chunk-size parser, the abort-message case inside
emit-error-frame, an optional-header helper in forward, body-allowed?
inlined into serve-one, and the relay close path flattened. Trim
docstrings that restate adjacent comments and drop the unused imports
(guix packages) and (ice-9 receive).
The claude-proxy tests stay green: the full VM suite passes 41/41,
covering the deadline and streaming semantics that the rewrite must
preserve.
Add a make test-vps-live target that rehearses the proxy against the
real DeepSeek API: it starts the built proxy pointed at the real
upstream, reads the API key from the per-user runtime cache
(/run/user/$(id -u)/claude-apikey) and sends one streaming and one
non-streaming request. Verified live: both requests return HTTP 200
with real completions and the full event trace.