Credit analysis as a lender does it: the five Cs
Every credit officer asks the same five questions, and every one of them can be answered badly with a clean-looking number. Read the cash flow before you trust the ratio
A merchant's wallet shows average credits of ₦3,982,997.66 a month. The loan it asks for has an instalment of ₦255,979.44, which is 6.4% of those credits. In the same wallet's history the lender's own book shows an earlier loan with instalments of ₦1,314,588.59 a month still to run. Which statement is right?
Credit analysis is the work a lender does between “someone asked for money” and “someone signs”. You met its pieces in module 1: the bureau report in credit data in Nigeria, the economics of expected loss in the economics of a loan and the stages of the loan lifecycle. This chapter puts them in the order a credit officer uses them, for a borrower who is a business, and ends with the one-page document that records the judgement.
The lab runs on Owoleaf’s loan book: a merchant with an SME (small and medium-sized enterprise) application, and the wallet history Owoleaf holds on it. Northmere and Tallowmere are the example in the prose. Tallowmere’s request is the ₦4,000,000 over six months you met in loan products, priced on the lab’s illustrative SME terms (3.5% a month on the reducing balance, so six instalments of ₦750,672.83) to keep the numbers comparable. It is not an offer. The data in the lab is Owoleaf’s, not Tallowmere’s.
The five Cs
The five Cs are an old checklist, and its age is its value: each C names a question that a lender once lost money by not asking.
| C | The question | Where the evidence comes from | How the answer goes wrong |
|---|---|---|---|
| Character | Will they repay if they can? | Bureau report, the lender’s own history with them, references, how they behaved on earlier debts | A thin file read as a bad file; a good score hiding a loan the bureau has not seen |
| Capacity | Can they repay from cash flow? | Bank and wallet statements, accounts, tax records | Turnover read as profit; one good month read as a trend |
| Capital | What have they put in themselves? | Balance sheet, owner’s equity, savings | Equity taken from the applicant’s own claim; borrowed money counted as capital |
| Collateral | What can the lender take if they do not repay? | Security, guarantees, assets | A valuation that assumes a forced sale fetches the market price |
| Conditions | What is the money for, and what is the market doing? | Loan purpose, sector, season, the terms offered | A seasonal business assessed in its busiest month |
Two of them are about the person: character and capital. Two are about the money: capacity and collateral. Conditions is about the world. Capacity gets most of the work, because cash flow is the first source of repayment. Collateral is the second source: it is what you fall back on when capacity has failed, and a lender that lends on collateral alone has quietly become a pawnbroker with a legal department.
The Cs are not scored and added. A strong character does not buy back a missing capacity. The analysis is a set of five answers, each with its evidence and its gaps, and the memo at the end is where they are put side by side.
Character: what the record says, and what it cannot
Character, in a lender’s use of the word, is a record and not a verdict. You are asking what the borrower has done with money before.
The bureau report is the main source. In the lab, a report is a snapshot taken on the application date: score, number of open loans and outstanding balance, delinquencies in 12 months, worst days past due in 24 months, enquiries in 90 days, and years of history. Credit data in Nigeria explains what those fields are and how a thin file arises. Three habits make the reading better.
Read the whole report, not the score. A score of 743 sits above every cut-off in the lab. The same report also says 3 open loans and ₦796,968.00 outstanding, which is a fact about how stretched the borrower is. A score is a summary, and a summary can hide the line that matters.
Add what the bureau cannot know. The lender’s own book is the best record it has. In the lab’s merchant, the 25 June report says 3 open loans and ₦796,968.00 outstanding. Owoleaf’s own book also shows a loan of its own, ₦3,683,000.00, with two instalments still to fall due, and the report does not say whether it counts it. A report is a view of what lenders reported by the report date, and a lender’s own system is always fresher. Look in your own tables first.
Do not treat a thin file as bad character. A thin file means no history, which says the bureau knows nothing, not that the borrower failed. The lab’s merchant with 30 days of wallet history and a score of 604 shows the opposite risk: a short record and a borderline report together tell you very little, and a lender that fills the silence with optimism has made a choice and not a finding.
Character also has a conduct side: do the numbers in the application match the statements, and did the applicant answer questions plainly? Those are interviews and reference checks, and no lab table captures them. The memo records what was checked and by whom.
Capacity: reading cash flow
Capacity is the question of whether cash will arrive in the right amounts at the right times. For a business, the source is its bank or wallet statements. Open banking in the Payments course covers how a lender can obtain them electronically with consent; here the question is how to read them.
Turnover is not income
A statement shows credits in and debits out. For a merchant, credits are mostly sales proceeds, which is turnover: the money the business takes in before it pays for what it sold. The lender cares about the cash left after the business pays for stock, staff, rent, fuel and tax. That is the margin, and a statement does not show it. Most mistakes in capacity analysis are this one: dividing by turnover and calling it affordability.
A second mistake is counting every credit as a sale. Strip out, before you add anything up:
- transfers from the owner’s own accounts, which are the owner’s money, not the business’s;
- loan proceeds, including from the lender you are analysing;
- reversals and refunds from suppliers, which are not sales;
- transfers between the business’s own accounts, which appear as a credit in one and a debit in another.
Circular transfers are the sharpest version. An applicant can inflate credits by moving money in a loop through accounts it controls, and a statement then shows a business larger than it is. The test is to look at who the money came from, how often the same counterparty appears and whether the same amount goes out soon after it came in.
Windows, trend and volatility
One total hides the shape. The lab splits the months before the application into 30-day windows, ending the day before it. The windows are measured back from the application date, not by calendar month, so that every window has the same length and nothing after the application leaks in. A window that starts before the wallet was opened is not a zero window. It is a window that did not exist, and the code marks it as not full.
For the lab’s merchant, three full windows give ₦4,375,544.00, ₦4,173,412.00 and ₦3,400,037.00 of credits. Their average is ₦3,982,997.66. The newest window is 22.3% below the oldest (3,400,037 ÷ 4,375,544 = 0.777). A single average would have shown nothing. A falling trend does not decide the case, but it is a question for the memo: is the business shrinking or is this the quiet season?
Volatility says how reliable the cash is. The lab uses the coefficient of variation (CV): the standard deviation of weekly credits divided by their mean. A CV of 0.32 across 13 weeks means a typical week moves about a third away from the average. The lowest week was ₦302,399.00 against a mean of ₦927,738.15. An instalment due that week would have fallen on a business taking a third of its normal cash. A lender with a monthly instalment due on a fixed day should know what the worst week looks like.
Window length is a trade-off. A month is long enough to smooth a few big payments and short enough to show change. Under three full windows there is no trend and no volatility to speak of, and the analysis should say so and ask for a longer statement.
The balance floor
A wallet or account balance tells you what the business keeps. The merchant in the lab has credits of about ₦4,000,000 a month and payouts of almost exactly the same, so its wallet is swept nearly empty: the lowest balance in the history is ₦90.83. That is not a sign of distress. The wallet is a pipe, not a savings account. But it means the balance cannot be offered as capital or as a buffer, and the lender should not read a wallet balance as the business’s cash. Where the payouts went (suppliers, staff, the owner) is not in the wallet either.
Affordability and debt-service ratios
Affordability turns capacity into a test. Two ratios do most of the work.
Debt service as a share of inflow is the instalments due in a month divided by average credits. It needs no assumption about margin and it is a floor for how much of the business’s cash the debt will claim.
The debt service coverage ratio (DSCR) is cash available for debt service divided by the debt service due in the same period. A DSCR of 1.0 means the cash exactly covers the instalments. A lender sets a target above 1 so that one weak month does not break the loan. 1.25 is a figure often used in teaching examples, and the lab uses it as an illustration, not as a rule: each lender sets its own.
Cash available is where the margin comes in. The lab uses an assumed margin of 10%, labelled illustrative, and shows what changes if it is 5%, 20% or 40%. In a real file the margin comes from the accounts: revenue less cost of sales and operating costs, read from at least a year of them.
The pieces for Tallowmere’s request can be redone by hand. The instalment is ₦750,672.83. To reach a DSCR of 1.25, Tallowmere needs cash available of 1.25 × 750,672.83 = ₦938,341.04 a month. What monthly credits does that take?
| Assumed margin | Credits needed a month | Working |
|---|---|---|
| 5% | ₦18,766,821 | 938,341.04 ÷ 0.05 |
| 10% | ₦9,383,410 | 938,341.04 ÷ 0.10 |
| 20% | ₦4,691,705 | 938,341.04 ÷ 0.20 |
| 40% | ₦2,345,853 | 938,341.04 ÷ 0.40 |
The table is the useful shape of the answer. It does not say Tallowmere can or cannot afford the loan. It says what turnover the loan needs at each margin, and the credit officer compares that with the statements and the accounts. The same table with a falling month, or with a second loan’s instalment added to 750,672.83, moves every row.
Stacking is borrowing again while an earlier loan is still running. It matters more than a score. In the lab’s merchant, the first loan’s instalment is ₦1,314,588.59, the new one is ₦255,979.44, and together they are ₦1,570,568.03 a month, 39.4% of average credits. The new loan alone is only 6.4%. Add the bureau’s 3 open loans, whose instalments are not in the report because bureaus mostly hold balances, and the true burden is higher still. Always ask for a list of every obligation, and always check your own book.
Capital, collateral and conditions
Capital is what the owners have put in. A lender wants to see that the business can absorb a bad quarter without the lender’s money being the only cushion. It comes from the balance sheet, and a wallet history contains none of it. The lab’s memo says so in one line and asks for accounts. Take care with the opposite error: borrowed money in the account is not capital. A statement showing ₦4,000,000 after a loan arrived is a loan, not equity.
Collateral is the second way out. The lab’s SME product is unsecured and repaid by a standing instruction on the borrower’s accounts. For a bank like Northmere the options include stock, receivables, equipment, property and the personal guarantee of the owner. Each has a failure mode. Stock held by a pharmacy has an expiry date and may be controlled. Receivables are only worth what customers pay. A guarantee is worth the guarantor’s assets, which the lender has to check. A valuation is a market price, and a lender that has to sell fast gets less. Lending against collateral you cannot practically take is an unsecured loan with extra paperwork.
Conditions are the outside facts: the loan’s purpose, the sector, the season, the terms. Tallowmere asks for working capital for a stock build. The stock cycle in the example is about 45 days, so the first instalment, due 30 days after payout, falls before the stock has sold. That is a conditions finding, and it points at the loan’s shape (a later first instalment or a bullet repayment) as much as at the yes or no. Conditions also include the lender’s own: a loan priced and sized to the borrower’s cycle is a better loan than the same money on a standard schedule.
The credit memo
A credit memo is the one-page record of the analysis. It exists so that Chidubem can decide without redoing Oyebola’s work, so that an auditor or a regulator can see later why the loan was made, and so that Oyebola has to state what she does not know. A usable memo has six parts:
- The request: amount, tenor, purpose, instalment, rate and fees, repayment source.
- The five Cs, each with its evidence and its gaps.
- The numbers: average and latest cash flow, volatility, debt service, DSCR and the margin it rests on, shown with their sensitivity.
- The risks, in order of importance, with what would mitigate each.
- A recommendation: approve, approve with conditions, decline or defer, with the conditions stated (a document to obtain, a smaller amount, a different first instalment date).
- Sign-off: who analysed, who approved, the date and the data’s as-at date.
The most useful line in the memo is the gap. When the lab’s third merchant has only 30 days of history, its memo does not produce a DSCR: it says the history is too short and names the missing statements. A number there would have looked like analysis and been a guess. A memo that always has an answer is a memo that has stopped being honest.
A memo also keeps a lender consistent. Two officers who analyse the same file should find the same facts. They may weigh them differently, and the memo shows where.
What the data permits, and what the rules say
Using a customer’s statements needs their agreement. Law-firm summaries of the Nigeria Data Protection Act 2023 say section 26 puts the burden of proving a data subject’s consent on the data controller, and that silence or inactivity is not consentas of 2026-11. Those points come from summaries, and this build did not read the Act’s text, so check them there (a copy is hosted by Nigeria’s national CERT). For a lender, the working rule is to record which statements the applicant agreed to share, for which purpose, when and with what wording, and to use them for that purpose only. Module 2’s chapter on alternative data returns to what a statement can lawfully be used for.
On the duty to check affordability, commentary on the Digital, Electronic, Online or Non-Traditional Consumer Lending Regulations 2025 of the Federal Competition and Consumer Protection Commission (FCCPC), and on its companion guidelines, says a lender must assess a consumer’s ability to repay before lending. The commentary disagrees on some dates, and one summary places the duty in the guidelines rather than the Regulationsas of 2026-11. This build could not read the texts themselves, and the summaries do not say how repayment ability must be measured. A bank’s loan to a company such as Tallowmere is not a consumer loan, so that rule is relevant to Owoleaf’s individuals more than to Northmere’s SME file. The chapter on consumer protection and digital lending rules reads the text. Whatever the rule, a lender that cannot show how it measured capacity has a weak position.
When the analysis goes wrong
Four failures recur, and each has already appeared above:
- Dividing by turnover. The ratio is clean, the denominator is not income.
- One window. A single good month taken as the business. Three full windows are the least that shows a trend.
- Ignoring the lender’s own book. The bureau has not caught up with a loan made last month, and yours has.
- An answer where there should be a gap. A memo that produces a DSCR from a month of data has hidden the finding.
None of these is fixed by a better formula. They are fixed by asking what a number is made of.
You work in labs/finance against data/finance.sqlite (scale 0.1, seed 42). You analyse one merchant’s SME application, application 283, as a credit officer would, using only what was known on the application date. Owoleaf’s merchants stand in for Tallowmere: Northmere’s officer would have bank statements where you have the wallet.
1. Check the book and write the helper module. check.py should end in OK. Then save the helper functions: they read the wallet and the book, and every amount stays in integer kobo until naira() prints it.
cd labs/finance
python3 check.py | tail -1
cat > credit5c.py <<'PY'
"""Helpers for the credit-analysis lab. Standard library only. Money is integer kobo."""
import sqlite3
import statistics
from datetime import date, timedelta
DB = "data/finance.sqlite"
def naira(kobo):
sign = "-" if kobo < 0 else ""
kobo = abs(kobo)
return f"{sign}₦{kobo // 100:,}.{kobo % 100:02d}"
def connect():
db = sqlite3.connect(DB)
db.row_factory = sqlite3.Row
return db
def application(db, app_id):
"""One SME application with its bureau report and the customer's sign-up date."""
return db.execute("""
SELECT a.id, a.customer_id, c.ref, c.state, c.signup_at, a.applied_at, a.requested_kobo,
a.approved_kobo, a.instalments, a.decision, a.bureau_report_id,
b.hit, b.score, b.open_loans, b.outstanding_kobo, b.delinquent_12m,
b.worst_dpd_24m, b.enquiries_90d, b.history_years
FROM applications a
JOIN customers c ON c.id = a.customer_id
JOIN bureau_reports b ON b.id = a.bureau_report_id
WHERE a.id = ? AND a.product = 'SME'""", (app_id,)).fetchone()
def history_days(app):
return (date.fromisoformat(app["applied_at"]) - date.fromisoformat(app["signup_at"][:10])).days
def inflows_by_day(db, customer_id, as_of):
"""Succeeded bank-transfer and card fundings per day, strictly before as_of."""
out = {}
for day, kobo in db.execute("""
SELECT substr(created_at, 1, 10), SUM(amount_kobo) FROM transactions
WHERE customer_id = ? AND status = 'succeeded'
AND kind IN ('funding_transfer', 'funding_card')
AND substr(created_at, 1, 10) < ? GROUP BY 1""", (customer_id, as_of)):
out[date.fromisoformat(day)] = kobo
return out
def payouts_by_day(db, customer_id, as_of):
out = {}
for day, kobo in db.execute("""
SELECT substr(created_at, 1, 10), SUM(amount_kobo) FROM transactions
WHERE customer_id = ? AND status = 'succeeded' AND kind = 'payout_nip'
AND substr(created_at, 1, 10) < ? GROUP BY 1""", (customer_id, as_of)):
out[date.fromisoformat(day)] = kobo
return out
def windows(db, customer_id, as_of, signup, count=3):
"""The `count` 30-day windows before as_of, oldest first: inflow, payouts, credits, and
whether the wallet existed for the whole window (`full`)."""
end = date.fromisoformat(as_of)
first = date.fromisoformat(signup[:10])
inflow = inflows_by_day(db, customer_id, as_of)
payout = payouts_by_day(db, customer_id, as_of)
n_credits = {}
for day, n in db.execute("""
SELECT substr(created_at, 1, 10), COUNT(*) FROM transactions
WHERE customer_id = ? AND status = 'succeeded'
AND kind IN ('funding_transfer', 'funding_card')
AND substr(created_at, 1, 10) < ? GROUP BY 1""", (customer_id, as_of)):
n_credits[date.fromisoformat(day)] = n
out = []
for k in range(count, 0, -1):
lo, hi = end - timedelta(days=30 * k), end - timedelta(days=30 * (k - 1))
days = [lo + timedelta(days=i) for i in range(30)]
out.append(dict(start=lo, end=hi - timedelta(days=1), full=lo >= first,
inflow=sum(inflow.get(d, 0) for d in days),
payout=sum(payout.get(d, 0) for d in days),
credits=sum(n_credits.get(d, 0) for d in days)))
return out
def weekly_inflows(db, customer_id, as_of, signup, weeks=13):
"""Inflow per week for the weeks before as_of that start on or after the wallet's
sign-up date. A week the wallet did not exist for is not a zero week."""
end = date.fromisoformat(as_of)
first = date.fromisoformat(signup[:10])
inflow = inflows_by_day(db, customer_id, as_of)
out = []
for k in range(weeks, 0, -1):
lo = end - timedelta(days=7 * k)
if lo >= first:
out.append(sum(inflow.get(lo + timedelta(days=i), 0) for i in range(7)))
return out
def balance_floor(db, customer_id, as_of):
"""Replay the wallet's entries before as_of: lowest and end balance, in kobo."""
bal, floor = 0, None
for direction, kobo in db.execute("""
SELECT e.direction, e.amount_kobo FROM entries e
JOIN accounts a ON a.id = e.account_id
WHERE a.code = ? AND substr(e.posted_at, 1, 10) < ?
ORDER BY e.posted_at, e.id""", (f"wallet:{customer_id}", as_of)):
bal += kobo if direction == "credit" else -kobo
floor = bal if floor is None else min(floor, bal)
return floor, bal
def own_instalments(db, customer_id, as_of):
"""Instalments of Owoleaf's own loans to this customer that fall due on or after as_of,
for loans disbursed before as_of."""
return db.execute("""
SELECT s.loan_id, s.instalment, s.due_date, s.total_kobo FROM schedule s
JOIN loans l ON l.id = s.loan_id
WHERE l.customer_id = ? AND l.disbursed_at < ? AND s.due_date >= ?
ORDER BY s.due_date""", (customer_id, as_of, as_of)).fetchall()
def new_instalment(db, app_id):
"""The first instalment of the loan this application became (equal instalments)."""
row = db.execute("""SELECT s.total_kobo FROM schedule s JOIN loans l ON l.id = s.loan_id
WHERE l.application_id = ? AND s.instalment = 1""", (app_id,)).fetchone()
return row[0] if row else None
def cv(values):
m = statistics.mean(values)
return statistics.pstdev(values) / m if m else float("nan")
def instalment_for(principal_kobo, rate, n):
"""Equal monthly instalment on a reducing balance, rounded to the kobo, as loans.py does."""
return round(principal_kobo * rate / (1 - (1 + rate) ** -n))
PYOK: all invariants holdNothing else prints. If check.py fails, regenerate with the README’s commands and try again.
2. Find the candidates. 73 SME applications exist. Keep the ones with at least 90 days of wallet history before they applied, enough for three full 30-day windows.
python3 - <<'PY'
from credit5c import *
db = connect()
print("app customer applied decision asked history score")
n = 0
for r in db.execute("SELECT id FROM applications WHERE product = 'SME' ORDER BY applied_at, id"):
a = application(db, r["id"])
if history_days(a) >= 90:
n += 1
score = a["score"] if a["hit"] else "thin"
print(f"{a['id']:>3} {a['ref']} {a['applied_at']} {a['decision']:<9} {naira(a['requested_kobo']):>14} {history_days(a):>5} d {score}")
print(n, "SME applications with at least 90 days of wallet history")
PYapp customer applied decision asked history score
328 C0000764 2026-04-30 declined ₦944,000.00 117 d thin
285 C0000688 2026-05-08 approved ₦529,000.00 91 d 642
201 C0000483 2026-05-09 approved ₦444,000.00 95 d 690
501 C0001136 2026-05-09 declined ₦1,891,000.00 95 d thin
165 C0000398 2026-05-12 approved ₦1,156,000.00 124 d 850
413 C0000954 2026-05-22 approved ₦581,000.00 111 d 649
786 C0001798 2026-05-28 approved ₦1,709,000.00 146 d 812
845 C0001961 2026-06-10 declined ₦1,235,000.00 98 d 547
611 C0001376 2026-06-19 withdrawn ₦328,000.00 163 d 773
352 C0000814 2026-06-23 approved ₦2,064,000.00 118 d 805
283 C0000687 2026-06-25 approved ₦1,364,000.00 109 d 743
63 C0000144 2026-06-27 declined ₦718,000.00 146 d 561
12 SME applications with at least 90 days of wallet historyOnly 12 of 73 qualify. Application 283 is the one to analyse: a merchant asking for ₦1,364,000.00 over six months, approved, with a bureau score of 743.
3. Read the cash flow. Three 30-day windows before 25 June, with credits, payouts and what is left.
python3 - <<'PY'
from credit5c import *
db = connect()
a = application(db, 283)
print(f"application {a['id']}: {a['ref']} ({a['state']}), applied {a['applied_at']}, asked {naira(a['requested_kobo'])} over {a['instalments']} months")
print("wallet opened", a["signup_at"][:10], f"({history_days(a)} days before the application)")
print("30-day window inflow credits payouts retained")
ws = windows(db, a["customer_id"], a["applied_at"], a["signup_at"])
for w in ws:
print(f"{w['start']} to {w['end']} {naira(w['inflow']):>14} {w['credits']:>5} {naira(w['payout']):>14} {naira(w['inflow'] - w['payout']):>10}")
avg = sum(w["inflow"] for w in ws) // 3
print("average 30-day inflow", naira(avg))
print("newest window against oldest: %.1f%%" % (100 * (ws[-1]["inflow"] / ws[0]["inflow"] - 1)))
PYapplication 283: C0000687 (FCT), applied 2026-06-25, asked ₦1,364,000.00 over 6 months
wallet opened 2026-03-08 (109 days before the application)
30-day window inflow credits payouts retained
2026-03-27 to 2026-04-25 ₦4,375,544.00 112 ₦4,522,881.95 -₦147,337.95
2026-04-26 to 2026-05-25 ₦4,173,412.00 97 ₦4,049,500.74 ₦123,911.26
2026-05-26 to 2026-06-24 ₦3,400,037.00 94 ₦3,528,607.97 -₦128,570.97
average 30-day inflow ₦3,982,997.66
newest window against oldest: -22.3%The average is (4,375,544.00 + 4,173,412.00 + 3,400,037.00) ÷ 3 = ₦3,982,997.66. The newest window is 22.3% below the oldest. Payouts are within about 4% of credits in every window: the wallet is a pipe, and the “retained” column is noise, not savings.
4. Measure volatility and the balance floor.
python3 - <<'PY'
from credit5c import *
db = connect()
a = application(db, 283)
wk = weekly_inflows(db, a["customer_id"], a["applied_at"], a["signup_at"])
print("weekly inflows in naira:", [v // 100 for v in wk])
print("weeks", len(wk), "| mean", naira(sum(wk) // len(wk)), "| lowest", naira(min(wk)), "| coefficient of variation %.2f" % cv(wk))
floor, end = balance_floor(db, a["customer_id"], a["applied_at"])
print("wallet balance: lowest", naira(floor), "| on the day before the application", naira(end))
PYweekly inflows in naira: [957429, 858968, 696794, 1280031, 1409753, 707997, 682756, 1322899, 1037254, 1006098, 302399, 1065263, 732955]
weeks 13 | mean ₦927,738.15 | lowest ₦302,399.00 | coefficient of variation 0.32
wallet balance: lowest ₦90.83 | on the day before the application ₦9,508.53Thirteen weeks of credits, with a CV of 0.32 and a lowest week of ₦302,399.00 against a mean of ₦927,738.15. The wallet’s lowest balance was ₦90.83 and it stood at ₦9,508.53 the day before the application: no cash buffer to count as capital.
5. Add up the debt service. The merchant’s own Owoleaf loan still has instalments to fall due. Add the new one, compare with credits and find the margin the loan needs.
python3 - <<'PY'
from credit5c import *
db = connect()
a = application(db, 283)
ws = windows(db, a["customer_id"], a["applied_at"], a["signup_at"])
avg = sum(w["inflow"] for w in ws) // 3
print("Owoleaf's own loans to this customer, instalments still to fall due:")
own = own_instalments(db, a["customer_id"], a["applied_at"])
for r in own:
print(f" {r['loan_id']} instalment {r['instalment']} due {r['due_date']} {naira(r['total_kobo'])}")
existing = own[0]["total_kobo"] if own else 0
proposed = new_instalment(db, a["id"])
print("proposed instalment (6 months, 3.5% a month, reducing balance):", naira(proposed))
service = existing + proposed
print("monthly debt service while both run:", naira(service))
print("bureau: open loans", a["open_loans"], "| outstanding", naira(a["outstanding_kobo"]), "| their instalments are not in the report")
print("debt service as a share of average inflow: %.1f%%" % (100 * service / avg))
print("cash available for debt service = margin x average inflow; DSCR = cash / debt service")
for m in (5, 10, 20, 40):
cads = avg * m // 100
print(f" margin {m:>2}%: cash {naira(cads):>14} DSCR {cads / service:.2f}")
print("margin needed for DSCR 1.25: %.1f%%" % (100 * 1.25 * service / avg))
PYOwoleaf's own loans to this customer, instalments still to fall due:
L000119 instalment 2 due 2026-07-13 ₦1,314,588.59
L000119 instalment 3 due 2026-08-12 ₦1,314,588.58
proposed instalment (6 months, 3.5% a month, reducing balance): ₦255,979.44
monthly debt service while both run: ₦1,570,568.03
bureau: open loans 3 | outstanding ₦796,968.00 | their instalments are not in the report
debt service as a share of average inflow: 39.4%
cash available for debt service = margin x average inflow; DSCR = cash / debt service
margin 5%: cash ₦199,149.88 DSCR 0.13
margin 10%: cash ₦398,299.76 DSCR 0.25
margin 20%: cash ₦796,599.53 DSCR 0.51
margin 40%: cash ₦1,593,199.06 DSCR 1.01
margin needed for DSCR 1.25: 49.3%Check by hand: 1,314,588.59 + 255,979.44 = 1,570,568.03, and 1,570,568.03 ÷ 3,982,997.66 = 39.4%. At a 10% margin cash available is ₦398,299.76, and 398,299.76 ÷ 1,570,568.03 = 0.25. To reach 1.25 the margin must be 1.25 × 1,570,568.03 ÷ 3,982,997.66 = 49.3%. The answer rests on a margin you do not have, which is the finding.
6. Write the memo. One function prints the five Cs for any SME application, and says when the data is too thin to judge. Save it and run it on application 283.
cat > memo.py <<'PY'
from credit5c import *
def memo(app_id, margin_pct=10, target=1.25):
db = connect()
a = application(db, app_id)
ws = windows(db, a["customer_id"], a["applied_at"], a["signup_at"])
full = [w for w in ws if w["full"]]
wk = weekly_inflows(db, a["customer_id"], a["applied_at"], a["signup_at"])
floor, end_bal = balance_floor(db, a["customer_id"], a["applied_at"])
own = own_instalments(db, a["customer_id"], a["applied_at"])
proposed = new_instalment(db, app_id)
existing = own[0]["total_kobo"] if own else 0
service = existing + proposed
print(f"CREDIT MEMO: application {a['id']}, {a['ref']} ({a['state']}), {a['applied_at']}")
print(f"Request: {naira(a['requested_kobo'])} over {a['instalments']} months; first instalment {naira(proposed)}")
print("1. CHARACTER")
if a["hit"]:
print(f" bureau score {a['score']}; delinquencies in 12 months {a['delinquent_12m']} (worst {a['worst_dpd_24m']} days past due in 24);"
f" enquiries in 90 days {a['enquiries_90d']}; {a['history_years']} years of history")
else:
print(" no bureau hit (thin file): character rests on the wallet record alone")
print(f" wallet open {history_days(a)} days; own-book loans still running: {len({r['loan_id'] for r in own})}")
print("2. CAPACITY")
if len(full) < 3:
print(f" only {len(full)} full 30-day window(s) of wallet history: no trend, no volatility. Ask for 6-12 months of statements.")
else:
avg = sum(w["inflow"] for w in full) // len(full)
trend = 100 * (full[-1]["inflow"] / full[0]["inflow"] - 1)
print(f" average 30-day inflow {naira(avg)}, newest window {trend:+.1f}% on the oldest, weekly variation {cv(wk):.2f}")
print(f" debt service {naira(service)} a month = {100 * service / avg:.1f}% of inflow")
cads = avg * margin_pct // 100
print(f" at an assumed {margin_pct}% margin: DSCR {cads / service:.2f} (target {target}); margin needed {100 * target * service / avg:.1f}%")
print("3. CAPITAL")
print(f" wallet balance {naira(end_bal)}, lowest {naira(floor)}. The wallet shows no owner's equity: ask for accounts.")
print("4. COLLATERAL")
print(" none in the data; the product is unsecured and repaid by standing instruction.")
print("5. CONDITIONS")
print(" purpose of the loan, sector and season are not in the data: ask the applicant.")
if __name__ == "__main__":
import sys
memo(int(sys.argv[1]), int(sys.argv[2]) if len(sys.argv) > 2 else 10)
PY
python3 memo.py 283CREDIT MEMO: application 283, C0000687 (FCT), 2026-06-25
Request: ₦1,364,000.00 over 6 months; first instalment ₦255,979.44
1. CHARACTER
bureau score 743; delinquencies in 12 months 0 (worst 0 days past due in 24); enquiries in 90 days 3; 4 years of history
wallet open 109 days; own-book loans still running: 1
2. CAPACITY
average 30-day inflow ₦3,982,997.66, newest window -22.3% on the oldest, weekly variation 0.32
debt service ₦1,570,568.03 a month = 39.4% of inflow
at an assumed 10% margin: DSCR 0.25 (target 1.25); margin needed 49.3%
3. CAPITAL
wallet balance ₦9,508.53, lowest ₦90.83. The wallet shows no owner's equity: ask for accounts.
4. COLLATERAL
none in the data; the product is unsecured and repaid by standing instruction.
5. CONDITIONS
purpose of the loan, sector and season are not in the data: ask the applicant.The capacity section gives a DSCR of 0.25 at the assumed margin and the margin needed, not a verdict. A reasonable recommendation here is to defer pending accounts: the credits are falling, the obligations are stacked and the margin is unknown.
7. Run it on two other applicants. Application 285 has 91 days of history and no other loan. Application 435 has 30 days of history, a borderline score and one delinquency.
python3 memo.py 285
python3 memo.py 435CREDIT MEMO: application 285, C0000688 (Lagos), 2026-05-08
Request: ₦529,000.00 over 6 months; first instalment ₦99,276.48
1. CHARACTER
bureau score 642; delinquencies in 12 months 0 (worst 0 days past due in 24); enquiries in 90 days 2; 9 years of history
wallet open 91 days; own-book loans still running: 0
2. CAPACITY
average 30-day inflow ₦4,050,944.33, newest window +38.0% on the oldest, weekly variation 0.32
debt service ₦99,276.48 a month = 2.5% of inflow
at an assumed 10% margin: DSCR 4.08 (target 1.25); margin needed 3.1%
3. CAPITAL
wallet balance ₦151,454.78, lowest ₦109.51. The wallet shows no owner's equity: ask for accounts.
4. COLLATERAL
none in the data; the product is unsecured and repaid by standing instruction.
5. CONDITIONS
purpose of the loan, sector and season are not in the data: ask the applicant.
CREDIT MEMO: application 435, C0001005 (Rivers), 2026-05-12
Request: ₦3,313,000.00 over 6 months; first instalment ₦621,744.78
1. CHARACTER
bureau score 604; delinquencies in 12 months 1 (worst 30 days past due in 24); enquiries in 90 days 2; 4 years of history
wallet open 30 days; own-book loans still running: 0
2. CAPACITY
only 1 full 30-day window(s) of wallet history: no trend, no volatility. Ask for 6-12 months of statements.
3. CAPITAL
wallet balance ₦24,669.59, lowest ₦380.64. The wallet shows no owner's equity: ask for accounts.
4. COLLATERAL
none in the data; the product is unsecured and repaid by standing instruction.
5. CONDITIONS
purpose of the loan, sector and season are not in the data: ask the applicant.Application 285 needs only a 3.1% margin for a DSCR of 1.25: on credits alone it looks easy, yet the Cs still ask for accounts. Application 435 asks for ₦3,313,000.00 on one full window, so the memo gives no capacity figure at all and says what to ask for. That refusal is the memo working.
Now look at outcomes, which a credit officer cannot see on the day. Run the margin-needed calculation for every approved SME loan that has at least one full window, rank them and see where the loans that went wrong sit.
python3 - <<'PY'
from credit5c import *
db = connect()
rows, skipped, skipped_bad = [], 0, []
for l in db.execute("SELECT id, application_id, status, days_past_due FROM loans WHERE product = 'SME'").fetchall():
a = application(db, l["application_id"])
full = [w for w in windows(db, a["customer_id"], a["applied_at"], a["signup_at"]) if w["full"]]
if not full:
skipped += 1
if l["status"] not in ("closed", "current"):
skipped_bad.append(l["id"])
continue
avg = sum(w["inflow"] for w in full) // len(full)
own = own_instalments(db, a["customer_id"], a["applied_at"])
service = (own[0]["total_kobo"] if own else 0) + new_instalment(db, a["id"])
rows.append((1.25 * service / avg, l["id"], a["id"], l["status"], l["days_past_due"], len(full)))
rows.sort(reverse=True)
print(len(rows), "SME loans could be analysed;", skipped, "had no full 30-day window and were skipped")
print("rank margin needed loan application status dpd windows")
for i, (need, lid, aid, st, dpd, nw) in enumerate(rows, 1):
if i <= 3 or st not in ("closed", "current"):
print(f"{i:>4} {100 * need:>10.1f}% {lid} {aid:>10} {st:<11} {dpd:>4} {nw}")
bad = [r for r in rows if r[3] not in ("closed", "current")]
print(len(bad), "of the analysed loans are past due; among the skipped, past due:", ", ".join(skipped_bad))
PYYou get:
24 SME loans could be analysed; 21 had no full 30-day window and were skipped
rank margin needed loan application status dpd windows
1 138.0% L000221 505 closed 0 1
2 94.4% L000351 802 closed 0 1
3 61.4% L000202 458 current 0 2
8 54.2% L000053 128 default 93 2
24 3.1% L000120 285 arrears 23 3
2 of the analysed loans are past due; among the skipped, past due: L000026, L000088Twenty-one of the 45 SME loans were approved on less than 30 days of wallet history and the memo cannot analyse them, and two of the four loans that went wrong are among them (L000026 and L000088). Of the 24 it can analyse, the loan that needed the highest margin (138.0%, L000221) closed, and the two past-due loans rank 8th and 24th. The generator draws who stops paying mostly from a hidden risk and not from wallet cash flow, so this book cannot validate a memo, and 24 loans with 2 bad ones prove nothing either way. The lesson is how to test one: with real outcomes, by rank, on enough loans. Module 2’s scoring chapter does exactly that. Before you move on, change the 10% margin in memo.py to 5% and to 20% and say which of the three applicants’ recommendations changes.
Template
# Credit memo: <applicant>, application <id>, <date>
Prepared by <analyst>, credit. Approved by <head of credit approval>. Data as at <date>.
## 1. The request
Amount <₦>, <n> months, purpose <what for>, instalment <₦>, repayment from <source>.
## 2. The five Cs
- Character: <evidence: score, delinquencies, own-book history>. Cannot see: <gap>.
- Capacity: <average inflow, trend, volatility, debt service, share of inflow>. Cannot see: <gap>.
- Capital: <evidence>. Cannot see: <gap>.
- Collateral: <evidence>. Cannot see: <gap>.
- Conditions: <purpose, sector, season>. Cannot see: <gap>.
## 3. The numbers
| Assumed margin | Cash available | DSCR | Target <x> met? |
Margin needed for the target: <%>. The margin is an assumption: <source or none>.
## 4. Risks and mitigants
| Risk | Why it matters | What would reduce it |
## 5. Recommendation
<approve | approve with conditions | decline | defer>. Conditions: <document or date, one per line>.
## 6. How this could be wrong, and sign-off
<one way, and what would show it>. Out of scope: <what this memo does not cover>.
The approver is asked to sign: <the decision>. Prepared <name, date>. Approved <name, date>. WORKED EXAMPLE
At Northmere Bank a credit analyst, Oyebola here, writes the memo, and the head of credit approval, Chidubem, signs it. This one uses the lab’s application 283 as at 25 June 2026, the merchant that stands in for Tallowmere.
Request. ₦1,364,000.00 over 6 months, first instalment ₦255,979.44, repaid from wallet credits by standing instruction.
Five Cs. Character: score 743, no delinquencies in 12 months, 3 open loans and ₦796,968.00 outstanding at the bureau. The lender’s own book also shows loan L000119 with ₦1,314,588.59 and ₦1,314,588.58 still due on 13 July and 12 August, which the bureau may not count. Capacity: average 30-day inflow ₦3,982,997.66, newest window 22.3% below the oldest, weekly variation 0.32. Debt service while both loans run is ₦1,570,568.03, 39.4% of inflow. Capital: wallet balance ₦9,508.53, lowest ₦90.83, so no equity is visible. Collateral: none, unsecured. Conditions: purpose and season unknown.
Numbers. At an assumed 10% margin the DSCR is 0.25 against a target of 1.25. At 40% it is 1.01. The loan needs a margin of 49.3%, and no margin is known.
Risks. Stacked debt is the largest. Once L000119 ends, the new instalment alone would give a DSCR of 1.56 at 10% (derived here, not printed by the lab: 398,299.76 ÷ 255,979.44, assuming inflow holds), so timing is the mitigant to test.
Recommendation. Defer. Conditions: twelve months of accounts, a list of every obligation, and the purpose and stock cycle.
Could be wrong. The 10% margin is invented. Accounts showing a higher margin would change the DSCR. Chidubem is asked to sign the deferral. Out of scope: pricing.
Now you
You are a credit analyst at Owoleaf, and your head of credit approval signs what you write. It is 8 May 2026 and you have application 285, a Lagos merchant asking for ₦529,000.00 over 6 months. Run python3 memo.py 285 and rebuild the capacity step with application(db, 285), so you can see the three windows and the weekly inflows yourself. The merchant has 91 days of wallet history, a bureau score of 642, nine years of bureau history and no other Owoleaf loan, though the bureau report shows 4 open loans and ₦1,286,364.00 outstanding (print them from application(db, 285)). On the printed numbers the loan looks easy, and the lab says what the margin needed is. Decide what that ease is made of, what 91 days can and cannot show, and what you would ask for before anyone signs. Your head of credit approval reads the memo to decide whether to approve, approve with conditions or defer this request.
Self-check
Oyebola has six months of Tallowmere's statements. Average credits look ample for the ₦4,000,000 request. Chidubem notices that about a third of the credits come from two accounts in the director's own name, and that the largest credits are followed within days by debits for similar amounts. The approver wants a decision by Friday, and the memo is due today.
- DOC Principles for the Management of Credit Risk (BCBS, revised April 2025) Basel Committee on Banking Supervision, 2025
The Basel Committee's current principles for how banks grant and monitor credit, in the supervisor's own words. Read the sections on sound credit-granting and on credit monitoring to see what a bank is expected to be able to show about each loan. Skip the supervisory-assessment material on a first pass.
- DOC Principles for the Management of Credit Risk (BCBS, 2000 original) Basel Committee on Banking Supervision, 2000
The 2000 text, which the 2025 revision updates. Read it for how it treats a borrower's repayment capacity and collateral, and compare with the 2025 wording.
- DOC Prudential Guidelines for Deposit Money Banks (CBN, 30 June 2010) Central Bank of Nigeria, 2010
The CBN's prudential text for Nigerian banks, the version dated 30 June 2010. Search results say a later CBN document states that it supersedes this text, so this one may no longer be in force: use it as background on how a Nigerian bank is expected to manage credit, and find the current text before quoting any requirement.
- DOC Digital, Electronic, Online or Non-Traditional Consumer Lending Regulations, 2025 (FCCPC) Federal Competition and Consumer Protection Commission, 2025
The primary text behind the affordability point above, which this chapter states from summaries. Read it to see what the Regulations themselves say about assessing a borrower before lending to an individual. It covers consumer lending, so it is not the rule for a bank's company loan.
- DOC DEON Consumer Lending Guidelines 2025 (FCCPC) Federal Competition and Consumer Protection Commission, 2025
The commission's companion guidelines, which search results date to November 2025. Read them alongside the Regulations to see where each sets out the duty to assess a borrower, and keep the two documents apart when you cite them.
- DOC Nigeria Data Protection Act 2023 Federal Republic of Nigeria (copy via NgCERT), 2023
A copy of the Act hosted by Nigeria's national CERT. Read the consent provisions (section 26 in the summaries this chapter used) to see what a lender must be able to show before using an applicant's statements. Check the wording against the official gazetted text.
All companies and people in these examples are fictional. Any resemblance to a real business or person is unintended.