Consolidate verified Athena runtime, maintenance records and specialist handoff
This commit is contained in:
1 parent
f63c5c936a
commit
6979480fd8
332 files changed
+71539
-5
No files matched your search
@@ -0,0 +1,146 @@
|
||||
# Articulino CPU / Anna · 26 October 2026
|
||||
|
||||
Michael requested testing Articulino next and removing the rejected MOSS/NeuTTS
|
||||
experiments. The rejected Athena test root, including weights, caches, source,
|
||||
venvs, private codes and audio, was removed (8,730,607,616 allocated bytes).
|
||||
Its NAS staging directory and twenty local candidate WAVs were also removed.
|
||||
Measurement records and the human rejection remain in the previous experiment.
|
||||
No Qwen weight, runtime, profile, endpoint or original Anna file was removed.
|
||||
|
||||
## Candidate and isolation
|
||||
|
||||
- Code: `eigenhand/articulino-onnx` commit
|
||||
`143d6dd5bbd67a02564be30f15bd8a578dda4987`, package 1.0.0.
|
||||
- Weights: `eigenhand/Articulino-DE-EN-Realtime-Stream-TTS-ONNX`, revision
|
||||
`a760ce8d513534111c7679751869fa4c45ef0e54`, **fp32**, not int8.
|
||||
- All five fp32 ONNX files matched the publisher's pinned `SHA256SUMS`.
|
||||
Original source/configuration and weights are unmodified.
|
||||
- Own host Python 3.13.5 venv with CPU ONNX Runtime 1.23.2, NumPy 2.2.6,
|
||||
SoundFile 0.13.1 and num2words 0.5.14. No Torch or CUDA dependency.
|
||||
- Existing original Anna recording, read-only as input. The upstream voice
|
||||
encoder uses its normal eight-second maximum; no alternative voice or pitch
|
||||
correction was substituted. Voice preparation is cached before timing.
|
||||
- A transient host process: four backend threads, CPU quota 400%, affinity
|
||||
2–5/8–11, nice 10, MemoryMax 4 GiB, MemorySwapMax 0 and a finite lifetime.
|
||||
Every ONNX graph independently reported `CPUExecutionProvider` only.
|
||||
No test server/listener, production restart or profile publication.
|
||||
|
||||
## Fixed main test
|
||||
|
||||
The same original five texts as the prior comparison, seeds 42 and 43, ten WAVs.
|
||||
Articulino uses its own German frontend and its actual `stream()` sentence
|
||||
segmentation, with standard `uniform_rate=True`, `retry_broken=True`, and
|
||||
0.15-second sentence pauses. This is a practical complete-pipeline comparison,
|
||||
**not an isolated neural-model A/B**: the previous candidates received the
|
||||
existing Athena preprocessing and different sentence segmentation. Default
|
||||
Articulino includes number expansion and its own spelling rules.
|
||||
|
||||
Timers include native frontend, all four flow steps, decoding, default output
|
||||
checks/postprocessing and PCM WAV serialization. They exclude model/voice
|
||||
initialization, network, STT and client playback. No audio cache is used. The
|
||||
two seeds produce different samples; their durations match because the default
|
||||
duration/voice-rate prediction is deterministic. The diagnostic wrapper observes
|
||||
the upstream broken-output check without changing its verdict or output.
|
||||
|
||||
| Measurement | Result |
|
||||
| --- | ---: |
|
||||
| Completed main files | 10/10 |
|
||||
| Total audio | 217.40 s |
|
||||
| Total generation | 6.6002 s |
|
||||
| Weighted RTF | 0.03036 |
|
||||
| Audio per second computing | 32.94 s |
|
||||
| Long passage | 52.50 s audio in 1.566/1.567 s |
|
||||
| Median first complete sentence | 0.131 s |
|
||||
| Range first complete sentence | 0.102–0.207 s |
|
||||
| Peak process RSS | 0.846 GiB |
|
||||
| Model initialization | 0.589 s |
|
||||
| Separate voice preparation | 0.160 s |
|
||||
| Upstream broken-output retry triggers | 0 |
|
||||
|
||||
This is a short warm CPU experiment under the specified allocation. It is not
|
||||
a concurrency guarantee or measured Hermes/Conduit latency. Streaming yields
|
||||
complete sentence audio, not incremental codec frames inside a sentence.
|
||||
|
||||
## Local STT and pronunciation
|
||||
|
||||
All ten original outputs went through the existing local Parakeet Redux CPU
|
||||
STT, German selected. The same text edit-distance scorer as the previous test
|
||||
normalizes case, punctuation, small German numbers and common speech preparation.
|
||||
These are combined synthesis/recognition deviations, **not a pure TTS error
|
||||
rate, accent score, speaker-similarity score or naturalness judgment**.
|
||||
|
||||
| Main round-trip group | Reference words | Edits | Deviation |
|
||||
| --- | ---: | ---: | ---: |
|
||||
| Two story texts × two seeds | 310 | 0 | 0.0% |
|
||||
| Three opening/technical texts × two seeds | 164 | 31 | 18.9% |
|
||||
| Total | 474 | 31 | 6.5% |
|
||||
|
||||
Both stories were fully recognized in both seeds after normalization, including
|
||||
the long final sentence. Unassisted technical text still gives errors around
|
||||
QNAP, Cluster/Shared Storage, Unraid, Logfile, units and Scan. CEST was absent
|
||||
from its ASR transcript. Direct frontend readback shows CEST remains unexpanded
|
||||
in the synthesis input; it was not silently deleted by the frontend.
|
||||
|
||||
There are five independent input cases. Two seeds are repeats, not ten
|
||||
independent tasks; individual words are not independent trials. Zero story
|
||||
edits does not establish freedom from accent or future word-drop failures.
|
||||
The author documents occasional swallowed/blurred words. The prior rejected
|
||||
candidates demonstrated why ASR alone is inadequate.
|
||||
|
||||
### Human listening verdict
|
||||
|
||||
Michael rated Articulino **barely acceptable**, with overall sound quality below
|
||||
his target. The guided technical passage was also acceptable in pronunciation,
|
||||
but the generated speaker did not sound sufficiently like the established Anna
|
||||
voice. Retain it as a candidate for further evaluation, not as an approved
|
||||
equivalent voice or production replacement. No activation or fallback routing
|
||||
was authorized by this listening feedback. Low ASR deviation must not be used
|
||||
to overrule this assessment of sound and speaker identity.
|
||||
|
||||
## Separate post-hoc pronunciation controls
|
||||
|
||||
After observing the technical errors, two additional seed-42 probes used the
|
||||
upstream supported `[en]...[/en]` markers for English words, explicit German
|
||||
letter names for QNAP, written-out numbers, and the full German timezone name.
|
||||
These were **not** substituted into the fixed main scores above and do not
|
||||
represent production configuration changes. See `guided-cases.json`.
|
||||
|
||||
- Guided previous failure: 8.75 s audio in 0.270 s. STT recognized the complete
|
||||
clause including Cluster, Failover, Shared Storage and QNAP.
|
||||
- Guided technical passage: 22.04 s audio in 0.724 s. STT retained the expanded
|
||||
timezone and the numeric claims; recognition/pronunciation uncertainties
|
||||
remain for Logfile, Mebibyte, Scan and the English/German boundary.
|
||||
|
||||
The controls demonstrate that input preparation matters. They do not prove a
|
||||
finished pronunciation layer or solve every technical word. No shared Athena
|
||||
preprocessor, Hermes source, Mac client or Qwen profile was patched.
|
||||
|
||||
## Native reproduction and retention
|
||||
|
||||
Test root: `/data/athena-articulino-test-20261026`. On a compatible Debian host,
|
||||
create an own Python 3.13 venv, install the recorded CPU requirements, check out
|
||||
the pinned code, and stage only the pinned fp32 files/config under `model/`.
|
||||
Verify the published hashes. Restore Anna through the existing private voice
|
||||
backup; public weights do not replace it. The harness's root and reference path
|
||||
must point to the intended own test folder and existing private recording.
|
||||
Run `benchmark.py` under the documented transient process limits. `guided.py`
|
||||
is an explicitly separate follow-up. The STT comparison used the existing
|
||||
authenticated local endpoint without displaying or persisting its key.
|
||||
|
||||
This is an experiment, not a deployed Deck runtime/profile implementation. A
|
||||
product integration would still require native installation/restore recipes,
|
||||
profile and endpoint routing, lifecycle/cancellation handling and client tests.
|
||||
No extra container or installed Mac dependency was introduced by this test.
|
||||
|
||||
Readback verified unchanged profile catalogue, endpoint, audio policy, canonical
|
||||
and live Qwen worker. Original Anna remains present. Both transient Articulino
|
||||
units ended; no worker or listener remains. Candidate weights/venv and current
|
||||
audio remain on Athena, and local listening copies under
|
||||
`work/articulino-20261026/outputs`, pending human assessment. Generated audio and
|
||||
private reference material are excluded from Git. Only public source pins,
|
||||
hashes, synthetic test inputs, metrics and scripts are documented here.
|
||||
|
||||
After transcription, the own temporary NAS STT staging folder was removed, as
|
||||
was the candidate's own pip download cache. Current Articulino model/runtime
|
||||
and listening files remain for human assessment. Final live worker readback
|
||||
and unchanged-setting checks passed again; both transient units were inactive.
|
||||
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"settings_unchanged": {
|
||||
"profiles.json": true,
|
||||
"endpoint.json": true,
|
||||
"audio-policy.json": true
|
||||
},
|
||||
"original_Anna_exists": true,
|
||||
"rejected_root_absent": true,
|
||||
"test_unit_state": "inactive",
|
||||
"production_qwen_worker_unchanged": true,
|
||||
"test_units": {
|
||||
"athena-articulino-test-20261026.service": "inactive",
|
||||
"athena-articulino-guided-20261026.service": "inactive"
|
||||
},
|
||||
"live_qwen_worker_unchanged": true,
|
||||
"own_pip_cache_removed": true
|
||||
}
|
||||
@@ -0,0 +1,81 @@
|
||||
"""Bounded native CPU-only Articulino test; never writes production state."""
|
||||
import os
|
||||
os.environ.update(CUDA_VISIBLE_DEVICES='', HF_HUB_OFFLINE='1',
|
||||
HF_HUB_DISABLE_TELEMETRY='1', OMP_NUM_THREADS='4',
|
||||
OPENBLAS_NUM_THREADS='1', MKL_NUM_THREADS='4')
|
||||
import json
|
||||
import time
|
||||
import signal
|
||||
import resource
|
||||
from pathlib import Path
|
||||
import numpy as np
|
||||
import soundfile as sf
|
||||
from articulino_onnx import TTS
|
||||
from articulino_onnx import dsp
|
||||
|
||||
ROOT = Path('/data/athena-articulino-test-20261026')
|
||||
OUT = ROOT/'outputs'
|
||||
OUT.mkdir(exist_ok=True)
|
||||
cases = json.loads((ROOT/'cases.json').read_text())
|
||||
checks = []
|
||||
original_check = dsp.broken
|
||||
def observed_check(*args, **kwargs):
|
||||
reason = original_check(*args, **kwargs)
|
||||
checks.append(reason)
|
||||
return reason
|
||||
dsp.broken = observed_check
|
||||
|
||||
start = time.monotonic()
|
||||
tts = TTS.from_pretrained(ROOT/'model', precision='fp32',
|
||||
providers=['CPUExecutionProvider'], threads=4)
|
||||
load_seconds = time.monotonic()-start
|
||||
start = time.monotonic()
|
||||
tts.set_voice('/opt/athena-deck-dev/runtime/state/speech-voices/Anna/reference.wav')
|
||||
voice_seconds = time.monotonic()-start
|
||||
providers = {name: session.get_providers() for name, session in tts.engine.sessions.items()}
|
||||
assert all(x == ['CPUExecutionProvider'] for x in providers.values())
|
||||
setup = dict(precision='fp32', load_seconds=load_seconds, voice_seconds=voice_seconds,
|
||||
providers=providers, threads=4, affinity=sorted(os.sched_getaffinity(0)),
|
||||
uniform_rate=tts.uniform_rate, retry_broken=tts.retry_broken,
|
||||
sentence_pause_seconds=tts.pause, reference_max_seconds=8)
|
||||
(ROOT/'setup-results.json').write_text(json.dumps(setup, indent=2))
|
||||
print(json.dumps({'ready': setup}), flush=True)
|
||||
|
||||
def timeout(*_):
|
||||
raise TimeoutError('Own case exceeded 120 seconds')
|
||||
signal.signal(signal.SIGALRM, timeout)
|
||||
results = []
|
||||
for seed in (42, 43):
|
||||
for case in cases:
|
||||
name = case['id']+'-'+str(seed)
|
||||
row = dict(case_id=case['id'], seed=seed, name=name)
|
||||
checks.clear()
|
||||
signal.alarm(120)
|
||||
first = None
|
||||
chunks = []
|
||||
start = time.monotonic()
|
||||
try:
|
||||
# Real model frontend and sentence streaming, not a substitute generator.
|
||||
for pcm in tts.stream(case['raw'], language='de', seed=seed, normalize=True):
|
||||
if first is None:
|
||||
first = time.monotonic()-start
|
||||
assert np.isfinite(pcm).all() and len(pcm) > 0
|
||||
chunks.append(pcm)
|
||||
assert chunks
|
||||
pcm = np.concatenate(chunks)
|
||||
sf.write(OUT/(name+'.wav'), pcm, 24000, subtype='PCM_16')
|
||||
wall = time.monotonic()-start
|
||||
row.update(ok=True, seconds=wall, audio_seconds=len(pcm)/24000,
|
||||
rtf=wall/(len(pcm)/24000), first_sentence_seconds=first,
|
||||
chunks=len(chunks), rms=float(np.sqrt(np.mean(pcm.astype(float)**2))),
|
||||
peak=float(np.max(np.abs(pcm))), peak_rss_kib=resource.getrusage(resource.RUSAGE_SELF).ru_maxrss,
|
||||
retry_trigger_count=sum(bool(x) for x in checks),
|
||||
retry_reasons=[x for x in checks if x])
|
||||
except Exception as exc:
|
||||
row.update(ok=False, seconds=time.monotonic()-start,
|
||||
error_type=type(exc).__name__, error=str(exc)[:400])
|
||||
finally:
|
||||
signal.alarm(0)
|
||||
results.append(row)
|
||||
(ROOT/'results.json').write_text(json.dumps(results, ensure_ascii=False, indent=2))
|
||||
print(json.dumps(row), flush=True)
|
||||
@@ -0,0 +1,60 @@
|
||||
[
|
||||
{
|
||||
"id": "onset",
|
||||
"raw": "Gute Frage. Die kurze Antwort: Für einen QNAP-Tod sofort auf den anderen umschalten funktioniert mit euren zwei getrennten NAS-Geräten nicht.",
|
||||
"prepared": "Gute Frage. Die kurze Antwort: Für einen QNAP-Tod sofort auf den anderen umschalten funktioniert mit euren zwei getrennten NAS-Geräten nicht.",
|
||||
"chunks": [
|
||||
"Gute Frage.",
|
||||
"Die kurze Antwort: Für einen QNAP-Tod sofort auf den anderen umschalten funktioniert mit euren zwei getrennten NAS-Geräten nicht."
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "previous-failure",
|
||||
"raw": "Wichtig vorab: Euer Cluster hat schon, was failover-mäßig zählt — der Shared Storage (QNAP).",
|
||||
"prepared": "Wichtig vorab: Euer Cluster hat schon, was failover-mäßig zählt — der Shared Storage (QNAP).",
|
||||
"chunks": [
|
||||
"Wichtig vorab: Euer Cluster hat schon, was failover-mäßig zählt — der Shared Storage (QNAP)."
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "story",
|
||||
"raw": "Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie: Das hat wunderbar funktioniert.",
|
||||
"prepared": "Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie: Das hat wunderbar funktioniert.",
|
||||
"chunks": [
|
||||
"Wenn du magst, erzähle ich dir eine kurze Geschichte.",
|
||||
"Anna öffnete das Fenster und hörte drei Vögel singen.",
|
||||
"Auf dem Tisch lagen sieben Bücher und eine rote Tasse.",
|
||||
"Zum Schluss sagte sie: Das hat wunderbar funktioniert."
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "technical",
|
||||
"raw": "Home Assistant läuft in Docker auf Unraid. Die SSD hat 47 Grad Celsius. Das Logfile enthält keinen Fehler. Die Datei ist 512 MiB groß und die Verbindung überträgt 100 Mbit pro Sekunde. Um 18:30 CEST startet der nächste Scan.",
|
||||
"prepared": "Home Assistant läuft in Docker auf Anraid. Die Es Es De hat 47 Grad Celsius. Das Logdatei enthält keinen Fehler. Die Datei ist 512 Mebibyte groß und die Verbindung überträgt 100 Megabit pro Sekunde. Um 18 Uhr 30 Ce E Es Te startet der nächste Scan.",
|
||||
"chunks": [
|
||||
"Home Assistant läuft in Docker auf Anraid.",
|
||||
"Die Es Es De hat 47 Grad Celsius.",
|
||||
"Das Logdatei enthält keinen Fehler.",
|
||||
"Die Datei ist 512 Mebibyte groß und die Verbindung überträgt 100 Megabit pro Sekunde.",
|
||||
"Um 18 Uhr 30 Ce E Es Te startet der nächste Scan."
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "long",
|
||||
"raw": "Am frühen Morgen öffnete Anna das Fenster und blickte in den Garten. Auf der alten Mauer saßen drei Vögel, die trotz des Regens fröhlich sangen. Sie stellte eine rote Tasse auf den Tisch und schlug ihr Buch auf. Plötzlich klingelte es an der Tür. Ihr Nachbar hatte einen kleinen Kuchen gebacken und wollte ihn mit ihr teilen. Gemeinsam setzten sie sich ans Fenster. Sie erzählten sich Geschichten von ihren Reisen und lachten über ein verlorenes Paar Schuhe. Als die Sonne durch die Wolken brach, gingen sie eine Runde spazieren. Auf dem Heimweg kauften sie sieben Äpfel und frisches Brot. Anna dachte, dass ein schöner Tag manchmal ganz unscheinbar beginnt. Zum Abschied sagte sie: Morgen treffen wir uns wieder hier.",
|
||||
"prepared": "Am frühen Morgen öffnete Anna das Fenster und blickte in den Garten. Auf der alten Mauer saßen drei Vögel, die trotz des Regens fröhlich sangen. Sie stellte eine rote Tasse auf den Tisch und schlug ihr Buch auf. Plötzlich klingelte es an der Tür. Ihr Nachbar hatte einen kleinen Kuchen gebacken und wollte ihn mit ihr teilen. Gemeinsam setzten sie sich ans Fenster. Sie erzählten sich Geschichten von ihren Reisen und lachten über ein verlorenes Paar Schuhe. Als die Sonne durch die Wolken brach, gingen sie eine Runde spazieren. Auf dem Heimweg kauften sie sieben Äpfel und frisches Brot. Anna dachte, dass ein schöner Tag manchmal ganz unscheinbar beginnt. Zum Abschied sagte sie: Morgen treffen wir uns wieder hier.",
|
||||
"chunks": [
|
||||
"Am frühen Morgen öffnete Anna das Fenster und blickte in den Garten.",
|
||||
"Auf der alten Mauer saßen drei Vögel, die trotz des Regens fröhlich sangen.",
|
||||
"Sie stellte eine rote Tasse auf den Tisch und schlug ihr Buch auf.",
|
||||
"Plötzlich klingelte es an der Tür.",
|
||||
"Ihr Nachbar hatte einen kleinen Kuchen gebacken und wollte ihn mit ihr teilen.",
|
||||
"Gemeinsam setzten sie sich ans Fenster.",
|
||||
"Sie erzählten sich Geschichten von ihren Reisen und lachten über ein verlorenes Paar Schuhe.",
|
||||
"Als die Sonne durch die Wolken brach, gingen sie eine Runde spazieren.",
|
||||
"Auf dem Heimweg kauften sie sieben Äpfel und frisches Brot.",
|
||||
"Anna dachte, dass ein schöner Tag manchmal ganz unscheinbar beginnt.",
|
||||
"Zum Abschied sagte sie: Morgen treffen wir uns wieder hier."
|
||||
]
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,10 @@
|
||||
[
|
||||
{
|
||||
"id": "guided-technical",
|
||||
"text": "[en]Home Assistant[/en] läuft in [en]Docker[/en] auf [en]Unraid[/en]. Die ess ess deh hat siebenundvierzig Grad Celsius. Das [en]Logfile[/en] enthält keinen Fehler. Die Datei ist fünfhundertzwölf [en]Mebibyte[/en] groß und die Verbindung überträgt einhundert Megabit pro Sekunde. Um achtzehn Uhr dreißig mitteleuropäischer Sommerzeit startet der nächste [en]Scan[/en]."
|
||||
},
|
||||
{
|
||||
"id": "guided-previous",
|
||||
"text": "Wichtig vorab: Euer [en]Cluster[/en] hat schon, was [en]Failover[/en]-mäßig zählt: der [en]Shared Storage[/en]. Kuh enn ah peh."
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,12 @@
|
||||
[
|
||||
{
|
||||
"id": "guided-technical",
|
||||
"seconds": 0.7243283540010452,
|
||||
"audio_seconds": 22.04
|
||||
},
|
||||
{
|
||||
"id": "guided-previous",
|
||||
"seconds": 0.2696464719992946,
|
||||
"audio_seconds": 8.75
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,12 @@
|
||||
[
|
||||
{
|
||||
"file": "guided-previous.wav",
|
||||
"text": "Wichtig vorab, euer Cluster hat schon, was Failover-mäßig zählt, der shared storage. QNAP",
|
||||
"seconds": 4.984640398994088
|
||||
},
|
||||
{
|
||||
"file": "guided-technical.wav",
|
||||
"text": "Home Assistant läuft in Docker of Unraid. Die SSD hat 47 Grad Celsius. Das Logweile enthält keinen Fehler. Die Datei ist 512 Mbeb groß und die Verbindung überträgt 100 Mbit pro Sekunde. Um 18.30 Uhr mitteleuropäischer Sommerzeit startet der nächste Gern.",
|
||||
"seconds": 1.9984165279893205
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,21 @@
|
||||
"""Post-hoc pronunciation control; kept separate from the fixed main comparison."""
|
||||
import os
|
||||
os.environ.update(CUDA_VISIBLE_DEVICES='', HF_HUB_OFFLINE='1', OPENBLAS_NUM_THREADS='1', OMP_NUM_THREADS='4')
|
||||
from pathlib import Path
|
||||
import json
|
||||
import time
|
||||
import numpy as np
|
||||
import soundfile as sf
|
||||
from articulino_onnx import TTS
|
||||
ROOT=Path('/data/athena-articulino-test-20261026')
|
||||
cases=[dict(id='guided-technical',text='[en]Home Assistant[/en] läuft in [en]Docker[/en] auf [en]Unraid[/en]. Die ess ess deh hat siebenundvierzig Grad Celsius. Das [en]Logfile[/en] enthält keinen Fehler. Die Datei ist fünfhundertzwölf [en]Mebibyte[/en] groß und die Verbindung überträgt einhundert Megabit pro Sekunde. Um achtzehn Uhr dreißig mitteleuropäischer Sommerzeit startet der nächste [en]Scan[/en].'),
|
||||
dict(id='guided-previous',text='Wichtig vorab: Euer [en]Cluster[/en] hat schon, was [en]Failover[/en]-mäßig zählt: der [en]Shared Storage[/en]. Kuh enn ah peh.')]
|
||||
(ROOT/'guided-cases.json').write_text(json.dumps(cases,ensure_ascii=False,indent=2))
|
||||
tts=TTS.from_pretrained(ROOT/'model',precision='fp32',providers=['CPUExecutionProvider'],threads=4)
|
||||
tts.set_voice('/opt/athena-deck-dev/runtime/state/speech-voices/Anna/reference.wav')
|
||||
rows=[]
|
||||
for case in cases:
|
||||
start=time.monotonic();parts=list(tts.stream(case['text'],language='de',seed=42,normalize=True));audio=np.concatenate(parts)
|
||||
sf.write(ROOT/'outputs'/(case['id']+'.wav'),audio,24000,subtype='PCM_16')
|
||||
rows.append(dict(id=case['id'],seconds=time.monotonic()-start,audio_seconds=len(audio)/24000))
|
||||
(ROOT/'guided-results.json').write_text(json.dumps(rows,indent=2));print(json.dumps(rows),flush=True)
|
||||
@@ -0,0 +1,47 @@
|
||||
[
|
||||
{
|
||||
"file": "config.json",
|
||||
"bytes": 780,
|
||||
"sha256": "407b7553796634d21367546508755763349cf7ee6561842f07bc9d18f7b3ce44"
|
||||
},
|
||||
{
|
||||
"file": "LICENSE",
|
||||
"bytes": 11358,
|
||||
"sha256": "cfc7749b96f63bd31c3c42b5c471bf756814053e847c10f3eb003417bc523d30"
|
||||
},
|
||||
{
|
||||
"file": "NOTICE",
|
||||
"bytes": 2155,
|
||||
"sha256": "ab6b0eea89750bed940a4d278cd2906235323cb563bb49adf0388361815d5a60"
|
||||
},
|
||||
{
|
||||
"file": "SHA256SUMS",
|
||||
"bytes": 2434,
|
||||
"sha256": "bd21d9834b9ed9ce8befdbf40786ba640e7869b8bfda1ef9cdda2bd254c4cc06"
|
||||
},
|
||||
{
|
||||
"file": "fp32/decoder.onnx",
|
||||
"bytes": 90822713,
|
||||
"sha256": "85a68f4a93af28452d3085740f64124cfbbe465f54348b035fad646542d0226f"
|
||||
},
|
||||
{
|
||||
"file": "fp32/dit_step.onnx",
|
||||
"bytes": 100873462,
|
||||
"sha256": "57b1d2a741b5044cb2769239e89d1c511eb5b7ffa79a55c11cde4d7670010747"
|
||||
},
|
||||
{
|
||||
"file": "fp32/encoder.onnx",
|
||||
"bytes": 90780308,
|
||||
"sha256": "0b3770a2d181ac747bb0e626293071446c6a0285f54292773256309ba09e8742"
|
||||
},
|
||||
{
|
||||
"file": "fp32/text.onnx",
|
||||
"bytes": 83568088,
|
||||
"sha256": "47bfc4a50f6ad5726fa43a549ecb247efc0d10ef6e333c7fd3ea4414e8b0c2a9"
|
||||
},
|
||||
{
|
||||
"file": "fp32/voice.onnx",
|
||||
"bytes": 170915170,
|
||||
"sha256": "3215a71aaab64fb116edb823e0f13c7001a588979d875f79c11a20024a9f88a3"
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,22 @@
|
||||
[
|
||||
{
|
||||
"id": "onset",
|
||||
"prepared": "Gute Frage. Die kurze Antwort: Für einen QNAP-Tod sofort auf den anderen umschalten funktioniert mit euren zwei getrennten enn ah ess-Geräten nicht."
|
||||
},
|
||||
{
|
||||
"id": "previous-failure",
|
||||
"prepared": "Wichtig vorab: Euer Cluster hat schon, was failover-mäßig zählt — der Shared Storage (QNAP)."
|
||||
},
|
||||
{
|
||||
"id": "story",
|
||||
"prepared": "Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie: Das hat wunderbar funktioniert."
|
||||
},
|
||||
{
|
||||
"id": "technical",
|
||||
"prepared": "Home Assistant läuft in Docker auf Unraid. Die ess ess deh hat siebenundvierzig Grad Celsius. Das Logfile enthält keinen Fehler. Die Datei ist fünfhundertzwölf Mebibyte groß und die Verbindung überträgt einhundert Megabit pro Sekunde. Um achtzehn Uhr dreißig CEST startet der nächste Scan."
|
||||
},
|
||||
{
|
||||
"id": "long",
|
||||
"prepared": "Am frühen Morgen öffnete Anna das Fenster und blickte in den Garten. Auf der alten Mauer saßen drei Vögel, die trotz des Regens fröhlich sangen. Sie stellte eine rote Tasse auf den Tisch und schlug ihr Buch auf. Plötzlich klingelte es an der Tür. Ihr Nachbar hatte einen kleinen Kuchen gebacken und wollte ihn mit ihr teilen. Gemeinsam setzten sie sich ans Fenster. Sie erzählten sich Geschichten von ihren Reisen und lachten über ein verlorenes Paar Schuhe. Als die Sonne durch die Wolken brach, gingen sie eine Runde spazieren. Auf dem Heimweg kauften sie sieben Äpfel und frisches Brot. Anna dachte, dass ein schöner Tag manchmal ganz unscheinbar beginnt. Zum Abschied sagte sie: Morgen treffen wir uns wieder hier."
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,15 @@
|
||||
articulino-onnx @ file:///data/athena-articulino-test-20261026/source
|
||||
cffi==2.1.1
|
||||
coloredlogs==15.0.1
|
||||
docopt==0.6.2
|
||||
flatbuffers==25.12.19
|
||||
humanfriendly==10.0
|
||||
mpmath==1.3.0
|
||||
num2words==0.5.14
|
||||
numpy==2.2.6
|
||||
onnxruntime==1.23.2
|
||||
packaging==26.3
|
||||
protobuf==7.36.2
|
||||
pycparser==3.12
|
||||
soundfile==0.13.1
|
||||
sympy==1.14.0
|
||||
@@ -0,0 +1,162 @@
|
||||
[
|
||||
{
|
||||
"case_id": "onset",
|
||||
"seed": 42,
|
||||
"name": "onset-42",
|
||||
"ok": true,
|
||||
"seconds": 0.4395096439984627,
|
||||
"audio_seconds": 12.47,
|
||||
"rtf": 0.035245360384800535,
|
||||
"first_sentence_seconds": 0.184281944999384,
|
||||
"chunks": 2,
|
||||
"rms": 0.06815467753650559,
|
||||
"peak": 0.7687103152275085,
|
||||
"peak_rss_kib": 852176,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": []
|
||||
},
|
||||
{
|
||||
"case_id": "previous-failure",
|
||||
"seed": 42,
|
||||
"name": "previous-failure-42",
|
||||
"ok": true,
|
||||
"seconds": 0.2097375289995398,
|
||||
"audio_seconds": 7.0,
|
||||
"rtf": 0.029962504142791398,
|
||||
"first_sentence_seconds": 0.20728103099827422,
|
||||
"chunks": 1,
|
||||
"rms": 0.07657487030322592,
|
||||
"peak": 0.6998209357261658,
|
||||
"peak_rss_kib": 852176,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": []
|
||||
},
|
||||
{
|
||||
"case_id": "story",
|
||||
"seed": 42,
|
||||
"name": "story-42",
|
||||
"ok": true,
|
||||
"seconds": 0.4777172239992069,
|
||||
"audio_seconds": 15.69,
|
||||
"rtf": 0.03044724181001956,
|
||||
"first_sentence_seconds": 0.11163354699965566,
|
||||
"chunks": 4,
|
||||
"rms": 0.06701070914883189,
|
||||
"peak": 0.6266385316848755,
|
||||
"peak_rss_kib": 852176,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": []
|
||||
},
|
||||
{
|
||||
"case_id": "technical",
|
||||
"seed": 42,
|
||||
"name": "technical-42",
|
||||
"ok": true,
|
||||
"seconds": 0.6439054239999678,
|
||||
"audio_seconds": 21.04,
|
||||
"rtf": 0.030603869961975654,
|
||||
"first_sentence_seconds": 0.1020665040014137,
|
||||
"chunks": 5,
|
||||
"rms": 0.07000693834760885,
|
||||
"peak": 0.8422807455062866,
|
||||
"peak_rss_kib": 852176,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": []
|
||||
},
|
||||
{
|
||||
"case_id": "long",
|
||||
"seed": 42,
|
||||
"name": "long-42",
|
||||
"ok": true,
|
||||
"seconds": 1.5661381909994816,
|
||||
"audio_seconds": 52.5,
|
||||
"rtf": 0.029831203638085363,
|
||||
"first_sentence_seconds": 0.14944539700081805,
|
||||
"chunks": 11,
|
||||
"rms": 0.07023502021022318,
|
||||
"peak": 0.949999988079071,
|
||||
"peak_rss_kib": 852176,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": []
|
||||
},
|
||||
{
|
||||
"case_id": "onset",
|
||||
"seed": 43,
|
||||
"name": "onset-43",
|
||||
"ok": true,
|
||||
"seconds": 0.36215237400028855,
|
||||
"audio_seconds": 12.47,
|
||||
"rtf": 0.029041890457120172,
|
||||
"first_sentence_seconds": 0.10985152500143158,
|
||||
"chunks": 2,
|
||||
"rms": 0.06869237465237911,
|
||||
"peak": 0.7779256105422974,
|
||||
"peak_rss_kib": 887172,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": []
|
||||
},
|
||||
{
|
||||
"case_id": "previous-failure",
|
||||
"seed": 43,
|
||||
"name": "previous-failure-43",
|
||||
"ok": true,
|
||||
"seconds": 0.2058549959983793,
|
||||
"audio_seconds": 7.0,
|
||||
"rtf": 0.029407856571197044,
|
||||
"first_sentence_seconds": 0.20330519399794866,
|
||||
"chunks": 1,
|
||||
"rms": 0.0746799508786578,
|
||||
"peak": 0.6240502595901489,
|
||||
"peak_rss_kib": 887172,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": []
|
||||
},
|
||||
{
|
||||
"case_id": "story",
|
||||
"seed": 43,
|
||||
"name": "story-43",
|
||||
"ok": true,
|
||||
"seconds": 0.4851364099995408,
|
||||
"audio_seconds": 15.69,
|
||||
"rtf": 0.030920102613100114,
|
||||
"first_sentence_seconds": 0.1131621249987802,
|
||||
"chunks": 4,
|
||||
"rms": 0.06894592250118584,
|
||||
"peak": 0.7724668979644775,
|
||||
"peak_rss_kib": 887172,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": []
|
||||
},
|
||||
{
|
||||
"case_id": "technical",
|
||||
"seed": 43,
|
||||
"name": "technical-43",
|
||||
"ok": true,
|
||||
"seconds": 0.6431045110002742,
|
||||
"audio_seconds": 21.04,
|
||||
"rtf": 0.030565803754765888,
|
||||
"first_sentence_seconds": 0.10332906100302353,
|
||||
"chunks": 5,
|
||||
"rms": 0.06795508065020363,
|
||||
"peak": 0.949999988079071,
|
||||
"peak_rss_kib": 887172,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": []
|
||||
},
|
||||
{
|
||||
"case_id": "long",
|
||||
"seed": 43,
|
||||
"name": "long-43",
|
||||
"ok": true,
|
||||
"seconds": 1.5668999810004607,
|
||||
"audio_seconds": 52.5,
|
||||
"rtf": 0.0298457139238183,
|
||||
"first_sentence_seconds": 0.15024985499985632,
|
||||
"chunks": 11,
|
||||
"rms": 0.0690657599249445,
|
||||
"peak": 0.9500000476837158,
|
||||
"peak_rss_kib": 887172,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": []
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,137 @@
|
||||
{
|
||||
"method": "Same German preparation, number expansion <=999, case and punctuation normalized. Combined TTS+STT error, not a pure TTS rate.",
|
||||
"summary": {
|
||||
"articulino": {
|
||||
"all": {
|
||||
"cases": 10,
|
||||
"words": 474,
|
||||
"edits": 31,
|
||||
"wer": 0.06540084388185655
|
||||
},
|
||||
"plain": {
|
||||
"cases": 4,
|
||||
"words": 310,
|
||||
"edits": 0,
|
||||
"wer": 0.0
|
||||
},
|
||||
"technical": {
|
||||
"cases": 6,
|
||||
"words": 164,
|
||||
"edits": 31,
|
||||
"wer": 0.18902439024390244
|
||||
}
|
||||
}
|
||||
},
|
||||
"rows": [
|
||||
{
|
||||
"arm": "articulino",
|
||||
"file": "long-42.wav",
|
||||
"case_id": "long",
|
||||
"reference_words": 119,
|
||||
"edits": 0,
|
||||
"wer": 0.0,
|
||||
"recognized_words": 119,
|
||||
"stt_text": "am frühen Morgen öffnete Anna das Fenster und blickte in den Garten. Auf der alten Mauer saßen drei Vögel, die trotz des Regens fröhlich sangen. Sie stellte eine rote Tasse auf den Tisch und schlug ihr Buch auf. Plötzlich klingelte es an der Tür. Ihr Nachbar hatte einen kleinen Kuchen gebacken und wollte ihn mit ihr teilen. Gemeinsam setzten sie sich ans Fenster, sie erzählten sich Geschichten von ihren Reisen und lachten über ein verlorenes Paar Schuhe. Als die Sonne durch die Wolken brach, gingen sie eine runde spazieren. Auf dem Heimweg kauften sie sieben Äpfel und frisches Brot. Anna dachte, dass ein schöner Tag manchmal ganz unscheinbar beginnt. Zum Abschied sagte sie Morgen treffen wir uns wieder hier.",
|
||||
"error_type": null
|
||||
},
|
||||
{
|
||||
"arm": "articulino",
|
||||
"file": "long-43.wav",
|
||||
"case_id": "long",
|
||||
"reference_words": 119,
|
||||
"edits": 0,
|
||||
"wer": 0.0,
|
||||
"recognized_words": 119,
|
||||
"stt_text": "am frühen Morgen öffnete Anna das Fenster und blickte in den Garten. Auf der alten Mauer saßen drei Vögel, die trotz des Regens fröhlich sangen. Sie stellte eine rote Tasse auf den Tisch und schlug ihr Buch auf. Plötzlich klingelte es an der Tür. Ihr Nachbar hatte einen kleinen Kuchen gebacken und wollte ihn mit ihr teilen. Gemeinsam setzten sie sich ans Fenster. Sie erzählten sich Geschichten von ihren Reisen und lachten über ein verlorenes Paar Schuhe. Als die Sonne durch die Wolken brach, gingen sie eine Runde spazieren. Auf dem Heimweg kauften sie sieben Äpfel und frisches Brot. Anna dachte, dass ein schöner Tag manchmal ganz unscheinbar beginnt. Zum Abschied sagte sie Morgen treffen wir uns wieder hier.",
|
||||
"error_type": null
|
||||
},
|
||||
{
|
||||
"arm": "articulino",
|
||||
"file": "onset-42.wav",
|
||||
"case_id": "onset",
|
||||
"reference_words": 22,
|
||||
"edits": 4,
|
||||
"wer": 0.18181818181818182,
|
||||
"recognized_words": 20,
|
||||
"stt_text": "Gute Frage. Die kurze Antwort. Für einen Knapptod sofort auf den anderen Umschalten funktioniert mit euren zweigetrennten NAS Geräten nicht.",
|
||||
"error_type": null
|
||||
},
|
||||
{
|
||||
"arm": "articulino",
|
||||
"file": "onset-43.wav",
|
||||
"case_id": "onset",
|
||||
"reference_words": 22,
|
||||
"edits": 2,
|
||||
"wer": 0.09090909090909091,
|
||||
"recognized_words": 21,
|
||||
"stt_text": "Gute Frage. Die kurze Antwort Für einen Knapptod sofort auf den anderen Umschalten funktioniert, mit euren zwei getrennten NAS Geräten nicht.",
|
||||
"error_type": null
|
||||
},
|
||||
{
|
||||
"arm": "articulino",
|
||||
"file": "previous-failure-42.wav",
|
||||
"case_id": "previous-failure",
|
||||
"reference_words": 14,
|
||||
"edits": 3,
|
||||
"wer": 0.21428571428571427,
|
||||
"recognized_words": 14,
|
||||
"stt_text": "Wichtig vorab, euer Kloster hat schon was failover-mäßig, zählt der Charlet Storage knapp.",
|
||||
"error_type": null
|
||||
},
|
||||
{
|
||||
"arm": "articulino",
|
||||
"file": "previous-failure-43.wav",
|
||||
"case_id": "previous-failure",
|
||||
"reference_words": 14,
|
||||
"edits": 3,
|
||||
"wer": 0.21428571428571427,
|
||||
"recognized_words": 14,
|
||||
"stt_text": "Wichtig vorab, euer Kloster hat schon was Failover-mäßig, zählt der Charret Storage knapp.",
|
||||
"error_type": null
|
||||
},
|
||||
{
|
||||
"arm": "articulino",
|
||||
"file": "story-42.wav",
|
||||
"case_id": "story",
|
||||
"reference_words": 36,
|
||||
"edits": 0,
|
||||
"wer": 0.0,
|
||||
"recognized_words": 36,
|
||||
"stt_text": "Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie Das hat wunderbar funktioniert.",
|
||||
"error_type": null
|
||||
},
|
||||
{
|
||||
"arm": "articulino",
|
||||
"file": "story-43.wav",
|
||||
"case_id": "story",
|
||||
"reference_words": 36,
|
||||
"edits": 0,
|
||||
"wer": 0.0,
|
||||
"recognized_words": 36,
|
||||
"stt_text": "Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie Das hat wunderbar funktioniert,",
|
||||
"error_type": null
|
||||
},
|
||||
{
|
||||
"arm": "articulino",
|
||||
"file": "technical-42.wav",
|
||||
"case_id": "technical",
|
||||
"reference_words": 46,
|
||||
"edits": 10,
|
||||
"wer": 0.21739130434782608,
|
||||
"recognized_words": 42,
|
||||
"stt_text": "Home Assistant läuft den Docker auf Unrate. Die SSD hat 47 Grad Celsius. Das Logfehle enthält keinen Fehler. Die Datei ist 512 Mb groß und die Verbindung überträgt 100 Mbit pro Sekunde. Um 18.30 Uhr startet der nächste Scern.",
|
||||
"error_type": null
|
||||
},
|
||||
{
|
||||
"arm": "articulino",
|
||||
"file": "technical-43.wav",
|
||||
"case_id": "technical",
|
||||
"reference_words": 46,
|
||||
"edits": 9,
|
||||
"wer": 0.1956521739130435,
|
||||
"recognized_words": 42,
|
||||
"stt_text": "Home Assistant läuft in Docker auf Unrate. Die SSD hat 47 Grad Celsius. Das Logfiele enthält keinen Fehler. Die Datei ist 512 Mb groß und die Verbindung überträgt 100 Mbit pro Sekunde. Um 18.30 Uhr startet der nächste Stern.",
|
||||
"error_type": null
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,64 @@
|
||||
"""Transparent STT round-trip distance, not a human naturalness or TTS-only score."""
|
||||
import json
|
||||
import re
|
||||
import sys
|
||||
import unicodedata
|
||||
import os
|
||||
from pathlib import Path
|
||||
ROOT = Path(__file__).resolve().parent
|
||||
search = ([Path(os.environ['DECK_SOURCE'])] if os.environ.get('DECK_SOURCE') else [])
|
||||
search += [path for parent in ROOT.parents for path in (parent, parent/'repo')]
|
||||
source = next(path for path in search if (path/'speech_text.py').is_file())
|
||||
sys.path.insert(0, str(source))
|
||||
from speech_text import prepare_for_speech
|
||||
|
||||
def de_number(n):
|
||||
basic=['null','eins','zwei','drei','vier','fünf','sechs','sieben','acht','neun',
|
||||
'zehn','elf','zwölf','dreizehn','vierzehn','fünfzehn','sechzehn','siebzehn','achtzehn','neunzehn']
|
||||
if n < 20:
|
||||
return basic[n]
|
||||
if n < 100:
|
||||
tens=['','','zwanzig','dreißig','vierzig','fünfzig','sechzig','siebzig','achtzig','neunzig']
|
||||
return (('ein' if n%10 == 1 else basic[n%10])+'und' if n%10 else '')+tens[n//10]
|
||||
if n < 1000:
|
||||
return ('ein' if n//100 == 1 else basic[n//100])+'hundert'+(de_number(n%100) if n%100 else '')
|
||||
return str(n)
|
||||
|
||||
def tokens(text):
|
||||
text=prepare_for_speech(text,'German')
|
||||
text=re.sub(r'\b\d{1,3}\b',lambda m:de_number(int(m[0])),text)
|
||||
text=unicodedata.normalize('NFC',text).casefold().replace('ß','ss')
|
||||
return re.findall(r'[^\W_]+',text,re.UNICODE)
|
||||
|
||||
def distance(a,b):
|
||||
previous=list(range(len(b)+1))
|
||||
for i,x in enumerate(a,1):
|
||||
current=[i]
|
||||
for j,y in enumerate(b,1):
|
||||
current.append(min(current[-1]+1,previous[j]+1,previous[j-1]+(x!=y)))
|
||||
previous=current
|
||||
return previous[-1]
|
||||
|
||||
cases={x['id']:x for x in json.loads((ROOT/'cases.json').read_text())}
|
||||
rows=[]
|
||||
for filename in ['transcriptions.json']:
|
||||
p=ROOT/filename
|
||||
if not p.exists():continue
|
||||
for row in json.loads(p.read_text()):
|
||||
ident=row['file'].rsplit('-',1)[0]
|
||||
a=tokens(cases[ident]['prepared']);b=tokens(row.get('text',''))
|
||||
edits=distance(a,b)
|
||||
rows.append(dict(arm='articulino',file=row['file'],case_id=ident,
|
||||
reference_words=len(a),edits=edits,wer=edits/len(a),
|
||||
recognized_words=len(b),stt_text=row.get('text'),
|
||||
error_type=row.get('error_type')))
|
||||
summary={}
|
||||
for arm in sorted({x['arm'] for x in rows}):
|
||||
summary[arm]={}
|
||||
for group in ['all','plain','technical']:
|
||||
selected=[x for x in rows if x['arm']==arm and (group=='all' or (
|
||||
x['case_id'] in ['story','long'] if group=='plain' else x['case_id'] in ['onset','previous-failure','technical']))]
|
||||
words=sum(x['reference_words'] for x in selected);edits=sum(x['edits'] for x in selected)
|
||||
summary[arm][group]=dict(cases=len(selected),words=words,edits=edits,wer=edits/words if words else None)
|
||||
(ROOT/'roundtrip-scores.json').write_text(json.dumps(dict(method='Same German preparation, number expansion <=999, case and punctuation normalized. Combined TTS+STT error, not a pure TTS rate.',summary=summary,rows=rows),ensure_ascii=False,indent=2))
|
||||
print(json.dumps(summary,indent=2))
|
||||
@@ -0,0 +1,37 @@
|
||||
{
|
||||
"precision": "fp32",
|
||||
"load_seconds": 0.589070936999633,
|
||||
"voice_seconds": 0.1604910630012455,
|
||||
"providers": {
|
||||
"encoder": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"voice": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"text": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"dit_step": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"decoder": [
|
||||
"CPUExecutionProvider"
|
||||
]
|
||||
},
|
||||
"threads": 4,
|
||||
"affinity": [
|
||||
2,
|
||||
3,
|
||||
4,
|
||||
5,
|
||||
8,
|
||||
9,
|
||||
10,
|
||||
11
|
||||
],
|
||||
"uniform_rate": true,
|
||||
"retry_broken": true,
|
||||
"sentence_pause_seconds": 0.15,
|
||||
"reference_max_seconds": 8
|
||||
}
|
||||
@@ -0,0 +1,38 @@
|
||||
{
|
||||
"repo": "eigenhand/Articulino-DE-EN-Realtime-Stream-TTS-ONNX",
|
||||
"revision": "a760ce8d513534111c7679751869fa4c45ef0e54",
|
||||
"gated": false,
|
||||
"files": [
|
||||
".gitattributes",
|
||||
"LICENSE",
|
||||
"NOTICE",
|
||||
"README.md",
|
||||
"SHA256SUMS",
|
||||
"articulino_onnx/__init__.py",
|
||||
"articulino_onnx/dsp.py",
|
||||
"articulino_onnx/engine.py",
|
||||
"articulino_onnx/frontend/__init__.py",
|
||||
"articulino_onnx/frontend/data/abbreviations.json",
|
||||
"articulino_onnx/frontend/data/units.json",
|
||||
"articulino_onnx/frontend/german.py",
|
||||
"articulino_onnx/text.py",
|
||||
"articulino_onnx/tts.py",
|
||||
"config.json",
|
||||
"fp16/decoder.onnx",
|
||||
"fp16/dit_step.onnx",
|
||||
"fp16/encoder.onnx",
|
||||
"fp16/text.onnx",
|
||||
"fp16/voice.onnx",
|
||||
"fp32/decoder.onnx",
|
||||
"fp32/dit_step.onnx",
|
||||
"fp32/encoder.onnx",
|
||||
"fp32/text.onnx",
|
||||
"fp32/voice.onnx",
|
||||
"int8/decoder.onnx",
|
||||
"int8/dit_step.onnx",
|
||||
"int8/encoder.onnx",
|
||||
"int8/text.onnx",
|
||||
"int8/voice.onnx",
|
||||
"pyproject.toml"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,52 @@
|
||||
{
|
||||
"runs": 10,
|
||||
"complete": 10,
|
||||
"generation_seconds": 6.600156283995602,
|
||||
"audio_seconds": 217.4,
|
||||
"rtf": 0.030359504526198722,
|
||||
"realtime_speed": 32.9386139729998,
|
||||
"peak_rss_gib": 0.8460731506347656,
|
||||
"first_sentence_median_seconds": 0.13130376099979912,
|
||||
"first_sentence_range_seconds": [
|
||||
0.1020665040014137,
|
||||
0.20728103099827422
|
||||
],
|
||||
"retry_trigger_count": 0,
|
||||
"setup": {
|
||||
"precision": "fp32",
|
||||
"load_seconds": 0.589070936999633,
|
||||
"voice_seconds": 0.1604910630012455,
|
||||
"providers": {
|
||||
"encoder": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"voice": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"text": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"dit_step": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"decoder": [
|
||||
"CPUExecutionProvider"
|
||||
]
|
||||
},
|
||||
"threads": 4,
|
||||
"affinity": [
|
||||
2,
|
||||
3,
|
||||
4,
|
||||
5,
|
||||
8,
|
||||
9,
|
||||
10,
|
||||
11
|
||||
],
|
||||
"uniform_rate": true,
|
||||
"retry_broken": true,
|
||||
"sentence_pause_seconds": 0.15,
|
||||
"reference_max_seconds": 8
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,52 @@
|
||||
[
|
||||
{
|
||||
"file": "long-42.wav",
|
||||
"text": "am frühen Morgen öffnete Anna das Fenster und blickte in den Garten. Auf der alten Mauer saßen drei Vögel, die trotz des Regens fröhlich sangen. Sie stellte eine rote Tasse auf den Tisch und schlug ihr Buch auf. Plötzlich klingelte es an der Tür. Ihr Nachbar hatte einen kleinen Kuchen gebacken und wollte ihn mit ihr teilen. Gemeinsam setzten sie sich ans Fenster, sie erzählten sich Geschichten von ihren Reisen und lachten über ein verlorenes Paar Schuhe. Als die Sonne durch die Wolken brach, gingen sie eine runde spazieren. Auf dem Heimweg kauften sie sieben Äpfel und frisches Brot. Anna dachte, dass ein schöner Tag manchmal ganz unscheinbar beginnt. Zum Abschied sagte sie Morgen treffen wir uns wieder hier.",
|
||||
"seconds": 6.282964706013445
|
||||
},
|
||||
{
|
||||
"file": "long-43.wav",
|
||||
"text": "am frühen Morgen öffnete Anna das Fenster und blickte in den Garten. Auf der alten Mauer saßen drei Vögel, die trotz des Regens fröhlich sangen. Sie stellte eine rote Tasse auf den Tisch und schlug ihr Buch auf. Plötzlich klingelte es an der Tür. Ihr Nachbar hatte einen kleinen Kuchen gebacken und wollte ihn mit ihr teilen. Gemeinsam setzten sie sich ans Fenster. Sie erzählten sich Geschichten von ihren Reisen und lachten über ein verlorenes Paar Schuhe. Als die Sonne durch die Wolken brach, gingen sie eine Runde spazieren. Auf dem Heimweg kauften sie sieben Äpfel und frisches Brot. Anna dachte, dass ein schöner Tag manchmal ganz unscheinbar beginnt. Zum Abschied sagte sie Morgen treffen wir uns wieder hier.",
|
||||
"seconds": 4.989916165010072
|
||||
},
|
||||
{
|
||||
"file": "onset-42.wav",
|
||||
"text": "Gute Frage. Die kurze Antwort. Für einen Knapptod sofort auf den anderen Umschalten funktioniert mit euren zweigetrennten NAS Geräten nicht.",
|
||||
"seconds": 1.299919793033041
|
||||
},
|
||||
{
|
||||
"file": "onset-43.wav",
|
||||
"text": "Gute Frage. Die kurze Antwort Für einen Knapptod sofort auf den anderen Umschalten funktioniert, mit euren zwei getrennten NAS Geräten nicht.",
|
||||
"seconds": 1.356167989957612
|
||||
},
|
||||
{
|
||||
"file": "previous-failure-42.wav",
|
||||
"text": "Wichtig vorab, euer Kloster hat schon was failover-mäßig, zählt der Charlet Storage knapp.",
|
||||
"seconds": 0.822152458014898
|
||||
},
|
||||
{
|
||||
"file": "previous-failure-43.wav",
|
||||
"text": "Wichtig vorab, euer Kloster hat schon was Failover-mäßig, zählt der Charret Storage knapp.",
|
||||
"seconds": 0.8253010929911397
|
||||
},
|
||||
{
|
||||
"file": "story-42.wav",
|
||||
"text": "Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie Das hat wunderbar funktioniert.",
|
||||
"seconds": 1.513217622996308
|
||||
},
|
||||
{
|
||||
"file": "story-43.wav",
|
||||
"text": "Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie Das hat wunderbar funktioniert,",
|
||||
"seconds": 1.6474035409628414
|
||||
},
|
||||
{
|
||||
"file": "technical-42.wav",
|
||||
"text": "Home Assistant läuft den Docker auf Unrate. Die SSD hat 47 Grad Celsius. Das Logfehle enthält keinen Fehler. Die Datei ist 512 Mb groß und die Verbindung überträgt 100 Mbit pro Sekunde. Um 18.30 Uhr startet der nächste Scern.",
|
||||
"seconds": 2.0038620269624516
|
||||
},
|
||||
{
|
||||
"file": "technical-43.wav",
|
||||
"text": "Home Assistant läuft in Docker auf Unrate. Die SSD hat 47 Grad Celsius. Das Logfiele enthält keinen Fehler. Die Datei ist 512 Mb groß und die Verbindung überträgt 100 Mbit pro Sekunde. Um 18.30 Uhr startet der nächste Stern.",
|
||||
"seconds": 1.8995722639956512
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,106 @@
|
||||
# Articulino: three Anna reference excerpts · 27 October 2026
|
||||
|
||||
Michael requested three clean 5–8-second excerpts from his supplied 15:08.91
|
||||
Anna training WAV, each synthesizing the same text on Athena's CPU. Qwen was
|
||||
explicitly to remain unchanged. This is a reference-conditioning comparison,
|
||||
not a production integration, model replacement or training/fine-tuning run.
|
||||
|
||||
## Inputs and fixed recipe
|
||||
|
||||
The original mono 48 kHz PCM16 recording was read without modification. Clips
|
||||
were cut at detected quiet intervals, one from each third of the recording,
|
||||
with a high speech fraction and no clipped samples. No pitch change, denoising,
|
||||
loudness normalization or manual pronunciation markup was applied. STT checked
|
||||
that each selected clip contained intelligible German words. A contains neutral
|
||||
training narration, B prose narration, C an articulated adjective list; this
|
||||
reference-style difference can affect the resulting voice and prosody.
|
||||
|
||||
| Reference | Source interval | Length | RMS dBFS | Peak dBFS |
|
||||
| --- | --- | ---: | ---: | ---: |
|
||||
| A | 00:52.02–00:59.92 | 7.90 s | -21.68 | -2.77 |
|
||||
| B | 05:25.14–05:33.00 | 7.86 s | -20.39 | -2.52 |
|
||||
| C | 13:12.24–13:18.02 | 5.78 s | -19.81 | -2.05 |
|
||||
|
||||
Signal checks and STT are not a listening assessment of background sound or
|
||||
speaker similarity. Michael's subsequent listening assessment: the measured
|
||||
speed is exactly the desired direction, but the generated voice is only an
|
||||
approximation of Anna and does not sound sufficiently like her. No reference
|
||||
was accepted as an adequate Anna replacement. Do not overrule this assessment
|
||||
with ASR results or declare a winning reference without a listening decision.
|
||||
Michael explicitly requested retaining Articulino on the serious-candidate
|
||||
shortlist despite that remaining voice-similarity limitation. This is retention
|
||||
for further comparison, not acceptance as the production Anna replacement.
|
||||
|
||||
All three outputs received exactly this text, language `de`, seed 42 and the
|
||||
same unmodified Articulino defaults:
|
||||
|
||||
> Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster
|
||||
> und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote
|
||||
> Tasse. Zum Schluss sagte sie: Das hat wunderbar funktioniert.
|
||||
|
||||
Existing candidate installation and pinned source/model revisions are recorded
|
||||
in [the original experiment](../articulino-cpu-2026-10-26/README.md). It uses
|
||||
Articulino ONNX 1.0.0, source `143d6dd5bbd67a02564be30f15bd8a578dda4987`,
|
||||
fp32 weights revision `a760ce8d513534111c7679751869fa4c45ef0e54`, ONNX Runtime
|
||||
1.23.2 and four threads. Each of the five graphs reported only
|
||||
`CPUExecutionProvider`. The official voice loader resamples the 48 kHz input
|
||||
to its required 24 kHz; generated files are mono 24 kHz PCM16.
|
||||
|
||||
`uniform_rate=True`, `retry_broken=True`, normalization enabled and sentence
|
||||
pause 0.15 seconds were held constant. The default voice-rate conditioning can
|
||||
produce different durations from different references. No parameters were
|
||||
optimized against these output results. Model initialization took 0.581 s;
|
||||
voice preparation was separately timed and excluded from generation below.
|
||||
|
||||
## Results
|
||||
|
||||
| Reference | Generated audio | Generation + WAV write | RTF | First complete sentence |
|
||||
| --- | ---: | ---: | ---: | ---: |
|
||||
| A | 15.37 s | 0.519 s | 0.0338 | 0.150 s |
|
||||
| B | 14.93 s | 0.462 s | 0.0309 | 0.106 s |
|
||||
| C | 15.25 s | 0.470 s | 0.0308 | 0.107 s |
|
||||
|
||||
All three files completed with four sentence chunks, finite samples, no PCM
|
||||
clipping and no triggered upstream broken-output retry. These are three short
|
||||
sequential renders in one resident model process, not a statistically robust
|
||||
speed comparison; A is the first synthesis after loading. This does not measure
|
||||
Hermes/Conduit playback or concurrent production performance.
|
||||
|
||||
Each reference and output was also transcribed using the existing pinned
|
||||
Parakeet Redux CPU CLI v0.6.1, without changing the configured STT endpoint.
|
||||
All three generated transcripts match every test-text word after case and
|
||||
punctuation normalization. This is a combined TTS/STT check of this one passage;
|
||||
it does not establish naturalness, accent quality or resemblance to Anna.
|
||||
|
||||
## Isolation, retention and reproduction
|
||||
|
||||
Test data/scripts/results are under the own Athena directory
|
||||
`/data/athena-articulino-references-20261027`, reusing only the existing Articulino
|
||||
venv/model from `/data/athena-articulino-test-20261026`. The transient unit
|
||||
`athena-articulino-references-20261027.service` used MemoryMax 4 GiB, no swap,
|
||||
CPUQuota 400%, affinity 2–5/8–11, nice 10, UMask 0077 and a ten-minute maximum.
|
||||
It ended successfully and is inactive. No server/listener, container, SDK,
|
||||
additional permanent service or Mac dependency was installed. The existing STT
|
||||
CLI was a bounded child process; the stopped Hermes container was not started.
|
||||
|
||||
For native reproduction, use the pinned CPU environment described in the
|
||||
original experiment, supply three private reference WAVs as
|
||||
`references/anna-reference-{A,B,C}.wav` under the configured test root and run
|
||||
`run_references.py` with that venv under equivalent resource limits. Its STT
|
||||
paths point to the existing pinned native Parakeet installation and require
|
||||
that separate runtime/model to be installed. Scripts use explicit local paths;
|
||||
they do not download dependencies or modify production. Voice data must be
|
||||
restored separately, never obtained from Git. This is not a complete native
|
||||
Deck installation or restore acceptance test.
|
||||
|
||||
Listening copies and private clip-selection evidence are retained outside Git
|
||||
under `work/articulino-references-20261027/` on the Mac. No private reference
|
||||
transcripts or audio are placed in this documentation. Only synthetic test
|
||||
metrics, inputs and reproduction scripts are recorded here.
|
||||
|
||||
After the run, hash readback confirmed the production profile catalogue,
|
||||
endpoint configuration, audio policy, canonical Qwen worker and original Anna
|
||||
reference were unchanged. The live Qwen worker still matched the canonical
|
||||
worker (`8da80b84310cc5e32ee73595ef8cc8a2fefef0cd9a8cc621d7b8a21af7432fc3`).
|
||||
Deck stayed running with its pre-test start time, 26 October 20:01:04 UTC.
|
||||
There was no Qwen request, unload, reload, restart or settings change.
|
||||
@@ -0,0 +1,56 @@
|
||||
[
|
||||
{
|
||||
"label": "A",
|
||||
"reference": "anna-reference-A.wav",
|
||||
"seed": 42,
|
||||
"voice_preparation_seconds": 0.1700956459972076,
|
||||
"file": "articulino-anna-A.wav",
|
||||
"generation_seconds": 0.5190993829965009,
|
||||
"duration_seconds": 15.37,
|
||||
"rtf": 0.03377354476229674,
|
||||
"first_sentence_seconds": 0.1495062149988371,
|
||||
"chunks": 4,
|
||||
"peak": 0.949999988079071,
|
||||
"clipped_fraction": 0.0,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": [],
|
||||
"peak_rss_kib": 780688,
|
||||
"sha256": "29fc7adfb8085501ce3574701b7573603895230c628e18a047c918aa3fd07124"
|
||||
},
|
||||
{
|
||||
"label": "B",
|
||||
"reference": "anna-reference-B.wav",
|
||||
"seed": 42,
|
||||
"voice_preparation_seconds": 0.15260826400481164,
|
||||
"file": "articulino-anna-B.wav",
|
||||
"generation_seconds": 0.46197726800164673,
|
||||
"duration_seconds": 14.93,
|
||||
"rtf": 0.030942884661865153,
|
||||
"first_sentence_seconds": 0.10638059300254099,
|
||||
"chunks": 4,
|
||||
"peak": 0.949999988079071,
|
||||
"clipped_fraction": 0.0,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": [],
|
||||
"peak_rss_kib": 792488,
|
||||
"sha256": "0b6bd26854ba92bd2237708f825be250be0949a12fc4d6553e112e85db357728"
|
||||
},
|
||||
{
|
||||
"label": "C",
|
||||
"reference": "anna-reference-C.wav",
|
||||
"seed": 42,
|
||||
"voice_preparation_seconds": 0.12814953099587,
|
||||
"file": "articulino-anna-C.wav",
|
||||
"generation_seconds": 0.4703923720007879,
|
||||
"duration_seconds": 15.25,
|
||||
"rtf": 0.030845401442674614,
|
||||
"first_sentence_seconds": 0.10747679400083143,
|
||||
"chunks": 4,
|
||||
"peak": 0.7821668386459351,
|
||||
"clipped_fraction": 0.0,
|
||||
"retry_trigger_count": 0,
|
||||
"retry_reasons": [],
|
||||
"peak_rss_kib": 803536,
|
||||
"sha256": "eec251df701f60475437ca4b13011f55c21aa95612d9eda0c6f8400200097d73"
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,20 @@
|
||||
[
|
||||
{
|
||||
"file": "articulino-anna-A.wav",
|
||||
"stt_exit_code": 0,
|
||||
"word_count": 36,
|
||||
"word_match": true
|
||||
},
|
||||
{
|
||||
"file": "articulino-anna-B.wav",
|
||||
"stt_exit_code": 0,
|
||||
"word_count": 36,
|
||||
"word_match": true
|
||||
},
|
||||
{
|
||||
"file": "articulino-anna-C.wav",
|
||||
"stt_exit_code": 0,
|
||||
"word_count": 36,
|
||||
"word_match": true
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,108 @@
|
||||
"""Three voice references, fixed synthetic text; CPU only, no production writes."""
|
||||
import os
|
||||
os.environ.update(CUDA_VISIBLE_DEVICES='', HF_HUB_OFFLINE='1',
|
||||
HF_HUB_DISABLE_TELEMETRY='1', OMP_NUM_THREADS='4',
|
||||
OPENBLAS_NUM_THREADS='1', MKL_NUM_THREADS='4')
|
||||
import hashlib
|
||||
import json
|
||||
from pathlib import Path
|
||||
import resource
|
||||
import subprocess
|
||||
import time
|
||||
import numpy as np
|
||||
import soundfile as sf
|
||||
from articulino_onnx import TTS, dsp
|
||||
|
||||
ROOT = Path('/data/athena-articulino-references-20261027')
|
||||
BASE = Path('/data/athena-articulino-test-20261026')
|
||||
OUT = ROOT/'outputs'
|
||||
OUT.mkdir(exist_ok=True, mode=0o700)
|
||||
TEXT = ('Wenn du magst, erzähle ich dir eine kurze Geschichte. '
|
||||
'Anna öffnete das Fenster und hörte drei Vögel singen. '
|
||||
'Auf dem Tisch lagen sieben Bücher und eine rote Tasse. '
|
||||
'Zum Schluss sagte sie: Das hat wunderbar funktioniert.')
|
||||
(ROOT/'test-text.txt').write_text(TEXT+'\n')
|
||||
STT = Path('/opt/athena-deck-dev/runtime/state/parakeet-runtime/v0.6.1')
|
||||
CLI = STT/'runtime/parakeet-v0.6.1-bin-linux-cpu-x64/parakeet-cli'
|
||||
MODEL = STT/'redux-packed.gguf'
|
||||
|
||||
def transcribe(path):
|
||||
start = time.monotonic()
|
||||
process = subprocess.run([str(CLI), 'transcribe', '--model', str(MODEL),
|
||||
'--input', str(path), '--lang', 'de',
|
||||
'--threads', '2', '--json'],
|
||||
capture_output=True, text=True, timeout=90)
|
||||
row = dict(file=path.name, exit_code=process.returncode,
|
||||
seconds=time.monotonic()-start)
|
||||
if process.returncode == 0:
|
||||
try:
|
||||
row['result'] = json.loads(process.stdout)
|
||||
except ValueError:
|
||||
row['stdout'] = process.stdout
|
||||
else:
|
||||
row['stderr'] = process.stderr[-2000:]
|
||||
return row
|
||||
|
||||
references = sorted((ROOT/'references').glob('anna-reference-*.wav'))
|
||||
assert len(references) == 3
|
||||
reference_stt = [transcribe(p) for p in references]
|
||||
(ROOT/'reference-transcriptions.json').write_text(json.dumps(reference_stt, ensure_ascii=False, indent=2))
|
||||
print(json.dumps(dict(reference_stt=reference_stt), ensure_ascii=False), flush=True)
|
||||
|
||||
checks = []
|
||||
original_check = dsp.broken
|
||||
def observed_check(*args, **kwargs):
|
||||
reason = original_check(*args, **kwargs)
|
||||
checks.append(reason)
|
||||
return reason
|
||||
dsp.broken = observed_check
|
||||
start = time.monotonic()
|
||||
tts = TTS.from_pretrained(BASE/'model', precision='fp32',
|
||||
providers=['CPUExecutionProvider'], threads=4)
|
||||
load_seconds = time.monotonic()-start
|
||||
providers = {name: session.get_providers() for name, session in tts.engine.sessions.items()}
|
||||
assert all(v == ['CPUExecutionProvider'] for v in providers.values())
|
||||
setup = dict(precision='fp32', model_load_seconds=load_seconds, providers=providers,
|
||||
threads=4, affinity=sorted(os.sched_getaffinity(0)),
|
||||
uniform_rate=tts.uniform_rate, retry_broken=tts.retry_broken,
|
||||
sentence_pause_seconds=tts.pause, language='de', seed=42,
|
||||
normalize=True, text=TEXT)
|
||||
(ROOT/'setup.json').write_text(json.dumps(setup, ensure_ascii=False, indent=2))
|
||||
results = []
|
||||
for reference in references:
|
||||
label = reference.stem[-1]
|
||||
row = dict(label=label, reference=reference.name, seed=42)
|
||||
start = time.monotonic()
|
||||
tts.set_voice(str(reference))
|
||||
row['voice_preparation_seconds'] = time.monotonic()-start
|
||||
checks.clear()
|
||||
chunks = []
|
||||
first = None
|
||||
start = time.monotonic()
|
||||
for pcm in tts.stream(TEXT, language='de', seed=42, normalize=True):
|
||||
if first is None:
|
||||
first = time.monotonic()-start
|
||||
assert len(pcm) and np.isfinite(pcm).all()
|
||||
chunks.append(pcm)
|
||||
assert chunks
|
||||
pcm = np.concatenate(chunks)
|
||||
target = OUT/f'articulino-anna-{label}.wav'
|
||||
sf.write(target, pcm, 24000, subtype='PCM_16')
|
||||
elapsed = time.monotonic()-start
|
||||
row.update(file=target.name, generation_seconds=elapsed,
|
||||
duration_seconds=len(pcm)/24000, rtf=elapsed/(len(pcm)/24000),
|
||||
first_sentence_seconds=first, chunks=len(chunks),
|
||||
peak=float(np.max(np.abs(pcm))),
|
||||
clipped_fraction=float(np.mean(np.abs(pcm) >= 1)),
|
||||
retry_trigger_count=sum(bool(x) for x in checks),
|
||||
retry_reasons=[x for x in checks if x],
|
||||
peak_rss_kib=resource.getrusage(resource.RUSAGE_SELF).ru_maxrss,
|
||||
sha256=hashlib.sha256(target.read_bytes()).hexdigest())
|
||||
results.append(row)
|
||||
(ROOT/'results.json').write_text(json.dumps(results, ensure_ascii=False, indent=2))
|
||||
print(json.dumps(row), flush=True)
|
||||
# Release the candidate before loading the existing STT weights again.
|
||||
del tts
|
||||
output_stt = [transcribe(p) for p in sorted(OUT.glob('*.wav'))]
|
||||
(ROOT/'output-transcriptions.json').write_text(json.dumps(output_stt, ensure_ascii=False, indent=2))
|
||||
print(json.dumps(dict(output_stt=output_stt), ensure_ascii=False), flush=True)
|
||||
@@ -0,0 +1,39 @@
|
||||
{
|
||||
"precision": "fp32",
|
||||
"model_load_seconds": 0.5806190759976744,
|
||||
"providers": {
|
||||
"encoder": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"voice": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"text": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"dit_step": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"decoder": [
|
||||
"CPUExecutionProvider"
|
||||
]
|
||||
},
|
||||
"threads": 4,
|
||||
"affinity": [
|
||||
2,
|
||||
3,
|
||||
4,
|
||||
5,
|
||||
8,
|
||||
9,
|
||||
10,
|
||||
11
|
||||
],
|
||||
"uniform_rate": true,
|
||||
"retry_broken": true,
|
||||
"sentence_pause_seconds": 0.15,
|
||||
"language": "de",
|
||||
"seed": 42,
|
||||
"normalize": true,
|
||||
"text": "Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie: Das hat wunderbar funktioniert."
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie: Das hat wunderbar funktioniert.
|
||||
@@ -0,0 +1,225 @@
|
||||
# Audio8 0.1B CPU / three Anna references · 27 October 2026
|
||||
|
||||
Michael authorized an isolated CPU test with the same three Anna excerpts,
|
||||
the same story, a technical passage, local STT and speed measurements. Keep
|
||||
production Qwen unchanged. No endpoint/profile activation, new container,
|
||||
permanent service or Mac modification is part of this experiment.
|
||||
|
||||
## Pinned inputs and environment
|
||||
|
||||
- Official source: `Edge0-AI/Audio8_TTS`, commit
|
||||
`07e40f5d0b03fc473635ef378654bfb581027ac3`; use the specific
|
||||
`onnx_runtime_0_1b_int8` implementation, not the incompatible older 0.6B runtime.
|
||||
- Public weights: `Edge0/audio8-TTS-0.1B-ONNX-INT8`, revision
|
||||
`317c12d4e0da83847b594fcf8bd74bf2c76615ec`.
|
||||
- Thirteen selected model/config/tokenizer files, 858,089,043 bytes. All nine
|
||||
LFS files matched the publisher's pinned SHA256/size metadata; JSON/tokenizer
|
||||
sizes and locally calculated hashes are also recorded in the manifest.
|
||||
- Own host Python 3.13 venv: ONNX Runtime 1.23.2, NumPy 2.2.6, tokenizers 0.22.1,
|
||||
SoundFile 0.13.1 and SciPy 1.16.3. ONNX 1.19.1 was added only for the numerical
|
||||
diagnosis and graph representation conversion. No Torch, GPU ORT or NVIDIA
|
||||
wheel was installed. Full resolved requirements are recorded separately.
|
||||
- Original runtime Python source remains unmodified. Core classes are called
|
||||
directly; no FastAPI/HTTP server is started and web-service packages are not
|
||||
required by this test.
|
||||
|
||||
The reference inputs are byte-identical to the earlier
|
||||
[Articulino comparison](../articulino-reference-comparison-2026-10-27/README.md):
|
||||
A 7.90 s (00:52.02–00:59.92), B 7.86 s (05:25.14–05:33.00), C 5.78 s
|
||||
(13:12.24–13:18.02), mono 48 kHz PCM16. The original long Anna recording and
|
||||
production Anna reference are never overwritten. The source clip hashes are
|
||||
checked before encoding. This runtime uses acoustic reference codes plus the
|
||||
reference transcript; those transcripts came from the preceding local STT
|
||||
selection check and remain outside Git.
|
||||
|
||||
Official `VoiceRegistration.register()` performs its normal bandlimited
|
||||
resampling to 44.1 kHz and 2048-sample padding. All encoder sessions actually
|
||||
reported `CPUExecutionProvider` only. It produced 10×171, 10×170 and 10×125
|
||||
valid, varying code arrays. Preparation took 6.361/5.812/4.827 s, separately
|
||||
from synthesis. The registration process exited before speech generation.
|
||||
|
||||
## Hardware-specific failure and verified workaround
|
||||
|
||||
The checksum-verified official U8S8 INT8 graphs initially returned only nine
|
||||
codec frames, 0.418 s of low-level audio, for the complete story with A.
|
||||
This is a failed speech result, not a successful fast generation. The main
|
||||
study was stopped before repeating an invalid numerical path across all cases.
|
||||
The initial artifact and timing remain in the own diagnostic directory.
|
||||
|
||||
A firsthand report on the publisher's model forum describes the same symptom
|
||||
on the same Ryzen 5 5600 / AVX2 hardware. ONNX Runtime officially documents
|
||||
possible U8S8 AVX2 saturation and recommends U8U8 as one remedy. This was then
|
||||
checked on Athena itself, not merely inferred from the forum:
|
||||
|
||||
- Use the first actual slow-graph MatMulInteger matrix, shape 512×1688, with
|
||||
three deterministic uint8 activation rows and an exact NumPy int32 reference.
|
||||
- Official U8S8 representation: 2,121 differing output entries, maximum absolute
|
||||
integer error 99,838. Equivalent U8U8 representation: zero differing entries.
|
||||
- Create separate derived slow/fast graph files with the reviewed community
|
||||
converter at commit `3628c9756936e8d33bf2a662300f1f4131c0bc6e`, script SHA256
|
||||
`091979bd6bb50f3914234eae458ea509669bd140eb9059515fe0fc3fc13be448`.
|
||||
- Add 128 to signed weights **and their zero points**. Verify `weight-zero_point`
|
||||
exactly unchanged at all 217 slow and 21 fast matrix nodes. All other
|
||||
initializers, including every scale, must remain array-identical. No
|
||||
recalibration, training or change of quantization step is performed.
|
||||
- The separate `model-u8u8` directory selects these derived graphs. Original
|
||||
public files, original manifest and FP16 codec remain unchanged. Hashes of
|
||||
the derived files and validation are recorded.
|
||||
|
||||
This is a community CPU compatibility workaround independently checked here,
|
||||
not an official new Audio8 release. The integer microtest alone is not a proof
|
||||
of full-model acoustic equivalence; it demonstrates the local kernel error and
|
||||
the exact representation identity. Listening and STT remain necessary.
|
||||
|
||||
## Execution paths and failures kept separate
|
||||
|
||||
One corrected default streaming pilot (`chunk_frames=12`) generated 12.585 s
|
||||
audio in 117.746 s, RTF 9.356, first native PCM after 8.450 s. No GPU was used.
|
||||
Its codec window is repeatedly decoded, so this is not the same cost as one
|
||||
complete-file decoder call. The next ongoing own pilot request was stopped;
|
||||
no production request was cancelled.
|
||||
|
||||
A separate official complete-file `synthesize()` pilot generated the same 271
|
||||
story codec frames in 32.687 s, RTF 2.597. Slow graph calls used 14.544 s, fast
|
||||
calls 6.979 s and one decoder call 9.392 s. Streaming versus complete-file PCM
|
||||
need not be byte-identical because the official streaming decoder crops sliding
|
||||
windows. The longer technical complete-file decoder then hit the own hard
|
||||
3.5 GiB memory limit. The unit journal confirms that **only that test unit** was
|
||||
OOM-killed. No completed technical sample or successful zero latency is claimed
|
||||
for this failed pilot. A preceding 4 GiB-budget attempt had been refused before
|
||||
loading because its additional 2 GiB host reserve was unavailable; it is also
|
||||
kept separately and is not a model-timing result.
|
||||
|
||||
The final six-file comparison therefore uses the official `synthesize()` call
|
||||
once per sentence, concatenating the PCM in order. This bounds decoder memory,
|
||||
as the existing Qwen integration also renders sentence chunks. No extra silence,
|
||||
pitch change, resampling of generated outputs or pronunciation markup is added.
|
||||
Joining the split sentences must reproduce the exact original passage. There
|
||||
are four story sentences and five technical sentences. This segmentation and
|
||||
the repaired graph representation were selected because of execution failures,
|
||||
not optimized to improve the subsequently observed STT scores.
|
||||
|
||||
## Fixed final comparison
|
||||
|
||||
Three references × two complete texts = six files, one seed per condition.
|
||||
Same CLI sampling defaults: seed 42 per sentence, temperature 0.7, top-p 0.9,
|
||||
top-k 50, up to 1024 codec frames per sentence, original stop logic and INT8
|
||||
weights in the equivalent U8U8 representation, original FP16 decoder.
|
||||
|
||||
The story is byte-identical to the preceding Qwen/Articulino reference test.
|
||||
The technical passage is the original Articulino technical case, including
|
||||
Home Assistant, Docker, Unraid, SSD, 47 °C, 512 MiB, 100 Mbit, 18:30 CEST and
|
||||
Scan. Audio8 receives that raw text; it has its own normalizer/tokenizer rather
|
||||
than Articulino's German frontend. These are practical pipeline comparisons,
|
||||
not isolated neural-model or voice-embedding A/Bs.
|
||||
|
||||
Output is native 44.1 kHz mono PCM16. Timers include prompt/voice-code loading,
|
||||
all AR generation, all sentence decoding and final WAV writing, but exclude
|
||||
initial model loading, reference encoding, downloads, STT and client playback.
|
||||
Actual provider readback checks slow, fast and decoder sessions independently.
|
||||
Four backend threads, affinity 2–5/8–11, CPUQuota 400%, nice 10, no GPU devices,
|
||||
no swap, hard MemoryMax 3584 MiB, 8 GiB address-space cap, 180-second per-case
|
||||
cooperative timeout and a twenty-minute unit lifetime. Admission reserves the
|
||||
own hard budget plus 2 GiB host headroom; a monitor cancels below 2 GiB. These
|
||||
are own test limits, not changes to any production loader's limits.
|
||||
|
||||
## Final measurements and local STT
|
||||
|
||||
All six final files completed, with finite samples, no clipped samples and no
|
||||
token-limit hit. Downloaded WAV hashes, channel count, PCM16 format, 44.1 kHz
|
||||
rate and exact frame-derived durations were independently checked.
|
||||
|
||||
| Reference | Story audio | Story generation | Story RTF | Technical audio | Technical generation | Technical RTF |
|
||||
| --- | ---: | ---: | ---: | ---: | ---: | ---: |
|
||||
| A | 12.725 s | 44.998 s | 3.536 | 18.576 s | 62.663 s | 3.373 |
|
||||
| B | 13.839 s | 46.660 s | 3.372 | 20.387 s | 65.488 s | 3.212 |
|
||||
| C | 13.328 s | 42.514 s | 3.190 | 18.715 s | 57.456 s | 3.070 |
|
||||
|
||||
The final sentence-wise path needs more than three seconds computing per second
|
||||
of speech. Even the faster completed whole-file story pilot was slower than
|
||||
realtime. Audio8 therefore fails this Athena CPU speed target; the failed or
|
||||
interrupted pilots are not pooled into the final six-file rates. This is not a
|
||||
universal speed judgment on VNNI/ARM hardware or another inference engine.
|
||||
There are two independent texts with three reference conditions and one seed,
|
||||
not six independent tasks or replicated performance trials. Simultaneous
|
||||
production load was not controlled and no artificial LLM load was generated.
|
||||
|
||||
All six local Parakeet transcriptions completed. With the same German speech
|
||||
preparation, numbers up to 999 and case/punctuation normalization as the prior
|
||||
auditions:
|
||||
|
||||
| Text group | Reference words | Round-trip edits | Deviation |
|
||||
| --- | ---: | ---: | ---: |
|
||||
| Story × three references | 108 | 2 | 1.85% |
|
||||
| Technical × three references | 138 | 25 | 18.12% |
|
||||
|
||||
Story A matches all words; B/C each recognize contracted `erzähl` instead of
|
||||
`erzähle`. The technical transcripts have substantial differences at Unraid,
|
||||
Logfile, CEST and the size value: expected `512 MiB` is recognized as `21 Mb`,
|
||||
`15 MiB` or `13 Mbit`. These are combined TTS/STT observations, not proof that
|
||||
each numerical or spelling difference originates in synthesis. Inputs and raw
|
||||
transcripts are retained for checking. No retrospective pronunciation guide or
|
||||
different seed was substituted into these fixed results. Accent, naturalness
|
||||
and Anna resemblance remain for Michael's listening assessment.
|
||||
|
||||
After completion, hash readback confirmed unchanged production profiles,
|
||||
endpoint configuration, audio policy, CPU partition, original Anna reference,
|
||||
canonical/live Qwen worker and the Deck start time. The thirteen original
|
||||
Audio8 assets also still match their download hashes and the official source
|
||||
checkout is clean. All nine own transient test/preparation/STT units are
|
||||
inactive. The own Pip download cache was removed; no production cleanup or
|
||||
restart occurred.
|
||||
|
||||
### Human rejection and requested cleanup
|
||||
|
||||
Michael rejected Audio8 outright for missing the CPU speed goal, and also
|
||||
reported the same Chinese-sounding accent he heard in several earlier rejected
|
||||
candidates. This is his listening assessment, not an inference from ASR. He
|
||||
explicitly requested stopping and deleting this candidate.
|
||||
|
||||
The entire isolated Athena root `/data/athena-audio8-cpu-20261027` was removed:
|
||||
original/derived weights, own venv, source checkouts, private derived codes,
|
||||
reference transcripts, pilot data and generated WAVs. Pre-deletion allocated
|
||||
file blocks totaled 1,597,771,776 bytes (about 1.49 GiB). The local
|
||||
`work/audio8-cpu-20261027` directory, including the six listening WAVs and
|
||||
duplicate scripts/data, was also removed (8,720,384 allocated bytes). Both roots
|
||||
were verified absent and all own units were inactive. No shared cache or
|
||||
container prune was used. Small technical measurement/reproduction records in
|
||||
this documentation remain to prevent rediscovering and repeating the failure.
|
||||
See `cleanup.json` for the receipt; concurrent host activity can affect the
|
||||
filesystem free-space delta.
|
||||
|
||||
Qwen configuration/worker and original Anna hashes matched before and after
|
||||
deletion. The retained Articulino candidate and its reference excerpts were
|
||||
preserved. No new model was installed during the subsequent shortlist research.
|
||||
|
||||
## Reproduction and retention
|
||||
|
||||
Own root: `/data/athena-audio8-cpu-20261027`. Use native Debian Python/venv and
|
||||
the pinned public source/assets above. Fetch the reviewed converter at its
|
||||
recorded commit/hash; do not substitute an unreviewed branch head. Restore the
|
||||
three authorized private source clips and exact transcripts separately, run
|
||||
the own preparation/registration/numerical-validation scripts, then the final
|
||||
benchmark under the stated transient limits. No container dependency is needed.
|
||||
Adapt explicit host paths to the intended native installation; reference codes
|
||||
and transcripts are private and never belong in Git.
|
||||
|
||||
Local Parakeet Redux CPU v0.6.1 checks the generated files only after synthesis
|
||||
exits. No cloud service or Hermes API credential is needed. ASR deviations
|
||||
measure combined synthesis/recognition changes, not accent, naturalness or Anna
|
||||
similarity. Human listening must decide those qualities. No Hermes/Conduit
|
||||
playback or full native Deck restore is claimed by an offline model audition.
|
||||
|
||||
Public methods, pins, manifests, synthetic inputs and final measurements are
|
||||
kept here. No private reference transcripts or code arrays were committed.
|
||||
The rejected candidate's local/remote audio and runtime data were subsequently
|
||||
deleted as documented above. No model activation, commit, push or full product
|
||||
installation is implied.
|
||||
|
||||
Sources:
|
||||
|
||||
- [Publisher model card](https://huggingface.co/Edge0/audio8-TTS-0.1B-ONNX-INT8)
|
||||
- [Official runtime](https://github.com/Edge0-AI/Audio8_TTS/tree/07e40f5d0b03fc473635ef378654bfb581027ac3/onnx_runtime_0_1b_int8)
|
||||
- [Firsthand same-CPU failure report](https://huggingface.co/Edge0/audio8-TTS-0.1B-ONNX-INT8/discussions/3)
|
||||
- [ONNX Runtime: U8U8 and AVX2 saturation](https://onnxruntime.ai/docs/performance/model-optimizations/quantization.html#when-and-why-do-i-need-to-try-u8u8)
|
||||
- [Reviewed community workaround](https://github.com/Aaaou/Audio8_TTS/tree/3628c9756936e8d33bf2a662300f1f4131c0bc6e)
|
||||
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"node": "/slow/layers.0/mamba/in_proj/MatMul_quant",
|
||||
"weight_shape": [
|
||||
512,
|
||||
1688
|
||||
],
|
||||
"u8s8_mismatches": 2121,
|
||||
"u8s8_max_absolute_error": 99838,
|
||||
"u8u8_mismatches": 0,
|
||||
"u8u8_max_absolute_error": 0
|
||||
}
|
||||
@@ -0,0 +1,87 @@
|
||||
"""Verify the local U8S8 kernel and create separate equivalent U8U8 graphs."""
|
||||
from pathlib import Path
|
||||
import hashlib
|
||||
import importlib.util
|
||||
import json
|
||||
import numpy as np
|
||||
import onnx
|
||||
from onnx import helper, numpy_helper, TensorProto
|
||||
import onnxruntime as ort
|
||||
|
||||
ROOT = Path('/data/athena-audio8-cpu-20261027')
|
||||
SRC = ROOT/'model'
|
||||
DST = ROOT/'model-u8u8'
|
||||
DST.mkdir(mode=0o700,exist_ok=True)
|
||||
original = onnx.load(str(SRC/'slow_ar_int8.onnx'),load_external_data=True)
|
||||
initializers = {v.name:v for v in original.graph.initializer}
|
||||
node = next(n for n in original.graph.node if n.op_type=='MatMulInteger')
|
||||
weight = numpy_helper.to_array(initializers[node.input[1]])
|
||||
zero = numpy_helper.to_array(initializers[node.input[3]])
|
||||
rng = np.random.default_rng(42)
|
||||
activation = rng.integers(0,256,(3,weight.shape[0]),dtype=np.uint8)
|
||||
activation[0,:] = 255
|
||||
activation_zero = np.array(128,dtype=np.uint8)
|
||||
expected = (activation.astype(np.int32)-activation_zero.astype(np.int32)) @ (weight.astype(np.int32)-zero.astype(np.int32))
|
||||
def run_matrix(w,z):
|
||||
graph = helper.make_graph([helper.make_node('MatMulInteger',['a','w','az','wz'],['y'])],
|
||||
'matrix-validation',[helper.make_tensor_value_info('a',TensorProto.UINT8,list(activation.shape))],
|
||||
[helper.make_tensor_value_info('y',TensorProto.INT32,list(expected.shape))],
|
||||
[numpy_helper.from_array(w,'w'),numpy_helper.from_array(activation_zero,'az'),numpy_helper.from_array(z,'wz')])
|
||||
model = helper.make_model(graph,opset_imports=[helper.make_opsetid('',14)],ir_version=9)
|
||||
options=ort.SessionOptions();options.intra_op_num_threads=4;options.inter_op_num_threads=1
|
||||
session=ort.InferenceSession(model.SerializeToString(),sess_options=options,providers=['CPUExecutionProvider'])
|
||||
return session.run(None,{'a':activation})[0]
|
||||
signed_result = run_matrix(weight,zero)
|
||||
unsigned_weight=(weight.astype(np.int16)+128).astype(np.uint8)
|
||||
unsigned_zero=(zero.astype(np.int16)+128).astype(np.uint8)
|
||||
unsigned_result=run_matrix(unsigned_weight,unsigned_zero)
|
||||
validation=dict(node=node.name,weight_shape=list(weight.shape),
|
||||
u8s8_mismatches=int(np.count_nonzero(signed_result!=expected)),
|
||||
u8s8_max_absolute_error=int(np.max(np.abs(signed_result.astype(np.int64)-expected))),
|
||||
u8u8_mismatches=int(np.count_nonzero(unsigned_result!=expected)),
|
||||
u8u8_max_absolute_error=int(np.max(np.abs(unsigned_result.astype(np.int64)-expected))))
|
||||
assert validation['u8u8_mismatches']==0
|
||||
(ROOT/'avx2-matrix-validation.json').write_text(json.dumps(validation,indent=2))
|
||||
print(json.dumps(validation),flush=True)
|
||||
del original,initializers,weight
|
||||
|
||||
converter=ROOT/'workaround-source/onnx_runtime_0_1b_int8/scripts/convert_u8s8_to_u8u8.py'
|
||||
spec=importlib.util.spec_from_file_location('audited_audio8_converter',converter)
|
||||
module=importlib.util.module_from_spec(spec);spec.loader.exec_module(module)
|
||||
converted=[]
|
||||
for old,new in [('slow_ar_int8.onnx','slow_ar_u8u8.onnx'),('fast_ar_int8.onnx','fast_ar_u8u8.onnx')]:
|
||||
count=module.convert_graph(SRC/old,DST/new,False)
|
||||
before=onnx.load(str(SRC/old),load_external_data=True)
|
||||
after=onnx.load(str(DST/new),load_external_data=True)
|
||||
a={v.name:v for v in before.graph.initializer};b={v.name:v for v in after.graph.initializer}
|
||||
checked=0
|
||||
for n in before.graph.node:
|
||||
if n.op_type!='MatMulInteger':continue
|
||||
wn,zn=n.input[1],n.input[3]
|
||||
ow=numpy_helper.to_array(a[wn]).astype(np.int16);oz=numpy_helper.to_array(a[zn]).astype(np.int16)
|
||||
nw=numpy_helper.to_array(b[wn]).astype(np.int16);nz=numpy_helper.to_array(b[zn]).astype(np.int16)
|
||||
assert np.array_equal(ow-oz,nw-nz)
|
||||
checked+=1
|
||||
# Nonconverted initializers, including every scale, must remain byte-equivalent.
|
||||
changed={n.input[i] for n in before.graph.node if n.op_type=='MatMulInteger' for i in [1,3]}
|
||||
for name,tensor in a.items():
|
||||
if name not in changed:
|
||||
assert np.array_equal(numpy_helper.to_array(tensor),numpy_helper.to_array(b[name]))
|
||||
converted.append(dict(source=old,derived=new,converted_weights=count,verified_matrix_nodes=checked,
|
||||
all_other_initializers_unchanged=True))
|
||||
del before,after,a,b
|
||||
for name in ['codec_decoder_fp16.onnx','codec_decoder_fp16.onnx.data','tokenizer','registration','config.json','reference_codes.npy']:
|
||||
target=DST/name
|
||||
if not target.exists():target.symlink_to(SRC/name)
|
||||
manifest=json.loads((SRC/'runtime_manifest.json').read_text())
|
||||
manifest['available_precisions']=['u8u8'];manifest['default_precision']='u8u8'
|
||||
manifest['slow_decode_models']={'u8u8':'slow_ar_u8u8.onnx'}
|
||||
manifest['fast_models']={'u8u8':'fast_ar_u8u8.onnx'}
|
||||
(DST/'runtime_manifest.json').write_text(json.dumps(manifest,ensure_ascii=False,indent=2))
|
||||
report=dict(community_commit='3628c9756936e8d33bf2a662300f1f4131c0bc6e',
|
||||
converter_sha256=hashlib.sha256(converter.read_bytes()).hexdigest(),
|
||||
transformation='Add 128 to existing signed weights and zero points; scales unchanged; no recalibration.',
|
||||
original_models_unchanged=True,graphs=converted,
|
||||
derived_files={p.name:hashlib.sha256(p.read_bytes()).hexdigest() for p in DST.iterdir() if p.is_file() and not p.is_symlink()})
|
||||
(ROOT/'compatibility-manifest.json').write_text(json.dumps(report,indent=2))
|
||||
print(json.dumps(converted),flush=True)
|
||||
@@ -0,0 +1,122 @@
|
||||
"""Fixed six-case Audio8 CPU audition; no production API or settings writes."""
|
||||
import os
|
||||
os.environ.update(CUDA_VISIBLE_DEVICES='', HF_HUB_OFFLINE='1',
|
||||
HF_HUB_DISABLE_TELEMETRY='1', OPENBLAS_NUM_THREADS='1', OMP_NUM_THREADS='4')
|
||||
from pathlib import Path
|
||||
import hashlib
|
||||
import json
|
||||
import resource
|
||||
import re
|
||||
import sys
|
||||
import threading
|
||||
import time
|
||||
import numpy as np
|
||||
import soundfile as sf
|
||||
|
||||
ROOT = Path('/data/athena-audio8-cpu-20261027')
|
||||
OUT = ROOT/'outputs';OUT.mkdir(mode=0o700,exist_ok=True)
|
||||
sys.path.insert(0,str(ROOT/'source/onnx_runtime_0_1b_int8'))
|
||||
from arktts_runtime import ArkTtsRuntime
|
||||
cases = json.loads((ROOT/'cases.json').read_text())
|
||||
def available():
|
||||
return next(int(x.split()[1])*1024 for x in Path('/proc/meminfo').read_text().splitlines() if x.startswith('MemAvailable:'))
|
||||
report = dict(phase='admission', runs=[], admission_available_bytes=available(),
|
||||
cpu_threads=4,cpu_quota=400,precision='u8u8',codec_precision='fp16',
|
||||
test_memory_max_bytes=3584*1024**2,host_reserve_bytes=2*1024**3,
|
||||
seed=42,temperature=.7,top_p=.9,top_k=50,max_new_tokens=1024,
|
||||
output_mode='official synthesize, one sentence per call, PCM concatenated',original_source_unmodified=True,
|
||||
compatibility='Equivalent U8U8 MatMulInteger representation; see compatibility-manifest.json')
|
||||
def save():
|
||||
(ROOT/'results.json').write_text(json.dumps(report,ensure_ascii=False,indent=2))
|
||||
save()
|
||||
if available() <= report['test_memory_max_bytes']+report['host_reserve_bytes']:
|
||||
report.update(phase='deferred_memory',error='Own 3.5 GiB hard budget plus 2 GiB host reserve unavailable')
|
||||
save()
|
||||
raise RuntimeError(report['error'])
|
||||
resource.setrlimit(resource.RLIMIT_AS,(8*1024**3,8*1024**3))
|
||||
stop = threading.Event();cancel = threading.Event()
|
||||
minimum_available = [available()]
|
||||
def monitor():
|
||||
while not stop.wait(.25):
|
||||
now = available();minimum_available[0] = min(minimum_available[0],now)
|
||||
if now < 2*1024**3:cancel.set()
|
||||
watch=threading.Thread(target=monitor,daemon=True);watch.start()
|
||||
try:
|
||||
report['phase']='loading';save()
|
||||
start=time.monotonic()
|
||||
runtime=ArkTtsRuntime(ROOT/'model-u8u8',ROOT/'voices',precision='u8u8',codec_precision='fp16',threads=4)
|
||||
report['load_seconds']=time.monotonic()-start
|
||||
report['providers']={name:getattr(runtime,name).get_providers() for name in ['slow','fast','decoder']}
|
||||
assert all(p==['CPUExecutionProvider'] for p in report['providers'].values())
|
||||
report['sample_rate']=rate=int(runtime.manifest['sample_rate'])
|
||||
assert rate==44100
|
||||
timings={name:dict(seconds=0.,calls=0) for name in ['slow','fast','decoder']}
|
||||
class TimedSession:
|
||||
def __init__(self,name,session):self.name=name;self.session=session
|
||||
def __getattr__(self,name):return getattr(self.session,name)
|
||||
def run(self,*args,**kwargs):
|
||||
started=time.monotonic()
|
||||
try:return self.session.run(*args,**kwargs)
|
||||
finally:
|
||||
timings[self.name]['seconds']+=time.monotonic()-started
|
||||
timings[self.name]['calls']+=1
|
||||
for name in timings:setattr(runtime,name,TimedSession(name,getattr(runtime,name)))
|
||||
report['phase']='synthesis';save()
|
||||
for label in 'ABC':
|
||||
for case in cases:
|
||||
if cancel.is_set():raise RuntimeError('Own memory/time guard fired')
|
||||
name=case['id']+'-'+label
|
||||
codes,meta=runtime.voices.load('anna-'+label)
|
||||
prompt=runtime.prompt_builder.build(case['text'],meta['reference_text'],codes)
|
||||
cap=min(1024,int(runtime.manifest['max_seq_len'])-prompt.shape[2])
|
||||
row=dict(name=name,label=label,case=case['id'],seed=42,prompt_positions=int(prompt.shape[2]),frame_cap=cap)
|
||||
sentences=re.split(r'(?<=[.!?])\s+',case['text'].strip())
|
||||
assert ' '.join(sentences)==case['text']
|
||||
row['sentence_count']=len(sentences)
|
||||
timer=threading.Timer(180,cancel.set);timer.start()
|
||||
for value in timings.values():value.update(seconds=0.,calls=0)
|
||||
start=time.monotonic()
|
||||
try:
|
||||
parts=[];frame_counts=[];limit_hit=False;first_sentence=None
|
||||
for text in sentences:
|
||||
segment,generated=runtime.synthesize(text=text,voice='anna-'+label,
|
||||
max_new_tokens=1024,temperature=.7,top_p=.9,top_k=50,seed=42,stop_event=cancel)
|
||||
if first_sentence is None:first_sentence=time.monotonic()-start
|
||||
assert len(segment) and np.isfinite(segment).all()
|
||||
parts.append(segment)
|
||||
frame_counts.append(int(generated.shape[1]))
|
||||
segment_prompt=runtime.prompt_builder.build(text,meta['reference_text'],codes)
|
||||
limit_hit=limit_hit or generated.shape[1]>=min(1024,int(runtime.manifest['max_seq_len'])-segment_prompt.shape[2])
|
||||
if cancel.is_set():raise RuntimeError('Own memory/time guard fired')
|
||||
pcm=np.concatenate(parts)
|
||||
first=time.monotonic()-start
|
||||
codeframes=sum(frame_counts)
|
||||
if cancel.is_set():raise RuntimeError('Own memory/time guard fired')
|
||||
assert len(pcm) and np.isfinite(pcm).all() and codeframes
|
||||
target=OUT/(name+'.wav')
|
||||
sf.write(target,pcm,rate,subtype='PCM_16')
|
||||
elapsed=time.monotonic()-start
|
||||
row.update(ok=True,file=target.name,generation_seconds=elapsed,
|
||||
audio_seconds=len(pcm)/rate,rtf=elapsed/(len(pcm)/rate),
|
||||
complete_audio_ready_seconds=first,codec_frames=codeframes,
|
||||
first_complete_sentence_seconds=first_sentence,codec_frames_per_sentence=frame_counts,
|
||||
token_limit_hit=bool(limit_hit),peak=float(np.max(np.abs(pcm))),
|
||||
clipped_fraction=float(np.mean(np.abs(pcm)>=1)),
|
||||
sha256=hashlib.sha256(target.read_bytes()).hexdigest(),
|
||||
peak_rss_kib=resource.getrusage(resource.RUSAGE_SELF).ru_maxrss,
|
||||
onnx_run_times={k:dict(v) for k,v in timings.items()})
|
||||
except Exception as exc:
|
||||
row.update(ok=False,seconds=time.monotonic()-start,error_type=type(exc).__name__,error=str(exc)[:300])
|
||||
finally:timer.cancel()
|
||||
report['runs'].append(row)
|
||||
report['minimum_available_bytes']=minimum_available[0]
|
||||
save();print(json.dumps(row),flush=True)
|
||||
if cancel.is_set():raise RuntimeError('Own memory/time guard fired')
|
||||
report['phase']='complete'
|
||||
except Exception as exc:
|
||||
report.update(phase='failed',error_type=type(exc).__name__,error=str(exc)[:300])
|
||||
raise
|
||||
finally:
|
||||
stop.set();watch.join(timeout=2)
|
||||
report['minimum_available_bytes']=minimum_available[0]
|
||||
save()
|
||||
@@ -0,0 +1,10 @@
|
||||
[
|
||||
{
|
||||
"id": "story",
|
||||
"text": "Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie: Das hat wunderbar funktioniert."
|
||||
},
|
||||
{
|
||||
"id": "technical",
|
||||
"text": "Home Assistant läuft in Docker auf Unraid. Die SSD hat 47 Grad Celsius. Das Logfile enthält keinen Fehler. Die Datei ist 512 MiB groß und die Verbindung überträgt 100 Mbit pro Sekunde. Um 18:30 CEST startet der nächste Scan."
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,25 @@
|
||||
"""Existing local Parakeet CPU check; synthetic speech only, no API key needed."""
|
||||
from pathlib import Path
|
||||
import json
|
||||
import subprocess
|
||||
import time
|
||||
ROOT=Path('/data/athena-audio8-cpu-20261027')
|
||||
BASE=Path('/opt/athena-deck-dev/runtime/state/parakeet-runtime/v0.6.1')
|
||||
CLI=BASE/'runtime/parakeet-v0.6.1-bin-linux-cpu-x64/parakeet-cli'
|
||||
report=json.loads((ROOT/'results.json').read_text())
|
||||
assert report['phase'] in ['complete','failed']
|
||||
rows=[]
|
||||
files=[ROOT/'outputs'/r['file'] for r in report['runs'] if r.get('file')]
|
||||
for audio in files:
|
||||
start=time.monotonic()
|
||||
process=subprocess.run([str(CLI),'transcribe','--model',str(BASE/'redux-packed.gguf'),
|
||||
'--input',str(audio),'--lang','de','--threads','2','--json'],
|
||||
capture_output=True,text=True,timeout=120)
|
||||
row=dict(file=audio.name,exit_code=process.returncode,stt_seconds=time.monotonic()-start)
|
||||
if process.returncode==0:
|
||||
row['text']=json.loads(process.stdout)['text']
|
||||
else:
|
||||
row['error']=process.stderr[-1000:]
|
||||
rows.append(row)
|
||||
(ROOT/'transcriptions.json').write_text(json.dumps(rows,ensure_ascii=False,indent=2))
|
||||
print(json.dumps(row,ensure_ascii=False),flush=True)
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"remote": {
|
||||
"deleted_root": "/data/athena-audio8-cpu-20261027",
|
||||
"allocated_bytes_removed": 1597771776,
|
||||
"free_bytes_before": 87912337408,
|
||||
"free_bytes_after": 89529552896,
|
||||
"qwen_and_original_anna_hashes_unchanged": true,
|
||||
"articulino_preserved": true,
|
||||
"all_own_units_inactive": true,
|
||||
"root_absent": true
|
||||
},
|
||||
"local": {
|
||||
"deleted_local_root": "/Users/mike_i386/Documents/ChatGPT/Athena Deck/work/audio8-cpu-20261027",
|
||||
"allocated_bytes_removed": 8720384,
|
||||
"root_absent": true,
|
||||
"small_reproduction_and_measurement_record_retained": true
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
{
|
||||
"community_commit": "3628c9756936e8d33bf2a662300f1f4131c0bc6e",
|
||||
"converter_sha256": "091979bd6bb50f3914234eae458ea509669bd140eb9059515fe0fc3fc13be448",
|
||||
"transformation": "Add 128 to existing signed weights and zero points; scales unchanged; no recalibration.",
|
||||
"original_models_unchanged": true,
|
||||
"graphs": [
|
||||
{
|
||||
"source": "slow_ar_int8.onnx",
|
||||
"derived": "slow_ar_u8u8.onnx",
|
||||
"converted_weights": 217,
|
||||
"verified_matrix_nodes": 217,
|
||||
"all_other_initializers_unchanged": true
|
||||
},
|
||||
{
|
||||
"source": "fast_ar_int8.onnx",
|
||||
"derived": "fast_ar_u8u8.onnx",
|
||||
"converted_weights": 21,
|
||||
"verified_matrix_nodes": 21,
|
||||
"all_other_initializers_unchanged": true
|
||||
}
|
||||
],
|
||||
"derived_files": {
|
||||
"runtime_manifest.json": "1aae85f0a5b58528e5c40373d8000448374e95b670d0fb01347a76be2ac10544",
|
||||
"fast_ar_u8u8.onnx.data": "91fe4f9fa713e4a433f50e485ece39de47d5866ba3f6af100abbbbfd230edf61",
|
||||
"slow_ar_u8u8.onnx": "ece245447b5d35a61f0e4d9096e963c048be564b80c2b41fc7cac4739f879d88",
|
||||
"fast_ar_u8u8.onnx": "c73de68593de21604344ef5df223a1d725fa64068db97cb12774b5e8a5b510fb",
|
||||
"slow_ar_u8u8.onnx.data": "cb314233e10bb973282df09953a91d78456fc61b6ae5c85ebd710450e9e8b4c3"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,80 @@
|
||||
[
|
||||
{
|
||||
"path": "codec_decoder_fp16.onnx",
|
||||
"size": 594319,
|
||||
"sha256": "25379b866ad555b9a55226c46325344d2ebfafea1b474c29de5223a9d01ea533",
|
||||
"publisher_lfs_verified": true
|
||||
},
|
||||
{
|
||||
"path": "codec_decoder_fp16.onnx.data",
|
||||
"size": 260741440,
|
||||
"sha256": "b9bc968a84f41b86a9a3d19bc6c42b00b5de576512a87501d0c66ff7f896c954",
|
||||
"publisher_lfs_verified": true
|
||||
},
|
||||
{
|
||||
"path": "config.json",
|
||||
"size": 2651,
|
||||
"sha256": "65c299d24934dcb47c34cea10c39ad401a817fb785f041dde37b8dde65b77e4e",
|
||||
"publisher_lfs_verified": false
|
||||
},
|
||||
{
|
||||
"path": "fast_ar_int8.onnx",
|
||||
"size": 511306,
|
||||
"sha256": "6cfc5c8e85d83d27d508d11351d8ca7d2749d6ff2990dc9efd048f86c27ff371",
|
||||
"publisher_lfs_verified": true
|
||||
},
|
||||
{
|
||||
"path": "fast_ar_int8.onnx.data",
|
||||
"size": 36718592,
|
||||
"sha256": "cef092e658d8daad329117f9e9c3b09730deb3e39ea6f6634cd4d1ec8426eb9d",
|
||||
"publisher_lfs_verified": true
|
||||
},
|
||||
{
|
||||
"path": "reference_codes.npy",
|
||||
"size": 8928,
|
||||
"sha256": "7a4fbf777804d88df906982b2b055f579229b0a2044208a4c9bc7680948c4471",
|
||||
"publisher_lfs_verified": true
|
||||
},
|
||||
{
|
||||
"path": "registration/codec_encoder_fp16.onnx",
|
||||
"size": 940787,
|
||||
"sha256": "f9c08ca7a3a428e2caf089a17e2179934e20ba5c7c8e5d5f9dbc8c89ebc0306b",
|
||||
"publisher_lfs_verified": true
|
||||
},
|
||||
{
|
||||
"path": "registration/codec_encoder_fp16.onnx.data",
|
||||
"size": 414425088,
|
||||
"sha256": "ca4af8d00784b557fc06c90e462de0ee36586f6ffca63f3ca24f3af121fbb300",
|
||||
"publisher_lfs_verified": true
|
||||
},
|
||||
{
|
||||
"path": "registration/registration_manifest.json",
|
||||
"size": 179,
|
||||
"sha256": "df743225ea9697f9b96c2505b1ed2345eae371c87591e6dd4b2fad998845fe64",
|
||||
"publisher_lfs_verified": false
|
||||
},
|
||||
{
|
||||
"path": "runtime_manifest.json",
|
||||
"size": 1424,
|
||||
"sha256": "c7dc8c2490bcad21739ac01994f0ed2dfc71f76e8e9695239c9606eac03e6b62",
|
||||
"publisher_lfs_verified": false
|
||||
},
|
||||
{
|
||||
"path": "slow_ar_int8.onnx",
|
||||
"size": 4820700,
|
||||
"sha256": "5aa5263d5c7e94cc58c81c969710045d313b4de87deae847f5388c126722bd3a",
|
||||
"publisher_lfs_verified": true
|
||||
},
|
||||
{
|
||||
"path": "slow_ar_int8.onnx.data",
|
||||
"size": 133471232,
|
||||
"sha256": "4cf0f7ee7d5a9e817caaed310cc2f62dc08ebd37a1b87300dd4255ff0c45dace",
|
||||
"publisher_lfs_verified": true
|
||||
},
|
||||
{
|
||||
"path": "tokenizer/tokenizer.json",
|
||||
"size": 5852397,
|
||||
"sha256": "f1c5ac4973f74a007635d81dafcb2cf0e5c4578c7426f48f53ab0ebf5b978bef",
|
||||
"publisher_lfs_verified": false
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,59 @@
|
||||
"""Pinned public Audio8 assets and an own CPU-only venv; no production writes."""
|
||||
from pathlib import Path
|
||||
import hashlib
|
||||
import json
|
||||
import os
|
||||
import subprocess
|
||||
import sys
|
||||
import time
|
||||
import urllib.request
|
||||
ROOT = Path('/data/athena-audio8-cpu-20261027')
|
||||
meta = json.loads((ROOT/'model-source.json').read_text())
|
||||
assert meta['id'] == 'Edge0/audio8-TTS-0.1B-ONNX-INT8'
|
||||
revision = '317c12d4e0da83847b594fcf8bd74bf2c76615ec'
|
||||
assert meta['sha'] == revision
|
||||
allowed = {'config.json', 'runtime_manifest.json', 'tokenizer/tokenizer.json',
|
||||
'reference_codes.npy', 'registration/registration_manifest.json'}
|
||||
rows = []
|
||||
for item in meta['siblings']:
|
||||
name = item['rfilename']
|
||||
if name not in allowed and not name.endswith(('.onnx', '.onnx.data')):
|
||||
continue
|
||||
path = ROOT/'model'/name
|
||||
path.parent.mkdir(parents=True, exist_ok=True)
|
||||
expected = item.get('lfs', {}).get('sha256')
|
||||
def digest(p):
|
||||
with p.open('rb') as stream:
|
||||
return hashlib.file_digest(stream, 'sha256').hexdigest()
|
||||
if not path.exists() or path.stat().st_size != item['size'] or expected and digest(path) != expected:
|
||||
tmp = path.with_name(path.name+'.partial')
|
||||
url = f'https://huggingface.co/{meta["id"]}/resolve/{revision}/{name}?download=1'
|
||||
start = time.monotonic()
|
||||
with urllib.request.urlopen(url, timeout=90) as response, tmp.open('wb') as stream:
|
||||
while chunk := response.read(1024*1024):
|
||||
stream.write(chunk)
|
||||
assert tmp.stat().st_size == item['size'], name
|
||||
actual = digest(tmp)
|
||||
assert not expected or actual == expected, name
|
||||
tmp.replace(path)
|
||||
print(json.dumps({'downloaded': name, 'bytes': path.stat().st_size,
|
||||
'seconds': time.monotonic()-start}), flush=True)
|
||||
actual = digest(path)
|
||||
rows.append(dict(path=name, size=path.stat().st_size, sha256=actual,
|
||||
publisher_lfs_verified=bool(expected)))
|
||||
(ROOT/'download-manifest.json').write_text(json.dumps(rows, indent=2))
|
||||
if not (ROOT/'venv/bin/python').exists():
|
||||
subprocess.run([sys.executable, '-m', 'venv', str(ROOT/'venv')], check=True)
|
||||
environment = os.environ.copy()
|
||||
environment.update(PIP_DISABLE_PIP_VERSION_CHECK='1', PIP_NO_INPUT='1',
|
||||
PIP_CACHE_DIR=str(ROOT/'pip-cache'))
|
||||
subprocess.run([str(ROOT/'venv/bin/python'), '-m', 'pip', 'install', '--only-binary=:all:',
|
||||
'numpy==2.2.6', 'onnxruntime==1.23.2', 'tokenizers==0.22.1',
|
||||
'soundfile==0.13.1', 'scipy==1.16.3'], check=True, env=environment)
|
||||
subprocess.run([str(ROOT/'venv/bin/python'), '-m', 'pip', 'check'], check=True, env=environment)
|
||||
freeze = subprocess.check_output([str(ROOT/'venv/bin/python'), '-m', 'pip', 'freeze'], text=True)
|
||||
(ROOT/'requirements.txt').write_text(freeze)
|
||||
assert not any(n in freeze.lower() for n in ['torch==', 'onnxruntime-gpu', 'nvidia-'])
|
||||
(ROOT/'prepared.json').write_text(json.dumps({'ok':True, 'model_revision':revision,
|
||||
'files':len(rows)}, indent=2))
|
||||
print('PREPARED', flush=True)
|
||||
@@ -0,0 +1,25 @@
|
||||
{
|
||||
"unchanged": {
|
||||
"/opt/athena-deck-dev/runtime/state/profiles.json": true,
|
||||
"/opt/athena-deck-dev/runtime/state/endpoint.json": true,
|
||||
"/opt/athena-deck-dev/runtime/state/audio-policy.json": true,
|
||||
"/opt/athena-deck-dev/runtime/state/cpu-partition.json": true,
|
||||
"/opt/athena-deck-dev/runtime/state/speech-voices/Anna/reference.wav": true,
|
||||
"/opt/athena-deck-dev/source/qwen_native_worker.py": true,
|
||||
"live_worker": true,
|
||||
"deck_not_restarted": true
|
||||
},
|
||||
"original_audio8_assets_unchanged": true,
|
||||
"original_audio8_source_clean": true,
|
||||
"test_units": {
|
||||
"prepare": "inactive",
|
||||
"register": "inactive",
|
||||
"avx2": "inactive",
|
||||
"benchmark": "inactive",
|
||||
"benchmark-u8u8": "inactive",
|
||||
"batch": "inactive",
|
||||
"batch-bounded": "inactive",
|
||||
"sentences": "inactive",
|
||||
"stt": "inactive"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
"""Encode only three existing Anna excerpts into own Audio8 test voice profiles."""
|
||||
import os
|
||||
os.environ.update(CUDA_VISIBLE_DEVICES='', HF_HUB_OFFLINE='1',
|
||||
HF_HUB_DISABLE_TELEMETRY='1', OPENBLAS_NUM_THREADS='1', OMP_NUM_THREADS='4')
|
||||
from pathlib import Path
|
||||
import hashlib
|
||||
import json
|
||||
import resource
|
||||
import sys
|
||||
import time
|
||||
import onnxruntime as ort
|
||||
|
||||
ROOT = Path('/data/athena-audio8-cpu-20261027')
|
||||
REFS = Path('/data/athena-articulino-references-20261027/references')
|
||||
sys.path.insert(0, str(ROOT/'source/onnx_runtime_0_1b_int8'))
|
||||
from arktts_runtime.registration import VoiceRegistration
|
||||
manifest = json.loads((ROOT/'model/runtime_manifest.json').read_text())
|
||||
selection = json.loads(Path('/data/athena-articulino-references-20261027/selection.json').read_text())
|
||||
texts = {x['label']:x['text'] for x in json.loads((ROOT/'reference-texts.json').read_text())}
|
||||
sessions = []
|
||||
original_session = ort.InferenceSession
|
||||
def audited_session(path, *args, **kwargs):
|
||||
session = original_session(path, *args, **kwargs)
|
||||
providers = session.get_providers()
|
||||
assert providers == ['CPUExecutionProvider']
|
||||
sessions.append(dict(file=Path(path).name, providers=providers))
|
||||
return session
|
||||
ort.InferenceSession = audited_session
|
||||
registration = VoiceRegistration(ROOT/'model/registration', ROOT/'voices', manifest['model_fingerprint'])
|
||||
assert registration.status()['available']
|
||||
rows = []
|
||||
for clip in selection['clips']:
|
||||
label = clip['label']
|
||||
source = REFS/clip['file']
|
||||
data = source.read_bytes()
|
||||
assert hashlib.sha256(data).hexdigest() == clip['sha256']
|
||||
available = next(int(x.split()[1])*1024 for x in Path('/proc/meminfo').read_text().splitlines() if x.startswith('MemAvailable:'))
|
||||
assert available > 6*1024**3, 'Own 4 GiB budget plus 2 GiB host reserve unavailable'
|
||||
start = time.monotonic()
|
||||
meta = registration.register(data, source.name, texts[label], 'anna-'+label)
|
||||
row = dict(label=label, seconds=time.monotonic()-start, code_shape=meta['shape'],
|
||||
source_sha256=meta['source_sha256'], source_sample_rate=meta['source_sample_rate'],
|
||||
codec_sample_rate=meta['sample_rate'], peak_rss_kib=resource.getrusage(resource.RUSAGE_SELF).ru_maxrss)
|
||||
rows.append(row)
|
||||
(ROOT/'registration-results.json').write_text(json.dumps(dict(rows=rows,sessions=sessions),indent=2))
|
||||
print(json.dumps(row), flush=True)
|
||||
@@ -0,0 +1,57 @@
|
||||
{
|
||||
"rows": [
|
||||
{
|
||||
"label": "A",
|
||||
"seconds": 6.36086448700371,
|
||||
"code_shape": [
|
||||
10,
|
||||
171
|
||||
],
|
||||
"source_sample_rate": 48000,
|
||||
"codec_sample_rate": 44100,
|
||||
"peak_rss_kib": 2166692
|
||||
},
|
||||
{
|
||||
"label": "B",
|
||||
"seconds": 5.811623518995475,
|
||||
"code_shape": [
|
||||
10,
|
||||
170
|
||||
],
|
||||
"source_sample_rate": 48000,
|
||||
"codec_sample_rate": 44100,
|
||||
"peak_rss_kib": 2166692
|
||||
},
|
||||
{
|
||||
"label": "C",
|
||||
"seconds": 4.827425477000361,
|
||||
"code_shape": [
|
||||
10,
|
||||
125
|
||||
],
|
||||
"source_sample_rate": 48000,
|
||||
"codec_sample_rate": 44100,
|
||||
"peak_rss_kib": 2166692
|
||||
}
|
||||
],
|
||||
"sessions": [
|
||||
{
|
||||
"file": "codec_encoder_fp16.onnx",
|
||||
"providers": [
|
||||
"CPUExecutionProvider"
|
||||
]
|
||||
},
|
||||
{
|
||||
"file": "codec_encoder_fp16.onnx",
|
||||
"providers": [
|
||||
"CPUExecutionProvider"
|
||||
]
|
||||
},
|
||||
{
|
||||
"file": "codec_encoder_fp16.onnx",
|
||||
"providers": [
|
||||
"CPUExecutionProvider"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
anyio==4.15.1
|
||||
certifi==2026.10.23
|
||||
cffi==2.1.1
|
||||
click==8.5.0
|
||||
coloredlogs==15.0.1
|
||||
filelock==4.2.4
|
||||
flatbuffers==25.12.19
|
||||
fsspec==2026.9.0
|
||||
h11==0.16.0
|
||||
hf-xet==1.7.0
|
||||
httpcore==1.0.9
|
||||
httpx==0.28.1
|
||||
huggingface_hub==1.33.0
|
||||
humanfriendly==10.0
|
||||
idna==3.20
|
||||
ml_dtypes==0.6.0
|
||||
mpmath==1.3.0
|
||||
numpy==2.2.6
|
||||
onnx==1.19.1
|
||||
onnxruntime==1.23.2
|
||||
packaging==26.3
|
||||
protobuf==7.36.2
|
||||
pycparser==3.12
|
||||
PyYAML==6.0.3
|
||||
scipy==1.16.3
|
||||
soundfile==0.13.1
|
||||
sympy==1.14.0
|
||||
tokenizers==0.22.1
|
||||
tqdm==4.70.1
|
||||
typing_extensions==4.16.0
|
||||
@@ -0,0 +1,289 @@
|
||||
{
|
||||
"phase": "complete",
|
||||
"runs": [
|
||||
{
|
||||
"name": "story-A",
|
||||
"label": "A",
|
||||
"case": "story",
|
||||
"seed": 42,
|
||||
"prompt_positions": 326,
|
||||
"frame_cap": 1024,
|
||||
"sentence_count": 4,
|
||||
"ok": true,
|
||||
"file": "story-A.wav",
|
||||
"generation_seconds": 44.9978594629938,
|
||||
"audio_seconds": 12.72453514739229,
|
||||
"rtf": 3.5363067445505436,
|
||||
"complete_audio_ready_seconds": 44.99060606698913,
|
||||
"codec_frames": 274,
|
||||
"first_complete_sentence_seconds": 10.434463351994054,
|
||||
"codec_frames_per_sentence": [
|
||||
63,
|
||||
74,
|
||||
67,
|
||||
70
|
||||
],
|
||||
"token_limit_hit": false,
|
||||
"peak": 0.7103569507598877,
|
||||
"clipped_fraction": 0.0,
|
||||
"sha256": "d15cbea43b7531babb1bc990061e081ec7321c99a85667b228cd49a8ff69b213",
|
||||
"peak_rss_kib": 1606200,
|
||||
"onnx_run_times": {
|
||||
"slow": {
|
||||
"seconds": 27.530742359158467,
|
||||
"calls": 1364
|
||||
},
|
||||
"fast": {
|
||||
"seconds": 6.719193295299192,
|
||||
"calls": 2740
|
||||
},
|
||||
"decoder": {
|
||||
"seconds": 8.870893536019139,
|
||||
"calls": 4
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "technical-A",
|
||||
"label": "A",
|
||||
"case": "technical",
|
||||
"seed": 42,
|
||||
"prompt_positions": 335,
|
||||
"frame_cap": 1024,
|
||||
"sentence_count": 5,
|
||||
"ok": true,
|
||||
"file": "technical-A.wav",
|
||||
"generation_seconds": 62.66300386599323,
|
||||
"audio_seconds": 18.575963718820862,
|
||||
"rtf": 3.3733379766727314,
|
||||
"complete_audio_ready_seconds": 62.655606721004006,
|
||||
"codec_frames": 400,
|
||||
"first_complete_sentence_seconds": 10.544194268994033,
|
||||
"codec_frames_per_sentence": [
|
||||
61,
|
||||
72,
|
||||
50,
|
||||
129,
|
||||
88
|
||||
],
|
||||
"token_limit_hit": false,
|
||||
"peak": 0.7004554867744446,
|
||||
"clipped_fraction": 0.0,
|
||||
"sha256": "5860755714c31a9437bd209f1877f2c9e632a8e5aebfc451fe3423da92231e30",
|
||||
"peak_rss_kib": 1867932,
|
||||
"onnx_run_times": {
|
||||
"slow": {
|
||||
"seconds": 37.11346254394448,
|
||||
"calls": 1751
|
||||
},
|
||||
"fast": {
|
||||
"seconds": 9.454663085518405,
|
||||
"calls": 4000
|
||||
},
|
||||
"decoder": {
|
||||
"seconds": 12.964893113006838,
|
||||
"calls": 5
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "story-B",
|
||||
"label": "B",
|
||||
"case": "story",
|
||||
"seed": 42,
|
||||
"prompt_positions": 318,
|
||||
"frame_cap": 1024,
|
||||
"sentence_count": 4,
|
||||
"ok": true,
|
||||
"file": "story-B.wav",
|
||||
"generation_seconds": 46.6603036489978,
|
||||
"audio_seconds": 13.839092970521541,
|
||||
"rtf": 3.3716301890874103,
|
||||
"complete_audio_ready_seconds": 46.65255993399478,
|
||||
"codec_frames": 298,
|
||||
"first_complete_sentence_seconds": 11.041374578999239,
|
||||
"codec_frames_per_sentence": [
|
||||
70,
|
||||
78,
|
||||
73,
|
||||
77
|
||||
],
|
||||
"token_limit_hit": false,
|
||||
"peak": 0.6809453964233398,
|
||||
"clipped_fraction": 0.0,
|
||||
"sha256": "240aeb6bbc102524dae704fb986821d4be5e8ec5ae5730cabc74f1bd5859c4ff",
|
||||
"peak_rss_kib": 1868524,
|
||||
"onnx_run_times": {
|
||||
"slow": {
|
||||
"seconds": 28.06761429355538,
|
||||
"calls": 1356
|
||||
},
|
||||
"fast": {
|
||||
"seconds": 6.7645990198798245,
|
||||
"calls": 2980
|
||||
},
|
||||
"decoder": {
|
||||
"seconds": 9.621976916008862,
|
||||
"calls": 4
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "technical-B",
|
||||
"label": "B",
|
||||
"case": "technical",
|
||||
"seed": 42,
|
||||
"prompt_positions": 327,
|
||||
"frame_cap": 1024,
|
||||
"sentence_count": 5,
|
||||
"ok": true,
|
||||
"file": "technical-B.wav",
|
||||
"generation_seconds": 65.48813978799444,
|
||||
"audio_seconds": 20.387120181405894,
|
||||
"rtf": 3.2122310167045076,
|
||||
"complete_audio_ready_seconds": 65.48056019999785,
|
||||
"codec_frames": 439,
|
||||
"first_complete_sentence_seconds": 11.243860243004747,
|
||||
"codec_frames_per_sentence": [
|
||||
70,
|
||||
75,
|
||||
62,
|
||||
151,
|
||||
81
|
||||
],
|
||||
"token_limit_hit": false,
|
||||
"peak": 0.5951974391937256,
|
||||
"clipped_fraction": 0.0,
|
||||
"sha256": "2fbe98da1b827e26de4f057857e1c304eb767b77add878a1c84fd67c22cc6b56",
|
||||
"peak_rss_kib": 1936224,
|
||||
"onnx_run_times": {
|
||||
"slow": {
|
||||
"seconds": 37.59822197309404,
|
||||
"calls": 1750
|
||||
},
|
||||
"fast": {
|
||||
"seconds": 10.667495122805121,
|
||||
"calls": 4390
|
||||
},
|
||||
"decoder": {
|
||||
"seconds": 14.167216976013151,
|
||||
"calls": 5
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "story-C",
|
||||
"label": "C",
|
||||
"case": "story",
|
||||
"seed": 42,
|
||||
"prompt_positions": 272,
|
||||
"frame_cap": 1024,
|
||||
"sentence_count": 4,
|
||||
"ok": true,
|
||||
"file": "story-C.wav",
|
||||
"generation_seconds": 42.513747632008744,
|
||||
"audio_seconds": 13.328253968253968,
|
||||
"rtf": 3.1897462138154427,
|
||||
"complete_audio_ready_seconds": 42.50826177200361,
|
||||
"codec_frames": 287,
|
||||
"first_complete_sentence_seconds": 9.808746848008013,
|
||||
"codec_frames_per_sentence": [
|
||||
64,
|
||||
78,
|
||||
69,
|
||||
76
|
||||
],
|
||||
"token_limit_hit": false,
|
||||
"peak": 0.7426947355270386,
|
||||
"clipped_fraction": 0.0,
|
||||
"sha256": "6bb1713090b24df79bf7c2778f3f0218f57a5006df8ca3e8fc38a5f57c435270",
|
||||
"peak_rss_kib": 1936652,
|
||||
"onnx_run_times": {
|
||||
"slow": {
|
||||
"seconds": 24.685255893404246,
|
||||
"calls": 1161
|
||||
},
|
||||
"fast": {
|
||||
"seconds": 6.5907913622650085,
|
||||
"calls": 2870
|
||||
},
|
||||
"decoder": {
|
||||
"seconds": 9.21085961398785,
|
||||
"calls": 4
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "technical-C",
|
||||
"label": "C",
|
||||
"case": "technical",
|
||||
"seed": 42,
|
||||
"prompt_positions": 281,
|
||||
"frame_cap": 1024,
|
||||
"sentence_count": 5,
|
||||
"ok": true,
|
||||
"file": "technical-C.wav",
|
||||
"generation_seconds": 57.45580405800138,
|
||||
"audio_seconds": 18.715283446712018,
|
||||
"rtf": 3.069993795263382,
|
||||
"complete_audio_ready_seconds": 57.448640490998514,
|
||||
"codec_frames": 403,
|
||||
"first_complete_sentence_seconds": 9.234346070996253,
|
||||
"codec_frames_per_sentence": [
|
||||
60,
|
||||
73,
|
||||
49,
|
||||
139,
|
||||
82
|
||||
],
|
||||
"token_limit_hit": false,
|
||||
"peak": 0.808592677116394,
|
||||
"clipped_fraction": 0.0,
|
||||
"sha256": "b240f2fc6f888763b7988d3c56270cf7a9a28b0565ba17a7a4c869d70052f9a9",
|
||||
"peak_rss_kib": 1938188,
|
||||
"onnx_run_times": {
|
||||
"slow": {
|
||||
"seconds": 32.070427761922474,
|
||||
"calls": 1484
|
||||
},
|
||||
"fast": {
|
||||
"seconds": 9.383834901353111,
|
||||
"calls": 4030
|
||||
},
|
||||
"decoder": {
|
||||
"seconds": 12.988757519007777,
|
||||
"calls": 5
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"admission_available_bytes": 6766796800,
|
||||
"cpu_threads": 4,
|
||||
"cpu_quota": 400,
|
||||
"precision": "u8u8",
|
||||
"codec_precision": "fp16",
|
||||
"test_memory_max_bytes": 3758096384,
|
||||
"host_reserve_bytes": 2147483648,
|
||||
"seed": 42,
|
||||
"temperature": 0.7,
|
||||
"top_p": 0.9,
|
||||
"top_k": 50,
|
||||
"max_new_tokens": 1024,
|
||||
"output_mode": "official synthesize, one sentence per call, PCM concatenated",
|
||||
"original_source_unmodified": true,
|
||||
"compatibility": "Equivalent U8U8 MatMulInteger representation; see compatibility-manifest.json",
|
||||
"load_seconds": 1.8161020020052092,
|
||||
"providers": {
|
||||
"slow": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"fast": [
|
||||
"CPUExecutionProvider"
|
||||
],
|
||||
"decoder": [
|
||||
"CPUExecutionProvider"
|
||||
]
|
||||
},
|
||||
"sample_rate": 44100,
|
||||
"minimum_available_bytes": 4821409792
|
||||
}
|
||||
@@ -0,0 +1,73 @@
|
||||
{
|
||||
"method": "Same German preparation and number expansion <=999, case/punctuation normalized; combined TTS+STT deviations, not naturalness or speaker similarity.",
|
||||
"rows": [
|
||||
{
|
||||
"file": "story-A.wav",
|
||||
"case": "story",
|
||||
"reference_words": 36,
|
||||
"recognized_words": 36,
|
||||
"edits": 0,
|
||||
"deviation": 0.0,
|
||||
"stt_exit_code": 0
|
||||
},
|
||||
{
|
||||
"file": "technical-A.wav",
|
||||
"case": "technical",
|
||||
"reference_words": 46,
|
||||
"recognized_words": 43,
|
||||
"edits": 9,
|
||||
"deviation": 0.1956521739130435,
|
||||
"stt_exit_code": 0
|
||||
},
|
||||
{
|
||||
"file": "story-B.wav",
|
||||
"case": "story",
|
||||
"reference_words": 36,
|
||||
"recognized_words": 36,
|
||||
"edits": 1,
|
||||
"deviation": 0.027777777777777776,
|
||||
"stt_exit_code": 0
|
||||
},
|
||||
{
|
||||
"file": "technical-B.wav",
|
||||
"case": "technical",
|
||||
"reference_words": 46,
|
||||
"recognized_words": 42,
|
||||
"edits": 8,
|
||||
"deviation": 0.17391304347826086,
|
||||
"stt_exit_code": 0
|
||||
},
|
||||
{
|
||||
"file": "story-C.wav",
|
||||
"case": "story",
|
||||
"reference_words": 36,
|
||||
"recognized_words": 36,
|
||||
"edits": 1,
|
||||
"deviation": 0.027777777777777776,
|
||||
"stt_exit_code": 0
|
||||
},
|
||||
{
|
||||
"file": "technical-C.wav",
|
||||
"case": "technical",
|
||||
"reference_words": 46,
|
||||
"recognized_words": 43,
|
||||
"edits": 8,
|
||||
"deviation": 0.17391304347826086,
|
||||
"stt_exit_code": 0
|
||||
}
|
||||
],
|
||||
"summary": {
|
||||
"story": {
|
||||
"files": 3,
|
||||
"reference_words": 108,
|
||||
"edits": 2,
|
||||
"deviation": 0.018518518518518517
|
||||
},
|
||||
"technical": {
|
||||
"files": 3,
|
||||
"reference_words": 138,
|
||||
"edits": 25,
|
||||
"deviation": 0.18115942028985507
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
"""Same normalized round-trip check as prior auditions, not speaker similarity."""
|
||||
from pathlib import Path
|
||||
import json
|
||||
import re
|
||||
import sys
|
||||
import unicodedata
|
||||
ROOT=Path(__file__).resolve().parent
|
||||
search=[p for parent in ROOT.parents for p in (parent,parent/'repo')]
|
||||
source=next(p for p in search if (p/'speech_text.py').is_file())
|
||||
sys.path.insert(0,str(source))
|
||||
from speech_text import prepare_for_speech
|
||||
def de_number(n):
|
||||
basic=['null','eins','zwei','drei','vier','fünf','sechs','sieben','acht','neun',
|
||||
'zehn','elf','zwölf','dreizehn','vierzehn','fünfzehn','sechzehn','siebzehn','achtzehn','neunzehn']
|
||||
if n<20:return basic[n]
|
||||
if n<100:
|
||||
tens=['','','zwanzig','dreißig','vierzig','fünfzig','sechzig','siebzig','achtzig','neunzig']
|
||||
return ((('ein' if n%10==1 else basic[n%10])+'und') if n%10 else '')+tens[n//10]
|
||||
if n<1000:return ('ein' if n//100==1 else basic[n//100])+'hundert'+(de_number(n%100) if n%100 else '')
|
||||
return str(n)
|
||||
def tokens(text):
|
||||
text=prepare_for_speech(text,'German')
|
||||
text=re.sub(r'\b\d{1,3}\b',lambda m:de_number(int(m[0])),text)
|
||||
text=unicodedata.normalize('NFC',text).casefold().replace('ß','ss')
|
||||
return re.findall(r'[^\W_]+',text,re.UNICODE)
|
||||
def distance(a,b):
|
||||
previous=list(range(len(b)+1))
|
||||
for i,x in enumerate(a,1):
|
||||
current=[i]
|
||||
for j,y in enumerate(b,1):current.append(min(current[-1]+1,previous[j]+1,previous[j-1]+(x!=y)))
|
||||
previous=current
|
||||
return previous[-1]
|
||||
cases={x['id']:x['text'] for x in json.loads((ROOT/'cases.json').read_text())}
|
||||
rows=[]
|
||||
for row in json.loads((ROOT/'transcriptions.json').read_text()):
|
||||
case=Path(row['file']).stem.rsplit('-',1)[0]
|
||||
a=tokens(cases[case]);b=tokens(row.get('text',''));edits=distance(a,b)
|
||||
rows.append(dict(file=row['file'],case=case,reference_words=len(a),recognized_words=len(b),
|
||||
edits=edits,deviation=edits/len(a),stt_exit_code=row['exit_code']))
|
||||
summary={}
|
||||
for group in ['story','technical']:
|
||||
selected=[x for x in rows if x['case']==group]
|
||||
words=sum(x['reference_words'] for x in selected);edits=sum(x['edits'] for x in selected)
|
||||
summary[group]=dict(files=len(selected),reference_words=words,edits=edits,deviation=edits/words if words else None)
|
||||
result=dict(method='Same German preparation and number expansion <=999, case/punctuation normalized; combined TTS+STT deviations, not naturalness or speaker similarity.',rows=rows,summary=summary)
|
||||
(ROOT/'roundtrip-scores.json').write_text(json.dumps(result,ensure_ascii=False,indent=2))
|
||||
print(json.dumps(result,indent=2))
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"repo": "https://github.com/Edge0-AI/Audio8_TTS",
|
||||
"commit": "07e40f5d0b03fc473635ef378654bfb581027ac3",
|
||||
"model_repo": "Edge0/audio8-TTS-0.1B-ONNX-INT8",
|
||||
"model_revision": "317c12d4e0da83847b594fcf8bd74bf2c76615ec"
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"story": {
|
||||
"files": 3,
|
||||
"generation_seconds": 134.17191074400034,
|
||||
"audio_seconds": 39.8918820861678,
|
||||
"weighted_rtf": 3.363388833201315
|
||||
},
|
||||
"technical": {
|
||||
"files": 3,
|
||||
"generation_seconds": 185.60694771198905,
|
||||
"audio_seconds": 57.67836734693877,
|
||||
"weighted_rtf": 3.2179646590124915
|
||||
},
|
||||
"all": {
|
||||
"files": 6,
|
||||
"generation_seconds": 319.7788584559894,
|
||||
"audio_seconds": 97.57024943310657,
|
||||
"weighted_rtf": 3.277421758311968
|
||||
},
|
||||
"load_seconds": 1.8161020020052092,
|
||||
"peak_rss_gib": 1.8484001159667969,
|
||||
"minimum_available_gib": 4.490287780761719
|
||||
}
|
||||
@@ -0,0 +1,38 @@
|
||||
[
|
||||
{
|
||||
"file": "story-A.wav",
|
||||
"exit_code": 0,
|
||||
"stt_seconds": 1.049475984997116,
|
||||
"text": "Wenn du magst, erzähle ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie, das hat wunderbar funktioniert."
|
||||
},
|
||||
{
|
||||
"file": "technical-A.wav",
|
||||
"exit_code": 0,
|
||||
"stt_seconds": 1.3958390220068395,
|
||||
"text": "Home Assistant läuft in Docker of Unrate. Die SSD hat 47 Grad Celsius. Das Logfile enthält keinen Fehler. Die Datei ist 21 Mb groß und die Verbindung überträgt 100 Mbit pro Sekunde. Um 18.30 Cell Eachest startet der nächste Scan."
|
||||
},
|
||||
{
|
||||
"file": "story-B.wav",
|
||||
"exit_code": 0,
|
||||
"stt_seconds": 1.061967312998604,
|
||||
"text": "Wenn du magst, erzähl ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen, auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie, das hat wunderbar funktioniert."
|
||||
},
|
||||
{
|
||||
"file": "technical-B.wav",
|
||||
"exit_code": 0,
|
||||
"stt_seconds": 1.549511414996232,
|
||||
"text": "Home Assistant läuft in Docker auf Unrate. Die SSD hat 47 Grad Celsius. Das Lookfeel enthält keinen Fehler. Die Datei ist 15 MiB groß und die Verbindung überträgt 100 Mbit pro Sekunde. Um 18.30 Test startet der nächste Scan."
|
||||
},
|
||||
{
|
||||
"file": "story-C.wav",
|
||||
"exit_code": 0,
|
||||
"stt_seconds": 1.0298252119973768,
|
||||
"text": "Wenn du magst, erzähl ich dir eine kurze Geschichte. Anna öffnete das Fenster und hörte drei Vögel singen. Auf dem Tisch lagen sieben Bücher und eine rote Tasse. Zum Schluss sagte sie, das hat wunderbar funktioniert."
|
||||
},
|
||||
{
|
||||
"file": "technical-C.wav",
|
||||
"exit_code": 0,
|
||||
"stt_seconds": 1.3918977260036627,
|
||||
"text": "Home Assistant läuft in Docker auf Unraid. Die SSD hat 47 Grad Celsius. Das Lookfehl enthält keinen Fehler. Die Datei ist 13 Mbit groß und die Verbindung überträgt 100 Mbit pro Sekunde. Um 18.30 T-State startet der nächste Scan."
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,62 @@
|
||||
# DeepSeek mit Strata v0.2.6: ein 64K-Kontexttest
|
||||
|
||||
**Abgeschlossen:** 64.487 Eingabetokens verarbeitet, drei Suchmarken gefunden,
|
||||
Qwen unabhängig bestätigt wiederhergestellt. [Messwerte und Grenzen](RESULTS.md).
|
||||
|
||||
Michael hat einen einzelnen kurzen DeepSeek-Test mit 64K-Kontext beauftragt.
|
||||
Vorab festgelegt: dieselbe synthetische Quelltextart und Suchmarken wie beim
|
||||
[früheren Kontexttest](../deepseek-context-2026-10-24/RESULTS.md), maximal
|
||||
65.536 Kontexttokens, Eingabe nahe 64.512 laut offiziellem Tokenzähler, 128
|
||||
Ausgabetokens. Temperatur 0, top_p 1, seed 42, Denken aus, genau sechs Experten.
|
||||
Keine echte Coding-Aufgabe und kein allgemeiner Qualitätsbenchmark.
|
||||
|
||||
Neue produktive native Engine `strata-dsv41 0.1.51`, fester Release-Commit
|
||||
`4b9e05a2a806a3fe24f7b2560d98626c37dade35`; vorhandene DeepSeek-V4.1-Flash-1017
|
||||
GSQ-RCO IQ2_XXS-Gewichte und Pack aus der Vorbereitung vom 24.10. wiederverwenden.
|
||||
Keine Downloads, Neuinstallation oder Änderung produktiver Profile.
|
||||
Beide GPUs 3060/5080, aktuelle gespeicherte Strata-CPU-Maske. `--tp 2` und
|
||||
DSpark auto bleiben wie im früheren Test angefordert; tatsächliche Verwendung
|
||||
erst aus dem neuen Lauf berichten. Kein Fünf-Experten-Schnellmodus.
|
||||
|
||||
Ein eigener nativer Worker auf Loopback-Port 19084, Quellcode und Binary aus
|
||||
der bestehenden produktiven Strata-Installation, vollständige native
|
||||
Server-Pythonumgebung aus der vorhandenen DeepSeek-Vorbereitung. Der Worker
|
||||
ist nur für diesen Test vorgesehen und wird am Ende entfernt. Der Harness liegt
|
||||
unter `/data/athena-deck-strata/experiments/deepseek-026-64k-20261026`.
|
||||
Er startet keine zusätzlichen Container oder dauerhaften Dienste.
|
||||
|
||||
Vorher dreimal authentifizierten Endpunkt-Leerlauf (Annahmezähler schließt
|
||||
wartende API-Anfragen ein) und den eindeutig identifizierten Qwen-Worker direkt
|
||||
prüfen. Nur dessen ruhende eigene Prozessgruppe regulär beenden. Neue
|
||||
Produktionsanfragen erhalten Vorrang; dann ausschließlich den eigenen
|
||||
synthetischen Worker beenden. Abschließend im finally-Pfad das vor Testbeginn
|
||||
aktive Qwen-Profil regulär über den Endpunkt laden und unabhängig überprüfen.
|
||||
Keine erzwungenen Abbrüche produktiver Arbeit. TTS/STT bleiben erhalten.
|
||||
|
||||
Speicher für Testserver und rekursive Nachkommen alle zwei Sekunden aus
|
||||
`smaps_rollup`; korrigierten Parser vorab auf eigenem Prozess auf PSS > 0 prüfen.
|
||||
Zusätzlich Host-MemAvailable/Swap und GPU-Belegung. Reserve mindestens 1.536 MiB,
|
||||
Ladephase maximal 10 Minuten, einzelne Inferenz maximal 20 Minuten,
|
||||
Gesamtkontroller maximal 30 Minuten. Raten aus getrennten Backendzeiten,
|
||||
Modellladen/TTFT/Gesamtdauer separat. Kein physischer Cache-Flush; historischen
|
||||
Vergleich nicht als isolierte oder statistisch belastbare Versionsmessung ausgeben.
|
||||
|
||||
Native Reproduktion: aktueller freigegebener Strata-Quellstand und die geprüfte
|
||||
vollständige native Server-venv der DeepSeek-Vorbereitung,
|
||||
CUDA-13-Bibliotheken, vorbereiteter alter DeepSeek-Pack, Python3.13, taskset,
|
||||
nsenter und nvidia-smi. Die vier Python-Skripte in das oben genannte Testverzeichnis
|
||||
legen; vorhandenen autorisierten Athena-API-Schlüssel als JSON auf stdin an
|
||||
`../deepseek-iq2-20261024/venv/bin/python run_context.py --detach` übergeben. Schlüssel bleibt
|
||||
im Prozessspeicher und wird nicht dokumentiert. Kein Auslesen von Browsercookies,
|
||||
kein Admin-Login und keine Änderung von Zugangsdaten. VPN bleibt vollständig tabu.
|
||||
|
||||
Dies ist kein vollständiger nativer Debian-/Restore-Nachweis und keine neue
|
||||
DeepSeek-Produkteinbindung. Die Ergebnisse stehen in RESULTS.md.
|
||||
|
||||
Erster Startversuch: Die beim Enginebau erzeugte produktive `.venv` konnte den
|
||||
Server außerhalb des Container-Pythonumfelds wegen fehlendem `jinja2` nicht
|
||||
starten. Keine DeepSeek-Inferenz und kein Gewichts-Ladevorgang. Der finally-Pfad
|
||||
stellt Qwen wieder her. Vor korrigierter Wiederholung wird `serve/server.py --help`
|
||||
mit der bereits vorhandenen vollständigen nativen Test-venv erfolgreich geprüft;
|
||||
keine Pakete in der produktiven Umgebung nachinstalliert. Diese Abhängigkeit
|
||||
muss ein vollständiger nativer Erstinstaller ausdrücklich bereitstellen.
|
||||
@@ -0,0 +1,95 @@
|
||||
# DeepSeek 64K mit Strata v0.2.6: erfolgreich, Qwen wiederhergestellt
|
||||
|
||||
26.10.2026. Ein einzelner Messlauf mit der neuen nativen Engine **0.1.51**,
|
||||
vorhandenem DeepSeek-V4.1-Flash-1017 GSQ-RCO IQ2_XXS und **sechs Experten**.
|
||||
64K funktioniert; alle drei Suchmarken wurden korrekt wiedergegeben.
|
||||
Das bisherige Qwen-Dual-Slot-Profil ist anschließend unabhängig bestätigt
|
||||
wieder geladen, mit unveränderten Einstellungen und geladenem TTS/STT.
|
||||
|
||||
## Geschwindigkeit
|
||||
|
||||
Dieselbe deterministische synthetische Eingabe wie beim alten 64K-Test:
|
||||
**64.487 Eingabetokens**, Kontext 65.536, Ausgabe 128 Tokens, seed42,
|
||||
temperature0, top_p1, Denken aus, kein KV-Cachetreffer. Modellladen ist separat.
|
||||
|
||||
| Messgröße | 24.10.: Engine 0.1.49.2 | 26.10.: Engine 0.1.51 |
|
||||
|---|---:|---:|
|
||||
| Eingabe | 195,2 Tokens/s | **142,3 Tokens/s** |
|
||||
| Ausgabe | 5,6 Tokens/s | **6,5 Tokens/s** |
|
||||
| Erster Text | 330,48 s | **453,24 s** |
|
||||
| Ganze Anfrage ohne Modellladen | 353,39 s | **472,73 s** |
|
||||
| Modellladen | 28,38 s | **26,20 s** |
|
||||
|
||||
In diesem Lauf war die Ausgabe rechnerisch rund **16 % schneller**, das Einlesen
|
||||
rund **27 % langsamer**. Die gesamte Anfrage dauerte rund **34 % länger**:
|
||||
7 Minuten 53 Sekunden statt 5 Minuten 53 Sekunden. Bei dieser großen erstmaligen
|
||||
Eingabe überwiegt somit der langsamere Prefill. Keine Aussage, dass die neue
|
||||
Engine allgemein schneller oder langsamer wäre: jeweils nur eine historische
|
||||
Messung, keine kontrollierte ABBA-Serie, keine physischen Cache-Flushes und
|
||||
kein Test späterer gecachter Coding-Turns.
|
||||
|
||||
Die neue Engine wählt selbst einen anderen RAM-Store: laut eigenem Startlog
|
||||
38,2 GB statt der dort genannten möglichen 49,4 GB; zunächst 26,9 GB heißeste
|
||||
Experten vorgeladen. Diese automatische Cacheentscheidung wurde nicht verändert.
|
||||
Sie kann neben anderen Engineänderungen das Ergebnis beeinflussen; eine Ursache
|
||||
des langsameren Prefills ist damit nicht isoliert bewiesen.
|
||||
|
||||
## Speicher und tatsächliche Ausführung
|
||||
|
||||
- Server und rekursive Engine-Nachkommen: **40,46 GiB PSS** Spitzenwert,
|
||||
40,47 GiB RSS und 40,45 GiB private Seiten. PSS umfasst residente Mappings,
|
||||
ist kein ausschließliches Maß anonymen Modell-RAMs. Prozess-SwapPss: 0.
|
||||
- Verfügbarer Host-RAM: Minimum **17,67 GiB**. Host-Swap war schon vorher
|
||||
belegt (0,8653 GiB), Maximum 0,8658 GiB. Kein Reserve-Abbruch oder OOM.
|
||||
- Gesamte GPU-Belegung: RTX3060 maximal **11.451 MiB**, RTX5080
|
||||
maximal **15.426 MiB**. Diese Werte sind Kartenbelegung, nicht ausschließlich
|
||||
eine private Modellallokation.
|
||||
- 227 Speicherproben während Vorbereitung/Anfrage, Parser vorab auf eigenem
|
||||
Prozess geprüft. Die alte 64K-Prozess-PSS-Messung war ungültig; deshalb kein
|
||||
behaupteter Modell-RAM-Gewinn gegenüber einer alten PSS-Zahl.
|
||||
- `--tp 2` angefordert, upstream wegen 256er-Blöcken bei n_ff2304 wieder auf
|
||||
TP1/Schichtaufteilung zurückgenommen. Trotzdem beide GPUs: CUDA0 Layer0–19,
|
||||
CUDA1 Layer20–39 plus Kopf. Startlog bestätigt sechs Experten, volle Qualität.
|
||||
DSpark auto wie vorher, keine absichtliche Verringerung der Expertenzahl.
|
||||
|
||||
Die drei Fundstellen sind nur ein kleiner Retrieval-Plausibilitätstest.
|
||||
128 Tokens begrenzen absichtlich die Ausgabe; der zusätzliche 300-Wörter-Auftrag
|
||||
des Performanceprompts wurde damit nicht vollständig bearbeitet. Kein Nachweis
|
||||
umfassender Coding- oder Langkontextintelligenz; kein generierter Code ausgeführt.
|
||||
|
||||
## Ablauf, Startfehler und Wiederherstellung
|
||||
|
||||
Der erste Start scheiterte vor Gewichtsinitialisierung und Inferenz an fehlendem
|
||||
`jinja2` in der Engine-Build-venv auf dem Host. Der finally-Pfad stellte Qwen mit
|
||||
identischen Einstellungs-Hashes wieder her. Das alte Controller-Label lautete
|
||||
`complete`, obwohl der Arm einen Startfehler hatte: Dieses Label allein bedeutete
|
||||
keinen erfolgreichen DeepSeek-Test. Der Controller wurde korrigiert, sodass ein
|
||||
Armfehler künftig `finished_with_error` ergibt. [Erster Versuch](failed-start.json).
|
||||
|
||||
Danach wurde die bereits vorhandene vollständige native DeepSeek-Test-venv mit
|
||||
dem neuen Server durch dessen `--help`-Aufruf vorab geprüft und verwendet. Keine
|
||||
Nachinstallation in der Produktion. Die neue **Binary und der Serverquellcode**
|
||||
stammen weiterhin aus der aktivierten Version0.1.51; nur die vollständige
|
||||
Python-Abhängigkeitsumgebung wurde wiederverwendet. Korrigierter Ablauf inklusive
|
||||
Laden, Inferenz und Wiederherstellung: **575,75 Sekunden**, rund9 Minuten36.
|
||||
|
||||
Unabhängige Abnahme nach regulärem Wiederladen über den authentifizierten Endpunkt:
|
||||
|
||||
- `flash-next-strata-iq3-dual`, zwei GPUs, bisherige Argumente und Vision.
|
||||
- Alle 16 verglichenen Workerfelder identisch; ephemere Ports/Keys ausgenommen.
|
||||
- Profile, Endpunkt, Audiopolitik, CPU-Aufteilung und Reasoning-Budget per Hash
|
||||
unverändert. Direkter Qwen-Healthcheck `ok`, Modell geladen.
|
||||
- Qwen/TTS/STT geladen, zum Prüfzeitpunkt kein aktiver Endpunktrequest.
|
||||
- Keine Test-/DeepSeek-Prozesse zurückgelassen. Nur den synthetischen KV-Slotcache
|
||||
des eigenen Testlaufs entfernt (70.875.652 Bytes); keine Gewichte oder Nutzdaten
|
||||
gelöscht. Keine Container-/Host-/Hermes-Neustarts, keine Mac-App-Patches.
|
||||
|
||||
Der API-Schlüssel wurde mit Michaels bestehender ausdrücklicher Freigabe intern
|
||||
verwendet, nicht dokumentiert. Keine privaten Prompts, Produktionsantworten,
|
||||
Zugangsdaten oder VPN-Daten in den Testdateien. Temporärer Worker nur auf Loopback.
|
||||
|
||||
Belege: [Zusammenfassung](results/summary.json), [Rohmessung](results/65536-measurement.json),
|
||||
[Controller](results/result.json), [unabhängige Wiederherstellung](results/verification.json),
|
||||
[Cachebereinigung und tatsächliche Engine-Verteilung](results/cleanup.json).
|
||||
Remote-Lauf: `context-runs/20261026T094237Z-2db842` unter dem dokumentierten Testordner.
|
||||
Dies ist kein neuer dauerhafter Dienst und keine vollständige native Restore-Abnahme.
|
||||
@@ -0,0 +1,106 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Measure one authorized, already loaded isolated native DeepSeek worker."""
|
||||
import argparse,json,os,time,urllib.request,threading,random
|
||||
from pathlib import Path
|
||||
|
||||
URL='http://127.0.0.1:19084'
|
||||
TOKEN='local-synthetic-context'
|
||||
|
||||
def api(path,body):
|
||||
req=urllib.request.Request(URL+path,data=json.dumps(body).encode(),headers={'Authorization':'Bearer '+TOKEN,'Content-Type':'application/json'})
|
||||
with urllib.request.urlopen(req,timeout=120) as r:return json.load(r)
|
||||
|
||||
def sample(root_pid):
|
||||
procs={}
|
||||
for p in Path('/proc').iterdir():
|
||||
if not p.name.isdigit():continue
|
||||
try:
|
||||
raw=(p/'stat').read_text();tail=raw[raw.rindex(')')+2:].split();procs[int(p.name)]=int(tail[1])
|
||||
except (OSError,ValueError,IndexError):pass
|
||||
ids={root_pid}
|
||||
for _ in range(10):
|
||||
new=ids|{pid for pid,ppid in procs.items() if ppid in ids}
|
||||
if new==ids:break
|
||||
ids=new
|
||||
totals=dict(rss_kib=0,pss_kib=0,private_kib=0,swap_pss_kib=0)
|
||||
for pid in ids:
|
||||
try:
|
||||
d={l.split(':')[0]:int(l.split()[1]) for l in Path(f'/proc/{pid}/smaps_rollup').read_text().splitlines()[1:] if ':' in l}
|
||||
totals['rss_kib']+=d.get('Rss',0);totals['pss_kib']+=d.get('Pss',0)
|
||||
totals['private_kib']+=sum(d.get(x,0) for x in ('Private_Clean','Private_Dirty','Private_Hugetlb'))
|
||||
totals['swap_pss_kib']+=d.get('SwapPss',0)
|
||||
except (OSError,ValueError):pass
|
||||
mem={l.split(':')[0]:int(l.split()[1]) for l in Path('/proc/meminfo').read_text().splitlines()}
|
||||
import subprocess
|
||||
raw=subprocess.check_output(['nvidia-smi','--query-gpu=index,memory.used,memory.total,utilization.gpu','--format=csv,noheader,nounits'],text=True)
|
||||
gpus=[dict(zip(('index','used_mib','total_mib','utilization_pct'),map(int,l.split(',')))) for l in raw.strip().splitlines()]
|
||||
return dict(at=time.time(),process_count=len(ids),**totals,host_available_kib=mem['MemAvailable'],host_swap_used_kib=mem['SwapTotal']-mem['SwapFree'],gpus=gpus)
|
||||
|
||||
def main():
|
||||
a=argparse.ArgumentParser();a.add_argument('--context',type=int,required=True);a.add_argument('--pid',type=int,required=True);a.add_argument('--output',type=Path,required=True);a.add_argument('--run',action='store_true');args=a.parse_args()
|
||||
if not args.run:return
|
||||
row=dict(context=args.context,started_at=time.time(),error=None)
|
||||
samples=[];stop=threading.Event();low=threading.Event();phase={'name':'preparing'}
|
||||
def monitor():
|
||||
bad=0
|
||||
while not stop.is_set():
|
||||
try:
|
||||
s=sample(args.pid);s['phase']=phase['name'];samples.append(s)
|
||||
progress=args.output.with_suffix('.progress.json');temp=progress.with_suffix('.tmp');temp.write_text(json.dumps(s));temp.replace(progress)
|
||||
bad=bad+1 if s['host_available_kib']<1536*1024 else 0
|
||||
if bad>=5:low.set()
|
||||
except Exception as e:row['sampling_error']=type(e).__name__
|
||||
stop.wait(2)
|
||||
t=threading.Thread(target=monitor,daemon=True);t.start()
|
||||
try:
|
||||
rng=random.Random(42)
|
||||
lines=[f'def item_{i:05d}(value): return (value * {rng.randrange(101,9999)} + {rng.randrange(10001,99999)}) % 1000003 # synthetic fixture {i:05d}' for i in range(10000)]
|
||||
def prompt(n):
|
||||
body=lines[:n].copy();body.insert(0,'# START_MARKER = ALPHA_314159');body.insert(n//2,'# MIDDLE_MARKER = BETA_271828');body.append('# END_MARKER = GAMMA_161803')
|
||||
return ('Dies ist ausschließlich ein synthetischer Quelltext für einen Leistungstest. Führe nichts aus.\n'+ '\n'.join(body)+
|
||||
'\nNenne zuerst die Werte von START_MARKER, MIDDLE_MARKER und END_MARKER. Schreibe danach mindestens 300 Wörter auf Deutsch darüber, wie man diesen Quelltext testen könnte. Keine Werkzeuge. Keine Rechnung über den gesamten Quelltext erforderlich.')
|
||||
target=args.context-1024
|
||||
lo,hi=1,len(lines)
|
||||
while lo<hi:
|
||||
n=(lo+hi+1)//2
|
||||
count=api('/v1/messages/count_tokens',dict(model='synthetic-context',messages=[dict(role='user',content=prompt(n))],thinking={'type':'disabled'},max_tokens=128))['input_tokens']
|
||||
if count<=target:lo=n
|
||||
else:hi=n-1
|
||||
text=prompt(lo)
|
||||
row['planned_input_tokens']=api('/v1/messages/count_tokens',dict(model='synthetic-context',messages=[dict(role='user',content=text)],thinking={'type':'disabled'},max_tokens=128))['input_tokens']
|
||||
row['source_lines']=lo
|
||||
if low.is_set():raise MemoryError('Host reserve below 1536MiB')
|
||||
row['memory_after_load']=sample(args.pid)
|
||||
print('Sending',row['planned_input_tokens'],'tokens at context',args.context,flush=True)
|
||||
req=urllib.request.Request(URL+'/v1/chat/completions',data=json.dumps(dict(model='synthetic-context',messages=[dict(role='user',content=text)],temperature=0,top_p=1,seed=42,reasoning_effort='none',max_tokens=128,stream=True,stream_options={'include_usage':True})).encode(),headers={'Authorization':'Bearer '+TOKEN,'Content-Type':'application/json'})
|
||||
phase['name']='prefill';start=time.monotonic();answer='';usage={};timings={};ttft=None;finish=None;done=False
|
||||
# SSE keepalives keep the read timeout bounded; parent separately watches
|
||||
# production requests and an overall four-hour deadline.
|
||||
with urllib.request.urlopen(req,timeout=180) as response:
|
||||
for line in response:
|
||||
if low.is_set():raise MemoryError('Host reserve below 1536MiB for ten seconds')
|
||||
if time.monotonic()-start>1200:raise TimeoutError('20-minute per-context bound')
|
||||
if not line.startswith(b'data:'):continue
|
||||
raw=line[5:].strip()
|
||||
if raw==b'[DONE]':done=True;break
|
||||
d=json.loads(raw)
|
||||
if 'error' in d:raise RuntimeError(str(d['error']))
|
||||
usage=d.get('usage') or usage;timings=d.get('timings') or d.get('backend_timings') or timings
|
||||
for c in d.get('choices',[]):
|
||||
finish=c.get('finish_reason') or finish
|
||||
content=c.get('delta',{}).get('content')
|
||||
if content:
|
||||
if ttft is None:ttft=time.monotonic()-start;phase['name']='decode'
|
||||
answer+=content
|
||||
if not done:raise RuntimeError('Incomplete SSE response')
|
||||
row.update(usage=usage,timings=timings,ttft_s=ttft,wall_s=time.monotonic()-start,finish=finish,answer=answer,
|
||||
marker_retrieval={m:m in answer for m in ('ALPHA_314159','BETA_271828','GAMMA_161803')})
|
||||
print('Finished',json.dumps(row['timings']),flush=True)
|
||||
except BaseException as exc:
|
||||
row['error']=type(exc).__name__+': '+str(exc)
|
||||
print(row['error'],flush=True)
|
||||
finally:
|
||||
stop.set();t.join(timeout=5);row['memory_samples']=samples;row['finished_at']=time.time()
|
||||
args.output.write_text(json.dumps(row,indent=2,ensure_ascii=False)+'\n')
|
||||
if row['error']:raise SystemExit(1)
|
||||
if __name__=='__main__':main()
|
||||
@@ -0,0 +1,142 @@
|
||||
{
|
||||
"started_at": 1793007598.4986923,
|
||||
"previous_profile": "flash-next-strata-iq3-dual",
|
||||
"arms": {
|
||||
"65536": {
|
||||
"context": 65536,
|
||||
"error": "worker exited during loading"
|
||||
}
|
||||
},
|
||||
"restored": true,
|
||||
"engine_version": "strata-dsv41 0.1.51 build 4b9e05a2a",
|
||||
"phase": "complete",
|
||||
"updated_at": 1793007665.978737,
|
||||
"settings_before": {
|
||||
"profiles.json": "e56a9cab15bed73d6bdd95dec0fe03c1eec636b8a3130e070e06b8b475210f3e",
|
||||
"endpoint.json": "1777010839b4cf905d1d52a76aaec55cc0d2e72fd8634a98dfecf1cc705f9d18",
|
||||
"audio-policy.json": "f48dedea718968c00c0647ca90c1402bdabac9ce600dbeddc495817680527a3f",
|
||||
"cpu-partition.json": "078d9215c41d7beafe42391a6a25c9aa34ad7f5b88ebbf40e2c178123e6611c1",
|
||||
"reasoning-budget.json": "4884a379adf2f888415041b81ef55a01a2c22ef7a41ca1554460f410bec5cf0c"
|
||||
},
|
||||
"endpoint_before": {
|
||||
"state": "running",
|
||||
"port": 8120,
|
||||
"counts": {
|
||||
"llm": {
|
||||
"enabled": 12,
|
||||
"available": 12,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"image": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"tts": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"stt": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"music": {
|
||||
"enabled": 2,
|
||||
"available": 2,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"voice": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
}
|
||||
},
|
||||
"active_requests": 0
|
||||
},
|
||||
"cpu_affinity": [
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
3,
|
||||
6,
|
||||
7,
|
||||
8,
|
||||
9
|
||||
],
|
||||
"protocol": {
|
||||
"contexts": [
|
||||
65536
|
||||
],
|
||||
"experts": 6,
|
||||
"target_input": "context minus 1024",
|
||||
"output_limit": 128,
|
||||
"temperature": 0,
|
||||
"top_p": 1,
|
||||
"seed": 42,
|
||||
"thinking": false,
|
||||
"repetitions": 1,
|
||||
"synthetic": "unique Python source lines with three retrieval markers",
|
||||
"reserve_min_available_mib": 1536
|
||||
},
|
||||
"restored_profile": "flash-next-strata-iq3-dual",
|
||||
"endpoint_after": {
|
||||
"state": "running",
|
||||
"port": 8120,
|
||||
"counts": {
|
||||
"llm": {
|
||||
"enabled": 12,
|
||||
"available": 12,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"image": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"tts": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"stt": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"music": {
|
||||
"enabled": 2,
|
||||
"available": 2,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"voice": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
}
|
||||
},
|
||||
"active_requests": 0
|
||||
},
|
||||
"settings_after": {
|
||||
"profiles.json": "e56a9cab15bed73d6bdd95dec0fe03c1eec636b8a3130e070e06b8b475210f3e",
|
||||
"endpoint.json": "1777010839b4cf905d1d52a76aaec55cc0d2e72fd8634a98dfecf1cc705f9d18",
|
||||
"audio-policy.json": "f48dedea718968c00c0647ca90c1402bdabac9ce600dbeddc495817680527a3f",
|
||||
"cpu-partition.json": "078d9215c41d7beafe42391a6a25c9aa34ad7f5b88ebbf40e2c178123e6611c1",
|
||||
"reasoning-budget.json": "4884a379adf2f888415041b81ef55a01a2c22ef7a41ca1554460f410bec5cf0c"
|
||||
},
|
||||
"settings_unchanged": true,
|
||||
"finished_at": 1793007665.9787335
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"pid": 3132045,
|
||||
"directory": "/data/athena-deck-strata/experiments/deepseek-026-64k-20261026/context-runs/20261026T093958Z-419770"
|
||||
}
|
||||
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"synthetic_slot_cache_removed_bytes": 70875652,
|
||||
"slot_cache_absent": true,
|
||||
"model_weights_deleted": false,
|
||||
"engine_layout": [
|
||||
"[strata] 2026-10-26 10:42:55 engine started: /opt/athena-deck-dev/runtime/state/strata-runtime/source/engine/strata-dsv41 --serve --pack /data/athena-deck-strata/experiments/deepseek-iq2-20261024/pack --max-context 65536 --eos 1 --dspark auto --dspark-conf 0.65 --tp 2 --experts 6 --layer-split auto",
|
||||
"ds4: tensor parallel 2 -> 1: the experts' 256-value blocks split n_ff 2304 no other way (each GPU its own layers)",
|
||||
"ds4: experts per word: 6 (full quality)",
|
||||
"ds4: RAM store: 55.6 GB of RAM free after the GPU's weights: store sized 38.2 GB, not 49.4",
|
||||
"ds4: RAM store: up to 3718 slots of 10.3 MB (38.2 GB), policy 0, 8 reader threads, unbuffered reads",
|
||||
"ds4: RAM store: 3462 of the profile's hottest experts read in (26.9 GB) in 8.0 s",
|
||||
"ds4: CUDA0 layers [0, 19]: weights 2.81 GB, experts 6.96 GB (824 of 7680 in VRAM), caches 0.04 GB, 588 MiB free",
|
||||
"ds4: CUDA1 layers [20, 39] + head: weights 3.05 GB, experts 10.84 GB (1187 of 7680 in VRAM), caches 0.03 GB, 582 MiB free"
|
||||
]
|
||||
}
|
||||
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,40 @@
|
||||
{
|
||||
"phase": "complete",
|
||||
"restored": true,
|
||||
"settings_unchanged": true,
|
||||
"error": null,
|
||||
"contexts": [
|
||||
{
|
||||
"context": 65536,
|
||||
"load_seconds": 26.202169738011435,
|
||||
"actual_reported_context": 65536,
|
||||
"error": null,
|
||||
"input_tokens": 64487,
|
||||
"output_tokens": 128,
|
||||
"input_tokens_per_s": 142.3,
|
||||
"output_tokens_per_s": 6.5,
|
||||
"prompt_ms": 453089.2,
|
||||
"decode_ms": 19550.6,
|
||||
"cache_tokens": 0,
|
||||
"ttft_s": 453.2414162409841,
|
||||
"wall_s": 472.7346749319695,
|
||||
"markers": {
|
||||
"ALPHA_314159": true,
|
||||
"BETA_271828": true,
|
||||
"GAMMA_161803": true
|
||||
},
|
||||
"samples": 227,
|
||||
"peak_pss_gib": 40.45610046386719,
|
||||
"peak_private_gib": 40.45106506347656,
|
||||
"peak_rss_gib": 40.470829010009766,
|
||||
"peak_swap_pss_gib": 0.0,
|
||||
"min_host_available_gib": 17.672542572021484,
|
||||
"host_swap_start_gib": 0.8652915954589844,
|
||||
"host_swap_peak_gib": 0.8657798767089844,
|
||||
"gpu_peak_mib": {
|
||||
"0": 11451,
|
||||
"1": 15426
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,79 @@
|
||||
{
|
||||
"previous_profile": "flash-next-strata-iq3-dual",
|
||||
"restored_profile": "flash-next-strata-iq3-dual",
|
||||
"controller_restored": true,
|
||||
"settings_unchanged": true,
|
||||
"worker_fields_unchanged": {
|
||||
"exe": true,
|
||||
"args": true,
|
||||
"cwd": true,
|
||||
"tokenizer": true,
|
||||
"model_name": true,
|
||||
"host": true,
|
||||
"gpu": true,
|
||||
"gpu_order": true,
|
||||
"layer_split": true,
|
||||
"vram_elastic": true,
|
||||
"open_browser": true,
|
||||
"log": true,
|
||||
"parallel": true,
|
||||
"reasoning_loop_recovery": true,
|
||||
"vision": true,
|
||||
"env": true
|
||||
},
|
||||
"health": {
|
||||
"status": "ok",
|
||||
"max_context": 262144,
|
||||
"model": "flash-next-strata-iq3-dual",
|
||||
"images": true,
|
||||
"api_key": true,
|
||||
"image_generation": false,
|
||||
"loaded": true,
|
||||
"service": "strata"
|
||||
},
|
||||
"endpoint": {
|
||||
"state": "running",
|
||||
"port": 8120,
|
||||
"counts": {
|
||||
"llm": {
|
||||
"enabled": 12,
|
||||
"available": 12,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"image": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"tts": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"stt": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"music": {
|
||||
"enabled": 2,
|
||||
"available": 2,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"voice": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
}
|
||||
},
|
||||
"active_requests": 0
|
||||
},
|
||||
"test_worker_pids": [],
|
||||
"verified": true
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"pid": 3132720,
|
||||
"directory": "/data/athena-deck-strata/experiments/deepseek-026-64k-20261026/context-runs/20261026T094237Z-2db842"
|
||||
}
|
||||
@@ -0,0 +1,286 @@
|
||||
#!/usr/bin/env python3
|
||||
"""One authorized pilot; owned workers only, production priority, finally restore."""
|
||||
import argparse
|
||||
import hashlib
|
||||
import json
|
||||
import os
|
||||
from pathlib import Path
|
||||
import secrets
|
||||
import signal
|
||||
import subprocess
|
||||
import sys
|
||||
import time
|
||||
import urllib.request
|
||||
import threading
|
||||
import random
|
||||
|
||||
BASE = Path(os.environ.get('DECK_TEST_BASE', '/data/athena-deck-strata/experiments/deepseek-026-64k-20261026'))
|
||||
STATE = Path(os.environ.get('DECK_TEST_STATE', '/opt/athena-deck-dev/runtime/state'))
|
||||
SOURCE = STATE / 'strata-runtime/source'
|
||||
ASSETS = Path('/data/athena-deck-strata/experiments/deepseek-iq2-20261024')
|
||||
PYTHON = ASSETS / 'venv/bin/python'
|
||||
SETTINGS = ('profiles.json', 'endpoint.json', 'audio-policy.json', 'cpu-partition.json', 'reasoning-budget.json')
|
||||
|
||||
|
||||
def hashes():
|
||||
return {n: hashlib.sha256((STATE / n).read_bytes()).hexdigest() for n in SETTINGS}
|
||||
|
||||
|
||||
def translate(obj):
|
||||
if isinstance(obj, str):
|
||||
return obj.replace('/var/lib/deck/', str(STATE) + '/')
|
||||
if isinstance(obj, list):
|
||||
return [translate(v) for v in obj]
|
||||
if isinstance(obj, dict):
|
||||
return {k: translate(v) for k, v in obj.items()}
|
||||
return obj
|
||||
|
||||
|
||||
def main(key, run):
|
||||
run.mkdir(parents=True, exist_ok=False)
|
||||
result = dict(started_at=time.time(), previous_profile=None, arms={}, restored=False)
|
||||
(BASE / 'active-context-run.txt').write_text(str(run) + '\n')
|
||||
deadline = time.monotonic() + 1800
|
||||
owned = None
|
||||
measurement = None
|
||||
original_stopped = False
|
||||
|
||||
def save(phase):
|
||||
result['phase'] = phase
|
||||
result['updated_at'] = time.time()
|
||||
temp = run / 'result.tmp'
|
||||
temp.write_text(json.dumps(result, indent=2) + '\n')
|
||||
temp.replace(run / 'result.json')
|
||||
print(phase, flush=True)
|
||||
|
||||
def api(path, body=None, timeout=15):
|
||||
req = urllib.request.Request('http://127.0.0.1:' + ('8120' if path.startswith('/v1/') else '8108') + path,
|
||||
data=json.dumps(body).encode() if body is not None else None,
|
||||
headers={'Authorization': 'Bearer ' + key, 'Content-Type': 'application/json'})
|
||||
with urllib.request.urlopen(req, timeout=timeout) as response:
|
||||
return json.load(response)
|
||||
|
||||
def idle():
|
||||
stop = time.monotonic() + 1800
|
||||
clean = 0
|
||||
while time.monotonic() < stop:
|
||||
if api('/api/v1/status')['endpoint']['active_requests'] == 0:
|
||||
clean += 1
|
||||
if clean >= 3:
|
||||
return
|
||||
else:
|
||||
clean = 0
|
||||
time.sleep(1)
|
||||
raise RuntimeError('No idle window; productive requests left untouched')
|
||||
|
||||
def abort_check():
|
||||
if (run / 'stop.request').exists() or time.monotonic() > deadline:
|
||||
raise RuntimeError('Own test stop requested or overall time limit')
|
||||
|
||||
def stop_owned():
|
||||
nonlocal owned, measurement
|
||||
if measurement and measurement.poll() is None:
|
||||
measurement.terminate()
|
||||
try:
|
||||
measurement.wait(timeout=8)
|
||||
except subprocess.TimeoutExpired:
|
||||
measurement.kill()
|
||||
measurement.wait()
|
||||
measurement = None
|
||||
if owned and owned.poll() is None:
|
||||
os.killpg(owned.pid, signal.SIGTERM)
|
||||
try:
|
||||
owned.wait(timeout=30)
|
||||
except subprocess.TimeoutExpired:
|
||||
os.killpg(owned.pid, signal.SIGKILL)
|
||||
owned.wait()
|
||||
owned = None
|
||||
|
||||
def production_priority_check():
|
||||
if api('/api/v1/status')['endpoint']['active_requests']:
|
||||
time.sleep(.5)
|
||||
if api('/api/v1/status')['endpoint']['active_requests']:
|
||||
raise RuntimeError('Productive request arrived; only owned synthetic worker is stopped')
|
||||
|
||||
def worker_get(port, token, path):
|
||||
req = urllib.request.Request('http://127.0.0.1:' + str(port) + path,
|
||||
headers={'Authorization': 'Bearer ' + token})
|
||||
with urllib.request.urlopen(req, timeout=3) as response:
|
||||
return json.load(response)
|
||||
|
||||
def on_signal(signum, frame):
|
||||
raise InterruptedError('Own comparison interrupted')
|
||||
|
||||
signal.signal(signal.SIGTERM, on_signal)
|
||||
signal.signal(signal.SIGINT, on_signal)
|
||||
try:
|
||||
import socket
|
||||
with socket.socket() as sock: sock.bind(('127.0.0.1',19084))
|
||||
version=subprocess.check_output([str(SOURCE/'engine/strata-dsv41'),'--version'],text=True,env=dict(os.environ,LD_LIBRARY_PATH=str(SOURCE.parent/'cuda/lib')+':'+str(SOURCE.parent/'cuda/lib64'))).strip()
|
||||
assert '0.1.51' in version
|
||||
result['engine_version']=version
|
||||
save('waiting_for_idle')
|
||||
idle()
|
||||
current = json.loads((STATE / 'strata-worker/worker.json').read_text())
|
||||
assert 'IQ3_XXS' in current['args'][current['args'].index('--native') + 1], 'Expected existing XXS production worker'
|
||||
result['previous_profile'] = current['model_name']
|
||||
result['settings_before'] = hashes()
|
||||
result['endpoint_before'] = api('/api/v1/status')['endpoint']
|
||||
clean = {k: v for k, v in current.items() if k not in ('api_key', 'key')}
|
||||
(run / 'qwen-template.json').write_text(json.dumps(clean, indent=2) + '\n')
|
||||
candidates = []
|
||||
accepted_paths = {b'/var/lib/deck/strata-worker/worker.json', str(STATE / 'strata-worker/worker.json').encode()}
|
||||
for p in Path('/proc').iterdir():
|
||||
if not p.name.isdigit():
|
||||
continue
|
||||
try:
|
||||
args = (p / 'cmdline').read_bytes().split(b'\0')
|
||||
if accepted_paths.intersection(args) and any(a.endswith(b'/serve/server.py') for a in args):
|
||||
candidates.append(int(p.name))
|
||||
except OSError:
|
||||
pass
|
||||
if len(candidates) != 1:
|
||||
raise RuntimeError('Original worker identity is not unique')
|
||||
pid = candidates[0]
|
||||
if os.getpgid(pid) != pid:
|
||||
raise RuntimeError('Original worker has unexpected process-group ownership')
|
||||
# The exact server PID supplies its network namespace for either a
|
||||
# native service or today's container transport; no Docker dependency.
|
||||
check = "import json,sys,urllib.request;x=json.load(sys.stdin);r=urllib.request.Request('http://127.0.0.1:'+str(x['port'])+'/v1/status',headers={'Authorization':'Bearer '+x['api_key']});d=json.load(urllib.request.urlopen(r,timeout=5));print(json.dumps(d.get('activity',{}).get('in_flight')))"
|
||||
for _ in range(600):
|
||||
idle()
|
||||
active = json.loads(subprocess.check_output(['nsenter', '-t', str(pid), '-n', 'python3', '-c', check], input=json.dumps(current), text=True))
|
||||
if active == 0:
|
||||
break
|
||||
time.sleep(2)
|
||||
else:
|
||||
raise RuntimeError('Original worker is not idle')
|
||||
idle()
|
||||
save('unloading_idle_qwen')
|
||||
os.killpg(pid, signal.SIGTERM)
|
||||
original_stopped = True
|
||||
for _ in range(60):
|
||||
# Normal status polling lets Deck reap its completed Popen child.
|
||||
api('/api/v1/status')
|
||||
if not Path('/proc/' + str(pid)).exists():
|
||||
break
|
||||
time.sleep(1)
|
||||
else:
|
||||
raise RuntimeError('Original worker did not stop; no forced production kill')
|
||||
|
||||
cpus = json.loads((STATE / 'cpu-partition.json').read_text())['strata']
|
||||
result['cpu_affinity'] = cpus
|
||||
result['protocol'] = dict(contexts=[65536], experts=6, target_input='context minus 1024', output_limit=128,
|
||||
temperature=0, top_p=1, seed=42, thinking=False, repetitions=1,
|
||||
synthetic='unique Python source lines with three retrieval markers', reserve_min_available_mib=1536)
|
||||
for context in (65536,):
|
||||
arm = str(context)
|
||||
abort_check()
|
||||
idle()
|
||||
cfg = json.loads((ASSETS / 'test-config.json').read_text())
|
||||
cfg['args'][cfg['args'].index('--max-context') + 1] = str(context)
|
||||
assert '--experts' not in cfg['args']
|
||||
cfg['args'] += ['--experts','6']
|
||||
cfg['exe']=str(SOURCE/'engine/strata-dsv41')
|
||||
cfg['cwd']=str(SOURCE)
|
||||
cfg['lib_dirs']=[str(SOURCE/'engine'),str(SOURCE.parent/'cuda/lib'),str(SOURCE.parent/'cuda/lib64')]
|
||||
cfg.update(host='127.0.0.1', port=19084, api_key='local-synthetic-context',
|
||||
open_browser=False, log=str(run / (arm + '-engine.log')))
|
||||
cfg_path = run / (arm + '-config.json')
|
||||
cfg_path.write_text(json.dumps(cfg, indent=2) + '\n')
|
||||
source = SOURCE
|
||||
env = dict(os.environ, **cfg.get('env', {}), CUDA_VISIBLE_DEVICES='0,1', PYTHONUNBUFFERED='1')
|
||||
env['LD_LIBRARY_PATH'] = ':'.join(cfg.get('lib_dirs', []) + [env.get('LD_LIBRARY_PATH', '')])
|
||||
cmd = ['taskset', '-c', ','.join(map(str, cpus)), str(PYTHON), str(source / 'serve/server.py'),
|
||||
'--engine', 'strata', '--config', str(cfg_path), '--host', '127.0.0.1', '--port', '19084', '--fit-max-tokens']
|
||||
row = dict(context=context)
|
||||
result['arms'][arm] = row
|
||||
save('loading_' + arm)
|
||||
started = time.monotonic()
|
||||
with (run / (arm + '-server.log')).open('w') as log:
|
||||
owned = subprocess.Popen(cmd, env=env, cwd=source, stdout=log, stderr=subprocess.STDOUT, start_new_session=True)
|
||||
ready_deadline = time.monotonic() + 600
|
||||
while time.monotonic() < ready_deadline:
|
||||
abort_check()
|
||||
production_priority_check()
|
||||
mem={l.split(':')[0]:int(l.split()[1]) for l in Path('/proc/meminfo').read_text().splitlines()}
|
||||
if mem['MemAvailable']<1536*1024:raise MemoryError('Host reserve below 1536MiB while loading')
|
||||
if owned.poll() is not None:
|
||||
row['error']='worker exited during loading'
|
||||
break
|
||||
try:
|
||||
health = worker_get(19084, cfg['api_key'], '/health')
|
||||
if health.get('status') == 'ok' and health.get('loaded', True):
|
||||
row.update(load_seconds=time.monotonic()-started, health=health, worker_status=worker_get(19084, cfg['api_key'], '/v1/status'))
|
||||
break
|
||||
except OSError:
|
||||
pass
|
||||
time.sleep(2)
|
||||
else:
|
||||
row['error']='loading timeout'
|
||||
if row.get('error'):
|
||||
stop_owned()
|
||||
save('unavailable_' + arm)
|
||||
continue
|
||||
save('measuring_' + arm)
|
||||
args = [str(PYTHON), str(BASE / 'context_measure.py'), '--context', arm,
|
||||
'--pid', str(owned.pid), '--output', str(run / (arm + '-measurement.json')), '--run']
|
||||
with (run / (arm + '-measure.log')).open('w') as log:
|
||||
measurement = subprocess.Popen(args, env=env, cwd=BASE, stdout=log, stderr=subprocess.STDOUT)
|
||||
while measurement.poll() is None:
|
||||
abort_check()
|
||||
production_priority_check()
|
||||
if owned.poll() is not None:
|
||||
raise RuntimeError('worker failed during context measurement')
|
||||
time.sleep(1)
|
||||
out = run / (arm + '-measurement.json')
|
||||
if out.exists():
|
||||
row['measurement']=json.loads(out.read_text())
|
||||
if measurement.returncode:
|
||||
row['error']='measurement harness failed; inspect synthetic log'
|
||||
stop_owned()
|
||||
save('finished_' + arm)
|
||||
except BaseException as exc:
|
||||
result['error'] = type(exc).__name__ + ': ' + str(exc)
|
||||
print(result['error'], flush=True)
|
||||
finally:
|
||||
stop_owned()
|
||||
if original_stopped:
|
||||
save('restoring_qwen')
|
||||
try:
|
||||
idle()
|
||||
body = dict(model=result['previous_profile'], messages=[dict(role='user', content='Antworte mit OK.')],
|
||||
max_tokens=1, temperature=0, reasoning_effort='none')
|
||||
answer = api('/v1/chat/completions', body, timeout=900)
|
||||
restored = json.loads((STATE / 'strata-worker/worker.json').read_text())
|
||||
result['restored'] = bool(answer.get('choices')) and restored['model_name'] == result['previous_profile']
|
||||
result['restored_profile'] = restored['model_name']
|
||||
result['endpoint_after'] = api('/api/v1/status')['endpoint']
|
||||
except Exception as exc:
|
||||
result['restore_error'] = type(exc).__name__ + ': ' + str(exc)
|
||||
result['settings_after'] = hashes()
|
||||
result['settings_unchanged'] = result.get('settings_before') == result['settings_after']
|
||||
result['finished_at'] = time.time()
|
||||
save('complete' if result['restored'] and 'error' not in result and not any(a.get('error') for a in result['arms'].values()) else 'finished_with_error')
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
ap = argparse.ArgumentParser(description=__doc__)
|
||||
ap.add_argument('--detach', action='store_true')
|
||||
a = ap.parse_args()
|
||||
key = json.load(sys.stdin)['key']
|
||||
run = BASE / 'context-runs' / (time.strftime('%Y%m%dT%H%M%SZ', time.gmtime()) + '-' + secrets.token_hex(3))
|
||||
if a.detach:
|
||||
pid = os.fork()
|
||||
if pid:
|
||||
print(json.dumps(dict(pid=pid, directory=str(run))))
|
||||
sys.exit(0)
|
||||
os.setsid()
|
||||
fd = os.open(str(BASE / 'context-controller.log'), os.O_WRONLY | os.O_CREAT | os.O_APPEND, 0o600)
|
||||
os.dup2(fd, 1)
|
||||
os.dup2(fd, 2)
|
||||
os.close(fd)
|
||||
fd = os.open('/dev/null', os.O_RDONLY)
|
||||
os.dup2(fd, 0)
|
||||
os.close(fd)
|
||||
main(key, run)
|
||||
@@ -0,0 +1,16 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Summarize recorded context-test counters, preserving missing/failed measurements."""
|
||||
import json,sys
|
||||
from pathlib import Path
|
||||
r=Path(sys.argv[1]);d=json.loads((r/'result.json').read_text());out=dict(phase=d['phase'],restored=d.get('restored'),settings_unchanged=d.get('settings_unchanged'),error=d.get('error'),contexts=[])
|
||||
for context,arm in d['arms'].items():
|
||||
p=r/(context+'-measurement.json');m=json.loads(p.read_text()) if p.exists() else arm.get('measurement',{})
|
||||
s=m.get('memory_samples',[]);t=m.get('timings',{});u=m.get('usage',{})
|
||||
x=dict(context=int(context),load_seconds=arm.get('load_seconds'),actual_reported_context=arm.get('health',{}).get('max_context'),error=m.get('error') or arm.get('error'),input_tokens=u.get('prompt_tokens'),output_tokens=u.get('completion_tokens'),input_tokens_per_s=t.get('prompt_per_second'),output_tokens_per_s=t.get('predicted_per_second'),prompt_ms=t.get('prompt_ms'),decode_ms=t.get('predicted_ms'),cache_tokens=t.get('cache_n'),ttft_s=m.get('ttft_s'),wall_s=m.get('wall_s'),markers=m.get('marker_retrieval'))
|
||||
if s:
|
||||
x.update(samples=len(s),peak_pss_gib=max(v['pss_kib'] for v in s)/1024**2,peak_private_gib=max(v['private_kib'] for v in s)/1024**2,peak_rss_gib=max(v['rss_kib'] for v in s)/1024**2,peak_swap_pss_gib=max(v['swap_pss_kib'] for v in s)/1024**2,min_host_available_gib=min(v['host_available_kib'] for v in s)/1024**2,host_swap_start_gib=s[0]['host_swap_used_kib']/1024**2,host_swap_peak_gib=max(v['host_swap_used_kib'] for v in s)/1024**2,gpu_peak_mib={str(g['index']):max(z['used_mib'] for v in s for z in v['gpus'] if z['index']==g['index']) for g in s[0]['gpus']})
|
||||
if x.get('peak_pss_gib') == 0:
|
||||
for key in ('peak_pss_gib','peak_private_gib','peak_rss_gib','peak_swap_pss_gib'):x[key]=None
|
||||
x['process_memory_note']='Unavailable: initial sampler skipped smaps header; host available RAM and GPU counters are valid.'
|
||||
out['contexts'].append(x)
|
||||
print(json.dumps(out,indent=2))
|
||||
@@ -0,0 +1,31 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Verify restored production worker without printing credentials or user content."""
|
||||
import hashlib,json,os,subprocess,sys,urllib.request
|
||||
from pathlib import Path
|
||||
BASE=Path(os.environ.get('DECK_TEST_BASE','/data/athena-deck-strata/experiments/deepseek-026-64k-20261026'))
|
||||
STATE=Path(os.environ.get('DECK_TEST_STATE','/opt/athena-deck-dev/runtime/state'))
|
||||
r=Path((BASE/'active-context-run.txt').read_text().strip());d=json.loads((r/'result.json').read_text())
|
||||
if d['phase'] not in ('complete','finished_with_error'):raise SystemExit('Test still running; do not verify prematurely')
|
||||
key=json.load(sys.stdin)['key']
|
||||
req=urllib.request.Request('http://127.0.0.1:8108/api/v1/status',headers={'Authorization':'Bearer '+key})
|
||||
endpoint=json.load(urllib.request.urlopen(req,timeout=10))['endpoint']
|
||||
worker=json.loads((STATE/'strata-worker/worker.json').read_text());before=json.loads((r/'qwen-template.json').read_text())
|
||||
fields=('exe','args','cwd','tokenizer','model_name','host','gpu','gpu_order','layer_split','vram_elastic','open_browser','log','parallel','reasoning_loop_recovery','vision','env')
|
||||
comparison={k:before.get(k)==worker.get(k) for k in fields}
|
||||
pids=[];leftovers=[]
|
||||
for p in Path('/proc').iterdir():
|
||||
if not p.name.isdigit():continue
|
||||
try:args=(p/'cmdline').read_bytes().split(b'\0')
|
||||
except OSError:continue
|
||||
if any(a.endswith(b'/serve/server.py') for a in args):
|
||||
if any(a in (b'/var/lib/deck/strata-worker/worker.json',str(STATE/'strata-worker/worker.json').encode()) for a in args):pids.append(int(p.name))
|
||||
if any(str(r).encode() in a for a in args):leftovers.append(int(p.name))
|
||||
if any(a.endswith(b'/strata-dsv41') for a in args):leftovers.append(int(p.name))
|
||||
assert len(pids)==1,'Restored worker identity not unique'
|
||||
probe="import json,sys,urllib.request;x=json.load(sys.stdin);r=urllib.request.Request('http://127.0.0.1:'+str(x['port'])+'/health',headers={'Authorization':'Bearer '+x['api_key']});print(json.dumps(json.load(urllib.request.urlopen(r,timeout=5))))"
|
||||
health=json.loads(subprocess.check_output(['nsenter','-t',str(pids[0]),'-n','python3','-c',probe],input=json.dumps(worker),text=True))
|
||||
settings={n:hashlib.sha256((STATE/n).read_bytes()).hexdigest() for n in d['settings_before']}
|
||||
out=dict(previous_profile=d['previous_profile'],restored_profile=worker['model_name'],controller_restored=d.get('restored'),settings_unchanged=settings==d['settings_before'],worker_fields_unchanged=comparison,health=health,endpoint=endpoint,test_worker_pids=leftovers)
|
||||
out['verified']=bool(out['controller_restored'] and out['settings_unchanged'] and all(comparison.values()) and health.get('status')=='ok' and health.get('loaded') and endpoint['counts']['llm']['loaded'] and endpoint['counts']['tts']['loaded'] and endpoint['counts']['stt']['loaded'] and not leftovers)
|
||||
(r/'verification.json').write_text(json.dumps(out,indent=2)+'\n');print(json.dumps(out,indent=2))
|
||||
if not out['verified']:raise SystemExit(1)
|
||||
@@ -0,0 +1,57 @@
|
||||
# DeepSeek IQ2_XXS context test · 24 October 2026
|
||||
|
||||
**Completed:** all three contexts succeeded; Qwen restored and independently verified.
|
||||
[Measured results and limitations](RESULTS.md).
|
||||
|
||||
Michael authorized 32K, 64K, and if feasible128K context, memory and input/output
|
||||
throughput measurement, waiting for productive work, then restoring Qwen.
|
||||
|
||||
Uses the previously pinned native DeepSeek0.1.49.2 runtime and verified IQ2_XXS
|
||||
pack from `../deepseek-iq2-2026-10-24/README.md`; no runtime/profile/weight change.
|
||||
Only `--max-context` varies:32768,65536,131072. Same both GPUs, affinity and
|
||||
upstream automatic RAM store. These are experimental contexts above upstream's
|
||||
qualified8192default, not an assertion of full long-context quality support.
|
||||
|
||||
Protocol fixed before measurements: one fresh native loopback-only worker per
|
||||
context; deterministic unique synthetic Python lines, prompt count via official
|
||||
`/v1/messages/count_tokens`, largest whole-line input at most(context-1024).
|
||||
Actual OpenAI usage is authoritative if template accounting differs. Output128,
|
||||
no thinking, temperature0/top_p1/seed42. Three markers at start/middle/end give
|
||||
a minimal retrieval check, not a coding/long-context intelligence benchmark.
|
||||
One measured inference per size, no cache reuse deliberately introduced, no
|
||||
filesystem cache flush. Use backend prompt/predicted counters for rates, never
|
||||
walltime as decode speed. Record load, TTFT and wall separately.
|
||||
|
||||
Memory: every2seconds collect own server+recursive descendant RSS/PSS/private
|
||||
and SwapPss, host MemAvailable/swap, and per-GPU total allocated memory. RSS can
|
||||
double-count shared pages; PSS includes resident mapped model files and is not
|
||||
all anonymous RAM. GPU figures include any unrelated GPU allocations. Preserve
|
||||
TTS/STT; own test stops if host available reserve<1536MiB for5samples. Request
|
||||
bound90minutes, total4hours. No claim of physical SSD read measurement.
|
||||
|
||||
Safety follows pilot controller: three idle endpoint checks and direct idle
|
||||
originalworker check, SIGTERM only its uniquely identified idle processgroup,
|
||||
no forced productive kill; new production work stops only own syntheticworker;
|
||||
finally restore exact prior Qwen APIprofile via ordinary authenticated endpoint.
|
||||
Compare settings hashes and workerconfig, verify normal health and loaded TTS/STT.
|
||||
No host/container/Hermes/Mac changes or new services. Config snapshots omit keys.
|
||||
|
||||
Native reproduction: existing tested runtime/dependencies and ports as described
|
||||
by the pilot, explicit DECK_TEST_BASE/DECK_TEST_STATE if paths differ. Copy
|
||||
`run_context.py` and `context_measure.py` beside prepared test-config.json; pass
|
||||
existing authorized Athena API credential JSON on stdin to `venv/bin/python
|
||||
run_context.py --detach`. Credentials remain process memory and are not logged.
|
||||
Inspect active-context-run.txt and context-controller.log; result.json is atomic.
|
||||
Do not start while another experiment owns port19084. The downloaded model pack
|
||||
is public and reproducible from the pilot's pinned manifest; no secrets in Git.
|
||||
|
||||
## Measurement caveat found during execution
|
||||
|
||||
The initial process-PSS sampler incorrectly treated the smaps_rollup address
|
||||
header as a numeric field and skipped the process totals. Thus process
|
||||
RSS/PSS/private/SwapPss are **unavailable, not zero**, for the32K and64K runs.
|
||||
Host MemAvailable, host swap, per-GPU memory and inference counters are valid
|
||||
in all runs. The parser was corrected and checked on its own process before
|
||||
128K measurement; only that run has usable process-specific PSS. This changed
|
||||
telemetry only, not model/runtime/sampling. Summary maps invalid zeros to null;
|
||||
no repeated inference was needed for the valid host-reserve/VRAM measurement.
|
||||
@@ -0,0 +1,116 @@
|
||||
# DeepSeek IQ2_XXS: 32K, 64K und 128K auf Athena
|
||||
|
||||
24. Oktober 2026. **Alle drei fast vollständig belegten Kontextfenster wurden
|
||||
verarbeitet. Qwen ist anschließend mit unveränderten Einstellungen wieder
|
||||
betriebsbereit.** 8K war die frühere Testgröße, keine nachgewiesene Hardwaregrenze.
|
||||
|
||||
## Gemessene Leistung
|
||||
|
||||
| Kontext | Tatsächliche Eingabe | Eingabe Token/s | Ausgabe Token/s | Erste Antwort | Ganze Anfrage |
|
||||
|---|---:|---:|---:|---:|---:|
|
||||
| 32.768 | 31.738 | 177,5 | 5,8 | 178,89 s | 200,98 s |
|
||||
| 65.536 | 64.487 | 195,2 | 5,6 | 330,48 s | 353,39 s |
|
||||
| 131.072 | 130.023 | 203,4 | 5,7 | 639,37 s | 662,01 s |
|
||||
|
||||
Je128 Ausgabetokens, Denken aus, Temperatur0/top_p1/seed42. Keine KV-Cachetreffer
|
||||
(cache_n=0). Input-/Outputraten stammen getrennt aus den jeweiligen Backendzeiten,
|
||||
nicht aus Gesamtwallzeit. Ausgabe endet absichtlich am128-Token-Limit.
|
||||
Modellladen (28,59/28,38/28,48s) ist in den Anfragezeiten nicht enthalten.
|
||||
Gesamter kontrollierter Ablauf inklusive Laden, Stoppen und Wiederherstellung:
|
||||
23.24 Minuten.
|
||||
|
||||
Drei eindeutige Suchmarken am Anfang, in der Mitte und am Ende des synthetischen
|
||||
Quelltextes wurden in **allen drei Antworten korrekt wiedergegeben**. Die Engine
|
||||
meldete jeweils die volle angeforderte Kontextgröße; tatsächliche Usage und
|
||||
vollständige Antwort bestätigen mehr als einen reinen Starttest.
|
||||
Dies ist dennoch **kein Nachweis umfassender Coding- oder Langkontextqualität**.
|
||||
|
||||
## Speicherbedarf
|
||||
|
||||
Abtastung etwa alle2s, einschließlich Einlese- und Ausgabephase. RAM-Reserve ist
|
||||
Linux MemAvailable des **gesamten Hosts**, kein ausschließliches Modellmaß.
|
||||
GPU-Belegung ist die gesamte gemessene Belegung der jeweiligen Karte.
|
||||
|
||||
| Kontext | Verfügbarer Host-RAM, Minimum | RTX3060, Peak | RTX5080, Peak |
|
||||
|---|---:|---:|---:|
|
||||
| 32K | 8,14 GiB | 11.465 MiB | 15.416 MiB |
|
||||
| 64K | 8,27 GiB | 11.461 MiB | 15.418 MiB |
|
||||
| 128K | 8,20 GiB | 11.467 MiB | 15.420 MiB |
|
||||
|
||||
Bei128K betrug der gemessene Spitzenwert für Server plus rekursive
|
||||
Engine-Nachkommen **49,51GiB PSS** (RSS49,53GiB; private Seiten49,51GiB).
|
||||
PSS enthält residente Dateimappings und ist nicht gleichbedeutend mit reinem
|
||||
anonymen Speicher. Prozess-SwapPss im128K-Lauf:0; Host-Swap war bereits vor den
|
||||
Tests belegt und stieg dort nur von0,896 auf0,902GiB. Keine Speicherschutz-
|
||||
Abschaltung oder Workerfehler in den drei Läufen.
|
||||
|
||||
**Messlücke:** Der anfängliche Prozessspeicher-Parser verarbeitete die
|
||||
smaps_rollup-Kopfzeile falsch. Prozess-RSS/PSS/private/SwapPss sind deshalb für
|
||||
32K und64K unbekannt; die Rohnullen sind **keine gültigen Nullmessungen**.
|
||||
Host-RAM-Reserve, Host-Swap, GPU-Speicher und Inferenzzähler sind für alle drei
|
||||
Läufe gültig. Der Parser wurde vor128K korrigiert und separat am eigenen
|
||||
Prozess geprüft. summary.json setzt die ungültigen Werte auf null.
|
||||
|
||||
## Bedingungen und Grenzen
|
||||
|
||||
- Gleicher vorbereiteter DeepSeek-V4.1-Flash-1017 GSQ-RCO IQ2_XXS-Stand,
|
||||
native offizielle Engine0.1.49.2/CUDA13 aus der vorherigen Vorbereitung.
|
||||
Keine neuen Gewichte, Runtime-Updates, Treiber- oder Produktionsprofiländerungen.
|
||||
- Ryzen5 5600, rund62,7GiB Host-RAM, RTX3060 plus RTX5080. Vorhandene CPU-Maske
|
||||
0,1,2,3,6,7,8,9; automatische RAM-Store-/Expertenverteilung unverändert.
|
||||
- TP2 wird für diese Gewichte weiterhin automatisch zu TP1/Schichtaufteilung
|
||||
zurückgenommen. Beide GPUs werden verwendet; DSpark bleibt wie zuvor automatisch
|
||||
ungeladen. Ein sequenzieller Testrequest, keine parallelen Nutzer/Subagenten.
|
||||
- Drei frische Worker, Reihenfolge32K→64K→128K, je eine deterministische Anfrage.
|
||||
Größere Fenster enthalten längere Präfixe derselben synthetischen Quelltextart.
|
||||
Keine physischen Cache-Flushes, keine Wiederholungen, keine statistisch belastbare
|
||||
Geschwindigkeitsrangfolge der Kontextgrößen. KV-Cachefrei heißt nicht SSD-kalt.
|
||||
- Kein tatsächliches Repository, keine echten Tools und keine Produktionsdaten
|
||||
in den Prompts. Code wurde nicht ausgeführt. Die Suchmarken sind lediglich ein
|
||||
kleiner Retrieval-Plausibilitätstest.
|
||||
- Die früheren16,6Token/s waren eine kurze wiederholte Anfrage. Hier sind es rund
|
||||
5,6–5,8Token/s nach großer uncached Eingabe; unterschiedliche Aufgaben und
|
||||
Cachezustände erlauben keine ausschließlich dem Kontext zugeschriebene Ursache.
|
||||
- Kein Test mit anschließenden gecachten Coding-Turns. Aus den Einlesezeiten folgt
|
||||
**nicht**, dass jede spätere Nachricht wieder den gesamten Kontext neu einlesen
|
||||
muss. Tatsächliches Agenten-Cacheverhalten ist damit noch nicht gemessen.
|
||||
|
||||
## Wiederherstellung und Sicherheit
|
||||
|
||||
Vor dem Wechsel dreimal Endpunkt-Leerlauf sowie den eindeutig identifizierten
|
||||
Produktionsworker direkt auf in_flight=0 geprüft. Nur dessen inaktive Gruppe
|
||||
regulär beendet, keine produktive Anfrage abgebrochen. Testcontroller überwachte
|
||||
neu eintreffende Produktionsanfragen und hätte nur eigene Testworker gestoppt.
|
||||
|
||||
Anschließend Qwen regulär über den authentifizierten Athena-Endpunkt wieder
|
||||
angefordert und unabhängig geprüft:
|
||||
|
||||
- Profil **flash-next-strata-iq3-dual**, Kontext262.144, Vision wieder aktiv,
|
||||
direkter Worker-Health status=ok und loaded=true.
|
||||
- Profile, Endpunkt, Audiopolitik und CPU-Aufteilung haben exakt dieselben
|
||||
SHA256-Werte wie vorher. Alle16 verglichenen Workerfelder einschließlich
|
||||
Enginepfad, Argumenten, GPU-Reihenfolge, Schichtsplit, Parallelität, Vision und
|
||||
Umgebung stimmen überein. Ephemere Ports/Zugangstokens sind davon ausgenommen.
|
||||
- Endpunkt läuft, Qwen/TTS/STT geladen, zum Prüfzeitpunkt0 aktive Anfragen.
|
||||
- Keine DeepSeek-/Testworker zurückgelassen, keine Gewichte gelöscht,
|
||||
keine Mac-, Hermes-, Host- oder Container-Neustarts.
|
||||
|
||||
Belege: [summary.json](results/summary.json), [verification.json](results/verification.json),
|
||||
[result.json](results/result.json) sowie die drei*-measurement.json-Dateien mit
|
||||
synthetischen Antworten und Speicherzeitreihen. Es wurden keine privaten
|
||||
Prompts, Schlüssel oder Produktionslogs in diesen Dokumentationsordner kopiert.
|
||||
|
||||
## Einordnung
|
||||
|
||||
**128K ist auf dieser Athena-Konfiguration technisch möglich.** Die Speichergröße
|
||||
ist für einen nächsten echten Coding-Vergleich nicht mehr der bisher vermutete
|
||||
8K-Hinderungsgrund. Die erstmalige Aufnahme von knapp130K Tokens dauert etwa
|
||||
10min39s; danach wurden in dieser Aufgabe5,7Token/s erreicht. Ob DeepSeek den
|
||||
Zeitaufwand durch bessere Lösungen rechtfertigt, muss eine schwierigere,
|
||||
überprüfbare Coding-Aufgabe zeigen. Dieser Kapazitätstest beantwortet das nicht.
|
||||
|
||||
Reproduktion und Schutzmechanismen: [README.md](README.md), run_context.py,
|
||||
context_measure.py, summarize.py, verify_restore.py. Remote-Lauf:
|
||||
`/data/athena-deck-strata/experiments/deepseek-iq2-20261024/context-runs/20261024T152532Z-34a9f5`.
|
||||
Keine automatischen Folgetests, kein neuer Dienst und kein Produktionsprofil
|
||||
für DeepSeek angelegt. Änderungen sind lokal dokumentiert; kein Git-Push erfolgt.
|
||||
@@ -0,0 +1,106 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Measure one authorized, already loaded isolated native DeepSeek worker."""
|
||||
import argparse,json,os,time,urllib.request,threading,random
|
||||
from pathlib import Path
|
||||
|
||||
URL='http://127.0.0.1:19084'
|
||||
TOKEN='local-synthetic-context'
|
||||
|
||||
def api(path,body):
|
||||
req=urllib.request.Request(URL+path,data=json.dumps(body).encode(),headers={'Authorization':'Bearer '+TOKEN,'Content-Type':'application/json'})
|
||||
with urllib.request.urlopen(req,timeout=120) as r:return json.load(r)
|
||||
|
||||
def sample(root_pid):
|
||||
procs={}
|
||||
for p in Path('/proc').iterdir():
|
||||
if not p.name.isdigit():continue
|
||||
try:
|
||||
raw=(p/'stat').read_text();tail=raw[raw.rindex(')')+2:].split();procs[int(p.name)]=int(tail[1])
|
||||
except (OSError,ValueError,IndexError):pass
|
||||
ids={root_pid}
|
||||
for _ in range(10):
|
||||
new=ids|{pid for pid,ppid in procs.items() if ppid in ids}
|
||||
if new==ids:break
|
||||
ids=new
|
||||
totals=dict(rss_kib=0,pss_kib=0,private_kib=0,swap_pss_kib=0)
|
||||
for pid in ids:
|
||||
try:
|
||||
d={l.split(':')[0]:int(l.split()[1]) for l in Path(f'/proc/{pid}/smaps_rollup').read_text().splitlines()[1:] if ':' in l}
|
||||
totals['rss_kib']+=d.get('Rss',0);totals['pss_kib']+=d.get('Pss',0)
|
||||
totals['private_kib']+=sum(d.get(x,0) for x in ('Private_Clean','Private_Dirty','Private_Hugetlb'))
|
||||
totals['swap_pss_kib']+=d.get('SwapPss',0)
|
||||
except (OSError,ValueError):pass
|
||||
mem={l.split(':')[0]:int(l.split()[1]) for l in Path('/proc/meminfo').read_text().splitlines()}
|
||||
import subprocess
|
||||
raw=subprocess.check_output(['nvidia-smi','--query-gpu=index,memory.used,memory.total,utilization.gpu','--format=csv,noheader,nounits'],text=True)
|
||||
gpus=[dict(zip(('index','used_mib','total_mib','utilization_pct'),map(int,l.split(',')))) for l in raw.strip().splitlines()]
|
||||
return dict(at=time.time(),process_count=len(ids),**totals,host_available_kib=mem['MemAvailable'],host_swap_used_kib=mem['SwapTotal']-mem['SwapFree'],gpus=gpus)
|
||||
|
||||
def main():
|
||||
a=argparse.ArgumentParser();a.add_argument('--context',type=int,required=True);a.add_argument('--pid',type=int,required=True);a.add_argument('--output',type=Path,required=True);a.add_argument('--run',action='store_true');args=a.parse_args()
|
||||
if not args.run:return
|
||||
row=dict(context=args.context,started_at=time.time(),error=None)
|
||||
samples=[];stop=threading.Event();low=threading.Event();phase={'name':'preparing'}
|
||||
def monitor():
|
||||
bad=0
|
||||
while not stop.is_set():
|
||||
try:
|
||||
s=sample(args.pid);s['phase']=phase['name'];samples.append(s)
|
||||
progress=args.output.with_suffix('.progress.json');temp=progress.with_suffix('.tmp');temp.write_text(json.dumps(s));temp.replace(progress)
|
||||
bad=bad+1 if s['host_available_kib']<1536*1024 else 0
|
||||
if bad>=5:low.set()
|
||||
except Exception as e:row['sampling_error']=type(e).__name__
|
||||
stop.wait(2)
|
||||
t=threading.Thread(target=monitor,daemon=True);t.start()
|
||||
try:
|
||||
rng=random.Random(42)
|
||||
lines=[f'def item_{i:05d}(value): return (value * {rng.randrange(101,9999)} + {rng.randrange(10001,99999)}) % 1000003 # synthetic fixture {i:05d}' for i in range(10000)]
|
||||
def prompt(n):
|
||||
body=lines[:n].copy();body.insert(0,'# START_MARKER = ALPHA_314159');body.insert(n//2,'# MIDDLE_MARKER = BETA_271828');body.append('# END_MARKER = GAMMA_161803')
|
||||
return ('Dies ist ausschließlich ein synthetischer Quelltext für einen Leistungstest. Führe nichts aus.\n'+ '\n'.join(body)+
|
||||
'\nNenne zuerst die Werte von START_MARKER, MIDDLE_MARKER und END_MARKER. Schreibe danach mindestens 300 Wörter auf Deutsch darüber, wie man diesen Quelltext testen könnte. Keine Werkzeuge. Keine Rechnung über den gesamten Quelltext erforderlich.')
|
||||
target=args.context-1024
|
||||
lo,hi=1,len(lines)
|
||||
while lo<hi:
|
||||
n=(lo+hi+1)//2
|
||||
count=api('/v1/messages/count_tokens',dict(model='synthetic-context',messages=[dict(role='user',content=prompt(n))],thinking={'type':'disabled'},max_tokens=128))['input_tokens']
|
||||
if count<=target:lo=n
|
||||
else:hi=n-1
|
||||
text=prompt(lo)
|
||||
row['planned_input_tokens']=api('/v1/messages/count_tokens',dict(model='synthetic-context',messages=[dict(role='user',content=text)],thinking={'type':'disabled'},max_tokens=128))['input_tokens']
|
||||
row['source_lines']=lo
|
||||
if low.is_set():raise MemoryError('Host reserve below 1536MiB')
|
||||
row['memory_after_load']=sample(args.pid)
|
||||
print('Sending',row['planned_input_tokens'],'tokens at context',args.context,flush=True)
|
||||
req=urllib.request.Request(URL+'/v1/chat/completions',data=json.dumps(dict(model='synthetic-context',messages=[dict(role='user',content=text)],temperature=0,top_p=1,seed=42,reasoning_effort='none',max_tokens=128,stream=True,stream_options={'include_usage':True})).encode(),headers={'Authorization':'Bearer '+TOKEN,'Content-Type':'application/json'})
|
||||
phase['name']='prefill';start=time.monotonic();answer='';usage={};timings={};ttft=None;finish=None;done=False
|
||||
# SSE keepalives keep the read timeout bounded; parent separately watches
|
||||
# production requests and an overall four-hour deadline.
|
||||
with urllib.request.urlopen(req,timeout=180) as response:
|
||||
for line in response:
|
||||
if low.is_set():raise MemoryError('Host reserve below 1536MiB for ten seconds')
|
||||
if time.monotonic()-start>5400:raise TimeoutError('90-minute per-context bound')
|
||||
if not line.startswith(b'data:'):continue
|
||||
raw=line[5:].strip()
|
||||
if raw==b'[DONE]':done=True;break
|
||||
d=json.loads(raw)
|
||||
if 'error' in d:raise RuntimeError(str(d['error']))
|
||||
usage=d.get('usage') or usage;timings=d.get('timings') or d.get('backend_timings') or timings
|
||||
for c in d.get('choices',[]):
|
||||
finish=c.get('finish_reason') or finish
|
||||
content=c.get('delta',{}).get('content')
|
||||
if content:
|
||||
if ttft is None:ttft=time.monotonic()-start;phase['name']='decode'
|
||||
answer+=content
|
||||
if not done:raise RuntimeError('Incomplete SSE response')
|
||||
row.update(usage=usage,timings=timings,ttft_s=ttft,wall_s=time.monotonic()-start,finish=finish,answer=answer,
|
||||
marker_retrieval={m:m in answer for m in ('ALPHA_314159','BETA_271828','GAMMA_161803')})
|
||||
print('Finished',json.dumps(row['timings']),flush=True)
|
||||
except BaseException as exc:
|
||||
row['error']=type(exc).__name__+': '+str(exc)
|
||||
print(row['error'],flush=True)
|
||||
finally:
|
||||
stop.set();t.join(timeout=5);row['memory_samples']=samples;row['finished_at']=time.time()
|
||||
args.output.write_text(json.dumps(row,indent=2,ensure_ascii=False)+'\n')
|
||||
if row['error']:raise SystemExit(1)
|
||||
if __name__=='__main__':main()
|
||||
File diff suppressed because it is too large.
Load diff
File diff suppressed because it is too large.
Load diff
File diff suppressed because it is too large.
Load diff
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,106 @@
|
||||
{
|
||||
"phase": "complete",
|
||||
"restored": true,
|
||||
"settings_unchanged": true,
|
||||
"error": null,
|
||||
"contexts": [
|
||||
{
|
||||
"context": 32768,
|
||||
"load_seconds": 28.592900628049392,
|
||||
"actual_reported_context": 32768,
|
||||
"error": null,
|
||||
"input_tokens": 31738,
|
||||
"output_tokens": 128,
|
||||
"input_tokens_per_s": 177.5,
|
||||
"output_tokens_per_s": 5.8,
|
||||
"prompt_ms": 178831.0,
|
||||
"decode_ms": 22101.6,
|
||||
"cache_tokens": 0,
|
||||
"ttft_s": 178.8928487599478,
|
||||
"wall_s": 200.98310893098824,
|
||||
"markers": {
|
||||
"ALPHA_314159": true,
|
||||
"BETA_271828": true,
|
||||
"GAMMA_161803": true
|
||||
},
|
||||
"samples": 93,
|
||||
"peak_pss_gib": null,
|
||||
"peak_private_gib": null,
|
||||
"peak_rss_gib": null,
|
||||
"peak_swap_pss_gib": null,
|
||||
"min_host_available_gib": 8.140388488769531,
|
||||
"host_swap_start_gib": 0.8835487365722656,
|
||||
"host_swap_peak_gib": 0.8869667053222656,
|
||||
"gpu_peak_mib": {
|
||||
"0": 11465,
|
||||
"1": 15416
|
||||
},
|
||||
"process_memory_note": "Unavailable: initial sampler skipped smaps header; host available RAM and GPU counters are valid."
|
||||
},
|
||||
{
|
||||
"context": 65536,
|
||||
"load_seconds": 28.381254011008423,
|
||||
"actual_reported_context": 65536,
|
||||
"error": null,
|
||||
"input_tokens": 64487,
|
||||
"output_tokens": 128,
|
||||
"input_tokens_per_s": 195.2,
|
||||
"output_tokens_per_s": 5.6,
|
||||
"prompt_ms": 330376.8,
|
||||
"decode_ms": 22919.3,
|
||||
"cache_tokens": 0,
|
||||
"ttft_s": 330.4832194269984,
|
||||
"wall_s": 353.3924959129654,
|
||||
"markers": {
|
||||
"ALPHA_314159": true,
|
||||
"BETA_271828": true,
|
||||
"GAMMA_161803": true
|
||||
},
|
||||
"samples": 162,
|
||||
"peak_pss_gib": null,
|
||||
"peak_private_gib": null,
|
||||
"peak_rss_gib": null,
|
||||
"peak_swap_pss_gib": null,
|
||||
"min_host_available_gib": 8.273757934570312,
|
||||
"host_swap_start_gib": 0.8886756896972656,
|
||||
"host_swap_peak_gib": 0.8969764709472656,
|
||||
"gpu_peak_mib": {
|
||||
"0": 11461,
|
||||
"1": 15418
|
||||
},
|
||||
"process_memory_note": "Unavailable: initial sampler skipped smaps header; host available RAM and GPU counters are valid."
|
||||
},
|
||||
{
|
||||
"context": 131072,
|
||||
"load_seconds": 28.47565862996271,
|
||||
"actual_reported_context": 131072,
|
||||
"error": null,
|
||||
"input_tokens": 130023,
|
||||
"output_tokens": 128,
|
||||
"input_tokens_per_s": 203.4,
|
||||
"output_tokens_per_s": 5.7,
|
||||
"prompt_ms": 639174.7,
|
||||
"decode_ms": 22638.5,
|
||||
"cache_tokens": 0,
|
||||
"ttft_s": 639.372068970988,
|
||||
"wall_s": 662.0075952869956,
|
||||
"markers": {
|
||||
"ALPHA_314159": true,
|
||||
"BETA_271828": true,
|
||||
"GAMMA_161803": true
|
||||
},
|
||||
"samples": 304,
|
||||
"peak_pss_gib": 49.512999534606934,
|
||||
"peak_private_gib": 49.508392333984375,
|
||||
"peak_rss_gib": 49.52780532836914,
|
||||
"peak_swap_pss_gib": 0.0,
|
||||
"min_host_available_gib": 8.199592590332031,
|
||||
"host_swap_start_gib": 0.8964881896972656,
|
||||
"host_swap_peak_gib": 0.9018592834472656,
|
||||
"gpu_peak_mib": {
|
||||
"0": 11467,
|
||||
"1": 15420
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,79 @@
|
||||
{
|
||||
"previous_profile": "flash-next-strata-iq3-dual",
|
||||
"restored_profile": "flash-next-strata-iq3-dual",
|
||||
"controller_restored": true,
|
||||
"settings_unchanged": true,
|
||||
"worker_fields_unchanged": {
|
||||
"exe": true,
|
||||
"args": true,
|
||||
"cwd": true,
|
||||
"tokenizer": true,
|
||||
"model_name": true,
|
||||
"host": true,
|
||||
"gpu": true,
|
||||
"gpu_order": true,
|
||||
"layer_split": true,
|
||||
"vram_elastic": true,
|
||||
"open_browser": true,
|
||||
"log": true,
|
||||
"parallel": true,
|
||||
"reasoning_loop_recovery": true,
|
||||
"vision": true,
|
||||
"env": true
|
||||
},
|
||||
"health": {
|
||||
"status": "ok",
|
||||
"max_context": 262144,
|
||||
"model": "flash-next-strata-iq3-dual",
|
||||
"images": true,
|
||||
"api_key": true,
|
||||
"image_generation": false,
|
||||
"loaded": true,
|
||||
"service": "strata"
|
||||
},
|
||||
"endpoint": {
|
||||
"state": "running",
|
||||
"port": 8120,
|
||||
"counts": {
|
||||
"llm": {
|
||||
"enabled": 12,
|
||||
"available": 12,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"image": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"tts": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"stt": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"music": {
|
||||
"enabled": 2,
|
||||
"available": 2,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"voice": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
}
|
||||
},
|
||||
"active_requests": 0
|
||||
},
|
||||
"test_worker_pids": [],
|
||||
"verified": true
|
||||
}
|
||||
@@ -0,0 +1,273 @@
|
||||
#!/usr/bin/env python3
|
||||
"""One authorized pilot; owned workers only, production priority, finally restore."""
|
||||
import argparse
|
||||
import hashlib
|
||||
import json
|
||||
import os
|
||||
from pathlib import Path
|
||||
import secrets
|
||||
import signal
|
||||
import subprocess
|
||||
import sys
|
||||
import time
|
||||
import urllib.request
|
||||
import threading
|
||||
import random
|
||||
|
||||
BASE = Path(os.environ.get('DECK_TEST_BASE', '/data/athena-deck-strata/experiments/deepseek-iq2-20261024'))
|
||||
STATE = Path(os.environ.get('DECK_TEST_STATE', '/opt/athena-deck-dev/runtime/state'))
|
||||
SOURCE = STATE / 'strata-runtime/source'
|
||||
PYTHON = BASE / 'venv/bin/python'
|
||||
SETTINGS = ('profiles.json', 'endpoint.json', 'audio-policy.json', 'cpu-partition.json')
|
||||
|
||||
|
||||
def hashes():
|
||||
return {n: hashlib.sha256((STATE / n).read_bytes()).hexdigest() for n in SETTINGS}
|
||||
|
||||
|
||||
def translate(obj):
|
||||
if isinstance(obj, str):
|
||||
return obj.replace('/var/lib/deck/', str(STATE) + '/')
|
||||
if isinstance(obj, list):
|
||||
return [translate(v) for v in obj]
|
||||
if isinstance(obj, dict):
|
||||
return {k: translate(v) for k, v in obj.items()}
|
||||
return obj
|
||||
|
||||
|
||||
def main(key, run):
|
||||
run.mkdir(parents=True, exist_ok=False)
|
||||
result = dict(started_at=time.time(), previous_profile=None, arms={}, restored=False)
|
||||
(BASE / 'active-context-run.txt').write_text(str(run) + '\n')
|
||||
deadline = time.monotonic() + 14400
|
||||
owned = None
|
||||
measurement = None
|
||||
original_stopped = False
|
||||
|
||||
def save(phase):
|
||||
result['phase'] = phase
|
||||
result['updated_at'] = time.time()
|
||||
temp = run / 'result.tmp'
|
||||
temp.write_text(json.dumps(result, indent=2) + '\n')
|
||||
temp.replace(run / 'result.json')
|
||||
print(phase, flush=True)
|
||||
|
||||
def api(path, body=None, timeout=15):
|
||||
req = urllib.request.Request('http://127.0.0.1:' + ('8120' if path.startswith('/v1/') else '8108') + path,
|
||||
data=json.dumps(body).encode() if body is not None else None,
|
||||
headers={'Authorization': 'Bearer ' + key, 'Content-Type': 'application/json'})
|
||||
with urllib.request.urlopen(req, timeout=timeout) as response:
|
||||
return json.load(response)
|
||||
|
||||
def idle():
|
||||
stop = time.monotonic() + 1800
|
||||
clean = 0
|
||||
while time.monotonic() < stop:
|
||||
if api('/api/v1/status')['endpoint']['active_requests'] == 0:
|
||||
clean += 1
|
||||
if clean >= 3:
|
||||
return
|
||||
else:
|
||||
clean = 0
|
||||
time.sleep(1)
|
||||
raise RuntimeError('No idle window; productive requests left untouched')
|
||||
|
||||
def abort_check():
|
||||
if (run / 'stop.request').exists() or time.monotonic() > deadline:
|
||||
raise RuntimeError('Own test stop requested or overall time limit')
|
||||
|
||||
def stop_owned():
|
||||
nonlocal owned, measurement
|
||||
if measurement and measurement.poll() is None:
|
||||
measurement.terminate()
|
||||
try:
|
||||
measurement.wait(timeout=8)
|
||||
except subprocess.TimeoutExpired:
|
||||
measurement.kill()
|
||||
measurement.wait()
|
||||
measurement = None
|
||||
if owned and owned.poll() is None:
|
||||
os.killpg(owned.pid, signal.SIGTERM)
|
||||
try:
|
||||
owned.wait(timeout=30)
|
||||
except subprocess.TimeoutExpired:
|
||||
os.killpg(owned.pid, signal.SIGKILL)
|
||||
owned.wait()
|
||||
owned = None
|
||||
|
||||
def production_priority_check():
|
||||
if api('/api/v1/status')['endpoint']['active_requests']:
|
||||
time.sleep(.5)
|
||||
if api('/api/v1/status')['endpoint']['active_requests']:
|
||||
raise RuntimeError('Productive request arrived; only owned synthetic worker is stopped')
|
||||
|
||||
def worker_get(port, token, path):
|
||||
req = urllib.request.Request('http://127.0.0.1:' + str(port) + path,
|
||||
headers={'Authorization': 'Bearer ' + token})
|
||||
with urllib.request.urlopen(req, timeout=3) as response:
|
||||
return json.load(response)
|
||||
|
||||
def on_signal(signum, frame):
|
||||
raise InterruptedError('Own comparison interrupted')
|
||||
|
||||
signal.signal(signal.SIGTERM, on_signal)
|
||||
signal.signal(signal.SIGINT, on_signal)
|
||||
try:
|
||||
save('waiting_for_idle')
|
||||
idle()
|
||||
current = json.loads((STATE / 'strata-worker/worker.json').read_text())
|
||||
assert 'IQ3_XXS' in current['args'][current['args'].index('--native') + 1], 'Expected existing XXS production worker'
|
||||
result['previous_profile'] = current['model_name']
|
||||
result['settings_before'] = hashes()
|
||||
result['endpoint_before'] = api('/api/v1/status')['endpoint']
|
||||
clean = {k: v for k, v in current.items() if k not in ('api_key', 'key')}
|
||||
(run / 'qwen-template.json').write_text(json.dumps(clean, indent=2) + '\n')
|
||||
candidates = []
|
||||
accepted_paths = {b'/var/lib/deck/strata-worker/worker.json', str(STATE / 'strata-worker/worker.json').encode()}
|
||||
for p in Path('/proc').iterdir():
|
||||
if not p.name.isdigit():
|
||||
continue
|
||||
try:
|
||||
args = (p / 'cmdline').read_bytes().split(b'\0')
|
||||
if accepted_paths.intersection(args) and any(a.endswith(b'/serve/server.py') for a in args):
|
||||
candidates.append(int(p.name))
|
||||
except OSError:
|
||||
pass
|
||||
if len(candidates) != 1:
|
||||
raise RuntimeError('Original worker identity is not unique')
|
||||
pid = candidates[0]
|
||||
if os.getpgid(pid) != pid:
|
||||
raise RuntimeError('Original worker has unexpected process-group ownership')
|
||||
# The exact server PID supplies its network namespace for either a
|
||||
# native service or today's container transport; no Docker dependency.
|
||||
check = "import json,sys,urllib.request;x=json.load(sys.stdin);r=urllib.request.Request('http://127.0.0.1:'+str(x['port'])+'/v1/status',headers={'Authorization':'Bearer '+x['api_key']});d=json.load(urllib.request.urlopen(r,timeout=5));print(json.dumps(d.get('activity',{}).get('in_flight')))"
|
||||
for _ in range(600):
|
||||
idle()
|
||||
active = json.loads(subprocess.check_output(['nsenter', '-t', str(pid), '-n', 'python3', '-c', check], input=json.dumps(current), text=True))
|
||||
if active == 0:
|
||||
break
|
||||
time.sleep(2)
|
||||
else:
|
||||
raise RuntimeError('Original worker is not idle')
|
||||
idle()
|
||||
save('unloading_idle_qwen')
|
||||
os.killpg(pid, signal.SIGTERM)
|
||||
original_stopped = True
|
||||
for _ in range(60):
|
||||
# Normal status polling lets Deck reap its completed Popen child.
|
||||
api('/api/v1/status')
|
||||
if not Path('/proc/' + str(pid)).exists():
|
||||
break
|
||||
time.sleep(1)
|
||||
else:
|
||||
raise RuntimeError('Original worker did not stop; no forced production kill')
|
||||
|
||||
cpus = json.loads((STATE / 'cpu-partition.json').read_text())['strata']
|
||||
result['cpu_affinity'] = cpus
|
||||
result['protocol'] = dict(contexts=[32768,65536,131072], target_input='context minus 1024', output_limit=128,
|
||||
temperature=0, top_p=1, seed=42, thinking=False, repetitions=1,
|
||||
synthetic='unique Python source lines with three retrieval markers', reserve_min_available_mib=1536)
|
||||
for context in (32768,65536,131072):
|
||||
arm = str(context)
|
||||
abort_check()
|
||||
idle()
|
||||
cfg = json.loads((BASE / 'test-config.json').read_text())
|
||||
cfg['args'][cfg['args'].index('--max-context') + 1] = str(context)
|
||||
cfg.update(host='127.0.0.1', port=19084, api_key='local-synthetic-context',
|
||||
open_browser=False, log=str(run / (arm + '-engine.log')))
|
||||
cfg_path = run / (arm + '-config.json')
|
||||
cfg_path.write_text(json.dumps(cfg, indent=2) + '\n')
|
||||
source = BASE / 'source'
|
||||
env = dict(os.environ, **cfg.get('env', {}), CUDA_VISIBLE_DEVICES='0,1', PYTHONUNBUFFERED='1')
|
||||
env['LD_LIBRARY_PATH'] = ':'.join(cfg.get('lib_dirs', []) + [env.get('LD_LIBRARY_PATH', '')])
|
||||
cmd = ['taskset', '-c', ','.join(map(str, cpus)), str(PYTHON), str(source / 'serve/server.py'),
|
||||
'--engine', 'strata', '--config', str(cfg_path), '--host', '127.0.0.1', '--port', '19084', '--fit-max-tokens']
|
||||
row = dict(context=context)
|
||||
result['arms'][arm] = row
|
||||
save('loading_' + arm)
|
||||
started = time.monotonic()
|
||||
with (run / (arm + '-server.log')).open('w') as log:
|
||||
owned = subprocess.Popen(cmd, env=env, cwd=source, stdout=log, stderr=subprocess.STDOUT, start_new_session=True)
|
||||
ready_deadline = time.monotonic() + 1800
|
||||
while time.monotonic() < ready_deadline:
|
||||
abort_check()
|
||||
production_priority_check()
|
||||
if owned.poll() is not None:
|
||||
row['error']='worker exited during loading'
|
||||
break
|
||||
try:
|
||||
health = worker_get(19084, cfg['api_key'], '/health')
|
||||
if health.get('status') == 'ok' and health.get('loaded', True):
|
||||
row.update(load_seconds=time.monotonic()-started, health=health, worker_status=worker_get(19084, cfg['api_key'], '/v1/status'))
|
||||
break
|
||||
except OSError:
|
||||
pass
|
||||
time.sleep(2)
|
||||
else:
|
||||
row['error']='loading timeout'
|
||||
if row.get('error'):
|
||||
stop_owned()
|
||||
save('unavailable_' + arm)
|
||||
continue
|
||||
save('measuring_' + arm)
|
||||
args = [str(PYTHON), str(BASE / 'context_measure.py'), '--context', arm,
|
||||
'--pid', str(owned.pid), '--output', str(run / (arm + '-measurement.json')), '--run']
|
||||
with (run / (arm + '-measure.log')).open('w') as log:
|
||||
measurement = subprocess.Popen(args, env=env, cwd=BASE, stdout=log, stderr=subprocess.STDOUT)
|
||||
while measurement.poll() is None:
|
||||
abort_check()
|
||||
production_priority_check()
|
||||
if owned.poll() is not None:
|
||||
raise RuntimeError('worker failed during context measurement')
|
||||
time.sleep(1)
|
||||
out = run / (arm + '-measurement.json')
|
||||
if out.exists():
|
||||
row['measurement']=json.loads(out.read_text())
|
||||
if measurement.returncode:
|
||||
row['error']='measurement harness failed; inspect synthetic log'
|
||||
stop_owned()
|
||||
save('finished_' + arm)
|
||||
except BaseException as exc:
|
||||
result['error'] = type(exc).__name__ + ': ' + str(exc)
|
||||
print(result['error'], flush=True)
|
||||
finally:
|
||||
stop_owned()
|
||||
if original_stopped:
|
||||
save('restoring_qwen')
|
||||
try:
|
||||
idle()
|
||||
body = dict(model=result['previous_profile'], messages=[dict(role='user', content='Antworte mit OK.')],
|
||||
max_tokens=1, temperature=0, reasoning_effort='none')
|
||||
answer = api('/v1/chat/completions', body, timeout=900)
|
||||
restored = json.loads((STATE / 'strata-worker/worker.json').read_text())
|
||||
result['restored'] = bool(answer.get('choices')) and restored['model_name'] == result['previous_profile']
|
||||
result['restored_profile'] = restored['model_name']
|
||||
result['endpoint_after'] = api('/api/v1/status')['endpoint']
|
||||
except Exception as exc:
|
||||
result['restore_error'] = type(exc).__name__ + ': ' + str(exc)
|
||||
result['settings_after'] = hashes()
|
||||
result['settings_unchanged'] = result.get('settings_before') == result['settings_after']
|
||||
result['finished_at'] = time.time()
|
||||
save('complete' if result['restored'] and 'error' not in result else 'finished_with_error')
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
ap = argparse.ArgumentParser(description=__doc__)
|
||||
ap.add_argument('--detach', action='store_true')
|
||||
a = ap.parse_args()
|
||||
key = json.load(sys.stdin)['key']
|
||||
run = BASE / 'context-runs' / (time.strftime('%Y%m%dT%H%M%SZ', time.gmtime()) + '-' + secrets.token_hex(3))
|
||||
if a.detach:
|
||||
pid = os.fork()
|
||||
if pid:
|
||||
print(json.dumps(dict(pid=pid, directory=str(run))))
|
||||
sys.exit(0)
|
||||
os.setsid()
|
||||
fd = os.open(str(BASE / 'context-controller.log'), os.O_WRONLY | os.O_CREAT | os.O_APPEND, 0o600)
|
||||
os.dup2(fd, 1)
|
||||
os.dup2(fd, 2)
|
||||
os.close(fd)
|
||||
fd = os.open('/dev/null', os.O_RDONLY)
|
||||
os.dup2(fd, 0)
|
||||
os.close(fd)
|
||||
main(key, run)
|
||||
@@ -0,0 +1,16 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Summarize recorded context-test counters, preserving missing/failed measurements."""
|
||||
import json,sys
|
||||
from pathlib import Path
|
||||
r=Path(sys.argv[1]);d=json.loads((r/'result.json').read_text());out=dict(phase=d['phase'],restored=d.get('restored'),settings_unchanged=d.get('settings_unchanged'),error=d.get('error'),contexts=[])
|
||||
for context,arm in d['arms'].items():
|
||||
p=r/(context+'-measurement.json');m=json.loads(p.read_text()) if p.exists() else arm.get('measurement',{})
|
||||
s=m.get('memory_samples',[]);t=m.get('timings',{});u=m.get('usage',{})
|
||||
x=dict(context=int(context),load_seconds=arm.get('load_seconds'),actual_reported_context=arm.get('health',{}).get('max_context'),error=m.get('error') or arm.get('error'),input_tokens=u.get('prompt_tokens'),output_tokens=u.get('completion_tokens'),input_tokens_per_s=t.get('prompt_per_second'),output_tokens_per_s=t.get('predicted_per_second'),prompt_ms=t.get('prompt_ms'),decode_ms=t.get('predicted_ms'),cache_tokens=t.get('cache_n'),ttft_s=m.get('ttft_s'),wall_s=m.get('wall_s'),markers=m.get('marker_retrieval'))
|
||||
if s:
|
||||
x.update(samples=len(s),peak_pss_gib=max(v['pss_kib'] for v in s)/1024**2,peak_private_gib=max(v['private_kib'] for v in s)/1024**2,peak_rss_gib=max(v['rss_kib'] for v in s)/1024**2,peak_swap_pss_gib=max(v['swap_pss_kib'] for v in s)/1024**2,min_host_available_gib=min(v['host_available_kib'] for v in s)/1024**2,host_swap_start_gib=s[0]['host_swap_used_kib']/1024**2,host_swap_peak_gib=max(v['host_swap_used_kib'] for v in s)/1024**2,gpu_peak_mib={str(g['index']):max(z['used_mib'] for v in s for z in v['gpus'] if z['index']==g['index']) for g in s[0]['gpus']})
|
||||
if x.get('peak_pss_gib') == 0:
|
||||
for key in ('peak_pss_gib','peak_private_gib','peak_rss_gib','peak_swap_pss_gib'):x[key]=None
|
||||
x['process_memory_note']='Unavailable: initial sampler skipped smaps header; host available RAM and GPU counters are valid.'
|
||||
out['contexts'].append(x)
|
||||
print(json.dumps(out,indent=2))
|
||||
@@ -0,0 +1,31 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Verify restored production worker without printing credentials or user content."""
|
||||
import hashlib,json,os,subprocess,sys,urllib.request
|
||||
from pathlib import Path
|
||||
BASE=Path(os.environ.get('DECK_TEST_BASE','/data/athena-deck-strata/experiments/deepseek-iq2-20261024'))
|
||||
STATE=Path(os.environ.get('DECK_TEST_STATE','/opt/athena-deck-dev/runtime/state'))
|
||||
r=Path((BASE/'active-context-run.txt').read_text().strip());d=json.loads((r/'result.json').read_text())
|
||||
if d['phase'] not in ('complete','finished_with_error'):raise SystemExit('Test still running; do not verify prematurely')
|
||||
key=json.load(sys.stdin)['key']
|
||||
req=urllib.request.Request('http://127.0.0.1:8108/api/v1/status',headers={'Authorization':'Bearer '+key})
|
||||
endpoint=json.load(urllib.request.urlopen(req,timeout=10))['endpoint']
|
||||
worker=json.loads((STATE/'strata-worker/worker.json').read_text());before=json.loads((r/'qwen-template.json').read_text())
|
||||
fields=('exe','args','cwd','tokenizer','model_name','host','gpu','gpu_order','layer_split','vram_elastic','open_browser','log','parallel','reasoning_loop_recovery','vision','env')
|
||||
comparison={k:before.get(k)==worker.get(k) for k in fields}
|
||||
pids=[];leftovers=[]
|
||||
for p in Path('/proc').iterdir():
|
||||
if not p.name.isdigit():continue
|
||||
try:args=(p/'cmdline').read_bytes().split(b'\0')
|
||||
except OSError:continue
|
||||
if any(a.endswith(b'/serve/server.py') for a in args):
|
||||
if any(a in (b'/var/lib/deck/strata-worker/worker.json',str(STATE/'strata-worker/worker.json').encode()) for a in args):pids.append(int(p.name))
|
||||
if any(str(r).encode() in a for a in args):leftovers.append(int(p.name))
|
||||
if any(a.endswith(b'/strata-dsv41') for a in args):leftovers.append(int(p.name))
|
||||
assert len(pids)==1,'Restored worker identity not unique'
|
||||
probe="import json,sys,urllib.request;x=json.load(sys.stdin);r=urllib.request.Request('http://127.0.0.1:'+str(x['port'])+'/health',headers={'Authorization':'Bearer '+x['api_key']});print(json.dumps(json.load(urllib.request.urlopen(r,timeout=5))))"
|
||||
health=json.loads(subprocess.check_output(['nsenter','-t',str(pids[0]),'-n','python3','-c',probe],input=json.dumps(worker),text=True))
|
||||
settings={n:hashlib.sha256((STATE/n).read_bytes()).hexdigest() for n in d['settings_before']}
|
||||
out=dict(previous_profile=d['previous_profile'],restored_profile=worker['model_name'],controller_restored=d.get('restored'),settings_unchanged=settings==d['settings_before'],worker_fields_unchanged=comparison,health=health,endpoint=endpoint,test_worker_pids=leftovers)
|
||||
out['verified']=bool(out['controller_restored'] and out['settings_unchanged'] and all(comparison.values()) and health.get('status')=='ok' and health.get('loaded') and endpoint['counts']['llm']['loaded'] and endpoint['counts']['tts']['loaded'] and endpoint['counts']['stt']['loaded'] and not leftovers)
|
||||
(r/'verification.json').write_text(json.dumps(out,indent=2)+'\n');print(json.dumps(out,indent=2))
|
||||
if not out['verified']:raise SystemExit(1)
|
||||
@@ -0,0 +1,181 @@
|
||||
# DeepSeek IQ2_XXS preparation · 24 October 2026
|
||||
|
||||
**Follow-up comparison completed after Michael's explicit Go:**
|
||||
[Measured results, blind quality assessment and verified Qwen restoration](RESULTS.md).
|
||||
**Later context-capacity test:** [32K,64K and128K measurements](../deepseek-context-2026-10-24/RESULTS.md) completed successfully with Qwen restored.
|
||||
|
||||
The restrictions below describe the earlier preparation-only authorization;
|
||||
the later execution and current restored production state are recorded there.
|
||||
|
||||
Michael authorized downloading DeepSeek-V4.1-Flash-1017 IQ2_XXS and preparing a
|
||||
test. **No production replacement, model unload, inference test, endpoint
|
||||
registration, or application/runtime update is authorized by this preparation.**
|
||||
The existing Qwen IQ3_XXS weights, packs, runtime and profiles remain intact.
|
||||
|
||||
## Current preparation
|
||||
|
||||
**Completed on 24 October 2026.** All seven files passed the configured SHA-256
|
||||
checks, the download exited0, official metadata packing succeeded and the signed
|
||||
engine's `--pack-info` confirmed every referenced file and supported tensor type.
|
||||
See `preparation-result.json`. No inference was run. Qwen's original worker
|
||||
remained loaded and healthy; its GPU memory use stayed11353/15530MiB.
|
||||
About90.4 GB (84.2GiB) remains free on `/data` after preparation.
|
||||
|
||||
Separate native directory on Athena's data NVMe:
|
||||
|
||||
`/data/athena-deck-strata/experiments/deepseek-iq2-20261024`
|
||||
|
||||
Downloads and preparation ran in that directory. The operation is not a new
|
||||
container, permanent service or scheduled task. `prepare.py` performs only
|
||||
acquisition, official signature/hash checks, metadata packing and `--pack-info`.
|
||||
The upstream engine implements `--pack-info` before device/weight initialization.
|
||||
It does **not** execute upstream setup's GPU smoke test or launch the server.
|
||||
|
||||
Preparation can run asynchronously. Read `preparation-status.json` on Athena:
|
||||
only `ready_for_manual_test` means all
|
||||
downloads, the signed engine and pack validation succeeded. It still explicitly
|
||||
means that GPU inference and production integration have **not** been tested.
|
||||
`failed` preserves a concrete error; partial downloads remain resumable. Logs:
|
||||
`download.log`, `download-resume.log` if needed, `engine-download.log`,
|
||||
`prepare.log`, `pack.log`, `pack-info.log` and `python-setup.log`.
|
||||
|
||||
Seven model/support files total **256,816,878,701 bytes**. About 349 GB was free
|
||||
on `/data` before acquisition. The pack indexes original files rather than
|
||||
copying the 138 GB backbone. No other model or data is deleted to make room.
|
||||
|
||||
## Fixed sources
|
||||
|
||||
- Official source tag `v0.2.4`, commit
|
||||
`96ca4383c7b05a8a3e6064c65d9e9977d4b3bb59`, in the isolated `source/`.
|
||||
- ISTA-DASLab/DeepSeek-V4.1-Flash-1017-GSQ-RCO-GGUF, revision
|
||||
`cb02422c900df489cea5833e8a92171224059b3c`: four IQ2_XXS shards and Engram.
|
||||
- Unsloth support files, revision `f924b94f19c1fea02c06a65c8475b0a45e2b88b1`:
|
||||
DSpark Q8_0 and the 5.8 MB metadata-only first UD-Q8_K_XL shard. No other
|
||||
large Unsloth shards or vision files are downloaded.
|
||||
- Every filename, size and original SHA-256 is in `weights-manifest.json`,
|
||||
extracted from that official setup's pinned constants. aria2 verifies the
|
||||
supplied SHA-256 and supports resumption; failed downloads cannot mark ready.
|
||||
- Separate release asset
|
||||
`strata-dsv41-0.1.49.2-linux-x86_64-cuda-cuda13.tar.gz`, 439,871,969 bytes,
|
||||
SHA-256 `918a2155ad6bad0ef6d54e57280dfc7cf6fe713838ca9303300bccaebf275283`.
|
||||
Its version differs from the original source tag because upstream refreshed
|
||||
the DeepSeek package in the same release. The official
|
||||
`strata_control.dsv41_engine.install_package` verifies its trusted signature
|
||||
and every packaged file. The production Qwen 0.1.48 engine is not touched.
|
||||
- Isolated `venv/` uses native host Python 3.13 and pinned upstream
|
||||
`requirements.txt`. `python-lock.txt` records installed dependencies. No host
|
||||
Python packages, CUDA drivers or production environments are changed.
|
||||
|
||||
The official pack command is reproduced exactly: four explicit shards,
|
||||
`--engram`, `--engram-meta`, `--dspark-gguf`, `--dspark-noise-token 128799`,
|
||||
`--dspark-markov-rank 256`. No `--skip-tensors` or `--dense-override`.
|
||||
The shipped `profile-2.00.bin` is copied into the pack as `expert-profile.bin`.
|
||||
|
||||
## Prepared hardware plan, not measured performance
|
||||
|
||||
`hardware-plan.json` is computed by upstream `strata_control.dsv41_fit.plan`
|
||||
using actual GPU identities/capacities and total RAM: RTX 3060 12 GiB,
|
||||
RTX 5080 about 16 GiB and about 62.7 GiB RAM reported by Linux. It returns
|
||||
`tight`, both cards and `--tp 2`. Roughly 107 GB of CPU-lane experts exceed RAM;
|
||||
SSD reads remain essential. These are planner estimates, not observed placement
|
||||
or a speed prediction. Qwen is currently using the GPUs; the plan assumes a
|
||||
later safe unload, not simultaneous DeepSeek operation.
|
||||
|
||||
On successful preparation, `test-config.json` uses both cards `[0,1]`, official
|
||||
`--tp 2`, 8192 context, `--dspark auto` with confidence 0.65, and a private
|
||||
loopback server on port 19084. No speculative CPU/thread/split tuning is applied.
|
||||
No image support or simultaneous requests are claimed for DeepSeek.
|
||||
|
||||
## Fixed later comparison
|
||||
|
||||
`cases.json` contains ten synthetic cases selected before either model answers:
|
||||
the first two per category from the prior IQ3 suite: German, Python coding,
|
||||
diagnosis, simulated tool choice, instruction adherence. Rubric per task:
|
||||
correctness 0–4, instruction following 0–2, evidence/uncertainty 0–2, German 0–2.
|
||||
Record Chinese/Cyrillic intrusions and misspellings separately; legitimate code
|
||||
and quotations are exempt. No claim of general superiority from ten tasks.
|
||||
|
||||
`measure.py` is inert without `--run`. It never launches/stops workers, touches
|
||||
production settings, executes generated code or calls real tools. `mock_tools.py`
|
||||
contains only fixed local responses and rejects state-changing calls. Any later
|
||||
code evaluation must use the existing isolated sandbox, never the host shell.
|
||||
|
||||
Two phases per model, one request at a time:
|
||||
|
||||
1. `--speed-only`: two identical short German backup-writing requests,
|
||||
seed42, temperature0, top_p1, thinking off, max256 output tokens. First and
|
||||
cached repeat are separate; model-loading time is not decode time and a fresh
|
||||
request is not necessarily a cold filesystem cache.
|
||||
2. Ten quality cases, seed42, max2048 output tokens including thinking,
|
||||
requested reasoning budget1024, at most four mock steps and 900 seconds per
|
||||
case. Qwen: temperature1/top_p0.95/top_k20/presence0/repeat1 and medium effort.
|
||||
DeepSeek: temperature1/top_p1 and low effort (upstream's numeric50).
|
||||
These model-specific efforts are **not identical thinking workloads**;
|
||||
record effective limits and truncation. Never tune from observed answers.
|
||||
|
||||
The harness records usage, backend timing objects, first stream token and first
|
||||
answer token times, wall duration, errors, finish reasons, mock validation and
|
||||
final synthetic answer; it discards reasoning text. Compute input/output rates
|
||||
only from actual backend token/time counters, weighted by sum(tokens)/sum(time).
|
||||
Do not label whole-request wall throughput as decode or fabricate missing
|
||||
metrics. Blind-score shuffled responses before checking identities. A larger
|
||||
quality study is a separate decision after this pilot.
|
||||
|
||||
## Later execution requires a separate explicit Go
|
||||
|
||||
Before a later test, recheck active **and queued** productive requests; let them
|
||||
finish. Snapshot the then-active Qwen profile/settings, perform a regulated
|
||||
unload through Deck, and arrange finally-protected restoration of that exact
|
||||
profile. Never start DeepSeek alongside the currently full Qwen GPUs, kill
|
||||
productive requests or assume the old IQ3 benchmark's restore paths still fit.
|
||||
Production requests take priority. This preparation does not implement or
|
||||
authorize the model switch.
|
||||
|
||||
After that separately authorized safe switch, use the isolated native server:
|
||||
|
||||
```sh
|
||||
cd /data/athena-deck-strata/experiments/deepseek-iq2-20261024
|
||||
CUDA_VISIBLE_DEVICES=0,1 venv/bin/python source/serve/server.py \
|
||||
--engine strata --config test-config.json --host 127.0.0.1 --port 19084
|
||||
```
|
||||
|
||||
Wait for actual health/model readiness before calling `measure.py`. Example
|
||||
for a worker already started safely (not executed during preparation):
|
||||
|
||||
```sh
|
||||
venv/bin/python measure.py --arm deepseek --speed-only --output speed-deepseek.jsonl --run
|
||||
venv/bin/python measure.py --arm deepseek --output quality-deepseek.jsonl --run
|
||||
```
|
||||
|
||||
Use the same fixtures against a separately prepared Qwen test worker. Do not
|
||||
point this harness at the production ports 8120/8108; it refuses those ports.
|
||||
Outputs are created exclusively and never overwritten. Restore Qwen and verify
|
||||
its version, health, profile/settings and TTS/STT after any later model test.
|
||||
|
||||
## Native reproduction and preparation checks
|
||||
|
||||
Requires Debian x86_64 with compatible CUDA13 driver, Python3.12+ including
|
||||
venv, git, aria2c, internet and model size plus at least10 GB free. The runtime
|
||||
is not dependent on a Docker image or hidden production mounts. As the intended
|
||||
service user, run `sh acquire.sh /absolute/new/experiment-directory`. It creates
|
||||
only that destination, uses the same source/package/model pins, and never starts
|
||||
inference. For interrupted preparation, inspect status and rerun
|
||||
`python3 prepare.py DIRECTORY`; do not rerun against unrelated directories.
|
||||
Keep scripts together with their execution directory. No weights, secrets or
|
||||
production logs belong in Git; the manifest reacquires public artifacts.
|
||||
|
||||
Checked during preparation: Python syntax, CLI dry-run with no network/inference,
|
||||
ten unique fixtures, accepted expected mock calls, rejected restart mock calls;
|
||||
isolated pinned Python environment installed. The separate engine0.1.49.2 passed
|
||||
the official trusted-signature and full package-file verification. Native `ldd`
|
||||
resolves every library (CUDA13 libraries included in the package); the server's
|
||||
`--help` completes in the isolated venv without loading a model. Production Qwen
|
||||
remains commit `5c8dd322528cc84f68f461ad54a506b9da8fa8d4`, worker port50439,
|
||||
model `flash-next-strata-iq3-dual`. Model acquisition and pack validation are
|
||||
complete. GPU inference, quality, speed,
|
||||
Deck profile/API integration and production restoration remain untested.
|
||||
|
||||
Official references:
|
||||
- https://github.com/Niko1221/Strata/blob/v0.2.4/docs/DEEPSEEK41.md
|
||||
- https://github.com/Niko1221/Strata/releases/tag/v0.2.4
|
||||
- https://huggingface.co/ISTA-DASLab/DeepSeek-V4.1-Flash-1017-GSQ-RCO-GGUF
|
||||
@@ -0,0 +1,202 @@
|
||||
# Qwen IQ3_XXS gegen DeepSeek IQ2_XXS · 24. Oktober 2026
|
||||
|
||||
**Abgeschlossen. Qwen ist wieder gesund und geladen, alle ursprünglichen
|
||||
Workerparameter und persistenten Einstellungen sind erhalten.** Im kleinen
|
||||
Blindvergleich ergibt sich kein nachgewiesener Qualitätsgewinn für DeepSeek;
|
||||
die Geschwindigkeit fällt deutlich geringer aus.
|
||||
|
||||
## Qualität
|
||||
|
||||
Zehn vorher festgelegte synthetische Aufgaben, einmal je Modell, Seed42.
|
||||
Die Rubrik vergibt4 Punkte für sachliche/funktionale Richtigkeit und jeweils2
|
||||
für Anweisungstreue, Belege/Unsicherheit und Deutsch. Ein manueller Bewerter
|
||||
bewertete zufällig anonymisierte Antworten, bevor die Modellzuordnung geöffnet
|
||||
wurde. Das ist ein Pilot, keine unabhängige umfassende Benchmarkstudie.
|
||||
|
||||
| Bereich, je2 Aufgaben | Qwen IQ3_XXS | DeepSeek IQ2_XXS |
|
||||
| --- | ---: | ---: |
|
||||
| Deutsch | 9,75 | 10,00 |
|
||||
| Coding | 10,00 | 9,00 |
|
||||
| Diagnose | 9,00 | 10,00 |
|
||||
| Simulierte Werkzeugwahl | 10,00 | 10,00 |
|
||||
| Anweisungstreue/Unsicherheit | 10,00 | 9,50 |
|
||||
| **Gesamt, maximal10** | **9,75** | **9,70** |
|
||||
| Kernauftrag einschließlich Ausgabeformat erfüllt | 10/10 | 9/10 |
|
||||
|
||||
Nach Aufgaben: DeepSeek gewinnt3, Qwen2, fünf Gleichstände. Der winzige
|
||||
Unterschied im Mittelwert trägt keine allgemeine Rangfolge. Zehn Aufgaben sind
|
||||
die unabhängigen Einheiten, nicht20 unabhängige Vergleichspaare.
|
||||
|
||||
Konkrete Unterschiede:
|
||||
|
||||
- DeepSeek setzte bei `code-bytes` das verlangte reine JSON in einen Markdown-
|
||||
Codeblock. Der unveränderte Output scheitert an striktem JSON-Parsing. Nach
|
||||
Entfernung ausschließlich dieses Rahmens besteht der enthaltene Code die
|
||||
Funktionstests; diese zusätzliche Diagnose hebt den ursprünglichen
|
||||
Anweisungsfehler nicht auf. Ein zweiter kleiner Abzug betrifft unklar als
|
||||
Fahrplandaten gekennzeichnete Zugzeiten, nicht eine behauptete Pünktlichkeit.
|
||||
- Qwen gab bei einer ansonsten richtigen systemd-Diagnose ein zusätzliches
|
||||
`pip`-Beispiel ohne führenden Schrägstrich und eine unbelegte Empfehlung für
|
||||
den Interpreter-Namen aus; außerdem „das Exec-Aufruf“. Kleinere Abzüge
|
||||
betreffen die überstarken Aussagen „ordnungsgemäß“ beziehungsweise dass nur
|
||||
eine einzelne Fehlkonfiguration existieren könne.
|
||||
- Beide Modelle wählten in beiden Werkzeugfällen die korrekte Funktion und
|
||||
die korrekten Parameter. Sämtliche Werkzeugergebnisse waren lokale Mocks;
|
||||
keine realen MCP-, SSH-, Dienst- oder Änderungsaktionen wurden ausgeführt.
|
||||
- In den20 finalen Antworten wurden **keine chinesischen Einwürfe** beobachtet.
|
||||
Das ist keine ausreichende Stichprobe, um gelegentliche Sprachmischung im
|
||||
langen Hermes-Alltag auszuschließen.
|
||||
|
||||
Alle vier Codeantworten wurden ohne Netzwerk, GPU, Zugangsdaten oder Host-
|
||||
Mounts in kurzlebigen, begrenzten Offline-Sandboxes aus dem vorhandenen Image
|
||||
geprüft. Beide Qwen-Antworten und eine unveränderte DeepSeek-Antwort bestehen.
|
||||
Die vierte besteht nach der gesondert protokollierten Rahmenentfernung.
|
||||
Generierter Code wurde zusätzlich gelesen; seine eigene stdout-Ausgabe allein
|
||||
wurde nicht als Testnachweis akzeptiert.
|
||||
|
||||
Die Bewertung wurde vor Entblindung festgeschrieben:
|
||||
|
||||
`cd44fb230dfb0df58fb9d63fae4971990b9fb1d44105b9a96ede1f44a0e57220`
|
||||
|
||||
Dateien: `results/blind-assessment.json`, `blind-assessment.sha256`,
|
||||
`blind-answers.json`, `identity-map.json`, `blind-code-results.json` und
|
||||
`quality-summary.json`.
|
||||
|
||||
## Geschwindigkeit
|
||||
|
||||
Die beiden kurzen Geschwindigkeitsanfragen sind identisch, ohne Denken,
|
||||
temperature0, seed42 und je256 Ausgabetokens. Sie wurden nach dem Laden des
|
||||
jeweiligen Testworkers gesendet. Die zweite ist eine direkte Wiederholung;
|
||||
ein „erster Lauf“ bedeutet hier keine neue Chatfrage im laufenden Alltag und
|
||||
keinen garantierten kalten SSD-Cache.
|
||||
|
||||
| Kurze Messung | Qwen | DeepSeek |
|
||||
| --- | ---: | ---: |
|
||||
| Erste Anfrage nach Laden: Ausgabe Tokens/s | **62,6** | **10,2** |
|
||||
| Direkte Wiederholung: Ausgabe Tokens/s | **85,4** | **16,6** |
|
||||
| Erste Anfrage: Promptzeit | 1,077s | 26,244s |
|
||||
| Erste Anfrage: erste sichtbare Ausgabe | 1,122s | 26,300s |
|
||||
| Wiederholung: Promptzeit | 0,120s | 0,187s |
|
||||
| Wiederholung: erste sichtbare Ausgabe | 0,137s | 0,189s |
|
||||
| Erste Anfrage: gesamte Requestzeit | 5,178s | 51,321s |
|
||||
| Wiederholung: gesamte Requestzeit | 3,122s | 15,594s |
|
||||
|
||||
Je83 Eingabetokens: Qwen nutzt bei der Wiederholung76 gecachte Tokens,
|
||||
DeepSeek82. Der absichtliche256-Token-Stopp dieser Geschwindigkeitsaufgabe ist
|
||||
kein Qualitätsfehler und wird nicht mit den Qualitätsaufgaben vermischt.
|
||||
|
||||
Über den eigentlichen Aufgabenmix ergeben sich aus allen12 Modellschritten
|
||||
je Modell folgende gewichtete Backend-Raten:
|
||||
|
||||
| Aufgabenmix | Qwen | DeepSeek |
|
||||
| --- | ---: | ---: |
|
||||
| Neue Eingabetokens/s | **155,7** | **10,4** |
|
||||
| Ausgabetokens/s inklusive Denken | **75,0** | **9,6** |
|
||||
| Median der einzelnen Ausgaberaten | 71,55 | 10,0 |
|
||||
| Spanne der einzelnen Ausgaberaten | 60,4–81,6 | 7,3–10,7 |
|
||||
| Eingabe gesamt, inklusive Cache | 3270 | 3691 |
|
||||
| Davon Cache | 1035 | 1129 |
|
||||
| Neu eingelesene Eingabetokens | 2235 | 2562 |
|
||||
| Ausgabe inklusive Denken | 5698 | 4840 |
|
||||
| Requestzeit im Aufgabenmix insgesamt | 90,4s | 750,4s |
|
||||
| Fehler / durch Ausgabelimit abgeschnittene Qualitätsfälle | 0 / 0 | 0 / 0 |
|
||||
|
||||
Raten sind `Summe(Tokens)/Summe(zugehöriger Backendzeit)`, kein Mittelwert von
|
||||
Einzelraten und kein Decode aus gesamter Wallzeit. Alle24 Qualitätsschritte
|
||||
liefern Backend-Timings. Eingabeumfang und Cacheanteil unterscheiden sich
|
||||
aufgrund der Tokenizer, Templates und eigener Antworten in den Mock-Schritten.
|
||||
Die Eingaberaten aus diesen kurzen Aufgaben sind **kein Langkontext-Benchmark**;
|
||||
sie sagen nicht voraus, wie schnell beispielsweise4K oder100K Tokens gelesen
|
||||
würden. Cachezustände wurden nicht physisch gelöscht, die Reihenfolge war Qwen
|
||||
vor DeepSeek, nicht randomisiert. Das sind zwei kurze Geschwindigkeitsproben
|
||||
und ein Aufgabenmix, keine belastbare Leistungsstreuung über mehrere Tage.
|
||||
|
||||
Der gesamte Testablauf einschließlich Laden, Wechsel und Wiederherstellung
|
||||
dauerte **18min23s**. Die Blindbewertung und Codeprüfung folgten danach.
|
||||
Ladezeiten des Testworkers: Qwen71,8s, DeepSeek28,7s; diese Zeiten sind nicht
|
||||
in den Decode-Raten enthalten und hängen ebenfalls von Cachezuständen ab.
|
||||
|
||||
## Tatsächliche Hardware und Laufzeiten
|
||||
|
||||
- Athena: Ryzen5 5600, etwa62,7GiB nutzbarer RAM, RTX3060 12GiB und RTX5080
|
||||
etwa16GiB. Beide Tests verwenden dieselbe aktuelle Strata-CPU-Affinität
|
||||
`0,1,2,3,6,7,8,9`; TTS/STT bleiben unverändert geladen.
|
||||
- Qwen: vorhandene Engine0.1.48 aus v0.2.3,
|
||||
Commit `5c8dd322528cc84f68f461ad54a506b9da8fa8d4`, originale IQ3_XXS-Gewichte,
|
||||
originale gespeicherte Zweikarten-Aufteilung, Kontext262144 und Dual-Slot-
|
||||
Konfiguration. Nur eine synthetische Anfrage gleichzeitig. Für diesen reinen
|
||||
Texttest wurde ausschließlich im eigenen Testconfig der CPU-Bildleser
|
||||
weggelassen; die Produktion behält ihn. MTP und Helper-CPU-Einstellung bleiben
|
||||
wie in der bestehenden Laufzeit.
|
||||
- DeepSeek: separate signaturgeprüfte Engine0.1.49.2, Serverquelle v0.2.4,
|
||||
vorbereitete IQ2_XXS-Revision, Kontext8192, ein Slot. Das angeforderte `--tp 2`
|
||||
wird von der Engine wegen der256-Werte-Quantblöcke und `n_ff=2304` intern auf
|
||||
**tp1, Schichtaufteilung**, zurückgenommen. Tatsächlich beide Karten: CUDA0
|
||||
Layer0–19, CUDA1 Layer20–39 plus Kopf. Gemeldete Expertenbelegung:6,10GB und
|
||||
10,02GB; etwa572/590MiB bleiben frei. Es wurde nicht nachgetunt.
|
||||
- DSpark bleibt bei `auto` ungeladen: die Engine meldet, dass die132GB
|
||||
gerouteten Experten gegenüber28GB VRAM bei Verifikationsrunden unnötige
|
||||
zusätzliche Lesezugriffe erzeugen. Der RAM-Store ist48GB groß;34,3GB des
|
||||
Hot-Expert-Profils wurden in10,5s vorab gelesen. Das sind Engine-Beobachtungen,
|
||||
keine manuell erzwungene Abschaltung.
|
||||
- Es werden zwei praktisch einsetzbare Modellkonfigurationen verglichen,
|
||||
keine isolierte Quantisierungsänderung oder identischen Engineversionen.
|
||||
Modellabhängige empfohlene Sampling-Werte/Denkstufen stehen im Testplan.
|
||||
Das Denkbudget ist auf1024 und die Gesamtausgabe auf2048 angefordert;
|
||||
DeepSeek low entspricht50, Qwen verwendet medium. Das ist kein Nachweis
|
||||
gleicher interner Denkarbeit. Große Kontexte, Bilder, vollständige Hermes-
|
||||
MCP-Kataloge, Subagenten und gleichzeitige Nutzer wurden nicht getestet.
|
||||
|
||||
**SSD-Zählergrenze:** Der ursprüngliche optionale Collector sah nur die
|
||||
Prozessgruppe des Servers, während die Engine ihre eigene startet. Die in
|
||||
`results/result.json` vorhandenen0-Byte-Werte sind deshalb **nicht gemessen /
|
||||
ungültig**, kein Nachweis von0 SSD-Lesezugriffen. `verification.json` hält diese
|
||||
Grenze fest. Aus diesen Werten werden keine Aussagen zur SSD-Last abgeleitet.
|
||||
Der gewartete Runner gibt diesen optionalen Wert künftig als unavailable aus.
|
||||
|
||||
## Wiederherstellung und Sicherheit
|
||||
|
||||
Die Endpunktzählung umfasst auch vor der Modellreservierung wartende Anfragen.
|
||||
Sie wurde mehrfach mit0 geprüft; zusätzlich meldete der originale Worker
|
||||
`activity.in_flight=0`. Nur die eindeutig identifizierte Prozessgruppe des
|
||||
untätigen Deck-Modellworkers wurde regulär beendet. Kein Container, Host oder
|
||||
Hermes-Dienst wurde neu gestartet. Neue produktive Anfragen hätten den eigenen
|
||||
synthetischen Worker beendet; keine produktive Anfrage wurde zum Fortsetzen
|
||||
des Benchmarks abgebrochen.
|
||||
|
||||
Die Testworker liefen auf dem Host in einer eigenen Python-Umgebung und auf
|
||||
einem privaten Loopback-Port. Alle Produktionsschlüssel blieben nur im
|
||||
Controller-Speicher; Testworker verwenden ausschließlich eine lokale
|
||||
synthetische Testidentität. Produktive Prompts/Antworten wurden nicht gesammelt.
|
||||
|
||||
Der Controller hat in seinem `finally`-Pfad den bisherigen API-Namen
|
||||
`flash-next-strata-iq3-dual` über eine reguläre authentifizierte Anfrage wieder
|
||||
geladen. Anschließend bestätigt:
|
||||
|
||||
- Direkter Worker-Health `ok`, `loaded=true`.
|
||||
- Alle gespeicherten Original-Workerfelder identisch, ausgenommen neuer
|
||||
temporärer Schlüssel und Port.
|
||||
- SHA-256 von `profiles.json`, `endpoint.json`, `audio-policy.json` und
|
||||
`cpu-partition.json` vorher/nachher identisch.
|
||||
- Endpunkt läuft, Qwen/TTS/STT sind geladen; keine offenen Anfragen am Abschluss.
|
||||
- Keine eigenen Testserver oder DeepSeek-Engineprozesse verbleiben.
|
||||
|
||||
Nachweis: `results/result.json` und `results/verification.json`. Die großen
|
||||
Gewichte, Laufzeiten und produktiven Endpunkte bleiben erhalten; DeepSeek ist
|
||||
nicht als produktives Modell freigegeben.
|
||||
|
||||
Für künftige Läufe wurde lediglich die Orchestrierung nachgeschärft: Der
|
||||
originale Server-PID liefert den Netzwerk-Namespace ohne Docker-Abhängigkeit;
|
||||
eine normale Statusabfrage lässt Deck den beendeten Popen-Prozess abholen.
|
||||
Produktionspfade sind mit `DECK_TEST_BASE`/`DECK_TEST_STATE` explizit anpassbar;
|
||||
die hier verwendeten lokalen API-Ports8108/8120 und das Workerlayout müssen
|
||||
vorher geprüft werden. Diese Wartung ändert weder Modellantworten noch die
|
||||
festgeschriebene Bewertung. Die separate Code-Sandbox benötigt das bereits
|
||||
vorhandene lokale Docker-Image; sie ist keine Laufzeitabhängigkeit der nativen
|
||||
Modelle. Eine universelle native Produktintegration von DeepSeek ist nicht
|
||||
implementiert oder als getestet ausgewiesen.
|
||||
|
||||
**Empfehlung:** Qwen als Standard behalten. DeepSeek zeigt hier keinen
|
||||
nachgewiesenen Gesamtqualitätsgewinn, aber erheblich längere Antwortzeiten.
|
||||
Schwierige Repo-Aufgaben oder seltene Sprachfehler sind durch diesen kleinen
|
||||
Pilot nicht abschließend bewertet.
|
||||
@@ -0,0 +1,33 @@
|
||||
#!/bin/sh
|
||||
# Native reproducible preparation; never launches a model or touches Deck.
|
||||
set -eu
|
||||
task_source_dir=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
|
||||
task_destination=${1:?Usage: acquire.sh /absolute/new/experiment-directory}
|
||||
case "$task_destination" in /*) ;; *) echo 'Use an absolute destination.' >&2; exit 2;; esac
|
||||
if [ -e "$task_destination" ]; then
|
||||
echo 'Destination already exists; inspect its status and resume prepare.py instead.' >&2
|
||||
exit 2
|
||||
fi
|
||||
for task_program in python3 git aria2c; do command -v "$task_program" >/dev/null; done
|
||||
mkdir -p "$task_destination/models"
|
||||
cp "$task_source_dir/prepare.py" "$task_source_dir/measure.py" "$task_source_dir/mock_tools.py" \
|
||||
"$task_source_dir/cases.json" "$task_source_dir/weights-manifest.json" "$task_destination/"
|
||||
git clone --depth 1 --branch v0.2.4 https://github.com/Niko1221/Strata.git "$task_destination/source"
|
||||
test "$(git -C "$task_destination/source" rev-parse HEAD)" = 96ca4383c7b05a8a3e6064c65d9e9977d4b3bb59
|
||||
python3 - "$task_destination" <<'PY'
|
||||
import json, shutil, sys
|
||||
from pathlib import Path
|
||||
base=Path(sys.argv[1]);m=json.loads((base/'weights-manifest.json').read_text())
|
||||
if shutil.disk_usage(base).free < m['total_bytes'] + 10_000_000_000:
|
||||
raise SystemExit('Need at least model download size plus 10 GB free. Nothing is deleted.')
|
||||
lines=[]
|
||||
for f in m['files']:
|
||||
lines += [f"https://huggingface.co/{f['repo']}/resolve/{f['revision']}/{f['path']}",
|
||||
f" dir={base/'models'}",f" out={f['name']}",f" checksum=sha-256={f['sha256']}"]
|
||||
(base/'weights.aria2').write_text('\n'.join(lines)+'\n')
|
||||
PY
|
||||
python3 -m venv "$task_destination/venv"
|
||||
"$task_destination/venv/bin/python" -m pip install --disable-pip-version-check -r "$task_destination/source/requirements.txt"
|
||||
"$task_destination/venv/bin/python" -m pip freeze >"$task_destination/python-lock.txt"
|
||||
printf 'ready\n' >"$task_destination/python-ready.txt"
|
||||
exec python3 "$task_destination/prepare.py" "$task_destination"
|
||||
@@ -0,0 +1,24 @@
|
||||
"""Anonymize synthetic final answers; freeze assessment before opening mapping."""
|
||||
import json
|
||||
from pathlib import Path
|
||||
import random
|
||||
import secrets
|
||||
import sys
|
||||
|
||||
stage = Path(sys.argv[1])
|
||||
answers, mapping = [], {}
|
||||
for path in sorted(stage.glob('quality-*.jsonl')):
|
||||
for line in path.read_text().splitlines():
|
||||
row = json.loads(line)
|
||||
code = secrets.token_hex(6)
|
||||
mapping[code] = dict(arm=row['arm'], case_id=row['case_id'])
|
||||
answers.append(dict(answer_id=code, case_id=row['case_id'], category=row['category'],
|
||||
answer=row['answer'], error=row.get('error'),
|
||||
truncated=row.get('truncated', False), tool_checks=row['tool_checks']))
|
||||
random.SystemRandom().shuffle(answers)
|
||||
for name, data in [('blind-answers.json', answers), ('identity-map.json', mapping)]:
|
||||
with (stage / name).open('x') as output:
|
||||
json.dump(data, output, ensure_ascii=False, indent=2)
|
||||
if name == 'identity-map.json':
|
||||
(stage / name).chmod(0o600)
|
||||
print('Anonymized answers:', len(answers), '; do not read identity-map before freezing assessment.')
|
||||
@@ -0,0 +1,317 @@
|
||||
[
|
||||
{
|
||||
"id": "de-correction",
|
||||
"category": "deutsch",
|
||||
"prompt": "Korrigiere ausschließlich Rechtschreibung und Grammatik. Gib nur den korrigierten Text zurück: Beide Server sind ereichbar. Wenn du magst, prüfe die zugehörigkeit der VM. Die Konfiguration wurde verschoben, die Datenträger blieben unverendert.",
|
||||
"criteria": "Keine unveränderten Tippfehler, keine neuen Fehler, deutsche Begriffe statt fremdsprachiger Einwürfe, keine Zusatzinformationen.",
|
||||
"points": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "de-summary",
|
||||
"category": "deutsch",
|
||||
"prompt": "Fasse auf Deutsch in genau drei vollständigen Sätzen zusammen: Dienst läuft; kein Fehler im Log; zwei Warnungen betreffen einen einmaligen Timeout; keine bestätigte Ursache; es wurde nichts neu gestartet.",
|
||||
"criteria": "Drei korrekte deutsche Sätze; alle fünf Fakten; keine erfundene Ursache; keine fremdsprachigen Wörter außer etablierten Fachbegriffen.",
|
||||
"points": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "code-merge",
|
||||
"category": "coding",
|
||||
"prompt": "Schreibe Python 3 ohne externe Bibliotheken: merge_intervals(intervals) vereinigt überlappende oder sich berührende geschlossene Intervalle. Eingaben können unsortiert sein; verändere die Eingabe nicht; [] ergibt []. Ausgabe Liste von (start,end)-Tupeln. Antworte ausschließlich mit JSON {\"code\":\"...\"}.",
|
||||
"criteria": "Syntax, ausführbare Funktion, alle verdeckten Tests, keine Seiteneffekte.",
|
||||
"function": "merge_intervals",
|
||||
"tests": "data=[(5,7),(1,3),(3,5)]; copy=list(data); assert merge_intervals(data)==[(1,7)]; assert data==copy; assert merge_intervals([])==[]; assert merge_intervals([(1,1),(2,2)])==[(1,1),(2,2)]; assert merge_intervals([(-3,0),(-1,2),(8,9)])==[(-3,2),(8,9)]",
|
||||
"points": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "code-bytes",
|
||||
"category": "coding",
|
||||
"prompt": "Schreibe Python 3: parse_size(text) -> int. Erlaube nur nichtnegative ganze Zahlen mit B, KB, MB, GB (1000er) oder KiB, MiB, GiB (1024er), optional Leerraum zwischen Zahl und Einheit sowie außen. Groß-/Kleinschreibung der Einheiten ist exakt. Ungültiges ergibt ValueError. Keine externen Bibliotheken. Nur JSON {\"code\":\"...\"}.",
|
||||
"criteria": "Alle Tests, präzise Einheiten, vollständige Eingabevalidierung.",
|
||||
"function": "parse_size",
|
||||
"tests": "assert parse_size('1 GiB')==1073741824; assert parse_size(' 2MB ')==2000000; assert parse_size('0 B')==0; assert parse_size('3KiB')==3072\nfor bad in ['-1 GB','1.5 GB','1 gb','4 TB','1 MB xyz','']:\n try: parse_size(bad)\n except ValueError: pass\n else: raise AssertionError(bad)",
|
||||
"points": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "diag-service",
|
||||
"category": "diagnose",
|
||||
"prompt": "Nur diese synthetischen Daten auswerten: systemd atlas.service: failed, status=203/EXEC. ExecStart=/srv/atlas/venv/bin/python /srv/atlas/app.py. /srv/atlas/venv/bin/python fehlt; /usr/bin/python3 existiert. Log: Failed at step EXEC spawning /srv/atlas/venv/bin/python: No such file or directory. Was ist die belegte Ursache, was wäre der nächste sinnvolle Schritt? Nichts ausführen.",
|
||||
"criteria": "Fehlender Interpreterpfad, nicht belegte kaputte App vermeiden; virtuelle Umgebung/Deployment prüfen; keine angeblich ausgeführten Änderungen.",
|
||||
"points": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "diag-proxy",
|
||||
"category": "diagnose",
|
||||
"prompt": "Synthetischer Befund: Reverse Proxy antwortet 502. Upstream ist 127.0.0.1:9000 im Proxy-Container. Anwendung läuft in anderem Container auf app:9000. Beide sind im gleichen Docker-Netzwerk. GET http://app:9000/health im Proxy-Container:200. Was ist die wahrscheinlichste Fehlkonfiguration und wie prüfen wir eine Korrektur?",
|
||||
"criteria": "127.0.0.1 bezieht sich auf Proxy-Container, Backend app:9000 erreichbar; Änderung nur vorschlagen; externen Zugriff nachher verifizieren; keine behauptete Ausführung.",
|
||||
"points": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "tool-status",
|
||||
"category": "werkzeuge",
|
||||
"prompt": "Prüfe ausschließlich den Zustand von atlas.service mit dem passenden Werkzeug. Nichts ändern. Berichte den belegten Zustand.",
|
||||
"criteria": "service_status mit service=atlas.service; Antwort muss Toolbefund failed wiedergeben; keine restart_service-Anfrage.",
|
||||
"tools": [
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "service_status",
|
||||
"description": "Read the state of one synthetic service.",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"service": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"service"
|
||||
],
|
||||
"additionalProperties": false
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "service_logs",
|
||||
"description": "Read synthetic service logs.",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"service": {
|
||||
"type": "string"
|
||||
},
|
||||
"lines": {
|
||||
"type": "integer",
|
||||
"minimum": 1,
|
||||
"maximum": 50
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"service",
|
||||
"lines"
|
||||
],
|
||||
"additionalProperties": false
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "restart_service",
|
||||
"description": "Restart a service (state-changing; forbidden unless explicitly authorized).",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"service": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"service"
|
||||
],
|
||||
"additionalProperties": false
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "search_tools",
|
||||
"description": "Discover a synthetic capability; no real backend.",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"query": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"query"
|
||||
],
|
||||
"additionalProperties": false
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"mocks": {
|
||||
"service_status": {
|
||||
"service": "atlas.service",
|
||||
"state": "failed"
|
||||
}
|
||||
},
|
||||
"expected_tool": "service_status",
|
||||
"expected_args": {
|
||||
"service": "atlas.service"
|
||||
},
|
||||
"points": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "tool-logs",
|
||||
"category": "werkzeuge",
|
||||
"prompt": "Lies die letzten 20 Logzeilen von atlas.service. Keine anderen Daten und nichts neu starten. Erkläre die belegte Fehlermeldung.",
|
||||
"criteria": "service_logs mit exakten Parametern; fehlender Interpreter erkannt; kein Neustart.",
|
||||
"tools": [
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "service_status",
|
||||
"description": "Read the state of one synthetic service.",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"service": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"service"
|
||||
],
|
||||
"additionalProperties": false
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "service_logs",
|
||||
"description": "Read synthetic service logs.",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"service": {
|
||||
"type": "string"
|
||||
},
|
||||
"lines": {
|
||||
"type": "integer",
|
||||
"minimum": 1,
|
||||
"maximum": 50
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"service",
|
||||
"lines"
|
||||
],
|
||||
"additionalProperties": false
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "restart_service",
|
||||
"description": "Restart a service (state-changing; forbidden unless explicitly authorized).",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"service": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"service"
|
||||
],
|
||||
"additionalProperties": false
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "search_tools",
|
||||
"description": "Discover a synthetic capability; no real backend.",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"query": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"query"
|
||||
],
|
||||
"additionalProperties": false
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"mocks": {
|
||||
"service_logs": {
|
||||
"service": "atlas.service",
|
||||
"lines": [
|
||||
"Failed at step EXEC spawning /srv/atlas/venv/bin/python: No such file or directory"
|
||||
]
|
||||
}
|
||||
},
|
||||
"expected_tool": "service_logs",
|
||||
"expected_args": {
|
||||
"service": "atlas.service",
|
||||
"lines": 20
|
||||
},
|
||||
"points": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "rule-json",
|
||||
"category": "anweisungen",
|
||||
"prompt": "Antworte ausschließlich als gültiges JSON mit genau diesen Schlüsseln: status, evidence, unknown. Daten: Dienst antwortet auf /health mit200; keine Logdaten vorhanden. status soll \"erreichbar\" sein, evidence eine Liste mit dem belegten Befund, unknown eine Liste der nicht geprüften Dinge.",
|
||||
"criteria": "Exaktes JSON/Schlüssel, erreichbar statt vollständig gesund, keine erfundenen Logs oder Diagnosen.",
|
||||
"points": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "rule-uncertainty",
|
||||
"category": "anweisungen",
|
||||
"prompt": "Ein Zug fährt laut Fahrplan 05:21 ab und kommt 05:40 an. realtime_available=false; estimated_unconfirmed=true. Berichte knapp Abfahrt, Ankunft, Dauer und Pünktlichkeit.",
|
||||
"criteria": "19Minuten; Fahrplandaten; keine bestätigte Echtzeit oder Pünktlichkeit; estimated_unconfirmed nicht als Prognose bestätigen.",
|
||||
"points": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,27 @@
|
||||
"""Execute anonymous coding answers in the existing disposable offline sandbox."""
|
||||
import json
|
||||
from pathlib import Path
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
base = Path(__file__).resolve().parent
|
||||
stage = Path(sys.argv[1])
|
||||
cases = {c['id']: c for c in json.loads((base / 'cases.json').read_text())}
|
||||
answers = json.loads((stage / 'blind-answers.json').read_text())
|
||||
image = subprocess.check_output(['docker', 'inspect', '-f', '{{.Image}}', 'athena-deck-dev'], text=True).strip()
|
||||
directory = stage / 'blind-code-checks'
|
||||
directory.mkdir(exist_ok=False)
|
||||
results = {}
|
||||
for answer in answers:
|
||||
case = cases[answer['case_id']]
|
||||
if 'function' not in case:
|
||||
continue
|
||||
identity = answer['answer_id']
|
||||
cpath, apath = directory / (identity + '-case.json'), directory / (identity + '-answer.json')
|
||||
cpath.write_text(json.dumps(case))
|
||||
apath.write_text(json.dumps(answer))
|
||||
checked = subprocess.run([sys.executable, str(base / 'check_code.py'), str(cpath), str(apath), image],
|
||||
text=True, capture_output=True, timeout=40, check=True)
|
||||
results[identity] = json.loads(checked.stdout)
|
||||
print(identity, json.dumps(results[identity]), flush=True)
|
||||
(stage / 'blind-code-results.json').write_text(json.dumps(results, indent=2) + '\n')
|
||||
@@ -0,0 +1,24 @@
|
||||
"""Run one generated function only in an existing-image disposable sandbox."""
|
||||
import json,subprocess,sys,uuid
|
||||
from pathlib import Path
|
||||
case=json.loads(Path(sys.argv[1]).read_text());answer=json.loads(Path(sys.argv[2]).read_text());image=sys.argv[3]
|
||||
try:code=json.loads(answer['answer'])['code'];assert isinstance(code,str)
|
||||
except Exception:print(json.dumps({'passed':False,'error':'invalid_code_json'}));raise SystemExit(0)
|
||||
script="""import json,sys,resource
|
||||
resource.setrlimit(resource.RLIMIT_CPU,(2,2))
|
||||
resource.setrlimit(resource.RLIMIT_FSIZE,(1048576,1048576))
|
||||
payload=json.load(sys.stdin)
|
||||
try:
|
||||
scope={};exec(compile(payload['code'],'candidate','exec'),scope);exec(compile(payload['tests'],'tests','exec'),scope)
|
||||
print(json.dumps({'passed':True}))
|
||||
except BaseException as e:print(json.dumps({'passed':False,'error':type(e).__name__}))
|
||||
"""
|
||||
name='athena-deepseek-pilot-code-'+uuid.uuid4().hex[:12]
|
||||
cmd=['docker','run','--runtime','runc','--env','NVIDIA_VISIBLE_DEVICES=void','--env','CUDA_VISIBLE_DEVICES=-1','--name',name,'--rm','-i','--network','none','--read-only','--tmpfs','/tmp:rw,noexec,nosuid,size=16m','--cap-drop','ALL','--security-opt','no-new-privileges','--memory','256m','--memory-swap','256m','--cpus','1','--pids-limit','32','--user','65534:65534','--entrypoint','python3',image,'-I','-c',script]
|
||||
try:
|
||||
r=subprocess.run(cmd,input=json.dumps({'code':code,'tests':case['tests']}),text=True,capture_output=True,timeout=15)
|
||||
# Generated code could print fake success: evaluator must also inspect code/tests.
|
||||
print(json.dumps({'returncode':r.returncode,'stdout':r.stdout[-4000:],'stderr':r.stderr[-1000:],'sandbox_result_requires_review':True}))
|
||||
except subprocess.TimeoutExpired:print(json.dumps({'passed':False,'error':'sandbox_timeout'}))
|
||||
|
||||
finally:subprocess.run(['docker','rm','-f',name],stdout=subprocess.DEVNULL,stderr=subprocess.DEVNULL)
|
||||
@@ -0,0 +1,63 @@
|
||||
{
|
||||
"variant": "IST-DAS-2.00bpw",
|
||||
"cards": [
|
||||
{
|
||||
"index": 0,
|
||||
"name": "NVIDIA GeForce RTX 3060",
|
||||
"vram_gb": 12.884901888,
|
||||
"layers": [
|
||||
0,
|
||||
16
|
||||
],
|
||||
"dense_gb": 2.2,
|
||||
"experts_gb": 10.4,
|
||||
"experts": 1213
|
||||
},
|
||||
{
|
||||
"index": 1,
|
||||
"name": "NVIDIA GeForce RTX 5080",
|
||||
"vram_gb": 17.094934528,
|
||||
"layers": [
|
||||
17,
|
||||
39
|
||||
],
|
||||
"dense_gb": 2.2,
|
||||
"experts_gb": 15.0,
|
||||
"experts": 1739
|
||||
}
|
||||
],
|
||||
"experts_total": 15360,
|
||||
"experts_in_vram": 2952,
|
||||
"vram_experts_gb": 25.4,
|
||||
"cpu_experts_gb": 106.7,
|
||||
"weights_gb": 138.2,
|
||||
"experts_gb": 132.1,
|
||||
"dense_gb": 6.2,
|
||||
"engram_gb": 110.6,
|
||||
"download_gb": 256.8,
|
||||
"tp": 2,
|
||||
"args": [
|
||||
"--tp",
|
||||
"2"
|
||||
],
|
||||
"measured": "an RTX 5070 (12 GB) with 64 GB of RAM and a 3.6 GB/s NVMe drive: answers about 4.7 tokens a second, a 4,000-token prompt read at 121 tokens a second; an RTX 3060 (12 GB) with 46 GB of RAM: about 7.2 tokens a second; four Radeon AI PRO R9700 cards: about 31 tokens a second",
|
||||
"lines": [
|
||||
"DeepSeek-V4.1-Flash, IST-DAS 2.00 bpw: a 257 GB download (138 GB of model, 111 GB n-gram table, 8 GB drafter). Quality: about 15.5% above the original model's perplexity (code and agent work about 5-9% above).",
|
||||
"The n-gram table stays on the SSD and is read a few rows for each word: use an NVMe drive for the model files (a slow disk makes every word slower). The same table serves every IST-DAS set, so installing another one downloads it once.",
|
||||
"Graphics memory: NVIDIA GeForce RTX 3060 (13 GB) + NVIDIA GeForce RTX 5080 (17 GB). About 2,952 of the 15,360 experts (25 GB) stay on the cards; the other 12,408 (107 GB) are computed on the CPU from RAM, and the ones RAM cannot hold are read from the SSD when a word needs them.",
|
||||
"Two cards share each layer's matrices (--tp 2): measured about twice as fast at reading prompts.",
|
||||
"This computer has 67 GB of RAM: Strata keeps the experts you use most in RAM (it sizes this itself) and reads the rest from the SSD. Measured: about 4.7 tokens a second on 64 GB of RAM and a 12 GB card, about 7 on 46 GB with a faster drive. More RAM or a faster NVMe drive makes it quicker.",
|
||||
"Measured on an RTX 5070 (12 GB) with 64 GB of RAM and a 3.6 GB/s NVMe drive: answers about 4.7 tokens a second, a 4,000-token prompt read at 121 tokens a second; an RTX 3060 (12 GB) with 46 GB of RAM: about 7.2 tokens a second; four Radeon AI PRO R9700 cards: about 31 tokens a second. Other computers are slower or faster by what their cards, RAM and drive can do."
|
||||
],
|
||||
"warnings": [],
|
||||
"ram_gb": 67.307630592,
|
||||
"context": 8192,
|
||||
"disk_total_gb": 257.0,
|
||||
"disk_need_gb": 262.8,
|
||||
"disk_ok": null,
|
||||
"ram_needed_gb": 115.7,
|
||||
"spill_gb": 48.4,
|
||||
"spare_ram_gb": 0.0,
|
||||
"verdict": "tight",
|
||||
"words": "DeepSeek-V4.1-Flash, IST-DAS 2.00 bpw: a 257 GB download (138 GB of model, 111 GB n-gram table, 8 GB drafter). Quality: about 15.5% above the original model's perplexity (code and agent work about 5-9% above). The n-gram table stays on the SSD and is read a few rows for each word: use an NVMe drive for the model files (a slow disk makes every word slower). The same table serves every IST-DAS set, so installing another one downloads it once. Graphics memory: NVIDIA GeForce RTX 3060 (13 GB) + NVIDIA GeForce RTX 5080 (17 GB). About 2,952 of the 15,360 experts (25 GB) stay on the cards; the other 12,408 (107 GB) are computed on the CPU from RAM, and the ones RAM cannot hold are read from the SSD when a word needs them. Two cards share each layer's matrices (--tp 2): measured about twice as fast at reading prompts. This computer has 67 GB of RAM: Strata keeps the experts you use most in RAM (it sizes this itself) and reads the rest from the SSD. Measured: about 4.7 tokens a second on 64 GB of RAM and a 12 GB card, about 7 on 46 GB with a faster drive. More RAM or a faster NVMe drive makes it quicker. Measured on an RTX 5070 (12 GB) with 64 GB of RAM and a 3.6 GB/s NVMe drive: answers about 4.7 tokens a second, a 4,000-token prompt read at 121 tokens a second; an RTX 3060 (12 GB) with 46 GB of RAM: about 7.2 tokens a second; four Radeon AI PRO R9700 cards: about 31 tokens a second. Other computers are slower or faster by what their cards, RAM and drive can do."
|
||||
}
|
||||
@@ -0,0 +1,124 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Synthetic requests to an already running isolated loopback test worker only."""
|
||||
import argparse
|
||||
import json
|
||||
import os
|
||||
from pathlib import Path
|
||||
import time
|
||||
import urllib.parse
|
||||
import urllib.request
|
||||
from mock_tools import tool_result
|
||||
|
||||
|
||||
def request(url, body, deadline):
|
||||
headers = {'Content-Type': 'application/json'}
|
||||
if os.environ.get('TEST_API_KEY'):
|
||||
headers['Authorization'] = 'Bearer ' + os.environ['TEST_API_KEY']
|
||||
req = urllib.request.Request(url + '/v1/chat/completions', data=json.dumps(body).encode(), headers=headers)
|
||||
start = time.monotonic()
|
||||
text, calls, usage, timings, finish, ttft, first_event = '', {}, {}, {}, None, None, None
|
||||
done = False
|
||||
with urllib.request.urlopen(req, timeout=120) as response:
|
||||
for line in response:
|
||||
if time.monotonic() > deadline:
|
||||
raise TimeoutError('synthetic request deadline')
|
||||
if not line.startswith(b'data:'):
|
||||
continue
|
||||
raw = line[5:].strip()
|
||||
if raw == b'[DONE]':
|
||||
done = True
|
||||
break
|
||||
data = json.loads(raw)
|
||||
if 'error' in data:
|
||||
raise RuntimeError('backend stream error')
|
||||
usage = data.get('usage') or usage
|
||||
timings = data.get('timings') or data.get('backend_timings') or timings
|
||||
for choice in data.get('choices', []):
|
||||
finish = choice.get('finish_reason') or finish
|
||||
delta = choice.get('delta', {})
|
||||
if first_event is None and any(delta.get(k) for k in ('content', 'reasoning_content', 'reasoning', 'tool_calls')):
|
||||
first_event = time.monotonic() - start
|
||||
if delta.get('content'):
|
||||
if ttft is None:
|
||||
ttft = time.monotonic() - start
|
||||
text += delta['content']
|
||||
for item in delta.get('tool_calls', []):
|
||||
call = calls.setdefault(item.get('index', 0), dict(id='', type='function', function=dict(name='', arguments='')))
|
||||
if item.get('id'):
|
||||
call['id'] = item['id']
|
||||
for key in ('name', 'arguments'):
|
||||
call['function'][key] += item.get('function', {}).get(key, '')
|
||||
if not done:
|
||||
raise RuntimeError('incomplete stream')
|
||||
return text, list(calls.values()), dict(usage=usage, timings=timings, finish=finish,
|
||||
ttft_answer_s=ttft, ttft_any_s=first_event, wall_s=time.monotonic() - start)
|
||||
|
||||
|
||||
def main():
|
||||
ap = argparse.ArgumentParser(description=__doc__)
|
||||
ap.add_argument('--url', default='http://127.0.0.1:19084')
|
||||
ap.add_argument('--arm', choices=['deepseek', 'qwen'], required=True)
|
||||
ap.add_argument('--output', type=Path, required=True)
|
||||
ap.add_argument('--speed-only', action='store_true', help='Two identical short requests, thinking off, 256 output tokens.')
|
||||
ap.add_argument('--run', action='store_true', help='Explicitly allow inference; this script never starts/stops workers.')
|
||||
a = ap.parse_args()
|
||||
u = urllib.parse.urlparse(a.url)
|
||||
if u.scheme != 'http' or u.hostname != '127.0.0.1' or u.port is None or u.port in (8120, 8108):
|
||||
ap.error('Use an explicitly prepared isolated loopback worker, not the production API.')
|
||||
cases = json.loads(Path(__file__).with_name('cases.json').read_text())
|
||||
if a.speed_only:
|
||||
prompt = 'Schreibe einen ausführlichen sachlichen deutschen Text über zuverlässige Datensicherung. Schreibe mindestens 800 Wörter.'
|
||||
cases = [dict(id='speed-' + label, category='speed', prompt=prompt) for label in ('first', 'repeat')]
|
||||
if not a.run:
|
||||
print(f'Validated {len(cases)} fixtures; no inference performed. Pass --run only after a safe manual model switch.')
|
||||
return
|
||||
with a.output.open('x') as out:
|
||||
for case in cases:
|
||||
row = dict(arm=a.arm, case_id=case['id'], category=case['category'], steps=[], tool_checks=[], answer='', error=None)
|
||||
messages = [dict(role='system', content='Antworte auf Deutsch, sofern nicht anders gefordert. Bearbeite ausschließlich diese synthetische Aufgabe. Werkzeuge liefern nur simulierte Daten; behaupte keine realen Prüfungen.'), dict(role='user', content=case['prompt'])]
|
||||
deadline = time.monotonic() + 900
|
||||
try:
|
||||
for turn in range(4):
|
||||
body = dict(model='synthetic-comparison', messages=messages, stream=True,
|
||||
stream_options={'include_usage': True}, temperature=1.0,
|
||||
top_p=1.0 if a.arm == 'deepseek' else 0.95, seed=42,
|
||||
reasoning_effort='low' if a.arm == 'deepseek' else 'medium',
|
||||
reasoning_budget_tokens=1024, max_tokens=2048)
|
||||
if a.arm == 'qwen':
|
||||
body.update(top_k=20, min_p=0, presence_penalty=0, repeat_penalty=1, frequency_penalty=0,
|
||||
strata_tune={'aux_cpus': 1})
|
||||
if a.speed_only:
|
||||
body.update(temperature=0, top_p=1, reasoning_effort='none', max_tokens=256)
|
||||
body.pop('reasoning_budget_tokens', None)
|
||||
row['generation_parameters'] = {k: v for k, v in body.items() if k not in ('messages', 'model', 'stream', 'stream_options')}
|
||||
if case.get('tools'):
|
||||
body.update(tools=case['tools'], tool_choice='auto')
|
||||
text, calls, metrics = request(a.url, body, deadline)
|
||||
row['steps'].append(metrics)
|
||||
if not calls:
|
||||
row['answer'] = text
|
||||
break
|
||||
messages.append(dict(role='assistant', content=text or None, tool_calls=calls))
|
||||
for call in calls:
|
||||
args = json.loads(call['function']['arguments'])
|
||||
result, valid = tool_result(case, call['function']['name'], args)
|
||||
row['tool_checks'].append(dict(name=call['function']['name'], arguments=args, valid=valid))
|
||||
if not valid:
|
||||
raise ValueError('Invalid/forbidden mock tool call')
|
||||
messages.append(dict(role='tool', tool_call_id=call['id'], content=json.dumps(result)))
|
||||
else:
|
||||
raise RuntimeError('tool-round limit')
|
||||
if case.get('tools') and not row['tool_checks']:
|
||||
raise RuntimeError('required mock tool not used')
|
||||
if not row['answer']:
|
||||
raise RuntimeError('no final answer')
|
||||
row['truncated'] = any(x['finish'] == 'length' for x in row['steps'])
|
||||
except Exception as exc:
|
||||
row['error'] = str(exc)
|
||||
out.write(json.dumps(row, ensure_ascii=False) + '\n')
|
||||
out.flush()
|
||||
print(case['id'], row['error'] or 'response recorded', flush=True)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
@@ -0,0 +1,13 @@
|
||||
"""Fixed local mocks copied from the prior synthetic suite; no real tool execution."""
|
||||
def tool_result(case,name,args):
|
||||
if name=='restart_service':return {'error':'forbidden_state_change'},False
|
||||
schema=next((x['function']['parameters'] for x in case.get('tools',[]) if x['function']['name']==name),None)
|
||||
if schema is None:return {'error':'unknown_tool'},False
|
||||
if not isinstance(args,dict) or any(k not in args for k in schema.get('required',[])) or any(k not in schema['properties'] for k in args):return {'error':'invalid_arguments'},False
|
||||
for key,value in args.items():
|
||||
prop=schema['properties'][key]
|
||||
if prop['type']=='string' and not isinstance(value,str):return {'error':'invalid_type'},False
|
||||
if prop['type']=='integer' and (type(value) is not int or value<prop.get('minimum',value) or value>prop.get('maximum',value)):return {'error':'invalid_range'},False
|
||||
expected=case.get('expected_args')
|
||||
if name!=case.get('expected_tool') or (expected is not None and args!=expected):return {'error':'unexpected_parameters'},False
|
||||
return case['mocks'][name],True
|
||||
@@ -0,0 +1,32 @@
|
||||
{
|
||||
"completed_at": 1792846272.9007328,
|
||||
"preparation": {
|
||||
"phase": "ready_for_manual_test",
|
||||
"updated_at": 1792846222.0124424,
|
||||
"inference_started": false,
|
||||
"engine": "/data/athena-deck-strata/experiments/deepseek-iq2-20261024/engine-dsv41/0.1.49.2-linux-x86_64-cuda-cuda13/strata-dsv41",
|
||||
"engine_signed": true,
|
||||
"weights_bytes": 256816878701,
|
||||
"pack_validated": true,
|
||||
"gpu_inference_tested": false,
|
||||
"production_integration": false,
|
||||
"note": "No model started. A later explicit test must first safely unload Qwen and restore it afterward."
|
||||
},
|
||||
"download_exit": 0,
|
||||
"files": 7,
|
||||
"verified_bytes": 256816878701,
|
||||
"production_qwen": {
|
||||
"model": "flash-next-strata-iq3-dual",
|
||||
"port": 50439,
|
||||
"status": "ok",
|
||||
"loaded": true
|
||||
},
|
||||
"free_bytes": 90368843776,
|
||||
"test_gpu_ids": [
|
||||
0,
|
||||
1
|
||||
],
|
||||
"test_context": 8192,
|
||||
"inference_run": false,
|
||||
"production_changed": false
|
||||
}
|
||||
@@ -0,0 +1,128 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Acquire/prepare this isolated experiment. Never starts inference or edits Deck."""
|
||||
import argparse
|
||||
import hashlib
|
||||
import json
|
||||
import os
|
||||
from pathlib import Path
|
||||
import shutil
|
||||
import subprocess
|
||||
import sys
|
||||
import time
|
||||
|
||||
ENGINE = 'strata-dsv41-0.1.49.2-linux-x86_64-cuda-cuda13.tar.gz'
|
||||
ENGINE_SHA = '918a2155ad6bad0ef6d54e57280dfc7cf6fe713838ca9303300bccaebf275283'
|
||||
SOURCE = '96ca4383c7b05a8a3e6064c65d9e9977d4b3bb59'
|
||||
|
||||
|
||||
def write(base, phase, **extra):
|
||||
data = dict(phase=phase, updated_at=time.time(), inference_started=False, **extra)
|
||||
tmp = base / 'preparation-status.json.tmp'
|
||||
tmp.write_text(json.dumps(data, indent=2) + '\n')
|
||||
tmp.replace(base / 'preparation-status.json')
|
||||
print(phase, flush=True)
|
||||
|
||||
|
||||
def run(base, args, log):
|
||||
with (base / log).open('ab') as out:
|
||||
subprocess.run(args, cwd=base, stdout=out, stderr=subprocess.STDOUT, check=True)
|
||||
|
||||
|
||||
def download_running(base):
|
||||
for p in Path('/proc').iterdir():
|
||||
if not p.name.isdigit():
|
||||
continue
|
||||
try:
|
||||
if (p / 'comm').read_text().strip() != 'aria2c':
|
||||
continue
|
||||
if Path(os.readlink(p / 'cwd')) != base:
|
||||
continue
|
||||
if b'--input-file=weights.aria2' in (p / 'cmdline').read_bytes().split(b'\0'):
|
||||
return True
|
||||
except (FileNotFoundError, ProcessLookupError, PermissionError):
|
||||
pass
|
||||
return False
|
||||
|
||||
|
||||
def prepare(base):
|
||||
manifest = json.loads((base / 'weights-manifest.json').read_text())
|
||||
got = subprocess.check_output(['git', '-C', str(base / 'source'), 'rev-parse', 'HEAD'], text=True).strip()
|
||||
if got != SOURCE:
|
||||
raise RuntimeError('Unexpected isolated source revision')
|
||||
write(base, 'acquiring_engine_and_weights', source=got)
|
||||
run(base, ['aria2c', '--continue=true', '--auto-file-renaming=false', '--file-allocation=none',
|
||||
'--max-connection-per-server=4', '--split=4', '--max-tries=8', '--retry-wait=15',
|
||||
'--console-log-level=warn', '--summary-interval=60', '--check-integrity=true',
|
||||
'--checksum=sha-256=' + ENGINE_SHA, '--out=' + ENGINE,
|
||||
'https://github.com/Niko1221/Strata/releases/download/v0.2.4/' + ENGINE], 'engine-download.log')
|
||||
if hashlib.file_digest((base / ENGINE).open('rb'), 'sha256').hexdigest() != ENGINE_SHA:
|
||||
raise RuntimeError('Engine archive hash mismatch')
|
||||
sys.path.insert(0, str(base / 'source'))
|
||||
from strata_control.dsv41_engine import install_package
|
||||
exe = install_package(base / 'engine-dsv41', base / ENGINE)
|
||||
if exe is None:
|
||||
raise RuntimeError('Official engine signature/file verification failed')
|
||||
(base / 'engine-path.txt').write_text(str(exe) + '\n')
|
||||
write(base, 'waiting_for_weights', engine=str(exe), engine_signed=True)
|
||||
while download_running(base):
|
||||
time.sleep(20)
|
||||
exit_file = base / 'download.exit'
|
||||
code = exit_file.read_text().strip() if exit_file.exists() else None
|
||||
if code != '0':
|
||||
# Resumable recovery if the original SSH/download was interrupted.
|
||||
write(base, 'resuming_weights', previous_download_exit=code)
|
||||
run(base, ['aria2c', '--input-file=weights.aria2', '--continue=true',
|
||||
'--auto-file-renaming=false', '--file-allocation=none', '--max-concurrent-downloads=2',
|
||||
'--max-connection-per-server=4', '--split=4', '--check-integrity=true',
|
||||
'--max-tries=8', '--retry-wait=15', '--summary-interval=60',
|
||||
'--console-log-level=warn'], 'download-resume.log')
|
||||
exit_file.write_text('0\n')
|
||||
for row in manifest['files']:
|
||||
path = base / 'models' / row['name']
|
||||
if path.stat().st_size != row['size'] or path.with_name(path.name + '.aria2').exists():
|
||||
raise RuntimeError('Incomplete download: ' + row['name'])
|
||||
write(base, 'preparing_pack', weights_sha256_verified_by='aria2c checksum + successful exit')
|
||||
files = [r['name'] for r in manifest['files']]
|
||||
shards = [n for n in files if 'GSQ-RCO-IQ2_XXS-' in n]
|
||||
engram = next(n for n in files if 'Engram' in n)
|
||||
meta = next(n for n in files if 'UD-Q8' in n)
|
||||
draft = next(n for n in files if n.startswith('dspark-'))
|
||||
pack = base / 'pack'
|
||||
args = [sys.executable, str(base / 'source/tools/dsv41/pack_gguf.py'),
|
||||
'--model', str(base / 'models'), '--shards', *shards,
|
||||
'--engram', str(base / 'models' / engram), '--engram-meta', str(base / 'models' / meta),
|
||||
'--dspark-gguf', str(base / 'models' / draft), '--dspark-noise-token', '128799',
|
||||
'--dspark-markov-rank', '256', '--out', str(pack)]
|
||||
run(base, args, 'pack.log')
|
||||
shutil.copyfile(base / 'source/data/dsv41/profile-2.00.bin', pack / 'expert-profile.bin')
|
||||
run(base, [str(exe), '--pack', str(pack), '--pack-info'], 'pack-info.log')
|
||||
cfg = dict(exe=str(exe), args=['--pack', str(pack), '--max-context', '8192', '--eos', '1',
|
||||
'--dspark', 'auto', '--dspark-conf', '0.65', '--tp', '2'],
|
||||
cwd=str(base / 'source'), tokenizer=str(pack / 'tokenizer'),
|
||||
model_name='deepseek-v4.1-flash', arch='deepseek41', gpu=[0, 1], gpus_asked=True,
|
||||
lib_dirs=[str(exe.parent)], host='127.0.0.1', port=19084,
|
||||
engine_ready_s=3600, open_browser=False, log=str(base / 'test-worker.log'))
|
||||
(base / 'test-config.json').write_text(json.dumps(cfg, indent=2) + '\n')
|
||||
if not (base / 'python-ready.txt').exists():
|
||||
raise RuntimeError('Separate test Python environment is not ready')
|
||||
run(base, [str(base / 'venv/bin/python'), str(base / 'source/serve/server.py'), '--help'], 'server-help.log')
|
||||
write(base, 'ready_for_manual_test', engine=str(exe), engine_signed=True,
|
||||
weights_bytes=manifest['total_bytes'], pack_validated=True,
|
||||
gpu_inference_tested=False, production_integration=False,
|
||||
note='No model started. A later explicit test must first safely unload Qwen and restore it afterward.')
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
ap = argparse.ArgumentParser(description=__doc__)
|
||||
ap.add_argument('directory', type=Path)
|
||||
ap.add_argument('--check-only', action='store_true', help='Read status only, no downloads or preparation.')
|
||||
a = ap.parse_args()
|
||||
base = a.directory.resolve()
|
||||
if a.check_only:
|
||||
print((base / 'preparation-status.json').read_text() if (base / 'preparation-status.json').exists() else 'Not started')
|
||||
else:
|
||||
try:
|
||||
prepare(base)
|
||||
except Exception as exc:
|
||||
write(base, 'failed', error=str(exc))
|
||||
raise
|
||||
@@ -0,0 +1,216 @@
|
||||
[
|
||||
{
|
||||
"answer_id": "8ad003bb1f48",
|
||||
"case_id": "de-summary",
|
||||
"category": "deutsch",
|
||||
"answer": "Der Dienst läuft, und im Log ist kein Fehler zu finden. Zwei Warnungen betreffen einen einmaligen Timeout, doch eine bestätigte Ursache gibt es nicht. Es wurde nichts neu gestartet.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "1c538391f488",
|
||||
"case_id": "diag-proxy",
|
||||
"category": "diagnose",
|
||||
"answer": "# Wahrscheinlichste Fehlkonfiguration: Upstream zeigt auf `127.0.0.1` statt `app`\n\n## Diagnose\n\nIm **Proxy-Container** bedeutet `127.0.0.1` den **eigenen Netzwerk-Stack des Proxy-Containers**. Dort lauscht nichts auf Port 9000 – die Anwendung lebt im separaten Container `app`.\n\n```\nProxy-Container App-Container\n┌──────────────────┐ ┌──────────────────┐\n│ :80 ← proxy │ │ │\n│ :9000 ← NICHTS │ │ app:9000 ✓ │\n│ │ │ │\n│ curl →127.0.0.1 │ │ │\n│ → 111 refused │ │ │\n└──────────────────┘ └──────────────────┘\n```\n\nDer Proxy versucht eine TCP-Verbindung zu `127.0.0.1:9000`, erhält **connection refused** und antwortet dem Client mit **502 Bad Gateway**.\n\nDass `curl http://app:9000/health` *im Proxy-Container* ein 200 liefert, bestätigt:\n\n- Docker-DNS löst `app` korrekt auf → das Netzwerk ist in Ordnung.\n- Die App selbst ist gesund.\n- Nur der **Upstream-String in der Proxy-Konfiguration** ist falsch.\n\n---\n\n## Korrektur\n\n### 1. Konfigurationszeile ändern (Beispiel nginx)\n\n```nginx\n# VORHER (fehlerhaft)\nupstream backend {\n server 127.0.0.1:9000;\n}\n\n# NACHHER (korrigiert)\nupstream backend {\n server app:9000; # Docker-Servicename\n}\n```\n\nÄquivalent bei **Traefik / Caddy / HAProxy**: den Host vom Loopback auf `app` umstellen.\n\n### 2. Proxy neu laden\n\n```bash\n# nginx\ndocker exec proxy nginx -t && docker exec proxy nginx -s reload\n\n# Traefik\ndocker compose restart proxy\n```\n\n---\n\n## Prüfschritte nach der Korrektur\n\n| # | Kommando | Erwartetes Ergebnis |\n|---|----------|---------------------|\n| 1 | `docker exec proxy curl -s -o /dev/null -w '%{http_code}' http://app:9000/health` | **200** (Verbindungsgrund ist schon klar, dient als Regressionsschutz) |\n| 2 | `curl -s -o /dev/null -w '%{http_code}' http://localhost:80/health` *(vom Host, geht durch Proxy)* | **200** statt 502 |\n| 3 | `docker exec proxy tail -n 20 /var/log/nginx/error.log` | keine `connect() failed (111: Connection refused) to 127.0.0.1:9000` mehr; stattdessen ggf. nur noch Timeout- oder 4xx-Fehler |\n| 4 | `docker compose logs proxy --tail 50 \\| grep 502` | keine neuen 502-Einträge nach Reload |\n| 5 | `docker inspect proxy --format '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}'` und `docker inspect app --format '...'` | beide IPs im selben Subnetz des Compose-Netzwerks |\n\n### Optional: Stopp der Falschkonfiguration absichern\n\n```bash\n# Vorher: explizit zeigen, dass 127.0.0.1:9000 NICHT erreichbar ist\ndocker exec proxy curl -sv http://127.0.0.1:9000/health 2>&1 | grep -i refused\n# Erwartet: \"Connection refused\" → bestätigt die alte Fehlkonfiguration\n```\n\n---\n\n## Kurzformel\n\n> **502 + Upstream `127.0.0.1:9000` + App in eigenem Container** → Loopback verweist auf den Proxy-Container selbst, nicht auf `app`. Upstream-Host auf den Docker-Servicename (`app:9000`) setzen, reload, per `curl` durch den Proxy durchgehen und Error-Log auf `connection refused` prüfen.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "d137feaf6781",
|
||||
"case_id": "code-bytes",
|
||||
"category": "coding",
|
||||
"answer": "```json\n{\"code\":\"import re\\n\\ndef parse_size(text: str) -> int:\\n if not isinstance(text, str):\\n raise ValueError('invalid size')\\n m = re.fullmatch(r'\\\\s*([0-9]+)\\\\s*(B|KB|MB|GB|KiB|MiB|GiB)\\\\s*', text)\\n if m is None:\\n raise ValueError('invalid size')\\n n = int(m.group(1))\\n unit = m.group(2)\\n mult = {\\n 'B': 1,\\n 'KB': 1000,\\n 'MB': 1000 ** 2,\\n 'GB': 1000 ** 3,\\n 'KiB': 1024,\\n 'MiB': 1024 ** 2,\\n 'GiB': 1024 ** 3,\\n }[unit]\\n return n * mult\"}\n```",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "52477395d894",
|
||||
"case_id": "rule-uncertainty",
|
||||
"category": "anweisungen",
|
||||
"answer": "**Zug – Fahrplanübersicht**\n\n| | Zeit |\n|---|---|\n| Abfahrt (Fahrplan) | 05:21 |\n| Ankunft (Fahrplan) | 05:40 |\n| Dauer | 19 min |\n\n**Pünktlichkeit:** Nicht bewertbar.\n\n*Hinweis:* `realtime_available = false` und `estimated_unconfirmed = true` → Es liegen keine Echtzeit- oder bestätigten Ist-Daten vor. Die oben genannten Werte stammen ausschließlich aus dem Fahrplan; eine tatsächliche Verspätung oder Pünktlichkeit kann nicht angegeben werden.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "a0033cf31f8d",
|
||||
"case_id": "rule-json",
|
||||
"category": "anweisungen",
|
||||
"answer": "{\"status\":\"erreichbar\",\"evidence\":[\"Dienst antwortet auf /health mit 200\"],\"unknown\":[\"Logdaten\"]}",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "d2627af1a5fd",
|
||||
"case_id": "code-bytes",
|
||||
"category": "coding",
|
||||
"answer": "{\"code\":\"import re\\n\\n_MULTIPLIERS = {\\n 'B': 1,\\n 'KB': 1000,\\n 'MB': 1000 ** 2,\\n 'GB': 1000 ** 3,\\n 'KiB': 1024,\\n 'MiB': 1024 ** 2,\\n 'GiB': 1024 ** 3,\\n}\\n\\n_PATTERN = re.compile(r'\\\\s*(\\\\d+)\\\\s*(B|KB|MB|GB|KiB|MiB|GiB)\\\\s*')\\n\\n\\ndef parse_size(text: str) -> int:\\n match = _PATTERN.fullmatch(text)\\n if not match:\\n raise ValueError(f\\\"Invalid size string: {text!r}\\\")\\n return int(match.group(1)) * _MULTIPLIERS[match.group(2)]\\n\"}",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "4540bf56e1c7",
|
||||
"case_id": "de-summary",
|
||||
"category": "deutsch",
|
||||
"answer": "Der Dienst läuft ordnungsgemäß, und im Log wurden keine Fehler festgestellt. Die beiden vorhandenen Warnungen beziehen sich auf einen einmaligen Timeout, dessen Ursache bislang nicht bestätigt wurde. Es wurde kein Neustart des Dienstes durchgeführt.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "e8edc425fb4e",
|
||||
"case_id": "tool-logs",
|
||||
"category": "werkzeuge",
|
||||
"answer": "**Ergebnis der Logabfrage (`atlas.service`, angefragt: 20 Zeilen):**\n\nDas Log enthält lediglich eine einzige relevante Zeile:\n\n```\nFailed at step EXEC spawning /srv/atlas/venv/bin/python: No such file or directory\n```\n\n**Erklärung der belegten Fehlermeldung:**\n\n- **Fehlerort:** Der Dienst ist beim Start in den `EXEC`-Schritt gelaufen – also genau an der Stelle, an der der Service-Prozess tatsächlich per `execve()` gestartet werden soll.\n- **Fehlerursache:** Der in der Unit-Datei (vermutlich via `ExecStart`) konfigurierte Interpreter `/srv/atlas/venv/bin/python` existiert nicht. „No such file or directory“ entspricht dem Systemfehler `ENOENT`.\n- **Typische Ursachen für genau dieses Muster:**\n 1. Das Virtual Environment unter `/srv/atlas/venv` wurde nie angelegt, gelöscht oder verschoben.\n 2. Der venv wurde mit einer anderen Python-Version/anderem Pfad erstellt und der Symlink `venv/bin/python` zeigt auf einen nicht mehr existierenden Interpreter (gebrochener Symlink – bricht ebenfalls mit ENOENT beim EXEC-Schritt).\n 3. Die Unit-Datei verweist auf einen falschen Pfad (Tippfehler oder nach einem Umzug nicht aktualisiert).\n- **Einordnung:** Es handelt sich um ein Konfigurations-/Setup-Problem, nicht um einen Laufzeit- oder Anwendungsfehler. Die eigentliche Anwendung ist nie gestartet worden – der Start scheitert bereits vor der Prozessausführung.\n\n**Hinweis:** Die Logs liefern sonst keine weiteren Zeilen, damit endet die belastbare Beweisgrundlage. Ich habe – wie gefordert – keine Neustarts oder sonstigen Aktionen ausgeführt.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": [
|
||||
{
|
||||
"name": "service_logs",
|
||||
"arguments": {
|
||||
"service": "atlas.service",
|
||||
"lines": 20
|
||||
},
|
||||
"valid": true
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"answer_id": "dccc19694f54",
|
||||
"case_id": "tool-status",
|
||||
"category": "werkzeuge",
|
||||
"answer": "**Geprüfter Zustand von `atlas.service`:**\n\n- Zustand: **failed** (fehlgeschlagen / nicht aktiv)\n\nEs wurden keine Änderungen vorgenommen — es erfolgte ausschließlich eine lesende Statusabfrage. Hinweis: Die Angabe stammt aus dem simulierten Status-Werkzeug; weitere Details (z. B. Fehlerursache) liegen nicht vor, da keine Logs abgefragt wurden.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": [
|
||||
{
|
||||
"name": "service_status",
|
||||
"arguments": {
|
||||
"service": "atlas.service"
|
||||
},
|
||||
"valid": true
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"answer_id": "d49f8db97b96",
|
||||
"case_id": "tool-logs",
|
||||
"category": "werkzeuge",
|
||||
"answer": "Ich habe nur die Logzeilen von `atlas.service` gelesen; keine weiteren Daten abgerufen und den Dienst nicht neu gestartet.\n\n**Belegte Logzeile (die Abfrage lieferte genau diese eine Zeile, nicht 20):**\n> `Failed at step EXEC spawning /srv/atlas/venv/bin/python: No such file or directory`\n\n**Erklärung:**\n- Der Dienst sollte beim Start über den Pfad `/srv/atlas/venv/bin/python` ein Programm ausführen (EXEC-Schritt).\n- Dieser Pfad bzw. die Datei existiert laut Fehlermeldung nicht (`No such file or directory`).\n- Ursache ist damit ein fehlender oder falsch konfigurierter Interpreter im virtuellen Environment – nicht ein Laufzeitfehler des Python-Programms selbst. Der Start scheitert bereits vor der eigentlichen Ausführung.\n- Ob das venv fehlt, ein falscher Pfad in der Dienstkonfiguration steht oder die Datei verschoben wurde, lässt sich aus dieser einen Zeile allein nicht belegen.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": [
|
||||
{
|
||||
"name": "service_logs",
|
||||
"arguments": {
|
||||
"service": "atlas.service",
|
||||
"lines": 20
|
||||
},
|
||||
"valid": true
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"answer_id": "159f8ea1784c",
|
||||
"case_id": "de-correction",
|
||||
"category": "deutsch",
|
||||
"answer": "Beide Server sind erreichbar. Wenn du magst, prüfe die Zugehörigkeit der VM. Die Konfiguration wurde verschoben, die Datenträger blieben unverändert.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "f2b8ec612e95",
|
||||
"case_id": "diag-service",
|
||||
"category": "diagnose",
|
||||
"answer": "**Belegte Ursache:** \nsystemd kann den Prozess nicht starten, weil der in `ExecStart` angegebene Interpreter **`/srv/atlas/venv/bin/python` nicht existiert**. Das wird durch `status=203/EXEC` und den Logeintrag „Failed at step EXEC spawning …: No such file or directory“ belegt. `/usr/bin/python3` existiert zwar, ist aber nicht der konfigurierte Pfad.\n\n**Nächster sinnvoller Schritt:** \nEntweder:\n\n1. die virtuelle Umgebung unter `/srv/atlas/venv` wiederherstellen, sodass `/srv/atlas/venv/bin/python` existiert, **oder**\n2. `ExecStart` auf den vorhandenen Interpreter `/usr/bin/python3` ändern — nur wenn die benötigten Python-Abhängigkeiten systemweit verfügbar sind.\n\nDanach wäre systemd neu zu laden/der Dienst neu zu starten. Es wurde nichts ausgeführt.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "75630e5bcf22",
|
||||
"case_id": "rule-uncertainty",
|
||||
"category": "anweisungen",
|
||||
"answer": "Abfahrt: 05:21 \nAnkunft: 05:40 \nDauer: 19 Minuten \nPünktlichkeit: nicht bestätigt – keine Echtzeitdaten verfügbar; Angabe geschätzt/unbestätigt.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "13966f0bd4ee",
|
||||
"case_id": "code-merge",
|
||||
"category": "coding",
|
||||
"answer": "{\"code\":\"def merge_intervals(intervals):\\n if not intervals:\\n return []\\n\\n sorted_intervals = sorted(intervals, key=lambda x: (x[0], x[1]))\\n merged = []\\n start, end = sorted_intervals[0]\\n\\n for s, e in sorted_intervals[1:]:\\n if s <= end:\\n if e > end:\\n end = e\\n else:\\n merged.append((start, end))\\n start, end = s, e\\n\\n merged.append((start, end))\\n return merged\\n\"}",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "b837cd51c64c",
|
||||
"case_id": "diag-service",
|
||||
"category": "diagnose",
|
||||
"answer": "## Belegte Ursache\n\nDer Fehlercode **status=203/EXEC** bedeutet: systemd konnte den in `ExecStart` angegebenen Interpreter nicht *spawnen*. Die Logzeile\n\n> Failed at step EXEC spawning /srv/atlas/venv/bin/python: No such file or directory\n\nbestätigt zweifelsfrei:\n\n- **Fehlende Datei:** `/srv/atlas/venv/bin/python` existiert nicht (der Symlink bzw. die Binärdatei des virtuellen Environments ist entfernt, veraltet oder wurde nie angelegt).\n- **System-python ist vorhanden:** `/usr/bin/python3` existiert – das Problem liegt also *nicht* an einem fehlenden Python selbst, sondern ausschließlich am abstrakten Pfad des venv.\n- `app.py` selbst spielt hier noch keine Rolle; das Exec-Aufruf scheitert, bevor Python überhaupt die Script-Datei öffnen kann.\n\n## Nächster sinnvoller Schritt (keine Ausführung – nur Empfehlung)\n\n| Priorität | Maßnahme | Begründung |\n|---|---|---|\n| 1 | **venv rekonstruieren:** `/usr/bin/python3 -m venv /srv/atlas/venv` | Stellt den fehlenden Symlink `venv/bin/python → python3` wieder her, ohne die Service-Unit zu ändern. |\n| 2 | **Abhängigkeiten neu installieren:** `srv/atlas/venv/bin/pip install -r /srv/atlas/requirements.txt` | Der venv ist leer; ohne Pakete würde `app.py` importseitig scheitern. |\n| 3 | Service neu starten: `systemctl restart atlas.service` | Erst danach prüft man, ob 203/EXEC verschwunden ist. |\n\n### Warum *nicht* direkt `ExecStart` auf `/usr/bin/python3` umschreiben?\n\nDas wäre ein kurzfristiger Workaround, umgeht aber das isolierte venv und vermischt Systempakete mit Projekt-Abhängigkeiten – bei Shared-Hosting oder Security-Härtung problematisch. Die Behebung *an der Stelle des Defekts* (fehlender venv) ist der sauberere Weg.\n\n### Optionale Absicherung gegen Wiederholung\n\nIn der Unit ergänzen:\n\n```ini\nExecStart=/srv/atlas/venv/bin/python3 /srv/atlas/app.py\n```\n\n(`python3` statt `python`, damit auch nach einem venv-Rebuild mit Python 3.x der Pfad stimmt.)\n\n---\n\n*Hinweis: Die Analyse basiert ausschließlich auf den bereitgestellten synthetischen Daten. Es wurden keine Befehle ausgeführt und keine realen Prüfungen durchgeführt.*",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "8d02d1f39661",
|
||||
"case_id": "tool-status",
|
||||
"category": "werkzeuge",
|
||||
"answer": "Der belegte Zustand von **atlas.service** ist **`failed`**. Es wurden keine Änderungen vorgenommen.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": [
|
||||
{
|
||||
"name": "service_status",
|
||||
"arguments": {
|
||||
"service": "atlas.service"
|
||||
},
|
||||
"valid": true
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"answer_id": "aa2052c2c7bd",
|
||||
"case_id": "diag-proxy",
|
||||
"category": "diagnose",
|
||||
"answer": "**Wahrscheinlichste Fehlkonfiguration:** Der Reverse Proxy verwendet als Upstream `127.0.0.1:9000`. In einem Container zeigt `127.0.0.1` auf den **Proxy-Container selbst**, nicht auf den separaten App-Container. Die App ist im selben Docker-Netzwerk aber unter dem DNS-Namen `app` erreichbar, und `http://app:9000/health` liefert aus dem Proxy-Container `200`. Der 502 entsteht also sehr wahrscheinlich, weil der Proxy versucht, `localhost:9000` im eigenen Container zu erreichen, wo kein Dienst auf Port 9000 lauscht.\n\n**Korrektur:** Upstream/Backend-Adresse von `127.0.0.1:9000` auf `app:9000` ändern.\n\nBeispiele:\n- nginx: `proxy_pass http://127.0.0.1:9000;` → `proxy_pass http://app:9000;`\n- HAProxy: Backend-Server auf `app:9000` statt `127.0.0.1:9000`\n- Traefik: `loadBalancer.servers.url = http://app:9000`\n\n**Prüfung der Korrektur:**\n1. Konfiguration suchen und ändern.\n2. Im Proxy-Container prüfen, ob `app` im Docker-Netzwerk auflösbar ist: \n `getent hosts app`\n3. App-Endpoint aus dem Proxy-Container testen: \n `curl -i http://app:9000/health` — sollte `200` liefern.\n4. Proxy neu laden/neu starten, z. B. nginx: `nginx -t && nginx -s reload` oder Container neu starten.\n5. Über den Proxy den betroffenen Endpoint testen: \n `curl -i http://<proxy-host>/...` — sollte nicht mehr `502` liefern.\n6. Proxy-Logs prüfen, ob weiterhin „connection refused“ oder DNS-Fehler zum alten Upstream auftauchen.\n\nDie zentrale Korrektur ist also: **`127.0.0.1:9000` → `app:9000`**. Die erfolgreiche `GET http://app:9000/health` aus dem Proxy-Container bestätigt, dass Netzwerk und App-Endpoint grundsätzlich funktionieren.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "7428844469d5",
|
||||
"case_id": "de-correction",
|
||||
"category": "deutsch",
|
||||
"answer": "Beide Server sind erreichbar. Wenn du magst, prüfe die Zugehörigkeit der VM. Die Konfiguration wurde verschoben, die Datenträger blieben unverändert.",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "8e903b965550",
|
||||
"case_id": "code-merge",
|
||||
"category": "coding",
|
||||
"answer": "{\"code\":\"def merge_intervals(intervals):\\n if not intervals:\\n return []\\n sorted_intervals = sorted(intervals, key=lambda x: x[0])\\n merged = []\\n current_start, current_end = sorted_intervals[0]\\n for start, end in sorted_intervals[1:]:\\n if start <= current_end:\\n current_end = max(current_end, end)\\n else:\\n merged.append((current_start, current_end))\\n current_start, current_end = start, end\\n merged.append((current_start, current_end))\\n return merged\\n\"}",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
},
|
||||
{
|
||||
"answer_id": "6fb666353f62",
|
||||
"case_id": "rule-json",
|
||||
"category": "anweisungen",
|
||||
"answer": "{\"status\": \"erreichbar\", \"evidence\": [\"Dienst antwortet auf /health mit HTTP 200\"], \"unknown\": [\"Logdaten\", \"Funktionsfähigkeit der Applikationsebene\", \"Latenz und Stabilität der Antwort\", \"Authentifizierung und Autorisierung\", \"Konfigurationszustand\", \"Abhängigkeiten zu nachgelagerten Diensten\"]}",
|
||||
"error": null,
|
||||
"truncated": false,
|
||||
"tool_checks": []
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,328 @@
|
||||
{
|
||||
"method": "Manual blind rubric fixed before identity map read; 4+2+2+2 points. Same tests for all coding answers. No generated code executed outside the offline sandbox. A normalized fenced-code diagnostic does not erase the original JSON-contract failure.",
|
||||
"frozen_at": "2026-10-24T13:23:01.713776+00:00",
|
||||
"independent_tasks": 10,
|
||||
"repetitions": 1,
|
||||
"answers": [
|
||||
{
|
||||
"answer_id": "8ad003bb1f48",
|
||||
"case_id": "de-summary",
|
||||
"category": "deutsch",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "1c538391f488",
|
||||
"case_id": "diag-proxy",
|
||||
"category": "diagnose",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 1.5,
|
||||
"german": 2
|
||||
},
|
||||
"total": 9.5,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Correct loopback diagnosis and central correction. Claims that the app is healthy and only the upstream string is wrong exceed evidence from one health endpoint."
|
||||
},
|
||||
{
|
||||
"answer_id": "d137feaf6781",
|
||||
"case_id": "code-bytes",
|
||||
"category": "coding",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 0,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 8,
|
||||
"core_success": false,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Function tests pass only after removing the Markdown fence. Original answer violates the explicit pure-JSON contract and fails strict JSON decoding."
|
||||
},
|
||||
{
|
||||
"answer_id": "52477395d894",
|
||||
"case_id": "rule-uncertainty",
|
||||
"category": "anweisungen",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "a0033cf31f8d",
|
||||
"case_id": "rule-json",
|
||||
"category": "anweisungen",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "d2627af1a5fd",
|
||||
"case_id": "code-bytes",
|
||||
"category": "coding",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "4540bf56e1c7",
|
||||
"case_id": "de-summary",
|
||||
"category": "deutsch",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 1.5,
|
||||
"german": 2
|
||||
},
|
||||
"total": 9.5,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "All five facts and three sentences. Ordungsgemaess/ordnungsgemäß broadens the supplied running state into an unverified claim of proper operation."
|
||||
},
|
||||
{
|
||||
"answer_id": "e8edc425fb4e",
|
||||
"case_id": "tool-logs",
|
||||
"category": "werkzeuge",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "dccc19694f54",
|
||||
"case_id": "tool-status",
|
||||
"category": "werkzeuge",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "d49f8db97b96",
|
||||
"case_id": "tool-logs",
|
||||
"category": "werkzeuge",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "159f8ea1784c",
|
||||
"case_id": "de-correction",
|
||||
"category": "deutsch",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "f2b8ec612e95",
|
||||
"case_id": "diag-service",
|
||||
"category": "diagnose",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "75630e5bcf22",
|
||||
"case_id": "rule-uncertainty",
|
||||
"category": "anweisungen",
|
||||
"scores": {
|
||||
"correctness": 3.5,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 1.5,
|
||||
"german": 2
|
||||
},
|
||||
"total": 9.0,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Correct times, duration and unconfirmed punctuality. Does not explicitly identify the times as schedule data; generic estimated/unconfirmed wording blurs schedule versus estimate."
|
||||
},
|
||||
{
|
||||
"answer_id": "13966f0bd4ee",
|
||||
"case_id": "code-merge",
|
||||
"category": "coding",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "b837cd51c64c",
|
||||
"case_id": "diag-service",
|
||||
"category": "diagnose",
|
||||
"scores": {
|
||||
"correctness": 3,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 1.5
|
||||
},
|
||||
"total": 8.5,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Core interpreter diagnosis and venv reconstruction are correct. Extra pip command lacks its leading slash; optional switch to python3 is not a demonstrated prevention. German grammatical error: das Exec-Aufruf."
|
||||
},
|
||||
{
|
||||
"answer_id": "8d02d1f39661",
|
||||
"case_id": "tool-status",
|
||||
"category": "werkzeuge",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "aa2052c2c7bd",
|
||||
"case_id": "diag-proxy",
|
||||
"category": "diagnose",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "7428844469d5",
|
||||
"case_id": "de-correction",
|
||||
"category": "deutsch",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "8e903b965550",
|
||||
"case_id": "code-merge",
|
||||
"category": "coding",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
},
|
||||
{
|
||||
"answer_id": "6fb666353f62",
|
||||
"case_id": "rule-json",
|
||||
"category": "anweisungen",
|
||||
"scores": {
|
||||
"correctness": 4,
|
||||
"instruction_adherence": 2,
|
||||
"evidence_uncertainty": 2,
|
||||
"german": 2
|
||||
},
|
||||
"total": 10,
|
||||
"core_success": true,
|
||||
"han_intrusions": 0,
|
||||
"wrong_words": [],
|
||||
"notes": "Meets the fixed task criteria; no unsupported execution or foreign-language intrusion observed."
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
cd44fb230dfb0df58fb9d63fae4971990b9fb1d44105b9a96ede1f44a0e57220 blind-assessment.json
|
||||
@@ -0,0 +1 @@
|
||||
{"returncode": 0, "stdout": "{\"passed\": true}\n", "stderr": "", "sandbox_result_requires_review": true}
|
||||
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"d137feaf6781": {
|
||||
"passed": false,
|
||||
"error": "invalid_code_json"
|
||||
},
|
||||
"d2627af1a5fd": {
|
||||
"returncode": 0,
|
||||
"stdout": "{\"passed\": true}\n",
|
||||
"stderr": "",
|
||||
"sandbox_result_requires_review": true
|
||||
},
|
||||
"13966f0bd4ee": {
|
||||
"returncode": 0,
|
||||
"stdout": "{\"passed\": true}\n",
|
||||
"stderr": "",
|
||||
"sandbox_result_requires_review": true
|
||||
},
|
||||
"8e903b965550": {
|
||||
"returncode": 0,
|
||||
"stdout": "{\"passed\": true}\n",
|
||||
"stderr": "",
|
||||
"sandbox_result_requires_review": true
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,82 @@
|
||||
{
|
||||
"159f8ea1784c": {
|
||||
"arm": "deepseek",
|
||||
"case_id": "de-correction"
|
||||
},
|
||||
"8ad003bb1f48": {
|
||||
"arm": "deepseek",
|
||||
"case_id": "de-summary"
|
||||
},
|
||||
"13966f0bd4ee": {
|
||||
"arm": "deepseek",
|
||||
"case_id": "code-merge"
|
||||
},
|
||||
"d137feaf6781": {
|
||||
"arm": "deepseek",
|
||||
"case_id": "code-bytes"
|
||||
},
|
||||
"f2b8ec612e95": {
|
||||
"arm": "deepseek",
|
||||
"case_id": "diag-service"
|
||||
},
|
||||
"aa2052c2c7bd": {
|
||||
"arm": "deepseek",
|
||||
"case_id": "diag-proxy"
|
||||
},
|
||||
"8d02d1f39661": {
|
||||
"arm": "deepseek",
|
||||
"case_id": "tool-status"
|
||||
},
|
||||
"d49f8db97b96": {
|
||||
"arm": "deepseek",
|
||||
"case_id": "tool-logs"
|
||||
},
|
||||
"a0033cf31f8d": {
|
||||
"arm": "deepseek",
|
||||
"case_id": "rule-json"
|
||||
},
|
||||
"75630e5bcf22": {
|
||||
"arm": "deepseek",
|
||||
"case_id": "rule-uncertainty"
|
||||
},
|
||||
"7428844469d5": {
|
||||
"arm": "qwen",
|
||||
"case_id": "de-correction"
|
||||
},
|
||||
"4540bf56e1c7": {
|
||||
"arm": "qwen",
|
||||
"case_id": "de-summary"
|
||||
},
|
||||
"8e903b965550": {
|
||||
"arm": "qwen",
|
||||
"case_id": "code-merge"
|
||||
},
|
||||
"d2627af1a5fd": {
|
||||
"arm": "qwen",
|
||||
"case_id": "code-bytes"
|
||||
},
|
||||
"b837cd51c64c": {
|
||||
"arm": "qwen",
|
||||
"case_id": "diag-service"
|
||||
},
|
||||
"1c538391f488": {
|
||||
"arm": "qwen",
|
||||
"case_id": "diag-proxy"
|
||||
},
|
||||
"dccc19694f54": {
|
||||
"arm": "qwen",
|
||||
"case_id": "tool-status"
|
||||
},
|
||||
"e8edc425fb4e": {
|
||||
"arm": "qwen",
|
||||
"case_id": "tool-logs"
|
||||
},
|
||||
"6fb666353f62": {
|
||||
"arm": "qwen",
|
||||
"case_id": "rule-json"
|
||||
},
|
||||
"52477395d894": {
|
||||
"arm": "qwen",
|
||||
"case_id": "rule-uncertainty"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,218 @@
|
||||
{
|
||||
"qwen": {
|
||||
"speed": {
|
||||
"cases": 2,
|
||||
"errors": 0,
|
||||
"truncated": 2,
|
||||
"prompt_tokens": 166,
|
||||
"cached_tokens": 76,
|
||||
"output_tokens": 512,
|
||||
"fresh_prompt_tokens": 90,
|
||||
"input_tokens_per_second": 75.19425181719441,
|
||||
"output_tokens_per_second": 72.22253568808891,
|
||||
"decode_median": 74.0,
|
||||
"decode_range": [
|
||||
62.6,
|
||||
85.4
|
||||
],
|
||||
"steps": 2,
|
||||
"backend_timing_steps": 2,
|
||||
"request_wall_seconds": 8.300150020979345,
|
||||
"individual": [
|
||||
{
|
||||
"case_id": "speed-first",
|
||||
"steps": [
|
||||
{
|
||||
"usage": {
|
||||
"prompt_tokens": 83,
|
||||
"completion_tokens": 256,
|
||||
"total_tokens": 339,
|
||||
"prompt_tokens_details": {
|
||||
"cached_tokens": 0
|
||||
}
|
||||
},
|
||||
"timings": {
|
||||
"cache_n": 0,
|
||||
"prompt_n": 83,
|
||||
"prompt_ms": 1076.9,
|
||||
"prompt_per_token_ms": 12.975,
|
||||
"prompt_per_second": 77.1,
|
||||
"predicted_n": 256,
|
||||
"predicted_ms": 4089.8,
|
||||
"predicted_per_token_ms": 15.976,
|
||||
"predicted_per_second": 62.6,
|
||||
"draft_n": 159,
|
||||
"draft_n_accepted": 104
|
||||
},
|
||||
"finish": "length",
|
||||
"ttft_answer_s": 1.1219784839777276,
|
||||
"ttft_any_s": 1.1219777929945849,
|
||||
"wall_s": 5.177759660000447
|
||||
}
|
||||
],
|
||||
"error": null
|
||||
},
|
||||
{
|
||||
"case_id": "speed-repeat",
|
||||
"steps": [
|
||||
{
|
||||
"usage": {
|
||||
"prompt_tokens": 83,
|
||||
"completion_tokens": 256,
|
||||
"total_tokens": 339,
|
||||
"prompt_tokens_details": {
|
||||
"cached_tokens": 76
|
||||
}
|
||||
},
|
||||
"timings": {
|
||||
"cache_n": 76,
|
||||
"prompt_n": 7,
|
||||
"prompt_ms": 120.0,
|
||||
"prompt_per_token_ms": 17.143,
|
||||
"prompt_per_second": 58.3,
|
||||
"predicted_n": 256,
|
||||
"predicted_ms": 2999.4,
|
||||
"predicted_per_token_ms": 11.716,
|
||||
"predicted_per_second": 85.4,
|
||||
"draft_n": 159,
|
||||
"draft_n_accepted": 105
|
||||
},
|
||||
"finish": "length",
|
||||
"ttft_answer_s": 0.1366954009863548,
|
||||
"ttft_any_s": 0.1366949299699627,
|
||||
"wall_s": 3.1223903609788977
|
||||
}
|
||||
],
|
||||
"error": null
|
||||
}
|
||||
]
|
||||
},
|
||||
"quality": {
|
||||
"cases": 10,
|
||||
"errors": 0,
|
||||
"truncated": 0,
|
||||
"prompt_tokens": 3270,
|
||||
"cached_tokens": 1035,
|
||||
"output_tokens": 5698,
|
||||
"fresh_prompt_tokens": 2235,
|
||||
"input_tokens_per_second": 155.66234851650648,
|
||||
"output_tokens_per_second": 75.01385610451914,
|
||||
"decode_median": 71.55000000000001,
|
||||
"decode_range": [
|
||||
60.4,
|
||||
81.6
|
||||
],
|
||||
"steps": 12,
|
||||
"backend_timing_steps": 12,
|
||||
"request_wall_seconds": 90.36786482104799
|
||||
}
|
||||
},
|
||||
"deepseek": {
|
||||
"speed": {
|
||||
"cases": 2,
|
||||
"errors": 0,
|
||||
"truncated": 2,
|
||||
"prompt_tokens": 166,
|
||||
"cached_tokens": 82,
|
||||
"output_tokens": 512,
|
||||
"fresh_prompt_tokens": 84,
|
||||
"input_tokens_per_second": 3.1781705088478,
|
||||
"output_tokens_per_second": 12.65087777818959,
|
||||
"decode_median": 13.4,
|
||||
"decode_range": [
|
||||
10.2,
|
||||
16.6
|
||||
],
|
||||
"steps": 2,
|
||||
"backend_timing_steps": 2,
|
||||
"request_wall_seconds": 66.91436810401501,
|
||||
"individual": [
|
||||
{
|
||||
"case_id": "speed-first",
|
||||
"steps": [
|
||||
{
|
||||
"usage": {
|
||||
"prompt_tokens": 83,
|
||||
"completion_tokens": 256,
|
||||
"total_tokens": 339,
|
||||
"prompt_tokens_details": {
|
||||
"cached_tokens": 0
|
||||
}
|
||||
},
|
||||
"timings": {
|
||||
"cache_n": 0,
|
||||
"prompt_n": 83,
|
||||
"prompt_ms": 26243.5,
|
||||
"prompt_per_token_ms": 316.187,
|
||||
"prompt_per_second": 3.2,
|
||||
"predicted_n": 256,
|
||||
"predicted_ms": 25066.4,
|
||||
"predicted_per_token_ms": 97.916,
|
||||
"predicted_per_second": 10.2,
|
||||
"draft_n": 0,
|
||||
"draft_n_accepted": 0
|
||||
},
|
||||
"finish": "length",
|
||||
"ttft_answer_s": 26.29990776098566,
|
||||
"ttft_any_s": 26.299907030013856,
|
||||
"wall_s": 51.320503826020285
|
||||
}
|
||||
],
|
||||
"error": null
|
||||
},
|
||||
{
|
||||
"case_id": "speed-repeat",
|
||||
"steps": [
|
||||
{
|
||||
"usage": {
|
||||
"prompt_tokens": 83,
|
||||
"completion_tokens": 256,
|
||||
"total_tokens": 339,
|
||||
"prompt_tokens_details": {
|
||||
"cached_tokens": 82
|
||||
}
|
||||
},
|
||||
"timings": {
|
||||
"cache_n": 82,
|
||||
"prompt_n": 1,
|
||||
"prompt_ms": 186.8,
|
||||
"prompt_per_token_ms": 186.8,
|
||||
"prompt_per_second": 5.4,
|
||||
"predicted_n": 256,
|
||||
"predicted_ms": 15405.1,
|
||||
"predicted_per_token_ms": 60.176,
|
||||
"predicted_per_second": 16.6,
|
||||
"draft_n": 0,
|
||||
"draft_n_accepted": 0
|
||||
},
|
||||
"finish": "length",
|
||||
"ttft_answer_s": 0.18857223296072334,
|
||||
"ttft_any_s": 0.18857174197910354,
|
||||
"wall_s": 15.593864277994726
|
||||
}
|
||||
],
|
||||
"error": null
|
||||
}
|
||||
]
|
||||
},
|
||||
"quality": {
|
||||
"cases": 10,
|
||||
"errors": 0,
|
||||
"truncated": 0,
|
||||
"prompt_tokens": 3691,
|
||||
"cached_tokens": 1129,
|
||||
"output_tokens": 4840,
|
||||
"fresh_prompt_tokens": 2562,
|
||||
"input_tokens_per_second": 10.36217039339442,
|
||||
"output_tokens_per_second": 9.62253039944237,
|
||||
"decode_median": 10.0,
|
||||
"decode_range": [
|
||||
7.3,
|
||||
10.7
|
||||
],
|
||||
"steps": 12,
|
||||
"backend_timing_steps": 12,
|
||||
"request_wall_seconds": 750.3919659769745
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
{"arm": "deepseek", "case_id": "de-correction", "category": "deutsch", "steps": [{"usage": {"prompt_tokens": 146, "completion_tokens": 255, "total_tokens": 401, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 146, "prompt_ms": 16975.0, "prompt_per_token_ms": 116.267, "prompt_per_second": 8.6, "predicted_n": 255, "predicted_ms": 24235.5, "predicted_per_token_ms": 95.041, "predicted_per_second": 10.5, "draft_n": 0, "draft_n_accepted": 0}, "finish": "stop", "ttft_answer_s": 37.49657300801482, "ttft_any_s": 16.98487763904268, "wall_s": 41.2204253289965}], "tool_checks": [], "answer": "Beide Server sind erreichbar. Wenn du magst, prüfe die Zugehörigkeit der VM. Die Konfiguration wurde verschoben, die Datenträger blieben unverändert.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 1.0, "seed": 42, "reasoning_effort": "low", "reasoning_budget_tokens": 1024, "max_tokens": 2048}, "truncated": false}
|
||||
{"arm": "deepseek", "case_id": "de-summary", "category": "deutsch", "steps": [{"usage": {"prompt_tokens": 128, "completion_tokens": 164, "total_tokens": 292, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 128, "prompt_ms": 17615.6, "prompt_per_token_ms": 137.622, "prompt_per_second": 7.3, "predicted_n": 164, "predicted_ms": 16411.3, "predicted_per_token_ms": 100.069, "predicted_per_second": 10.0, "draft_n": 0, "draft_n_accepted": 0}, "finish": "stop", "ttft_answer_s": 30.12859473505523, "ttft_any_s": 17.618195249000564, "wall_s": 34.02965180500178}], "tool_checks": [], "answer": "Der Dienst läuft, und im Log ist kein Fehler zu finden. Zwei Warnungen betreffen einen einmaligen Timeout, doch eine bestätigte Ursache gibt es nicht. Es wurde nichts neu gestartet.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 1.0, "seed": 42, "reasoning_effort": "low", "reasoning_budget_tokens": 1024, "max_tokens": 2048}, "truncated": false}
|
||||
{"arm": "deepseek", "case_id": "code-merge", "category": "coding", "steps": [{"usage": {"prompt_tokens": 161, "completion_tokens": 450, "total_tokens": 611, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 161, "prompt_ms": 19932.2, "prompt_per_token_ms": 123.802, "prompt_per_second": 8.1, "predicted_n": 450, "predicted_ms": 61708.1, "predicted_per_token_ms": 137.129, "predicted_per_second": 7.3, "draft_n": 0, "draft_n_accepted": 0}, "finish": "stop", "ttft_answer_s": 62.66665399400517, "ttft_any_s": 19.93483726098202, "wall_s": 81.64312560897088}], "tool_checks": [], "answer": "{\"code\":\"def merge_intervals(intervals):\\n if not intervals:\\n return []\\n\\n sorted_intervals = sorted(intervals, key=lambda x: (x[0], x[1]))\\n merged = []\\n start, end = sorted_intervals[0]\\n\\n for s, e in sorted_intervals[1:]:\\n if s <= end:\\n if e > end:\\n end = e\\n else:\\n merged.append((start, end))\\n start, end = s, e\\n\\n merged.append((start, end))\\n return merged\\n\"}", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 1.0, "seed": 42, "reasoning_effort": "low", "reasoning_budget_tokens": 1024, "max_tokens": 2048}, "truncated": false}
|
||||
{"arm": "deepseek", "case_id": "code-bytes", "category": "coding", "steps": [{"usage": {"prompt_tokens": 174, "completion_tokens": 1254, "total_tokens": 1428, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 174, "prompt_ms": 30288.0, "prompt_per_token_ms": 174.069, "prompt_per_second": 5.7, "predicted_n": 1254, "predicted_ms": 134336.9, "predicted_per_token_ms": 108.599, "predicted_per_second": 9.2, "draft_n": 0, "draft_n_accepted": 0}, "finish": "stop", "ttft_answer_s": 137.90250900300452, "ttft_any_s": 21.80236120399786, "wall_s": 164.6380779829924}], "tool_checks": [], "answer": "```json\n{\"code\":\"import re\\n\\ndef parse_size(text: str) -> int:\\n if not isinstance(text, str):\\n raise ValueError('invalid size')\\n m = re.fullmatch(r'\\\\s*([0-9]+)\\\\s*(B|KB|MB|GB|KiB|MiB|GiB)\\\\s*', text)\\n if m is None:\\n raise ValueError('invalid size')\\n n = int(m.group(1))\\n unit = m.group(2)\\n mult = {\\n 'B': 1,\\n 'KB': 1000,\\n 'MB': 1000 ** 2,\\n 'GB': 1000 ** 3,\\n 'KiB': 1024,\\n 'MiB': 1024 ** 2,\\n 'GiB': 1024 ** 3,\\n }[unit]\\n return n * mult\"}\n```", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 1.0, "seed": 42, "reasoning_effort": "low", "reasoning_budget_tokens": 1024, "max_tokens": 2048}, "truncated": false}
|
||||
{"arm": "deepseek", "case_id": "diag-service", "category": "diagnose", "steps": [{"usage": {"prompt_tokens": 198, "completion_tokens": 568, "total_tokens": 766, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 198, "prompt_ms": 22622.0, "prompt_per_token_ms": 114.253, "prompt_per_second": 8.8, "predicted_n": 568, "predicted_ms": 56808.9, "predicted_per_token_ms": 100.016, "predicted_per_second": 10.0, "draft_n": 0, "draft_n_accepted": 0}, "finish": "stop", "ttft_answer_s": 58.247347068972886, "ttft_any_s": 22.63773682998726, "wall_s": 79.44687576103024}], "tool_checks": [], "answer": "**Belegte Ursache:** \nsystemd kann den Prozess nicht starten, weil der in `ExecStart` angegebene Interpreter **`/srv/atlas/venv/bin/python` nicht existiert**. Das wird durch `status=203/EXEC` und den Logeintrag „Failed at step EXEC spawning …: No such file or directory“ belegt. `/usr/bin/python3` existiert zwar, ist aber nicht der konfigurierte Pfad.\n\n**Nächster sinnvoller Schritt:** \nEntweder:\n\n1. die virtuelle Umgebung unter `/srv/atlas/venv` wiederherstellen, sodass `/srv/atlas/venv/bin/python` existiert, **oder**\n2. `ExecStart` auf den vorhandenen Interpreter `/usr/bin/python3` ändern — nur wenn die benötigten Python-Abhängigkeiten systemweit verfügbar sind.\n\nDanach wäre systemd neu zu laden/der Dienst neu zu starten. Es wurde nichts ausgeführt.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 1.0, "seed": 42, "reasoning_effort": "low", "reasoning_budget_tokens": 1024, "max_tokens": 2048}, "truncated": false}
|
||||
{"arm": "deepseek", "case_id": "diag-proxy", "category": "diagnose", "steps": [{"usage": {"prompt_tokens": 175, "completion_tokens": 1299, "total_tokens": 1474, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 175, "prompt_ms": 20403.9, "prompt_per_token_ms": 116.594, "prompt_per_second": 8.6, "predicted_n": 1299, "predicted_ms": 122260.7, "predicted_per_token_ms": 94.119, "predicted_per_second": 10.6, "draft_n": 0, "draft_n_accepted": 0}, "finish": "stop", "ttft_answer_s": 95.3297532509896, "ttft_any_s": 20.418829732981976, "wall_s": 142.67963300296105}], "tool_checks": [], "answer": "**Wahrscheinlichste Fehlkonfiguration:** Der Reverse Proxy verwendet als Upstream `127.0.0.1:9000`. In einem Container zeigt `127.0.0.1` auf den **Proxy-Container selbst**, nicht auf den separaten App-Container. Die App ist im selben Docker-Netzwerk aber unter dem DNS-Namen `app` erreichbar, und `http://app:9000/health` liefert aus dem Proxy-Container `200`. Der 502 entsteht also sehr wahrscheinlich, weil der Proxy versucht, `localhost:9000` im eigenen Container zu erreichen, wo kein Dienst auf Port 9000 lauscht.\n\n**Korrektur:** Upstream/Backend-Adresse von `127.0.0.1:9000` auf `app:9000` ändern.\n\nBeispiele:\n- nginx: `proxy_pass http://127.0.0.1:9000;` → `proxy_pass http://app:9000;`\n- HAProxy: Backend-Server auf `app:9000` statt `127.0.0.1:9000`\n- Traefik: `loadBalancer.servers.url = http://app:9000`\n\n**Prüfung der Korrektur:**\n1. Konfiguration suchen und ändern.\n2. Im Proxy-Container prüfen, ob `app` im Docker-Netzwerk auflösbar ist: \n `getent hosts app`\n3. App-Endpoint aus dem Proxy-Container testen: \n `curl -i http://app:9000/health` — sollte `200` liefern.\n4. Proxy neu laden/neu starten, z. B. nginx: `nginx -t && nginx -s reload` oder Container neu starten.\n5. Über den Proxy den betroffenen Endpoint testen: \n `curl -i http://<proxy-host>/...` — sollte nicht mehr `502` liefern.\n6. Proxy-Logs prüfen, ob weiterhin „connection refused“ oder DNS-Fehler zum alten Upstream auftauchen.\n\nDie zentrale Korrektur ist also: **`127.0.0.1:9000` → `app:9000`**. Die erfolgreiche `GET http://app:9000/health` aus dem Proxy-Container bestätigt, dass Netzwerk und App-Endpoint grundsätzlich funktionieren.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 1.0, "seed": 42, "reasoning_effort": "low", "reasoning_budget_tokens": 1024, "max_tokens": 2048}, "truncated": false}
|
||||
{"arm": "deepseek", "case_id": "tool-status", "category": "werkzeuge", "steps": [{"usage": {"prompt_tokens": 563, "completion_tokens": 71, "total_tokens": 634, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 563, "prompt_ms": 30729.7, "prompt_per_token_ms": 54.582, "prompt_per_second": 18.3, "predicted_n": 71, "predicted_ms": 8159.0, "predicted_per_token_ms": 114.915, "predicted_per_second": 8.7, "draft_n": 0, "draft_n_accepted": 0}, "finish": "tool_calls", "ttft_answer_s": null, "ttft_any_s": 30.75651527097216, "wall_s": 38.91565078200074}, {"usage": {"prompt_tokens": 629, "completion_tokens": 29, "total_tokens": 658, "prompt_tokens_details": {"cached_tokens": 563}}, "timings": {"cache_n": 563, "prompt_n": 66, "prompt_ms": 10329.8, "prompt_per_token_ms": 156.512, "prompt_per_second": 6.4, "predicted_n": 29, "predicted_ms": 2855.8, "predicted_per_token_ms": 98.476, "predicted_per_second": 10.2, "draft_n": 0, "draft_n_accepted": 0}, "finish": "stop", "ttft_answer_s": 10.4306527239969, "ttft_any_s": 10.430652323993854, "wall_s": 13.200588433013763}], "tool_checks": [{"name": "service_status", "arguments": {"service": "atlas.service"}, "valid": true}], "answer": "Der belegte Zustand von **atlas.service** ist **`failed`**. Es wurden keine Änderungen vorgenommen.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 1.0, "seed": 42, "reasoning_effort": "low", "reasoning_budget_tokens": 1024, "max_tokens": 2048}, "truncated": false}
|
||||
{"arm": "deepseek", "case_id": "tool-logs", "category": "werkzeuge", "steps": [{"usage": {"prompt_tokens": 566, "completion_tokens": 103, "total_tokens": 669, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 566, "prompt_ms": 28762.0, "prompt_per_token_ms": 50.816, "prompt_per_second": 19.7, "predicted_n": 103, "predicted_ms": 11722.1, "predicted_per_token_ms": 113.807, "predicted_per_second": 8.8, "draft_n": 0, "draft_n_accepted": 0}, "finish": "tool_calls", "ttft_answer_s": null, "ttft_any_s": 28.77542641304899, "wall_s": 40.49764515104471}, {"usage": {"prompt_tokens": 671, "completion_tokens": 275, "total_tokens": 946, "prompt_tokens_details": {"cached_tokens": 566}}, "timings": {"cache_n": 566, "prompt_n": 105, "prompt_ms": 12593.3, "prompt_per_token_ms": 119.936, "prompt_per_second": 8.3, "predicted_n": 275, "predicted_ms": 26138.4, "predicted_per_token_ms": 95.049, "predicted_per_second": 10.5, "draft_n": 0, "draft_n_accepted": 0}, "finish": "stop", "ttft_answer_s": 16.372973744990304, "ttft_any_s": 12.606634089024737, "wall_s": 38.745138811995275}], "tool_checks": [{"name": "service_logs", "arguments": {"service": "atlas.service", "lines": 20}, "valid": true}], "answer": "Ich habe nur die Logzeilen von `atlas.service` gelesen; keine weiteren Daten abgerufen und den Dienst nicht neu gestartet.\n\n**Belegte Logzeile (die Abfrage lieferte genau diese eine Zeile, nicht 20):**\n> `Failed at step EXEC spawning /srv/atlas/venv/bin/python: No such file or directory`\n\n**Erklärung:**\n- Der Dienst sollte beim Start über den Pfad `/srv/atlas/venv/bin/python` ein Programm ausführen (EXEC-Schritt).\n- Dieser Pfad bzw. die Datei existiert laut Fehlermeldung nicht (`No such file or directory`).\n- Ursache ist damit ein fehlender oder falsch konfigurierter Interpreter im virtuellen Environment – nicht ein Laufzeitfehler des Python-Programms selbst. Der Start scheitert bereits vor der eigentlichen Ausführung.\n- Ob das venv fehlt, ein falscher Pfad in der Dienstkonfiguration steht oder die Datei verschoben wurde, lässt sich aus dieser einen Zeile allein nicht belegen.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 1.0, "seed": 42, "reasoning_effort": "low", "reasoning_budget_tokens": 1024, "max_tokens": 2048}, "truncated": false}
|
||||
{"arm": "deepseek", "case_id": "rule-json", "category": "anweisungen", "steps": [{"usage": {"prompt_tokens": 151, "completion_tokens": 181, "total_tokens": 332, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 151, "prompt_ms": 18588.0, "prompt_per_token_ms": 123.099, "prompt_per_second": 8.1, "predicted_n": 181, "predicted_ms": 16940.4, "predicted_per_token_ms": 93.593, "predicted_per_second": 10.7, "draft_n": 0, "draft_n_accepted": 0}, "finish": "stop", "ttft_answer_s": 32.63896123797167, "ttft_any_s": 18.602180608955678, "wall_s": 35.54272269294597}], "tool_checks": [], "answer": "{\"status\":\"erreichbar\",\"evidence\":[\"Dienst antwortet auf /health mit 200\"],\"unknown\":[\"Logdaten\"]}", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 1.0, "seed": 42, "reasoning_effort": "low", "reasoning_budget_tokens": 1024, "max_tokens": 2048}, "truncated": false}
|
||||
{"arm": "deepseek", "case_id": "rule-uncertainty", "category": "anweisungen", "steps": [{"usage": {"prompt_tokens": 129, "completion_tokens": 191, "total_tokens": 320, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 129, "prompt_ms": 18406.0, "prompt_per_token_ms": 142.682, "prompt_per_second": 7.0, "predicted_n": 191, "predicted_ms": 21409.1, "predicted_per_token_ms": 112.09, "predicted_per_second": 8.9, "draft_n": 0, "draft_n_accepted": 0}, "finish": "stop", "ttft_answer_s": 34.662921478040516, "ttft_any_s": 18.423188726999797, "wall_s": 39.832430616021156}], "tool_checks": [], "answer": "Abfahrt: 05:21 \nAnkunft: 05:40 \nDauer: 19 Minuten \nPünktlichkeit: nicht bestätigt – keine Echtzeitdaten verfügbar; Angabe geschätzt/unbestätigt.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 1.0, "seed": 42, "reasoning_effort": "low", "reasoning_budget_tokens": 1024, "max_tokens": 2048}, "truncated": false}
|
||||
@@ -0,0 +1,10 @@
|
||||
{"arm": "qwen", "case_id": "de-correction", "category": "deutsch", "steps": [{"usage": {"prompt_tokens": 116, "completion_tokens": 630, "total_tokens": 746, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 116, "prompt_ms": 901.8, "prompt_per_token_ms": 7.774, "prompt_per_second": 128.6, "predicted_n": 630, "predicted_ms": 7717.4, "predicted_per_token_ms": 12.25, "predicted_per_second": 81.6, "draft_n": 512, "draft_n_accepted": 361}, "finish": "stop", "ttft_answer_s": 7.8624818659736775, "ttft_any_s": 0.9326814870000817, "wall_s": 8.629706239968073}], "tool_checks": [], "answer": "Beide Server sind erreichbar. Wenn du magst, prüfe die Zugehörigkeit der VM. Die Konfiguration wurde verschoben, die Datenträger blieben unverändert.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 0.95, "seed": 42, "reasoning_effort": "medium", "reasoning_budget_tokens": 1024, "max_tokens": 2048, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": false}
|
||||
{"arm": "qwen", "case_id": "de-summary", "category": "deutsch", "steps": [{"usage": {"prompt_tokens": 97, "completion_tokens": 171, "total_tokens": 268, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 97, "prompt_ms": 894.7, "prompt_per_token_ms": 9.224, "prompt_per_second": 108.4, "predicted_n": 171, "predicted_ms": 2386.1, "predicted_per_token_ms": 13.954, "predicted_per_second": 71.7, "draft_n": 118, "draft_n_accepted": 102}, "finish": "stop", "ttft_answer_s": 2.515477267035749, "ttft_any_s": 0.9180371210095473, "wall_s": 3.2843307650182396}], "tool_checks": [], "answer": "Der Dienst läuft ordnungsgemäß, und im Log wurden keine Fehler festgestellt. Die beiden vorhandenen Warnungen beziehen sich auf einen einmaligen Timeout, dessen Ursache bislang nicht bestätigt wurde. Es wurde kein Neustart des Dienstes durchgeführt.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 0.95, "seed": 42, "reasoning_effort": "medium", "reasoning_budget_tokens": 1024, "max_tokens": 2048, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": false}
|
||||
{"arm": "qwen", "case_id": "code-merge", "category": "coding", "steps": [{"usage": {"prompt_tokens": 126, "completion_tokens": 399, "total_tokens": 525, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 126, "prompt_ms": 1014.9, "prompt_per_token_ms": 8.055, "prompt_per_second": 124.2, "predicted_n": 399, "predicted_ms": 6034.5, "predicted_per_token_ms": 15.124, "predicted_per_second": 66.1, "draft_n": 314, "draft_n_accepted": 273}, "finish": "stop", "ttft_answer_s": 4.899893037974834, "ttft_any_s": 1.0342254939605482, "wall_s": 7.052935062965844}], "tool_checks": [], "answer": "{\"code\":\"def merge_intervals(intervals):\\n if not intervals:\\n return []\\n sorted_intervals = sorted(intervals, key=lambda x: x[0])\\n merged = []\\n current_start, current_end = sorted_intervals[0]\\n for start, end in sorted_intervals[1:]:\\n if start <= current_end:\\n current_end = max(current_end, end)\\n else:\\n merged.append((current_start, current_end))\\n current_start, current_end = start, end\\n merged.append((current_start, current_end))\\n return merged\\n\"}", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 0.95, "seed": 42, "reasoning_effort": "medium", "reasoning_budget_tokens": 1024, "max_tokens": 2048, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": false}
|
||||
{"arm": "qwen", "case_id": "code-bytes", "category": "coding", "steps": [{"usage": {"prompt_tokens": 151, "completion_tokens": 1066, "total_tokens": 1217, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 151, "prompt_ms": 1159.4, "prompt_per_token_ms": 7.678, "prompt_per_second": 130.2, "predicted_n": 1066, "predicted_ms": 14165.6, "predicted_per_token_ms": 13.289, "predicted_per_second": 75.3, "draft_n": 825, "draft_n_accepted": 702}, "finish": "stop", "ttft_answer_s": 12.367019161989447, "ttft_any_s": 1.1826338259852491, "wall_s": 15.328651610005181}], "tool_checks": [], "answer": "{\"code\":\"import re\\n\\n_MULTIPLIERS = {\\n 'B': 1,\\n 'KB': 1000,\\n 'MB': 1000 ** 2,\\n 'GB': 1000 ** 3,\\n 'KiB': 1024,\\n 'MiB': 1024 ** 2,\\n 'GiB': 1024 ** 3,\\n}\\n\\n_PATTERN = re.compile(r'\\\\s*(\\\\d+)\\\\s*(B|KB|MB|GB|KiB|MiB|GiB)\\\\s*')\\n\\n\\ndef parse_size(text: str) -> int:\\n match = _PATTERN.fullmatch(text)\\n if not match:\\n raise ValueError(f\\\"Invalid size string: {text!r}\\\")\\n return int(match.group(1)) * _MULTIPLIERS[match.group(2)]\\n\"}", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 0.95, "seed": 42, "reasoning_effort": "medium", "reasoning_budget_tokens": 1024, "max_tokens": 2048, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": false}
|
||||
{"arm": "qwen", "case_id": "diag-service", "category": "diagnose", "steps": [{"usage": {"prompt_tokens": 159, "completion_tokens": 878, "total_tokens": 1037, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 159, "prompt_ms": 1273.2, "prompt_per_token_ms": 8.008, "prompt_per_second": 124.9, "predicted_n": 878, "predicted_ms": 12289.6, "predicted_per_token_ms": 13.997, "predicted_per_second": 71.4, "draft_n": 603, "draft_n_accepted": 426}, "finish": "stop", "ttft_answer_s": 6.149433507001959, "ttft_any_s": 1.299202954978682, "wall_s": 13.566913629998453}], "tool_checks": [], "answer": "## Belegte Ursache\n\nDer Fehlercode **status=203/EXEC** bedeutet: systemd konnte den in `ExecStart` angegebenen Interpreter nicht *spawnen*. Die Logzeile\n\n> Failed at step EXEC spawning /srv/atlas/venv/bin/python: No such file or directory\n\nbestätigt zweifelsfrei:\n\n- **Fehlende Datei:** `/srv/atlas/venv/bin/python` existiert nicht (der Symlink bzw. die Binärdatei des virtuellen Environments ist entfernt, veraltet oder wurde nie angelegt).\n- **System-python ist vorhanden:** `/usr/bin/python3` existiert – das Problem liegt also *nicht* an einem fehlenden Python selbst, sondern ausschließlich am abstrakten Pfad des venv.\n- `app.py` selbst spielt hier noch keine Rolle; das Exec-Aufruf scheitert, bevor Python überhaupt die Script-Datei öffnen kann.\n\n## Nächster sinnvoller Schritt (keine Ausführung – nur Empfehlung)\n\n| Priorität | Maßnahme | Begründung |\n|---|---|---|\n| 1 | **venv rekonstruieren:** `/usr/bin/python3 -m venv /srv/atlas/venv` | Stellt den fehlenden Symlink `venv/bin/python → python3` wieder her, ohne die Service-Unit zu ändern. |\n| 2 | **Abhängigkeiten neu installieren:** `srv/atlas/venv/bin/pip install -r /srv/atlas/requirements.txt` | Der venv ist leer; ohne Pakete würde `app.py` importseitig scheitern. |\n| 3 | Service neu starten: `systemctl restart atlas.service` | Erst danach prüft man, ob 203/EXEC verschwunden ist. |\n\n### Warum *nicht* direkt `ExecStart` auf `/usr/bin/python3` umschreiben?\n\nDas wäre ein kurzfristiger Workaround, umgeht aber das isolierte venv und vermischt Systempakete mit Projekt-Abhängigkeiten – bei Shared-Hosting oder Security-Härtung problematisch. Die Behebung *an der Stelle des Defekts* (fehlender venv) ist der sauberere Weg.\n\n### Optionale Absicherung gegen Wiederholung\n\nIn der Unit ergänzen:\n\n```ini\nExecStart=/srv/atlas/venv/bin/python3 /srv/atlas/app.py\n```\n\n(`python3` statt `python`, damit auch nach einem venv-Rebuild mit Python 3.x der Pfad stimmt.)\n\n---\n\n*Hinweis: Die Analyse basiert ausschließlich auf den bereitgestellten synthetischen Daten. Es wurden keine Befehle ausgeführt und keine realen Prüfungen durchgeführt.*", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 0.95, "seed": 42, "reasoning_effort": "medium", "reasoning_budget_tokens": 1024, "max_tokens": 2048, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": false}
|
||||
{"arm": "qwen", "case_id": "diag-proxy", "category": "diagnose", "steps": [{"usage": {"prompt_tokens": 153, "completion_tokens": 1305, "total_tokens": 1458, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 153, "prompt_ms": 1032.8, "prompt_per_token_ms": 6.75, "prompt_per_second": 148.1, "predicted_n": 1305, "predicted_ms": 16127.6, "predicted_per_token_ms": 12.358, "predicted_per_second": 80.9, "draft_n": 1008, "draft_n_accepted": 741}, "finish": "stop", "ttft_answer_s": 4.584941634035204, "ttft_any_s": 1.0607183990068734, "wall_s": 17.163994643022306}], "tool_checks": [], "answer": "# Wahrscheinlichste Fehlkonfiguration: Upstream zeigt auf `127.0.0.1` statt `app`\n\n## Diagnose\n\nIm **Proxy-Container** bedeutet `127.0.0.1` den **eigenen Netzwerk-Stack des Proxy-Containers**. Dort lauscht nichts auf Port 9000 – die Anwendung lebt im separaten Container `app`.\n\n```\nProxy-Container App-Container\n┌──────────────────┐ ┌──────────────────┐\n│ :80 ← proxy │ │ │\n│ :9000 ← NICHTS │ │ app:9000 ✓ │\n│ │ │ │\n│ curl →127.0.0.1 │ │ │\n│ → 111 refused │ │ │\n└──────────────────┘ └──────────────────┘\n```\n\nDer Proxy versucht eine TCP-Verbindung zu `127.0.0.1:9000`, erhält **connection refused** und antwortet dem Client mit **502 Bad Gateway**.\n\nDass `curl http://app:9000/health` *im Proxy-Container* ein 200 liefert, bestätigt:\n\n- Docker-DNS löst `app` korrekt auf → das Netzwerk ist in Ordnung.\n- Die App selbst ist gesund.\n- Nur der **Upstream-String in der Proxy-Konfiguration** ist falsch.\n\n---\n\n## Korrektur\n\n### 1. Konfigurationszeile ändern (Beispiel nginx)\n\n```nginx\n# VORHER (fehlerhaft)\nupstream backend {\n server 127.0.0.1:9000;\n}\n\n# NACHHER (korrigiert)\nupstream backend {\n server app:9000; # Docker-Servicename\n}\n```\n\nÄquivalent bei **Traefik / Caddy / HAProxy**: den Host vom Loopback auf `app` umstellen.\n\n### 2. Proxy neu laden\n\n```bash\n# nginx\ndocker exec proxy nginx -t && docker exec proxy nginx -s reload\n\n# Traefik\ndocker compose restart proxy\n```\n\n---\n\n## Prüfschritte nach der Korrektur\n\n| # | Kommando | Erwartetes Ergebnis |\n|---|----------|---------------------|\n| 1 | `docker exec proxy curl -s -o /dev/null -w '%{http_code}' http://app:9000/health` | **200** (Verbindungsgrund ist schon klar, dient als Regressionsschutz) |\n| 2 | `curl -s -o /dev/null -w '%{http_code}' http://localhost:80/health` *(vom Host, geht durch Proxy)* | **200** statt 502 |\n| 3 | `docker exec proxy tail -n 20 /var/log/nginx/error.log` | keine `connect() failed (111: Connection refused) to 127.0.0.1:9000` mehr; stattdessen ggf. nur noch Timeout- oder 4xx-Fehler |\n| 4 | `docker compose logs proxy --tail 50 \\| grep 502` | keine neuen 502-Einträge nach Reload |\n| 5 | `docker inspect proxy --format '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}'` und `docker inspect app --format '...'` | beide IPs im selben Subnetz des Compose-Netzwerks |\n\n### Optional: Stopp der Falschkonfiguration absichern\n\n```bash\n# Vorher: explizit zeigen, dass 127.0.0.1:9000 NICHT erreichbar ist\ndocker exec proxy curl -sv http://127.0.0.1:9000/health 2>&1 | grep -i refused\n# Erwartet: \"Connection refused\" → bestätigt die alte Fehlkonfiguration\n```\n\n---\n\n## Kurzformel\n\n> **502 + Upstream `127.0.0.1:9000` + App in eigenem Container** → Loopback verweist auf den Proxy-Container selbst, nicht auf `app`. Upstream-Host auf den Docker-Servicename (`app:9000`) setzen, reload, per `curl` durch den Proxy durchgehen und Error-Log auf `connection refused` prüfen.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 0.95, "seed": 42, "reasoning_effort": "medium", "reasoning_budget_tokens": 1024, "max_tokens": 2048, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": false}
|
||||
{"arm": "qwen", "case_id": "tool-status", "category": "werkzeuge", "steps": [{"usage": {"prompt_tokens": 519, "completion_tokens": 71, "total_tokens": 590, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 519, "prompt_ms": 2343.7, "prompt_per_token_ms": 4.516, "prompt_per_second": 221.4, "predicted_n": 71, "predicted_ms": 1175.5, "predicted_per_token_ms": 16.556, "predicted_per_second": 60.4, "draft_n": 57, "draft_n_accepted": 48}, "finish": "tool_calls", "ttft_answer_s": null, "ttft_any_s": 2.374219354998786, "wall_s": 3.524472138029523}, {"usage": {"prompt_tokens": 579, "completion_tokens": 116, "total_tokens": 695, "prompt_tokens_details": {"cached_tokens": 514}}, "timings": {"cache_n": 514, "prompt_n": 65, "prompt_ms": 663.4, "prompt_per_token_ms": 10.206, "prompt_per_second": 98.0, "predicted_n": 116, "predicted_ms": 1715.3, "predicted_per_token_ms": 14.787, "predicted_per_second": 67.6, "draft_n": 81, "draft_n_accepted": 52}, "finish": "stop", "ttft_answer_s": 1.232855298963841, "ttft_any_s": 0.6804317769710906, "wall_s": 2.3819484669947997}], "tool_checks": [{"name": "service_status", "arguments": {"service": "atlas.service"}, "valid": true}], "answer": "**Geprüfter Zustand von `atlas.service`:**\n\n- Zustand: **failed** (fehlgeschlagen / nicht aktiv)\n\nEs wurden keine Änderungen vorgenommen — es erfolgte ausschließlich eine lesende Statusabfrage. Hinweis: Die Angabe stammt aus dem simulierten Status-Werkzeug; weitere Details (z. B. Fehlerursache) liegen nicht vor, da keine Logs abgefragt wurden.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 0.95, "seed": 42, "reasoning_effort": "medium", "reasoning_budget_tokens": 1024, "max_tokens": 2048, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": false}
|
||||
{"arm": "qwen", "case_id": "tool-logs", "category": "werkzeuge", "steps": [{"usage": {"prompt_tokens": 526, "completion_tokens": 98, "total_tokens": 624, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 526, "prompt_ms": 2290.1, "prompt_per_token_ms": 4.354, "prompt_per_second": 229.7, "predicted_n": 98, "predicted_ms": 1393.8, "predicted_per_token_ms": 14.222, "predicted_per_second": 70.3, "draft_n": 77, "draft_n_accepted": 62}, "finish": "tool_calls", "ttft_answer_s": null, "ttft_any_s": 2.306632873020135, "wall_s": 3.6872013300308026}, {"usage": {"prompt_tokens": 618, "completion_tokens": 450, "total_tokens": 1068, "prompt_tokens_details": {"cached_tokens": 521}}, "timings": {"cache_n": 521, "prompt_n": 97, "prompt_ms": 834.0, "prompt_per_token_ms": 8.598, "prompt_per_second": 116.3, "predicted_n": 450, "predicted_ms": 5922.4, "predicted_per_token_ms": 13.161, "predicted_per_second": 76.0, "draft_n": 324, "draft_n_accepted": 204}, "finish": "stop", "ttft_answer_s": 1.6937103659729473, "ttft_any_s": 0.8512991039897315, "wall_s": 6.759573258983437}], "tool_checks": [{"name": "service_logs", "arguments": {"service": "atlas.service", "lines": 20}, "valid": true}], "answer": "**Ergebnis der Logabfrage (`atlas.service`, angefragt: 20 Zeilen):**\n\nDas Log enthält lediglich eine einzige relevante Zeile:\n\n```\nFailed at step EXEC spawning /srv/atlas/venv/bin/python: No such file or directory\n```\n\n**Erklärung der belegten Fehlermeldung:**\n\n- **Fehlerort:** Der Dienst ist beim Start in den `EXEC`-Schritt gelaufen – also genau an der Stelle, an der der Service-Prozess tatsächlich per `execve()` gestartet werden soll.\n- **Fehlerursache:** Der in der Unit-Datei (vermutlich via `ExecStart`) konfigurierte Interpreter `/srv/atlas/venv/bin/python` existiert nicht. „No such file or directory“ entspricht dem Systemfehler `ENOENT`.\n- **Typische Ursachen für genau dieses Muster:**\n 1. Das Virtual Environment unter `/srv/atlas/venv` wurde nie angelegt, gelöscht oder verschoben.\n 2. Der venv wurde mit einer anderen Python-Version/anderem Pfad erstellt und der Symlink `venv/bin/python` zeigt auf einen nicht mehr existierenden Interpreter (gebrochener Symlink – bricht ebenfalls mit ENOENT beim EXEC-Schritt).\n 3. Die Unit-Datei verweist auf einen falschen Pfad (Tippfehler oder nach einem Umzug nicht aktualisiert).\n- **Einordnung:** Es handelt sich um ein Konfigurations-/Setup-Problem, nicht um einen Laufzeit- oder Anwendungsfehler. Die eigentliche Anwendung ist nie gestartet worden – der Start scheitert bereits vor der Prozessausführung.\n\n**Hinweis:** Die Logs liefern sonst keine weiteren Zeilen, damit endet die belastbare Beweisgrundlage. Ich habe – wie gefordert – keine Neustarts oder sonstigen Aktionen ausgeführt.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 0.95, "seed": 42, "reasoning_effort": "medium", "reasoning_budget_tokens": 1024, "max_tokens": 2048, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": false}
|
||||
{"arm": "qwen", "case_id": "rule-json", "category": "anweisungen", "steps": [{"usage": {"prompt_tokens": 125, "completion_tokens": 185, "total_tokens": 310, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 125, "prompt_ms": 948.9, "prompt_per_token_ms": 7.591, "prompt_per_second": 131.7, "predicted_n": 185, "predicted_ms": 2648.7, "predicted_per_token_ms": 14.317, "predicted_per_second": 69.8, "draft_n": 134, "draft_n_accepted": 106}, "finish": "stop", "ttft_answer_s": 2.3869663369841874, "ttft_any_s": 0.9767342249979265, "wall_s": 3.600775359023828}], "tool_checks": [], "answer": "{\"status\": \"erreichbar\", \"evidence\": [\"Dienst antwortet auf /health mit HTTP 200\"], \"unknown\": [\"Logdaten\", \"Funktionsfähigkeit der Applikationsebene\", \"Latenz und Stabilität der Antwort\", \"Authentifizierung und Autorisierung\", \"Konfigurationszustand\", \"Abhängigkeiten zu nachgelagerten Diensten\"]}", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 0.95, "seed": 42, "reasoning_effort": "medium", "reasoning_budget_tokens": 1024, "max_tokens": 2048, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": false}
|
||||
{"arm": "qwen", "case_id": "rule-uncertainty", "category": "anweisungen", "steps": [{"usage": {"prompt_tokens": 101, "completion_tokens": 329, "total_tokens": 430, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 101, "prompt_ms": 1001.1, "prompt_per_token_ms": 9.912, "prompt_per_second": 100.9, "predicted_n": 329, "predicted_ms": 4382.8, "predicted_per_token_ms": 13.322, "predicted_per_second": 75.1, "draft_n": 254, "draft_n_accepted": 195}, "finish": "stop", "ttft_answer_s": 3.510094168013893, "ttft_any_s": 1.0212127059930936, "wall_s": 5.387362317007501}], "tool_checks": [], "answer": "**Zug – Fahrplanübersicht**\n\n| | Zeit |\n|---|---|\n| Abfahrt (Fahrplan) | 05:21 |\n| Ankunft (Fahrplan) | 05:40 |\n| Dauer | 19 min |\n\n**Pünktlichkeit:** Nicht bewertbar.\n\n*Hinweis:* `realtime_available = false` und `estimated_unconfirmed = true` → Es liegen keine Echtzeit- oder bestätigten Ist-Daten vor. Die oben genannten Werte stammen ausschließlich aus dem Fahrplan; eine tatsächliche Verspätung oder Pünktlichkeit kann nicht angegeben werden.", "error": null, "generation_parameters": {"temperature": 1.0, "top_p": 0.95, "seed": 42, "reasoning_effort": "medium", "reasoning_budget_tokens": 1024, "max_tokens": 2048, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": false}
|
||||
@@ -0,0 +1,64 @@
|
||||
{
|
||||
"deepseek": {
|
||||
"mean": 9.7,
|
||||
"core_success": 9,
|
||||
"cases": 10,
|
||||
"han_intrusions": 0,
|
||||
"categories": {
|
||||
"anweisungen": 9.5,
|
||||
"coding": 9,
|
||||
"deutsch": 10,
|
||||
"diagnose": 10,
|
||||
"werkzeuge": 10
|
||||
},
|
||||
"deductions": [
|
||||
{
|
||||
"case_id": "code-bytes",
|
||||
"score": 8,
|
||||
"reason": "Function tests pass only after removing the Markdown fence. Original answer violates the explicit pure-JSON contract and fails strict JSON decoding."
|
||||
},
|
||||
{
|
||||
"case_id": "rule-uncertainty",
|
||||
"score": 9.0,
|
||||
"reason": "Correct times, duration and unconfirmed punctuality. Does not explicitly identify the times as schedule data; generic estimated/unconfirmed wording blurs schedule versus estimate."
|
||||
}
|
||||
]
|
||||
},
|
||||
"qwen": {
|
||||
"mean": 9.75,
|
||||
"core_success": 10,
|
||||
"cases": 10,
|
||||
"han_intrusions": 0,
|
||||
"categories": {
|
||||
"anweisungen": 10,
|
||||
"coding": 10,
|
||||
"deutsch": 9.75,
|
||||
"diagnose": 9.0,
|
||||
"werkzeuge": 10
|
||||
},
|
||||
"deductions": [
|
||||
{
|
||||
"case_id": "diag-proxy",
|
||||
"score": 9.5,
|
||||
"reason": "Correct loopback diagnosis and central correction. Claims that the app is healthy and only the upstream string is wrong exceed evidence from one health endpoint."
|
||||
},
|
||||
{
|
||||
"case_id": "de-summary",
|
||||
"score": 9.5,
|
||||
"reason": "All five facts and three sentences. Ordungsgemaess/ordnungsgemäß broadens the supplied running state into an unverified claim of proper operation."
|
||||
},
|
||||
{
|
||||
"case_id": "diag-service",
|
||||
"score": 8.5,
|
||||
"reason": "Core interpreter diagnosis and venv reconstruction are correct. Extra pip command lacks its leading slash; optional switch to python3 is not a demonstrated prevention. German grammatical error: das Exec-Aufruf."
|
||||
}
|
||||
]
|
||||
},
|
||||
"paired_tasks": {
|
||||
"qwen_wins": 2,
|
||||
"deepseek_wins": 3,
|
||||
"ties": 5
|
||||
},
|
||||
"assessment_sha256": "cd44fb230dfb0df58fb9d63fae4971990b9fb1d44105b9a96ede1f44a0e57220",
|
||||
"limits": "10 independent synthetic tasks, one repetition per model, one subjective blind assessor. No demonstrated overall quality improvement; no full Hermes/MCP/long-context evaluation."
|
||||
}
|
||||
@@ -0,0 +1,154 @@
|
||||
{
|
||||
"started_at": 1792846884.8103952,
|
||||
"previous_profile": "flash-next-strata-iq3-dual",
|
||||
"arms": {
|
||||
"qwen": {
|
||||
"load_seconds": 71.83826783200493,
|
||||
"health": {
|
||||
"status": "ok",
|
||||
"max_context": 262144,
|
||||
"model": "flash-next-strata-iq3-dual",
|
||||
"images": false,
|
||||
"api_key": true,
|
||||
"image_generation": false,
|
||||
"loaded": true,
|
||||
"service": "strata"
|
||||
},
|
||||
"context": "262144",
|
||||
"speed_rows": 2,
|
||||
"quality_rows": 10,
|
||||
"engine_read_bytes_during_measurement": 0
|
||||
},
|
||||
"deepseek": {
|
||||
"load_seconds": 28.672750627971254,
|
||||
"health": {
|
||||
"status": "ok",
|
||||
"max_context": 8192,
|
||||
"model": "deepseek-v4.1-flash",
|
||||
"images": false,
|
||||
"api_key": true,
|
||||
"image_generation": false,
|
||||
"loaded": true,
|
||||
"service": "strata"
|
||||
},
|
||||
"context": "8192",
|
||||
"speed_rows": 2,
|
||||
"quality_rows": 10,
|
||||
"engine_read_bytes_during_measurement": 0
|
||||
}
|
||||
},
|
||||
"restored": true,
|
||||
"phase": "complete",
|
||||
"updated_at": 1792847987.9579268,
|
||||
"settings_before": {
|
||||
"profiles.json": "e56a9cab15bed73d6bdd95dec0fe03c1eec636b8a3130e070e06b8b475210f3e",
|
||||
"endpoint.json": "1777010839b4cf905d1d52a76aaec55cc0d2e72fd8634a98dfecf1cc705f9d18",
|
||||
"audio-policy.json": "f48dedea718968c00c0647ca90c1402bdabac9ce600dbeddc495817680527a3f",
|
||||
"cpu-partition.json": "078d9215c41d7beafe42391a6a25c9aa34ad7f5b88ebbf40e2c178123e6611c1"
|
||||
},
|
||||
"endpoint_before": {
|
||||
"state": "running",
|
||||
"port": 8120,
|
||||
"counts": {
|
||||
"llm": {
|
||||
"enabled": 12,
|
||||
"available": 12,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"image": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"tts": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"stt": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"music": {
|
||||
"enabled": 2,
|
||||
"available": 2,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"voice": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
}
|
||||
},
|
||||
"active_requests": 0
|
||||
},
|
||||
"cpu_affinity": [
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
3,
|
||||
6,
|
||||
7,
|
||||
8,
|
||||
9
|
||||
],
|
||||
"restored_profile": "flash-next-strata-iq3-dual",
|
||||
"endpoint_after": {
|
||||
"state": "running",
|
||||
"port": 8120,
|
||||
"counts": {
|
||||
"llm": {
|
||||
"enabled": 12,
|
||||
"available": 12,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"image": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"tts": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"stt": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": true,
|
||||
"supported": true
|
||||
},
|
||||
"music": {
|
||||
"enabled": 2,
|
||||
"available": 2,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
},
|
||||
"voice": {
|
||||
"enabled": 1,
|
||||
"available": 1,
|
||||
"loaded": false,
|
||||
"supported": true
|
||||
}
|
||||
},
|
||||
"active_requests": 0
|
||||
},
|
||||
"settings_after": {
|
||||
"profiles.json": "e56a9cab15bed73d6bdd95dec0fe03c1eec636b8a3130e070e06b8b475210f3e",
|
||||
"endpoint.json": "1777010839b4cf905d1d52a76aaec55cc0d2e72fd8634a98dfecf1cc705f9d18",
|
||||
"audio-policy.json": "f48dedea718968c00c0647ca90c1402bdabac9ce600dbeddc495817680527a3f",
|
||||
"cpu-partition.json": "078d9215c41d7beafe42391a6a25c9aa34ad7f5b88ebbf40e2c178123e6611c1"
|
||||
},
|
||||
"settings_unchanged": true,
|
||||
"finished_at": 1792847987.9579253
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
{"arm": "deepseek", "case_id": "speed-first", "category": "speed", "steps": [{"usage": {"prompt_tokens": 83, "completion_tokens": 256, "total_tokens": 339, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 83, "prompt_ms": 26243.5, "prompt_per_token_ms": 316.187, "prompt_per_second": 3.2, "predicted_n": 256, "predicted_ms": 25066.4, "predicted_per_token_ms": 97.916, "predicted_per_second": 10.2, "draft_n": 0, "draft_n_accepted": 0}, "finish": "length", "ttft_answer_s": 26.29990776098566, "ttft_any_s": 26.299907030013856, "wall_s": 51.320503826020285}], "tool_checks": [], "answer": "# Zuverlässige Datensicherung: Grundlagen, Strategien und praktische Umsetzung\n\nZuverlässige Datensicherung ist ein zentraler Bestandteil moderner IT-Infrastruktur. Sie dient dazu, Daten vor Verlust, Beschädigung, unbefugtem Zugriff und technischen Fehlern zu schützen und im Schadensfall eine schnelle Wiederherstellung zu ermöglichen. Zuverlässigkeit entsteht nicht durch ein einzelnes Werkzeug, sondern durch ein systematisches Zusammenspiel von Strategie, technischer Umsetzung, regelmäßiger Überprüfung und organisatorischen Regelungen.\n\n## 1. Was „zuverlässig“ bedeutet\n\nEine Datensicherung ist zuverlässig, wenn sie mehrere Eigenschaften erfüllt:\n\n- **Vollständigkeit:** Alle relevanten Daten werden erfasst, nicht nur einzelne Ordner oder Systeme.\n- **Aktualität:** Die Sicherung erfolgt regelmäßig und passt zum Veränderungsrhythmus der Daten.\n- **Wiederherstellbarkeit:** Die gesicherten Daten lassen sich tatsächlich und innerhalb eines definierten Zeitraums zurückführen.\n- **Integrität", "error": null, "generation_parameters": {"temperature": 0, "top_p": 1, "seed": 42, "reasoning_effort": "none", "max_tokens": 256}, "truncated": true}
|
||||
{"arm": "deepseek", "case_id": "speed-repeat", "category": "speed", "steps": [{"usage": {"prompt_tokens": 83, "completion_tokens": 256, "total_tokens": 339, "prompt_tokens_details": {"cached_tokens": 82}}, "timings": {"cache_n": 82, "prompt_n": 1, "prompt_ms": 186.8, "prompt_per_token_ms": 186.8, "prompt_per_second": 5.4, "predicted_n": 256, "predicted_ms": 15405.1, "predicted_per_token_ms": 60.176, "predicted_per_second": 16.6, "draft_n": 0, "draft_n_accepted": 0}, "finish": "length", "ttft_answer_s": 0.18857223296072334, "ttft_any_s": 0.18857174197910354, "wall_s": 15.593864277994726}], "tool_checks": [], "answer": "# Zuverlässige Datensicherung: Grundlagen, Strategien und praktische Umsetzung\n\nZuverlässige Datensicherung ist ein zentraler Bestandteil moderner IT-Infrastruktur. Sie dient dazu, Daten vor Verlust, Beschädigung, unbefugtem Zugriff und technischen Fehlern zu schützen und im Schadensfall eine schnelle Wiederherstellung zu ermöglichen. Eine belastbare Sicherungsstrategie beruht nicht auf einem einzelnen Mechanismus, sondern auf mehreren miteinander verbundenen Maßnahmen: klare Verantwortlichkeiten, regelmäßige Sicherungen, geprüfte Wiederherstellbarkeit, getrennte Speicherorte und dokumentierte Verfahren.\n\n## 1. Ziele und Grundprinzipien\n\nDatensicherung verfolgt mehrere Ziele. Erstens soll sie die Verfügbarkeit wichtiger Daten gewährleisten. Zweitens soll sie die Integrität der Daten erhalten, also sicherstellen, dass gesicherte Kopien unverändert und vollständig sind. Drittens soll sie Vertraulichkeit unterstützen, indem Sicherungen angemessen geschützt werden. Viertens soll sie die Wieder", "error": null, "generation_parameters": {"temperature": 0, "top_p": 1, "seed": 42, "reasoning_effort": "none", "max_tokens": 256}, "truncated": true}
|
||||
@@ -0,0 +1,2 @@
|
||||
{"arm": "qwen", "case_id": "speed-first", "category": "speed", "steps": [{"usage": {"prompt_tokens": 83, "completion_tokens": 256, "total_tokens": 339, "prompt_tokens_details": {"cached_tokens": 0}}, "timings": {"cache_n": 0, "prompt_n": 83, "prompt_ms": 1076.9, "prompt_per_token_ms": 12.975, "prompt_per_second": 77.1, "predicted_n": 256, "predicted_ms": 4089.8, "predicted_per_token_ms": 15.976, "predicted_per_second": 62.6, "draft_n": 159, "draft_n_accepted": 104}, "finish": "length", "ttft_answer_s": 1.1219784839777276, "ttft_any_s": 1.1219777929945849, "wall_s": 5.177759660000447}], "tool_checks": [], "answer": "# Zuverlässige Datensicherung: Strategien, Methoden und Best Practices\n\nIn der modernen digitalen Welt sind Daten das wertvollste Gut von Unternehmen, Institutionen und Privatpersonen. Ob es sich um sensible Kundeninformationen, komplexe Forschungsdaten, persönliche Fotos oder kritische Betriebsabläufe handelt, der Verlust dieser Informationen kann existenzbedrohende Konsequenzen nach sich ziehen. Daher ist eine zuverlässige Datensicherung (Backup) keine optionale Zusatzleistung, sondern eine fundamentale Säule der IT-Sicherheit und des Risikomanagements. Ein effektives Backup-System schützt nicht nur vor technischen Ausfällen, sondern auch vor menschlichen Fehlern, Cyberangriffen wie Ransomware und physischen Katastrophen. Dieser Text beleuchtet die grundlegenden Prinzipien, bewährte Methoden und strategische Überlegungen für eine robuste Datensicherungsstrategie.\n\n## Die 3-2-1-Regel als Goldstandard\n\nDas am weitesten verbreitete und von Experten empfohlene Modell für eine zuverlässige Datensicherung ist die sogenannte 3-2-1-Regel. Diese Regel definiert die Mindestanforderungen an die Redundanz und Verteilung von Datenkopien. Konkret bedeutet dies, dass mindestens drei Kop", "error": null, "generation_parameters": {"temperature": 0, "top_p": 1, "seed": 42, "reasoning_effort": "none", "max_tokens": 256, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": true}
|
||||
{"arm": "qwen", "case_id": "speed-repeat", "category": "speed", "steps": [{"usage": {"prompt_tokens": 83, "completion_tokens": 256, "total_tokens": 339, "prompt_tokens_details": {"cached_tokens": 76}}, "timings": {"cache_n": 76, "prompt_n": 7, "prompt_ms": 120.0, "prompt_per_token_ms": 17.143, "prompt_per_second": 58.3, "predicted_n": 256, "predicted_ms": 2999.4, "predicted_per_token_ms": 11.716, "predicted_per_second": 85.4, "draft_n": 159, "draft_n_accepted": 105}, "finish": "length", "ttft_answer_s": 0.1366954009863548, "ttft_any_s": 0.1366949299699627, "wall_s": 3.1223903609788977}], "tool_checks": [], "answer": "# Zuverlässige Datensicherung: Strategien, Methoden und Best Practices\n\nIn der modernen digitalen Welt sind Daten das wertvollste Gut von Unternehmen, Institutionen und Privatpersonen. Ob es sich um sensible Kundeninformationen, komplexe Forschungsdaten, persönliche Fotos oder kritische Betriebsabläufe handelt, der Verlust dieser Informationen kann existenzbedrohende Konsequenzen nach sich ziehen. Daher ist eine zuverlässige Datensicherung (Backup) keine optionale Zusatzleistung, sondern eine fundamentale Säule der IT-Sicherheit und des Risikomanagements. Ein effektives Backup-System schützt nicht nur vor technischen Ausfällen, sondern auch vor menschlichen Fehlern, Cyberangriffen wie Ransomware und physischen Katastrophen. Dieser Text beleuchtet die grundlegenden Prinzipien, bewährte Methoden und strategische Überlegungen für eine robuste Datensicherungsstrategie.\n\n## Die 3-2-1-Regel als Goldstandard\n\nDas am weitesten verbreitete und von Experten empfohlene Modell für eine zuverlässige Datensicherung ist die sogenannte 3-2-1-Regel. Diese Regel definiert die Mindestanforderungen an die Redundanz und die geografische Verteilung von Datenkopien. Konkret bedeutet dies: Es", "error": null, "generation_parameters": {"temperature": 0, "top_p": 1, "seed": 42, "reasoning_effort": "none", "max_tokens": 256, "top_k": 20, "min_p": 0, "presence_penalty": 0, "repeat_penalty": 1, "frequency_penalty": 0, "strata_tune": {"aux_cpus": 1}}, "truncated": true}
|
||||
@@ -0,0 +1,30 @@
|
||||
{
|
||||
"qwen_model": "flash-next-strata-iq3-dual",
|
||||
"qwen_loaded": true,
|
||||
"qwen_health": "ok",
|
||||
"original_worker_parameters_restored": true,
|
||||
"compared_fields": [
|
||||
"exe",
|
||||
"args",
|
||||
"cwd",
|
||||
"tokenizer",
|
||||
"model_name",
|
||||
"host",
|
||||
"gpu",
|
||||
"gpu_order",
|
||||
"layer_split",
|
||||
"vram_elastic",
|
||||
"open_browser",
|
||||
"log",
|
||||
"parallel",
|
||||
"reasoning_loop_recovery",
|
||||
"vision",
|
||||
"env"
|
||||
],
|
||||
"own_test_workers_remaining": [],
|
||||
"gpu_memory": [
|
||||
"NVIDIA GeForce RTX 3060, 11269 MiB",
|
||||
"NVIDIA GeForce RTX 5080, 15378 MiB"
|
||||
],
|
||||
"io_measurement_note": "Engine read-byte counters were not captured: engine subprocesses use separate process groups. Recorded zeros are unavailable measurements, not zero physical SSD reads."
|
||||
}
|
||||
@@ -0,0 +1,268 @@
|
||||
#!/usr/bin/env python3
|
||||
"""One authorized pilot; owned workers only, production priority, finally restore."""
|
||||
import argparse
|
||||
import hashlib
|
||||
import json
|
||||
import os
|
||||
from pathlib import Path
|
||||
import secrets
|
||||
import signal
|
||||
import subprocess
|
||||
import sys
|
||||
import time
|
||||
import urllib.request
|
||||
|
||||
BASE = Path(os.environ.get('DECK_TEST_BASE', '/data/athena-deck-strata/experiments/deepseek-iq2-20261024'))
|
||||
STATE = Path(os.environ.get('DECK_TEST_STATE', '/opt/athena-deck-dev/runtime/state'))
|
||||
SOURCE = STATE / 'strata-runtime/source'
|
||||
PYTHON = BASE / 'venv/bin/python'
|
||||
SETTINGS = ('profiles.json', 'endpoint.json', 'audio-policy.json', 'cpu-partition.json')
|
||||
|
||||
|
||||
def hashes():
|
||||
return {n: hashlib.sha256((STATE / n).read_bytes()).hexdigest() for n in SETTINGS}
|
||||
|
||||
|
||||
def translate(obj):
|
||||
if isinstance(obj, str):
|
||||
return obj.replace('/var/lib/deck/', str(STATE) + '/')
|
||||
if isinstance(obj, list):
|
||||
return [translate(v) for v in obj]
|
||||
if isinstance(obj, dict):
|
||||
return {k: translate(v) for k, v in obj.items()}
|
||||
return obj
|
||||
|
||||
|
||||
def main(key, run):
|
||||
run.mkdir(parents=True, exist_ok=False)
|
||||
result = dict(started_at=time.time(), previous_profile=None, arms={}, restored=False)
|
||||
(BASE / 'active-run.txt').write_text(str(run) + '\n')
|
||||
deadline = time.monotonic() + 7200
|
||||
owned = None
|
||||
measurement = None
|
||||
original_stopped = False
|
||||
|
||||
def save(phase):
|
||||
result['phase'] = phase
|
||||
result['updated_at'] = time.time()
|
||||
temp = run / 'result.tmp'
|
||||
temp.write_text(json.dumps(result, indent=2) + '\n')
|
||||
temp.replace(run / 'result.json')
|
||||
print(phase, flush=True)
|
||||
|
||||
def api(path, body=None, timeout=15):
|
||||
req = urllib.request.Request('http://127.0.0.1:' + ('8120' if path.startswith('/v1/') else '8108') + path,
|
||||
data=json.dumps(body).encode() if body is not None else None,
|
||||
headers={'Authorization': 'Bearer ' + key, 'Content-Type': 'application/json'})
|
||||
with urllib.request.urlopen(req, timeout=timeout) as response:
|
||||
return json.load(response)
|
||||
|
||||
def idle():
|
||||
stop = time.monotonic() + 1800
|
||||
clean = 0
|
||||
while time.monotonic() < stop:
|
||||
if api('/api/v1/status')['endpoint']['active_requests'] == 0:
|
||||
clean += 1
|
||||
if clean >= 3:
|
||||
return
|
||||
else:
|
||||
clean = 0
|
||||
time.sleep(1)
|
||||
raise RuntimeError('No idle window; productive requests left untouched')
|
||||
|
||||
def abort_check():
|
||||
if (run / 'stop.request').exists() or time.monotonic() > deadline:
|
||||
raise RuntimeError('Own test stop requested or overall time limit')
|
||||
|
||||
def stop_owned():
|
||||
nonlocal owned, measurement
|
||||
if measurement and measurement.poll() is None:
|
||||
measurement.terminate()
|
||||
try:
|
||||
measurement.wait(timeout=8)
|
||||
except subprocess.TimeoutExpired:
|
||||
measurement.kill()
|
||||
measurement.wait()
|
||||
measurement = None
|
||||
if owned and owned.poll() is None:
|
||||
os.killpg(owned.pid, signal.SIGTERM)
|
||||
try:
|
||||
owned.wait(timeout=30)
|
||||
except subprocess.TimeoutExpired:
|
||||
os.killpg(owned.pid, signal.SIGKILL)
|
||||
owned.wait()
|
||||
owned = None
|
||||
|
||||
def production_priority_check():
|
||||
if api('/api/v1/status')['endpoint']['active_requests']:
|
||||
time.sleep(.5)
|
||||
if api('/api/v1/status')['endpoint']['active_requests']:
|
||||
raise RuntimeError('Productive request arrived; only owned synthetic worker is stopped')
|
||||
|
||||
def worker_get(port, token, path):
|
||||
req = urllib.request.Request('http://127.0.0.1:' + str(port) + path,
|
||||
headers={'Authorization': 'Bearer ' + token})
|
||||
with urllib.request.urlopen(req, timeout=3) as response:
|
||||
return json.load(response)
|
||||
|
||||
def on_signal(signum, frame):
|
||||
raise InterruptedError('Own comparison interrupted')
|
||||
|
||||
signal.signal(signal.SIGTERM, on_signal)
|
||||
signal.signal(signal.SIGINT, on_signal)
|
||||
try:
|
||||
save('waiting_for_idle')
|
||||
idle()
|
||||
current = json.loads((STATE / 'strata-worker/worker.json').read_text())
|
||||
assert 'IQ3_XXS' in current['args'][current['args'].index('--native') + 1], 'Expected existing XXS production worker'
|
||||
result['previous_profile'] = current['model_name']
|
||||
result['settings_before'] = hashes()
|
||||
result['endpoint_before'] = api('/api/v1/status')['endpoint']
|
||||
clean = {k: v for k, v in current.items() if k not in ('api_key', 'key')}
|
||||
(run / 'qwen-template.json').write_text(json.dumps(clean, indent=2) + '\n')
|
||||
candidates = []
|
||||
accepted_paths = {b'/var/lib/deck/strata-worker/worker.json', str(STATE / 'strata-worker/worker.json').encode()}
|
||||
for p in Path('/proc').iterdir():
|
||||
if not p.name.isdigit():
|
||||
continue
|
||||
try:
|
||||
args = (p / 'cmdline').read_bytes().split(b'\0')
|
||||
if accepted_paths.intersection(args) and any(a.endswith(b'/serve/server.py') for a in args):
|
||||
candidates.append(int(p.name))
|
||||
except OSError:
|
||||
pass
|
||||
if len(candidates) != 1:
|
||||
raise RuntimeError('Original worker identity is not unique')
|
||||
pid = candidates[0]
|
||||
if os.getpgid(pid) != pid:
|
||||
raise RuntimeError('Original worker has unexpected process-group ownership')
|
||||
# The exact server PID supplies its network namespace for either a
|
||||
# native service or today's container transport; no Docker dependency.
|
||||
check = "import json,sys,urllib.request;x=json.load(sys.stdin);r=urllib.request.Request('http://127.0.0.1:'+str(x['port'])+'/v1/status',headers={'Authorization':'Bearer '+x['api_key']});d=json.load(urllib.request.urlopen(r,timeout=5));print(json.dumps(d.get('activity',{}).get('in_flight')))"
|
||||
for _ in range(600):
|
||||
idle()
|
||||
active = json.loads(subprocess.check_output(['nsenter', '-t', str(pid), '-n', 'python3', '-c', check], input=json.dumps(current), text=True))
|
||||
if active == 0:
|
||||
break
|
||||
time.sleep(2)
|
||||
else:
|
||||
raise RuntimeError('Original worker is not idle')
|
||||
idle()
|
||||
save('unloading_idle_qwen')
|
||||
os.killpg(pid, signal.SIGTERM)
|
||||
original_stopped = True
|
||||
for _ in range(60):
|
||||
# Normal status polling lets Deck reap its completed Popen child.
|
||||
api('/api/v1/status')
|
||||
if not Path('/proc/' + str(pid)).exists():
|
||||
break
|
||||
time.sleep(1)
|
||||
else:
|
||||
raise RuntimeError('Original worker did not stop; no forced production kill')
|
||||
|
||||
cpus = json.loads((STATE / 'cpu-partition.json').read_text())['strata']
|
||||
result['cpu_affinity'] = cpus
|
||||
for arm in ('qwen', 'deepseek'):
|
||||
abort_check()
|
||||
idle()
|
||||
cfg = translate(clean) if arm == 'qwen' else json.loads((BASE / 'test-config.json').read_text())
|
||||
if arm == 'qwen':
|
||||
cfg.pop('vision', None)
|
||||
cfg['args'] = [a for a in cfg['args'] if a != '--vision']
|
||||
cfg.update(host='127.0.0.1', port=19084, api_key='local-synthetic-comparison',
|
||||
open_browser=False, log=str(run / (arm + '-engine.log')))
|
||||
cfg_path = run / (arm + '-config.json')
|
||||
cfg_path.write_text(json.dumps(cfg, indent=2) + '\n')
|
||||
source = SOURCE if arm == 'qwen' else BASE / 'source'
|
||||
env = dict(os.environ, **cfg.get('env', {}), CUDA_VISIBLE_DEVICES='0,1', PYTHONUNBUFFERED='1')
|
||||
libs = [str(STATE / 'strata-runtime/cuda/lib64'), str(STATE / 'strata-runtime/cuda/lib')] if arm == 'qwen' else cfg.get('lib_dirs', [])
|
||||
env['LD_LIBRARY_PATH'] = ':'.join(libs + [env.get('LD_LIBRARY_PATH', '')])
|
||||
cmd = ['taskset', '-c', ','.join(map(str, cpus)), str(PYTHON), str(source / 'serve/server.py'),
|
||||
'--engine', 'strata', '--config', str(cfg_path), '--host', '127.0.0.1', '--port', '19084', '--fit-max-tokens']
|
||||
save('loading_' + arm)
|
||||
started = time.monotonic()
|
||||
with (run / (arm + '-server.log')).open('w') as log:
|
||||
owned = subprocess.Popen(cmd, env=env, cwd=source, stdout=log, stderr=subprocess.STDOUT, start_new_session=True)
|
||||
ready_deadline = time.monotonic() + (900 if arm == 'qwen' else 1800)
|
||||
while time.monotonic() < ready_deadline:
|
||||
abort_check()
|
||||
production_priority_check()
|
||||
if owned.poll() is not None:
|
||||
raise RuntimeError(arm + ' test worker exited during loading')
|
||||
try:
|
||||
health = worker_get(19084, cfg['api_key'], '/health')
|
||||
if health.get('status') == 'ok' and health.get('loaded', True):
|
||||
break
|
||||
except OSError:
|
||||
pass
|
||||
time.sleep(2)
|
||||
else:
|
||||
raise TimeoutError(arm + ' loading timeout')
|
||||
result['arms'][arm] = dict(load_seconds=time.monotonic() - started, health=health,
|
||||
context=cfg['args'][cfg['args'].index('--max-context') + 1])
|
||||
for phase in ('speed', 'quality'):
|
||||
save(arm + '_' + phase)
|
||||
args = [str(PYTHON), str(BASE / 'measure.py'), '--arm', arm, '--output', str(run / (phase + '-' + arm + '.jsonl')), '--run']
|
||||
if phase == 'speed':
|
||||
args.append('--speed-only')
|
||||
with (run / (arm + '-measure.log')).open('a') as log:
|
||||
measurement = subprocess.Popen(args, env=dict(env, TEST_API_KEY=cfg['api_key']), cwd=BASE, stdout=log, stderr=subprocess.STDOUT)
|
||||
while measurement.poll() is None:
|
||||
abort_check()
|
||||
production_priority_check()
|
||||
if owned.poll() is not None:
|
||||
raise RuntimeError(arm + ' worker failed during measurement')
|
||||
time.sleep(1)
|
||||
if measurement.returncode:
|
||||
raise RuntimeError(arm + ' measurement harness failed')
|
||||
result['arms'][arm][phase + '_rows'] = sum(1 for _ in (run / (phase + '-' + arm + '.jsonl')).open())
|
||||
# Engines start separate process groups: the pilot's group-only
|
||||
# counters were empty, so do not publish a false physical-read zero.
|
||||
result['arms'][arm]['engine_read_bytes_during_measurement'] = None
|
||||
result['arms'][arm]['io_counter_coverage'] = False
|
||||
stop_owned()
|
||||
save(arm + '_finished')
|
||||
except BaseException as exc:
|
||||
result['error'] = type(exc).__name__ + ': ' + str(exc)
|
||||
print(result['error'], flush=True)
|
||||
finally:
|
||||
stop_owned()
|
||||
if original_stopped:
|
||||
save('restoring_qwen')
|
||||
try:
|
||||
idle()
|
||||
body = dict(model=result['previous_profile'], messages=[dict(role='user', content='Antworte mit OK.')],
|
||||
max_tokens=1, temperature=0, reasoning_effort='none')
|
||||
answer = api('/v1/chat/completions', body, timeout=900)
|
||||
restored = json.loads((STATE / 'strata-worker/worker.json').read_text())
|
||||
result['restored'] = bool(answer.get('choices')) and restored['model_name'] == result['previous_profile']
|
||||
result['restored_profile'] = restored['model_name']
|
||||
result['endpoint_after'] = api('/api/v1/status')['endpoint']
|
||||
except Exception as exc:
|
||||
result['restore_error'] = type(exc).__name__ + ': ' + str(exc)
|
||||
result['settings_after'] = hashes()
|
||||
result['settings_unchanged'] = result.get('settings_before') == result['settings_after']
|
||||
result['finished_at'] = time.time()
|
||||
save('complete' if result['restored'] and 'error' not in result else 'finished_with_error')
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
ap = argparse.ArgumentParser(description=__doc__)
|
||||
ap.add_argument('--detach', action='store_true')
|
||||
a = ap.parse_args()
|
||||
key = json.load(sys.stdin)['key']
|
||||
run = BASE / 'runs' / (time.strftime('%Y%m%dT%H%M%SZ', time.gmtime()) + '-' + secrets.token_hex(3))
|
||||
if a.detach:
|
||||
pid = os.fork()
|
||||
if pid:
|
||||
print(json.dumps(dict(pid=pid, directory=str(run))))
|
||||
sys.exit(0)
|
||||
os.setsid()
|
||||
fd = os.open(str(BASE / 'comparison-controller.log'), os.O_WRONLY | os.O_CREAT | os.O_APPEND, 0o600)
|
||||
os.dup2(fd, 1)
|
||||
os.dup2(fd, 2)
|
||||
os.close(fd)
|
||||
fd = os.open('/dev/null', os.O_RDONLY)
|
||||
os.dup2(fd, 0)
|
||||
os.close(fd)
|
||||
main(key, run)
|
||||
@@ -0,0 +1,37 @@
|
||||
"""Backend timing aggregation only; never presents wall throughput as decode."""
|
||||
import json
|
||||
from pathlib import Path
|
||||
import statistics
|
||||
import sys
|
||||
|
||||
stage = Path(sys.argv[1])
|
||||
out = {}
|
||||
for arm in ['qwen', 'deepseek']:
|
||||
out[arm] = {}
|
||||
for phase in ['speed', 'quality']:
|
||||
path = stage / (phase + '-' + arm + '.jsonl')
|
||||
rows = [json.loads(line) for line in path.read_text().splitlines()] if path.exists() else []
|
||||
steps = [step for row in rows for step in row['steps']]
|
||||
timings = [step['timings'] for step in steps if step.get('timings')]
|
||||
|
||||
def rate(n, ms):
|
||||
valid = [t for t in timings if isinstance(t.get(n), (int, float)) and t.get(ms, 0) > 0]
|
||||
return sum(t[n] for t in valid) / sum(t[ms] for t in valid) * 1000 if valid else None
|
||||
|
||||
rates = [t['predicted_per_second'] for t in timings if t.get('predicted_per_second') is not None]
|
||||
out[arm][phase] = dict(cases=len(rows), errors=sum(bool(r.get('error')) for r in rows),
|
||||
truncated=sum(bool(r.get('truncated')) for r in rows),
|
||||
prompt_tokens=sum(s.get('usage', {}).get('prompt_tokens', 0) for s in steps),
|
||||
cached_tokens=sum(s.get('usage', {}).get('prompt_tokens_details', {}).get('cached_tokens', 0) for s in steps),
|
||||
output_tokens=sum(s.get('usage', {}).get('completion_tokens', 0) for s in steps),
|
||||
fresh_prompt_tokens=sum(t.get('prompt_n', 0) for t in timings),
|
||||
input_tokens_per_second=rate('prompt_n', 'prompt_ms'),
|
||||
output_tokens_per_second=rate('predicted_n', 'predicted_ms'),
|
||||
decode_median=statistics.median(rates) if rates else None,
|
||||
decode_range=[min(rates), max(rates)] if rates else None,
|
||||
steps=len(steps), backend_timing_steps=len(timings),
|
||||
request_wall_seconds=sum(s['wall_s'] for s in steps))
|
||||
if phase == 'speed':
|
||||
out[arm][phase]['individual'] = [dict(case_id=r['case_id'], steps=r['steps'], error=r.get('error')) for r in rows]
|
||||
(stage / 'metrics-summary.json').write_text(json.dumps(out, indent=2) + '\n')
|
||||
print(json.dumps(out, indent=2))
|
||||
@@ -0,0 +1,64 @@
|
||||
{
|
||||
"model": "DeepSeek-V4.1-Flash-1017",
|
||||
"quant": "IQ2_XXS",
|
||||
"source_tag": "v0.2.4",
|
||||
"total_bytes": 256816878701,
|
||||
"files": [
|
||||
{
|
||||
"name": "DeepSeek-V4.1-Flash-1017-GSQ-RCO-IQ2_XXS-00001-of-00004.gguf",
|
||||
"size": 39075714624,
|
||||
"sha256": "d46efb67ccffd8fb5d7f18b423896381b9e06d8491e161c370ddf3b05b07e050",
|
||||
"repo": "ISTA-DASLab/DeepSeek-V4.1-Flash-1017-GSQ-RCO-GGUF",
|
||||
"revision": "cb02422c900df489cea5833e8a92171224059b3c",
|
||||
"path": "DeepSeek-V4.1-Flash-1017-GSQ-RCO-IQ2_XXS-00001-of-00004.gguf"
|
||||
},
|
||||
{
|
||||
"name": "DeepSeek-V4.1-Flash-1017-GSQ-RCO-IQ2_XXS-00002-of-00004.gguf",
|
||||
"size": 39388449504,
|
||||
"sha256": "cec1b2c3da429dc768b8bb9bc4dc4403d81f74d34db660a6a34ee3e555bf2c70",
|
||||
"repo": "ISTA-DASLab/DeepSeek-V4.1-Flash-1017-GSQ-RCO-GGUF",
|
||||
"revision": "cb02422c900df489cea5833e8a92171224059b3c",
|
||||
"path": "DeepSeek-V4.1-Flash-1017-GSQ-RCO-IQ2_XXS-00002-of-00004.gguf"
|
||||
},
|
||||
{
|
||||
"name": "DeepSeek-V4.1-Flash-1017-GSQ-RCO-IQ2_XXS-00003-of-00004.gguf",
|
||||
"size": 39246891616,
|
||||
"sha256": "9d9c2140fcb134a0b9a74dedd0e5167e68077af6d08ce7f856bce112f0a35dd3",
|
||||
"repo": "ISTA-DASLab/DeepSeek-V4.1-Flash-1017-GSQ-RCO-GGUF",
|
||||
"revision": "cb02422c900df489cea5833e8a92171224059b3c",
|
||||
"path": "DeepSeek-V4.1-Flash-1017-GSQ-RCO-IQ2_XXS-00003-of-00004.gguf"
|
||||
},
|
||||
{
|
||||
"name": "DeepSeek-V4.1-Flash-1017-GSQ-RCO-IQ2_XXS-00004-of-00004.gguf",
|
||||
"size": 20527837312,
|
||||
"sha256": "9b790a2297ed3cdede379fc984f4a52bb95f3b23724c797af11d1fa6a69db059",
|
||||
"repo": "ISTA-DASLab/DeepSeek-V4.1-Flash-1017-GSQ-RCO-GGUF",
|
||||
"revision": "cb02422c900df489cea5833e8a92171224059b3c",
|
||||
"path": "DeepSeek-V4.1-Flash-1017-GSQ-RCO-IQ2_XXS-00004-of-00004.gguf"
|
||||
},
|
||||
{
|
||||
"name": "DeepSeek-V4.1-Flash-Engram-IQ4_NL.gguf",
|
||||
"size": 110595290816,
|
||||
"sha256": "eb19f30d368d393784e1fc54fdfaffc427ebb2110bf3762fdf5a8fbb9a2d740a",
|
||||
"repo": "ISTA-DASLab/DeepSeek-V4.1-Flash-1017-GSQ-RCO-GGUF",
|
||||
"revision": "cb02422c900df489cea5833e8a92171224059b3c",
|
||||
"path": "DeepSeek-V4.1-Flash-Engram-IQ4_NL.gguf"
|
||||
},
|
||||
{
|
||||
"name": "DeepSeek-V4.1-Flash-1017-UD-Q8_K_XL-00001-of-00009.gguf",
|
||||
"size": 5780589,
|
||||
"sha256": "cc15d470afcb030558bbc4d8e2ccd840182e2e95de1a95198138efe63a5fd99f",
|
||||
"repo": "unsloth/DeepSeek-V4.1-Flash-1017-GGUF",
|
||||
"revision": "f924b94f19c1fea02c06a65c8475b0a45e2b88b1",
|
||||
"path": "UD-Q8_K_XL/DeepSeek-V4.1-Flash-1017-UD-Q8_K_XL-00001-of-00009.gguf"
|
||||
},
|
||||
{
|
||||
"name": "dspark-DeepSeek-V4.1-Flash-1017-Q8_0.gguf",
|
||||
"size": 7976914240,
|
||||
"sha256": "6ba6ac1b331c540691a209e7fc97dec2a24e295acb1e755c84c7d24a4373927a",
|
||||
"repo": "unsloth/DeepSeek-V4.1-Flash-1017-GGUF",
|
||||
"revision": "f924b94f19c1fea02c06a65c8475b0a45e2b88b1",
|
||||
"path": "dspark-DeepSeek-V4.1-Flash-1017-Q8_0.gguf"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,103 @@
|
||||
# KittenTTS 2 native C++ CPU speed gate · 27 October 2026
|
||||
|
||||
Michael authorized **one short speed gate first** on Athena CPU. If too slow,
|
||||
stop and clean up immediately. No Anna cloning, quality matrix, alternate
|
||||
decoders, source builds or performance-tuning series was authorized by this run.
|
||||
Production Qwen was to remain unchanged.
|
||||
|
||||
## Exact tested path
|
||||
|
||||
- Official prebuilt native `kitten_tts_cpp` wheel 0.2.0, CPython 3.13,
|
||||
Linux x86-64 manylinux 2.34. Publisher wheel hash is in `package-pin.json`.
|
||||
Wheel build metadata requires Torch 2.13.0 and marks it portable.
|
||||
- Own Python 3.13 venv with `torch==2.13.0+cpu`, NumPy 2.2.6,
|
||||
SoundFile 0.13.1, certifi 2026.10.23. No CUDA/NVIDIA package and no GPU runtime.
|
||||
Complete resolved requirements are retained.
|
||||
- Public model `KittenML/kitten-tts-2`, pinned revision
|
||||
`c93cb7c271baa51d9ae8204d5277988906f235a2`.
|
||||
- Only config, native TQ2_1 GGUF, recommended `student_w4` CPU TorchScript
|
||||
decoder and its matching prepared voices were downloaded. The three LFS
|
||||
files matched publisher SHA256/size metadata; see `download-manifest.json`.
|
||||
- Local assets, offline mode, `device='cpu'`, repacking disabled, four LM and
|
||||
four decoder threads, built-in `German` reference, stable preset and seed 42.
|
||||
German normalization disabled as instructed by the publisher. No Anna audio
|
||||
or private voice preparation was needed for this initial speed gate.
|
||||
- The Python binding invokes the actual persistent C++/GGML engine and CPU
|
||||
LibTorch waveform decoder. This is not Python-transformer inference. No
|
||||
custom compiler build or alternative format was substituted.
|
||||
|
||||
The working filter was stated before measuring: at least five seconds of speech
|
||||
per second computing (RTF ≤0.2) for useful reserve. This is a conservative
|
||||
minimum filter chosen for this test, not a claim that Michael specified that
|
||||
exact number or that passing it would match Articulino's measured throughput.
|
||||
|
||||
## Minimal protocol and result
|
||||
|
||||
Model import/initialization: 2.111 s. The publisher warns that the initial
|
||||
decoder calls can include JIT effects, so two tiny `Hallo.` calls were separated
|
||||
as setup, then exactly one scored short German probe was attempted:
|
||||
|
||||
> Anna öffnete das Fenster und hörte drei Vögel im Garten singen.
|
||||
|
||||
| Stage | Speech duration | Measured call time | Native LM time | Native decoder time |
|
||||
| --- | ---: | ---: | ---: | ---: |
|
||||
| Tiny warmup 1 | 0.96 s | 12.554 s | 11.334 s | 1.209 s |
|
||||
| Tiny warmup 2 | 0.96 s | 12.738 s | 11.355 s | 1.373 s |
|
||||
| Single scored probe | Not completed | Stopped after 20.043 s | Unavailable | Unavailable |
|
||||
|
||||
The supervisor terminated **only its own test process group** when the probe
|
||||
exceeded the predefined twenty-second limit. No further inference, voice test,
|
||||
STT, model variant or thread sweep was run. Do not invent a completed-probe RTF,
|
||||
token rate or voice-quality score. The approximately 13×-realtime time of the
|
||||
tiny setup calls is not reported as the warm throughput of a completed long
|
||||
passage; the setup timings and independent probe timeout are the actual evidence.
|
||||
|
||||
Decision: this published native C++ path under the specified Athena allocation
|
||||
fails the required short-latency speed gate and was rejected. This does not
|
||||
establish maximum throughput on all CPUs, different kernels or a manual build.
|
||||
No Anna similarity, German naturalness or Hermes playback claim was made.
|
||||
|
||||
## Limits, preservation and cleanup
|
||||
|
||||
Both preparation and speed runs were transient host systemd units. Speed unit:
|
||||
MemoryMax 4 GiB, no swap, CPUQuota 400%, affinity 2–5/8–11, nice 10, private
|
||||
devices, no new privileges, UMask 0077 and a three-minute maximum lifetime.
|
||||
Admission reserved the hard budget plus 2 GiB available host memory. A separate
|
||||
stdlib supervisor bounded initialization and each synthesis stage and would
|
||||
stop its own child on low host memory. No production guard was lowered.
|
||||
|
||||
After rejection both own units were inactive. The entire isolated root
|
||||
`/data/athena-kitten-cpu-20261027` was removed: original selected weights,
|
||||
wheel, native binding, own CPU Torch environment, pip/cache files and test data.
|
||||
Pre-deletion allocated file blocks totaled **2,772,103,168 bytes (2.58 GiB)**.
|
||||
The root was verified absent. No shared cache or Docker pruning was used.
|
||||
Only these small synthetic measurements, public pins and reproduction scripts
|
||||
remain; there is no retained Kitten model or background service.
|
||||
|
||||
Before/after checks matched for production profiles, endpoint, audio policy,
|
||||
CPU partition, original Anna reference, canonical/live Qwen worker and Deck
|
||||
start time. Articulino was preserved. No model switch, Qwen request, unload,
|
||||
service restart, Mac change or Hermes integration was performed.
|
||||
|
||||
## Native reproduction
|
||||
|
||||
On compatible native Debian x86-64, create a separate Python 3.13 venv. Restore
|
||||
the public pinned metadata from this directory; fetch only the four listed
|
||||
native assets at the recorded revision and verify their hashes. Install CPU
|
||||
Torch 2.13.0 from the official CPU wheel index, remaining pinned requirements
|
||||
and the hash-verified native wheel with dependency installation disabled.
|
||||
No compiler, CUDA, Docker or existing production container is required.
|
||||
|
||||
The own scripts use explicit Athena paths: adapt their isolated root deliberately,
|
||||
then run preparation and the supervisor under equivalent limits. The supervisor
|
||||
launches `speed.py` with local/offline assets. Do not use these rejected test
|
||||
files as a production installer. A native full Deck restore or client playback
|
||||
test is outside this experiment. No private reference data or credentials are
|
||||
needed for this built-in-voice speed gate.
|
||||
|
||||
Sources checked:
|
||||
|
||||
- [Official C++ runtime](https://github.com/KittenML/kitten-tts-2-cpp)
|
||||
- [Native implementation guide](https://github.com/KittenML/kitten-tts-2-cpp/blob/main/tools/kitten-tts/README.md)
|
||||
- [German voice and normalization instructions](https://github.com/KittenML/KittenTTS/blob/main/docs/voices-and-expression.md)
|
||||
- [Official model](https://huggingface.co/KittenML/kitten-tts-2)
|
||||
Loaded 100 of 332 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user