Processing Error
{{ error }}
Pipeline Warnings
{% for err in errors %}{{ err }}
{% endfor %}
Request Info
Approval No
{{ ui_output_1[0] }}
Request Date
{{ ui_output_1[1] }}
Type
{{ ui_output_1[2] }}
Processed
Patient Demographics
Full Name
{{ ui_output_2[0] }}
DOB / Age
{{ ui_output_2[1] }} ({{ ui_output_2[3] }}y)
Gender
{{ ui_output_2[2] }}
ID/Iqama
{{ ui_output_2[4] }}
Nationality
{{ ui_output_2[5] }}
Insurance Info
Member ID
{{ ui_output_3[0] }}
Plan Type
{{ ui_output_3[1] }}
Health Dec.
{{ ui_output_3[2] }}
Status
{{ ui_output_3[3] | default('Active') }}
Provider Info
Facility
{{ ui_output_4[0] }}
Physician
{{ ui_output_4[1] }}
Specialty
{{ ui_output_4[2] }}
License No.
{{ ui_output_4[3] }}
Service Decisions
{% if ui_output_9 is string and ui_output_9 %} {{ ui_output_9 }} {% elif ui_output_9 and ui_output_9[0] is mapping and ui_output_9[0]['Category'] %} {{ ui_output_9[0]['Category'] }} {% endif %}
{% for decision in ui_output_8 %}
{% set is_approved = 'Approved' in decision['Decision'] and 'Disapproved' not in decision['Decision'] %}
{% if decision.get('Category') %}
{% if not is_approved and decision.get('Rejection Code') %}
{% endif %}
{% if decision['Justification'] or decision.get('layer_trace') %}
{% endfor %}
{{ decision['Service Name'] }}
#{{ loop.index }} Code: {{ decision['Internal Code'] }} {% if decision.get('Category Description') %} | {{ decision['Category Description'] }}{% endif %}
{{ decision['Category'] }}
{% endif %}
{{ decision['Requested Qty'] | default(1) }}
Requested
{% if is_approved %}{{ decision['Approved Qty'] | default(decision['Requested Qty'] | default(1)) }}{% else %}0{% endif %}
Approved
{% if is_approved %}A{% else %}D{% endif %}
Status
{{ decision['Rejection Code'] }}
Rej. Code
{% if decision['Justification'] %}
{% endif %}
{% if decision.get('layer_trace') %}
{% endif %}
{% endif %}
Justification
{{ decision['Justification'] }}
Decision Audit Trail
{% for trace in decision['layer_trace'] %}
{% set trace_status = trace.get('result', 'skip') | lower %}
{% if 'pass' in trace_status or 'approved' in trace_status %}
{% set trace_class = 'pass' %}
{% elif 'fail' in trace_status or 'reject' in trace_status or 'disapproved' in trace_status %}
{% set trace_class = 'fail' %}
{% else %}
{% set trace_class = 'skip' %}
{% endif %}
{{ trace.get('layer', trace.get('name', 'Layer')) }}
{% endfor %}
Clinical Assessment
Diagnosis Codes
{{ ui_output_5[0] | default('No diagnosis codes available') }}
Clinical Summary
{{ ui_output_5[2] | default('No clinical summary available') }}
Supporting Investigations
Radiology Findings
{{ ui_output_6[0] | default('No radiology findings available') }}
Laboratory Results
{{ ui_output_6[1] | default('No laboratory results available') }}
Past Medical History & Utilization Analysis
Historical Analysis
{{ ui_output_7 | default('No historical data available') }}
Communication Messages
{% if ui_output_0 %}
{% if ui_output_0 is mapping %}
{% if ui_output_0.english %}
{% endif %}
{% if ui_output_0.arabic %}
{% endif %}
{% elif ui_output_0 is iterable and ui_output_0 is not string %}
{% if ui_output_0[0] %}
{% endif %}
{% if ui_output_0[1] %}
{% endif %}
{% else %}
{% endif %}
{% else %}
No messages available
{% endif %}ملخص خدمة العملاء (Customer Service Agent Summary)
{% if ui_output_10 %}
{% else %}
No customer service summary available
{% endif %}Provider Response Messages
{% for decision in ui_output_8 %}
{% set is_approved = 'Approved' in decision['Decision'] and 'Disapproved' not in decision['Decision'] %}
{% if decision.get('Provider Message') or decision.get('Justification') %}
{% endfor %}
{% if ui_output_8 | length == 0 %}
{{ decision['Service Name'] }}
{% if is_approved %}Approved{% else %}Disapproved{% endif %}
{% if decision.get('Message Code') %}
MSG: {{ decision['Message Code'] }}
{% endif %}
{% if not is_approved and decision.get('Rejection Code') %}
{{ decision['Rejection Code'] }}
{% elif is_approved %}
Approved
{% endif %}
{{ decision.get('Provider Message', decision.get('Justification', 'No message available')) }}
{% endif %}
No provider response messages available
{% endif %}