SlideShare a Scribd company logo
Cost Sharing Estimator
Zainab Almugbel
Special thanks to Prof. Harold Boley for his
contribution in this use case
1
Cost sharing estimator
• Cost sharing is the share of costs covered by your
insurance that you pay out of your own pocket.
This term generally includes deductibles,
coinsurance, and copayments, or similar
charges, but it doesn't include premiums,
balance billing amounts for non-network
providers, or the cost of non-covered services.
2
https://www.healthcare.gov/glossary/cost-sharing/
3
4
start
Client has
insurance
?
Compensation
>
treatment cost
cost sharing
inquiry
yes
Payment = treatment cost
cost sharing
result
end
no
Payment = 0
yes
Payment = treatment
cost - compensation
no
Partner
hospital?
yes
no
Data Fact / Decision Rule Architecture
5
insuranceOffer client partnermedicalExpenses
Data Facts
costSharingEstimator
paymentCalculator
Decision Rules
This includes medicalExpenses, insuranceOffer, client and
partner
6
Data facts: medicalExpenses
• This predicate stores the expenses/price of having a service in a
specific hospital :
1. medicalExpenses(saudiGermanHospital, teeth, xray,
300^^Integer).
%...(hospital, site, required treatment, price)
2. medicalExpenses(britishSaudiHospital, teeth, xray, 350^^Integer).
3. medicalExpenses(dallahHospital, teeth, xray, 350^^Integer).
4. medicalExpenses(dallahHospital, teeth, surgery, 2000^^Integer).
5. medicalExpenses(britishSaudiHospital, teeth, surgery,
1350^^Integer).
6. medicalExpenses(binsinaMedicalCenter, teeth, surgery,
1500^^Integer).
7. medicalExpenses(medCareHospital, teeth, surgery,
1350^^Integer).
7
Data facts: insurance offers
• This predicate stores the information about the available
medical insurance offers in a specific insurance
company. The compensation for treating a specific site is
categorized based on the insurance type:
1. insuranceOffer(tawuniya, silver, teeth, 1000^^Integer).
%...(insurance company, insurance type, site, compensation)
2. insuranceOffer(tawuniya, gold, teeth, 1500^^Integer).
3. insuranceOffer(tawuniya, platinum, teeth,
2000^^Integer).
4. insuranceOffer(tawuniya, diamond, teeth,
2500^^Integer).
8
Data facts: client
• This predicate stores the registered clients, their
insurance company, and their insurance type:
1. client(11122, tawuniya, silver).
%...(clientSSN,insurance company, insurance type)
1. client(66700, tawuniya, gold).
9
Data facts: partner
• This predicate stores the partners :
1. partner(tawuniya, saudiGermanHospital).
%...(insurance company, partner hosipital)
1. partner(tawuniya, britishSaudiHospital).
2. partner(tawuniya, dallahHospital).
10
This includes costSharingEstimator and paymentCalculator
11
Decision Rule: costSharingEstimator
• The predicate costSharingEstimator estimates
the cost sharing ?Payment for a client
?ClientSSN who may have a medical insurance
in ?InsCompany and needs a treatment
?RequiredTreatment for a ?Site in a ?Hospital
• ?InsCompany is bound to Tawuniya company in
this usecase but it could be bound to any other
value
12
costSharingEstimator(?ClientSSN, ?InsCompany,
?Hospital, ?Site, ?RequiredTreatment, ?Payment) :-
Decision Rule: costSharingEstimator Cont’d.
costSharingEstimator has three versions:
• Client has medical insurance:
▫ Hospital is a partner with his insurance company(1)
 Compensation covers treatment cost
 Compensation does not cover treatment cost
▫ Hospital is not a partner with his insurance
company (2)
• Client does not have an insurance (3)
13
Decision Rule: costSharingEstimator(1)
costSharingEstimator(?ClientSSN, ?InsCompany, ?Hospital,
?Site, ?RequiredTreatment, ?Payment) :-
client(?ClientSSN, tawuniya, ?InsType), % check if the client has insurance
partner(tawuniya, ?Hospital), % check the partnered hospitals
medicalExpenses(?Hospital, ?Site, ?RequiredTreatment, ?Price),
% check the price (cost of the service)
insuranceOffer(tawuniya, ?InsType, ?Site, ?Compensation),
% check the compensation(money given by the insurance company)
paymentCalculator(?Price, ?Compensation, ?Payment).
% calculate the cost sharing (?Payment)
14
This rule executes when the hospital that provides services to
clients is partner of its insurance company
% costSharingEstimator(in, in, out, in, in, out)
Decision Rule: paymentCalculator
paymentCalculator (?Price, ?Compensation, ?Payment).
Since compensation is based on the insurance type. The
compensation may not cover the total treatment price. As a result,
there are two versions of this rule:
1. If compensation >= price then payment=0
paymentCalculator (?Price, ?Compensation, ?Payment) :-
greaterThanOrEqual(?Compensation, ?Price), subtract(?Payment,
?Price, ?Price).
2. If compensation < price then payment= price - compensation
paymentCalculator (?Price, ?Compensation, ?Payment) :-
lessThan(?Compensation, ?Price),
subtract(?Payment, ?Price, ?Compensation).
15
Decision Rule: costSharingEstimator(2)
costSharingEstimator(?ClientSSN, ?InsCompany, ?Hospital,
?Site, ?RequiredTreatment, ?Payment) :-
client(?ClientSSN, tawuniya, ?InsType),
naf(partner(tawuniya, ?Hospital)),
% return true if the hospital is in not a partner with the insurance company
medicalExpenses (?Hospital, ?Site, ?RequiredTreatment, ?Payment).
• This rule executes when the hospital that provides services to clients is
not partner (naf) of its insurance company. The client has to pay the
full cost of the service
16
Decision Rule: costSharingEstimator(3)
costSharingEstimator(?ClientSSN, ?InsCompany, ?Hospital, ?Site,
?RequiredTreatment, ?Payment) :-
naf(client(?ClientSSN, ?InsCompany, ?InsType)),
% return true if the client in not registered in the insurance company
medicalExpenses (?Hospital, ?Site, ?RequiredTreatment, ?Payment).
• This rule executes when the client is not registered (naf) in any
insurance company. The client has to pay the full cost of the service
17
1. costSharingEstimator is the main query
2. Both knowledgebase and query could be run using
OO JDREW on
http://www.jdrew.org/oojdrew/download.html
18
Query Sample 1
This query is for (Exist client); it gives 2 results:
19
• costSharingEstimator(11122, tawuniya, ?Hospital, teeth, surgery,
?Payment).
Only partner hospitals that provide the required treatment are shown in
the results
Query Sample 2
This query is for (exist client) with (non partner hospital); it gives one
result:
20
• costSharingEstimator(11122, tawuniya, medCareHospital, teeth,
surgery, ?Payment).
•Only the selected hospital is
shown in the result
•The client has to pay the full
cost of the service
Query Sample 3
This query is for (non exist client); it gives 4 results:
21
• costSharingEstimator(11622, tawuniya, ?Hospital, teeth, surgery,
?Payment).
•All available hospitals that
provide the required
treatment are shown in the
results
•The client has to pay the full
price of the service
Steps of Creating CostSharingEstimator
22
First
Second
Third
• Data and rules were
written in POSL
• OO JDREW[1] is used
to transform POSL
into RuleML
• Saxon[2] gets inputs:
the .ruleml of second
step and .xslt [3] to
output Grailog (.svg)
Note
• <Naf> [4] is not yet identified by Grailog.
Therefore, whenever it’s needed in a predicate,
the predicate is preceded by “not”
• For example:
23
POSL
naf(partner(tawuniya,
?Hospital))
RuleML (not)RuleML (naf)
Example: paymentCalculator rule
24
Transforming POSL to RuleML (OO JDREW)
POSL RuleML
paymentCalculator
(?Price,?Compensation,
?Payment) :-
lessThan(?Compensation,
?Price),
subtract(?Payment, ?Price,
?Compensation).
25
Visualizing RuleML as Grailog(svg)
26
Example: paymentCalculator rule
27
Transforming POSL to RuleML (manually)
POSL RuleML
paymentCalculator
(?Price,?Compensation,
?Payment) :-
lessThan(?Compensation,
?Price),
Equal(?Payment,subtract(?Price,
?Compensation)).
28
Visualizing RuleML as Grailog(svg)
29
Saxon
• Saxon [2] is used to transform the RuleML
version of this usecase into Grailog. It takes the
.ruleml and the .xslt files as inputs to produce
the .svg as output of the transformation process
• Saxon does not have an interface; it uses DOS
command for this purpose
30
Grailog
• More information about Grailog is available
on[5]
• [3] is the .xslt file that is used to transform
RuleML in to Grailog visualization
31
Future work
• Data in this use case can be extended to:
▫ contain comparable information about different
medical insurance companies in a specific region
to help the user to select the most suitable
insurance for himself
▫ include additional insurance types(ex, car
insurance)
• Grailog can be extended to visualize “naf”
32
References
[1]http://www.jdrew.org/oojdrew/demo.html
[2]http://www.saxonica.com/documentation/#!ab
out/gettingstarted/gettingstartedjava
[3]http://www2.unb.ca/~lbidlak1/GrailogKSViz2_
0StandAlone.xslt
[4]http://wiki.ruleml.org/index.php/Glossary_of_
Deliberation_RuleML_1.02#.3CNaf.3E
[5]http://wiki.ruleml.org/index.php/Grailog
33

More Related Content

Similar to Grailog Use Case

Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSDNegotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
Jeffrey Restuccio
 
Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSDNegotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
Jeffrey Restuccio
 
Part II Record Financial Operations CHAPTER 5 EXPE
Part II Record Financial Operations CHAPTER 5 EXPEPart II Record Financial Operations CHAPTER 5 EXPE
Part II Record Financial Operations CHAPTER 5 EXPE
twilacrt6k5
 
ED Financial Triage
ED Financial TriageED Financial Triage
ED Financial Triage
Corey Shank
 
Research several types of reimbursement methods for healthcare for.docx
Research several types of reimbursement methods for healthcare for.docxResearch several types of reimbursement methods for healthcare for.docx
Research several types of reimbursement methods for healthcare for.docx
ronak56
 
Medicare's Reimbursement System for Devices
Medicare's Reimbursement System for DevicesMedicare's Reimbursement System for Devices
Medicare's Reimbursement System for Devices
Yiscah Bracha
 
HE_JF 07_Feature 1_jad ghostwrite
HE_JF 07_Feature 1_jad ghostwriteHE_JF 07_Feature 1_jad ghostwrite
HE_JF 07_Feature 1_jad ghostwrite
Joyce Dunne
 
New Revenue Recognition Standards for Hospitals
New Revenue Recognition Standards for HospitalsNew Revenue Recognition Standards for Hospitals
New Revenue Recognition Standards for Hospitals
Chris Pritchard
 
Common challenges faced by Physicians and Practitioners with Medical Billing
Common challenges faced by Physicians and Practitioners with Medical BillingCommon challenges faced by Physicians and Practitioners with Medical Billing
Common challenges faced by Physicians and Practitioners with Medical Billing
jennyvergeese
 
01. medicare's device reimbursement system
01. medicare's device reimbursement system01. medicare's device reimbursement system
01. medicare's device reimbursement system
Yiscah Bracha, MS, PhD
 
Accounts Receivables Maturity in Billing Organizations
Accounts Receivables Maturity in Billing OrganizationsAccounts Receivables Maturity in Billing Organizations
Accounts Receivables Maturity in Billing Organizations
MelisaCooper3
 
Trends in Hospital-Based Agreements
Trends in Hospital-Based AgreementsTrends in Hospital-Based Agreements
Trends in Hospital-Based Agreements
MD Ranger, Inc.
 
Are You Ready to Send Consolidated Statements?
Are You Ready to Send Consolidated Statements?Are You Ready to Send Consolidated Statements?
Are You Ready to Send Consolidated Statements?
Jessica Parker
 
Introduction To Med Mal Insurance
Introduction To Med Mal InsuranceIntroduction To Med Mal Insurance
Introduction To Med Mal Insurance
RyanWilson2010
 
Pricing Physician Services
Pricing Physician ServicesPricing Physician Services
Pricing Physician Services
David Manning
 
The benefit of outsourcing medical billing
The benefit of outsourcing medical billingThe benefit of outsourcing medical billing
The benefit of outsourcing medical billing
AIEMedicalManagement
 
Navigating Hospital-Based Contracts
Navigating Hospital-Based ContractsNavigating Hospital-Based Contracts
Navigating Hospital-Based Contracts
MD Ranger, Inc.
 
Webinar: “While You Were Sleeping…Proposed Rule Positioned to Significantly I...
Webinar: “While You Were Sleeping…Proposed Rule Positioned to Significantly I...Webinar: “While You Were Sleeping…Proposed Rule Positioned to Significantly I...
Webinar: “While You Were Sleeping…Proposed Rule Positioned to Significantly I...
PYA, P.C.
 
Mission hospital package pricing analysis
Mission hospital package pricing analysisMission hospital package pricing analysis
Mission hospital package pricing analysis
Shresth Sethi
 
Implementing Bundled Payments: A Deeper Dive
Implementing Bundled Payments: A Deeper DiveImplementing Bundled Payments: A Deeper Dive
Implementing Bundled Payments: A Deeper Dive
Wellbe
 

Similar to Grailog Use Case (20)

Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSDNegotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
 
Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSDNegotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
Negotiating Carve-Outs for Hand-and-Wrist Surgical Procedures with Zero SOSD
 
Part II Record Financial Operations CHAPTER 5 EXPE
Part II Record Financial Operations CHAPTER 5 EXPEPart II Record Financial Operations CHAPTER 5 EXPE
Part II Record Financial Operations CHAPTER 5 EXPE
 
ED Financial Triage
ED Financial TriageED Financial Triage
ED Financial Triage
 
Research several types of reimbursement methods for healthcare for.docx
Research several types of reimbursement methods for healthcare for.docxResearch several types of reimbursement methods for healthcare for.docx
Research several types of reimbursement methods for healthcare for.docx
 
Medicare's Reimbursement System for Devices
Medicare's Reimbursement System for DevicesMedicare's Reimbursement System for Devices
Medicare's Reimbursement System for Devices
 
HE_JF 07_Feature 1_jad ghostwrite
HE_JF 07_Feature 1_jad ghostwriteHE_JF 07_Feature 1_jad ghostwrite
HE_JF 07_Feature 1_jad ghostwrite
 
New Revenue Recognition Standards for Hospitals
New Revenue Recognition Standards for HospitalsNew Revenue Recognition Standards for Hospitals
New Revenue Recognition Standards for Hospitals
 
Common challenges faced by Physicians and Practitioners with Medical Billing
Common challenges faced by Physicians and Practitioners with Medical BillingCommon challenges faced by Physicians and Practitioners with Medical Billing
Common challenges faced by Physicians and Practitioners with Medical Billing
 
01. medicare's device reimbursement system
01. medicare's device reimbursement system01. medicare's device reimbursement system
01. medicare's device reimbursement system
 
Accounts Receivables Maturity in Billing Organizations
Accounts Receivables Maturity in Billing OrganizationsAccounts Receivables Maturity in Billing Organizations
Accounts Receivables Maturity in Billing Organizations
 
Trends in Hospital-Based Agreements
Trends in Hospital-Based AgreementsTrends in Hospital-Based Agreements
Trends in Hospital-Based Agreements
 
Are You Ready to Send Consolidated Statements?
Are You Ready to Send Consolidated Statements?Are You Ready to Send Consolidated Statements?
Are You Ready to Send Consolidated Statements?
 
Introduction To Med Mal Insurance
Introduction To Med Mal InsuranceIntroduction To Med Mal Insurance
Introduction To Med Mal Insurance
 
Pricing Physician Services
Pricing Physician ServicesPricing Physician Services
Pricing Physician Services
 
The benefit of outsourcing medical billing
The benefit of outsourcing medical billingThe benefit of outsourcing medical billing
The benefit of outsourcing medical billing
 
Navigating Hospital-Based Contracts
Navigating Hospital-Based ContractsNavigating Hospital-Based Contracts
Navigating Hospital-Based Contracts
 
Webinar: “While You Were Sleeping…Proposed Rule Positioned to Significantly I...
Webinar: “While You Were Sleeping…Proposed Rule Positioned to Significantly I...Webinar: “While You Were Sleeping…Proposed Rule Positioned to Significantly I...
Webinar: “While You Were Sleeping…Proposed Rule Positioned to Significantly I...
 
Mission hospital package pricing analysis
Mission hospital package pricing analysisMission hospital package pricing analysis
Mission hospital package pricing analysis
 
Implementing Bundled Payments: A Deeper Dive
Implementing Bundled Payments: A Deeper DiveImplementing Bundled Payments: A Deeper Dive
Implementing Bundled Payments: A Deeper Dive
 

More from Zainab Almugbel

مسألة الألوهية في الإسلام والمسيحية
مسألة الألوهية في الإسلام والمسيحيةمسألة الألوهية في الإسلام والمسيحية
مسألة الألوهية في الإسلام والمسيحية
Zainab Almugbel
 
Ontology based approach for annotating a corpus of computer science abstracts
Ontology based approach for annotating a corpus of computer science abstractsOntology based approach for annotating a corpus of computer science abstracts
Ontology based approach for annotating a corpus of computer science abstracts
Zainab Almugbel
 
Lesson Sample Fourth Elementary Grade English Course
Lesson Sample Fourth Elementary Grade English Course Lesson Sample Fourth Elementary Grade English Course
Lesson Sample Fourth Elementary Grade English Course
Zainab Almugbel
 
Representing, Querying, and Visualizing Health-Insurance Knowledge in a Cost-...
Representing, Querying, and Visualizing Health-Insurance Knowledge in a Cost-...Representing, Querying, and Visualizing Health-Insurance Knowledge in a Cost-...
Representing, Querying, and Visualizing Health-Insurance Knowledge in a Cost-...
Zainab Almugbel
 
Preventive Maintenance
Preventive MaintenancePreventive Maintenance
Preventive Maintenance
Zainab Almugbel
 
how hardware and software works together
how hardware and software works togetherhow hardware and software works together
how hardware and software works together
Zainab Almugbel
 
computer maintenance
computer maintenance computer maintenance
computer maintenance
Zainab Almugbel
 
Introduction to Network
Introduction to NetworkIntroduction to Network
Introduction to Network
Zainab Almugbel
 
Introduction to transaction processing concepts and theory
Introduction to transaction processing concepts and theoryIntroduction to transaction processing concepts and theory
Introduction to transaction processing concepts and theory
Zainab Almugbel
 
Database concepts and Archeticture Ch2 with in class Activities
Database concepts and Archeticture Ch2 with in class ActivitiesDatabase concepts and Archeticture Ch2 with in class Activities
Database concepts and Archeticture Ch2 with in class Activities
Zainab Almugbel
 

More from Zainab Almugbel (10)

مسألة الألوهية في الإسلام والمسيحية
مسألة الألوهية في الإسلام والمسيحيةمسألة الألوهية في الإسلام والمسيحية
مسألة الألوهية في الإسلام والمسيحية
 
Ontology based approach for annotating a corpus of computer science abstracts
Ontology based approach for annotating a corpus of computer science abstractsOntology based approach for annotating a corpus of computer science abstracts
Ontology based approach for annotating a corpus of computer science abstracts
 
Lesson Sample Fourth Elementary Grade English Course
Lesson Sample Fourth Elementary Grade English Course Lesson Sample Fourth Elementary Grade English Course
Lesson Sample Fourth Elementary Grade English Course
 
Representing, Querying, and Visualizing Health-Insurance Knowledge in a Cost-...
Representing, Querying, and Visualizing Health-Insurance Knowledge in a Cost-...Representing, Querying, and Visualizing Health-Insurance Knowledge in a Cost-...
Representing, Querying, and Visualizing Health-Insurance Knowledge in a Cost-...
 
Preventive Maintenance
Preventive MaintenancePreventive Maintenance
Preventive Maintenance
 
how hardware and software works together
how hardware and software works togetherhow hardware and software works together
how hardware and software works together
 
computer maintenance
computer maintenance computer maintenance
computer maintenance
 
Introduction to Network
Introduction to NetworkIntroduction to Network
Introduction to Network
 
Introduction to transaction processing concepts and theory
Introduction to transaction processing concepts and theoryIntroduction to transaction processing concepts and theory
Introduction to transaction processing concepts and theory
 
Database concepts and Archeticture Ch2 with in class Activities
Database concepts and Archeticture Ch2 with in class ActivitiesDatabase concepts and Archeticture Ch2 with in class Activities
Database concepts and Archeticture Ch2 with in class Activities
 

Recently uploaded

Digital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental DesignDigital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental Design
amberjdewit93
 
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdfবাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
eBook.com.bd (প্রয়োজনীয় বাংলা বই)
 
Film vocab for eal 3 students: Australia the movie
Film vocab for eal 3 students: Australia the movieFilm vocab for eal 3 students: Australia the movie
Film vocab for eal 3 students: Australia the movie
Nicholas Montgomery
 
Life upper-Intermediate B2 Workbook for student
Life upper-Intermediate B2 Workbook for studentLife upper-Intermediate B2 Workbook for student
Life upper-Intermediate B2 Workbook for student
NgcHiNguyn25
 
clinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdfclinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdf
Priyankaranawat4
 
How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17
Celine George
 
A Independência da América Espanhola LAPBOOK.pdf
A Independência da América Espanhola LAPBOOK.pdfA Independência da América Espanhola LAPBOOK.pdf
A Independência da América Espanhola LAPBOOK.pdf
Jean Carlos Nunes Paixão
 
Main Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docxMain Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docx
adhitya5119
 
Pride Month Slides 2024 David Douglas School District
Pride Month Slides 2024 David Douglas School DistrictPride Month Slides 2024 David Douglas School District
Pride Month Slides 2024 David Douglas School District
David Douglas School District
 
Pengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptxPengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptx
Fajar Baskoro
 
How to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRMHow to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRM
Celine George
 
DRUGS AND ITS classification slide share
DRUGS AND ITS classification slide shareDRUGS AND ITS classification slide share
DRUGS AND ITS classification slide share
taiba qazi
 
How to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP ModuleHow to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP Module
Celine George
 
PIMS Job Advertisement 2024.pdf Islamabad
PIMS Job Advertisement 2024.pdf IslamabadPIMS Job Advertisement 2024.pdf Islamabad
PIMS Job Advertisement 2024.pdf Islamabad
AyyanKhan40
 
Digital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments UnitDigital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments Unit
chanes7
 
The Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collectionThe Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collection
Israel Genealogy Research Association
 
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
RitikBhardwaj56
 
The History of Stoke Newington Street Names
The History of Stoke Newington Street NamesThe History of Stoke Newington Street Names
The History of Stoke Newington Street Names
History of Stoke Newington
 
Hindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdfHindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdf
Dr. Mulla Adam Ali
 
Liberal Approach to the Study of Indian Politics.pdf
Liberal Approach to the Study of Indian Politics.pdfLiberal Approach to the Study of Indian Politics.pdf
Liberal Approach to the Study of Indian Politics.pdf
WaniBasim
 

Recently uploaded (20)

Digital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental DesignDigital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental Design
 
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdfবাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
 
Film vocab for eal 3 students: Australia the movie
Film vocab for eal 3 students: Australia the movieFilm vocab for eal 3 students: Australia the movie
Film vocab for eal 3 students: Australia the movie
 
Life upper-Intermediate B2 Workbook for student
Life upper-Intermediate B2 Workbook for studentLife upper-Intermediate B2 Workbook for student
Life upper-Intermediate B2 Workbook for student
 
clinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdfclinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdf
 
How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17
 
A Independência da América Espanhola LAPBOOK.pdf
A Independência da América Espanhola LAPBOOK.pdfA Independência da América Espanhola LAPBOOK.pdf
A Independência da América Espanhola LAPBOOK.pdf
 
Main Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docxMain Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docx
 
Pride Month Slides 2024 David Douglas School District
Pride Month Slides 2024 David Douglas School DistrictPride Month Slides 2024 David Douglas School District
Pride Month Slides 2024 David Douglas School District
 
Pengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptxPengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptx
 
How to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRMHow to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRM
 
DRUGS AND ITS classification slide share
DRUGS AND ITS classification slide shareDRUGS AND ITS classification slide share
DRUGS AND ITS classification slide share
 
How to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP ModuleHow to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP Module
 
PIMS Job Advertisement 2024.pdf Islamabad
PIMS Job Advertisement 2024.pdf IslamabadPIMS Job Advertisement 2024.pdf Islamabad
PIMS Job Advertisement 2024.pdf Islamabad
 
Digital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments UnitDigital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments Unit
 
The Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collectionThe Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collection
 
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
 
The History of Stoke Newington Street Names
The History of Stoke Newington Street NamesThe History of Stoke Newington Street Names
The History of Stoke Newington Street Names
 
Hindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdfHindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdf
 
Liberal Approach to the Study of Indian Politics.pdf
Liberal Approach to the Study of Indian Politics.pdfLiberal Approach to the Study of Indian Politics.pdf
Liberal Approach to the Study of Indian Politics.pdf
 

Grailog Use Case

  • 1. Cost Sharing Estimator Zainab Almugbel Special thanks to Prof. Harold Boley for his contribution in this use case 1
  • 2. Cost sharing estimator • Cost sharing is the share of costs covered by your insurance that you pay out of your own pocket. This term generally includes deductibles, coinsurance, and copayments, or similar charges, but it doesn't include premiums, balance billing amounts for non-network providers, or the cost of non-covered services. 2 https://www.healthcare.gov/glossary/cost-sharing/
  • 3. 3
  • 4. 4 start Client has insurance ? Compensation > treatment cost cost sharing inquiry yes Payment = treatment cost cost sharing result end no Payment = 0 yes Payment = treatment cost - compensation no Partner hospital? yes no
  • 5. Data Fact / Decision Rule Architecture 5 insuranceOffer client partnermedicalExpenses Data Facts costSharingEstimator paymentCalculator Decision Rules
  • 6. This includes medicalExpenses, insuranceOffer, client and partner 6
  • 7. Data facts: medicalExpenses • This predicate stores the expenses/price of having a service in a specific hospital : 1. medicalExpenses(saudiGermanHospital, teeth, xray, 300^^Integer). %...(hospital, site, required treatment, price) 2. medicalExpenses(britishSaudiHospital, teeth, xray, 350^^Integer). 3. medicalExpenses(dallahHospital, teeth, xray, 350^^Integer). 4. medicalExpenses(dallahHospital, teeth, surgery, 2000^^Integer). 5. medicalExpenses(britishSaudiHospital, teeth, surgery, 1350^^Integer). 6. medicalExpenses(binsinaMedicalCenter, teeth, surgery, 1500^^Integer). 7. medicalExpenses(medCareHospital, teeth, surgery, 1350^^Integer). 7
  • 8. Data facts: insurance offers • This predicate stores the information about the available medical insurance offers in a specific insurance company. The compensation for treating a specific site is categorized based on the insurance type: 1. insuranceOffer(tawuniya, silver, teeth, 1000^^Integer). %...(insurance company, insurance type, site, compensation) 2. insuranceOffer(tawuniya, gold, teeth, 1500^^Integer). 3. insuranceOffer(tawuniya, platinum, teeth, 2000^^Integer). 4. insuranceOffer(tawuniya, diamond, teeth, 2500^^Integer). 8
  • 9. Data facts: client • This predicate stores the registered clients, their insurance company, and their insurance type: 1. client(11122, tawuniya, silver). %...(clientSSN,insurance company, insurance type) 1. client(66700, tawuniya, gold). 9
  • 10. Data facts: partner • This predicate stores the partners : 1. partner(tawuniya, saudiGermanHospital). %...(insurance company, partner hosipital) 1. partner(tawuniya, britishSaudiHospital). 2. partner(tawuniya, dallahHospital). 10
  • 11. This includes costSharingEstimator and paymentCalculator 11
  • 12. Decision Rule: costSharingEstimator • The predicate costSharingEstimator estimates the cost sharing ?Payment for a client ?ClientSSN who may have a medical insurance in ?InsCompany and needs a treatment ?RequiredTreatment for a ?Site in a ?Hospital • ?InsCompany is bound to Tawuniya company in this usecase but it could be bound to any other value 12 costSharingEstimator(?ClientSSN, ?InsCompany, ?Hospital, ?Site, ?RequiredTreatment, ?Payment) :-
  • 13. Decision Rule: costSharingEstimator Cont’d. costSharingEstimator has three versions: • Client has medical insurance: ▫ Hospital is a partner with his insurance company(1)  Compensation covers treatment cost  Compensation does not cover treatment cost ▫ Hospital is not a partner with his insurance company (2) • Client does not have an insurance (3) 13
  • 14. Decision Rule: costSharingEstimator(1) costSharingEstimator(?ClientSSN, ?InsCompany, ?Hospital, ?Site, ?RequiredTreatment, ?Payment) :- client(?ClientSSN, tawuniya, ?InsType), % check if the client has insurance partner(tawuniya, ?Hospital), % check the partnered hospitals medicalExpenses(?Hospital, ?Site, ?RequiredTreatment, ?Price), % check the price (cost of the service) insuranceOffer(tawuniya, ?InsType, ?Site, ?Compensation), % check the compensation(money given by the insurance company) paymentCalculator(?Price, ?Compensation, ?Payment). % calculate the cost sharing (?Payment) 14 This rule executes when the hospital that provides services to clients is partner of its insurance company % costSharingEstimator(in, in, out, in, in, out)
  • 15. Decision Rule: paymentCalculator paymentCalculator (?Price, ?Compensation, ?Payment). Since compensation is based on the insurance type. The compensation may not cover the total treatment price. As a result, there are two versions of this rule: 1. If compensation >= price then payment=0 paymentCalculator (?Price, ?Compensation, ?Payment) :- greaterThanOrEqual(?Compensation, ?Price), subtract(?Payment, ?Price, ?Price). 2. If compensation < price then payment= price - compensation paymentCalculator (?Price, ?Compensation, ?Payment) :- lessThan(?Compensation, ?Price), subtract(?Payment, ?Price, ?Compensation). 15
  • 16. Decision Rule: costSharingEstimator(2) costSharingEstimator(?ClientSSN, ?InsCompany, ?Hospital, ?Site, ?RequiredTreatment, ?Payment) :- client(?ClientSSN, tawuniya, ?InsType), naf(partner(tawuniya, ?Hospital)), % return true if the hospital is in not a partner with the insurance company medicalExpenses (?Hospital, ?Site, ?RequiredTreatment, ?Payment). • This rule executes when the hospital that provides services to clients is not partner (naf) of its insurance company. The client has to pay the full cost of the service 16
  • 17. Decision Rule: costSharingEstimator(3) costSharingEstimator(?ClientSSN, ?InsCompany, ?Hospital, ?Site, ?RequiredTreatment, ?Payment) :- naf(client(?ClientSSN, ?InsCompany, ?InsType)), % return true if the client in not registered in the insurance company medicalExpenses (?Hospital, ?Site, ?RequiredTreatment, ?Payment). • This rule executes when the client is not registered (naf) in any insurance company. The client has to pay the full cost of the service 17
  • 18. 1. costSharingEstimator is the main query 2. Both knowledgebase and query could be run using OO JDREW on http://www.jdrew.org/oojdrew/download.html 18
  • 19. Query Sample 1 This query is for (Exist client); it gives 2 results: 19 • costSharingEstimator(11122, tawuniya, ?Hospital, teeth, surgery, ?Payment). Only partner hospitals that provide the required treatment are shown in the results
  • 20. Query Sample 2 This query is for (exist client) with (non partner hospital); it gives one result: 20 • costSharingEstimator(11122, tawuniya, medCareHospital, teeth, surgery, ?Payment). •Only the selected hospital is shown in the result •The client has to pay the full cost of the service
  • 21. Query Sample 3 This query is for (non exist client); it gives 4 results: 21 • costSharingEstimator(11622, tawuniya, ?Hospital, teeth, surgery, ?Payment). •All available hospitals that provide the required treatment are shown in the results •The client has to pay the full price of the service
  • 22. Steps of Creating CostSharingEstimator 22 First Second Third • Data and rules were written in POSL • OO JDREW[1] is used to transform POSL into RuleML • Saxon[2] gets inputs: the .ruleml of second step and .xslt [3] to output Grailog (.svg)
  • 23. Note • <Naf> [4] is not yet identified by Grailog. Therefore, whenever it’s needed in a predicate, the predicate is preceded by “not” • For example: 23 POSL naf(partner(tawuniya, ?Hospital)) RuleML (not)RuleML (naf)
  • 25. Transforming POSL to RuleML (OO JDREW) POSL RuleML paymentCalculator (?Price,?Compensation, ?Payment) :- lessThan(?Compensation, ?Price), subtract(?Payment, ?Price, ?Compensation). 25
  • 26. Visualizing RuleML as Grailog(svg) 26
  • 28. Transforming POSL to RuleML (manually) POSL RuleML paymentCalculator (?Price,?Compensation, ?Payment) :- lessThan(?Compensation, ?Price), Equal(?Payment,subtract(?Price, ?Compensation)). 28
  • 29. Visualizing RuleML as Grailog(svg) 29
  • 30. Saxon • Saxon [2] is used to transform the RuleML version of this usecase into Grailog. It takes the .ruleml and the .xslt files as inputs to produce the .svg as output of the transformation process • Saxon does not have an interface; it uses DOS command for this purpose 30
  • 31. Grailog • More information about Grailog is available on[5] • [3] is the .xslt file that is used to transform RuleML in to Grailog visualization 31
  • 32. Future work • Data in this use case can be extended to: ▫ contain comparable information about different medical insurance companies in a specific region to help the user to select the most suitable insurance for himself ▫ include additional insurance types(ex, car insurance) • Grailog can be extended to visualize “naf” 32