Browse Source
Add sharable
Signed-off-by: junjie.jiang <junjie.jiang@zilliz.com>
main
1 changed files with
4 additions and
1 deletions
-
hf_dolly.py
|
@ -17,7 +17,7 @@ from typing import List |
|
|
import torch |
|
|
import torch |
|
|
from transformers import pipeline |
|
|
from transformers import pipeline |
|
|
|
|
|
|
|
|
from towhee.operator.base import PyOperator |
|
|
|
|
|
|
|
|
from towhee.operator.base import PyOperator, SharedType |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class HuggingfaceDolly(PyOperator): |
|
|
class HuggingfaceDolly(PyOperator): |
|
@ -60,3 +60,6 @@ class HuggingfaceDolly(PyOperator): |
|
|
model_list.sort() |
|
|
model_list.sort() |
|
|
return model_list |
|
|
return model_list |
|
|
|
|
|
|
|
|
|
|
|
@property |
|
|
|
|
|
def shared_type(self): |
|
|
|
|
|
return SharedType.Shareable |
|
|