Repository navigation
Conversation
…ugging Face operators
|
/request-review @Ma77Ball |
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 #9209 +/- ##
=========================================
Coverage 92.05% 92.06%
+ Complexity 5041 5029 -12
=========================================
Files 1286 1287 +1
Lines 55911 55928 +17
Branches 7137 7135 -2
=========================================
+ Hits 51469 51488 +19
- Misses 2692 2693 +1
+ Partials 1750 1747 -3
*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 | 670 | 0.409 | 14,422/20,065/20,065 us | 🔴 -15.4% / 🔴 +43.0% |
| 🔴 | bs=100 sw=10 sl=64 | 1,646 | 1.004 | 59,313/67,701/67,701 us | 🟢 -14.0% / 🟢 -39.2% |
| ⚪ | bs=1000 sw=10 sl=64 | 1,966 | 1.2 | 498,797/593,621/593,621 us | ⚪ within ±5% / 🟢 +58.7% |
Baseline details
Latest main f673554 from same runner
| config | metric | PR | latest main | 7d avg | Δ latest | Δ 7d |
|---|---|---|---|---|---|---|
| bs=10 sw=10 sl=64 | throughput | 670 tuples/sec | 792 tuples/sec | 905.73 tuples/sec | -15.4% | -26.0% |
| bs=10 sw=10 sl=64 | MB/s | 0.409 MB/s | 0.483 MB/s | 0.553 MB/s | -15.3% | -26.0% |
| bs=10 sw=10 sl=64 | p50 | 14,422 us | 12,600 us | 11,331 us | +14.5% | +27.3% |
| bs=10 sw=10 sl=64 | p95 | 20,065 us | 18,652 us | 14,032 us | +7.6% | +43.0% |
| bs=10 sw=10 sl=64 | p99 | 20,065 us | 18,652 us | 17,338 us | +7.6% | +15.7% |
| bs=100 sw=10 sl=64 | throughput | 1,646 tuples/sec | 1,754 tuples/sec | 1,205 tuples/sec | -6.2% | +36.6% |
| bs=100 sw=10 sl=64 | MB/s | 1.004 MB/s | 1.07 MB/s | 0.735 MB/s | -6.2% | +36.5% |
| bs=100 sw=10 sl=64 | p50 | 59,313 us | 55,455 us | 89,237 us | +7.0% | -33.5% |
| bs=100 sw=10 sl=64 | p95 | 67,701 us | 78,685 us | 96,280 us | -14.0% | -29.7% |
| bs=100 sw=10 sl=64 | p99 | 67,701 us | 78,685 us | 111,344 us | -14.0% | -39.2% |
| bs=1000 sw=10 sl=64 | throughput | 1,966 tuples/sec | 2,003 tuples/sec | 1,239 tuples/sec | -1.8% | +58.7% |
| bs=1000 sw=10 sl=64 | MB/s | 1.2 MB/s | 1.223 MB/s | 0.756 MB/s | -1.9% | +58.7% |
| bs=1000 sw=10 sl=64 | p50 | 498,797 us | 493,785 us | 877,826 us | +1.0% | -43.2% |
| bs=1000 sw=10 sl=64 | p95 | 593,621 us | 586,484 us | 919,412 us | +1.2% | -35.4% |
| bs=1000 sw=10 sl=64 | p99 | 593,621 us | 586,484 us | 963,000 us | +1.2% | -38.4% |
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,298.44,200,128000,670,0.409,14422.42,20064.93,20064.93
1,100,10,64,20,1215.28,2000,1280000,1646,1.004,59312.91,67701.35,67701.35
2,1000,10,64,20,10172.52,20000,12800000,1966,1.200,498797.08,593621.49,593621.49
What changes were proposed in this PR?
The four legacy Hugging Face operators (Spam Detection, Sentiment Analysis, Text Summarization and Iris Logistic Regression) now validate their configuration the same way in
getOutputSchemas, through one shared helper,HuggingFaceSchemaValidation:null, as @Ma77Ball recommended on Align schema validation across the four legacy Hugging Face operators #8728. Spam and Sentiment used to returnnullfor an empty result column. The compiler runsgetOutputSchemasinside aTryand stores a thrown error on the output port. A returnednullcounted as success, then failed one line later inPhysicalOp.propagateSchema(schemaMapping.foldLeft) with aNullPointerException, so the user saw an NPE instead of a message. Summarization and Iris already threw, but with generic messages. All four now name the field, e.g.Spam result attribute cannot be empty.Attributefor the three text operators, the two petal columns for Iris) must be set and present in the input table. The match is exact-case:Schemalookups ignore case, but the generated Python does not. The error lists the available columns, as fix(workflow-operator): report a clear error when a configured HF image/audio column is missing #7299's does. Iris's petal columns must also be numeric (integer, long or double), matching its existing frontend type rule.inputSchemas(operatorInfo.inputPorts.head.id)), as the other three do, instead ofinputSchemas.values.head.Two corrections to the text of #8728. Iris reads two input columns (petal length and petal width), not four. And #7299's check runs in the generated Python at run time, so it is the precedent for the message wording, not for where the check lives.
Any related issues?
Closes #8728
How was this PR tested?
The tests were written first. 22 new or rewritten tests across the four specs failed against
mainfor the expected reasons; Spam's and Sentiment's propagation tests failed with theNullPointerExceptionitself. All 22 pass with the change, and reverting the four operators makes exactly those 22 fail again. The six tests that assertednullnow assert the thrown message. The Spam and Iris happy-path inputs gained the columns those operators read, and their assertions are unchanged.The full
WorkflowOperatorsuite passes: 2756 tests, 0 failures, with 1 cancelled and 2 pending, none of them in the Hugging Face suites. The generated Python of all 117 operators compiles, and scalafmt and scalafix are clean.Was this PR authored or co-authored using generative AI tooling?
Yes, this PR was co-authored with Claude in compliance with ASF policy.