diff --git a/README.md b/README.md index 16d74c8..84a283f 100644 --- a/README.md +++ b/README.md @@ -33,12 +33,10 @@ to generate a text embedding for the sentence "Hello, world.". *Write the pipeline*: ```python -from towhee import dc +import towhee - -dc.stream(["Hello, world."]) \ - .text_embedding.dpr(model_name="facebook/dpr-ctx_encoder-single-nq-base") \ - .to_list() +towhee.dc(["Hello, world."]) \ + .text_embedding.dpr(model_name="facebook/dpr-ctx_encoder-single-nq-base") ```