Upload README.md with huggingface_hub
Browse files
README.md
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# intent-onnx
|
| 2 |
+
|
| 3 |
+
This is an ONNX version of the fine-tuned intent classification model.
|
| 4 |
+
|
| 5 |
+
## Model Details
|
| 6 |
+
|
| 7 |
+
- **Model Type**: BERT-based sentence transformer
|
| 8 |
+
- **Architecture**: BertModel
|
| 9 |
+
- **Hidden Size**: 384
|
| 10 |
+
- **Attention Heads**: 12
|
| 11 |
+
- **Layers**: 3
|
| 12 |
+
- **Vocabulary Size**: 30,522
|
| 13 |
+
|
| 14 |
+
## Usage
|
| 15 |
+
|
| 16 |
+
### Transformers.js
|
| 17 |
+
|
| 18 |
+
```javascript
|
| 19 |
+
import { pipeline } from '@xenova/transformers';
|
| 20 |
+
|
| 21 |
+
const extractor = await pipeline('feature-extraction', 'drithh/intent-onnx');
|
| 22 |
+
|
| 23 |
+
const output = await extractor('your text here', {
|
| 24 |
+
pooling: 'mean',
|
| 25 |
+
normalize: true
|
| 26 |
+
});
|
| 27 |
+
|
| 28 |
+
console.log('Embedding shape:', output.data.length);
|
| 29 |
+
```
|
| 30 |
+
|
| 31 |
+
### Python
|
| 32 |
+
|
| 33 |
+
```python
|
| 34 |
+
from sentence_transformers import SentenceTransformer
|
| 35 |
+
|
| 36 |
+
model = SentenceTransformer('drithh/intent-classifier')
|
| 37 |
+
embeddings = model.encode('your text here')
|
| 38 |
+
print(f'Embedding shape: {embeddings.shape}')
|
| 39 |
+
```
|
| 40 |
+
|
| 41 |
+
## Training
|
| 42 |
+
|
| 43 |
+
This model was fine-tuned on intent classification data using SentenceTransformers.
|