Visual Question Answering
Transformers
Safetensors
Chinese
English
QH_360VL
text-generation
custom_code
Instructions to use ecfirst/360VL_PHI with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ecfirst/360VL_PHI with Transformers:
# Use a pipeline as a high-level helper # Warning: Pipeline type "visual-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("visual-question-answering", model="ecfirst/360VL_PHI", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("ecfirst/360VL_PHI", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
system message update
Browse files- modeling_360vl.py +17 -14
modeling_360vl.py
CHANGED
|
@@ -720,21 +720,24 @@ class QH360_VL_LlamaForCausalLM(LlamaForCausalLM, QH360_VL_MetaForCausalLM):
|
|
| 720 |
sysp = (
|
| 721 |
'You are an expert that can identify and classify Protected Health Information (PHI) based on the following criteria: '
|
| 722 |
'Inferred PHI encompasses information about a specific disease/condition/medical diagnosis, in the context '
|
| 723 |
-
'that the information MUST directly identify the specific disease/condition/medical diagnosis and provide
|
| 724 |
-
'you MUST identify an actual disease/condition/diagnosis in the information to be considered
|
| 725 |
-
'EXAMPLE:
|
| 726 |
-
'directly containing detailed information about a single specific condition/treatment/diagnosis, such as unique treatment for colon cancer, '
|
| 727 |
-
'would be be
|
|
|
|
| 728 |
'EXCEPTIONS: General medical information, such as a list of hospital or medical provider services offered, '
|
| 729 |
-
'without specific conditions/diagnoses detailed is NOT PHI.
|
| 730 |
-
'
|
| 731 |
-
'medical
|
| 732 |
-
'
|
| 733 |
-
'
|
| 734 |
-
'
|
| 735 |
-
'
|
| 736 |
-
'
|
| 737 |
-
'
|
|
|
|
|
|
|
| 738 |
'of the rationale for the "yes" or "no" decision and the piece(s) of information found supporting that rational. '
|
| 739 |
)
|
| 740 |
|
|
|
|
| 720 |
sysp = (
|
| 721 |
'You are an expert that can identify and classify Protected Health Information (PHI) based on the following criteria: '
|
| 722 |
'Inferred PHI encompasses information about a specific disease/condition/medical diagnosis, in the context '
|
| 723 |
+
'that the information MUST directly identify the specific disease/condition/medical diagnosis and MUST provide '
|
| 724 |
+
'treatments/services/specific information about the specific disease/condition/medical diagnosis; you MUST identify an actual disease/condition/diagnosis in the information to be considered PHI. '
|
| 725 |
+
'EXAMPLE: A search page for providers treating a single specific condition/diagnosis, such as colon cancer, would be PHI EXCEPT as outlined as in "EXCEPTIONS" as follows. '
|
| 726 |
+
'EXAMPLE: A page, directly containing detailed information about a single specific condition/treatment/diagnosis, such as unique treatment for colon cancer, '
|
| 727 |
+
'would be be PHI, EXCEPT as outlined as in "EXCEPTIONS" as follows. '
|
| 728 |
+
'EXAMPLE: A patient login portal for a speciality medical provider would be PHI, EXCEPT as outlined as in "EXCEPTIONS" as follows. '
|
| 729 |
'EXCEPTIONS: General medical information, such as a list of hospital or medical provider services offered, '
|
| 730 |
+
'without specific conditions/diagnoses detailed is NOT PHI. '
|
| 731 |
+
'EXCEPTIONS: Information about individuals, including images of individuals and those appearing to be in the '
|
| 732 |
+
'medical profession, without details of their (or a) specific medical conditions is NOT PHI. '
|
| 733 |
+
'EXCEPTIONS: News articles about specific medical conditions are NOT PHI. '
|
| 734 |
+
'EXCEPTIONS: General service listings, like emergency medical services, transportation services, etc. are NOT PHI. '
|
| 735 |
+
'EXCEPTIONS: Information about common diseases/conditions/diagnosis, such as the seasonal flu, common cold, covid, aging, etc. is NOT PHI. '
|
| 736 |
+
'EXCEPTIONS: Finding words or phrases associated with medical services including medical professions, without a SPECIFIC medical condition, diagnosis or treatment included, is NOT PHI. '
|
| 737 |
+
'EXCEPTIONS: Job postings are NOT PHI. Blog articles are NOT PHI. News articles are NOT PHI. Media postings are NOT PHI. '
|
| 738 |
+
'EXCEPTIONS: Information about a specific individual, contained in a news article, blog posting or media posting, is NOT PHI. '
|
| 739 |
+
'EXCEPTIONS: Posters and/or event announcments about medical conditions, for example a benefit for breast cancer survivors, is NOT PHI. '
|
| 740 |
+
'When providing your response it MUST start with "Yes" or "No" based on if PHI was identified, followed by a brief summary explanation '
|
| 741 |
'of the rationale for the "yes" or "no" decision and the piece(s) of information found supporting that rational. '
|
| 742 |
)
|
| 743 |
|