Token Classification
Transformers
Safetensors
Abkhaz
gpt_neox
text-generation
code
text-generation-inference
Instructions to use Mauricio-100/agent-ai with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Mauricio-100/agent-ai with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("token-classification", model="Mauricio-100/agent-ai")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Mauricio-100/agent-ai") model = AutoModelForCausalLM.from_pretrained("Mauricio-100/agent-ai", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Create pytorch_model.bin
Browse files- pytorch_model.bin +16 -0
pytorch_model.bin
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from transformers import GPTNeoXConfig, GPTNeoXForCausalLM
|
| 2 |
+
|
| 3 |
+
# Config minimale
|
| 4 |
+
config = GPTNeoXConfig(
|
| 5 |
+
vocab_size=30000,
|
| 6 |
+
hidden_size=512,
|
| 7 |
+
num_attention_heads=8,
|
| 8 |
+
num_hidden_layers=6,
|
| 9 |
+
max_position_embeddings=1024
|
| 10 |
+
)
|
| 11 |
+
|
| 12 |
+
# Créer le modèle
|
| 13 |
+
model = GPTNeoXForCausalLM(config)
|
| 14 |
+
|
| 15 |
+
# Sauvegarder les poids
|
| 16 |
+
model.save_pretrained("./agent_model")
|