avacaondata commited on
Commit
7b7b803
verified
1 Parent(s): 0fe7255

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +0 -20
README.md CHANGED
@@ -106,26 +106,6 @@ Adem谩s, debe tenerse en cuenta que el modelo base es de 煤nicamente 1.5b par谩m
106
 
107
  You can start using this model through the Hugging Face API or integrate it into your applications using the transformers library. Here is an example of how to load the model:
108
 
109
- ```python
110
- from transformers import AutoModelForCausalLM, AutoTokenizer
111
- import torch
112
-
113
- model_name = "LenguajeNaturalAI/leniachat-gemma-2b-v0"
114
- tokenizer = AutoTokenizer.from_pretrained(model_name)
115
- model = AutoModelForCausalLM.from_pretrained(model_name)
116
-
117
- # Generar texto
118
- messages = [
119
- {"role": "system", "content": "Eres un asistente que ayuda al usuario a lo largo de la conversaci贸n resolviendo sus dudas."},
120
- {"role": "user", "content": "驴Qu茅 fue la revoluci贸n industrial?"}
121
- ]
122
- input_ids = tokenizer.apply_chat_template(messages, tokenize=True, return_tensors="pt")
123
- with torch.no_grad():
124
- output = model.generate(input_ids, max_new_tokens=50)
125
- print(tokenizer.decode(output[0], skip_special_tokens=True))
126
- ```
127
-
128
-
129
  ## 驴C贸mo empezar?
130
 
131
  Puedes empezar a utilizar este modelo a trav茅s de la API de Hugging Face o integrarlo en tus aplicaciones utilizando la biblioteca `transformers`. Aqu铆 tienes un ejemplo de c贸mo cargar el modelo:
 
106
 
107
  You can start using this model through the Hugging Face API or integrate it into your applications using the transformers library. Here is an example of how to load the model:
108
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
109
  ## 驴C贸mo empezar?
110
 
111
  Puedes empezar a utilizar este modelo a trav茅s de la API de Hugging Face o integrarlo en tus aplicaciones utilizando la biblioteca `transformers`. Aqu铆 tienes un ejemplo de c贸mo cargar el modelo: