Andrea Cosentino created CAMEL-24540:
----------------------------------------
Summary: camel-huggingface: revision is ignored by two task
predictors and TextToImage never sets the OUTPUT header
Key: CAMEL-24540
URL: https://issues.apache.org/jira/browse/CAMEL-24540
Project: Camel
Issue Type: Bug
Components: camel-ai
Reporter: Andrea Cosentino
Assignee: Andrea Cosentino
Fix For: 4.23.0
Two minor correctness gaps in the camel-huggingface task predictors, both
incomplete ports of the pattern the other predictors follow:
1) The configured model revision is not passed through by
SentenceEmbeddingsPredictor (around lines 105-107) or TextToImagePredictor
(around lines 93-95); the other eight predictors pass config.getRevision() into
their generated Python script, so pinning a model revision silently has no
effect for these two tasks. Fix: pass config.getRevision() into the two scripts.
2) TextToImagePredictor (around lines 108-113) sets the message body to the
generated image bytes but never sets the OUTPUT header, even though its Javadoc
(line 53) documents that header as part of the contract. Fix:
setHeader(HuggingfaceConstants.OUTPUT, imageBytes) alongside the body.
_Claude Code on behalf of oscerd_
--
This message was sent by Atlassian Jira
(v8.20.10#820010)