From d55a4b8fd21235178899fda70361018a6c54d214 Mon Sep 17 00:00:00 2001 From: Alex Galarce Date: Thu, 6 Mar 2025 14:55:59 +0000 Subject: [PATCH] Merged in reimb-primary-accuracy-analysis (pull request #433) Reimb primary accuracy analysis * Add accuracy calculation to fuzzy matching evaluation * reimbursement primary accuracy test * add match_threshold control * clarify metrics * Merged main into reimb-primary-accuracy-analysis * Merge branch 'reimb-primary-accuracy-analysis' of https://bitbucket.org/aarete/doczy.ai into reimb-primary-accuracy-analysis Approved-by: Katon Minhas --- .../src/testbed/one_to_n_comparison.py | 2 + .../src/testbed/test_one_to_n.ipynb | 3817 ++--------------- 2 files changed, 361 insertions(+), 3458 deletions(-) diff --git a/fieldExtraction/src/testbed/one_to_n_comparison.py b/fieldExtraction/src/testbed/one_to_n_comparison.py index 81a7941..4358838 100644 --- a/fieldExtraction/src/testbed/one_to_n_comparison.py +++ b/fieldExtraction/src/testbed/one_to_n_comparison.py @@ -101,11 +101,13 @@ def evaluate_one_to_n_fields_fuzzy_matching_field_by_field( f1_score = ( 2 * precision * recall / (precision + recall) if (precision + recall) > 0 else 0 ) + accuracy = total_true_positives / (total_true_positives + total_false_positives + total_false_negatives) return { "precision": precision, "recall": recall, "f1_score": f1_score, + "accuracy": accuracy, "true_positives": total_true_positives, "false_positives": total_false_positives, "false_negatives": total_false_negatives, diff --git a/fieldExtraction/src/testbed/test_one_to_n.ipynb b/fieldExtraction/src/testbed/test_one_to_n.ipynb index 24502d2..8bf1019 100644 --- a/fieldExtraction/src/testbed/test_one_to_n.ipynb +++ b/fieldExtraction/src/testbed/test_one_to_n.ipynb @@ -6,7 +6,9 @@ "metadata": {}, "outputs": [], "source": [ - "from one_to_n_comparison import evaluate_one_to_n_fields_fuzzy_matching_field_by_field" + "from one_to_n_comparison import evaluate_one_to_n_fields_fuzzy_matching_field_by_field\n", + "import pandas as pd\n", + "import os" ] }, { @@ -15,17 +17,74 @@ "metadata": {}, "outputs": [], "source": [ - "import pandas as pd" + "MATCH_THRESHOLD = 90\n", + "# This is the labeled data from sharepoint. It can be found at\n", + "# OneDrive - AArete, LLC\\investment_samples\\Test Bed Files\n", + "# You'll need access to the `investment_samples` sharepoint folder\n", + "labels_files = os.listdir(\"Reimbursement Field Files\")\n", + "\n", + "fields = [\"CONTRACT_SERVICE_CD_OR_DESC\", \"CONTRACT_REIMBURSEMENT_METHOD\"] # comparison fields" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, - "outputs": [], + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Reading BSW _ Original Contract _ 1.1.2000 MU.xlsx\n", + "Reading 39-0806250-Divine Saviour Hospital-ICMProviderAgreement_97009.csv\n", + "Reading 65-0825133-Florida Cancer Specialists, P.L.-ICMProviderAgreement_192252_53.xlsx\n", + "Reading Custom_2009-08-10 Adventist - University Community Hopstial LTAC MU.txt-RESULTS.xlsx\n", + "Reading 2001-11-01 California Emergency Physicians PSA_MU.txt-RESULTS.xlsx\n", + "Reading 92-2764433-MAGNOLIA MOBILE HOME CARE LLC-ICMProviderAgreement_322270.xlsx\n", + "Reading Fac1_Bullhead City_Western Arizona Med Center - 860982071 MU.xlsx\n", + "Reading Custom_PSA - Advanced Gastroenterology of Texas PLLC -Executed 47-4543923 MU.txt-RESULTS.xlsx\n", + "Reading 2022 01 20 West Park Primary Care_Master (Master) PHY Executed.pdf.filepart MU.txt-RESULTS.xlsx\n", + "Reading 95-2648499-Mission Pathology Medical Associates-ICMProviderAgreement_254534.xlsx\n", + "Reading 61-1400871-West Kentucky Dermatology PSC-ICMProviderAgreement_104221.csv\n", + "Reading 91-1885077-COASTAL ANESTHESIOLOGY MEDICAL-ICMProviderAgreement_242069.csv\n", + "Reading 84-5179194-Heart and Soul Hospice LLC-ICMProviderAgreement_273737.csv\n", + "Reading 050540697 Deepak Nanda 2017 PHSP MU.txt-RESULTS.xlsx\n", + "Reading 02-0677066-Eyemasters-ICMProviderAgreement_64220_2.txt-RESULTS.xlsx\n", + "Reading 86-0898663-Founder Health, LLC dba Preferred Homecare-ICMProviderAgreement_120661.csv\n", + "Reading Adena Health System National Template Agreement C19460229AA.txt-RESULTS.xlsx\n", + "Reading 2018 09 01 UTMB (Amendment 10 change in reimbursement) MU.txt-RESULTS.xlsx\n", + "Reading 2014-01-01 United Health Centers San Joaquin AMD MU.txt-RESULTS.xlsx\n", + "Reading 5.2000_Rehab Designs of America_VendorAgreement MU.txt-RESULTS.xlsx\n", + "Reading 36-2902782-Circle Family HealthCare Network-ICMProviderAgreement_59631.csv\n", + "Reading 2014-01-01 COMM PPO - PeaceHealth Multi TIN - Facility and Prof MU.txt-RESULTS.xlsx\n", + "Reading 06-1798267-Anthony W. Le, A Professional Corp-ICMProviderAgreement_316844.txt-RESULTS.xlsx\n", + "Reading 33-0057155-Apria Healthcare, Inc.-ICMProviderAgreementAmendment_26762.txt-RESULTS.xlsx\n", + "Reading 20-1668371-Midwest Medical Equipment Solutions, Inc.-ICMProviderAgreementAmendment_166876.txt-RESULTS.xlsx\n", + "Reading 95-3372911; Multiple-Davita Healthcare Partners, Inc.-ICMProviderAgreement_138658.xlsx\n", + "Reading 429670586-Melissa Ann Clark-ICMProviderAgreement_128379_1.csv\n", + "Reading ICMProviderAgreement_ICMProviderAgreement_295973_15.txt-RESULTS.xlsx\n", + "Reading DocziAI_2-12.xlsx\n", + "Reading 00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt-RESULTS.xlsx\n", + "Reading 46-0979580-Harris and Theodore Anesthesia Services, LLC-ICMProviderAgreement_313205.csv\n", + "Extracted 31 dataframes.\n" + ] + } + ], "source": [ - "labels_df = pd.read_excel('input_data/00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285_LABELS.xlsx')\n", - "predictions_df = pd.read_csv('input_data/00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt-RESULTS.csv')" + "\n", + "# make list of dataframes from labels_files\n", + "labels_dfs = []\n", + "for filename in labels_files:\n", + " print(f\"Reading {filename}\")\n", + " if filename == \"DocziAI_2-12.xlsx\":\n", + " labels_dfs.append(pd.read_excel(\"Reimbursement Field Files/\" + filename, sheet_name=\"doczy-ai-test-20240211\", skiprows=3))\n", + " elif filename.endswith(\".xlsx\"):\n", + " labels_dfs.append(pd.read_excel(\"Reimbursement Field Files/\" + filename))\n", + " elif filename.endswith(\".csv\"):\n", + " labels_dfs.append(pd.read_csv(\"Reimbursement Field Files/\" + filename))\n", + " \n", + "\n", + "print(f\"Extracted {len(labels_dfs)} dataframes.\")\n" ] }, { @@ -34,9 +93,13 @@ "metadata": {}, "outputs": [], "source": [ - "# For all float and int columns, standardize to Int64 and handle NaN values\n", - "labels_df = labels_df.astype({col: 'Int64' for col in labels_df.select_dtypes(include=['float', 'int']).columns})\n", - "predictions_df = predictions_df.astype({col: 'Int64' for col in predictions_df.select_dtypes(include=['float', 'int']).columns})\n" + "labels_df = pd.concat(labels_dfs, ignore_index=True)\n", + "# This is any consolidated output from the model; they can be found in S3\n", + "predictions_df = pd.read_csv('inv-test-0305-RESULTS.csv')\n", + "\n", + "# For all float and int columns, standardize to Int64 and handle NaN values (optional)\n", + "# labels_df = labels_df.astype({col: 'Int64' for col in labels_df.select_dtypes(include=['float', 'int']).columns})\n", + "# predictions_df = predictions_df.astype({col: 'Int64' for col in predictions_df.select_dtypes(include=['float', 'int']).columns})\n" ] }, { @@ -45,1604 +108,20 @@ "metadata": {}, "outputs": [ { - "data": { - "application/vnd.microsoft.datawrangler.viewer.v0+json": { - "columns": [ - { - "name": "index", - "rawType": "int64", - "type": "integer" - }, - { - "name": "PROV_GROUP_TIN", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_TIN_OTHER", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_GROUP_NPI", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_NPI_OTHER", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_TERMINATION_DT", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_AUTO_RENEWAL_TERM", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_EFFECTIVE_DT", - "rawType": "datetime64[ns]", - "type": "datetime" - }, - { - "name": "CONTRACT_TITLE", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_AUTO_RENEWAL_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_CLAIM_TYPE_CD", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_AMENDMENT_NUM", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PAYER_NAME", - "rawType": "object", - "type": "string" - }, - { - "name": "PROV_GROUP_NAME_FULL", - "rawType": "object", - "type": "string" - }, - { - "name": "PROV_FULL_NAME", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_FILE_NAME", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_SERVICE_CD_OR_DESC", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_REIMBURSEMENT_METHOD", - "rawType": "object", - "type": "string" - }, - { - "name": "REIMBURSEMENT_PROV_NAME", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_CARVEOUT_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_CARVEOUT_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_LESSER_OF_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_GREATER_OF_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "AARETE_DERIVED_REIMBURSEMENT_METHOD", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_REIMBURSEMENT_FEE_RATE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_REIMBURSEMENT_PERCENT_RATE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "NOT_TO_EXCEED_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_DEFAULT_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_FEE_SCHEDULE_DESC", - "rawType": "object", - "type": "unknown" - }, - { - "name": "AARETE_DERIVED_FEE_SCHEDULE", - "rawType": "object", - "type": "unknown" - }, - { - "name": "AARETE_DERIVED_FEE_SCHEDULE_VERSION", - "rawType": "object", - "type": "unknown" - }, - { - "name": "CONTRACT_BILL_TYPE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CPT4_PROC_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CPT4_PROC_MOD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "REVENUE_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "DIAG_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "FACILITY_GROUPER_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "LINE_NDC_NUM", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CLAIM_ADMIT_TYPE_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CPT4_PROC_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CPT4_PROC_MOD_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "DIAG_CD_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "REVENUE_CD_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "FACILITY_GROUPER_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "GROUPER_TYPE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "AUTH_ADMIT_TYPE_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_REIMBURSEMENT_TIN", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_REIMBURSEMENT_NPI", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_LINE_OF_BUSINESS", - "rawType": "object", - "type": "string" - }, - { - "name": "REIMBURSEMENT_EFFECTIVE_DATE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "REIMBURSEMENT_TERMINATION_DATE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_NETWORK", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_PRODUCT", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_PROGRAM", - "rawType": "object", - "type": "unknown" - }, - { - "name": "AARETE_DERIVED_PROV_TYPE", - "rawType": "object", - "type": "unknown" - }, - { - "name": "EXHIBIT_NAME", - "rawType": "object", - "type": "string" - }, - { - "name": "EXHIBIT_PAGE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "AARETE_DERIVED_LINE_OF_BUSINESS", - "rawType": "object", - "type": "string" - }, - { - "name": "AARETE_DERIVED_NETWORK", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "AARETE_DERIVED_PRODUCT", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "AARETE_DERIVED_PROGRAM", - "rawType": "object", - "type": "unknown" - }, - { - "name": "AARETE_DERIVED_CLAIM_TYPE_CD", - "rawType": "object", - "type": "string" - }, - { - "name": "CLIENT_NAME", - "rawType": "object", - "type": "string" - }, - { - "name": "AARETE_DERIVED_TERMINATION_DATE", - "rawType": "object", - "type": "unknown" - } - ], - "conversionMethod": "pd.DataFrame", - "ref": "9224dba9-a25c-4363-b46e-25fbd8b96e9e", - "rows": [ - [ - "0", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "laboratory Covered Services", - "the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicaid fee schedule.", - "Central MS Diagnostic, LLC", - null, - "N", - "Y", - "N", - "Billed Charges", - null, - "100", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "MEDICAID", - null, - null, - null, - null, - "MississippiCAN", - "Lab", - "Attachment A-1: Medicaid\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nANCILLARY SERVICES\nLABORATORY\nCentral MS Diagnostic, LLC", - "30", - "Medicaid", - null, - null, - "MississippiCAN", - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "1", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "laboratory Covered Services", - "the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicaid fee schedule.", - "Central MS Diagnostic, LLC", - null, - "N", - "Y", - "N", - "Fee Schedule", - null, - "100", - "N", - "N", - "Payor's Medicaid fee schedule", - "MEDICAID", - "current", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "MEDICAID", - null, - null, - null, - null, - "MississippiCAN", - "Lab", - "Attachment A-1: Medicaid\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nANCILLARY SERVICES\nLABORATORY\nCentral MS Diagnostic, LLC", - "30", - "Medicaid", - null, - null, - "MississippiCAN", - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "2", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "Covered Services that are Medicare Covered Services and Medicaid Covered Services", - "The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service", - "Central MS Diagnostic, LLC", - null, - "Y", - "Y", - "N", - "Billed Charges", - null, - "100", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "DUAL", - null, - null, - null, - null, - null, - null, - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - "DUAL", - null, - null, - null, - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "3", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "Covered Services that are Medicare Covered Services and Medicaid Covered Services", - "The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service", - "Central MS Diagnostic, LLC", - null, - "Y", - "Y", - "N", - "Fee Schedule", - null, - "100", - "N", - "N", - "Medicare payment rate plus amount payable by Medicaid as secondary coverage", - "MEDICARE plus secondary coverage based on Medicaid", - "current", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "DUAL", - null, - null, - null, - null, - null, - null, - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - "DUAL", - null, - null, - null, - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "4", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "Covered Services that are Medicare Covered Services and are not Medicaid Covered Services", - "The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable based on the Medicare payment rate in effect on the date of service, not including Cost-Sharing Amounts", - "Central MS Diagnostic, LLC", - null, - "Y", - "Y", - "N", - "Billed Charges", - null, - "100", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "DUAL", - null, - null, - null, - null, - null, - null, - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - "DUAL", - null, - null, - null, - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "5", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "Covered Services that are Medicare Covered Services and are not Medicaid Covered Services", - "The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable based on the Medicare payment rate in effect on the date of service, not including Cost-Sharing Amounts", - "Central MS Diagnostic, LLC", - null, - "Y", - "Y", - "N", - "Fee Schedule", - null, - "100", - "N", - "N", - "Medicare payment rate", - "MEDICARE", - "in effect on the date of service", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "DUAL", - null, - null, - null, - null, - null, - null, - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - "DUAL", - null, - null, - null, - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "6", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "Covered Services that are Medicaid Covered Services and are not Medicare Covered Services", - "The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable by Medicaid, not including any Cost-Sharing Amounts that would have been applied by Medicaid, based on the Medicaid payment rate in effect on the date of service", - "Central MS Diagnostic, LLC", - null, - "Y", - "Y", - "N", - "Billed Charges", - null, - "100", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "DUAL", - null, - null, - null, - null, - null, - null, - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - "DUAL", - null, - null, - null, - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "7", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "Covered Services that are Medicaid Covered Services and are not Medicare Covered Services", - "The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable by Medicaid, not including any Cost-Sharing Amounts that would have been applied by Medicaid, based on the Medicaid payment rate in effect on the date of service", - "Central MS Diagnostic, LLC", - null, - "Y", - "Y", - "N", - "Fee Schedule", - null, - "100", - "N", - "N", - "Medicaid", - "MEDICAID", - "current", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "DUAL", - null, - null, - null, - null, - null, - null, - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - "DUAL", - null, - null, - null, - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "8", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "Covered Services where Payor is the only Payor for Medicare Covered Services", - "The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service", - "Central MS Diagnostic, LLC", - null, - "N", - "Y", - "N", - "Billed Charges", - null, - "100", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "MEDICARE", - null, - null, - null, - null, - null, - null, - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - "Medicare", - null, - null, - null, - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "9", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "Covered Services where Payor is the only Payor for Medicare Covered Services", - "The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service", - "Central MS Diagnostic, LLC", - null, - "N", - "Y", - "N", - "Fee Schedule", - null, - "100", - "Y", - "N", - "Medicare", - "MEDICARE", - "current", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "MEDICARE", - null, - null, - null, - null, - null, - null, - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - "Medicare", - null, - null, - null, - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "10", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "laboratory Covered Services", - "the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicare fee schedule.", - "Central MS Diagnostic, LLC", - null, - "N", - "Y", - "N", - "Billed Charges", - null, - "100", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "COMMERCIAL-EXCHANGE", - null, - null, - null, - null, - null, - "Lab", - "Attachment C: Commercial-Exchange\nEXHIBIT I\nCOMPENSATION SCHEDULE\nANCILLARY SERVICES\nLABORATORY\nCentral MS Diagnostic, LLC", - "47", - "COMMERCIAL-EXCHANGE", - null, - null, - null, - "M", - "Test-Client", - "9999-05-01 00:00:00" - ], - [ - "11", - "640908605", - null, - "1255427464", - null, - "three years from the contract effective date", - "one year", - "2018-05-02 00:00:00", - "PARTICIPATING PROVIDER AGREEMENT", - "Y", - "Ancillary", - null, - "Magnolia Health Plan, Inc.", - "Central MS Diagnostic, LLC", - null, - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "laboratory Covered Services", - "the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicare fee schedule.", - "Central MS Diagnostic, LLC", - null, - "N", - "Y", - "N", - "Fee Schedule", - null, - "100", - "N", - "N", - "Payor's Medicare fee schedule", - "MEDICARE", - "current", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "COMMERCIAL-EXCHANGE", - null, - null, - null, - null, - null, - "Lab", - "Attachment C: Commercial-Exchange\nEXHIBIT I\nCOMPENSATION SCHEDULE\nANCILLARY SERVICES\nLABORATORY\nCentral MS Diagnostic, LLC", - "47", - "COMMERCIAL-EXCHANGE", - null, - null, - null, - "M", - "Test-Client", - "9999-05-01 00:00:00" - ] - ], - "shape": { - "columns": 63, - "rows": 12 - } - }, - "text/html": [ - "
\n", - "\n", - "\n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - "
PROV_GROUP_TINPROV_TIN_OTHERPROV_GROUP_NPIPROV_NPI_OTHERCONTRACT_TERMINATION_DTCONTRACT_AUTO_RENEWAL_TERMCONTRACT_EFFECTIVE_DTCONTRACT_TITLECONTRACT_AUTO_RENEWAL_INDCONTRACT_CLAIM_TYPE_CD...AARETE_DERIVED_PROV_TYPEEXHIBIT_NAMEEXHIBIT_PAGEAARETE_DERIVED_LINE_OF_BUSINESSAARETE_DERIVED_NETWORKAARETE_DERIVED_PRODUCTAARETE_DERIVED_PROGRAMAARETE_DERIVED_CLAIM_TYPE_CDCLIENT_NAMEAARETE_DERIVED_TERMINATION_DATE
0640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...LabAttachment A-1: Medicaid\\nEXHIBIT 1\\nCOMPENSAT...30Medicaid<NA><NA>MississippiCANMTest-Client9999-05-01 00:00:00
1640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...LabAttachment A-1: Medicaid\\nEXHIBIT 1\\nCOMPENSAT...30Medicaid<NA><NA>MississippiCANMTest-Client9999-05-01 00:00:00
2640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...NaNAttachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO...41DUAL<NA><NA>NaNMTest-Client9999-05-01 00:00:00
3640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...NaNAttachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO...41DUAL<NA><NA>NaNMTest-Client9999-05-01 00:00:00
4640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...NaNAttachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO...41DUAL<NA><NA>NaNMTest-Client9999-05-01 00:00:00
5640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...NaNAttachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO...41DUAL<NA><NA>NaNMTest-Client9999-05-01 00:00:00
6640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...NaNAttachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO...41DUAL<NA><NA>NaNMTest-Client9999-05-01 00:00:00
7640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...NaNAttachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO...41DUAL<NA><NA>NaNMTest-Client9999-05-01 00:00:00
8640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...NaNAttachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO...41Medicare<NA><NA>NaNMTest-Client9999-05-01 00:00:00
9640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...NaNAttachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO...41Medicare<NA><NA>NaNMTest-Client9999-05-01 00:00:00
10640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...LabAttachment C: Commercial-Exchange\\nEXHIBIT I\\n...47COMMERCIAL-EXCHANGE<NA><NA>NaNMTest-Client9999-05-01 00:00:00
11640908605<NA>1255427464<NA>three years from the contract effective dateone year2018-05-02PARTICIPATING PROVIDER AGREEMENTYAncillary...LabAttachment C: Commercial-Exchange\\nEXHIBIT I\\n...47COMMERCIAL-EXCHANGE<NA><NA>NaNMTest-Client9999-05-01 00:00:00
\n", - "

12 rows × 63 columns

\n", - "
" - ], - "text/plain": [ - " PROV_GROUP_TIN PROV_TIN_OTHER PROV_GROUP_NPI PROV_NPI_OTHER \\\n", - "0 640908605 1255427464 \n", - "1 640908605 1255427464 \n", - "2 640908605 1255427464 \n", - "3 640908605 1255427464 \n", - "4 640908605 1255427464 \n", - "5 640908605 1255427464 \n", - "6 640908605 1255427464 \n", - "7 640908605 1255427464 \n", - "8 640908605 1255427464 \n", - "9 640908605 1255427464 \n", - "10 640908605 1255427464 \n", - "11 640908605 1255427464 \n", - "\n", - " CONTRACT_TERMINATION_DT CONTRACT_AUTO_RENEWAL_TERM \\\n", - "0 three years from the contract effective date one year \n", - "1 three years from the contract effective date one year \n", - "2 three years from the contract effective date one year \n", - "3 three years from the contract effective date one year \n", - "4 three years from the contract effective date one year \n", - "5 three years from the contract effective date one year \n", - "6 three years from the contract effective date one year \n", - "7 three years from the contract effective date one year \n", - "8 three years from the contract effective date one year \n", - "9 three years from the contract effective date one year \n", - "10 three years from the contract effective date one year \n", - "11 three years from the contract effective date one year \n", - "\n", - " CONTRACT_EFFECTIVE_DT CONTRACT_TITLE \\\n", - "0 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "1 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "2 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "3 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "4 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "5 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "6 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "7 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "8 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "9 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "10 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "11 2018-05-02 PARTICIPATING PROVIDER AGREEMENT \n", - "\n", - " CONTRACT_AUTO_RENEWAL_IND CONTRACT_CLAIM_TYPE_CD ... \\\n", - "0 Y Ancillary ... \n", - "1 Y Ancillary ... \n", - "2 Y Ancillary ... \n", - "3 Y Ancillary ... \n", - "4 Y Ancillary ... \n", - "5 Y Ancillary ... \n", - "6 Y Ancillary ... \n", - "7 Y Ancillary ... \n", - "8 Y Ancillary ... \n", - "9 Y Ancillary ... \n", - "10 Y Ancillary ... \n", - "11 Y Ancillary ... \n", - "\n", - " AARETE_DERIVED_PROV_TYPE \\\n", - "0 Lab \n", - "1 Lab \n", - "2 NaN \n", - "3 NaN \n", - "4 NaN \n", - "5 NaN \n", - "6 NaN \n", - "7 NaN \n", - "8 NaN \n", - "9 NaN \n", - "10 Lab \n", - "11 Lab \n", - "\n", - " EXHIBIT_NAME EXHIBIT_PAGE \\\n", - "0 Attachment A-1: Medicaid\\nEXHIBIT 1\\nCOMPENSAT... 30 \n", - "1 Attachment A-1: Medicaid\\nEXHIBIT 1\\nCOMPENSAT... 30 \n", - "2 Attachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO... 41 \n", - "3 Attachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO... 41 \n", - "4 Attachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO... 41 \n", - "5 Attachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO... 41 \n", - "6 Attachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO... 41 \n", - "7 Attachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO... 41 \n", - "8 Attachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO... 41 \n", - "9 Attachment B: Medicare\\nEXHIBIT 1\\nCOMPENSATIO... 41 \n", - "10 Attachment C: Commercial-Exchange\\nEXHIBIT I\\n... 47 \n", - "11 Attachment C: Commercial-Exchange\\nEXHIBIT I\\n... 47 \n", - "\n", - " AARETE_DERIVED_LINE_OF_BUSINESS AARETE_DERIVED_NETWORK \\\n", - "0 Medicaid \n", - "1 Medicaid \n", - "2 DUAL \n", - "3 DUAL \n", - "4 DUAL \n", - "5 DUAL \n", - "6 DUAL \n", - "7 DUAL \n", - "8 Medicare \n", - "9 Medicare \n", - "10 COMMERCIAL-EXCHANGE \n", - "11 COMMERCIAL-EXCHANGE \n", - "\n", - " AARETE_DERIVED_PRODUCT AARETE_DERIVED_PROGRAM AARETE_DERIVED_CLAIM_TYPE_CD \\\n", - "0 MississippiCAN M \n", - "1 MississippiCAN M \n", - "2 NaN M \n", - "3 NaN M \n", - "4 NaN M \n", - "5 NaN M \n", - "6 NaN M \n", - "7 NaN M \n", - "8 NaN M \n", - "9 NaN M \n", - "10 NaN M \n", - "11 NaN M \n", - "\n", - " CLIENT_NAME AARETE_DERIVED_TERMINATION_DATE \n", - "0 Test-Client 9999-05-01 00:00:00 \n", - "1 Test-Client 9999-05-01 00:00:00 \n", - "2 Test-Client 9999-05-01 00:00:00 \n", - "3 Test-Client 9999-05-01 00:00:00 \n", - "4 Test-Client 9999-05-01 00:00:00 \n", - "5 Test-Client 9999-05-01 00:00:00 \n", - "6 Test-Client 9999-05-01 00:00:00 \n", - "7 Test-Client 9999-05-01 00:00:00 \n", - "8 Test-Client 9999-05-01 00:00:00 \n", - "9 Test-Client 9999-05-01 00:00:00 \n", - "10 Test-Client 9999-05-01 00:00:00 \n", - "11 Test-Client 9999-05-01 00:00:00 \n", - "\n", - "[12 rows x 63 columns]" - ] - }, - "execution_count": 5, - "metadata": {}, - "output_type": "execute_result" + "name": "stdout", + "output_type": "stream", + "text": [ + "There are 70 unique contract file names in the labels dataframe.\n", + "There are 93 unique contract file names in the predictions dataframe.\n" + ] } ], "source": [ - "labels_df\n" + "unique_contracts_labels = labels_df['CONTRACT_FILE_NAME'].nunique()\n", + "print(f\"There are {unique_contracts_labels} unique contract file names in the labels dataframe.\")\n", + "\n", + "unique_contracts_predictions = predictions_df['CONTRACT_FILE_NAME'].nunique()\n", + "print(f\"There are {unique_contracts_predictions} unique contract file names in the predictions dataframe.\")" ] }, { @@ -1651,1624 +130,271 @@ "metadata": {}, "outputs": [ { - "data": { - "application/vnd.microsoft.datawrangler.viewer.v0+json": { - "columns": [ - { - "name": "index", - "rawType": "int64", - "type": "integer" - }, - { - "name": "CONTRACT_FILE_NAME", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_TITLE", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_AMENDMENT_NUM", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CLIENT_NAME", - "rawType": "object", - "type": "string" - }, - { - "name": "PAYER_NAME", - "rawType": "object", - "type": "string" - }, - { - "name": "PROV_GROUP_TIN", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_GROUP_NPI", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_GROUP_NAME_FULL", - "rawType": "object", - "type": "string" - }, - { - "name": "PROV_TIN_OTHER", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_NPI_OTHER", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_REIMBURSEMENT_TIN", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_REIMBURSEMENT_NPI", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "PROV_FULL_NAME", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_EFFECTIVE_DT", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_TERMINATION_DT", - "rawType": "object", - "type": "string" - }, - { - "name": "AARETE_DERIVED_TERMINATION_DATE", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_AUTO_RENEWAL_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_AUTO_RENEWAL_TERM", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_CLAIM_TYPE_CD", - "rawType": "object", - "type": "string" - }, - { - "name": "AARETE_DERIVED_CLAIM_TYPE_CD", - "rawType": "object", - "type": "string" - }, - { - "name": "EXHIBIT_NAME", - "rawType": "object", - "type": "string" - }, - { - "name": "EXHIBIT_PAGE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_PRODUCT", - "rawType": "object", - "type": "unknown" - }, - { - "name": "REIMBURSEMENT_PROV_NAME", - "rawType": "object", - "type": "string" - }, - { - "name": "AARETE_DERIVED_PRODUCT", - "rawType": "object", - "type": "unknown" - }, - { - "name": "CONTRACT_LINE_OF_BUSINESS", - "rawType": "object", - "type": "string" - }, - { - "name": "AARETE_DERIVED_LINE_OF_BUSINESS", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_PROGRAM", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "AARETE_DERIVED_PROGRAM", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_NETWORK", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "AARETE_DERIVED_NETWORK", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "AARETE_DERIVED_PROV_TYPE", - "rawType": "object", - "type": "unknown" - }, - { - "name": "REIMBURSEMENT_PROV_NAME.1", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_PROV_SPECIALTY", - "rawType": "object", - "type": "unknown" - }, - { - "name": "AARETE_DERIVED_PROV_SPECIALTY", - "rawType": "object", - "type": "unknown" - }, - { - "name": "CONTRACT_SERVICE_CD_OR_DESC", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_REIMBURSEMENT_METHOD", - "rawType": "object", - "type": "string" - }, - { - "name": "AARETE_DERIVED_REIMBURSEMENT_METHOD", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_REIMBURSEMENT_FEE_RATE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_REIMBURSEMENT_PERCENT_RATE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_FEE_SCHEDULE_DESC", - "rawType": "object", - "type": "unknown" - }, - { - "name": "AARETE_DERIVED_FEE_SCHEDULE", - "rawType": "object", - "type": "unknown" - }, - { - "name": "CONTRACT_FEE_SCHEDULE_VERSION", - "rawType": "object", - "type": "unknown" - }, - { - "name": "AARETE_DERIVED_FEE_SCHEDULE_VERSION", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CONTRACT_LESSER_OF_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_GREATER_OF_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_DEFAULT_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "CPT4_PROC_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CPT4_PROC_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CPT4_PROC_MOD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CPT4_PROC_MOD_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "REVENUE_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "REVENUE_CD_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "DIAG_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "DIAG_CD_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "GROUPER_TYPE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "FACILITY_GROUPER_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "FACILITY_GROUPER_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "LINE_NDC_NUM", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "CLAIM_ADMIT_TYPE_CD", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "AUTH_ADMIT_TYPE_DESC", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "NOT_TO_EXCEED_IND", - "rawType": "object", - "type": "string" - }, - { - "name": "CONTRACT_BILL_TYPE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "REIMBURSEMENT_EFFECTIVE_DATE", - "rawType": "Int64", - "type": "integer" - }, - { - "name": "REIMBURSEMENT_TERMINATION_DATE", - "rawType": "Int64", - "type": "integer" - } - ], - "conversionMethod": "pd.DataFrame", - "ref": "31241db5-0f2c-4162-9950-d67ba66851be", - "rows": [ - [ - "0", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment A-1: Medicaid\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nANCILLARY SERVICES\nLABORATORY\nCentral MS Diagnostic, LLC", - "30", - "Medicaid", - "Central MS Diagnostic, LLC", - "MEDICAID", - "MEDICAID", - "Medicaid", - null, - null, - null, - null, - "Lab", - "Central MS Diagnostic, LLC", - "LABORATORY", - "LABORATORY", - "laboratory Covered Services", - "the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicaid fee schedule.", - "Billed Charges", - null, - "100", - null, - null, - null, - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "N", - null, - null, - null - ], - [ - "1", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment A-1: Medicaid\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nANCILLARY SERVICES\nLABORATORY\nCentral MS Diagnostic, LLC", - "30", - "Medicaid", - "Central MS Diagnostic, LLC", - "MEDICAID", - "MEDICAID", - "Medicaid", - null, - null, - null, - null, - "Lab", - "Central MS Diagnostic, LLC", - "LABORATORY", - "LABORATORY", - "laboratory Covered Services", - "the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicaid fee schedule.", - "Fee Schedule", - null, - "100", - "Payor's Medicaid fee schedule", - "MEDICAID", - null, - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "N", - null, - null, - null - ], - [ - "2", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - null, - "Central MS Diagnostic, LLC", - null, - "MEDICARE", - "Medicare", - null, - null, - null, - null, - null, - "Central MS Diagnostic, LLC", - null, - null, - "Covered Services that are Medicare Covered Services and Medicaid Covered Services", - "Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service", - "Billed Charges", - null, - "100", - null, - null, - null, - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "N", - null, - null, - null - ], - [ - "3", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - null, - "Central MS Diagnostic, LLC", - null, - "MEDICARE", - "Medicare", - null, - null, - null, - null, - null, - "Central MS Diagnostic, LLC", - null, - null, - "Covered Services that are Medicare Covered Services and Medicaid Covered Services", - "Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service", - "Fee Schedule", - null, - "100", - "Medicare payment rate", - "MEDICARE", - "in effect on the date of service", - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "Y", - null, - null, - null - ], - [ - "4", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - null, - "Central MS Diagnostic, LLC", - null, - "MEDICARE", - "Medicare", - null, - null, - null, - null, - null, - "Central MS Diagnostic, LLC", - null, - null, - "Covered Services that are Medicare Covered Services and are not Medicaid Covered Services", - "Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable based on the Medicare payment rate in effect on the date of service, not including Cost-Sharing Amounts", - "Billed Charges", - null, - "100", - null, - null, - null, - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "N", - null, - null, - null - ], - [ - "5", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - null, - "Central MS Diagnostic, LLC", - null, - "MEDICARE", - "Medicare", - null, - null, - null, - null, - null, - "Central MS Diagnostic, LLC", - null, - null, - "Covered Services that are Medicare Covered Services and are not Medicaid Covered Services", - "Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable based on the Medicare payment rate in effect on the date of service, not including Cost-Sharing Amounts", - "Fee Schedule", - null, - "100", - "Medicare payment rate", - "MEDICARE", - "in effect on the date of service", - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "N", - null, - null, - null - ], - [ - "6", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - null, - "Central MS Diagnostic, LLC", - null, - "MEDICARE", - "Medicare", - null, - null, - null, - null, - null, - "Central MS Diagnostic, LLC", - null, - null, - "Covered Services that are Medicaid Covered Services and are not Medicare Covered Services", - "Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable by Medicaid, not including any Cost-Sharing Amounts that would have been applied by Medicaid, based on the Medicaid payment rate in effect on the date of service", - "Billed Charges", - null, - null, - null, - null, - null, - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "N", - null, - null, - null - ], - [ - "7", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - null, - "Central MS Diagnostic, LLC", - null, - "MEDICARE", - "Medicare", - null, - null, - null, - null, - null, - "Central MS Diagnostic, LLC", - null, - null, - "Covered Services that are Medicaid Covered Services and are not Medicare Covered Services", - "Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable by Medicaid, not including any Cost-Sharing Amounts that would have been applied by Medicaid, based on the Medicaid payment rate in effect on the date of service", - "Fee Schedule", - null, - "100", - "Medicaid", - "MEDICAID", - "in effect on the date of service", - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "Y", - null, - null, - null - ], - [ - "8", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - null, - "Central MS Diagnostic, LLC", - null, - "MEDICARE", - "Medicare", - null, - null, - null, - null, - null, - "Central MS Diagnostic, LLC", - null, - null, - "Covered Services rendered to Covered Person who are eligible for Medicare and enrolled in a Medicare Plan that may include coverage for both Medicare and Medicaid Covered Services", - "Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service", - "Billed Charges", - null, - "100", - null, - null, - null, - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "N", - null, - null, - null - ], - [ - "9", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment B: Medicare\nEXHIBIT 1\nCOMPENSATION SCHEDULE\nALL MEDICARE PRODUCT TYPES\nPROVIDER SERVICES\nCentral MS Diagnostic, LLC", - "41", - null, - "Central MS Diagnostic, LLC", - null, - "MEDICARE", - "Medicare", - null, - null, - null, - null, - null, - "Central MS Diagnostic, LLC", - null, - null, - "Covered Services rendered to Covered Person who are eligible for Medicare and enrolled in a Medicare Plan that may include coverage for both Medicare and Medicaid Covered Services", - "Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service", - "Fee Schedule", - null, - "100", - "Medicare payment rate", - "MEDICARE", - "in effect on the date of service", - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "Y", - null, - null, - null - ], - [ - "10", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment C: Commercial-Exchange\nEXHIBIT I\nCOMPENSATION SCHEDULE\nANCILLARY SERVICES\nLABORATORY\nCentral MS Diagnostic, LLC", - "47", - "Commercial-Exchange", - "Central MS Diagnostic, LLC", - "COMMERCIAL-EXCHANGE", - "COMMERCIAL-EXCHANGE", - "Commercial-Group", - null, - null, - null, - null, - "Lab", - "Central MS Diagnostic, LLC", - "LABORATORY", - "LABORATORY", - "laboratory Covered Services", - "the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicare fee schedule.", - "Billed Charges", - null, - "100", - null, - null, - null, - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "N", - null, - null, - null - ], - [ - "11", - "00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt", - "PARTICIPATING PROVIDER AGREEMENT", - null, - "Test-Client", - "Magnolia Health Plan, Inc.", - "640908605", - "1255427464", - "Central MS Diagnostic, LLC", - null, - null, - null, - null, - null, - "2018/05/02", - "three years from the contract effective date", - "9999/01/01", - "Y", - "one year", - "Ancillary", - "M", - "Attachment C: Commercial-Exchange\nEXHIBIT I\nCOMPENSATION SCHEDULE\nANCILLARY SERVICES\nLABORATORY\nCentral MS Diagnostic, LLC", - "47", - "Commercial-Exchange", - "Central MS Diagnostic, LLC", - "COMMERCIAL-EXCHANGE", - "COMMERCIAL-EXCHANGE", - "Commercial-Group", - null, - null, - null, - null, - "Lab", - "Central MS Diagnostic, LLC", - "LABORATORY", - "LABORATORY", - "laboratory Covered Services", - "the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicare fee schedule.", - "Fee Schedule", - null, - "100", - "Payor's Medicare fee schedule", - "MEDICARE", - null, - null, - "Y", - "N", - "N", - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - null, - "N", - null, - null, - null - ] - ], - "shape": { - "columns": 65, - "rows": 12 - } - }, - "text/html": [ - "
\n", - "\n", - "\n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - "
CONTRACT_FILE_NAMECONTRACT_TITLECONTRACT_AMENDMENT_NUMCLIENT_NAMEPAYER_NAMEPROV_GROUP_TINPROV_GROUP_NPIPROV_GROUP_NAME_FULLPROV_TIN_OTHERPROV_NPI_OTHER...GROUPER_TYPEFACILITY_GROUPER_CDFACILITY_GROUPER_DESCLINE_NDC_NUMCLAIM_ADMIT_TYPE_CDAUTH_ADMIT_TYPE_DESCNOT_TO_EXCEED_INDCONTRACT_BILL_TYPEREIMBURSEMENT_EFFECTIVE_DATEREIMBURSEMENT_TERMINATION_DATE
000-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>N<NA><NA><NA>
100-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>N<NA><NA><NA>
200-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>N<NA><NA><NA>
300-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>Y<NA><NA><NA>
400-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>N<NA><NA><NA>
500-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>N<NA><NA><NA>
600-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>N<NA><NA><NA>
700-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>Y<NA><NA><NA>
800-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>N<NA><NA><NA>
900-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>Y<NA><NA><NA>
1000-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>N<NA><NA><NA>
1100-125434-Central MS Diagnostic, LLC-ICMProvid...PARTICIPATING PROVIDER AGREEMENT<NA>Test-ClientMagnolia Health Plan, Inc.6409086051255427464Central MS Diagnostic, LLC<NA><NA>...<NA><NA><NA><NA><NA><NA>N<NA><NA><NA>
\n", - "

12 rows × 65 columns

\n", - "
" - ], - "text/plain": [ - " CONTRACT_FILE_NAME \\\n", - "0 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "1 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "2 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "3 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "4 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "5 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "6 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "7 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "8 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "9 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "10 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "11 00-125434-Central MS Diagnostic, LLC-ICMProvid... \n", - "\n", - " CONTRACT_TITLE CONTRACT_AMENDMENT_NUM CLIENT_NAME \\\n", - "0 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "1 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "2 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "3 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "4 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "5 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "6 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "7 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "8 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "9 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "10 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "11 PARTICIPATING PROVIDER AGREEMENT Test-Client \n", - "\n", - " PAYER_NAME PROV_GROUP_TIN PROV_GROUP_NPI \\\n", - "0 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "1 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "2 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "3 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "4 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "5 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "6 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "7 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "8 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "9 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "10 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "11 Magnolia Health Plan, Inc. 640908605 1255427464 \n", - "\n", - " PROV_GROUP_NAME_FULL PROV_TIN_OTHER PROV_NPI_OTHER ... \\\n", - "0 Central MS Diagnostic, LLC ... \n", - "1 Central MS Diagnostic, LLC ... \n", - "2 Central MS Diagnostic, LLC ... \n", - "3 Central MS Diagnostic, LLC ... \n", - "4 Central MS Diagnostic, LLC ... \n", - "5 Central MS Diagnostic, LLC ... \n", - "6 Central MS Diagnostic, LLC ... \n", - "7 Central MS Diagnostic, LLC ... \n", - "8 Central MS Diagnostic, LLC ... \n", - "9 Central MS Diagnostic, LLC ... \n", - "10 Central MS Diagnostic, LLC ... \n", - "11 Central MS Diagnostic, LLC ... \n", - "\n", - " GROUPER_TYPE FACILITY_GROUPER_CD FACILITY_GROUPER_DESC LINE_NDC_NUM \\\n", - "0 \n", - "1 \n", - "2 \n", - "3 \n", - "4 \n", - "5 \n", - "6 \n", - "7 \n", - "8 \n", - "9 \n", - "10 \n", - "11 \n", - "\n", - " CLAIM_ADMIT_TYPE_CD AUTH_ADMIT_TYPE_DESC NOT_TO_EXCEED_IND \\\n", - "0 N \n", - "1 N \n", - "2 N \n", - "3 Y \n", - "4 N \n", - "5 N \n", - "6 N \n", - "7 Y \n", - "8 N \n", - "9 Y \n", - "10 N \n", - "11 N \n", - "\n", - " CONTRACT_BILL_TYPE REIMBURSEMENT_EFFECTIVE_DATE \\\n", - "0 \n", - "1 \n", - "2 \n", - "3 \n", - "4 \n", - "5 \n", - "6 \n", - "7 \n", - "8 \n", - "9 \n", - "10 \n", - "11 \n", - "\n", - " REIMBURSEMENT_TERMINATION_DATE \n", - "0 \n", - "1 \n", - "2 \n", - "3 \n", - "4 \n", - "5 \n", - "6 \n", - "7 \n", - "8 \n", - "9 \n", - "10 \n", - "11 \n", - "\n", - "[12 rows x 65 columns]" - ] - }, - "execution_count": 6, - "metadata": {}, - "output_type": "execute_result" + "name": "stdout", + "output_type": "stream", + "text": [ + "Processing BSW _ Original Contract _ 1.1.2000 MU.txt\n", + "false_negatives: 22 | false_positives: 1 | true_positives: 0 | precision: 0.0 | recall: 0.0 | f1_score: 0\n", + "\n", + "Processing 39-0806250-Divine Saviour Hospital-ICMProviderAgreement_97009.txt\n", + "false_negatives: 0 | false_positives: 0 | true_positives: 2 | precision: 1.0 | recall: 1.0 | f1_score: 1.0\n", + "\n", + "Processing nan\n", + "Contract nan not found in labels.\n", + "\n", + "Processing Custom_2009-08-10 Adventist - University Community Hopstial LTAC MU.txt\n", + "false_negatives: 16 | false_positives: 0 | true_positives: 8 | precision: 1.0 | recall: 0.3333333333333333 | f1_score: 0.5\n", + "\n", + "Processing 2001-11-01 California Emergency Physicians PSA_MU.txt\n", + "false_negatives: 19 | false_positives: 12 | true_positives: 31 | precision: 0.7209302325581395 | recall: 0.62 | f1_score: 0.6666666666666666\n", + "\n", + "Processing 92-2764433-MAGNOLIA MOBILE HOME CARE LLC-ICMProviderAgreement_322270.txt\n", + "false_negatives: 0 | false_positives: 0 | true_positives: 14 | precision: 1.0 | recall: 1.0 | f1_score: 1.0\n", + "\n", + "Processing Fac1_Bullhead City_Western Arizona Med Center - 860982071 MU.txt\n", + "false_negatives: 4 | false_positives: 0 | true_positives: 5 | precision: 1.0 | recall: 0.5555555555555556 | f1_score: 0.7142857142857143\n", + "\n", + "Processing Custom_PSA - Advanced Gastroenterology of Texas PLLC -Executed 47-4543923 MU.txt\n", + "false_negatives: 12 | false_positives: 2 | true_positives: 0 | precision: 0.0 | recall: 0.0 | f1_score: 0\n", + "\n", + "Processing 2022 01 20 West Park Primary Care_Master (Master) PHY Executed.pdf.filepart MU.txt\n", + "false_negatives: 22 | false_positives: 29 | true_positives: 18 | precision: 0.3829787234042553 | recall: 0.45 | f1_score: 0.4137931034482758\n", + "\n", + "Processing 95-2648499-Mission Pathology Medical Associates-ICMProviderAgreement_254534.txt\n", + "false_negatives: 62 | false_positives: 2 | true_positives: 16 | precision: 0.8888888888888888 | recall: 0.20512820512820512 | f1_score: 0.3333333333333333\n", + "\n", + "Processing 61-1400871-West Kentucky Dermatology PSC-ICMProviderAgreement_104221.txt\n", + "false_negatives: 0 | false_positives: 0 | true_positives: 5 | precision: 1.0 | recall: 1.0 | f1_score: 1.0\n", + "\n", + "Processing 91-1885077-COASTAL ANESTHESIOLOGY MEDICAL-ICMProviderAgreement_242069.txt\n", + "false_negatives: 4 | false_positives: 3 | true_positives: 43 | precision: 0.9347826086956522 | recall: 0.9148936170212766 | f1_score: 0.924731182795699\n", + "\n", + "Processing 84-5179194-Heart and Soul Hospice LLC-ICMProviderAgreement_273737.txt\n", + "false_negatives: 2 | false_positives: 2 | true_positives: 2 | precision: 0.5 | recall: 0.5 | f1_score: 0.5\n", + "\n", + "Processing 050540697 Deepak Nanda 2017 PHSP MU.txt\n", + "false_negatives: 0 | false_positives: 0 | true_positives: 1 | precision: 1.0 | recall: 1.0 | f1_score: 1.0\n", + "\n", + "Processing 02-0677066-Eyemasters-ICMProviderAgreement_64220_2.txt\n", + "false_negatives: 112 | false_positives: 59 | true_positives: 3 | precision: 0.04838709677419355 | recall: 0.02608695652173913 | f1_score: 0.033898305084745756\n", + "\n", + "Processing 86-0898663-Founder Health, LLC dba Preferred Homecare-ICMProviderAgreement_120661.txt\n", + "false_negatives: 50 | false_positives: 21 | true_positives: 85 | precision: 0.8018867924528302 | recall: 0.6296296296296297 | f1_score: 0.7053941908713692\n", + "\n", + "Processing Adena Health System National Template Agreement C19460229AA.txt\n", + "false_negatives: 7 | false_positives: 7 | true_positives: 44 | precision: 0.8627450980392157 | recall: 0.8627450980392157 | f1_score: 0.8627450980392157\n", + "\n", + "Processing 2018 09 01 UTMB (Amendment 10 change in reimbursement) MU.txt\n", + "false_negatives: 57 | false_positives: 28 | true_positives: 1 | precision: 0.034482758620689655 | recall: 0.017241379310344827 | f1_score: 0.022988505747126436\n", + "\n", + "Processing 2014-01-01 United Health Centers San Joaquin AMD MU.txt\n", + "false_negatives: 15 | false_positives: 6 | true_positives: 15 | precision: 0.7142857142857143 | recall: 0.5 | f1_score: 0.588235294117647\n", + "\n", + "Processing 5.2000_Rehab Designs of America_VendorAgreement MU.txt\n", + "false_negatives: 0 | false_positives: 0 | true_positives: 4 | precision: 1.0 | recall: 1.0 | f1_score: 1.0\n", + "\n", + "Processing 36-2902782-Circle Family HealthCare Network-ICMProviderAgreement_59631.txt\n", + "Contract 36-2902782-Circle Family HealthCare Network-ICMProviderAgreement_59631.txt not found in predictions.\n", + "\n", + "Processing 2014-01-01 COMM PPO - PeaceHealth Multi TIN - Facility and Prof MU.txt\n", + "false_negatives: 66 | false_positives: 61 | true_positives: 181 | precision: 0.7479338842975206 | recall: 0.7327935222672065 | f1_score: 0.7402862985685071\n", + "\n", + "Processing 06-1798267-Anthony W. Le, A Professional Corp-ICMProviderAgreement_316844.txt\n", + "Contract 06-1798267-Anthony W. Le, A Professional Corp-ICMProviderAgreement_316844.txt not found in predictions.\n", + "\n", + "Processing 33-0057155-Apria Healthcare, Inc.-ICMProviderAgreementAmendment_26762.txt\n", + "false_negatives: 372 | false_positives: 243 | true_positives: 161 | precision: 0.39851485148514854 | recall: 0.30206378986866794 | f1_score: 0.3436499466382071\n", + "\n", + "Processing 20-1668371-Midwest Medical Equipment Solutions, Inc.-ICMProviderAgreementAmendment_166876.txt\n", + "false_negatives: 80 | false_positives: 44 | true_positives: 0 | precision: 0.0 | recall: 0.0 | f1_score: 0\n", + "\n", + "Processing 95-3372911; Multiple-Davita Healthcare Partners, Inc.-ICMProviderAgreement_138658.txt\n", + "false_negatives: 4 | false_positives: 4 | true_positives: 42 | precision: 0.9130434782608695 | recall: 0.9130434782608695 | f1_score: 0.9130434782608695\n", + "\n", + "Processing 429670586-Melissa Ann Clark-ICMProviderAgreement_128379_1.txt\n", + "false_negatives: 3 | false_positives: 4 | true_positives: 5 | precision: 0.5555555555555556 | recall: 0.625 | f1_score: 0.5882352941176471\n", + "\n", + "Processing ICMProviderAgreement_ICMProviderAgreement_295973_15.txt\n", + "false_negatives: 0 | false_positives: 5 | true_positives: 5 | precision: 0.5 | recall: 1.0 | f1_score: 0.6666666666666666\n", + "\n", + "Processing Custom_2018-09-15 COMM Agmt FE - Bandon Community Health Center dba Coast Community Health Center.txt\n", + "false_negatives: 159 | false_positives: 124 | true_positives: 15 | precision: 0.1079136690647482 | recall: 0.08620689655172414 | f1_score: 0.09584664536741214\n", + "\n", + "Processing Akron General Health System_Eleventh Amendment_20171001.txt\n", + "false_negatives: 14 | false_positives: 13 | true_positives: 12 | precision: 0.48 | recall: 0.46153846153846156 | f1_score: 0.47058823529411764\n", + "\n", + "Processing Progressive Women's Health, PLLC_Physician Agreement MU.txt\n", + "false_negatives: 17 | false_positives: 26 | true_positives: 13 | precision: 0.3333333333333333 | recall: 0.43333333333333335 | f1_score: 0.37681159420289856\n", + "\n", + "Processing Custom_HSA_EFF07012010_Driscoll Children's Hospital MU.txt\n", + "false_negatives: 4 | false_positives: 4 | true_positives: 1 | precision: 0.2 | recall: 0.2 | f1_score: 0.20000000000000004\n", + "\n", + "Processing Custom_2012-10-01 AdvenHealth Amendment.txt\n", + "false_negatives: 99 | false_positives: 107 | true_positives: 71 | precision: 0.398876404494382 | recall: 0.4176470588235294 | f1_score: 0.4080459770114942\n", + "\n", + "Processing BoilerplateAnc_Bentley Medical PLLC - Amendment 8.1.14_MU.txt\n", + "false_negatives: 2 | false_positives: 2 | true_positives: 0 | precision: 0.0 | recall: 0.0 | f1_score: 0\n", + "\n", + "Processing Boilerplate_2020-01-01 COMM Amend FE (Beacon) - Portland Adventist Medical Center MU.txt\n", + "false_negatives: 2 | false_positives: 4 | true_positives: 5 | precision: 0.5555555555555556 | recall: 0.7142857142857143 | f1_score: 0.6250000000000001\n", + "\n", + "Processing Hunt Regional Medical Center Executed Contract.txt\n", + "false_negatives: 1 | false_positives: 1 | true_positives: 1 | precision: 0.5 | recall: 0.5 | f1_score: 0.5\n", + "\n", + "Processing Custom_PSA - TX - Fresenius BIOMEDICAL APPLICATIONS OF TEXAS INC - 11-2226275 - 06012010 (1) (2) MU.txt\n", + "false_negatives: 24 | false_positives: 25 | true_positives: 0 | precision: 0.0 | recall: 0.0 | f1_score: 0\n", + "\n", + "Processing AMD - IV - HSA eff 2017 (amd 4) - Broward MU.txt\n", + "false_negatives: 41 | false_positives: 19 | true_positives: 11 | precision: 0.36666666666666664 | recall: 0.21153846153846154 | f1_score: 0.26829268292682923\n", + "\n", + "Processing 2019 01 01 Gulf Coast Division (Agreement_STAR, CHIP, CHIP P, STAR_PLUS) MU.txt\n", + "false_negatives: 20 | false_positives: 37 | true_positives: 16 | precision: 0.3018867924528302 | recall: 0.4444444444444444 | f1_score: 0.3595505617977528\n", + "\n", + "Processing AGMT - HSA - TEXAS HEALTH RESOURCES - 75-6001743 MU.txt\n", + "false_negatives: 3 | false_positives: 3 | true_positives: 1 | precision: 0.25 | recall: 0.25 | f1_score: 0.25\n", + "\n", + "Processing ICMProviderAgreement_CorasWellnessAndBehavioralHealth_212482_8.txt\n", + "false_negatives: 1 | false_positives: 0 | true_positives: 16 | precision: 1.0 | recall: 0.9411764705882353 | f1_score: 0.9696969696969697\n", + "\n", + "Processing Boilerplate_Benjamin Bieber MD - Amendment 5.30.16_MU.txt\n", + "false_negatives: 4 | false_positives: 4 | true_positives: 4 | precision: 0.5 | recall: 0.5 | f1_score: 0.5\n", + "\n", + "Processing Community Health Network_Base Contract MU.txt\n", + "false_negatives: 6 | false_positives: 3 | true_positives: 2 | precision: 0.4 | recall: 0.25 | f1_score: 0.3076923076923077\n", + "\n", + "Processing CustomFac_AMD - AMD - UNIVERSITY MEDICAL CENTER OF EL PASO - 74-6000756 MU.txt\n", + "false_negatives: 5 | false_positives: 5 | true_positives: 4 | precision: 0.4444444444444444 | recall: 0.4444444444444444 | f1_score: 0.4444444444444444\n", + "\n", + "Processing Anc2_23-1943113_BayadaHHC_Amendment1_553403.txt\n", + "false_negatives: 57 | false_positives: 56 | true_positives: 3 | precision: 0.05084745762711865 | recall: 0.05 | f1_score: 0.05042016806722689\n", + "\n", + "Processing 6.2000_Omni Transport Systems_ServicesAgreement MU.txt\n", + "false_negatives: 0 | false_positives: 0 | true_positives: 4 | precision: 1.0 | recall: 1.0 | f1_score: 1.0\n", + "\n", + "Processing Boilerplate_PSA_Houston Eye Associates_76-0512625_05012007 MU.txt\n", + "false_negatives: 0 | false_positives: 3 | true_positives: 2 | precision: 0.4 | recall: 1.0 | f1_score: 0.5714285714285715\n", + "\n", + "Processing ICMProviderAgreement_BanyanDelaware_210080_5.txt\n", + "false_negatives: 8 | false_positives: 8 | true_positives: 8 | precision: 0.5 | recall: 0.5 | f1_score: 0.5\n", + "\n", + "Processing ICMProviderAgreement_AlisonUnitisLPCMH_227710_5.txt\n", + "false_negatives: 1 | false_positives: 1 | true_positives: 9 | precision: 0.9 | recall: 0.9 | f1_score: 0.9\n", + "\n", + "Processing ICMProviderAgreement_NewCastleHealthandRehabilitationCenter_212261_13 MU.txt\n", + "false_negatives: 16 | false_positives: 18 | true_positives: 2 | precision: 0.1 | recall: 0.1111111111111111 | f1_score: 0.10526315789473685\n", + "\n", + "Processing 2013-09-01 Fresno Dental Surgery Center PPA_MU.txt\n", + "false_negatives: 31 | false_positives: 19 | true_positives: 9 | precision: 0.32142857142857145 | recall: 0.225 | f1_score: 0.2647058823529412\n", + "\n", + "Processing Genesis_ICMProviderAgreement_ICMProviderAgreement_153537_5.txt\n", + "false_negatives: 7 | false_positives: 6 | true_positives: 3 | precision: 0.3333333333333333 | recall: 0.3 | f1_score: 0.3157894736842105\n", + "\n", + "Processing Boilerplate_Fac_Bronx Lebanon Hospital Center - Amendment 1.1.14 MU.txt\n", + "false_negatives: 7 | false_positives: 7 | true_positives: 1 | precision: 0.125 | recall: 0.125 | f1_score: 0.125\n", + "\n", + "Processing Cabell Huntington_OH MCD Compensation MU.txt\n", + "false_negatives: 4 | false_positives: 5 | true_positives: 11 | precision: 0.6875 | recall: 0.7333333333333333 | f1_score: 0.7096774193548386\n", + "\n", + "Processing Boilerplate_AMD - MKPL - NBHD dba Broward Health - Copy_MU.txt\n", + "false_negatives: 3 | false_positives: 4 | true_positives: 9 | precision: 0.6923076923076923 | recall: 0.75 | f1_score: 0.7199999999999999\n", + "\n", + "Processing ICMProviderAgreement_ICMProviderAgreement_143342_10_Landmark of Midwest City Rehab and Nursing Center.txt\n", + "false_negatives: 0 | false_positives: 4 | true_positives: 6 | precision: 0.6 | recall: 1.0 | f1_score: 0.7499999999999999\n", + "\n", + "Processing Southeast Georgia Health System Inc_20170517_Dually Executed MU.txt\n", + "Contract Southeast Georgia Health System Inc_20170517_Dually Executed MU.txt not found in predictions.\n", + "\n", + "Processing 2021-07-15 COMM Agmt FE - Samaritan Health Services MU.txt\n", + "false_negatives: 185 | false_positives: 145 | true_positives: 78 | precision: 0.34977578475336324 | recall: 0.2965779467680608 | f1_score: 0.3209876543209877\n", + "\n", + "Processing Custom_Prof_Anna Suponya MD PC - Agreement Provider Signed_MU.txt\n", + "false_negatives: 9 | false_positives: 10 | true_positives: 5 | precision: 0.3333333333333333 | recall: 0.35714285714285715 | f1_score: 0.3448275862068965\n", + "\n", + "Processing ICMProviderAgreement_AzarEyeSurgeryCenter_232594_6.txt\n", + "false_negatives: 1 | false_positives: 0 | true_positives: 30 | precision: 1.0 | recall: 0.967741935483871 | f1_score: 0.9836065573770492\n", + "\n", + "Processing 2019 06 01 Dr Raul Rivera & Associates (Amend 1)_MU.txt\n", + "false_negatives: 2 | false_positives: 2 | true_positives: 0 | precision: 0.0 | recall: 0.0 | f1_score: 0\n", + "\n", + "Processing Custom_Parkview Health Systems-OH MP, IN MP-ID C15656222AA MU.txt\n", + "false_negatives: 2 | false_positives: 3 | true_positives: 10 | precision: 0.7692307692307693 | recall: 0.8333333333333334 | f1_score: 0.8\n", + "\n", + "Processing 133923495 CAIPA 2015 PHSP.txt\n", + "false_negatives: 64 | false_positives: 64 | true_positives: 54 | precision: 0.4576271186440678 | recall: 0.4576271186440678 | f1_score: 0.4576271186440678\n", + "\n", + "Processing Custom_060121 HonorHealth and its Affiliates Care 1st Physician Agreement.txt\n", + "false_negatives: 15 | false_positives: 29 | true_positives: 11 | precision: 0.275 | recall: 0.4230769230769231 | f1_score: 0.33333333333333337\n", + "\n", + "Processing Anc8_Hanger Pros & Ortho West Contract.txt\n", + "Contract Anc8_Hanger Pros & Ortho West Contract.txt not found in predictions.\n", + "\n", + "Processing Tampa General Rehabilitation Hospital Agreement MU.txt\n", + "false_negatives: 3 | false_positives: 2 | true_positives: 6 | precision: 0.75 | recall: 0.6666666666666666 | f1_score: 0.7058823529411765\n", + "\n", + "Processing Custom_2018-09-15 COMM Amend FE Plaza Ambulatory Surgery Center, LLC MU.txt\n", + "false_negatives: 12 | false_positives: 17 | true_positives: 4 | precision: 0.19047619047619047 | recall: 0.25 | f1_score: 0.2162162162162162\n", + "\n", + "Processing Custom_SOUTHWEST BEHAVIORAL & HEALTH SERVICES INC.txt\n", + "false_negatives: 67 | false_positives: 37 | true_positives: 2 | precision: 0.05128205128205128 | recall: 0.028985507246376812 | f1_score: 0.037037037037037035\n", + "\n", + "Processing CustomFac_Benedictine Hospital - Amendment 1.1.16 (HBX,HARP,EPP) (REVISED).txt\n", + "false_negatives: 1 | false_positives: 1 | true_positives: 31 | precision: 0.96875 | recall: 0.96875 | f1_score: 0.96875\n", + "\n", + "Processing 00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt\n", + "false_negatives: 2 | false_positives: 2 | true_positives: 10 | precision: 0.8333333333333334 | recall: 0.8333333333333334 | f1_score: 0.8333333333333334\n", + "\n", + "Processing 46-0979580-Harris and Theodore Anesthesia Services, LLC-ICMProviderAgreement_313205.txt\n", + "false_negatives: 4 | false_positives: 1 | true_positives: 23 | precision: 0.9583333333333334 | recall: 0.8518518518518519 | f1_score: 0.9019607843137256\n", + "\n" + ] } ], "source": [ - "predictions_df" + "precisions = []\n", + "recalls = []\n", + "\n", + "total_true_positives = 0\n", + "total_false_positives = 0\n", + "total_false_negatives = 0\n", + "\n", + "\n", + "for contract_file_name in labels_df[\"CONTRACT_FILE_NAME\"].unique():\n", + " print(f\"Processing {contract_file_name}\")\n", + " labels_df_contract = labels_df[\n", + " labels_df[\"CONTRACT_FILE_NAME\"] == contract_file_name\n", + " ]\n", + " predictions_df_contract = predictions_df[\n", + " predictions_df[\"CONTRACT_FILE_NAME\"] == contract_file_name\n", + " ]\n", + " if len(labels_df_contract) == 0:\n", + " print(f\"Contract {contract_file_name} not found in labels.\\n\")\n", + " continue\n", + " elif len(predictions_df_contract) == 0:\n", + " print(f\"Contract {contract_file_name} not found in predictions.\\n\")\n", + " continue\n", + "\n", + " # Full reimbursement primary\n", + " comparison = evaluate_one_to_n_fields_fuzzy_matching_field_by_field(\n", + " labels_df_contract,\n", + " predictions_df_contract,\n", + " \"CONTRACT_FILE_NAME\",\n", + " fields,\n", + " thresholds=MATCH_THRESHOLD\n", + " )\n", + "\n", + " # comparison = evaluate_one_to_n_fields_fuzzy_matching_field_by_field(labels_df_contract, predictions_df_contract, \"CONTRACT_FILE_NAME\", ['CONTRACT_REIMBURSEMENT_METHOD', 'CONTRACT_FEE_SCHEDULE_DESC'])\n", + "\n", + " precisions.append(comparison[\"precision\"])\n", + " recalls.append(comparison[\"recall\"])\n", + "\n", + " total_true_positives += comparison[\"true_positives\"]\n", + " total_false_positives += comparison[\"false_positives\"]\n", + " total_false_negatives += comparison[\"false_negatives\"]\n", + "\n", + " # contract file name is already printed above\n", + " print(\n", + " f\"false_negatives: {comparison['false_negatives']} | false_positives: {comparison['false_positives']} | true_positives: {comparison['true_positives']} | precision: {comparison['precision']} | recall: {comparison['recall']} | f1_score: {comparison['f1_score']}\\n\"\n", + " )" ] }, { @@ -3277,254 +403,29 @@ "metadata": {}, "outputs": [ { - "data": { - "text/plain": [ - "Index(['CONTRACT_FILE_NAME', 'CONTRACT_TITLE', 'CONTRACT_AMENDMENT_NUM',\n", - " 'CLIENT_NAME', 'PAYER_NAME', 'PROV_GROUP_TIN', 'PROV_GROUP_NPI',\n", - " 'PROV_GROUP_NAME_FULL', 'PROV_TIN_OTHER', 'PROV_NPI_OTHER',\n", - " 'PROV_REIMBURSEMENT_TIN', 'PROV_REIMBURSEMENT_NPI', 'PROV_FULL_NAME',\n", - " 'CONTRACT_EFFECTIVE_DT', 'CONTRACT_TERMINATION_DT',\n", - " 'AARETE_DERIVED_TERMINATION_DATE', 'CONTRACT_AUTO_RENEWAL_IND',\n", - " 'CONTRACT_AUTO_RENEWAL_TERM', 'CONTRACT_CLAIM_TYPE_CD',\n", - " 'AARETE_DERIVED_CLAIM_TYPE_CD', 'EXHIBIT_NAME', 'EXHIBIT_PAGE',\n", - " 'CONTRACT_PRODUCT', 'REIMBURSEMENT_PROV_NAME', 'AARETE_DERIVED_PRODUCT',\n", - " 'CONTRACT_LINE_OF_BUSINESS', 'AARETE_DERIVED_LINE_OF_BUSINESS',\n", - " 'CONTRACT_PROGRAM', 'AARETE_DERIVED_PROGRAM', 'CONTRACT_NETWORK',\n", - " 'AARETE_DERIVED_NETWORK', 'AARETE_DERIVED_PROV_TYPE',\n", - " 'REIMBURSEMENT_PROV_NAME.1', 'CONTRACT_PROV_SPECIALTY',\n", - " 'AARETE_DERIVED_PROV_SPECIALTY', 'CONTRACT_SERVICE_CD_OR_DESC',\n", - " 'CONTRACT_REIMBURSEMENT_METHOD', 'AARETE_DERIVED_REIMBURSEMENT_METHOD',\n", - " 'CONTRACT_REIMBURSEMENT_FEE_RATE',\n", - " 'CONTRACT_REIMBURSEMENT_PERCENT_RATE', 'CONTRACT_FEE_SCHEDULE_DESC',\n", - " 'AARETE_DERIVED_FEE_SCHEDULE', 'CONTRACT_FEE_SCHEDULE_VERSION',\n", - " 'AARETE_DERIVED_FEE_SCHEDULE_VERSION', 'CONTRACT_LESSER_OF_IND',\n", - " 'CONTRACT_GREATER_OF_IND', 'CONTRACT_DEFAULT_IND', 'CPT4_PROC_CD',\n", - " 'CPT4_PROC_DESC', 'CPT4_PROC_MOD', 'CPT4_PROC_MOD_DESC', 'REVENUE_CD',\n", - " 'REVENUE_CD_DESC', 'DIAG_CD', 'DIAG_CD_DESC', 'GROUPER_TYPE',\n", - " 'FACILITY_GROUPER_CD', 'FACILITY_GROUPER_DESC', 'LINE_NDC_NUM',\n", - " 'CLAIM_ADMIT_TYPE_CD', 'AUTH_ADMIT_TYPE_DESC', 'NOT_TO_EXCEED_IND',\n", - " 'CONTRACT_BILL_TYPE', 'REIMBURSEMENT_EFFECTIVE_DATE',\n", - " 'REIMBURSEMENT_TERMINATION_DATE'],\n", - " dtype='object')" - ] - }, - "execution_count": 7, - "metadata": {}, - "output_type": "execute_result" + "name": "stdout", + "output_type": "stream", + "text": [ + "Median precision across 66 contracts at match threshold 90: 0.5000\n", + "Median recall across 66 contracts at match threshold 90: 0.4808\n", + "Grand precision across 66 contracts at match threshold 90: 0.4686\n", + "Grand recall across 66 contracts at match threshold 90: 0.3946\n" + ] } ], "source": [ - "predictions_df.columns" + "from statistics import median\n", + "\n", + "print(f\"Median precision across {len(precisions)} contracts at match threshold {MATCH_THRESHOLD}: {median(precisions):.4f}\")\n", + "print(f\"Median recall across {len(recalls)} contracts at match threshold {MATCH_THRESHOLD}: {median(recalls):.4f}\")\n", + "print(f\"Grand precision across {len(precisions)} contracts at match threshold {MATCH_THRESHOLD}: {total_true_positives / (total_true_positives + total_false_positives):.4f}\")\n", + "print(f\"Grand recall across {len(recalls)} contracts at match threshold {MATCH_THRESHOLD}: {total_true_positives / (total_true_positives + total_false_negatives):.4f}\")" ] - }, - { - "cell_type": "code", - "execution_count": 8, - "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "{'precision': 1.0,\n", - " 'recall': 1.0,\n", - " 'f1_score': 1.0,\n", - " 'true_positives': 12,\n", - " 'false_positives': 0,\n", - " 'false_negatives': 0,\n", - " 'matched_labels': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': [(\"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicaid fee schedule.\",),\n", - " (\"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicaid fee schedule.\",),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service\",),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service\",),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable based on the Medicare payment rate in effect on the date of service, not including Cost-Sharing Amounts\",),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable based on the Medicare payment rate in effect on the date of service, not including Cost-Sharing Amounts\",),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable by Medicaid, not including any Cost-Sharing Amounts that would have been applied by Medicaid, based on the Medicaid payment rate in effect on the date of service\",),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable by Medicaid, not including any Cost-Sharing Amounts that would have been applied by Medicaid, based on the Medicaid payment rate in effect on the date of service\",),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service\",),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service\",),\n", - " (\"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicare fee schedule.\",),\n", - " (\"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicare fee schedule.\",)]},\n", - " 'unmatched_labels': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': []},\n", - " 'unmatched_predictions': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': []}}" - ] - }, - "execution_count": 8, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "evaluate_one_to_n_fields_fuzzy_matching_field_by_field(labels_df, predictions_df, \"CONTRACT_FILE_NAME\", ['CONTRACT_REIMBURSEMENT_METHOD'])" - ] - }, - { - "cell_type": "code", - "execution_count": 9, - "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "{'precision': 0.8333333333333334,\n", - " 'recall': 0.8333333333333334,\n", - " 'f1_score': 0.8333333333333334,\n", - " 'true_positives': 10,\n", - " 'false_positives': 2,\n", - " 'false_negatives': 2,\n", - " 'matched_labels': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': [(\"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicaid fee schedule.\",\n", - " nan),\n", - " (\"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicaid fee schedule.\",\n", - " \"Payor's Medicaid fee schedule\"),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service\",\n", - " nan),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable based on the Medicare payment rate in effect on the date of service, not including Cost-Sharing Amounts\",\n", - " nan),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable based on the Medicare payment rate in effect on the date of service, not including Cost-Sharing Amounts\",\n", - " 'Medicare payment rate'),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable by Medicaid, not including any Cost-Sharing Amounts that would have been applied by Medicaid, based on the Medicaid payment rate in effect on the date of service\",\n", - " nan),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable by Medicaid, not including any Cost-Sharing Amounts that would have been applied by Medicaid, based on the Medicaid payment rate in effect on the date of service\",\n", - " 'Medicaid'),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service\",\n", - " nan),\n", - " (\"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicare fee schedule.\",\n", - " nan),\n", - " (\"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicare fee schedule.\",\n", - " \"Payor's Medicare fee schedule\")]},\n", - " 'unmatched_labels': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': [(\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service\",\n", - " 'Medicare payment rate plus amount payable by Medicaid as secondary coverage'),\n", - " (\"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service\",\n", - " 'Medicare')]},\n", - " 'unmatched_predictions': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': [(\"Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service\",\n", - " 'Medicare payment rate'),\n", - " (\"Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service\",\n", - " 'Medicare payment rate')]}}" - ] - }, - "execution_count": 9, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "evaluate_one_to_n_fields_fuzzy_matching_field_by_field(labels_df, predictions_df, \"CONTRACT_FILE_NAME\", ['CONTRACT_REIMBURSEMENT_METHOD', 'CONTRACT_FEE_SCHEDULE_DESC'])" - ] - }, - { - "cell_type": "code", - "execution_count": 10, - "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "{'precision': 0.8333333333333334,\n", - " 'recall': 0.8333333333333334,\n", - " 'f1_score': 0.8333333333333334,\n", - " 'true_positives': 10,\n", - " 'false_positives': 2,\n", - " 'false_negatives': 2,\n", - " 'matched_labels': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': [('laboratory Covered Services',\n", - " \"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicaid fee schedule.\"),\n", - " ('laboratory Covered Services',\n", - " \"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicaid fee schedule.\"),\n", - " ('Covered Services that are Medicare Covered Services and Medicaid Covered Services',\n", - " \"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service\"),\n", - " ('Covered Services that are Medicare Covered Services and Medicaid Covered Services',\n", - " \"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on one hundred percent (100%) of the Medicare payment rate in effect on the date of service, plus the amount payable by Medicaid as a secondary coverage based on the Medicaid payment rate in effect on the date of service\"),\n", - " ('Covered Services that are Medicare Covered Services and are not Medicaid Covered Services',\n", - " \"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable based on the Medicare payment rate in effect on the date of service, not including Cost-Sharing Amounts\"),\n", - " ('Covered Services that are Medicare Covered Services and are not Medicaid Covered Services',\n", - " \"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable based on the Medicare payment rate in effect on the date of service, not including Cost-Sharing Amounts\"),\n", - " ('Covered Services that are Medicaid Covered Services and are not Medicare Covered Services',\n", - " \"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable by Medicaid, not including any Cost-Sharing Amounts that would have been applied by Medicaid, based on the Medicaid payment rate in effect on the date of service\"),\n", - " ('Covered Services that are Medicaid Covered Services and are not Medicare Covered Services',\n", - " \"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be one hundred percent (100%) of the amount payable by Medicaid, not including any Cost-Sharing Amounts that would have been applied by Medicaid, based on the Medicaid payment rate in effect on the date of service\"),\n", - " ('laboratory Covered Services',\n", - " \"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicare fee schedule.\"),\n", - " ('laboratory Covered Services',\n", - " \"the lesser of: (i) Allowable Charges; or (ii) one hundred percent (100%) of the Payor's Medicare fee schedule.\")]},\n", - " 'unmatched_labels': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': [('Covered Services where Payor is the only Payor for Medicare Covered Services',\n", - " \"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service\"),\n", - " ('Covered Services where Payor is the only Payor for Medicare Covered Services',\n", - " \"The Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service\")]},\n", - " 'unmatched_predictions': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': [('Covered Services rendered to Covered Person who are eligible for Medicare and enrolled in a Medicare Plan that may include coverage for both Medicare and Medicaid Covered Services',\n", - " \"Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service\"),\n", - " ('Covered Services rendered to Covered Person who are eligible for Medicare and enrolled in a Medicare Plan that may include coverage for both Medicare and Medicaid Covered Services',\n", - " \"Allowed Amount is the lesser of: (i) Allowable Charges; or (ii) Payor's maximum reimbursement schedule, which shall be the amount payable by Medicare, not including Cost-Sharing Amounts, as primary coverage based on the Medicare payment rate in effect on the date of service\")]}}" - ] - }, - "execution_count": 10, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "# just reimbursement primary <- This is the big one! We derive everything methodology-related from this.\n", - "evaluate_one_to_n_fields_fuzzy_matching_field_by_field(labels_df, predictions_df, \"CONTRACT_FILE_NAME\", ['CONTRACT_SERVICE_CD_OR_DESC', 'CONTRACT_REIMBURSEMENT_METHOD'])" - ] - }, - { - "cell_type": "code", - "execution_count": 11, - "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "{'precision': 0.9166666666666666,\n", - " 'recall': 0.9166666666666666,\n", - " 'f1_score': 0.9166666666666666,\n", - " 'true_positives': 11,\n", - " 'false_positives': 1,\n", - " 'false_negatives': 1,\n", - " 'matched_labels': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': [('Y',\n", - " 'N',\n", - " 'Billed Charges',\n", - " ,\n", - " 100),\n", - " ('Y', 'N', 'Fee Schedule', , 100),\n", - " ('Y', 'N', 'Billed Charges', , 100),\n", - " ('Y', 'N', 'Fee Schedule', , 100),\n", - " ('Y', 'N', 'Billed Charges', , 100),\n", - " ('Y', 'N', 'Fee Schedule', , 100),\n", - " ('Y', 'N', 'Billed Charges', , 100),\n", - " ('Y', 'N', 'Fee Schedule', , 100),\n", - " ('Y', 'N', 'Billed Charges', , 100),\n", - " ('Y', 'N', 'Fee Schedule', , 100),\n", - " ('Y', 'N', 'Fee Schedule', , 100)]},\n", - " 'unmatched_labels': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': [('Y',\n", - " 'N',\n", - " 'Billed Charges',\n", - " ,\n", - " 100)]},\n", - " 'unmatched_predictions': {'00-125434-Central MS Diagnostic, LLC-ICMProviderAgreement_78285.txt': [('Y',\n", - " 'N',\n", - " 'Billed Charges',\n", - " ,\n", - " )]}}" - ] - }, - "execution_count": 11, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "# Just breakout\n", - "evaluate_one_to_n_fields_fuzzy_matching_field_by_field(labels_df, predictions_df, \"CONTRACT_FILE_NAME\", ['CONTRACT_LESSER_OF_IND', 'CONTRACT_GREATER_OF_IND', 'AARETE_DERIVED_REIMBURSEMENT_METHOD', 'CONTRACT_REIMBURSEMENT_FEE_RATE', 'CONTRACT_REIMBURSEMENT_PERCENT_RATE'])" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [] } ], "metadata": { "kernelspec": { - "display_name": "doczy-smart-chunking-rwS2SHM0-py3.12", + "display_name": "doczy-smart-chunking-M88SnQcW-py3.12", "language": "python", "name": "python3" },