Probe success line as a full sentence: model name, endpoint, response time, pool size, and what happens next
Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
470496b7ef
commit
20e9b87248
@ -555,12 +555,14 @@ async def _probe_model(adapter, model_spec: str) -> None:
|
||||
dur = time.monotonic() - _probe_model._t0 if hasattr(_probe_model, '_t0') else 0.0
|
||||
name = getattr(members[0], 'model', '') or '?'
|
||||
url = members[0].api_base
|
||||
txt = (f'· model endpoint ok · model={name} · endpoint={url} · '
|
||||
f'instances={len(members)} · probe={dur:.1f}s')
|
||||
txt = (f'· Model endpoint verified: "{name}" responded at {url} '
|
||||
f'in {dur:.1f}s ({len(members)} instance(s) in pool) -- '
|
||||
f'generation will use this endpoint')
|
||||
if _sys.stdout.isatty(): # color the machine-relevant facts on terminals
|
||||
txt = (f'· model endpoint ok · model=\x1b[1m{name}\x1b[0m · '
|
||||
f'endpoint=\x1b[36m{url}\x1b[0m · '
|
||||
f'instances={len(members)} · probe={dur:.1f}s')
|
||||
txt = (f'· Model endpoint verified: "\x1b[1m{name}\x1b[0m" responded at '
|
||||
f'\x1b[36m{url}\x1b[0m in {dur:.1f}s '
|
||||
f'({len(members)} instance(s) in pool) -- '
|
||||
f'generation will use this endpoint')
|
||||
print(txt, flush=True) # probe runs before status_callback exists
|
||||
_PROBED_SPECS.add(model_spec)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user