Instructions to use Kossayart/klara_ai with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use Kossayart/klara_ai with PEFT:
Task type is invalid.
- Notebooks
- Google Colab
- Kaggle
Create README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,65 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
language:
|
| 3 |
+
- en
|
| 4 |
+
license: apache-2.0
|
| 5 |
+
base_model: tinyllama/tinyllama-1.1b-chat-v1.0 # Or smollm/smollm2-1.7b
|
| 6 |
+
tags:
|
| 7 |
+
- medical-assistant
|
| 8 |
+
- lora
|
| 9 |
+
- quantized
|
| 10 |
+
- edge-ai
|
| 11 |
+
- health-tech
|
| 12 |
+
library_name: peft
|
| 13 |
+
pipeline_tag: text-generation
|
| 14 |
+
---
|
| 15 |
+
|
| 16 |
+
# Model Card for Klara-LLM-v1
|
| 17 |
+
|
| 18 |
+
Klara-LLM-v1 is a lightweight, fine-tuned Large Language Model designed to act as the cognitive core for a smart health monitoring system. It translates physiological sensor data and crisis predictions into actionable, human-readable medical advice.
|
| 19 |
+
|
| 20 |
+
## Model Details
|
| 21 |
+
|
| 22 |
+
### Model Description
|
| 23 |
+
|
| 24 |
+
This model is a specialized version of a small-parameter LLM (e.g., TinyLlama/SmolLM2), fine-tuned using **LoRA (Low-Rank Adaptation)**. It is specifically optimized for local deployment on edge hardware to ensure user data privacy and low-latency responses.
|
| 25 |
+
|
| 26 |
+
- **Developed by:** Koussay Chaanbi
|
| 27 |
+
- **Project Name:** Klara (formerly Lyna.ai)
|
| 28 |
+
- **Model type:** Fine-tuned Causal Language Model
|
| 29 |
+
- **Fine-tuning Technique:** LoRA / QLoRA
|
| 30 |
+
- **Base Model:** TinyLlama-1.1B or SmolLM2-1.7B
|
| 31 |
+
- **Persona:** A professional, empathetic medical assistant programmed to assist users in interpreting health metrics and managing medical crises.
|
| 32 |
+
|
| 33 |
+
### Model Sources
|
| 34 |
+
|
| 35 |
+
- **Repository:** [Klara-Project on Hugging Face](https://huggingface.co/Koussay/Klara-LLM-v1)
|
| 36 |
+
- **Deployment Platform:** Raspberry Pi 4/5 via Ollama or Llama.cpp
|
| 37 |
+
|
| 38 |
+
## Uses
|
| 39 |
+
|
| 40 |
+
### Direct Use
|
| 41 |
+
|
| 42 |
+
The model is designed to:
|
| 43 |
+
1. Provide context-aware medical explanations based on sensor inputs (HR, SpO2).
|
| 44 |
+
2. Offer immediate guidance when a medical crisis is detected by the companion CNN-BiLSTM model.
|
| 45 |
+
3. Answer user queries regarding physiological health trends.
|
| 46 |
+
|
| 47 |
+
### Out-of-Scope Use
|
| 48 |
+
|
| 49 |
+
This model is not a licensed medical professional. It must not be used for life-critical decisions without human verification. It is intended for supportive health monitoring and research purposes within the Klara ecosystem.
|
| 50 |
+
|
| 51 |
+
## Bias, Risks, and Limitations
|
| 52 |
+
|
| 53 |
+
- **Medical Accuracy:** While fine-tuned on medical logic, the model may occasionally hallucinate or provide generalized advice.
|
| 54 |
+
- **Hardware Constraints:** Being a small-parameter model, its reasoning depth is more limited compared to larger models like Llama-3 or GPT-4.
|
| 55 |
+
- **Privacy:** Designed for local inference to mitigate the risks associated with transmitting sensitive health data to the cloud.
|
| 56 |
+
|
| 57 |
+
## How to Get Started with the Model
|
| 58 |
+
|
| 59 |
+
The model is typically served via **Ollama** or **Gemma.cpp**. You can interact with it using a structured system prompt:
|
| 60 |
+
|
| 61 |
+
```text
|
| 62 |
+
System Prompt:
|
| 63 |
+
"You are Klara, a professional medical assistant created by Koussay Chaanbi.
|
| 64 |
+
Your goal is to monitor the user's health using sensor data and provide
|
| 65 |
+
clear, supportive advice during medical crises."
|