Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/echosingh/medibot
A bot That can provide Medical assistance anytime to anyone , Just ask it and see yourself 🤗
https://github.com/echosingh/medibot
chatbot gradio-interface llm machine-learning medbot medicalchatbot nlp pdf-document
Last synced: 2 days ago
JSON representation
A bot That can provide Medical assistance anytime to anyone , Just ask it and see yourself 🤗
- Host: GitHub
- URL: https://github.com/echosingh/medibot
- Owner: EchoSingh
- License: mit
- Created: 2024-05-11T22:34:56.000Z (6 months ago)
- Default Branch: main
- Last Pushed: 2024-07-24T03:48:39.000Z (4 months ago)
- Last Synced: 2024-07-25T05:33:18.763Z (4 months ago)
- Topics: chatbot, gradio-interface, llm, machine-learning, medbot, medicalchatbot, nlp, pdf-document
- Language: Jupyter Notebook
- Homepage:
- Size: 26.4 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# MediBot ☤🩺
## Note speed for answering question is : 12-15 minutes
![Running!!](https://github.com/aditya26062003/MediBot/blob/main/Screenshot%20(4).png)## BioMistral-7B.Q4_K_M.gguf with Langchain
This repository provides a quick setup for using the BioMistral-7B.Q4_K_M.gguf model with the Langchain library.
## Table of Contents
- [Introduction](#introduction)
- [Setup](#setup)
- [Requirements](#requirements)
- [Installation](#installation)
- [Usage](#usage)
- [Configuration](#configuration)
- [Contributing](#contributing)
- [License](#license)## Introduction
This project demonstrates how to use the BioMistral-7B.Q4_K_M.gguf model with Langchain for natural language processing tasks. BioMistral-7B is a specialized language model designed for biomedical text, and Langchain is a flexible library that simplifies the integration and usage of large language models.
## Setup
### Requirements
- Python 3.7+
- `requirements.txt` file for dependencies
- BioMistral-7B.Q4_K_M.gguf model file### Installation
1. Clone the repository:
```bash
git clone https://github.com/EchoSingh/biomistral-langchain-setup.git
cd biomistral-langchain-setup
```
2. Create a virtual environment and activate it:
```bash
python -m venv venv
source venv/bin/activate # On Windows, use `venv\Scripts\activate`
```
3. Install the required libraries:
```bash
pip install langchain
```
4. Download the BioMistral-7B.Q4_K_M.gguf model file and place it in your desired directory. Update the path in the usage example accordingly.### Usage
Here's an example script to get started with the BioMistral model using Langchain:
```python
from langchain.llms import CTransformers# Define the path to the BioMistral-7B.Q4_K_M.gguf model file
biomistral_model_path = "C:\\path\\to\\your\\BioMistral-7B.Q4_K_M.gguf.bin"# Initialize the BioMistral model with the appropriate parameters
biomistral_model = CTransformers(
model=biomistral_model_path,
model_type="mistral",
config={
'max_new_tokens': 1000,
'temperature': 0.75,
'context_length': 2000
}
)# Example usage of the model
prompt = "What are the symptoms of diabetes?"
response = biomistral_model(prompt)
print(response)
```
Replace "C:\\path\\to\\your\\BioMistral-7B.Q4_K_M.gguf.bin" with the actual path to your BioMistral model file.### Configuration
You can customize the model's behavior by modifying the config dictionary:1. max_new_tokens: Maximum number of tokens to generate.
2. temperature: Sampling temperature, controlling the randomness of predictions.
3. context_length: Maximum context length for the input.### Contributing
Contributions are welcome! Please open an issue or submit a pull request for any improvements or bug fixes.### License
This project is licensed under the MIT License.