Upload README.md with huggingface_hub
Browse files
README.md
ADDED
|
@@ -0,0 +1,79 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
library_name: pytorch
|
| 3 |
+
license: other
|
| 4 |
+
pipeline_tag: text-generation
|
| 5 |
+
tags:
|
| 6 |
+
- llm
|
| 7 |
+
- generative_ai
|
| 8 |
+
- quantized
|
| 9 |
+
- android
|
| 10 |
+
|
| 11 |
+
---
|
| 12 |
+
|
| 13 |
+

|
| 14 |
+
|
| 15 |
+
# Mistral-3B: Optimized for Mobile Deployment
|
| 16 |
+
## State-of-the-art large language model useful on a variety of language understanding and generation tasks
|
| 17 |
+
|
| 18 |
+
Mistral 3B model is Mistral AI's first generation edge model, optimized for optimal performance on Snapdragon platforms.
|
| 19 |
+
|
| 20 |
+
This is based on the implementation of Mistral-3B found
|
| 21 |
+
[here]({source_repo}). More details on model performance
|
| 22 |
+
accross various devices, can be found [here](https://aihub.qualcomm.com/models/mistral_3b_quantized).
|
| 23 |
+
|
| 24 |
+
### Model Details
|
| 25 |
+
|
| 26 |
+
- **Model Type:** Text generation
|
| 27 |
+
- **Model Stats:**
|
| 28 |
+
- Input sequence length for Prompt Processor: 128
|
| 29 |
+
- Max context length: 4096
|
| 30 |
+
- Num of key-value heads: 8
|
| 31 |
+
- Number of parameters: 3B
|
| 32 |
+
- Precision: w4a16 + w8a16 (few layers)
|
| 33 |
+
- Use: Initiate conversation with prompt-processor and then token generator for subsequent iterations.
|
| 34 |
+
- Minimum QNN SDK version required: 2.27.7
|
| 35 |
+
- Supported languages: English.
|
| 36 |
+
- TTFT: Time To First Token is the time it takes to generate the first response token. This is expressed as a range because it varies based on the length of the prompt. The lower bound is for a short prompt (up to 128 tokens, i.e., one iteration of the prompt processor) and the upper bound is for a prompt using the full context length (4096 tokens).
|
| 37 |
+
- Response Rate: Rate of response generation after the first response token.
|
| 38 |
+
|
| 39 |
+
| Model | Device | Chipset | Target Runtime | Response Rate (tokens per second) | Time To First Token (range, seconds)
|
| 40 |
+
|---|---|---|---|---|---|
|
| 41 |
+
| Mistral-3B | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | QNN | 21.05 | 0.092289 - 2.9532736 | -- | -- |
|
| 42 |
+
|
| 43 |
+
## Deploying Mistral 3B on-device
|
| 44 |
+
|
| 45 |
+
Please follow the [LLM on-device deployment](https://github.com/quic/ai-hub-apps/tree/main/tutorials/llm_on_genie) tutorial.
|
| 46 |
+
|
| 47 |
+
|
| 48 |
+
|
| 49 |
+
|
| 50 |
+
## References
|
| 51 |
+
* [None](None)
|
| 52 |
+
* [Source Model Implementation](https://github.com/mistralai/mistral-inference)
|
| 53 |
+
|
| 54 |
+
|
| 55 |
+
|
| 56 |
+
## Community
|
| 57 |
+
* Join [our AI Hub Slack community](https://qualcomm-ai-hub.slack.com/join/shared_invite/zt-2d5zsmas3-Sj0Q9TzslueCjS31eXG2UA#/shared-invite/email) to collaborate, post questions and learn more about on-device AI.
|
| 58 |
+
* For questions or feedback please [reach out to us](mailto:ai-hub-support@qti.qualcomm.com).
|
| 59 |
+
|
| 60 |
+
## Usage and Limitations
|
| 61 |
+
|
| 62 |
+
Model may not be used for or in connection with any of the following applications:
|
| 63 |
+
|
| 64 |
+
- Accessing essential private and public services and benefits;
|
| 65 |
+
- Administration of justice and democratic processes;
|
| 66 |
+
- Assessing or recognizing the emotional state of a person;
|
| 67 |
+
- Biometric and biometrics-based systems, including categorization of persons based on sensitive characteristics;
|
| 68 |
+
- Education and vocational training;
|
| 69 |
+
- Employment and workers management;
|
| 70 |
+
- Exploitation of the vulnerabilities of persons resulting in harmful behavior;
|
| 71 |
+
- General purpose social scoring;
|
| 72 |
+
- Law enforcement;
|
| 73 |
+
- Management and operation of critical infrastructure;
|
| 74 |
+
- Migration, asylum and border control management;
|
| 75 |
+
- Predictive policing;
|
| 76 |
+
- Real-time remote biometric identification in public spaces;
|
| 77 |
+
- Recommender systems of social media platforms;
|
| 78 |
+
- Scraping of facial images (from the internet or otherwise); and/or
|
| 79 |
+
- Subliminal manipulation
|