-
Notifications
You must be signed in to change notification settings - Fork 70
feat[notask]: add download profiler for registry blob performance diagnostics #1040
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
yuranich
merged 8 commits into
tetherto:main
from
yuranich:feat/registry-download-profiler
Mar 23, 2026
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
dad8170
feat[notask]: add download profiler for registry blob performance dia…
yuranich a65447d
fix: move profiler deps from devDependencies to dependencies
yuranich c97c65a
doc: add profile command and example to client README
yuranich 1a4f83e
fix: show full peer keys in profiler output for troubleshooting
yuranich ace959d
Merge branch 'main' into feat/registry-download-profiler
Proletter df7b702
Merge branch 'main' into feat/registry-download-profiler
simon-iribarren 0fdfc98
fix: validate parseInt results for interval and timeout CLI flags
yuranich 8ba0da4
Merge branch 'main' into feat/registry-download-profiler
yuranich File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
59 changes: 59 additions & 0 deletions
59
packages/qvac-lib-registry-server/client/examples/profile-download.js
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,59 @@ | ||
| 'use strict' | ||
|
|
||
| const path = require('path') | ||
| require('dotenv').config({ path: path.resolve(__dirname, '../../.env') }) | ||
|
|
||
| const { profileDownload } = require('../lib/profiler') | ||
|
|
||
| const REGISTRY_CORE_KEY = process.env.QVAC_REGISTRY_CORE_KEY | ||
| const STATS_INTERVAL_SEC = parseInt(process.env.PROFILE_INTERVAL || '5', 10) | ||
|
|
||
| function usage () { | ||
| console.log(` | ||
| Usage: node profile-download.js [model-path] [source] | ||
|
|
||
| model-path Path of the model to download (omit to list available models) | ||
| source Source filter, e.g. "hf" or "s3" (default: first match) | ||
|
|
||
| Environment: | ||
| QVAC_REGISTRY_CORE_KEY Registry view core key (required) | ||
| PROFILE_INTERVAL Stats print interval in seconds (default: 5) | ||
|
|
||
| Examples: | ||
| node profile-download.js | ||
| node profile-download.js "ggerganov/whisper.cpp/resolve/5359861c739e955e79d9a303bcbc70fb988958b1/ggml-tiny.bin" | ||
| PROFILE_INTERVAL=2 node profile-download.js "ggerganov/whisper.cpp/resolve/5359861c739e955e79d9a303bcbc70fb988958b1/ggml-tiny.bin" hf | ||
| `) | ||
| } | ||
|
|
||
| async function main () { | ||
| if (!REGISTRY_CORE_KEY) { | ||
| console.error('QVAC_REGISTRY_CORE_KEY is not set') | ||
| process.exit(1) | ||
| } | ||
|
|
||
| const modelPath = process.argv[2] | ||
| const sourceFilter = process.argv[3] | ||
|
|
||
| if (modelPath === '--help' || modelPath === '-h') { | ||
| usage() | ||
| process.exit(0) | ||
| } | ||
|
|
||
| if (!modelPath) { | ||
| usage() | ||
| process.exit(0) | ||
| } | ||
|
|
||
| await profileDownload({ | ||
| registryCoreKey: REGISTRY_CORE_KEY, | ||
| modelPath, | ||
| source: sourceFilter, | ||
| intervalSec: STATS_INTERVAL_SEC | ||
| }) | ||
| } | ||
|
|
||
| main().catch((err) => { | ||
| console.error('Profiler failed:', err) | ||
| process.exit(1) | ||
| }) |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.