VicGerardoPR commited on
Commit
167a2cb
verified
1 Parent(s): 0c7c50a

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +47 -17
README.md CHANGED
@@ -1,17 +1,47 @@
1
- # Chatbot para Mac M1 con Phi-3-mini
2
-
3
- Chatbot optimizado para Apple Silicon usando:
4
- - Microsoft Phi-3-mini (3.8B par谩metros)
5
- - Quantizaci贸n 4-bit
6
- - Streamlit para la interfaz web
7
-
8
- ## Requisitos
9
- - Mac con chip M1/M2/M3
10
- - macOS 13.0+
11
- - Python 3.9+
12
-
13
- ## Instalaci贸n
14
- ```bash
15
- git clone https://github.com/tu-usuario/mi-chatbot.git
16
- cd mi-chatbot
17
- pip install -r requirements.txt
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ tags:
3
+ - text-generation
4
+ - conversational
5
+ - llama
6
+ license: mit
7
+ library_name: transformers
8
+ pipeline_tag: text-generation
9
+ ---
10
+
11
+ # Chatbot Phi-3-mini Optimizado para Mac M1/M2
12
+
13
+ Modelo de chatbot optimizado para Apple Silicon basado en **Microsoft Phi-3-mini-4k-instruct** (3.8B par谩metros) con quantizaci贸n 4-bit.
14
+
15
+ ![Chatbot Demo](https://i.imgur.com/5Xgq3TG.gif)
16
+
17
+ ## Model Details
18
+
19
+ ### **Caracter铆sticas Clave**
20
+ - **Arquitectura**: Transformer-based (Llama-like)
21
+ - **Context Window**: 4K tokens
22
+ - **Quantizaci贸n**: 4-bit (bnb)
23
+ - **Hardware Target**: Apple M1/M2/M3 (GPU Metal)
24
+ - **Framework**: PyTorch 2.3+ con MPS
25
+
26
+ ### **Uso Previsto**
27
+ - Asistente conversacional general
28
+ - Generaci贸n de texto en espa帽ol/ingl茅s
29
+ - Q&A contextual
30
+
31
+ ## How to Use
32
+
33
+ ### **Inferencia Directa**
34
+ ```python
35
+ from transformers import pipeline
36
+
37
+ chatbot = pipeline(
38
+ "text-generation",
39
+ model="microsoft/Phi-3-mini-4k-instruct",
40
+ device_map="auto",
41
+ torch_dtype="auto",
42
+ trust_remote_code=True
43
+ )
44
+
45
+ messages = [{"role": "user", "content": "Explica la teor铆a de relatividad"}]
46
+ response = chatbot(messages, max_new_tokens=256)
47
+ print(response[0]['generated_text'])