fix(workflow-operator): accept single-segment HF model IDs and reject '..' in the model-id check - #7474
fix(workflow-operator): accept single-segment HF model IDs and reject '..' in the model-id check#7474PG1204 wants to merge 1 commit into
Conversation
… '..' in the model-id check
Backport auto-label reportThis
|
Automated Reviewer SuggestionsBased on the
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #7474 +/- ##
=========================================
Coverage 85.43% 85.44%
Complexity 4150 4150
=========================================
Files 1169 1169
Lines 46740 46740
Branches 5202 5202
=========================================
+ Hits 39934 39935 +1
+ Misses 5092 5091 -1
Partials 1714 1714
*This pull request uses carry forward flags. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
| config | throughput | MB/s | latency | max Δ latest / 7d | |
|---|---|---|---|---|---|
| 🔴 | bs=10 sw=10 sl=64 | 413 | 0.252 | 24,144/30,027/30,027 us | 🔴 +23.6% / 🔴 +83.9% |
| 🟢 | bs=100 sw=10 sl=64 | 922 | 0.563 | 106,429/132,653/132,653 us | 🟢 -16.6% / 🔴 +17.9% |
| 🔴 | bs=1000 sw=10 sl=64 | 1,094 | 0.668 | 909,478/1,119,366/1,119,366 us | 🔴 +12.5% / 🟢 +12.6% |
Baseline details
Latest main 114a610 from same runner
| config | metric | PR | latest main | 7d avg | Δ latest | Δ 7d |
|---|---|---|---|---|---|---|
| bs=10 sw=10 sl=64 | throughput | 413 tuples/sec | 464 tuples/sec | 743.73 tuples/sec | -11.0% | -44.5% |
| bs=10 sw=10 sl=64 | MB/s | 0.252 MB/s | 0.283 MB/s | 0.454 MB/s | -11.0% | -44.5% |
| bs=10 sw=10 sl=64 | p50 | 24,144 us | 19,536 us | 13,130 us | +23.6% | +83.9% |
| bs=10 sw=10 sl=64 | p95 | 30,027 us | 31,677 us | 16,391 us | -5.2% | +83.2% |
| bs=10 sw=10 sl=64 | p99 | 30,027 us | 31,677 us | 19,408 us | -5.2% | +54.7% |
| bs=100 sw=10 sl=64 | throughput | 922 tuples/sec | 944 tuples/sec | 944.04 tuples/sec | -2.3% | -2.3% |
| bs=100 sw=10 sl=64 | MB/s | 0.563 MB/s | 0.576 MB/s | 0.576 MB/s | -2.3% | -2.3% |
| bs=100 sw=10 sl=64 | p50 | 106,429 us | 104,068 us | 105,853 us | +2.3% | +0.5% |
| bs=100 sw=10 sl=64 | p95 | 132,653 us | 159,118 us | 112,493 us | -16.6% | +17.9% |
| bs=100 sw=10 sl=64 | p99 | 132,653 us | 159,118 us | 122,200 us | -16.6% | +8.6% |
| bs=1000 sw=10 sl=64 | throughput | 1,094 tuples/sec | 1,107 tuples/sec | 972.22 tuples/sec | -1.2% | +12.5% |
| bs=1000 sw=10 sl=64 | MB/s | 0.668 MB/s | 0.675 MB/s | 0.593 MB/s | -1.0% | +12.6% |
| bs=1000 sw=10 sl=64 | p50 | 909,478 us | 897,538 us | 1,033,856 us | +1.3% | -12.0% |
| bs=1000 sw=10 sl=64 | p95 | 1,119,366 us | 995,243 us | 1,076,083 us | +12.5% | +4.0% |
| bs=1000 sw=10 sl=64 | p99 | 1,119,366 us | 995,243 us | 1,107,701 us | +12.5% | +1.1% |
Raw CSV
config_idx,batch_size,schema_width,string_len,num_batches,total_ms,total_tuples,total_bytes,tuples_per_sec,mb_per_sec,lat_p50_us,lat_p95_us,lat_p99_us
0,10,10,64,20,484.01,200,128000,413,0.252,24143.96,30026.51,30026.51
1,100,10,64,20,2168.50,2000,1280000,922,0.563,106429.14,132652.83,132652.83
2,1000,10,64,20,18280.78,20000,12800000,1094,0.668,909478.14,1119365.54,1119365.54|
/request-review @xuang7 |
What changes were proposed in this PR?
The generated model-ID validation regex (
_HF_MODEL_ID_PATTERN) had two problems:..path-traversal segments through: e.g.org/..passed, even though the comment claimed..was rejected (the character class allowed dots, so..was a valid segment).gpt2andbert-base-uncased, because it required at least one/.This adds a
(?!.*\.\.)lookahead to reject any.., and makes the trailing/segmentgroup optional so single-segment IDs are accepted. The comment and the "Invalid Hugging Face model ID" error message are updated to match.Any related issues?
Closes #7196
How was this PR tested?
PythonCodeRawInvalidTextSpecpy-compile guard (confirms the new regex is valid Python).gpt2,bert-base-uncased,t5-small,org/model,org/model/revisionare accepted;org/..,org/../secret,..are rejected.Was this PR authored or co-authored using generative AI tooling?
This PR was co-authored with Claude in compliance with ASF policy.