MCPcopy Create free account

hub / github.com/disler/live-bench / functions

Functions371 in github.com/disler/live-bench

↓ 1 callersFunctionnonce_prompt
Prefix a unique nonce so every measured run is a true cache miss.
apps/benchmarks/context-scaling/_harness.py:67
↓ 1 callersFunctionnonce_prompt
Prefix a unique nonce so every measured run is a true cache miss.
apps/benchmarks/qwen36-vs-qwen35-vs-gemma4/_harness.py:67
↓ 1 callersFunctionnonce_prompt
Prefix a unique nonce so every measured run is a true cache miss.
apps/benchmarks/qwen35-vs-gemma4/_harness.py:67
↓ 1 callersFunctionnow_ts
Return the current wall-clock instant as an aware UTC ``datetime``. This is the **single source of CLI timestamps** for the whole package. Ev
apps/cli/src/live_bench_cli/client.py:27
↓ 1 callersFunctionollama_chat
Single Ollama /api/chat call with keep_alive=-1. Always returns the same metrics dict shape as MLXRunner.generate(), so the same `run_warm_is
apps/benchmarks/context-scaling-3way/_harness.py:165
↓ 1 callersFunctionollama_chat
Single Ollama /api/chat call with keep_alive=-1. Always returns the same metrics dict shape as MLXRunner.generate(), so the same `run_warm_is
apps/benchmarks/context-scaling/_harness.py:165
↓ 1 callersFunctionping_mlx
Boot MLX runner, send one prompt, shut down. Returns metrics.
apps/benchmarks/ping/run.py:78
↓ 1 callersFunctionping_ollama
Single Ollama /api/chat call, returns metrics.
apps/benchmarks/ping/run.py:46
↓ 1 callersFunctionreadDensity
()
apps/frontend/src/stores/prefs.ts:39
↓ 1 callersFunctionreadTheme
()
apps/frontend/src/stores/prefs.ts:27
↓ 1 callersFunctionrun_pi_task
Invoke Pi in non-interactive JSON mode, parse agent_end event.
apps/benchmarks/pi-coding-agent/_pi_runner.py:132
↓ 1 callersFunctionrun_pi_task
Invoke Pi in non-interactive JSON mode, parse agent_end event.
apps/benchmarks/pi-coding-agent-3way/_pi_runner.py:132
↓ 1 callersFunctionsample_speed
Return a slightly jittered speed so each mock run looks fresh.
apps/benchmarks/mock-test/run.py:60
↓ 1 callersMethodset_prompt
(self, task_key: str, prompt_text: str)
apps/benchmarks/pi-coding-agent/bench.py:76
↓ 1 callersMethodset_prompt
(self, task_key: str, prompt_text: str)
apps/benchmarks/pi-coding-agent-3way/bench.py:80
↓ 1 callersFunctionsetup_task_dir
Create a fresh temp dir with any required fixtures copied in.
apps/benchmarks/pi-coding-agent/_tasks.py:459
↓ 1 callersFunctionsetup_task_dir
Create a fresh temp dir with any required fixtures copied in.
apps/benchmarks/pi-coding-agent-3way/_tasks.py:459
↓ 1 callersMethodsubscribe
Create a new queue subscribed to events for ``session_id``.
apps/backend/src/live_bench_server/broker.py:32
↓ 1 callersFunctiontest_mlx
(model_path)
apps/benchmarks/peak_rss_test.py:93
↓ 1 callersFunctiontest_ollama
(model, label)
apps/benchmarks/peak_rss_test.py:63
↓ 1 callersFunctiontruncate
Collapse whitespace and truncate for display.
apps/benchmarks/ping/run.py:159
↓ 1 callersMethodunsubscribe
Remove a previously-subscribed queue. Safe to call repeatedly.
apps/backend/src/live_bench_server/broker.py:38
↓ 1 callersFunctionwarmup_model
Quick Pi call to ensure model/provider are valid and the model is loaded.
apps/benchmarks/pi-coding-agent/_pi_runner.py:186
↓ 1 callersFunctionwarmup_model
Quick Pi call to ensure model/provider are valid and the model is loaded.
apps/benchmarks/pi-coding-agent-3way/_pi_runner.py:186
Method__enter__
(self)
apps/cli/src/live_bench_cli/client.py:92
Method__enter__
(self)
apps/cli/tests/test_commands.py:47
Method__exit__
(self, exc_type, exc, tb)
apps/cli/src/live_bench_cli/client.py:95
Method__exit__
(self, exc_type, exc, tb)
apps/cli/tests/test_commands.py:50
Method__init__
(self, queue_cap: int = 1024)
apps/backend/src/live_bench_server/broker.py:26
Method__init__
( self, status_code: int, code: str | None = None, message: str | None = None,
apps/cli/src/live_bench_cli/client.py:49
Method__init__
(self, base_url: str, timeout: float = 10.0)
apps/cli/src/live_bench_cli/client.py:80
Method__init__
(self, base_url: str, timeout: float = 10.0)
apps/cli/tests/test_commands.py:39
Method__init__
(self, pid, interval=0.05)
apps/benchmarks/peak_rss_test.py:30
Method__init__
(self, mlx_python: Path, runner_script: Path, model: str, *, ready_timeout: float = 600.0)
apps/benchmarks/context-scaling-3way/_harness.py:85
Method__init__
(self, hw: str, server: str)
apps/benchmarks/context-scaling-3way/bench.py:118
Method__init__
(self, hw: str, server: str)
apps/benchmarks/pi-coding-agent/bench.py:70
Method__init__
(self, mlx_python: Path, runner_script: Path, model: str, *, ready_timeout: float = 600.0)
apps/benchmarks/context-scaling/_harness.py:85
Method__init__
(self, hw: str, server: str)
apps/benchmarks/context-scaling/bench.py:108
Method__init__
(self, mlx_python: Path, runner_script: Path, model: str, *, ready_timeout: float = 600.0)
apps/benchmarks/qwen36-vs-qwen35-vs-gemma4/_harness.py:85
Method__init__
(self, hw: str, server: str)
apps/benchmarks/qwen36-vs-qwen35-vs-gemma4/bench.py:121
Method__init__
(self, hw: str, server: str)
apps/benchmarks/pi-coding-agent-3way/bench.py:74
Method__init__
(self, mlx_python: Path, runner_script: Path, model: str, *, ready_timeout: float = 600.0)
apps/benchmarks/qwen35-vs-gemma4/_harness.py:85
Method__init__
(self, hw: str, server: str)
apps/benchmarks/qwen35-vs-gemma4/bench.py:115
Method_coerce_string_complete_groups
Backward compat: bare strings are coerced to default-chart CompletionRefs. The original CLI shipped ``complete_groups: ["alpha", "bravo"]``.
apps/backend/src/live_bench_server/models.py:339
Method_emit_meta
(chart: str, data: dict)
apps/benchmarks/context-scaling-3way/bench.py:177
Method_emit_meta
(chart: str, data: dict)
apps/benchmarks/context-scaling/bench.py:167
Method_exactly_one_form
(self)
apps/backend/src/live_bench_server/models.py:235
Method_normalize_chart_form
(self)
apps/backend/src/live_bench_server/models.py:147
Method_poll
(self)
apps/benchmarks/peak_rss_test.py:37
Function_reader_thread
Read lines off ``stream`` and push (stamped_point_or_control, ts) tuples. The reader stamps ``client_ts`` the moment it pops a line so the time
apps/cli/src/live_bench_cli/commands/stream_cmd.py:38
Function_reset_fake_clients
()
apps/cli/tests/test_commands.py:71
Method_serialize_any
(self, value)
apps/backend/src/live_bench_server/models.py:75
FunctionapplyDatapoint
* Apply a single live datapoint with the §14.4 newer-wins guard. * * Comparison is direct string comparison on the ISO-8601 timestamps — bot
apps/frontend/src/stores/session.ts:112
FunctionapplyDatasetComplete
(chart_id: string, group_key: string, completed_at: string)
apps/frontend/src/stores/session.ts:149
FunctionapplyMetadata
* Apply metadata for a (chart, group) pair. Merges into existing — * the backend already performs the deep merge, so we just replace.
apps/frontend/src/stores/session.ts:165
FunctionapplyReset
* Wipe all live values but keep the dataset list. Each dataset's status * is reset to `pending`; this is what the user sees after a `reset`
apps/frontend/src/stores/session.ts:190
FunctionapplySnapshot
* Replace all session state from a fresh /stream snapshot. The backend * delivers `points` already as latest-per-cell ordered by `client_ts`,
apps/frontend/src/stores/session.ts:79
Functionclear
Reset everything — used by BenchmarkPage on unmount before reconnect.
apps/frontend/src/stores/session.ts:207
FunctionclearCompleted
(chartId: string)
apps/frontend/src/stores/session.ts:178
FunctionclearUpdated
Clear flash signal for a chart (called by BenchmarkCard after animation).
apps/frontend/src/stores/session.ts:173
Functionclient
Return a FastAPI TestClient bound to an isolated DB + broker. We monkeypatch ``LIVEBENCH_DB_PATH`` so the lifespan opens the temp DB, then po
apps/backend/tests/conftest.py:74
Functioncomplete
Mark one or more groups as complete for a session.
apps/cli/src/live_bench_cli/commands/complete_cmd.py:30
Functionconnect
Open a sqlite3 connection in WAL mode with foreign keys enabled. ``check_same_thread=False`` so the FastAPI event loop and uvicorn worker thr
apps/backend/src/live_bench_server/db.py:28
FunctionconnectStream
(sessionId: string, handlers: StreamHandlers)
apps/frontend/src/api/stream.ts:46
Functiondataset_states
Return one ``DatasetState`` per ``(chart, group)`` pair defined in the config. Status derivation (spec §4.1, chart-aware): - ``complete``
apps/backend/src/live_bench_server/store.py:388
Functionemit
Emit one or many datapoints to a session.
apps/cli/src/live_bench_cli/commands/emit_cmd.py:123
FunctiongetBenchmark
(sessionId: string)
apps/frontend/src/api/rest.ts:37
Functionget_all_metadata
Return all metadata for a session as ``{"chart_id:group_key": data_dict, ...}``.
apps/backend/src/live_bench_server/store.py:243
Functionget_benchmark
(request: Request, session_id: str)
apps/backend/src/live_bench_server/rest.py:48
FunctiongradientIdFor
(sessionId: string, metricKey: string)
apps/frontend/src/components/gradient.ts:5
Functionhandler
(request: httpx.Request)
apps/cli/tests/test_client.py:89
Functionhealthz
()
apps/backend/src/live_bench_server/rest.py:26
Functioningest
Accept a batch of datapoints and/or group completions for a session.
apps/backend/src/live_bench_server/http_ingest.py:44
Functioninsert_points
Insert a batch of datapoints and return their stored forms. Assigns ``seq`` monotonically as ``current_max + 1, +2, +3, ...`` inside a single
apps/backend/src/live_bench_server/store.py:265
Functionlatest_per_cell
Return the newest-by-``client_ts`` datapoint for each (chart, group, metric) cell. Uses the ``ix_datapoints_cell_client_ts`` index. Cells with no
apps/backend/src/live_bench_server/store.py:464
Functionlifespan
(app: FastAPI)
apps/backend/src/live_bench_server/main.py:57
Functionlist_
List all benchmarks registered with the server.
apps/cli/src/live_bench_cli/commands/list_cmd.py:14
Functionlist_benchmarks
(request: Request)
apps/backend/src/live_bench_server/rest.py:41
Functionlist_benchmarks
Return one summary dict per benchmark for ``GET /benchmarks``. Each dict carries surface fields (``session_id``, ``title``, ``subtitle``, ``b
apps/backend/src/live_bench_server/store.py:104
Functionlive_server
Start a real Uvicorn server in a daemon thread; seed a sample session.
apps/backend/tests/test_sse_stream.py:80
Functionload_benchmarks_dir
Load every ``*.yaml`` file in ``path``. Returns a list of ``(benchmark_file, source_path)`` tuples, sorted by file name for deterministic ord
apps/backend/src/live_bench_server/config.py:18
Functionmark_complete
UPSERT completion rows; return ``(CompletionRef, completed_at)`` per ref. Uses a single server timestamp for the whole batch so all completions
apps/backend/src/live_bench_server/store.py:339
Functionmax_seq
Return the current max ``seq`` for a session, or 0 if empty.
apps/backend/src/live_bench_server/store.py:493
Functionmeta
Emit metadata for a (chart, group) pair.
apps/cli/src/live_bench_cli/commands/meta_cmd.py:30
Functionmigrate
Run the spec §4.1 migration. Idempotent — safe to call on every boot.
apps/backend/src/live_bench_server/db.py:158
Functionpatch_client
Patch ``LiveBenchClient`` everywhere the commands import it.
apps/cli/tests/test_commands.py:78
Functionping
Broadcast a ping event to all active SSE subscribers.
apps/backend/src/live_bench_server/rest.py:31
Functionping
Ping the backend and broadcast to all connected frontends.
apps/cli/src/live_bench_cli/commands/ping_cmd.py:17
Functionpoints_after_seq
Return all datapoints for a session with ``seq > last_seq``, in seq order. Used by the SSE stream to replay missed events after a ``Last-Event-ID
apps/backend/src/live_bench_server/store.py:502
Functionreset
Delete all datapoints + completions for a session; bump ``updated_at``. The ``benchmarks`` row itself is preserved — config is owned by YAML.
apps/backend/src/live_bench_server/store.py:158
Functionreset
Reset a benchmark session (wipes points + datasets).
apps/cli/src/live_bench_cli/commands/reset_cmd.py:15
FunctionresetBenchmark
(sessionId: string)
apps/frontend/src/api/rest.ts:45
Functionreset_benchmark
(request: Request, session_id: str)
apps/backend/src/live_bench_server/rest.py:72
Functionsample_config
()
apps/backend/tests/conftest.py:63
Functionseeded_db
(tmp_db: sqlite3.Connection, sample_config: BenchmarkConfig)
apps/backend/tests/conftest.py:68
FunctionsetDensity
(density: Density)
apps/frontend/src/stores/prefs.ts:66
FunctionsetTheme
(theme: ThemeName)
apps/frontend/src/stores/prefs.ts:55
Functionshow
Show config + latest-per-cell values + per-group status for a session.
apps/cli/src/live_bench_cli/commands/show_cmd.py:109
Functionstream
SSE endpoint for a single session.
apps/backend/src/live_bench_server/sse_stream.py:39
Functionstream
Read JSONL from stdin and POST batches to /ingest until EOF.
apps/cli/src/live_bench_cli/commands/stream_cmd.py:128
← previousnext →201–300 of 371, ranked by callers