ELin2025 opened a new issue, #5314:
URL: https://github.com/apache/texera/issues/5314

   ### Task Summary
   
   ### Task Summary
   
   ## Feature Summary
   
   The HuggingFace inference operator (#5041) is being landed as a sequence of 
focused PRs. The backend operator descriptor and codegen architecture were 
introduced in #5277, with the final backend task family (QA/ranking) in #5292. 
This issue covers the frontend integration layer that connects to those backend 
endpoints.
   
   This issue covers adding the frontend custom formly field types that power 
the HuggingFace operator's property editor: a task-aware model selector and an 
audio file upload component.
   
   Concretely, landing this would enable:
   
   - A task dropdown that fetches available pipeline tags from the backend 
(with static fallback)
   - A paginated model browser that loads and caches models per task
   - Client-side search over the model list
   - Per-task field state snapshot and restore when switching tasks
   - An audio upload component for speech-recognition and audio-classification 
tasks
   
   ## Proposed Solution or Design
   
   Add new files:
   
   | Path | Purpose |
   | --- | --- |
   | `frontend/.../hugging-face/hugging-face.component.ts` | Custom formly 
field type wrapping task dropdown + paginated model browser |
   | `frontend/.../hugging-face/hugging-face.component.html` | Template with 
task selector, search bar, model grid, and pagination |
   | `frontend/.../hugging-face/hugging-face.component.scss` | Styles for 
task/model selector layout |
   | `frontend/.../hugging-face/hugging-face.component.spec.ts` | Component 
unit tests |
   | 
`frontend/.../hugging-face-audio-upload/hugging-face-audio-upload.component.ts` 
| Custom formly field type for audio file upload via backend storage |
   | 
`frontend/.../hugging-face-audio-upload/hugging-face-audio-upload.component.html`
 | Upload button, playback preview, filename and status display |
   | 
`frontend/.../hugging-face-audio-upload/hugging-face-audio-upload.component.scss`
 | Audio upload styles |
   | 
`frontend/.../hugging-face-audio-upload/hugging-face-audio-upload.component.spec.ts`
 | Audio upload unit tests |
   
   Modify:
   
   | File | Change |
   | --- | --- |
   | `frontend/src/app/app.module.ts` | Declare `HuggingFaceComponent` and 
`HuggingFaceAudioUploadComponent` |
   | `frontend/src/app/common/formly/formly-config.ts` | Register `huggingface` 
and `huggingface-audio-upload` formly field types |
   
   Design constraints:
   
   - Module-level caching for tasks and models so data survives component 
re-renders.
   - Task state snapshot/restore preserves user input when switching between 
tasks.
   - Backend endpoint failures fall back to a static task list — the component 
must remain functional without the backend proxy.
   - Audio upload posts the file to the backend's `/huggingface/upload-audio` 
endpoint and stores a server-side reference — audio data does not go into the 
workflow JSON.
   
   References:
   
   - Parent issue: #5041
   - Depends on: #5292 — this PR branches off the QA/ranking tasks PR; the 
frontend components assume all backend task families (text-generation, image, 
audio, QA/ranking) and their fields are available.
   
   ## Impact / Priority
   
   (P2) Medium — required for the HuggingFace operator to be usable in the 
frontend. Does not affect existing operators.
   
   ## Affected Area
   
   Frontend (Angular) — workspace property editor custom field types.
   
   ### Task Type
   
   - [ ] Refactor / Cleanup
   - [ ] DevOps / Deployment / CI
   - [ ] Testing / QA
   - [ ] Documentation
   - [ ] Performance
   - [x] Other
   
   ### Task Type
   
   - [ ] Refactor / Cleanup
   - [ ] DevOps / Deployment / CI
   - [ ] Testing / QA
   - [ ] Documentation
   - [ ] Performance
   - [x] Other


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to