Instructions to use johngiorgi/declutr-small with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use johngiorgi/declutr-small with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("johngiorgi/declutr-small") sentences = [ "That is a happy person", "That is a happy dog", "That is a very happy person", "Today is a sunny day" ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4] - Notebooks
- Google Colab
- Kaggle
Download config.json from johngiorgi/declutr-small: direct link, hf CLI and curl.
- Browser
- Download file 1.23 kB
-
https://huggingface.co/johngiorgi/declutr-small/resolve/552956247efa0b99b563dc32eff9d85acc3f89d6/config.json
- Command line
-
hf download hf://johngiorgi/declutr-small@552956247efa0b99b563dc32eff9d85acc3f89d6/config.json
-
curl -L -o config.json https://huggingface.co/johngiorgi/declutr-small/resolve/552956247efa0b99b563dc32eff9d85acc3f89d6/config.json
1.23 kB
| { | |
| "_num_labels": 2, | |
| "architectures": [ | |
| "RobertaForMaskedLM" | |
| ], | |
| "attention_probs_dropout_prob": 0.1, | |
| "bad_words_ids": null, | |
| "bos_token_id": 0, | |
| "decoder_start_token_id": null, | |
| "do_sample": false, | |
| "early_stopping": false, | |
| "eos_token_id": 2, | |
| "finetuning_task": null, | |
| "hidden_act": "gelu", | |
| "hidden_dropout_prob": 0.1, | |
| "hidden_size": 768, | |
| "id2label": { | |
| "0": "LABEL_0", | |
| "1": "LABEL_1" | |
| }, | |
| "initializer_range": 0.02, | |
| "intermediate_size": 3072, | |
| "is_decoder": false, | |
| "is_encoder_decoder": false, | |
| "label2id": { | |
| "LABEL_0": 0, | |
| "LABEL_1": 1 | |
| }, | |
| "layer_norm_eps": 1e-05, | |
| "length_penalty": 1.0, | |
| "max_length": 20, | |
| "max_position_embeddings": 514, | |
| "min_length": 0, | |
| "model_type": "roberta", | |
| "no_repeat_ngram_size": 0, | |
| "num_attention_heads": 12, | |
| "num_beams": 1, | |
| "num_hidden_layers": 6, | |
| "num_return_sequences": 1, | |
| "output_attentions": false, | |
| "output_hidden_states": true, | |
| "output_past": true, | |
| "pad_token_id": 1, | |
| "prefix": null, | |
| "pruned_heads": {}, | |
| "repetition_penalty": 1.0, | |
| "task_specific_params": null, | |
| "temperature": 1.0, | |
| "top_k": 50, | |
| "top_p": 1.0, | |
| "torchscript": false, | |
| "type_vocab_size": 1, | |
| "use_bfloat16": false, | |
| "vocab_size": 50265 | |
| } | |