Skip to main content

Best practices

Best Practices - Business Insurance

Operational guidelines for developers building AI/RAG/agent applications in the B2B insurance domain. Each practice includes rationale and concrete do/don't examples.

---

Structure the RAG corpus by insurance line of business

Rationale: Generalist language models mix terminology from different insurance lines (liability, fire, marine, cyber) with inconsistent results. A corpus segmented by line ensures precise retrieval.

Do: Tag every chunk with metadata branch (e.g., general_liability, fire, cyber), language, jurisdiction, and year. Use metadata filters in retrieval to restrict context to the line relevant to the query.

Don't: Mix regulatory documents (policy wordings, special conditions, IVASS circulars) with marketing material in a single vector index without filtering.

Explicitly model the policyholder, insured, and beneficiary as distinct entities

Rationale: In B2B insurance, the three roles are often distinct legal entities (e.g., a company director, the company itself, and a lender as beneficiary). Conflating them causes critical errors in claims handling and regulatory reporting.

Do: Define separate entities in the data model with explicit relationships. Validate at the application level that the beneficiary is an existing legal entity for Key Man policies or policy assignments.

Don't: Model the "customer" as a single omnibus entity; claims indemnity logic requires the precise distinction of roles.

Implement an immutable audit trail for all claims lifecycle events

Rationale: IVASS regulations (Regulation 40/2018) and Solvency II mandate complete traceability of settlement decisions. In disputes, the event log is documentary evidence.

Do: Use event sourcing or an append-only log for every claim state transition (notification → investigation → survey → settlement/rejection). Include timestamp, responsible actor, and justification for each transition.

Don't: Update claim status in-place without history; implement systems that allow retroactive deletion of events.

Validate GDPR/privacy compliance for health data in accident claims

Rationale: The insured's health data (medical records, test results, diagnoses) are special category data under GDPR Art. 9. Processing requires explicit consent or a specific legal basis (Art. 9 §2(b), (c), (f)).

Do: Physically separate health data from personal/policy data. Apply encryption at rest and in transit. Implement documented retention policies. Keep the processing register up to date.

Don't: Include diagnoses or medical records in unprotected API payloads; log health data in standard application logs; transmit health data to third parties (including AI providers) without a Data Processing Agreement (DPA).

Apply rate limiting and circuit breakers to AML/PEP blacklist check integrations

Rationale: AML (Anti-Money Laundering) and PEP (Politically Exposed Persons) checks required by EU and national regulations for insurance intermediaries rely on external data provider APIs (e.g., World-Check, Dow Jones). These services have SLAs and per-call costs.

Do: Cache verification results (TTL 24-48h), implement circuit breakers for graceful degradation when the service is unreachable, log every check for compliance purposes.

Don't: Call verification services for every micro-interaction; have no fallback when the external provider is offline (causing total onboarding process blockage).

Segment permissions by role in the claims management system

Rationale: The claims management system involves roles with different authorisations: junior adjuster (restricted access for claims < €5,000), senior adjuster, external surveyor (read-only document access), claims manager (payment approval), management (aggregate reporting).

Do: Implement granular RBAC (Role-Based Access Control) with delegatable authority limits by amount. Log every access to claim data. Implement Maker-Checker for payments above the threshold.

Don't: Grant uniform access to all staff; assign edit permissions to read-only users or vice versa.

Manage structured contractual formats (JSON/XML) for Solvency II Quantitative Reporting Templates

Rationale: The obligation to submit QRTs to IVASS requires the production of tables in XBRL or CSV format per EIOPA technical specifications. A manual system is error-prone; an automated system reduces compliance costs.

Do: Define an internal data model aligned with the EIOPA XBRL taxonomy. Implement automatic transformation from internal management data to QRTs. Validate the produced file before submission.

Don't: Produce QRTs through manual Excel exports; fail to version the XBRL schemas (which change with each EIOPA update).

Model policy renewal as a separate workflow from the main policy lifecycle

Rationale: Policy renewal is not a simple extension but a new contract with potentially varying conditions, limits, and premiums. In the data model, each annual period has its own validity, technical reserves, and claims history.

Do: Create an AnnualPeriod (or PolicyPeriod) entity linked to the parent Policy. Implement the renewal process as a workflow: renewal proposal → acceptance → new policy issuance → link to prior period.

Don't: Overwrite the existing policy with new conditions; lose the historical link between periods needed for claims history calculation.

Use ANIA/IVASS nomenclature for insurance line-of-business codes

Rationale: IVASS and ANIA use a standardised coding system for insurance lines (Classes I-VII for life; Classes 1-17 for non-life). Alignment ensures interoperability with regulatory systems and industry databases.

Do: Map every insurance product to standard IVASS line codes. Use the codes in Solvency II QRTs and communications with the authority. Include codes in contractual document metadata.

Don't: Use internal codes not mapped to IVASS standards; create proprietary taxonomies incompatible with regulatory reporting systems.

Implement a validation pipeline for AI-generated contractual clauses

Rationale: Generative AI systems can produce grammatically correct but legally invalid clauses, inconsistent with standard policy wordings, or non-compliant with IVASS circulars. Human validation by an underwriter or legal expert is essential.

Do: Implement a pipeline with steps: AI generation → underwriter review → legal approval → publication. Maintain a register of approved standard clauses (clause library) as the basis for AI generation.

Don't: Publish AI-generated clauses without human review; use AI to modify general policy conditions without a formal approval process.

Implement intelligent caching for high-traffic policy documents

Rationale: General policy conditions, IPID documents, and special conditions are frequently accessed by quotation and comparison systems. Caching reduces latency and load on document management systems.

Do: Implement CDN caching for policy condition PDFs with TTL tied to document version (cache busting on version ID). Use pre-signed URLs with expiry for premium documents accessible only to authenticated policyholders.

Don't: Serve policy condition documents without caching; use infinite cache without invalidation on version change (risking serving outdated terms).

Separate actuarial calculation logic from application business logic

Rationale: Actuarial models for technical reserves, SCR, and pricing change frequently (mortality table updates, model recalibrations, Solvency II regulatory changes). Clean separation facilitates updates without impacting the core system.

Do: Expose actuarial engines as microservices or versioned libraries with stable APIs. Version models and maintain backward compatibility for historical recalculation. Document every model change with its actuarial justification.

Don't: Hardcode actuarial formulas in business logic; mix calculation logic with presentation logic.

---

Note: This document is technical and informational in nature for software developers in the insurance sector. It does not constitute legal or actuarial advice. For specific regulatory obligations, refer to current IVASS regulations and EIOPA circulars.