Detect llama.cpp server readiness for auto-endpoint registration
Some checks are pending
CI / Focused test guidance (report-only) (push) Waiting to run
CI / Python syntax (compileall) (push) Waiting to run
CI / JS syntax (node --check) (push) Waiting to run
CI / Python tests (pytest) (push) Waiting to run
Container scan / hadolint (Dockerfile lint) (push) Waiting to run
Container scan (Trivy) / Trivy (image scan, advisory) (push) Waiting to run
Container scan (Trivy) / Trivy (image scan + SARIF upload) (push) Waiting to run
Dependency review / dependency-review (PR gate) (push) Waiting to run
Dependency review / pip-audit (advisory) (push) Waiting to run
ci / docker publish / build (amd64) (push) Waiting to run
ci / docker publish / build (arm64) (push) Waiting to run
ci / docker publish / merge manifest + tag (push) Blocked by required conditions
Secret scan / gitleaks (push) Waiting to run
Workflow security / actionlint (push) Waiting to run
Workflow security / zizmor (Actions SAST) (push) Waiting to run
Some checks are pending
CI / Focused test guidance (report-only) (push) Waiting to run
CI / Python syntax (compileall) (push) Waiting to run
CI / JS syntax (node --check) (push) Waiting to run
CI / Python tests (pytest) (push) Waiting to run
Container scan / hadolint (Dockerfile lint) (push) Waiting to run
Container scan (Trivy) / Trivy (image scan, advisory) (push) Waiting to run
Container scan (Trivy) / Trivy (image scan + SARIF upload) (push) Waiting to run
Dependency review / dependency-review (PR gate) (push) Waiting to run
Dependency review / pip-audit (advisory) (push) Waiting to run
ci / docker publish / build (amd64) (push) Waiting to run
ci / docker publish / build (arm64) (push) Waiting to run
ci / docker publish / merge manifest + tag (push) Blocked by required conditions
Secret scan / gitleaks (push) Waiting to run
Workflow security / actionlint (push) Waiting to run
Workflow security / zizmor (Actions SAST) (push) Waiting to run
_parseServePhase only recognized vLLM, FastAPI, and Ollama ready states.
llama-server's output ('server is listening on http://...') didn't match
any pattern, so _serveReady was never set and auto-registration never fired.
Added regex matching llamacpp-style listening messages.
This commit is contained in:
parent
6918d9417f
commit
80f38c9443
1 changed files with 4 additions and 0 deletions
|
|
@ -408,6 +408,10 @@ export function _parseServePhase(snapshot) {
|
||||||
if (/Ollama API ready on port\s+\d+/i.test(flat)) {
|
if (/Ollama API ready on port\s+\d+/i.test(flat)) {
|
||||||
return { phase: 'ready', status: 'ready' };
|
return { phase: 'ready', status: 'ready' };
|
||||||
}
|
}
|
||||||
|
// llama.cpp server (llama-server / llama-cli) — "server is listening" variants
|
||||||
|
if (/(?:server is listening|HTTP server listening|listening on (?:http|port))/i.test(flat)) {
|
||||||
|
return { phase: 'ready', status: 'ready' };
|
||||||
|
}
|
||||||
const llamaBuildMatches = [...flat.matchAll(/\[\s*(\d{1,3})%\]\s*(?:Building|Linking)/gi)];
|
const llamaBuildMatches = [...flat.matchAll(/\[\s*(\d{1,3})%\]\s*(?:Building|Linking)/gi)];
|
||||||
if (llamaBuildMatches.length) {
|
if (llamaBuildMatches.length) {
|
||||||
const pct = Math.min(100, parseInt(llamaBuildMatches[llamaBuildMatches.length - 1][1], 10));
|
const pct = Math.min(100, parseInt(llamaBuildMatches[llamaBuildMatches.length - 1][1], 10));
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue