North Carolina surplus lines filings

Insurance United States

Checks a surplus lines brokerage’s batch of policy transactions before it’s sent to the North Carolina Surplus Lines Association, then sums its premium and fees by transaction type, coverage code and tax status: every transaction against the fields and business rules of NCSLA’s batch upload guide, and every backout, reinstatement and likely duplicate against what the brokerage has already filed.

From the North Carolina Surplus Lines Association’s Agent Batch Upload Guide, updated May 2025, and its current coverage and tax status codes.

North Carolina surplus lines filings
Rules, test data, expected totals and a pipeline snapshot. Zip, 83 KB.
Download the template

See it in Quantemplate

The pipeline

The North Carolina surplus lines filings pipeline in Quantemplate, showing 11 of its 21 stages: Prepare this batch, Prepare previous filings, Batch and previous filings, Transaction keys, Matching transactions, Join matching transactions, Filed transactions in force, Policies, Covers, Transaction versions and Transaction insurers. The Uploads tab lists the two test files: the previous filings, uploaded to stage 2, and the batch, uploaded to stage 1.

The validations

The test run’s Validations tab: the one rule set, 01 Batch transactions in the Check this batch stage. Its bar is mostly red for failures, with a little yellow for warnings and green for rows that pass, as the test batch is built to fail every rule.

Premium by coverage

Stage 20’s totals for the clean data by coverage code: 12 rows, one for each coverage code in the batch, with its coverage group and name, the number of transactions, the premium and the company fees. Each code has one transaction. The largest premium is $26,800 for commercial aircraft, code 9000. Returned premium, cancellations and backouts show as negative amounts, such as −5,180 for a lawyers’ professional liability cancellation, code 7002.

What it checks

42 rules 35 Fail 7 Warning

A rule set to Fail marks its rows as failed, and any failure blocks Auto Export if you set it up. Warnings are only reported. Validation never removes a row. Every rule and its formula is listed in VALIDATIONS.md in the download.

How the pipeline works

  1. Stages 1–2 Prepare this batch and previous filings Detect headers, tidy each file (trim, collapse spaces and upper-case) and mark where each row came from
  2. Stage 3 Batch and previous filings Stack the two files
  3. Stage 4 Transaction keys Set the batch date, work out each date’s year, month, day and day number, and key each row by its policy and transaction details, its coverage and insurer, and its transaction ID
  4. Stages 5–7 Matching transactions Count the filed and batch originals and backouts with the same policy and transaction details, join the counts to each row, and find the filed transactions that haven’t been backed out
  5. Stages 8–11 Policies, covers, versions and insurers Each policy’s last filed transaction and cancellation, and its dates in the batch, each coverage and insurer’s last filed transaction, the versions of each transaction’s rows, and the rows for each insurer
  6. Stages 12–15 Joins Join all four to each row
  7. Stage 16 Check this batch Remove the previous filings, turn blank counts into 0, label the transaction type, tax status and coverage, and run the rules
  8. Stages 17–18 Batch checked and transactions The checked batch, and one row for each transaction with its insurers counted
  9. Stages 19–21 Totals Count the transactions and add up the premium and company fees by transaction type, coverage code and tax status

What’s in the download

The guide isn’t included. Download the Agent Batch Upload Guide from NCSLA, with its current coverage codes and tax status codes.

Build it

  1. Install the Quantemplate skills, version 1.0.0 or later, if you haven’t already. Then unzip the download.
  2. With Claude in Chrome signed in to Quantemplate, ask Claude Code:
    Build the North Carolina surplus lines filings pipeline from the nc-surplus-lines-filings folder.
  3. Claude creates the datasets and stages, runs the test data and checks every rule’s result. This takes around 3 minutes.

The agent builds through the Quantemplate app’s own API in your browser. That API isn’t published, so if a release changes it, the build stops and tells you what went wrong. Review what the agent builds before you rely on it.

Using a real batch

Contact the Quantemplate support team, or use your AI agent, to build custom logic for your use case.

Limits