Kossayart commited on
Commit
8a13cf9
·
verified ·
1 Parent(s): 31b7248

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +12 -13
README.md CHANGED
@@ -11,54 +11,55 @@ tags:
11
  - medical-llm
12
  library_name: peft
13
  pipeline_tag: text-generation
 
14
  ---
15
 
16
  # Model Card for Klara-Llama3-8B-v1
17
 
18
- Klara-Llama3-8B-v1 is a sophisticated medical assistant model fine-tuned from Meta's Llama 3 8B. It serves as the intelligent interface for the Klara health monitoring ecosystem, providing expert-level interpretation of physiological sensor data.
19
 
20
  ## Model Details
21
 
22
  ### Model Description
23
 
24
- By leveraging the advanced reasoning capabilities of Llama 3 8B, this model provides high-fidelity medical guidance. It is fine-tuned using **QLoRA** to maintain a balance between high-performance medical logic and the ability to run on consumer-grade or high-end edge hardware.
25
 
26
  - **Developed by:** Koussay Chaanbi
27
  - **Project Name:** Klara
28
  - **Model type:** Fine-tuned Causal Language Model
29
  - **Fine-tuning Technique:** QLoRA (4-bit Quantized LoRA)
30
  - **Base Model:** Meta-Llama-3-8B-Instruct
31
- - **Persona:** A professional and precise medical assistant created by Koussay Chaanbi, specialized in real-time health data analysis.
32
 
33
  ### Model Sources
34
 
35
  - **Repository:** [Klara-Project on Hugging Face](https://huggingface.co/Koussay/Klara-Llama3-8B-v1)
36
- - **Deployment Target:** Desktop/Edge environments using 4-bit quantization (GGUF/EXL2).
37
 
38
  ## Uses
39
 
40
  ### Direct Use
41
 
42
- 1. **Crisis Interpretation:** Explaining the severity and nature of medical crises detected by the CNN-BiLSTM sensor model.
43
- 2. **Contextual Health Advice:** Providing preventative advice based on trends in Heart Rate and SpO2.
44
- 3. **Structured Reporting:** Summarizing health metrics for university or medical review.
45
 
46
  ### Out-of-Scope Use
47
 
48
- This model is intended for research and supportive monitoring. It is not a substitute for clinical diagnostics or emergency medical services.
49
 
50
  ## Bias, Risks, and Limitations
51
 
52
- - **Compute Requirements:** Unlike 1B models, Llama 3 8B requires significant VRAM or 4-bit quantization to run effectively on edge devices like the Raspberry Pi (8GB recommended).
53
- - **Domain Specificity:** While excellent at reasoning, the model may still produce hallucinations regarding specific clinical dosages unless grounded in a RAG system.
54
 
55
  ## How to Get Started with the Model
56
 
57
- You can run this model using the `transformers` library with 4-bit quantization:
58
 
59
  ```python
60
  from transformers import AutoModelForCausalLM, AutoTokenizer
61
  import torch
 
62
 
63
  model_id = "meta-llama/Meta-Llama-3-8B-Instruct"
64
  adapter_id = "Koussay/Klara-Llama3-8B-v1-LoRA"
@@ -71,8 +72,6 @@ model = AutoModelForCausalLM.from_pretrained(
71
  torch_dtype=torch.bfloat16
72
  )
73
 
74
- # Apply the fine-tuned Klara adapters
75
- from peft import PeftModel
76
  model = PeftModel.from_pretrained(model, adapter_id)
77
 
78
  messages = [
 
11
  - medical-llm
12
  library_name: peft
13
  pipeline_tag: text-generation
14
+ inference: false # تم إضافة هذا السطر لإغلاق الـ API ومنع استهلاك التوكنز
15
  ---
16
 
17
  # Model Card for Klara-Llama3-8B-v1
18
 
19
+ **Note:** This model is part of a private graduation project (PFE). Access to weights and the Inference API is restricted to authorized users only.
20
 
21
  ## Model Details
22
 
23
  ### Model Description
24
 
25
+ Klara-Llama3-8B-v1 is a sophisticated medical assistant model fine-tuned from Meta's Llama 3 8B. It serves as the intelligent interface for the Klara health monitoring ecosystem, providing expert-level interpretation of physiological sensor data.
26
 
27
  - **Developed by:** Koussay Chaanbi
28
  - **Project Name:** Klara
29
  - **Model type:** Fine-tuned Causal Language Model
30
  - **Fine-tuning Technique:** QLoRA (4-bit Quantized LoRA)
31
  - **Base Model:** Meta-Llama-3-8B-Instruct
32
+ - **Persona:** A professional and precise medical assistant specialized in real-time health data analysis.
33
 
34
  ### Model Sources
35
 
36
  - **Repository:** [Klara-Project on Hugging Face](https://huggingface.co/Koussay/Klara-Llama3-8B-v1)
37
+ - **Deployment Target:** Desktop/Edge environments using 4-bit quantization.
38
 
39
  ## Uses
40
 
41
  ### Direct Use
42
 
43
+ - **Crisis Interpretation:** Explaining the severity and nature of medical crises detected by companion sensor models.
44
+ - **Contextual Health Advice:** Providing preventative advice based on physiological trends.
 
45
 
46
  ### Out-of-Scope Use
47
 
48
+ This model is **not** a substitute for professional clinical diagnostics or emergency medical services. It is intended for research and demonstration within the Klara project framework.
49
 
50
  ## Bias, Risks, and Limitations
51
 
52
+ - **Compute Requirements:** Requires significant VRAM or 4-bit quantization (GGUF/EXL2) for efficient inference.
53
+ - **Medical Accuracy:** Users must verify all outputs; the model may hallucinate specific clinical values.
54
 
55
  ## How to Get Started with the Model
56
 
57
+ *Note: Access must be requested and approved via the "Gated Access" system.*
58
 
59
  ```python
60
  from transformers import AutoModelForCausalLM, AutoTokenizer
61
  import torch
62
+ from peft import PeftModel
63
 
64
  model_id = "meta-llama/Meta-Llama-3-8B-Instruct"
65
  adapter_id = "Koussay/Klara-Llama3-8B-v1-LoRA"
 
72
  torch_dtype=torch.bfloat16
73
  )
74
 
 
 
75
  model = PeftModel.from_pretrained(model, adapter_id)
76
 
77
  messages = [