diff --git a/README.md b/README.md index e307d2e..2cbf9b6 100644 --- a/README.md +++ b/README.md @@ -23,8 +23,8 @@ to generate text embeddings for given code "" and text description "". import towhee ( - towhee.dc([""]) - .text_embedding.transformers(model_name="distilbert-base-cased") + towhee.dc(['find max value', 'def max(a,b): if a>b: return a else return b']) + .code_search.codebert(model_name='huggingface/CodeBERTa-small-v1') ) ``` @@ -34,8 +34,8 @@ import towhee import towhee ( - towhee.dc['text'](["Hello, world."]) - .text_embedding.transformers['text', 'vec'](model_name="distilbert-base-cased") + towhee.dc['text'](['find max value', 'def max(a,b): if a>b: return a else return b']) + .code_search.codebert['text', 'embedding'](model_name='huggingface/CodeBERTa-small-v1') .show() ) ``` diff --git a/result.png b/result.png new file mode 100644 index 0000000..ea62d44 Binary files /dev/null and b/result.png differ