⚕️ Medicus: Medical AI Assistant ⚕️
Описание на русском ниже
Medicus is a medical domain adaptation of Gemma2-2b-it, specifically fine-tuned for healthcare and medical applications. This model has been trained to support English and Russian languages, making it versatile for global medical use cases.
The fine-tuning process utilized the Continued Pretraining method over 10 epochs, ensuring optimization for medical domain understanding.
Examples are in the end of card
🔍 Model Details
- Base Model: Gemma2-2b-it
- Languages Supported: English and Russian
- Training Method: Continued Pretraining
- Epochs: 10
- Resources: 1 RTX A5000 24Gb vRAM for approximately 36 hours. The cost of finetuning is about $8.
- License: This model is distributed under the Gemma Terms of Use
Quantization Options
Medicus supports multiple quantization levels to allow flexible deployment based on computational resources:
Quantization Level | Description |
---|---|
Q8 | 8-bit quantization (standard) |
Q6_K | 6-bit quantization with K-means |
Q5_K_M | 5-bit quantization with K-means, mixed precision |
Q4_K_M | 4-bit quantization with K-means, mixed precision |
Q3_K_S | 3-bit quantization with K-means, small |
Q2_K | 2-bit quantization with K-means |
💡 Use Cases
Medicus is designed to assist with various medical and healthcare-related tasks, including:
- Medical Information Processing: Summarizing or extracting insights from medical texts.
- Healthcare-Related Queries: Answering questions about symptoms, treatments, and medical conditions.
- Clinical Documentation: Assisting in the generation, review, or organization of clinical notes.
- Medical Research Assistance: Supporting researchers with relevant insights or contextualizing medical literature.
Note: Medicus is a supplementary tool and should not replace professional medical judgment.
📊 Performance
Medicus retains the architectural benefits of its base model, Gemma, while being fine-tuned to comprehend and process medical domain-specific data. Its quantization options make it highly adaptable for both high-performance and resource-constrained environments.
🚀 Installation and Usage
We recommend using LMStudio for optimal performance and seamless integration.
For mobile devices we recommend LLM Farm
LMStudio Settings
To use Medicus in LMStudio, add the following preset configuration:
medicus.preset.json
{
"name": "Medicus",
"inference_params": {
"input_prefix": "<start_of_turn>user\n",
"input_suffix": "<end_of_turn>\n<start_of_turn>model\n",
"antiprompt": [
"<start_of_turn>user",
"<start_of_turn>model",
"<end_of_turn>"
],
"pre_prompt": "",
"pre_prompt_prefix": "",
"pre_prompt_suffix": "\n",
"n_threads": 4,
"n_predict": -1,
"top_k": 40,
"min_p": 0.3,
"top_p": 0.7,
"temp": 0.5,
"repeat_penalty": 1.1,
"seed": -1,
"tfs_z": 1,
"typical_p": 1,
"repeat_last_n": 64,
"frequency_penalty": 0,
"presence_penalty": 0,
"n_keep": 0,
"logit_bias": {},
"mirostat": 0,
"mirostat_tau": 5,
"mirostat_eta": 0.1,
"memory_f16": true,
"multiline_input": false,
"penalize_nl": true
},
"load_params": {
"n_ctx": 8192,
"n_batch": 512,
"rope_freq_base": 0,
"rope_freq_scale": 0,
"n_gpu_layers": -1,
"use_mlock": true,
"main_gpu": 0,
"tensor_split": [
0
],
"seed": -1,
"f16_kv": true,
"use_mmap": true
}
}
LLMFarm Prompt Format:
prompt format
<start_of_turn>user
{{prompt}} <end_of_turn>
<start_of_turn>model<reasoning>\n
⚠️ Limitations
While Medicus is trained on medical data, it should be used as a supplementary tool rather than a primary decision-making system in healthcare settings.
Key limitations include:
- It is not a substitute for professional medical advice, diagnosis, or treatment.
- Outputs may not always be accurate, reliable, or complete.
- Always consult a qualified healthcare professional for medical concerns.
❗ Disclaimer
THIS MODEL IS PROVIDED "AS IS," WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED.
The author and contributors make no guarantees regarding the accuracy, reliability, or completeness of any outputs generated by this model. Medicus should not be used as a replacement for professional medical judgment. Always seek the advice of a qualified healthcare provider for medical conditions.
The author explicitly disclaims any liability for actions taken based on this model's outputs.
🌍 Multilingual Support
Medicus is optimized for English and Russian, allowing it to assist in diverse linguistic and regional contexts.
📬 Contact
For issues, questions, or suggestions, feel free to open an issue in the repository or contact the authors.
⚕️ Medicus: Медицинский AI-ассистент ⚕️
Medicus — это медицинская адаптация модели Gemma2-2b-it, специально дообученная для применения в сфере здравоохранения и медицины. Модель поддерживает русский и английский языки, что делает её универсальной для использования в различных медицинских контекстах.
Дообучение модели проводилось методом Continued Pretraining в течение 10 эпох, что позволило адаптировать её под задачи медицинской тематики.
** Примеры ** в самом конце
🔍 Детали модели
- Базовая модель: Gemma2-2b-it
- Поддерживаемые языки: Русский и английский
- Метод обучения: Continued Pretraining
- Количество эпох: 10
- Оборужование: 1 RTX A5000 24Gb vRAM приблизительно в течение 36 часов. Общие затраты на файнтюнинг около $8.
- Лицензия: Модель распространяетчя по лицензии Google Gemma Terms of Use
Варианты квантизации
Medicus поддерживает различные уровни квантизации, что позволяет гибко развертывать модель в зависимости от доступных вычислительных ресурсов:
Уровень квантизации | Описание |
---|---|
Q8 | 8-битная квантизация (стандарт) |
Q6_K | 6-битная квантизация с использованием K-средних |
Q5_K_M | 5-битная квантизация с K-средними, смешанная точность |
Q4_K_M | 4-битная квантизация с K-средними, смешанная точность |
Q3_K_S | 3-битная квантизация с K-средними, малая |
Q2_K | 2-битная квантизация с K-средними |
💡 Варианты использования
Medicus разработан для помощи в решении медицинских и связанных со здравоохранением задач, включая:
- Обработка медицинской информации: Суммаризация и извлечение ключевых данных из медицинских текстов.
- Ответы на вопросы: Консультации по симптомам, методам лечения и медицинским терминам.
- Клиническая документация: Помощь в создании, редактировании и структурировании записей врача.
- Анализ медицинских исследований: Помощь в изучении и интерпретации медицинской литературы.
Важно: Medicus является вспомогательным инструментом и не заменяет профессиональное медицинское мнение.
📊 Производительность
Модель Medicus сохраняет преимущества архитектуры своей базовой версии (Gemma), при этом дополнительно оптимизирована для задач медицинской области. Различные уровни квантизации позволяют адаптировать её как для мощных, так и для ограниченных по ресурсам устройств.
🚀 Установка и использование
Рекомендуется использовать LMStudio для оптимальной производительности и удобства работы. Для мобильных устройств рекомендовано LLM Farm
Настройски для LMStudio
Для работы с Medicus в LMStudio добавьте следующий конфигурационный файл:
medicus.preset.json
{
"name": "Medicus",
"inference_params": {
"input_prefix": "<start_of_turn>user\n",
"input_suffix": "<end_of_turn>\n<start_of_turn>model\n",
"antiprompt": [
"<start_of_turn>user",
"<start_of_turn>model",
"<end_of_turn>"
],
"pre_prompt": "",
"pre_prompt_prefix": "",
"pre_prompt_suffix": "\n",
"n_threads": 4,
"n_predict": -1,
"top_k": 40,
"min_p": 0.3,
"top_p": 0.7,
"temp": 0.5,
"repeat_penalty": 1.1,
"seed": -1,
"tfs_z": 1,
"typical_p": 1,
"repeat_last_n": 64,
"frequency_penalty": 0,
"presence_penalty": 0,
"n_keep": 0,
"logit_bias": {},
"mirostat": 0,
"mirostat_tau": 5,
"mirostat_eta": 0.1,
"memory_f16": true,
"multiline_input": false,
"penalize_nl": true
},
"load_params": {
"n_ctx": 8192,
"n_batch": 512,
"rope_freq_base": 0,
"rope_freq_scale": 0,
"n_gpu_layers": -1,
"use_mlock": true,
"main_gpu": 0,
"tensor_split": [
0
],
"seed": -1,
"f16_kv": true,
"use_mmap": true
}
}
LLMFarm Prompt Format:
prompt format
<start_of_turn>user
{{prompt}} <end_of_turn>
<start_of_turn>model<reasoning>\n
⚠️ Ограничения
Хотя Medicus обучен на медицинских данных, модель должна использоваться как вспомогательный инструмент, а не как основной источник принятия решений в медицинской практике.
Основные ограничения:
- Модель не заменяет профессиональный медицинский совет, диагностику или лечение.
- Результаты модели могут быть неточными, неполными или ненадежными.
- Всегда консультируйтесь с квалифицированными специалистами по всем вопросам, связанным с медицинскими состояниями.
❗ Отказ от ответственности
ЭТА МОДЕЛЬ ПРЕДОСТАВЛЯЕТСЯ "КАК ЕСТЬ", БЕЗ ГАРАНТИЙ ЛЮБОГО РОДА.
Автор и участники разработки не несут ответственности за точность, надежность или полноту данных, сгенерированных моделью. Medicus не следует использовать как замену профессионального медицинского мнения. Всегда обращайтесь к квалифицированным медицинским специалистам по вопросам состояния здоровья.
Автор не несет ответственности за любые действия, предпринятые на основе результатов работы модели.
🌍 Поддержка нескольких языков
Medicus оптимизирован для работы на русском и английском языках, что позволяет использовать его в различных регионах и языковых контекстах.
📬 Контакты
Если у вас есть вопросы, предложения или замечания, вы можете открыть issue в репозитории или связаться с авторами.
Examples
Вопрос пациента (Ru)
Prompt:
Мама (71 год), находясь в стационаре с диагнозом "остеопороз", упала и ударилась рукой (со слов врача 4.02.2025).
Врач сказал, что у нее легкий ушиб. При посещении я заметила у нее на руке ссадину около 4 см и синяк желтого цвета с кровоподтеками на предплечье,
а также черный синяк на кисти. Ей не назначают дополнительное лечение, связанное с падением, травму считают незначительной.
Есть ли риски более серьезного повреждения?
Model response:
Ситуация требует внимательного рассмотрения. Хотя врач оценивает ушиб как легкий и не назначает дополнительного лечения, наличие таких характерных признаков травмы (ссадина, синяк с кровоподтеком, черный синяк) заставляет задуматься о возможности более серьезных повреждений.
**Вот почему стоит беспокоиться:**
* **Черный синяк**: Он указывает на тромбоз мелких сосудов. Тромбы могут развиваться даже при казалось незначительной травме, особенно у пожилых людей с остеопорозом, когда костная ткань более хрупкая и склонна к переломам.
* **Ушиб**: Хотя врач диагностировал его как легкий, важно помнить, что ушибы могут быть скрытыми и затрагивать более глубокие ткани. В данном случае синяк желтого цвета с кровоподтеками может свидетельствовать о повреждении мягких тканей или мелких сосудов под кожей.
* **Возраст**: Остеопороз у пожилых людей снижает плотность костной ткани, делая их более склонными к переломам и разрывам связок при падении. Это может привести к невидимым повреждениям мягких тканей или даже смещению костей в руке.
* **Необходимость тщательного обследования**: Без визуального осмотра сложно точно оценить состояние руки. Возможно, есть скрытые переломы или разрывы связок, которые требуют лечения.
**Что нужно сделать:**
1. **Консультация с другим специалистом**: Необходимо обратиться к другому травматологу для повторного осмотра и получения более точной оценки состояния руки.
2. **Рентген/КТ**: Необходимы рентгеновские снимки или компьютерная томография (КТ) для выявления возможных переломов или других повреждений костей и мягких тканей.
3. **Контроль за симптомами**: Важно следить за состоянием руки в ближайшие дни и недели, обращаясь к врачу при появлении новых болей, отеков, скованности движений или ухудшении самочувствия.
Важно помнить, что учитывая возраст и наличие остеопороза, даже незначительная травма может иметь серьезные последствия. Необходимо не полагаться на слова врача и пройти дополнительное обследование для исключения возможных повреждений
Ситуационная задача (Ru)
Prompt:
На прием обратился пациент 32 лет с жалобами на апатию, снижение интереса к окружающему, бессонницу.
На визите сидит в однообразной позе, речь монотонная. На вопросы отвечает односложно.
Отмечает, что "Суицидальных мыслей нет, но иногда хочется, чтобы все это как можно быстрее закончилось".
Какой вероятный диагноз? Какие действия?
Model response:
Пациент описывает симптомы, которые указывают на возможную депрессию.
**Вероятные диагнозы:**
* **Депрессия**:
* Апатия и снижение интереса к окружающему - характерные признаки.
* Бессонница также является распространенным проявлением депрессии.
* Однообразная поза, монотонная речь и односложное ответы указывают на изменение поведения, вызванное состоянием.
**Необходимые действия:**
1. **Сделать вывод о тяжести состояния**: Пациент говорит об "желании все как можно скорее закончить", что может свидетельствовать о глубоком чувстве безнадежности и желании избавиться от страданий. Это требует более пристального внимания.
2. **Провести тщательное обследование**:
* Необходимо выяснить наличие сопутствующих заболеваний (например, хронических болевых синдромов), которые могут влиять на самочувствие.
* Важно оценить уровень энергии пациента и степень влияния симптомов на его повседневную жизнь.
3. **Начать лечение**: В данном случае, учитывая выраженность симптомов, скорее всего потребуется не только психотерапия, но и медикаментозное лечение.
4. **Оценить suicidality**: Пациент говорит о желании "все как можно скорее закончить", что требует внимания. Необходимо провести более детальный анализ его суицидального риска:
* Проанализировать историю самоповреждений, если таковая имеется.
* Спросить о наличии попыток самоубийства в прошлом и о том, насколько серьезны его мысли по этому поводу сейчас.
5. **Обеспечить поддержку**: Пациенту необходимо обеспечить эмоциональную поддержку и объяснить ему важность лечения депрессии.
6. **Направить на консультацию специалиста**: В связи с выраженными симптомами, пациенту может потребоваться более глубокое обследование у психиатра или психолога для оценки suicidality и назначения адекватной терапии.
**Важно помнить:** Это предварительные выводы, основанные на описании пациента. Для точного диагноза и лечения необходима комплексная оценка состояния в условиях личной консультации с врачом-психиатром
Анализ статьи (Ru)
Prompt:
The therapeutic use of acetaminophen in patients with liver disease
Gordon D Benson 1, Raymond S Koff, Keith G Tolman
Affiliations Expand
PMID: 15767831 DOI: 10.1097/01.mjt.0000140216.40700.95
Abstract
Acetaminophen has been used safely and effectively for many years to manage pain and/or fever in patients of all ages.
It is commonly recommended as first-line therapy for a variety of patients and conditions, including the elderly,
children with viral illnesses, and patients with osteoarthritis, gastrointestinal conditions, bleeding disorders,
cardiovascular disease, or renal disease. However, its use is often avoided in patients with chronic liver disease.
The perception that acetaminophen should be avoided in such patients arose from awareness of the association between massive acetaminophen overdose and hepatotoxicity,
combined with a lack of understanding of the metabolism of acetaminophen in patients with liver disease.
There are various theoretical mechanisms of acetaminophen hepatotoxicity in chronic liver disease including:
altered metabolism and depleted glutathione stores that would be expected to increase accumulation of the hepatotoxic intermediate,
N-acetyl-p-benzoquinone imine (NAPQI). Available studies in patients with chronic liver disease, however,
have shown that although the half-life of acetaminophen may be prolonged, cytochrome P-450 activity is not increased and glutathione stores
are not depleted to critical levels in those taking recommended doses. Furthermore, acetaminophen has been studied in a variety of
liver diseases without evidence of increased risk of hepatotoxicity at currently recommended doses.
Therefore, acetaminophen can be used safely in patients with liver disease and is a preferred analgesic/antipyretic
because of the absence of the platelet impairment, gastrointestinal toxicity, and nephrotoxicity associated with nonsteroidal antiinflammatory drugs.
Напиши в одном абзаце смысл статьи
Model response:
Статья "Therapeutic use of acetaminophen in patients with liver disease" рассматривает вопрос о безопасности и эффективности
ацетаминофена для пациентов с заболеваниями печени. Хотя первоначально его использование в этом случае предпочтительно избегать из-за
риска передозировки, исследования показывают, что при рекомендуемой дозе ацетаминофена нет доказательств увеличения его токсичности у пациентов
с заболеваниями печени. В отличие от нестероидных противовоспалительных препаратов (НПВП), которые могут вызывать проблемы с почками и другими
побочными эффектами, ацетаминофен не имеет этих недостатков при осторожном применении.
Таким образом, для пациентов с заболеваниями печени ацетаминофен является безопасным
выбором для управления болью и лихорадкой без риска передозировки
Patient Question (En)
Prompt:
My mother (71 years old), while in hospital with a diagnosis of osteoporosis, fell and hit her arm (according to the doctor on 4.02.2025).
The doctor said she had a mild contusion. At the visit, I noticed an abrasion of about 4 cm on her arm and a
yellow coloured bruise with bruising on her forearm and a black bruise on her hand.
She is not receiving any further treatment related to the fall, the injury is considered minor.
Are there risks of a more serious injury?
Model response:
I understand your concern for your mother's health after the fall. While it sounds like the doctor considers the injury "mild," it's wise to be aware of potential long-term risks associated with osteoporosis and falls, especially at her age.
**Here's a breakdown of why you should be cautious:**
* **Osteoporosis:** As your mother is diagnosed with osteoporosis, her bones are weaker than average. This makes them more susceptible to fractures even from seemingly minor impacts like a fall. While the doctor says it was "mild," a 4cm abrasion can still involve broken or weakened bone beneath the skin.
* **Contusion and Bruising:** The contusion (bruised area) indicates internal bleeding in the soft tissues, which is common with any injury. However, the extensive bruising on her arm, forearm, and hand suggests that the force of the fall may have affected multiple layers of tissue.
* **Black Bruise on Hand:** A black bruise often signifies a deeper contusion or possible damage to capillaries in the skin, indicating more significant bleeding than just surface-level bruising.
**Potential Long-Term Risks:**
* **Fracture Healing:** Even if there's no visible fracture now, osteoporosis can make bone healing take longer and be less efficient.
* **Repetitive Injuries:** Falls are common for older adults, especially those with osteoporosis. Repeated falls could lead to further injuries or even a hidden fracture that goes unnoticed initially.
* **Pressure Ulcers:** The bruising and potential damage to skin from the fall may increase the risk of developing pressure ulcers (bedsores) if she's not properly repositioned regularly in bed.
**What You Can Do:**
1. **Communication:** Keep talking to her doctor about any changes you observe in her recovery or how she feels.
2. **Fall Prevention Measures:** Encourage your mother to follow fall prevention strategies, such as removing tripping hazards from her home, using grab bars in the bathroom, and wearing supportive shoes.
3. **Regular Checkups:** Continue getting regular checkups with her doctor to monitor her bone health and overall recovery.
**Important Note:** I am an AI chatbot and cannot provide medical advice. It's crucial for your mother to continue communicating with her doctor about any concerns you have regarding her injury and long-term health.
Remember, while the initial fall seems manageable now, it's essential to be vigilant about potential risks associated with osteoporosis and monitor her recovery closely.
Clinical Case (En)
Prompt:
A 32-year-old patient came to the clinic with complaints of apathy, decreased interest in the surrounding environment, insomnia.
At the visit he sits in a monotonous posture, his speech is monotonous.
He answers questions one-syllable. Notes that ‘There are no suicidal thoughts, but sometimes
I wish it would all end as soon as possible’. What is the likely diagnosis? What actions?
Model response:
The symptoms you describe – apathy, insomnia, monotonous behavior and speech, lack of eye contact, flat affect, and a desire for death despite not having active suicidal thoughts – are highly suggestive of **major depressive disorder**.
Here's a breakdown:
* **Apathy and decreased interest:** These are core features of depression. The patient's disengagement from activities they once enjoyed is characteristic.
* **Insomnia:** Difficulty sleeping is another common symptom of depression, often exacerbated by racing thoughts that keep the mind active at night.
* **Monotonous posture and speech:** This reflects a loss of energy and motivation, as well as possible emotional detachment.
* **One-syllable answers:** The brevity of responses indicates a lack of engagement or even emotional numbing.
* **Lack of eye contact:** Avoiding eye contact can be a sign of social withdrawal and internal struggles associated with depression.
**Actions to take:**
1. **Empathetic validation:** Start by acknowledging the patient's feelings without judgment. Let them know that you understand their experience is difficult, and that their emotions are valid.
2. **Open-ended questions:** Encourage the patient to talk about their experiences in more detail. Ask open-ended questions like "Can you tell me more about what it feels like to have this apathy?" or "How does your insomnia affect your daily life?".
3. **Normalize feelings of sadness:** Reassure the patient that feeling sad is normal, but that depression goes beyond temporary sadness and impacts their overall functioning.
4. **Offer practical support:** Help the patient identify small steps they can take to improve their mood and routine, such as getting enough sleep, engaging in gentle exercise, or spending time in nature.
5. **Encourage professional help:** Gently suggest that seeking professional help from a psychiatrist or therapist could provide them with valuable tools and strategies for managing depression.
**Important notes:**
* It's crucial to create a safe and supportive environment where the patient feels comfortable sharing their experiences.
* Be patient, as recovery takes time and effort.
* Remember that you are not a mental health professional; your role is to provide support and encouragement.
In this situation, it would be beneficial for the patient to consult with a psychiatrist or therapist for proper diagnosis and treatment options. They can prescribe medication (such as antidepressants) if necessary and offer therapy to address underlying emotional issues.
Article Analysis (En)
Prompt:
The therapeutic use of acetaminophen in patients with liver disease
Gordon D Benson 1, Raymond S Koff, Keith G Tolman
Affiliations Expand
PMID: 15767831 DOI: 10.1097/01.mjt.0000140216.40700.95
Abstract
Acetaminophen has been used safely and effectively for many years to manage pain and/or fever in patients of all ages.
It is commonly recommended as first-line therapy for a variety of patients and conditions, including the elderly,
children with viral illnesses, and patients with osteoarthritis, gastrointestinal conditions, bleeding disorders,
cardiovascular disease, or renal disease. However, its use is often avoided in patients with chronic liver disease.
The perception that acetaminophen should be avoided in such patients arose from awareness of the association between massive acetaminophen overdose and hepatotoxicity,
combined with a lack of understanding of the metabolism of acetaminophen in patients with liver disease.
There are various theoretical mechanisms of acetaminophen hepatotoxicity in chronic liver disease including:
altered metabolism and depleted glutathione stores that would be expected to increase accumulation of the hepatotoxic intermediate,
N-acetyl-p-benzoquinone imine (NAPQI). Available studies in patients with chronic liver disease, however,
have shown that although the half-life of acetaminophen may be prolonged, cytochrome P-450 activity is not increased and glutathione stores
are not depleted to critical levels in those taking recommended doses. Furthermore, acetaminophen has been studied in a variety of
liver diseases without evidence of increased risk of hepatotoxicity at currently recommended doses.
Therefore, acetaminophen can be used safely in patients with liver disease and is a preferred analgesic/antipyretic
because of the absence of the platelet impairment, gastrointestinal toxicity, and nephrotoxicity associated with nonsteroidal antiinflammatory drugs.
Provide summary about article in on abstract
Model response:
Acetaminophen is generally safe for use in patients with chronic liver disease at recommended doses.
Although there was once concern about its safety due to potential links to liver damage from overdose, research has
shown that at therapeutic levels, acetaminophen does not increase the risk of liver problems.
Here's a breakdown:
* **Theoretical concerns:** Past beliefs held that acetaminophen could be harmful in patients with liver disease because it might lead to increased buildup of toxic chemicals and depletion of protective substances within the liver.
* **Practical findings:** Studies have revealed that, at typical doses used for pain relief or fever reduction, acetaminophen doesn't actually increase these risks. In fact, its half-life is slightly longer in patients with liver disease, but their overall metabolism isn't significantly altered.
This means that acetaminophen can be safely used as an alternative to other painkillers (NSAIDs) which have additional potential side effects like bleeding or kidney problems. In essence, the article emphasizes that under normal circumstances, acetaminophen is a safe and effective option for patients with liver disease who need pain management.
- Downloads last month
- 390