Feature Extraction
sentence-transformers
PyTorch
Chinese
bert
mteb
Eval Results (legacy)
text-embeddings-inference
Instructions to use OpenSearch-AI/Ops-MoA-Conan-embedding-v1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use OpenSearch-AI/Ops-MoA-Conan-embedding-v1 with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("OpenSearch-AI/Ops-MoA-Conan-embedding-v1") sentences = [ "The weather is lovely today.", "It's so sunny outside!", "He drove to the stadium." ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [3, 3] - Notebooks
- Google Colab
- Kaggle
Update modeling_adaptor.py
Browse files- modeling_adaptor.py +0 -2
modeling_adaptor.py
CHANGED
|
@@ -1,8 +1,6 @@
|
|
| 1 |
import torch
|
| 2 |
import torch.nn as nn
|
| 3 |
-
import math
|
| 4 |
import torch.nn.functional as F
|
| 5 |
-
import joblib
|
| 6 |
|
| 7 |
class MoAGate(nn.Module):
|
| 8 |
def __init__(self, num_adaptors, hidden_dim):
|
|
|
|
| 1 |
import torch
|
| 2 |
import torch.nn as nn
|
|
|
|
| 3 |
import torch.nn.functional as F
|
|
|
|
| 4 |
|
| 5 |
class MoAGate(nn.Module):
|
| 6 |
def __init__(self, num_adaptors, hidden_dim):
|