From a7d00427022d4ffbf25f6c43e82eebda6186ccb4 Mon Sep 17 00:00:00 2001 From: Jael Gu Date: Tue, 8 Nov 2022 16:04:02 +0800 Subject: [PATCH] Update README Signed-off-by: Jael Gu --- README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0ed6f12..6d634d7 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,8 @@ This operator is implemented with pre-trained models from [Huggingface Transform ## Code Example Use the pre-trained model "huggingface/CodeBERTa-small-v1" -to generate text embeddings for given code "" and text description "". +to generate text embeddings for given +text description "return max value" and code "def max(a,b): if a>b: return a else return b". *Write the pipeline*: @@ -34,7 +35,7 @@ import towhee import towhee ( - towhee.dc['text'](['find max value', 'def max(a,b): if a>b: return a else return b']) + towhee.dc['text'](['return max value', 'def max(a,b): if a>b: return a else return b']) .code_search.codebert['text', 'embedding']() .show() )