michael-guenther commited on
Commit
9c1ca94
·
verified ·
1 Parent(s): 17d8c67

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +6 -6
README.md CHANGED
@@ -139,8 +139,8 @@ passage_embeddings = embeddings[2:]
139
  # Compute the (cosine) similarity between the query and document embeddings
140
  scores = cosine_similarity(query_embeddings, passage_embeddings)
141
  print(scores)
142
- # tensor([[0.8168, 0.1236],
143
- # [0.1204, 0.5525]], grad_fn=<MmBackward0>)
144
  ```
145
  </details>
146
 
@@ -180,8 +180,8 @@ document_embeddings = model.encode(documents, prompt_name="nl2code_document")
180
  # Compute the (cosine) similarity between the query and document embeddings
181
  similarity = model.similarity(query_embeddings, document_embeddings)
182
  print(similarity)
183
- # tensor([[0.8169, 0.1214],
184
- # [0.1190, 0.5500]])
185
  ```
186
  </details>
187
 
@@ -260,8 +260,8 @@ passage_embeddings = embeddings[n_q:]
260
  # Cosine similarity matrix (queries x documents)
261
  scores = cosine_similarity(query_embeddings, passage_embeddings)
262
  print(scores)
263
- # tensor([[0.8171, 0.1230],
264
- # [0.1207, 0.5513]])
265
  ```
266
 
267
  </details>
 
139
  # Compute the (cosine) similarity between the query and document embeddings
140
  scores = cosine_similarity(query_embeddings, passage_embeddings)
141
  print(scores)
142
+ # tensor([[0.7647, 0.1115],
143
+ # [0.0930, 0.6606]], grad_fn=<MmBackward0>)
144
  ```
145
  </details>
146
 
 
180
  # Compute the (cosine) similarity between the query and document embeddings
181
  similarity = model.similarity(query_embeddings, document_embeddings)
182
  print(similarity)
183
+ # tensor([[0.7670, 0.1117],
184
+ # [0.0938, 0.6607]])
185
  ```
186
  </details>
187
 
 
260
  # Cosine similarity matrix (queries x documents)
261
  scores = cosine_similarity(query_embeddings, passage_embeddings)
262
  print(scores)
263
+ # tensor([[0.7650, 0.1118],
264
+ # [0.0937, 0.6613]])
265
  ```
266
 
267
  </details>