Pass kwargs to Pipeline's tokenizer call#9143
Pass kwargs to Pipeline's tokenizer call#9143guyrosin wants to merge 1 commit intohuggingface:masterfrom
Conversation
2e5c210 to
82498cb
Compare
|
cc @Narsil who probably knows better. |
|
Hi @guyrosin , we actually don't want to enable that. I'm guessing you want to override a tokenizer argument at runtime in the pipeline. The best way to do that is to whitelist all arguments of the The |
|
Ohh, got it. Thanks for the explanation @Narsil! |
What does this PR do?
When calling a Pipeline, the
kwargsargument is not passed to the tokenizer (it is actually not used at all).I think the intended behavior is to pass it (as the base tokenizer's
__call__()method already supportskwargs), and that's what this PR does.[Related to #8180]
The call order is:
Before submitting
to it if that's the case.
documentation guidelines, and here are tips on formatting docstrings.
Who can review?
@sgugger @LysandreJik