# openai · R2 · run 5 - Model requested: `gpt-6.2-astra` · reported: `gpt-6.2-astra` - Started 2026-12-04T18:45:58+05:30 · finished 2026-12-04T18:47:00+05:30 · latency 62 s - Tokens: {"in": 11465, "out": 1392, "cache_read": 1223, "cache_write": 0, "reasoning": 1009} · cost estimate $0.178 - System prompt: none · effort: medium ## Prompt ``` Here's our data. Anything I should know? ``` Files attached: invoices.csv, credit_notes.csv, customers.csv, columns_note.txt ## Transcript **Code (code_interpreter):** ``` import os print(os.listdir('/mnt/data')) ``` **Output:** ``` ['file-148GQJApHG1xhKW5X6RUu8-credit_notes.csv', 'file-WyCJ1nkdKgEBXgV8KszbNP-columns_note.txt', 'file-FtYTGgPNtsfpqzYdz6FNSx-invoices.csv', 'file-QXYxyYcvj9dKA97xg6DwuD-customers.csv'] ``` **Code (code_interpreter):** ``` import glob,pandas as pd f=lambda pat:glob.glob('/mnt/data/*'+pat)[0] print(open(f('.txt')).read()) i,c,n=[pd.read_csv(f(x)) for x in ['invoices.csv','customers.csv','credit_notes.csv']] for d in [i,c,n]: print(d.shape,d.head().to_string(index=False),d.isna().sum(),sep='\n') ``` **Output:** ``` Indigo Thread Co. - export from the ERP (sales ledger). Three tables, CSV, all history from April 2024 up to 31 Oct 2026. Amounts are in Indian rupees (INR) unless a column says otherwise. invoices.csv - one row per sales invoice invoice_id internal id of the invoice invoice_no invoice number as printed invoice_date date of the invoice customer_id links to customers.customer_id currency currency the invoice was raised in (INR or EUR) fx_rate rupees per unit of that currency, used to convert amount_fc amount in the invoice currency (blank for INR invoices) net_amount invoice value in INR, before GST gst_amount GST charged, in INR gross_amount net_amount + gst_amount order_ref sales order the invoice was raised against created_at when the row was entered in the ERP credit_notes.csv - one row per credit note issued to a customer cn_id internal id of the credit note cn_no credit note number cn_date date of the credit note invoice_id the invoice it credits (links to invoices.invoice_id) customer_id links to customers.customer_id net_amount credit value in INR, before GST (a positive number that reduces revenue) gst_amount GST reversed, in INR reason reason recorded for the credit created_at when the row was entered in the ERP customers.csv - one row per customer account customer_id internal id customer_code customer code name customer name region sales region the account is managed under (South, West, East, North, Export) city customer's city segment account size band used by sales (key, mid, small) currency usual invoicing currency status account status in the ERP (active / inactive) payment_terms_days agreed payment terms in days credit_limit credit limit in INR created_at when the account was created Net revenue, as the company reports it from these tables: invoice net_amount minus credit note net_amount, by date. (8772, 12) invoice_id invoice_no invoice_date customer_id currency fx_rate amount_fc net_amount gst_amount gross_amount order_ref created_at 5411 BI/2425/000001 2024-04-01 11 INR 1.0000 NaN 117738.91 5886.95 123625.86 SO-24005358 2024-04-01 18:43:04 5412 BI/2425/000002 2024-04-01 21 EUR 100.6756 3671.5 369630.47 0.00 369630.47 SO-24005296 2024-04-01 17:59:42 5413 BI/2425/000003 2024-04-01 95 INR 1.0000 NaN 67337.59 3366.88 70704.47 SO-24005494 2024-04-01 19:00:03 5414 BI/2425/000004 2024-04-01 99 INR 1.0000 NaN 56480.17 2824.01 59304.18 SO-24005522 2024-04-01 19:02:32 5415 BI/2425/000005 2024-04-01 104 INR 1.0000 NaN 22867.57 1143.38 24010.95 SO-24005445 2024-04-01 13:56:45 invoice_id 0 invoice_no 0 invoice_date 0 customer_id 0 currency 0 fx_rate 0 amount_fc 7212 net_amount 0 gst_amount 0 gross_amount 0 order_ref 0 created_at 0 dtype: int64 (143, 11) customer_id customer_code name region city segment currency status payment_terms_days credit_limit created_at 1 C0001 Ravira Exports South Tiruppur key INR active 30 33600000.0 2023-08-05 17:08:04 2 C0002 Tessora EU South Rotterdam key EUR active 45 43700000.0 2021-12-11 17:53:30 3 C0003 Skarfab South Aarhus key EUR active 45 22800000.0 2022-05-07 16:51:47 4 C0004 Merai Apparels West Mumbai key INR active 30 15600000.0 2022-03-02 17:53:33 5 C0005 Shree Varada Textiles South Tiruppur mid INR active 30 6000000.0 2022-02-01 14:58:43 customer_id 0 customer_code 0 name 0 region 0 city 0 segment 0 currency 0 status 0 payment_terms_days 0 credit_limit 0 created_at 0 dtype: int64 (860, 9) cn_id cn_no cn_date invoice_id customer_id net_amount gst_amount reason created_at 1 CN/000001 2024-04-08 5448 50 3874.57 193.73 Quality claim 2024-04-08 16:30:56 2 CN/000002 2024-04-10 5433 142 5507.46 275.37 Return 2024-04-10 15:27:01 3 CN/000003 2024-04-13 5489 6 18492.12 924.61 Rate difference 2024-04-13 14:00:56 4 CN/000004 2024-04-18 5441 143 5035.80 251.79 Quality claim 2024-04-18 16:26:02 5 CN/000005 2024-04-24 5523 42 69088.99 0.00 Return 2024-04-24 15:16:58 cn_id 0 cn_no 0 cn_date 0 invoice_id 0 customer_id 0 net_amount 0 gst_amount 0 reason 0 created_at 0 dtype: int64 ``` **Code (code_interpreter):** ``` i['m']=i.invoice_date.str[:7];n['m']=n.cn_date.str[:7] g=pd.concat([i.groupby('m').net_amount.sum(),n.groupby('m').net_amount.sum(),i.groupby('m').size()],axis=1);g.columns=['bill','credit','count'];g['net']=g.bill-g.credit print(g.round().to_string());print(n.groupby('reason').net_amount.agg(['size','sum'])) print(i.nlargest(15,'net_amount').to_string(index=False)) ``` **Output:** ``` bill credit count net m 2024-04 42255120.0 115994.0 271 42139125.0 2024-05 43542599.0 519349.0 260 43023250.0 2024-06 45154601.0 812477.0 241 44342124.0 2024-07 43834883.0 810135.0 307 43024748.0 2024-08 41080239.0 674412.0 260 40405827.0 2024-09 45007042.0 679793.0 283 44327248.0 2024-10 44173656.0 724536.0 292 43449119.0 2024-11 43272183.0 681748.0 283 42590435.0 2024-12 44748938.0 436153.0 294 44312785.0 2025-01 43297508.0 1140669.0 276 42156839.0 2025-02 43001233.0 413743.0 217 42587489.0 2025-03 50233756.0 1115099.0 314 49118656.0 2025-04 45790037.0 796427.0 266 44993610.0 2025-05 46460196.0 546910.0 302 45913286.0 2025-06 48242660.0 928460.0 289 47314200.0 2025-07 47461566.0 1532054.0 299 45929511.0 2025-08 43595885.0 446691.0 268 43149193.0 2025-09 47974220.0 682390.0 297 47291830.0 2025-10 47147730.0 750519.0 324 46397211.0 2025-11 45870502.0 391855.0 254 45478648.0 2025-12 48114703.0 803797.0 326 47310906.0 2026-01 45385563.0 410786.0 303 44974777.0 2026-02 45988712.0 531858.0 272 45456854.0 2026-03 53105676.0 685936.0 346 52419740.0 2026-04 47731256.0 1010248.0 274 46721008.0 2026-05 48341390.0 697792.0 293 47643599.0 2026-06 50169114.0 1064355.0 267 49104759.0 2026-07 48135248.0 485701.0 245 47649547.0 2026-08 45434672.0 692084.0 237 44742587.0 2026-09 49066633.0 867445.0 293 48199188.0 2026-10 47843737.0 1492156.0 319 46351580.0 size sum reason Quality claim 187 5076391.88 Rate difference 241 5903927.68 Return 432 11961254.19 invoice_id invoice_no invoice_date customer_id currency fx_rate amount_fc net_amount gst_amount gross_amount order_ref created_at m 13775 BI/2627/001521 2026-09-26 2 EUR 98.1359 30990.24 3041255.09 0.00 3041255.09 SO-26013446 2026-09-26 14:09:16 2026-09 7864 BI/2425/002454 2024-12-30 2 EUR 100.3529 27790.35 2788842.21 0.00 2788842.21 SO-24007453 2024-12-30 12:48:20 2024-12 13546 BI/2627/001292 2026-08-29 1 INR 1.0000 NaN 2633541.50 131677.08 2765218.58 SO-26013206 2026-08-29 18:21:11 2026-08 10413 BI/2526/001705 2025-09-30 2 EUR 100.3276 25080.68 2516284.43 0.00 2516284.43 SO-25009909 2025-09-30 14:10:45 2025-09 6168 BI/2425/000758 2024-06-29 1 INR 1.0000 NaN 2466507.91 123325.40 2589833.31 SO-24005649 2024-06-29 14:31:10 2024-06 14059 BI/2627/001805 2026-10-22 4 INR 1.0000 NaN 2290465.44 114523.27 2404988.71 SO-26013507 2026-10-22 18:12:49 2026-10 9534 BI/2526/000826 2025-06-28 1 INR 1.0000 NaN 2241958.80 112097.94 2354056.74 SO-25009154 2025-06-28 15:51:09 2025-06 6642 BI/2425/001232 2024-08-20 2 EUR 100.0343 22135.38 2214297.24 0.00 2214297.24 SO-24006210 2024-08-20 14:33:22 2024-08 6005 BI/2425/000595 2024-06-12 2 EUR 99.3753 22204.65 2206593.76 0.00 2206593.76 SO-24005608 2024-06-12 14:46:36 2024-06 12450 BI/2627/000196 2026-04-24 1 INR 1.0000 NaN 2109484.07 105474.20 2214958.27 SO-26012179 2026-04-24 11:11:32 2026-04 8648 BI/2425/003238 2025-03-28 1 INR 1.0000 NaN 2084867.82 104243.39 2189111.21 SO-25008127 2025-03-28 12:59:51 2025-03 11571 BI/2526/002863 2026-01-26 2 EUR 101.6531 19375.67 1969596.92 0.00 1969596.92 SO-25011182 2026-01-26 19:34:16 2026-01 7234 BI/2425/001824 2024-10-26 1 INR 1.0000 NaN 1913302.94 95665.15 2008968.09 SO-24006742 2024-10-26 11:23:04 2024-10 12401 BI/2627/000147 2026-04-18 1 INR 1.0000 NaN 1896869.63 94843.48 1991713.11 SO-26011810 2026-04-18 12:01:09 2026-04 12916 BI/2627/000662 2026-06-13 2 EUR 100.8919 18506.91 1867197.31 0.00 1867197.31 SO-26012528 2026-06-13 14:39:54 2026-06 ``` **Code (code_interpreter):** ``` x=pd.concat([i[['m','customer_id','net_amount']],n[['m','customer_id','net_amount']].assign(net_amount=-n.net_amount)]).merge(c) x['y']=x.m.str[:4]; x['mo']=x.m.str[-2:] a=x[x.mo.between('04','10')] for k in ['region','segment','name','currency']: p=a.pivot_table(index=k,columns='y',values='net_amount',aggfunc='sum',fill_value=0)/1e7;p['diff']=p['2026']-p['2025'];print(p.sort_values('diff').iloc[([0,1,2,3,-4,-3,-2,-1] if len(p)>8 else slice(None))]) print(c.head(25).to_string(index=False));print(c.tail(15).to_string(index=False)) ``` **Output:** ``` y 2024 2025 2026 diff region South 17.562799 18.681157 17.575526 -1.105631 North 3.025021 3.650746 3.574961 -0.075786 East 1.816052 1.750632 2.193273 0.442641 Export 2.967245 3.286631 3.768645 0.482014 West 4.700027 4.729718 5.928823 1.199104 y 2024 2025 2026 diff segment mid 18.053922 19.424321 18.536750 -0.887571 small 4.227279 4.834761 5.303793 0.469032 key 7.789943 7.839802 9.200684 1.360882 y 2024 2025 2026 diff name Shree Varada Textiles 0.542508 0.533995 0.193379 -0.340615 Skarfab 1.748079 2.025200 1.728948 -0.296252 Anvika Knit Works 0.340714 0.400527 0.104677 -0.295850 Pamvra Fabrics 0.097008 0.287543 0.020931 -0.266613 Castelino 0.266265 0.308109 0.561699 0.253590 Moselweber 0.283904 0.243256 0.573191 0.329935 Saurava Fabrics 0.125073 0.111070 0.450350 0.339280 Merai Apparels 0.347227 0.532060 1.822896 1.290836 y 2024 2025 2026 diff currency INR 18.124464 20.169903 20.173665 0.003762 EUR 11.946680 11.928981 12.867561 0.938581 customer_id customer_code name region city segment currency status payment_terms_days credit_limit created_at 1 C0001 Ravira Exports South Tiruppur key INR active 30 33600000.0 2023-08-05 17:08:04 2 C0002 Tessora EU South Rotterdam key EUR active 45 43700000.0 2021-12-11 17:53:30 3 C0003 Skarfab South Aarhus key EUR active 45 22800000.0 2022-05-07 16:51:47 4 C0004 Merai Apparels West Mumbai key INR active 30 15600000.0 2022-03-02 17:53:33 5 C0005 Shree Varada Textiles South Tiruppur mid INR active 30 6000000.0 2022-02-01 14:58:43 6 C0006 Tidewell Garments South Coimbatore mid INR active 30 6000000.0 2023-03-05 18:54:32 7 C0007 Anvika Knit Works West Ahmedabad mid INR active 30 6000000.0 2022-04-05 14:44:19 8 C0008 Sanvi Weaves South Chennai mid INR active 30 6000000.0 2023-05-07 12:59:32 9 C0009 Kavira Knitwear South Kochi mid INR active 30 6000000.0 2022-06-07 13:55:42 10 C0010 Navika Fashions West Bhiwandi mid INR active 30 6000000.0 2023-07-09 18:27:26 11 C0011 Korana Clothing East Howrah mid INR active 30 6000000.0 2022-02-07 11:03:45 12 C0012 Devana Apparels South Tiruppur mid INR active 30 6000000.0 2023-03-11 16:57:48 13 C0013 Inara Creations North Noida mid INR active 30 6000000.0 2022-04-11 12:04:25 14 C0014 Maravi Linens South Bengaluru mid INR active 30 6000000.0 2023-05-13 14:28:48 15 C0015 Tarini Garments West Vapi mid INR active 30 6000000.0 2022-06-13 13:54:37 16 C0016 Nilavi Exports South Kochi mid INR active 30 6000000.0 2023-07-15 15:58:49 17 C0017 Vihana Textiles North Ludhiana mid INR active 30 6000000.0 2022-02-13 16:25:08 18 C0018 Charu Knit Fab South Madurai mid INR active 30 6000000.0 2023-03-17 09:59:58 19 C0019 Solvik Textil Export Hamburg mid EUR active 45 9900000.0 2021-03-02 15:41:56 20 C0020 Haus Brenner Stoffe Export Lyon mid EUR active 45 9000000.0 2022-04-01 16:27:17 21 C0021 Vela Moda Srl West Ahmedabad mid EUR active 45 9600000.0 2023-05-02 10:03:45 22 C0022 Atelier Saône Export Antwerp mid EUR active 45 8100000.0 2021-06-01 16:38:04 23 C0023 Van Rijt Stoffen West Mumbai mid EUR active 45 8600000.0 2022-07-02 16:34:18 24 C0024 Moda Castella North Delhi mid EUR active 45 8500000.0 2023-08-02 18:47:49 25 C0025 Kaskaro Textil Export Hamburg mid EUR active 45 8700000.0 2021-09-01 10:28:30 customer_id customer_code name region city segment currency status payment_terms_days credit_limit created_at 129 C0129 Kanvira Clothing North Jaipur small INR active 30 1400000.0 2021-03-02 13:28:02 130 C0130 Udavra Knitwear North Panipat small INR active 30 1700000.0 2022-05-02 10:53:43 131 C0131 Satvira Fabrics North Ludhiana small INR active 30 1800000.0 2023-06-01 14:21:53 132 C0132 Kosra Textiles North Delhi small INR active 30 1400000.0 2024-07-02 12:32:24 133 C0133 Perivra Apparels East Kolkata small INR active 30 1800000.0 2021-03-02 10:32:12 134 C0134 Brahmavra Wear East Bhubaneswar small INR active 30 1800000.0 2022-09-01 17:00:27 135 C0135 Mahanvi Creations East Howrah small INR active 30 1600000.0 2023-10-02 10:39:19 136 C0136 Sabarvi Fashions East Guwahati small INR active 30 1800000.0 2024-11-01 10:52:19 137 C0137 Tungavra Garments South Madurai small INR active 30 1400000.0 2021-03-02 11:19:19 138 C0138 Kalvira Overseas South Tiruppur small INR active 30 1300000.0 2022-01-02 12:57:44 139 C0139 Magvira Knitwear South Bengaluru small INR active 30 1300000.0 2024-03-02 13:10:47 140 C0140 Vidarva Fabrics South Chennai small INR active 30 1600000.0 2021-03-02 15:00:51 141 C0141 Bundra Textiles Old North Ludhiana small INR inactive 30 1800000.0 2021-12-11 14:59:54 142 C0142 Satvira Exports West Mumbai small INR inactive 30 1800000.0 2022-01-11 09:50:20 143 C0143 Kosra Garments East Kolkata small INR inactive 30 1800000.0 2022-02-08 11:57:54 ``` **Code (code_interpreter):** ``` p=x.pivot_table(index='m',columns='customer_id',values='net_amount',aggfunc='sum',fill_value=0) print((p.iloc[-14:,:18]/1e5).round(1)) j=i[i.currency=='EUR'];print(j.groupby('m').agg(fx=('fx_rate','mean'),eur=('amount_fc','sum')).tail(19)) print(i.duplicated(['customer_id','order_ref','net_amount']).sum(),i.duplicated('order_ref').sum()) print(n[n.m=='2026-10'].merge(c).groupby(['name','reason']).net_amount.sum().nlargest(10)) ``` **Output:** ``` customer_id 1 2 3 4 5 6 7 8 9 10 11 12 \ m 2025-09 46.4 35.4 40.6 -0.5 7.4 7.6 5.5 3.0 2.8 3.1 3.2 2.9 2025-10 40.8 12.3 27.2 9.8 6.2 5.4 5.7 2.6 3.6 3.8 2.3 3.0 2025-11 56.1 30.7 21.3 35.7 6.5 5.9 6.5 2.3 1.8 2.1 1.6 2.6 2025-12 55.8 46.2 19.6 16.8 8.4 7.7 3.9 3.1 3.9 3.4 3.2 2.3 2026-01 38.9 32.6 24.7 8.9 8.9 6.5 7.7 2.9 3.8 3.5 1.9 3.0 2026-02 39.1 28.5 26.9 22.1 6.3 4.1 5.7 2.9 3.0 2.6 3.0 2.6 2026-03 49.4 22.4 26.4 17.5 11.7 5.4 6.0 3.8 2.6 2.8 2.2 3.5 2026-04 83.3 20.2 21.5 24.0 6.1 6.5 2.9 3.3 3.3 3.3 2.8 2.4 2026-05 35.1 44.0 25.4 4.8 7.7 4.9 3.7 2.7 3.3 2.0 2.2 1.0 2026-06 40.9 27.5 23.5 12.2 4.4 4.6 3.8 3.1 1.4 2.4 2.4 1.6 2026-07 59.8 26.3 34.5 5.5 1.1 2.1 0.0 0.6 0.6 0.0 1.1 0.0 2026-08 62.6 31.0 25.0 5.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 2026-09 43.0 58.7 37.3 7.1 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 2026-10 21.2 11.3 5.7 123.7 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 customer_id 13 14 15 16 17 18 m 2025-09 2.9 2.2 2.0 1.8 3.2 1.5 2025-10 1.6 2.6 2.0 2.0 1.8 1.7 2025-11 2.1 2.7 1.7 1.8 1.8 2.4 2025-12 2.3 2.9 2.1 2.5 2.4 1.7 2026-01 2.7 2.3 1.3 1.9 2.1 1.8 2026-02 1.7 1.7 1.6 1.9 1.1 2.1 2026-03 1.8 2.8 2.2 2.6 2.1 1.3 2026-04 2.7 2.1 2.2 1.7 2.0 2.0 2026-05 2.4 0.8 2.6 1.4 1.7 1.6 2026-06 1.5 1.1 1.3 0.9 1.4 1.0 2026-07 0.6 0.0 0.8 0.7 0.0 0.4 2026-08 0.0 0.0 -0.0 0.0 0.0 0.0 2026-09 0.0 0.0 0.0 0.0 0.0 0.0 2026-10 0.0 0.0 0.0 0.0 0.0 0.0 fx eur m 2025-04 98.500671 169983.71 2025-05 98.440855 189131.57 2025-06 96.692277 192186.78 2025-07 96.469005 172418.59 2025-08 97.937608 144341.42 2025-09 99.659370 210667.09 2025-10 100.190381 153273.26 2025-11 100.995806 139641.08 2025-12 102.334591 178154.86 2026-01 102.165383 198016.00 2026-02 101.760881 167965.93 2026-03 100.905982 184509.75 2026-04 100.818667 123612.96 2026-05 101.015526 215227.54 2026-06 100.928635 180383.14 2026-07 99.868319 191792.18 2026-08 99.058422 195118.88 2026-09 98.205645 262475.72 2026-10 100.271650 138050.70 0 0 Series([], Name: net_amount, dtype: float64) ``` **Code (code_interpreter):** ``` l=i.groupby('customer_id').agg(last=('invoice_date','max'),months=('m','nunique')) print(l[l['last']<'2026-08'].to_string());print((p.loc['2025-08':'2025-10',5:18].sum().sum()/1e5)) o=i[i.m=='2026-10']; print(o[o.customer_id==4].to_string(index=False)) print(n[n.m=='2026-10'].merge(c,on='customer_id').groupby(['name','reason']).net_amount.sum().nlargest(12));print((p.iloc[-3:,:4]/p.sum(axis=1).iloc[-3:].values[:,None])) ``` **Output:** ``` last months customer_id 5 2026-07-12 28 6 2026-07-02 28 7 2026-06-28 27 8 2026-07-20 28 9 2026-07-08 28 10 2026-06-30 27 11 2026-07-25 28 12 2026-06-22 27 13 2026-07-16 28 14 2026-06-18 27 15 2026-07-29 28 16 2026-07-04 28 17 2026-06-26 27 18 2026-07-01 28 141 2025-02-14 11 142 2025-06-30 15 143 2024-11-20 8 139.1371784 invoice_id invoice_no invoice_date customer_id currency fx_rate amount_fc net_amount gst_amount gross_amount order_ref created_at m 13878 BI/2627/001624 2026-10-02 4 INR 1.0 NaN 369431.50 18471.58 387903.08 SO-26013587 2026-10-02 13:05:47 2026-10 13879 BI/2627/001625 2026-10-02 4 INR 1.0 NaN 446119.76 22305.99 468425.75 SO-26013525 2026-10-02 14:44:58 2026-10 13911 BI/2627/001657 2026-10-06 4 INR 1.0 NaN 668560.31 33428.02 701988.33 SO-26013485 2026-10-06 11:29:57 2026-10 13920 BI/2627/001666 2026-10-07 4 INR 1.0 NaN 888233.02 44411.65 932644.67 SO-26013562 2026-10-07 11:59:58 2026-10 13942 BI/2627/001688 2026-10-09 4 INR 1.0 NaN 453525.98 22676.30 476202.28 SO-26013620 2026-10-09 11:01:56 2026-10 13943 BI/2627/001689 2026-10-09 4 INR 1.0 NaN 476277.08 23813.85 500090.93 SO-26013366 2026-10-09 14:58:00 2026-10 13980 BI/2627/001726 2026-10-15 4 INR 1.0 NaN 478857.80 23942.89 502800.69 SO-26013628 2026-10-15 16:55:44 2026-10 14015 BI/2627/001761 2026-10-20 4 INR 1.0 NaN 1177645.63 58882.28 1236527.91 SO-26013526 2026-10-20 19:56:25 2026-10 14035 BI/2627/001781 2026-10-21 4 INR 1.0 NaN 1411096.81 70554.84 1481651.65 SO-26013640 2026-10-21 10:16:31 2026-10 14036 BI/2627/001782 2026-10-21 4 INR 1.0 NaN 1591714.80 79585.74 1671300.54 SO-26013572 2026-10-21 13:08:11 2026-10 14059 BI/2627/001805 2026-10-22 4 INR 1.0 NaN 2290465.44 114523.27 2404988.71 SO-26013507 2026-10-22 18:12:49 2026-10 14085 BI/2627/001831 2026-10-23 4 INR 1.0 NaN 1163909.81 58195.49 1222105.30 SO-26013578 2026-10-23 17:32:21 2026-10 14121 BI/2627/001867 2026-10-26 4 INR 1.0 NaN 590138.38 29506.92 619645.30 SO-26013868 2026-10-26 12:03:20 2026-10 14156 BI/2627/001902 2026-10-30 4 INR 1.0 NaN 498660.14 24933.01 523593.15 SO-26013685 2026-10-30 11:30:06 2026-10 name reason Ponnavra Fabrics Return 390720.93 Skarfab Rate difference 202303.92 Ponnavra Fabrics Rate difference 190157.81 Merai Apparels Rate difference 78261.72 Kollivra Knits Return 72439.02 Palvra Garments Return 56600.10 Merai Apparels Return 54036.13 Tatrava Cloth Return 49021.17 Moyvra Garments Rate difference 47092.57 Atelier Saône Rate difference 45205.69 Wattmeer Textil Return 44957.99 Tessuti Ombra Return 43012.71 Name: net_amount, dtype: float64 customer_id 1 2 3 4 m 2026-08 0.139906 0.069332 0.055787 0.011258 2026-09 0.089187 0.121783 0.077366 0.014790 2026-10 0.045648 0.024315 0.012243 0.266924 ``` **Code (code_interpreter):** ``` print(i[i.customer_id.isin([1,2,3]) & (i.m=='2026-10')].groupby(['customer_id']).invoice_date.agg(['min','max','size'])) t=i.copy();t['late']=(pd.to_datetime(t.invoice_date).dt.days_in_month-pd.to_datetime(t.invoice_date).dt.day)<7 print(t.groupby(['m','late']).net_amount.sum().unstack().tail(13)/1e5) print((p.iloc[-1,4:18].sum(),p.loc['2025-10',4]/1e5,(p.iloc[-1].sum()-p.iloc[-1,3])/(p.loc['2025-10'].sum()-p.loc['2025-10',4])-1)) ``` **Output:** ``` min max size customer_id 1 2026-10-01 2026-10-09 2 2 2026-10-08 2026-10-08 1 3 2026-10-06 2026-10-06 1 late False True m 2025-10 369.368236 102.109060 2025-11 349.840105 108.864919 2025-12 330.479811 150.667220 2026-01 336.234795 117.620834 2026-02 331.254741 128.632381 2026-03 349.621509 181.435252 2026-04 335.852002 141.460561 2026-05 371.779408 111.634494 2026-06 333.507125 168.184012 2026-07 356.166257 125.186223 2026-08 337.318064 117.028653 2026-09 311.396328 179.270002 2026-10 414.604280 63.833087 (np.float64(0.0), np.float64(9.787524399999999), np.float64(-0.2518627186134068)) ``` **Code (code_interpreter):** ``` b=i[i.customer_id<=3].copy();print(b.groupby('m').invoice_date.max().tail(20));print(p.loc['2025-10',1:3].sum()/1e5,p.iloc[-1,:3].sum()/1e5,p.iloc[-7:-1,:3].sum(axis=1).median()/1e5) ``` **Output:** ``` m 2025-03 2025-03-28 2025-04 2025-04-29 2025-05 2025-05-30 2025-06 2025-06-28 2025-07 2025-07-31 2025-08 2025-08-30 2025-09 2025-09-30 2025-10 2025-10-29 2025-11 2025-11-29 2025-12 2025-12-31 2026-01 2026-01-27 2026-02 2026-02-28 2026-03 2026-03-28 2026-04 2026-04-30 2026-05 2026-05-30 2026-06 2026-06-27 2026-07 2026-07-31 2026-08 2026-08-29 2026-09 2026-09-28 2026-10 2026-10-09 Name: invoice_date, dtype: object 80.3177622 38.103909800000004 119.62503210000001 ``` **Assistant:** **Net revenue grew 2.9% year over year to ₹33.04 crore in April–October 2026, but one customer, Merai Apparels, accounted for more than the entire gain.** Three changes are worth acting on: | What changed | What to check | |---|---| | **14 regular customers stopped appearing on invoices.** Accounts C0005–C0018 had each been invoiced every month from April 2024 through June 2026. None had an invoice in August, September or October 2026, although all are still marked active. Together they generated ₹1.39 crore in those same three months last year. | Start here. Ask the account owners whether orders stopped, moved to different customer codes, or are waiting to be billed. The ledger shows a break in billing, not proof of churn. | | **Merai masked a much weaker October.** Company net revenue was nearly flat at ₹4.64 crore, but Merai rose from ₹9.79 lakh in October 2025 to ₹1.24 crore in October 2026. It supplied 26.7% of the month’s net revenue. Excluding Merai from both periods, October was **down 25.2%**. | Check Merai’s forward orders before treating October’s sales as repeatable. | | **Three other key accounts went quiet early in October.** Ravira Exports, Tessora EU and Skarfab had no invoices after October 9. Together they generated ₹38.1 lakh that month, versus ₹80.3 lakh a year earlier. | Reconcile late-October dispatches and open orders with early-November invoices. That will help distinguish a billing delay from weaker demand. | Figures exclude GST and deduct credit notes on the date issued, following your reporting definition. ## Final answer (scored) **Net revenue grew 2.9% year over year to ₹33.04 crore in April–October 2026, but one customer, Merai Apparels, accounted for more than the entire gain.** Three changes are worth acting on: | What changed | What to check | |---|---| | **14 regular customers stopped appearing on invoices.** Accounts C0005–C0018 had each been invoiced every month from April 2024 through June 2026. None had an invoice in August, September or October 2026, although all are still marked active. Together they generated ₹1.39 crore in those same three months last year. | Start here. Ask the account owners whether orders stopped, moved to different customer codes, or are waiting to be billed. The ledger shows a break in billing, not proof of churn. | | **Merai masked a much weaker October.** Company net revenue was nearly flat at ₹4.64 crore, but Merai rose from ₹9.79 lakh in October 2025 to ₹1.24 crore in October 2026. It supplied 26.7% of the month’s net revenue. Excluding Merai from both periods, October was **down 25.2%**. | Check Merai’s forward orders before treating October’s sales as repeatable. | | **Three other key accounts went quiet early in October.** Ravira Exports, Tessora EU and Skarfab had no invoices after October 9. Together they generated ₹38.1 lakh that month, versus ₹80.3 lakh a year earlier. | Reconcile late-October dispatches and open orders with early-November invoices. That will help distinguish a billing delay from weaker demand. | Figures exclude GST and deduct credit notes on the date issued, following your reporting definition.