Instructions to use HuggingFaceH4/tiny-random-LlamaForSeqClass with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use HuggingFaceH4/tiny-random-LlamaForSeqClass with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="HuggingFaceH4/tiny-random-LlamaForSeqClass")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("HuggingFaceH4/tiny-random-LlamaForSeqClass") model = AutoModelForSequenceClassification.from_pretrained("HuggingFaceH4/tiny-random-LlamaForSeqClass", device_map="auto") - Notebooks
- Google Colab
- Kaggle
File size: 575 Bytes
5bc5525 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | {
"_name_or_path": "HuggingFaceH4/tiny-random-LlamaForCausalLM",
"architectures": [
"LlamaForSequenceClassification"
],
"bos_token_id": 0,
"eos_token_id": 1,
"hidden_act": "silu",
"hidden_size": 16,
"initializer_range": 0.02,
"intermediate_size": 64,
"max_position_embeddings": 2048,
"model_type": "llama",
"num_attention_heads": 4,
"num_hidden_layers": 2,
"pad_token_id": -1,
"rms_norm_eps": 1e-06,
"tie_word_embeddings": false,
"torch_dtype": "float32",
"transformers_version": "4.28.1",
"use_cache": true,
"vocab_size": 32000
}
|