Understanding recurrence in financial transactions is crucial for categorizing and predicting future cash flows. The Recurrence API allows you to identify and categorize recurring patterns found in the transactions of an account holder, such as periodic payments or subscriptions. These patterns are classified into a recurrence type and a recurrence group that encodes detailed information about its periodicity, transaction counterparty and amount metrics.

Understanding recurrence

We employ a machine learning model to identify recurring transactions and group them together. This model is designed to detect patterns of recurring transactions while filtering out noisy data, such as frequent transactions that may have similar periodicity by chance rather than being truly recurring. The model is able to categorize transactions into a recurrence type and group noncontiguous transactions, so even if there is a gap in a pattern - say missing a month on a monthly subscription over a year, it is still recognized.

Recurrence groups

A recurrence group is a grouping of transactions with the same recurring pattern. Every transaction in a recurring pattern shares the same counterparty, but not necessarily amounts. This means that:

  • We might have transactions with different amounts in the same recurring group.
  • There could be multiple recurrence groups per counterparty/general category.
  • We could have non-recurrent transactions with a counterparty (e.g Amazon Web Services) even if there’s already transactions with the same counterparty belonging to a group.

Example usage

SDK
1from ntropy_sdk import SDK
2
3sdk = SDK("cd1H...Wmhl")
4for i in range(1,5):
5 sdk.transactions.create(
6 id=f"netflix-{i}",
7 description=f"Recurring Debit Purchase Card 1350 #{i} netflix.com Netflix.com CA",
8 amount=17.99,
9 currency="USD",
10 entry_type="outgoing",
11 date=f"2021-0{i}-01",
12 account_holder_id="35b927b6-6fda-40aa-93b8-95b47c2b2cad",
13 )
14
15 sdk.transactions.create(
16 id=f"netflix-{i}",
17 description=f"Payment #{i} from netflix.com Netflix.com CA",
18 amount=1000,
19 currency="USD",
20 entry_type="incoming",
21 date=f"2021-0{i}-01",
22 account_holder_id="35b927b6-6fda-40aa-93b8-95b47c2b2cad",
23 )
24
25recurring_groups = sdk.account_holders.recurring_groups(
26 "35b927b6-6fda-40aa-93b8-95b47c2b2cad"
27)