Question Answering
Transformers
Safetensors
English
phi
text-generation
medical
custom_code
text-generation-inference
Instructions to use prsdm/phi-2-medquad with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use prsdm/phi-2-medquad with Transformers:
# Use a pipeline as a high-level helper # Warning: Pipeline type "question-answering" is no longer supported in transformers v5. # You must load the model directly (see below) or downgrade to v4.x with: # pip install "transformers<5.0.0" from transformers import pipeline pipe = pipeline("question-answering", model="prsdm/phi-2-medquad", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("prsdm/phi-2-medquad", trust_remote_code=True) model = AutoModelForCausalLM.from_pretrained("prsdm/phi-2-medquad", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Commit History
-
Update README.md
Verified signature7015892 -
Update README.md
Verified signature6afe186 -
Update README.md
Verified signature66fac74 -
Update README.md
Verified signatureUpdated on 14th August 2024 # Fine-tuning Large Language Models <p> 😸<a href="https://huggingface.co/prsdm">GitHub</a> • 📝<a href="https://medium.com/@prasadmahamulkar/fine-tuning-phi-2-a-step-by-step-guide-e672e7f1d009">Article</a> • Models & Datasets on: 🤗<a href="https://huggingface.co/prsdm">Hugging Face</a> </a> </p> This repository provides a collection of Jupyter notebooks that demonstrate how to fine-tune large language models using various tools and techniques. fine-tuning or instruction tuning is the process where the pre-trained model is further trained on the smaller dataset to adapt its knowledge for a specific task or domain. This process tweaks the model’s parameters to perform specific tasks. In fine-tuning, there are two methods: ### Supervised fine tuning (SFT): In SFT, the model is trained on a labeled dataset. The labeled dataset typically contains examples of instruction (input) and response (output) pairs relevant to the task. In this process, the model l…9536c8b
-
Update README.md
Verified signature32b6edc -
Upload tokenizer
Verified signature8d40afa -
Upload PhiForCausalLM
Verified signatured7f1854 -
initial commit
Verified signatureb76953c