ArvoAgentHub

Quantidade excessiva de cateter venoso periférico (ambulatorial)

Overview

Flag ambulatorial invoices with more than one peripheral venous catheter. The excess is distributed across items using the mais_baratas strategy (cheapest items denied first) via the ExcessiveAmountRule template.

Architecture

Field Value
Name Quantidade excessiva de cateter venoso periférico (ambulatorial)
Agent ID AI012
Version 0.0.0
Nature tech
Layer —

Inheritance

ExcessivePeripheralCatheterPetroRule → ExcessiveAmountRule → BaseAgent

Core Functionality

  1. load_artifacts
  2. prepare_data
  3. rule_assessment

Business Rules

Pertinência da cobrança

Constantes:

  • LIMIT_PER_FATURA = 1

Usage

from agents.excessiveperipheralcatheterpetrorule import ExcessivePeripheralCatheterPetroRule

rule = ExcessivePeripheralCatheterPetroRule()
violations_df = rule.rule_assessment(claims_df)

Configuration

Sem parâmetros configuráveis identificados.

Input Requirements

Column Type Description
EVENT_COLUMNS.id - -
EVENT_COLUMNS.id_fatura - -
EVENT_COLUMNS.id_evento - -
EVENT_COLUMNS.evento - -
EVENT_COLUMNS.vl_pago - -
EVENT_COLUMNS.qt_paga - -
EVENT_COLUMNS.vl_unitario_pago - -
EVENT_COLUMNS.dt_atendimento - -

Output Format

Glosa DataFrame Columns

Column Description
agent_id AI012
version 0.0.0
id_arvo Original record ID
vl_glosa_arvo Glosa value
qt_glosa_arvo Glosa quantity
score_arvo Confidence score
motivo_glosa_arvo Detailed reason in Portuguese
motivo_glosa_ANS ANS standard code
data_dict JSON metadata with calculation details

Error Handling

  • DataFrames vazios retornam estrutura vazia com colunas obrigatórias.
  • Colunas ausentes geram warning mas não causam crash.
  • Conversões numéricas usam errors="coerce" para evitar falhas.