Bill audit rule execution¶
clsBillAuditor.AuditBill runs thirteen rule handlers, in registration order, over the bill's auditable services. Together they validate bill-level codes (DRG, diagnosis/procedure, admit type), compute each service's basic allowance (fee schedule, pharmacy, mileage, cost-charge), apply provider contract pricing, check cross-service rules (global surgery periods, the three-point rule, procedure bundling), and run final checks (denied claim, ineligible providers/services, duplicates, late filing, non-MCO providers, MCO withhold, voided claim) before totaling the bill.
| Field | Value |
|---|---|
| Operation ID | OP-AA-05 |
| Trigger | BillAuditEngine.AuditBill calls clsBillAuditor.AuditBill(Bill) once bill edits, service edits, and (for non-Worker-Reimbursement bills) MCO determination have completed |
| Inputs | clsBillAudit with edited, MCO-resolved auditable services (ReauditCode = "R"); resolved Claim, BillingProvider, and service history |
| Outputs | Computed AllowedAmount/TotalAdjustmentAmount/adjustment codes per service; recomputed bill audit totals (TotalChargedAmount, TotalAllowedAmount, TotalMcoAdminFeeAmount); Bill.BillTotalAmount; audit messages; boolean pass/fail |
| Primary components | clsBillAuditor.AuditBill and its thirteen registered rule handlers |
| Entry point | Business\SAIF.Business.Claim.Bill.AutomatedAudit\AuditUtilities\clsBillAuditor.vb |
Steps¶
AuditBill starts the "Audit Bill" trail group, clears broken rules, and runs the following rule handlers in order, then returns ErrorCount = 0:
UpdateMergeClaimID. IfBill.ClaimID <> Bill.Claim.ClaimID(the claim was merged), update the bill's claim ID/number/check digit to the merged claim's values and record informational message"Claim has been merged".ValidateDRGCode.IsDRGCodeRequiredrequires a DRG code only forInpatientHospitalbills with a UB bill type code of0111–0118, no billed service code starting with"002", and a billing provider that is not a critical-access hospital. When required,IsDRGCodeValidchecks the code with an inline query (SQL-001, CBP_DRG_CODE). If missing/invalid: message"Invalid or missing DRG Code", disallow all services with adjustment codeGS(DisallowAllServices), and returnFalsefor this rule (BR-005).ValidateDiagnosisandProcedureCode. If the billing provider type requires a diagnosis and none exists: disallow all services withGWand stop. Otherwise, validate each diagnosis (must resolve and be effective on the statement-thru date; outpatient hospital bills additionally need at least one diagnosis of typeR) and each procedure (must resolve and be effective on the statement-thru date). Any invalid diagnosis produces warning"One or more diagnosis code is not valid."; any invalid procedure produces warning"One or more procedure code is not valid."Either failure disallows all services withGW(BR-006).ComputeBasicAllowance. For each auditable service (with a compound-drug dispensing-fee override applied on/after 4/1/2016), dispatch by service type:- Revenue → no basic allowance is computed here.
- Equipment →
ComputeFeeScheduleAllowance(pre-/post-1/1/2012 logic, see step 5). - Pharmacy (not Worker Reimbursement) →
ComputeServiceLinePharmacyAllowance, which resolves the effective pharmacy allowance record and NDC price and computes the fee schedule viaclsAuditCalculator.CalcPharmacyAllowance; if the charge exceeds the computed fee schedule, a full-chargeFTadjustment is created. - Worker Reimbursement
WMILE/FMILE→ComputeMileageAllowance(fee-maximum-times-quantity; overwrites billed/audited amounts to the regulated amount if the charge is not larger, else createsFT). - All other types →
ComputeFeeScheduleAllowance. -
For inpatient/outpatient bills where the fee schedule amount remains
0, additionally compute a cost-charge allowance (ComputeCostChargeAllowance) using the effectiveclsDCBSCostChargefactor on the billing provider (default factor1if none is found).Origin: The DCBS cost/charge factor is implemented by Retrieve DCBS cost charges in
SAIF.BOF.Business.View.Provider. -ComputeFeeScheduleAllowanceitself applies percent-off eligibility (80%, or 90% for dental on/after 4/1/2012), max-amount eligibility, facility/non-facility quantity rules, post-2012 equipment-modifier formulas (UE75%,RR10%, else full), and the DCBS conversion factor (defaulting to1if missing); it forces adjustment codeFTforSG/WMEAL/WDINR/WLODGservices and forR0001(which also adds a9.5base rate); if the charge exceeds the fee schedule, it creates the adjustment and marksFeeScheduleCode = "F"; for non-physician-assistant (NP/PA) CPT services it applies a further percentage reduction (FC, 80% before 4/1/2005 else 85%); and for modifiers80/81/82/50/51it callsAlterFeeScheduleto compute surgical-assistant (FP/FQ/FO/SI), multiple-surgery (FL, 50%), or bilateral-surgery (SF, 50%) adjustments. 5.MultipleRadiography. For each auditable service with a positive allowed amount whose CPT record (resolved via cached service reference data) flags multiple-radiography disallow codes (MULCT/MULMRpre-7/1/2007;MULCT/MULCA/MULMA/MULMRpost-6/30/2007 without modifier26), find matching historical (via SQL-002 history data, CBP_BILL) and current same-provider, same-day services and apply a percentage-basedFHadjustment (AllowedAmount - FeeScheduleAmount * percent, using the era-specific percentage table).
Origin: CPT/fee-schedule reference data and bundling flags used throughout this rule set (steps 4, 5, and 8) are resolved by Service reference lookups in
SAIF.Business.Claim.Bill. 6.ProviderContracts. If the billing provider has service contracts, first checks outpatient-hospital package pricing (CheckForProviderContractPackagePrice— a single-procedure MCO bill matched against package-priced contracts for the claim's MCO plan; spreads a computedMAadjustment across services when the package price is below the eligible amount), then for each auditable service finds a matching contract (FindProviderServiceContract/ContractQualifies, checked by service type/CBP code, purchase-vs-rental modifiers, ASC status, and MCO-plan match) and applies a discount-rate, additional-fee-discount-rate, or max-charge adjustment codedMC(MCO-plan contract) orNA(non-plan contract).Origin: Provider service contracts are implemented by Retrieve provider service contracts in
SAIF.BOF.Business.View.Provider. 7.EquipmentAllowance. For DME equipment services before 1/1/2012 that are auditable, not rentals (RR), and have no provider contract already applied: if the charge is under50, no action; otherwise dispatch byMsrpInvoiceCode—"M"→FGat 85%,"I"→SBat 125% before 4/1/2006 elseFGat 140%, anything else → error"<ServiceCode> Invalid MSRP/Invoice Flag". If no MSRP/invoice amount exists, compute the standard fee schedule and disallow withFZif still unreduced. 8.CrossServiceAudit2. For each auditable service with a positive allowed amount and a resolved CPT record:CheckGlobal(global-surgery-period checks against history and same-bill services, applyingCD/CC/CAadjustments, unless modifiers80/82are present) andCheckThreePTRule(for CPT disallow code3PT, allows the first three already-paid-or-highest-amount services and fully disallows the rest withFJ). For Standard/OutpatientHospital bills,CheckBundlingadditionally runs on remaining positive-allowed services (excluding physical-medicine codes97001–97799and ASCSGservices), applyingCBbundling adjustments unless override modifiers59/XE/XP/XS/XUare present (which instead generate a bundle-override warning). 9.FinalAuditChecks. Runs, in order: -CheckDeniedClaim— for a denied claim (excludingR0001/N0001/N0002and IME services), disallows remaining auditable services fully withDF, orDBif there are no medical conditions or any decision is missing a final denial reason. -CheckForInelligbleProviders— for each positive-allowed auditable service, checks servicing-provider ineligibility periods covering the service date; disallows fully withTDby default,TYfor reasonNPN, orTS(also forcingReauditCode = "X") for reasonCOL. -CheckForInelligbleServices— looks up a disallow code from the national drug record (pharmacy) or the resolved service (non-pharmacy); if present, creates a full adjustment and setsReauditCode = "X". -CheckForDuplicates— compares each service against historical (SQL-002) and current bill services using type-specific matching rules (inpatient exact/partial match on provider+admission date+service+charge; non-hospital exact/provider/date/service/charge, aWMILE-specific audited-charge comparison, pharmacy same-date-NDC match, and same-date service/NDC+charge matches), setsOriginalBillCodeto"D"(definite) or"U"(possible) and linksOriginalBillID/OriginalServiceID, and reduces payment by the prior-paid amount using adjustment codePA(fully paid previously),PB(no prior allowed amount found), orPC(prior payment exists but original incomplete) (BR-021). -CheckForLateFiling— for original (non-rebill), non-Worker-Reimbursement, positive-allowed services of eligible types (Ambulance/Dental/Equipment/Medical/Pharmacy/Revenue/VocRehab), applies era-based reductions or disallowance using the later of service date/service end date: before 4/1/2006 (or any Vocational Rehabilitation date), 10% reduction per month after 60 days (FD), with Vocational Rehabilitation fully disallowed (SO) after 180 days; 4/1/2006–6/30/2007, a compounding 10% monthly reduction after 90 days (FD); after 6/30/2007, full disallowance (FD) after 365 days (BR-020). -CheckForNonMCOProvider— for a claim with mandatory-MCO status"Y", a positive-allowed, mandatory-MCO service with no active withhold, a service date more than 14 days after the MCO effective date, and a non-anesthesiology (AN) servicing provider: full-chargeMGadjustment (BR-019). 10.MCOWithhold. For services flaggedIsMCOWithholdby MCO determination: if the provider-admin-fee flag applies and the service is not NDC-only, checks service-level MCO fee exemptions for the plan/date and clears the withhold flag if exempt. If still eligible, determines the withhold rate (service-specific admin-fee rate when under1, else the defaultclsMCOProviderTypeAdminFeefor the plan/provider-type/date) and setsMcoAdminFeeAmount = Rate * AllowedAmountandMcoAdminFeeRate = Rate. 11.CheckVoidedClaim. IfBill.Claim.ClaimStatus.IsVoid: disallow all services fully withWG, warn"Bill belongs to voided claim", and returnFalsefor this rule (BR-018). 12.CompleteAudit. For each service, verifyAllowedAmount = ChargeAmount + TotalAdjustmentAmount; on mismatch, log detail and error"<serviceCodeOrNDC> Error Computing Allowance - call Help Desk". Reset any remaining non-blankReauditCodeto a single blank, default null MCO admin-fee amounts to0, default blank service type codes to"U", and default null fee schedule amounts to0. Recompute the bill's audit totals (charged, allowed, MCO admin fee) and setBill.BillTotalAmountto the total charged amount. ReturnFalseif any mismatch error was generated. 13.ValidateAdmitTypeCode. ForInpatientHospitalbills, requiresAdmitTypeCodein1,2,3,4,5,9; if invalid, message"Invalid Admit Type Code({0})."and disallow all services withGY(BR-007).
AuditBill stops the "Audit Bill" trail group and returns ErrorCount = 0 — a False return from any handler above (steps 2, 3, 11, 12, 13) contributes to that error count and is surfaced to BillAuditEngine as FailAuditCheck.
Process flow¶
flowchart TD
Start([clsBillAuditor.AuditBill invoked]) --> Merge[UpdateMergeClaimID]
Merge --> DRG{DRG required<br>and valid?}
DRG -->|No| DisallowGS([Disallow all: GS]) --> Diag
DRG -->|Yes| Diag[ValidateDiagnosisandProcedureCode]
Diag -->|Invalid| DisallowGW([Disallow all: GW]) --> Admit
Diag -->|Valid| Basic[ComputeBasicAllowance per service]
Basic --> Radio[MultipleRadiography]
Radio --> Contracts[ProviderContracts]
Contracts --> Equip[EquipmentAllowance]
Equip --> Cross[CrossServiceAudit2:<br>global, 3PT, bundling]
Cross --> Final[FinalAuditChecks:<br>denied claim, ineligible provider/service,<br>duplicates, late filing, non-MCO provider]
Final --> Withhold[MCOWithhold]
Withhold --> Void{Claim voided?}
Void -->|Yes| DisallowWG([Disallow all: WG]) --> Complete
Void -->|No| Complete[CompleteAudit:<br>verify totals, recompute bill totals]
Complete --> Admit[ValidateAdmitTypeCode]
Admit -->|Invalid| DisallowGY([Disallow all: GY])
Admit -->|Valid| Done([Return ErrorCount = 0])
DisallowGY --> Done
Failure and edge-case behavior¶
DisallowAllServicesremoves prior adjustments and applies a full-charge disallowance to every service, so an early bill-level failure (DRG, diagnosis/procedure, voided claim, admit type) overwrites any per-service work already done byComputeBasicAllowance,ProviderContracts, and later steps for that run.ComputeFeeScheduleAllowance/AlterFeeSchedulelayer many date-conditional percentages (NP/PA reduction era, surgical-assistant modifier era, package-price ratio); a service can match more than one adjustment path in sequence, and only the last-applied non-zero adjustment is persisted, since each helper checks for a positive computed amount before generating its own adjustment.*CheckForProviderContractPackagePriceonly applies to outpatient-hospital bills with exactly one procedure and an MCO-enrolled billing provider; all other bill shapes skip package pricing even if the billing provider has service contracts.- The three-point rule (
CheckThreePTRule) and bundling (CheckBundling) both depend on accurate historical data from SQL-002; missing or stale historical bill data silently allows services that should have been reduced.* CheckForLateFilingexplicitly exempts Worker Reimbursement bills and rebills (non-"O"OriginalBillCode), so late-filed rebills are never reduced by this rule.- A
AllowedAmount <> ChargeAmount + TotalAdjustmentAmountmismatch inCompleteAuditis treated as a hard environment-level data error ("...call Help Desk"), not a business-rule warning, and fails the entire rule execution.
Related documentation¶
Note: Statements marked with
*were inferred from code structure, naming conventions, or contextual evidence where direct confirmation was not available in source artifacts.
Sources¶
Business\SAIF.Business.Claim.Bill.AutomatedAudit\AuditUtilities\clsBillAuditor.vbBusiness\SAIF.Business.Claim.Bill.AutomatedAudit\AuditUtilities\clsAuditCalculator.vbBusiness\SAIF.Business.Claim.Bill.AutomatedAudit\AuditUtilities\clsClaimBillHistory.vbBusiness\SAIF.Business.Claim.Bill.AutomatedAudit\AuditUtilities\clsBillAuditUtility.vb