CN109920524B - Multi-prescription pharmacist distribution method - Google Patents
Multi-prescription pharmacist distribution method Download PDFInfo
- Publication number
- CN109920524B CN109920524B CN201910133673.7A CN201910133673A CN109920524B CN 109920524 B CN109920524 B CN 109920524B CN 201910133673 A CN201910133673 A CN 201910133673A CN 109920524 B CN109920524 B CN 109920524B
- Authority
- CN
- China
- Prior art keywords
- prescription
- pharmacist
- feature
- data
- prescriptions
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Landscapes
- Medical Treatment And Welfare Office Work (AREA)
- Medical Preparation Storing Or Oral Administration Devices (AREA)
Abstract
The invention discloses a multi-prescription pharmacist distribution method, which comprises the following steps: (1) acquiring data of prescriptions and pharmacists; (2) performing feature extraction on the data obtained in the step (1); (3) constructing a feature matrix based on the features extracted in the step (2); (4) performing data format on the feature matrix constructed in the step (3), and inputting the feature matrix into a LambdaMART model for training; (5) and after the characteristics of the new prescription are extracted, inputting the new prescription into a trained LambdaMART model to obtain the score of each pharmacist, wherein the highest score is the pharmacist most suitable for processing the prescription. The invention introduces a learning to rank algorithm in the distribution problem of traditional Chinese medicine pharmacists for the first time. Through learning the sequencing algorithm, the effect of automatically distributing the most appropriate pharmacists can be achieved, the cost of labor distribution can be reduced, and the quality and efficiency of steps of grabbing, weighing, packaging and the like of the prescription can be optimized.
Description
Technical Field
The invention relates to the technical field of intellectualization of traditional Chinese medicines, in particular to a multi-prescription pharmacist distribution method.
Background
The medical health career is a great civil problem related to the healthy life of thousands of people and is also a basic element for maintaining the stability and development of the society. The development of the traditional Chinese medicine has a long history of thousands of years, has the characteristics of good curative effect, small side effect, small environmental pollution and the like, and especially plays an important role in the aspects of prevention and health care, disease rehabilitation and the like.
At present, the demand of traditional Chinese medicines is getting bigger and bigger, the variety of traditional Chinese medicines is thousands of traditional Chinese medicines, and the requirements for pharmacists are also getting higher and higher. At present, in most traditional Chinese medicine rooms, traditional Chinese medicine prescriptions are randomly distributed to pharmacists to complete the steps of grabbing, weighing, packaging and the like. However, different pharmacists have their own familiar and unfamiliar prescriptions, and can be fast and good at handling familiar prescriptions, but can be much less efficient and even erroneous at handling unfamiliar prescriptions. It is desirable that each prescription of a traditional Chinese medicine be distributed to the most appropriate pharmacist to optimize the quality and efficiency of the steps of taking, weighing, packaging, etc. the prescription. According to investigations, we have found that there is currently no better approach to this problem.
Disclosure of Invention
In view of the above disadvantages, the present invention provides a multi-prescription pharmacist distribution method.
The technical scheme adopted by the invention is as follows: a multi-prescription pharmacist dispensing method comprising the steps of:
(1) acquiring data of prescriptions and pharmacists;
(2) performing feature extraction on the data obtained in the step (1);
(3) constructing a feature matrix based on the features extracted in the step (2);
(4) performing data format on the feature matrix constructed in the step (3), and inputting the feature matrix into a LambdaMART model for training;
(5) and after the characteristics of the new prescription are extracted, inputting the new prescription into a trained LambdaMART model to obtain the score of each pharmacist, wherein the highest score is the pharmacist most suitable for processing the prescription.
Further, the characteristics extracted for the prescription data include the type of prescription, which drugs are included in the prescription, and the dose of each drug; there is also a feature between prescriptions, namely the number of conflicting medications between the prescriptions.
Further, the features extracted for the pharmacist data include the experience of the pharmacist and the status of the pharmacist.
Further, assuming that there are n pharmacists a1, a2, …, An and m prescriptions 1,2, …, m, the feature matrix constructed in the step (3) is as follows:
wherein, the label of the most suitable pharmacist corresponding to the prescription is 1, and the rest are 0;
the prescription types are classifications aiming at various diseases, and the classifications can be correspondingly numbered;
the medicament 1-medicament k is all medicaments forming the traditional Chinese medicine prescription, if the prescription contains the medicaments, the dosage of the medicaments is a constant larger than zero, otherwise, the dosage is 0; thus, by the agent 1-agent k, it is possible to obtain which agents a prescription contains and the dose of each agent;
the pharmacist experience is the number of times and the speed of the pharmacist taking the prescription, wherein the speed is the average time required by the pharmacist to take the prescription;
the pharmacist status is whether the pharmacist is taking a prescription;
it should be noted that the number of conflicting medications between prescriptions need not be individually characterized because the matrix contains conflicting information regarding the medications 1-k and the pharmacist status at the same time.
Further, the data format in the step (4) is as follows:
<line>.=.<target>qid:<qid><feature>:<value><feature>:<value>...<feature>:<value>
wherein the parameter < line > represents a piece of data, each piece of data occupying the position of a line; target is a label, qid is the number of each group, all rows of the same prescription in the characteristic matrix are a group, one pharmacist in the group is a recommended pharmacist, the label is 1, and the labels of the other pharmacists are 0; feature is all extracted features; < value > represents a numerical value corresponding to the feature.
The invention has the following effective effects: the invention introduces a learning to rank algorithm in the distribution problem of traditional Chinese medicine pharmacists for the first time. Through learning the sequencing algorithm, the effect of automatically distributing the most appropriate pharmacists can be achieved, the cost of labor distribution can be reduced, and the quality and efficiency of steps of grabbing, weighing, packaging and the like of the prescription can be optimized. Meanwhile, the invention also provides a complete flow frame from the acquisition of the original data, the characteristic engineering, the construction of the characteristic matrix to the establishment of the recommendation model, thereby improving the feasibility and the practical value of the automatic distribution of the traditional Chinese medicine pharmacists.
Drawings
FIG. 1 is a flow chart of the method of the present invention.
Detailed Description
The present invention will be described in further detail with reference to the following examples and the accompanying drawings.
Example 1:
the multi-prescription pharmacist distribution method mainly comprises two stages, namely a model training stage and a model application stage, and the main flow is shown in figure 1:
in the model training phase, in order to construct a model for automatically distributing pharmacists, we first need to manually extract some features from the raw data of the prescriptions and pharmacists, and the extracted features need to be able to characterize the relationship between each prescription and each pharmacist. Specifically, the following categories are included:
a) for each pharmacist, the following characteristics are present: the experience of the pharmacist, the status of the pharmacist.
b) For each prescription, there are some characteristics such as the kind of prescription, which medicines are contained in the prescription, and the dosage of each medicine.
c) In addition, there is a feature between prescriptions that the number of conflicting medications between prescriptions.
Based on these features, we construct a feature matrix. We assume that there are n pharmacists A1, A2, …, An and m prescriptions 1,2, …, m.
In the above matrix, there are a total of n x m combinations of n pharmacists and m prescriptions, i.e., there are n x m rows, each row being the label of the combination and the characteristics of the pharmacist and prescription contained therein. The most suitable pharmacist for the prescription has a label of 1, and the others are all 0. The prescription types are classifications aiming at various diseases, and the classifications can be correspondingly numbered; the medicament 1-the medicament k are all medicines forming the traditional Chinese medicine prescription, if the prescription contains the medicines, the dosage of the medicines is a constant larger than zero, otherwise, the dosage is 0; thus, with agents 1-k, it is possible to obtain which agents a prescription contains and the dosage of each agent; the pharmacist experience is the number of times and the speed of the pharmacist taking the prescription, wherein the speed is the average time required by the pharmacist to take the prescription; the pharmacist status is whether the pharmacist is taking a prescription. It should be noted that the number of conflicting medications between prescriptions need not be individually characterized because the matrix contains conflicting information regarding the combination of medication 1-medication k and pharmacist status at the same time. Furthermore, in theory, similar prescriptions should be assigned to the same pharmacist, and this information is contained in the matrix we build itself, so this rule can be learned automatically with machine-learned algorithms.
With the above feature matrix, we apply a very good recommendation algorithm learning ranking (learning to rank) in machine learning to recommend the most appropriate pharmacist for each prescription. We use the commonly used open source algorithm library ranklib to implement our recommendation method. The Ranklib requires a data input format as follows:
<line>.=.<target>qid:<qid><feature>:<value><feature>:<value>...<feature>:<value>
wherein the parameter < line > represents a piece of data, each piece of data occupying the position of a line; target is a label, qid is the number of each group, all rows of the same prescription in the characteristic matrix are a group, one pharmacist in the group is a recommended pharmacist, the label is 1, and the labels of the other pharmacists are 0; feature is all extracted features; < value > represents a numerical value corresponding to the feature. Therefore, we can input the above matrix into ranklib. Furthermore, ranklib has several parameters that can be set, the most important of which is the specific algorithm used to learn the ranking. We used the Lambdamart model. The Lambdamart model is a listwise learning ranking model. The LambdaMART model has two major advantages: firstly, training can be continued on the existing model, and the method is suitable for incremental learning; and secondly, the method is insensitive to unbalanced data of positive and negative samples. These two major advantages may well be exploited in our pharmacist dispensing problem.
After the model is built and a prescription is newly made, the fitting score of each pharmacist for the prescription can be calculated and obtained based on the characteristics of the prescription, and the most suitable pharmacist is obtained.
Claims (3)
1. A multi-prescription pharmacist dispensing method, comprising the steps of:
the method comprises the following steps of (1) acquiring data of a prescription and a pharmacist;
step (2) extracting the characteristics of the data obtained in the step (1);
step (3) constructing a feature matrix based on the features extracted in the step (2);
step (4) performing data format on the feature matrix constructed in the step (3), and inputting the feature matrix into a LambdaMART model for training;
step (5) after the characteristics of the new prescription are extracted, inputting the new prescription into a trained LambdaMART model to obtain the score of each pharmacist, wherein the highest score is the pharmacist most suitable for processing the prescription;
the features extracted for the pharmacist data include the experience of the pharmacist and the status of the pharmacist;
assuming that there are n pharmacists a1, a2, …, An and m prescriptions 1,2, …, m, the feature matrix constructed in the step (3) is as follows:
wherein, the label of the most suitable pharmacist corresponding to the prescription is 1, and the rest are 0;
the prescription types are classifications aiming at various diseases, and the classifications can be correspondingly numbered;
the medicament 1-medicament k is all medicaments forming the traditional Chinese medicine prescription, if the prescription contains the medicaments, the dosage of the medicaments is a constant larger than zero, otherwise, the dosage is 0; thus, by the agent 1-agent k, it is possible to obtain which agents a prescription contains and the dose of each agent;
the pharmacist experience is the number of times and the speed of the pharmacist taking the prescription, wherein the speed is the average time required by the pharmacist to take the prescription;
the pharmacist status is whether the pharmacist is taking a prescription;
it should be noted that the number of conflicting medications between prescriptions need not be individually characterized because the matrix contains conflicting information regarding the medications 1-k and the pharmacist status at the same time.
2. The multi-prescription pharmacist allocation method according to claim 1, wherein the data format in the step (4) is as follows:
<line> .=. <target> qid:<qid><feature>:<value><feature>:<value> ... <feature>:<value>
wherein the parameter < line > represents a piece of data, each piece of data occupying the position of a line; target is a label, qid is the number of each group, all rows of the same prescription in the characteristic matrix are a group, one pharmacist in the group is a recommended pharmacist, the label is 1, and the labels of the other pharmacists are 0; feature is all extracted features; < value > represents a numerical value corresponding to the feature.
3. The multi-prescription pharmacist allocation method according to claim 1, wherein the characteristics extracted for prescription data include the kind of prescription, what medicines are contained in the prescription, and the dose of each medicine; there is also a feature between prescriptions, namely the number of conflicting medications between the prescriptions.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910133673.7A CN109920524B (en) | 2019-02-22 | 2019-02-22 | Multi-prescription pharmacist distribution method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910133673.7A CN109920524B (en) | 2019-02-22 | 2019-02-22 | Multi-prescription pharmacist distribution method |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109920524A CN109920524A (en) | 2019-06-21 |
CN109920524B true CN109920524B (en) | 2021-01-08 |
Family
ID=66961990
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910133673.7A Active CN109920524B (en) | 2019-02-22 | 2019-02-22 | Multi-prescription pharmacist distribution method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109920524B (en) |
Family Cites Families (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101076311B (en) * | 2004-10-28 | 2011-05-04 | 株式会社汤山制作所 | Dispensing support system and dispensing support method |
CA2924966C (en) * | 2013-09-20 | 2022-04-05 | Corcept Therapeutics, Inc. | Systems and methods of treatment using intervention and tasking determination |
CN105701582A (en) * | 2014-11-24 | 2016-06-22 | 吴正燕 | Traditional Chinese medicine prescription dispensing work method and intelligent dispatching system thereof |
CN106201465B (en) * | 2016-06-23 | 2020-08-21 | 扬州大学 | Software project personalized recommendation method for open source community |
JP6597750B2 (en) * | 2017-10-25 | 2019-10-30 | キヤノンマーケティングジャパン株式会社 | The present invention relates to an information processing apparatus, a control method for the information processing apparatus, and a program. |
CN108763321B (en) * | 2018-05-02 | 2021-07-06 | 深圳智能思创科技有限公司 | Related entity recommendation method based on large-scale related entity network |
-
2019
- 2019-02-22 CN CN201910133673.7A patent/CN109920524B/en active Active
Also Published As
Publication number | Publication date |
---|---|
CN109920524A (en) | 2019-06-21 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR102292344B1 (en) | Personalized nutritional ingredient recommendation method and server | |
Blommaert et al. | Determinants of between-country differences in ambulatory antibiotic use and antibiotic resistance in Europe: a longitudinal observational study | |
CN108172302A (en) | Rational use of medicines information monitoring method and system | |
CN110827951A (en) | Clinical intelligent decision platform | |
CN109273098B (en) | Medicine curative effect prediction method and device based on intelligent decision | |
Leelavanich et al. | Prescription and non-prescription drug classification systems across countries: Lessons learned for Thailand | |
CN107945847A (en) | The commending system and method for a kind of OTC drugs | |
CN109920524B (en) | Multi-prescription pharmacist distribution method | |
JP5868538B1 (en) | Medical information management by medical information management and medical information management system | |
JP6960218B2 (en) | Service support system, service support method and program | |
CN112331260A (en) | Pharmaceutical excipient analysis management method and management system | |
JP7198959B1 (en) | Information processing method, computer program and information processing device | |
Maiti et al. | Social pharmacology: expanding horizons | |
CN103093408A (en) | Patient healthy record, examination and treatment system | |
JP7394286B2 (en) | Inference system, inference method, inference program, and data structure | |
Retallick-Brown et al. | Study protocol for a randomized double blind, treatment control trial comparing the efficacy of a micronutrient formula to a single vitamin supplement in the treatment of premenstrual syndrome | |
Sharmin et al. | An Automated and Online-Based Medicine Reminder and Dispenser | |
Vallès et al. | Acceptance of generic prescribing in general practice: effect of patient education and reference prices | |
Alkhaldi et al. | A five year review of patient focused medicine information queries at a large UK teaching trust: assessing the trends, predicting the future | |
Nantongo et al. | Application of the anatomical chemical system/defined daily doses: Challenges and way forward for resource‐limited countries | |
CN101526976A (en) | Prescription generation searching and old-young dosage converting system and operating method | |
WO2022202359A1 (en) | Information processing device, information processing method, and program | |
Sohn et al. | Patient response to insurer-led intervention for medication adherence-a pilot study based on claims data in Korea | |
Paul | An Overview of Ayurveda Industries in Kerala–An Entrepreneurial Perspective | |
JP2022115607A (en) | Information processing apparatus, information processing method, and program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |