@v587d/capital-generation 2.7.6 → 2.7.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (203) hide show
  1. package/CHANGELOG.md +78 -0
  2. package/README.md +5 -4
  3. package/THIRD_PARTY_NOTICES.md +14 -3
  4. package/capital-config/client.js +4 -4
  5. package/capital-config/package.json +1 -1
  6. package/capital-watchlist/package.json +1 -1
  7. package/chart-ui/package.json +1 -1
  8. package/lib/agents/selected-skills-provider.js +91 -41
  9. package/lib/index.js +3 -2
  10. package/lib/web-retriever/local-fetch.d.ts +1 -1
  11. package/lib/web-retriever/local-fetch.js +1 -1
  12. package/lib/web-retriever/wind-client.d.ts +1 -1
  13. package/lib/web-retriever/wind-client.js +1 -1
  14. package/package.json +2 -1
  15. package/selected-skills/README.md +3 -1
  16. package/selected-skills/catalog.js +155 -0
  17. package/selected-skills/financeskills/LICENSE +21 -0
  18. package/selected-skills/financeskills/UPSTREAM.md +202 -0
  19. package/selected-skills/financeskills/skills/ai-anomaly-detection/EXAMPLE.md +21 -0
  20. package/selected-skills/financeskills/skills/ai-anomaly-detection/SKILL.md +84 -0
  21. package/selected-skills/financeskills/skills/ai-anomaly-detection/references/feature-engineering.md +20 -0
  22. package/selected-skills/financeskills/skills/ai-anomaly-detection/references/ml-algorithms.md +28 -0
  23. package/selected-skills/financeskills/skills/aro-computation/EXAMPLE.md +21 -0
  24. package/selected-skills/financeskills/skills/aro-computation/SKILL.md +82 -0
  25. package/selected-skills/financeskills/skills/aro-computation/references/aro-standards.md +22 -0
  26. package/selected-skills/financeskills/skills/aro-computation/references/pv-math.md +27 -0
  27. package/selected-skills/financeskills/skills/audit-checklist/EXAMPLE.md +17 -0
  28. package/selected-skills/financeskills/skills/audit-checklist/SKILL.md +77 -0
  29. package/selected-skills/financeskills/skills/audit-checklist/references/internal-controls.md +36 -0
  30. package/selected-skills/financeskills/skills/audit-checklist/references/isa-standards.md +26 -0
  31. package/selected-skills/financeskills/skills/automated-reconciliation/EXAMPLE.md +21 -0
  32. package/selected-skills/financeskills/skills/automated-reconciliation/SKILL.md +87 -0
  33. package/selected-skills/financeskills/skills/automated-reconciliation/assets/reconciliation-statement-template.md +31 -0
  34. package/selected-skills/financeskills/skills/automated-reconciliation/references/fuzzy-logic.md +27 -0
  35. package/selected-skills/financeskills/skills/automated-reconciliation/references/rec-controls.md +28 -0
  36. package/selected-skills/financeskills/skills/banking-compliance/EXAMPLE.md +21 -0
  37. package/selected-skills/financeskills/skills/banking-compliance/SKILL.md +82 -0
  38. package/selected-skills/financeskills/skills/banking-compliance/references/basel-iii-framework.md +26 -0
  39. package/selected-skills/financeskills/skills/banking-compliance/references/risk-weights.md +32 -0
  40. package/selected-skills/financeskills/skills/budget-forecast/EXAMPLE.md +21 -0
  41. package/selected-skills/financeskills/skills/budget-forecast/SKILL.md +87 -0
  42. package/selected-skills/financeskills/skills/budget-forecast/references/forecasting-best-practices.md +26 -0
  43. package/selected-skills/financeskills/skills/budget-forecast/references/scenario-analysis.md +25 -0
  44. package/selected-skills/financeskills/skills/close-management/EXAMPLE.md +17 -0
  45. package/selected-skills/financeskills/skills/close-management/SKILL.md +85 -0
  46. package/selected-skills/financeskills/skills/close-management/references/close-task-library.md +32 -0
  47. package/selected-skills/financeskills/skills/company-valuation/EXAMPLE.md +21 -0
  48. package/selected-skills/financeskills/skills/company-valuation/SKILL.md +80 -0
  49. package/selected-skills/financeskills/skills/company-valuation/references/terminal-value-guide.md +33 -0
  50. package/selected-skills/financeskills/skills/corporate-consolidation/EXAMPLE.md +21 -0
  51. package/selected-skills/financeskills/skills/corporate-consolidation/SKILL.md +84 -0
  52. package/selected-skills/financeskills/skills/corporate-consolidation/references/consolidation-standard.md +28 -0
  53. package/selected-skills/financeskills/skills/corporate-consolidation/references/minority-interest.md +25 -0
  54. package/selected-skills/financeskills/skills/credit-analysis/EXAMPLE.md +21 -0
  55. package/selected-skills/financeskills/skills/credit-analysis/SKILL.md +84 -0
  56. package/selected-skills/financeskills/skills/credit-analysis/references/covenant-guide.md +26 -0
  57. package/selected-skills/financeskills/skills/crypto-accounting/EXAMPLE.md +21 -0
  58. package/selected-skills/financeskills/skills/crypto-accounting/SKILL.md +81 -0
  59. package/selected-skills/financeskills/skills/crypto-accounting/references/fasb-crypto.md +26 -0
  60. package/selected-skills/financeskills/skills/crypto-accounting/references/ifrs-crypto.md +25 -0
  61. package/selected-skills/financeskills/skills/cvp-breakeven/EXAMPLE.md +21 -0
  62. package/selected-skills/financeskills/skills/cvp-breakeven/SKILL.md +78 -0
  63. package/selected-skills/financeskills/skills/cvp-breakeven/references/cvp-patterns.md +28 -0
  64. package/selected-skills/financeskills/skills/debt-payoff/EXAMPLE.md +21 -0
  65. package/selected-skills/financeskills/skills/debt-payoff/SKILL.md +94 -0
  66. package/selected-skills/financeskills/skills/debt-payoff/references/debt-strategies.md +32 -0
  67. package/selected-skills/financeskills/skills/debt-payoff/references/interest-calculations.md +27 -0
  68. package/selected-skills/financeskills/skills/debt-restructuring/EXAMPLE.md +21 -0
  69. package/selected-skills/financeskills/skills/debt-restructuring/SKILL.md +79 -0
  70. package/selected-skills/financeskills/skills/debt-restructuring/references/creditor-priority.md +26 -0
  71. package/selected-skills/financeskills/skills/debt-restructuring/references/restructuring-types.md +24 -0
  72. package/selected-skills/financeskills/skills/deferred-tax/EXAMPLE.md +21 -0
  73. package/selected-skills/financeskills/skills/deferred-tax/SKILL.md +86 -0
  74. package/selected-skills/financeskills/skills/deferred-tax/references/td-catalogue.md +39 -0
  75. package/selected-skills/financeskills/skills/earned-value-mgmt/EXAMPLE.md +21 -0
  76. package/selected-skills/financeskills/skills/earned-value-mgmt/SKILL.md +79 -0
  77. package/selected-skills/financeskills/skills/earned-value-mgmt/references/forecasting-eac.md +27 -0
  78. package/selected-skills/financeskills/skills/earned-value-mgmt/references/pmi-evm.md +29 -0
  79. package/selected-skills/financeskills/skills/ecl-computation/EXAMPLE.md +21 -0
  80. package/selected-skills/financeskills/skills/ecl-computation/SKILL.md +85 -0
  81. package/selected-skills/financeskills/skills/ecl-computation/references/ifrs9-standard.md +27 -0
  82. package/selected-skills/financeskills/skills/ecl-computation/references/risk-modeling.md +26 -0
  83. package/selected-skills/financeskills/skills/esg-reporting/EXAMPLE.md +17 -0
  84. package/selected-skills/financeskills/skills/esg-reporting/SKILL.md +79 -0
  85. package/selected-skills/financeskills/skills/esg-reporting/references/ghg-protocol.md +22 -0
  86. package/selected-skills/financeskills/skills/esg-reporting/references/sasb-map.md +25 -0
  87. package/selected-skills/financeskills/skills/financial-analysis/EXAMPLE.md +21 -0
  88. package/selected-skills/financeskills/skills/financial-analysis/SKILL.md +108 -0
  89. package/selected-skills/financeskills/skills/financial-analysis/assets/analysis-memo-template.md +31 -0
  90. package/selected-skills/financeskills/skills/financial-analysis/references/accounting-standards.md +45 -0
  91. package/selected-skills/financeskills/skills/financial-analysis/references/ratio-definitions.md +14 -0
  92. package/selected-skills/financeskills/skills/fixed-asset-accounting/EXAMPLE.md +21 -0
  93. package/selected-skills/financeskills/skills/fixed-asset-accounting/SKILL.md +78 -0
  94. package/selected-skills/financeskills/skills/fixed-asset-accounting/references/useful-life-guide.md +30 -0
  95. package/selected-skills/financeskills/skills/forensic-accounting/EXAMPLE.md +21 -0
  96. package/selected-skills/financeskills/skills/forensic-accounting/SKILL.md +91 -0
  97. package/selected-skills/financeskills/skills/forensic-accounting/references/benfords-law.md +24 -0
  98. package/selected-skills/financeskills/skills/forensic-accounting/references/fraud-triangle.md +26 -0
  99. package/selected-skills/financeskills/skills/insurance-reserving/EXAMPLE.md +21 -0
  100. package/selected-skills/financeskills/skills/insurance-reserving/SKILL.md +82 -0
  101. package/selected-skills/financeskills/skills/insurance-reserving/references/actuarial-methods.md +33 -0
  102. package/selected-skills/financeskills/skills/insurance-reserving/references/insurance-metrics.md +26 -0
  103. package/selected-skills/financeskills/skills/intercompany-accounting/EXAMPLE.md +21 -0
  104. package/selected-skills/financeskills/skills/intercompany-accounting/SKILL.md +79 -0
  105. package/selected-skills/financeskills/skills/intercompany-accounting/references/elimination-entries.md +35 -0
  106. package/selected-skills/financeskills/skills/inventory-costing/EXAMPLE.md +21 -0
  107. package/selected-skills/financeskills/skills/inventory-costing/SKILL.md +80 -0
  108. package/selected-skills/financeskills/skills/inventory-costing/references/costing-examples.md +31 -0
  109. package/selected-skills/financeskills/skills/investment-analysis/EXAMPLE.md +21 -0
  110. package/selected-skills/financeskills/skills/investment-analysis/SKILL.md +82 -0
  111. package/selected-skills/financeskills/skills/investment-analysis/references/competitive-advantage.md +31 -0
  112. package/selected-skills/financeskills/skills/investment-analysis/references/valuation-guide.md +29 -0
  113. package/selected-skills/financeskills/skills/journal-entry/EXAMPLE.md +21 -0
  114. package/selected-skills/financeskills/skills/journal-entry/SKILL.md +94 -0
  115. package/selected-skills/financeskills/skills/journal-entry/assets/journal-entry-template.md +21 -0
  116. package/selected-skills/financeskills/skills/journal-entry/references/entry-patterns.md +51 -0
  117. package/selected-skills/financeskills/skills/lbo-modeling/EXAMPLE.md +21 -0
  118. package/selected-skills/financeskills/skills/lbo-modeling/SKILL.md +88 -0
  119. package/selected-skills/financeskills/skills/lbo-modeling/references/debt-structures.md +22 -0
  120. package/selected-skills/financeskills/skills/lbo-modeling/references/lbo-best-practices.md +27 -0
  121. package/selected-skills/financeskills/skills/lease-accounting/EXAMPLE.md +21 -0
  122. package/selected-skills/financeskills/skills/lease-accounting/SKILL.md +88 -0
  123. package/selected-skills/financeskills/skills/lease-accounting/assets/commencement-summary-template.md +28 -0
  124. package/selected-skills/financeskills/skills/lease-accounting/references/ibr-guide.md +26 -0
  125. package/selected-skills/financeskills/skills/net-worth-tracker/EXAMPLE.md +21 -0
  126. package/selected-skills/financeskills/skills/net-worth-tracker/SKILL.md +98 -0
  127. package/selected-skills/financeskills/skills/net-worth-tracker/references/asset-valuation.md +40 -0
  128. package/selected-skills/financeskills/skills/net-worth-tracker/references/net-worth-benchmarks.md +33 -0
  129. package/selected-skills/financeskills/skills/nlp-earnings-sentiment/EXAMPLE.md +17 -0
  130. package/selected-skills/financeskills/skills/nlp-earnings-sentiment/SKILL.md +77 -0
  131. package/selected-skills/financeskills/skills/nlp-earnings-sentiment/references/finbert-guide.md +26 -0
  132. package/selected-skills/financeskills/skills/nlp-earnings-sentiment/references/linguistic-finance.md +23 -0
  133. package/selected-skills/financeskills/skills/oil-gas-valuation/EXAMPLE.md +21 -0
  134. package/selected-skills/financeskills/skills/oil-gas-valuation/SKILL.md +86 -0
  135. package/selected-skills/financeskills/skills/oil-gas-valuation/references/sec-reporting.md +22 -0
  136. package/selected-skills/financeskills/skills/oil-gas-valuation/references/spe-standards.md +25 -0
  137. package/selected-skills/financeskills/skills/personal-budgeting/EXAMPLE.md +21 -0
  138. package/selected-skills/financeskills/skills/personal-budgeting/SKILL.md +100 -0
  139. package/selected-skills/financeskills/skills/personal-budgeting/references/budgeting-methods.md +40 -0
  140. package/selected-skills/financeskills/skills/personal-budgeting/references/spending-categories.md +40 -0
  141. package/selected-skills/financeskills/skills/predictive-burn-rate/EXAMPLE.md +21 -0
  142. package/selected-skills/financeskills/skills/predictive-burn-rate/SKILL.md +82 -0
  143. package/selected-skills/financeskills/skills/predictive-burn-rate/references/startup-metrics.md +27 -0
  144. package/selected-skills/financeskills/skills/predictive-burn-rate/references/time-series-forecasting.md +22 -0
  145. package/selected-skills/financeskills/skills/product-profitability/EXAMPLE.md +21 -0
  146. package/selected-skills/financeskills/skills/product-profitability/SKILL.md +83 -0
  147. package/selected-skills/financeskills/skills/product-profitability/references/allocation-logic.md +28 -0
  148. package/selected-skills/financeskills/skills/product-profitability/references/unit-economics.md +30 -0
  149. package/selected-skills/financeskills/skills/retirement-planning/EXAMPLE.md +21 -0
  150. package/selected-skills/financeskills/skills/retirement-planning/SKILL.md +98 -0
  151. package/selected-skills/financeskills/skills/retirement-planning/references/compound-growth.md +38 -0
  152. package/selected-skills/financeskills/skills/retirement-planning/references/retirement-fundamentals.md +29 -0
  153. package/selected-skills/financeskills/skills/revenue-recognition/EXAMPLE.md +21 -0
  154. package/selected-skills/financeskills/skills/revenue-recognition/SKILL.md +86 -0
  155. package/selected-skills/financeskills/skills/revenue-recognition/assets/allocation-workpaper-template.md +30 -0
  156. package/selected-skills/financeskills/skills/revenue-recognition/references/ifrs15-guide.md +28 -0
  157. package/selected-skills/financeskills/skills/revenue-recognition/references/saas-rev-rec.md +26 -0
  158. package/selected-skills/financeskills/skills/risk-assessment/EXAMPLE.md +21 -0
  159. package/selected-skills/financeskills/skills/risk-assessment/SKILL.md +83 -0
  160. package/selected-skills/financeskills/skills/risk-assessment/references/hedging-guide.md +24 -0
  161. package/selected-skills/financeskills/skills/risk-assessment/references/risk-metrics.md +24 -0
  162. package/selected-skills/financeskills/skills/sox-compliance/EXAMPLE.md +17 -0
  163. package/selected-skills/financeskills/skills/sox-compliance/SKILL.md +88 -0
  164. package/selected-skills/financeskills/skills/sox-compliance/references/sampling-methodology.md +27 -0
  165. package/selected-skills/financeskills/skills/startup-valuation/EXAMPLE.md +21 -0
  166. package/selected-skills/financeskills/skills/startup-valuation/SKILL.md +88 -0
  167. package/selected-skills/financeskills/skills/startup-valuation/references/berkus-method.md +25 -0
  168. package/selected-skills/financeskills/skills/startup-valuation/references/vc-method.md +23 -0
  169. package/selected-skills/financeskills/skills/statement-preparation/EXAMPLE.md +21 -0
  170. package/selected-skills/financeskills/skills/statement-preparation/SKILL.md +86 -0
  171. package/selected-skills/financeskills/skills/statement-preparation/references/accruals-deferrals.md +24 -0
  172. package/selected-skills/financeskills/skills/statement-preparation/references/cash-flow-method.md +32 -0
  173. package/selected-skills/financeskills/skills/tax-efficient-investing/EXAMPLE.md +21 -0
  174. package/selected-skills/financeskills/skills/tax-efficient-investing/SKILL.md +97 -0
  175. package/selected-skills/financeskills/skills/tax-efficient-investing/references/account-types.md +33 -0
  176. package/selected-skills/financeskills/skills/tax-efficient-investing/references/asset-location.md +36 -0
  177. package/selected-skills/financeskills/skills/tax-planning/EXAMPLE.md +21 -0
  178. package/selected-skills/financeskills/skills/tax-planning/SKILL.md +93 -0
  179. package/selected-skills/financeskills/skills/tax-planning/references/common-deductions.md +28 -0
  180. package/selected-skills/financeskills/skills/tax-planning/references/tax-code-lookup.md +25 -0
  181. package/selected-skills/financeskills/skills/three-statement-modeling/EXAMPLE.md +21 -0
  182. package/selected-skills/financeskills/skills/three-statement-modeling/SKILL.md +84 -0
  183. package/selected-skills/financeskills/skills/three-statement-modeling/references/model-checks.md +32 -0
  184. package/selected-skills/financeskills/skills/treasury-management/EXAMPLE.md +21 -0
  185. package/selected-skills/financeskills/skills/treasury-management/SKILL.md +83 -0
  186. package/selected-skills/financeskills/skills/treasury-management/references/fx-hedging.md +27 -0
  187. package/selected-skills/financeskills/skills/treasury-management/references/liquidity-metrics.md +24 -0
  188. package/selected-skills/financeskills/skills/variance-analysis/EXAMPLE.md +21 -0
  189. package/selected-skills/financeskills/skills/variance-analysis/SKILL.md +78 -0
  190. package/selected-skills/financeskills/skills/variance-analysis/references/overhead-logic.md +24 -0
  191. package/selected-skills/financeskills/skills/variance-analysis/references/variance-math.md +35 -0
  192. package/selected-skills/financeskills/skills/venture-debt/EXAMPLE.md +21 -0
  193. package/selected-skills/financeskills/skills/venture-debt/SKILL.md +84 -0
  194. package/selected-skills/financeskills/skills/venture-debt/references/saas-debt-metrics.md +26 -0
  195. package/selected-skills/financeskills/skills/venture-debt/references/venture-lending.md +23 -0
  196. package/selected-skills/financeskills/skills/wacc-computation/EXAMPLE.md +21 -0
  197. package/selected-skills/financeskills/skills/wacc-computation/SKILL.md +98 -0
  198. package/selected-skills/financeskills/skills/wacc-computation/assets/wacc-memo-template.md +40 -0
  199. package/selected-skills/financeskills/skills/wacc-computation/references/beta-math.md +24 -0
  200. package/selected-skills/financeskills/skills/wacc-computation/references/capm-basics.md +24 -0
  201. package/selected-skills/financeskills/skills/working-capital-analysis/EXAMPLE.md +21 -0
  202. package/selected-skills/financeskills/skills/working-capital-analysis/SKILL.md +83 -0
  203. package/selected-skills/financeskills/skills/working-capital-analysis/references/wc-metrics.md +30 -0
@@ -0,0 +1,39 @@
1
+ # Temporary Difference Catalogue (worked examples)
2
+
3
+ Assume 30% corporate rate (Nigeria CIT for large companies; substitute local rate).
4
+
5
+ ## 1. PP&E — Capital Allowances Faster Than Depreciation
6
+ Asset cost 100M. Year 1: book depreciation 10M (carrying 90M); capital allowances 35M (tax base 65M).
7
+ TD = 90 − 65 = 25M taxable → **DTL 7.5M**. Reverses as allowances exhaust while depreciation continues.
8
+
9
+ ## 2. Provision Deductible on Payment
10
+ Leave pay provision 8M booked; deductible only when paid → tax base 0.
11
+ TD = deductible 8M → **DTA 2.4M**, recognized if future profits probable.
12
+
13
+ ## 3. Tax Losses
14
+ Unused losses 50M, indefinite carryforward. Forecast supports utilization of 30M over planning horizon → recognize **DTA 9M** (30M × 30%); disclose unrecognized 20M. Recent-loss history demands convincing evidence — board-approved forecasts with achievable assumptions, contracted revenues.
15
+
16
+ ## 4. Revaluation Surplus
17
+ Building revalued +40M, tax base unchanged → DTL 12M **through OCI**, not P&L.
18
+
19
+ ## 5. Leases (post-2021 IAS 12 amendment)
20
+ ROU 31.3M and liability 31.3M at commencement, both tax bases nil (payments deducted when paid): recognize gross DTL 9.39M (ROU) and DTA 9.39M (liability) — net nil day one, diverges as depreciation and liability unwind at different paces.
21
+
22
+ ## 6. Intragroup Profit in Inventory
23
+ Sub sold goods to parent at 5M profit; still in parent inventory at year-end. Eliminate profit on consolidation; tax was PAID by the sub → **DTA = 5M × buyer's rate** (consolidation-level entry).
24
+
25
+ ## 7. ECL on Loans (banks)
26
+ ECL booked 100M; tax allows specific impairments only, say 60M → deductible TD 40M → DTA 12M.
27
+
28
+ ## ETR Reconciliation Skeleton
29
+ ```
30
+ Profit before tax 1,000
31
+ Tax at statutory 30% 300
32
+ + Non-deductible expenses (fines, ent.) 15
33
+ − Exempt income (FGN bond interest) (24)
34
+ + Unrecognized DTA on current-year losses 10
35
+ ± Rate change remeasurement 6
36
+ ± Prior-year true-up (4)
37
+ = Tax expense 303 → ETR 30.3%
38
+ ```
39
+ Every line needs a workpaper. An unexplained plug means the TD schedule and the current tax computation disagree — reconcile them, don't force it.
@@ -0,0 +1,21 @@
1
+ # Worked Example - earned-value-mgmt
2
+
3
+ ## Ask
4
+
5
+ > Our project was supposed to be 50% done ($500k PV). We've spent $600k (AC) but we are only 40% done (EV = $400k). How are we doing?
6
+
7
+ ## What a correct response contains
8
+
9
+ Should calculate CPI (400/600 = 0.67). Should calculate SPI (400/500 = 0.80). Should conclude the project is over budget and behind schedule. Should provide a Project Performance Dashboard.
10
+
11
+ ## File-driven variant
12
+
13
+ With fixture(s) `evals/files/project_status.csv`:
14
+
15
+ > Assess the project in the attached status file (evals/files/project_status.csv): compute CV, SV, CPI, SPI, EAC (CPI method), and TCPI, and state whether the original budget is still credible.
16
+
17
+ Expected: CV -70,000, SV -50,000, CPI 0.865, SPI 0.90, EAC $2,311,111, TCPI 1.047.
18
+
19
+ ## Compute, don't estimate
20
+
21
+ All figures above come from [`scripts/calculate.py`](./scripts/calculate.py) - import its functions rather than doing arithmetic in prose.
@@ -0,0 +1,79 @@
1
+ ---
2
+ name: earned-value-mgmt
3
+ description: When the user wants to track the financial progress of a large project. Also use when the user mentions "EVM," "Cost Performance Index (CPI)," "Schedule Performance Index (SPI)," "Estimated at Completion (EAC)," or "project financial audit."
4
+ metadata:
5
+ version: 1.0.0
6
+ ---
7
+
8
+ # Earned Value Management (EVM)
9
+
10
+ You are a Project Finance Manager. Your goal is to integrate project scope, schedule, and cost to provide a clear view of whether a project is on track to finish on time and on budget.
11
+
12
+ ## Initial Assessment
13
+
14
+ 1. **The Baseline**
15
+ - **Planned Value (PV)**: The budgeted cost of work scheduled to be done.
16
+ - **BAC**: Budget at Completion.
17
+
18
+ 2. **The Reality**
19
+ - **Actual Cost (AC)**: The cost actually incurred for the work done.
20
+ - **Earned Value (EV)**: The budgeted cost of work *actually* performed.
21
+
22
+ ---
23
+
24
+ ## EVM Framework
25
+
26
+ ### The Key Ratios
27
+ 1. **Cost Performance Index (CPI)**: `EV / AC`. (Target > 1.0).
28
+ 2. **Schedule Performance Index (SPI)**: `EV / PV`. (Target > 1.0).
29
+
30
+ ### The Forecasts
31
+ 1. **Estimate at Completion (EAC)**: `BAC / CPI`. (Predicts total cost based on current performance).
32
+ 2. **Variance at Completion (VAC)**: `BAC - EAC`.
33
+
34
+ ---
35
+
36
+ ## Technical Project Steps
37
+
38
+ ### 1. Percent Complete Calculation
39
+ - Determine the objective completion of each task (e.g., 50% of the foundation is poured).
40
+
41
+ ### 2. To-Complete Performance Index (TCPI)
42
+ - `(BAC - EV) / (BAC - AC)`.
43
+ - This tells you the efficiency needed on remaining work to stay within budget.
44
+
45
+ ---
46
+
47
+ ## Output Format
48
+
49
+ ### Project Performance Dashboard
50
+
51
+ **Key Metrics**
52
+ - **CPI**: (e.g., 0.92 - Over Budget).
53
+ - **SPI**: (e.g., 1.05 - Ahead of Schedule).
54
+
55
+ **Forecasting**
56
+ - **Original Budget (BAC)**: $1M.
57
+ - **Projected Final Cost (EAC)**: $1.08M.
58
+ - **Estimated Completion Date**: (Based on SPI).
59
+
60
+ **Corrective Actions**
61
+ - "Project is trending over budget due to higher labor rates; SPI suggests we can trade speed for cost-cutting."
62
+
63
+ ---
64
+
65
+ ## Scripts
66
+ - [calculate.py](./scripts/calculate.py): Deterministic functions for this skill's core computations. Run `python3 scripts/calculate.py` to self-test; import the functions instead of doing mental math.
67
+
68
+ ---
69
+
70
+ ## References
71
+ - [PMBOK EVM Standards](./references/pmi-evm.md): Official project management metrics.
72
+ - [EAC Forecasting Models](./references/forecasting-eac.md): Different ways to calculate final cost.
73
+
74
+ ---
75
+
76
+ ## Related Skills
77
+ - **budget-forecast**: For setting the original project budget.
78
+ - **financial-analysis**: For analyzing the impact of project overruns on company health.
79
+ - **capital-budgeting**: For evaluating if the project still meets its NPV targets.
@@ -0,0 +1,27 @@
1
+ # Estimate at Completion (EAC) Forecasting
2
+
3
+ ## The EAC Family — pick by diagnosis
4
+ | Formula | Assumption | Use When |
5
+ |---|---|---|
6
+ | `EAC = AC + (BAC − EV)` | Past variance was one-off; remaining work at plan | Isolated, corrected problem |
7
+ | `EAC = BAC / CPI` | Cost efficiency to date persists | Most common default; systemic cost issue |
8
+ | `EAC = AC + (BAC − EV)/(CPI × SPI)` | Cost AND schedule pressure both persist | Behind schedule with acceleration costs |
9
+ | `EAC = AC + bottom-up ETC` | Re-estimate remaining work | Major scope/approach change; mandated at thresholds |
10
+
11
+ `ETC = EAC − AC`; `VAC = BAC − EAC` (negative = overrun).
12
+
13
+ ## TCPI — the reality check
14
+ `TCPI(BAC) = (BAC − EV) / (BAC − AC)` = efficiency required on ALL remaining work to land on budget.
15
+ - TCPI > 1.10 while CPI < 0.95: recovery is fantasy — re-baseline or fund the variance.
16
+ - Compare TCPI against the project's best 3-month historical CPI: if required > best ever achieved, escalate.
17
+
18
+ ## Research-Backed Rules of Thumb (DoD studies)
19
+ - CPI stabilizes by ~20% completion; it rarely improves more than 10% thereafter.
20
+ - The overrun at completion is usually WORSE than the overrun to date predicts.
21
+ - Therefore: CPI-based EAC at 20%+ complete is a floor, not a ceiling.
22
+
23
+ ## Schedule Forecasting
24
+ SPI($) degenerates to 1.0 at completion — use **earned schedule**: `ES = time at which planned value equaled current EV`; `SPI(t) = ES / actual time`; forecast duration = planned duration / SPI(t).
25
+
26
+ ## Reporting Discipline
27
+ Show EAC range (best/likely/worst from the formula family), VAC, TCPI, and the driver narrative (rate vs. usage vs. scope — tie to variance-analysis decomposition).
@@ -0,0 +1,29 @@
1
+ # PMI Earned Value Management Standards
2
+
3
+ The global standard for project performance measurement.
4
+
5
+ ## 🏛️ Core Metrics
6
+
7
+ ### 1. The Triad
8
+ - **Planned Value (PV)**: Budgeted cost for the work scheduled to be completed.
9
+ - **Actual Cost (AC)**: Total cost incurred for the work performed.
10
+ - **Earned Value (EV)**: Budgeted cost for the work actually performed.
11
+
12
+ ### 2. Performance Indices
13
+ - **CPI (Cost Performance Index)**: `EV / AC`.
14
+ - > 1.0: Under budget.
15
+ - < 1.0: Over budget.
16
+ - **SPI (Schedule Performance Index)**: `EV / PV`.
17
+ - > 1.0: Ahead of schedule.
18
+ - < 1.0: Behind schedule.
19
+
20
+ ---
21
+
22
+ ## 🔍 Forecasting (EAC)
23
+ **Estimate at Completion (EAC)**: The expected total cost of the project.
24
+ - **Formula 1 (Current rate continues)**: `BAC / CPI`.
25
+ - **Formula 2 (Remaining work at budgeted rate)**: `AC + (BAC - EV)`.
26
+
27
+ ## 🔗 Sources
28
+ - [PMI: Practice Standard for Earned Value Management](https://www.pmi.org/pmbok-guide-standards/foundational/practice-standard-earned-value-management)
29
+ - [Project Management Institute (PMI)](https://www.pmi.org/)
@@ -0,0 +1,21 @@
1
+ # Worked Example - ecl-computation
2
+
3
+ ## Ask
4
+
5
+ > We have $1M in trade receivables. Historically, 2% of these fail to pay. This year, the economy is heading into a recession. How should we calculate our provision?
6
+
7
+ ## What a correct response contains
8
+
9
+ Should recommend a Provision Matrix approach for trade receivables. Should discuss adjusting the historical 2% rate upwards for the expected recession. Should mention Stage 1/2/3 classification for non-trade assets. Should provide an ECL Analysis Report.
10
+
11
+ ## File-driven variant
12
+
13
+ With fixture(s) `evals/files/receivables_aging.csv`:
14
+
15
+ > Apply the IFRS 9 simplified approach (provision matrix) to the attached receivables aging (evals/files/receivables_aging.csv). Compute the loss allowance per bucket and in total, and state the coverage ratio.
16
+
17
+ Expected: Allowance per bucket from balance x loss rate; total $721,400; coverage 10.66% of gross receivables.
18
+
19
+ ## Compute, don't estimate
20
+
21
+ All figures above come from [`scripts/calculate.py`](./scripts/calculate.py) - import its functions rather than doing arithmetic in prose.
@@ -0,0 +1,85 @@
1
+ ---
2
+ name: ecl-computation
3
+ description: When the user wants to calculate Expected Credit Losses (ECL) under IFRS 9 or CECL (ASC 326). Also use when the user mentions "loan loss provisions," "probability of default," "PD/LGD/EAD," "impairment of financial assets," or "credit risk modeling."
4
+ metadata:
5
+ version: 1.0.0
6
+ ---
7
+
8
+ # ECL Computation (IFRS 9)
9
+
10
+ You are a Credit Risk Accountant. Your goal is to provide a forward-looking estimate of credit losses for financial assets, accounting for historical data, current conditions, and reasonable forecasts.
11
+
12
+ ## Initial Assessment
13
+
14
+ 1. **Asset Classification**
15
+ - Amortized Cost, FVOCI, or FVTPL?
16
+ - Is the asset "Stage 1" (Performing), "Stage 2" (Significant Increase in Credit Risk), or "Stage 3" (Credit-Impaired)?
17
+
18
+ 2. **The Components**
19
+ - **PD**: Probability of Default.
20
+ - **LGD**: Loss Given Default (percentage of exposure lost if default occurs).
21
+ - **EAD**: Exposure at Default (total value at risk).
22
+
23
+ 3. **Macroeconomic Overlay**
24
+ - What are the forward-looking economic scenarios (Base, Upside, Downside) and their probabilities?
25
+
26
+ ---
27
+
28
+ ## ECL Framework
29
+
30
+ ### The Formula
31
+ `ECL = PD * LGD * EAD * DF`
32
+ - **DF**: Discount Factor (to present value).
33
+
34
+ ### Priority Order
35
+ 1. **Segmentation** (Grouping similar assets - e.g., by geography or product).
36
+ 2. **Stage Assignment** (Determining if credit risk has increased significantly since inception).
37
+ 3. **Parameter Estimation** (Calculating PD, LGD, EAD).
38
+ 4. **Scenario Weighting** (Applying macroeconomic forecasts).
39
+ 5. **Loss Allowance Posting** (Generating the journal entry).
40
+
41
+ ---
42
+
43
+ ## Technical Computation Steps
44
+
45
+ ### 1. Simplified Approach (Trade Receivables)
46
+ - Use a **Provision Matrix** based on historical loss rates for different aging buckets (e.g., 0-30 days, 31-60 days).
47
+
48
+ ### 2. General Approach (Loans/Bonds)
49
+ - **12-month ECL** (Stage 1): Losses from defaults likely in the next 12 months.
50
+ - **Lifetime ECL** (Stage 2 & 3): Losses from defaults likely over the entire life of the asset.
51
+
52
+ ---
53
+
54
+ ## Output Format
55
+
56
+ ### ECL Analysis Report
57
+
58
+ **The Portfolio**
59
+ - Total Exposure at Default (EAD).
60
+ - Breakdown of assets by Stage (1, 2, 3).
61
+
62
+ **The Provision**
63
+ - **Total Loss Allowance**: $X.
64
+ - **Coverage Ratio**: (Allowance / EAD).
65
+
66
+ **Sensitivity & Scenarios**
67
+ - Impact on ECL if the probability of the "Downside" economic scenario increases by 10%.
68
+
69
+ ---
70
+
71
+ ## Scripts
72
+ - [calculate.py](./scripts/calculate.py): 12-month/lifetime ECL, provision matrix, and scenario weighting functions, kept as reviewable material. This plugin's research role has no shell and the scripts are not part of the installed package, so nothing here runs them: work the parameters from [PD/LGD/EAD Modeling](./references/risk-modeling.md) and the stage definitions in [IFRS 9 Impairment](./references/ifrs9-standard.md), show each calculation in the answer, and hand anything that needs real compute to the delegated `data_junior`.
73
+
74
+ ---
75
+
76
+ ## References
77
+ - [IFRS 9 Impairment](./references/ifrs9-standard.md): Official IASB guidance.
78
+ - [PD/LGD/EAD Modeling](./references/risk-modeling.md): Quantitative risk basics.
79
+
80
+ ---
81
+
82
+ ## Related Skills
83
+ - **risk-assessment**: For identifying the underlying credit risks.
84
+ - **financial-statement-prep**: For accurately reporting the impairment allowance.
85
+ - **corporate-consolidation**: For aggregating ECL across subsidiaries.
@@ -0,0 +1,27 @@
1
+ # IFRS 9 Expected Credit Loss: Standard Essentials
2
+
3
+ ## The Three-Stage Model
4
+ | Stage | Trigger | ECL Horizon | Interest Revenue Basis |
5
+ |---|---|---|---|
6
+ | 1 | No significant increase in credit risk (SICR) since origination | 12-month ECL | Gross carrying amount |
7
+ | 2 | SICR (rebuttable: >30 days past due) | Lifetime ECL | Gross carrying amount |
8
+ | 3 | Credit-impaired (default; rebuttable: >90 DPD) | Lifetime ECL | Net (amortized cost) |
9
+
10
+ ## SICR Indicators
11
+ Quantitative: PD doubling or breach of origination-PD threshold; 30+ DPD backstop. Qualitative: watchlist placement, forbearance, covenant breach, sector deterioration. Low-credit-risk exemption (investment grade) is optional, use sparingly.
12
+
13
+ ## ECL Formula
14
+ `ECL = Σt [ PDt × LGDt × EADt × Dt ]` — probability-weighted across at least 2–3 macro scenarios (base/upside/downside) with scenario weights documented.
15
+
16
+ - **PD**: Point-in-time, forward-looking (adjust TTC ratings with macro overlays — GDP, oil price, unemployment, policy rate).
17
+ - **LGD**: 1 − recovery rate; collateral haircuts, time-to-recovery discounting at EIR.
18
+ - **EAD**: Amortization profile + CCF on undrawn commitments.
19
+ - **D**: Discount at original effective interest rate.
20
+
21
+ ## Simplified Approach (Trade Receivables)
22
+ Lifetime ECL always; provision matrix by aging bucket with forward-looking adjustment. Document the loss-rate derivation (historical write-offs by bucket, adjusted).
23
+
24
+ ## Governance
25
+ - Staging overrides require credit committee sign-off.
26
+ - Post-model adjustments (PMAs/overlays) documented with quantified rationale and release criteria.
27
+ - Back-test: actual defaults vs. predicted PDs annually.
@@ -0,0 +1,26 @@
1
+ # Credit Risk Modeling for ECL
2
+
3
+ ## PD Modeling
4
+ - **Scorecard/logistic regression**: `PD = 1/(1+e^-(β0+βX))` on borrower financials + behavioral data. Standard for retail and SME books.
5
+ - **Rating-based**: Map internal/external ratings to PD via transition matrices; derive multi-year cumulative PDs from matrix powers (Markov assumption — validate it).
6
+ - **PIT conversion**: Vasicek single-factor: `PD_PIT = N[(N⁻¹(PD_TTC) + √ρ × Z)/√(1−ρ)]` where Z is the macro factor.
7
+
8
+ ## LGD Modeling
9
+ - Workout LGD: discounted recoveries less costs / EAD. Segment by collateral type and seniority.
10
+ - Downturn LGD for stressed scenarios.
11
+ - Floors: regulatory floors may apply; never let modeled LGD go negative.
12
+
13
+ ## EAD / CCF
14
+ - Term loans: amortization schedule.
15
+ - Revolvers: `EAD = Drawn + CCF × Undrawn`. Estimate CCF from defaulted-facility history (typical 40%–75%).
16
+
17
+ ## Macro Scenario Integration
18
+ 1. Select drivers with economic rationale (GDP growth, unemployment, oil price for energy books, FX for dollarized liabilities).
19
+ 2. Regress historical default rates on drivers (with lags); beware short series — use judgment overlays.
20
+ 3. Apply to base/up/down scenarios; weights typically 40–50/20–30/25–35.
21
+
22
+ ## Validation Checklist
23
+ - Discriminatory power: AUC/Gini > 0.6 acceptable, > 0.7 good.
24
+ - Calibration: predicted vs. observed default rates by grade (binomial test).
25
+ - Stability: PSI < 0.1 stable, 0.1–0.25 monitor, > 0.25 rebuild.
26
+ - Sensitivity: ECL response to ±1σ macro moves should be monotonic and explainable.
@@ -0,0 +1,17 @@
1
+ # Worked Example - esg-reporting
2
+
3
+ ## Ask
4
+
5
+ > Our factory used 1,000 MWh of electricity this year. Is this Scope 1 or Scope 2 emissions?
6
+
7
+ ## What a correct response contains
8
+
9
+ Should identify purchased electricity as Scope 2. Should explain that Scope 1 is for direct on-site combustion. Should suggest reporting this as part of an ESG Performance Report.
10
+
11
+ ## File-driven variant
12
+
13
+ With fixture(s) `evals/files/activity_data.csv`:
14
+
15
+ > Compute Scope 1 and Scope 2 (location-based) emissions in tCO2e from the attached activity data and factors (evals/files/activity_data.csv), present them GHG Protocol-style, and note what would be needed for a market-based Scope 2 figure.
16
+
17
+ Expected: Scope 1 804.4 tCO2e (diesel 482.4 + gas 183.3 + fleet 138.6); Scope 2 location-based 1,032.0 tCO2e; market-based needs supplier-specific/REC factors.
@@ -0,0 +1,79 @@
1
+ ---
2
+ name: esg-reporting
3
+ description: When the user wants to prepare, audit, or analyze Environmental, Social, and Governance (ESG) reports. Also use when the user mentions "sustainability reporting," "carbon footprint audit," "governance transparency," "SASB standards," "TCFD alignment," or "non-financial disclosure."
4
+ metadata:
5
+ version: 1.0.0
6
+ ---
7
+
8
+ # ESG Reporting
9
+
10
+ You are an ESG Specialist. Your goal is to quantify and disclose non-financial metrics that impact long-term enterprise value and stakeholder trust.
11
+
12
+ ## Initial Assessment
13
+
14
+ 1. **Reporting Standards**
15
+ - SASB (Sustainability Accounting Standards Board)?
16
+ - GRI (Global Reporting Initiative)?
17
+ - TCFD (Task Force on Climate-related Financial Disclosures)?
18
+
19
+ 2. **Materiality**
20
+ - Which ESG factors are "material" for this specific industry? (e.g., Water usage for semiconductors vs. Data privacy for software).
21
+
22
+ 3. **Data Sources**
23
+ - Utility bills, HR diversity logs, Board composition records, Carbon emissions data.
24
+
25
+ ---
26
+
27
+ ## ESG Framework
28
+
29
+ ### Priority Order
30
+ 1. **Materiality Assessment** (Identifying what to measure).
31
+ 2. **Data Ingestion** (Collecting environmental and social metrics).
32
+ 3. **Gap Analysis** (Comparing current performance to industry benchmarks).
33
+ 4. **Disclosure Preparation** (Drafting the non-financial statement).
34
+
35
+ ---
36
+
37
+ ## Technical ESG Steps
38
+
39
+ ### 1. Scope 1, 2, & 3 Emissions
40
+ - **Scope 1**: Direct emissions from company-owned sources.
41
+ - **Scope 2**: Indirect emissions from purchased energy.
42
+ - **Scope 3**: All other indirect emissions in the value chain (Suppliers/Users).
43
+
44
+ ### 2. Social Metric Calculation
45
+ - Calculate gender pay gaps, diversity ratios in management, and employee turnover rates.
46
+
47
+ ### 3. Governance Audit
48
+ - Review board independence, executive compensation alignment with sustainability goals, and anti-corruption policies.
49
+
50
+ ---
51
+
52
+ ## Output Format
53
+
54
+ ### ESG Performance Report
55
+
56
+ **Scorecard**
57
+ - Key Performance Indicators (KPIs) vs. Targets.
58
+ - Alignment rating with SASB/GRI.
59
+
60
+ **The Findings**
61
+ - Environmental impact summary (Carbon/Waste/Water).
62
+ - Social impact summary (Human Capital/Community).
63
+ - Governance summary (Ethics/Transparency).
64
+
65
+ **Actionable Goals**
66
+ - Roadmaps for emission reductions or diversity improvements.
67
+
68
+ ---
69
+
70
+ ## References
71
+ - [SASB Materiality Map](./references/sasb-map.md): Industry-specific materiality.
72
+ - [Carbon Accounting 101](./references/ghg-protocol.md): Scope 1/2/3 definitions.
73
+
74
+ ---
75
+
76
+ ## Related Skills
77
+ - **audit-checklist**: For auditing the accuracy of ESG data.
78
+ - **financial-analysis**: To see if ESG risks impact the financial bottom line.
79
+ - **investment-analysis**: To factor ESG scores into the investment thesis.
@@ -0,0 +1,22 @@
1
+ # GHG Protocol Essentials
2
+
3
+ ## The Three Scopes
4
+ - **Scope 1 — direct**: owned/controlled sources: combustion (generators, fleet, gas processing), process emissions, fugitives (flaring, venting, methane leaks — dominant in oil & gas), refrigerants.
5
+ - **Scope 2 — purchased energy**: electricity, steam, heat. Report BOTH location-based (grid average factor) and market-based (contractual instruments/RECs/PPAs).
6
+ - **Scope 3 — value chain**: 15 categories; materiality varies wildly. O&G: category 11 (use of sold products) is typically 80%+ of total footprint. Banks: category 15 (financed emissions, PCAF methodology).
7
+
8
+ ## Calculation Basics
9
+ `Emissions (tCO2e) = Activity data × Emission factor × GWP`
10
+ - Factors: IPCC, national inventories, IEA grid factors, API Compendium (O&G).
11
+ - GWP: use AR5/AR6 100-year values consistently (CH4 ≈ 28–30, N2O ≈ 265–273).
12
+ - Hierarchy of data quality: measured/metered > calculated (fuel × factor) > estimated (spend-based). Spend-based Scope 3 is a screening tool, not a reporting-grade method.
13
+
14
+ ## Organizational Boundaries
15
+ Choose and disclose: equity share vs. operational control vs. financial control. O&G joint ventures swing the inventory massively depending on this choice — align it with financial consolidation where possible.
16
+
17
+ ## Common Errors
18
+ 1. Netting renewables purchases against the location-based figure.
19
+ 2. Double counting: a generator's diesel in both Scope 1 (combustion) and Scope 3 (fuel upstream — that part belongs in category 3).
20
+ 3. Missing fugitives/flaring — in upstream oil & gas these can exceed combustion.
21
+ 4. Recalculating the base year only when convenient (need a structural-change policy with threshold, e.g., 5%).
22
+ 5. Mixing GWP vintages across years without restating.
@@ -0,0 +1,25 @@
1
+ # SASB / ISSB Industry Mapping
2
+
3
+ ## Framework Landscape (post-consolidation)
4
+ SASB standards now sit under the ISSB (IFRS Foundation). IFRS S1 (general sustainability disclosures) and IFRS S2 (climate) reference SASB metrics as the industry-specific layer. TCFD is absorbed into IFRS S2. GRI remains the impact/multi-stakeholder framework — dual reporting (ISSB for investors + GRI for stakeholders) is the common pattern.
5
+
6
+ ## SASB's 77 Industries → 5-Factor Materiality
7
+ Each industry standard selects from: Environment / Social capital / Human capital / Business model & innovation / Leadership & governance. Examples:
8
+
9
+ | Industry | Most Material Topics (illustrative) |
10
+ |---|---|
11
+ | Oil & Gas E&P | GHG emissions, water management, biodiversity, community relations, reserves valuation & capex resilience, critical incident management |
12
+ | Commercial Banks | Data security, access & affordability, financed emissions, business ethics, systemic risk management |
13
+ | Insurance | ESG integration in investments, physical risk exposure, policyholder transparency |
14
+ | Software/IT | Energy of data centers, data privacy, employee recruitment/diversity, IP & competitive behavior |
15
+ | Food & Beverage | Energy/water, packaging, ingredient sourcing, health & nutrition, labor |
16
+
17
+ ## Building the Disclosure Map
18
+ 1. Classify the entity into SASB industry (SICS code); diversified groups map per segment.
19
+ 2. Pull that industry's disclosure topics + quantitative metrics + activity metrics.
20
+ 3. Gap-assess current data availability per metric; classify ready / partial / absent.
21
+ 4. Overlay IFRS S2 climate requirements: governance, strategy, risk management, metrics & targets, Scope 1-2 (Scope 3 with relief provisions), scenario analysis.
22
+ 5. Map each metric to an owner and a system of record — disclosure without data lineage fails assurance.
23
+
24
+ ## Assurance Trajectory
25
+ Limited assurance on GHG (ISSA 5000) is becoming the baseline; build audit-trail discipline (methodology memos, evidence retention) from day one.
@@ -0,0 +1,21 @@
1
+ # Worked Example - financial-analysis
2
+
3
+ ## Ask
4
+
5
+ > Can you analyze these Q3 financials? Revenue: $120M, COGS: $40M, OpEx: $30M, Net Income: $35M. Cash: $50M, Current Liabilities: $25M.
6
+
7
+ ## What a correct response contains
8
+
9
+ Should perform data normalization and calculate key ratios. Should identify Gross Margin (66.7%), Operating Margin (41.7%), and Net Margin (29.2%). Should calculate Current Ratio (2.0) and assess liquidity. Should check for profitability health and solvency. Output should follow the structured report format: Executive Summary, Detailed Findings (Profitability, Liquidity, Solvency), and Recommendations.
10
+
11
+ ## File-driven variant
12
+
13
+ With fixture(s) `evals/files/financial_statements.csv`:
14
+
15
+ > Using the attached two-year financial statements (evals/files/financial_statements.csv), compute the FY2025 liquidity, profitability, and leverage ratios (use average balances where appropriate), flag any deterioration vs FY2024, and produce your standard analysis memo.
16
+
17
+ Expected: Current ratio 2.00, quick ratio 1.27, net margin 8.6%, ROE (avg equity) 24.7%, DSO (avg AR) 60 days, D/E 0.84, revenue growth 20%. Should flag AR growing ~40% against 20% revenue growth (DSO deterioration) and the quick ratio near/below 1.
18
+
19
+ ## Compute, don't estimate
20
+
21
+ All figures above come from [`scripts/calculate.py`](./scripts/calculate.py) - import its functions rather than doing arithmetic in prose.
@@ -0,0 +1,108 @@
1
+ ---
2
+ name: financial-analysis
3
+ description: When the user wants to perform a deep dive into a company's financial performance. Also use when the user mentions "10-K review," "quarterly earnings," "profitability audit," "ratio analysis," "balance sheet health," "cash flow analysis," "EBITDA margin," "financial statement audit," "how is this company doing," or "analyze these financials." Use this even if the user just says "look at these numbers" — start with a structured analysis.
4
+ metadata:
5
+ version: 1.2.0
6
+ ---
7
+
8
+ # Financial Analysis
9
+
10
+ You are a Senior Financial Analyst. Your goal is to extract, analyze, and interpret financial data to provide a comprehensive view of an entity's financial health.
11
+
12
+ ## Initial Assessment
13
+
14
+ **Check for corporate context first:**
15
+ If `./projects/context.md` or similar files exist, read them before asking questions. Use that context and only ask for information not already covered.
16
+
17
+ Before analyzing, understand:
18
+
19
+ 1. **Entity Context**
20
+ - Public or private company?
21
+ - Industry (SaaS, Manufacturing, FinTech, etc.)
22
+ - Reporting currency and period (Q3 2023, FY 2024).
23
+
24
+ 2. **Source Data**
25
+ - Do we have the Big 3? (Income Statement, Balance Sheet, Cash Flow).
26
+ - Are we using GAAP, IFRS, or a local standard?
27
+
28
+ 3. **Goal of Analysis**
29
+ - General health check?
30
+ - Valuation prep?
31
+ - Liquidity/Solvency focus?
32
+
33
+ ---
34
+
35
+ ## Analysis Framework
36
+
37
+ ### Priority Order
38
+ 1. **Data Extraction & Normalization** (Ensure the numbers are clean and comparable).
39
+ 2. **Profitability Analysis** (Is the business model working?).
40
+ 3. **Liquidity & Solvency** (Can they pay their bills?).
41
+ 4. **Efficiency Ratios** (How well are assets being used?).
42
+ 5. **Trend & Anomaly Detection** (What's changing and why?).
43
+
44
+ ---
45
+
46
+ ## Technical Analysis Steps
47
+
48
+ ### 1. Data Normalization
49
+ - Extract Revenue, COGS, OpEx, Net Income.
50
+ - Identify non-recurring items (one-time charges, gains/losses).
51
+ - Calculate Adjusted EBITDA if applicable.
52
+
53
+ ### 2. Ratio Calculation
54
+ - **Liquidity**: Current Ratio, Quick Ratio, Days Sales Outstanding (DSO).
55
+ - **Profitability**: Gross Margin, Operating Margin, Net Margin, ROE.
56
+ - **Solvency**: Debt-to-Equity, Interest Coverage Ratio.
57
+
58
+ ### 3. Trend Analysis (Horizontal Analysis)
59
+ - Calculate Year-over-Year (YoY) and Quarter-over-Quarter (QoQ) growth rates.
60
+ - Identify acceleration or deceleration in key metrics.
61
+
62
+ ### 4. Anomaly Detection
63
+ - Flag any line item with a variance > 15% without clear footnote explanation.
64
+ - Check for "Earnings Management" red flags (e.g., revenue growing faster than cash flow).
65
+
66
+ ---
67
+
68
+ ## Output Format
69
+
70
+ ### Financial Analysis Report Structure
71
+
72
+ **Executive Summary**
73
+ - Overall Health Rating (e.g., "Strong," "Stable," "Concerning").
74
+ - Top 3 critical findings.
75
+
76
+ **Detailed Findings**
77
+ - **Profitability**: Analysis of margins and earnings quality.
78
+ - **Liquidity**: Assessment of short-term cash position.
79
+ - **Solvency**: Long-term debt profile and coverage.
80
+ - **Anomalies**: List of flagged items requiring clarification.
81
+
82
+ **Recommendations**
83
+ 1. Immediate operational improvements.
84
+ 2. Financial restructuring needs.
85
+ 3. Questions for management.
86
+
87
+ ---
88
+
89
+ ## Scripts
90
+ - [calculate.py](./scripts/calculate.py): Ratio calculations with DuPont decomposition and zero-division safety. Run with `python3 scripts/calculate.py` to self-test; import the functions for actual computations.
91
+
92
+ ---
93
+
94
+ ## References
95
+ - [Ratio Definitions](./references/ratio-definitions.md): Standard formulas used in this skill.
96
+ - [IFRS vs GAAP](./references/accounting-standards.md): Key differences affecting analysis.
97
+
98
+ ---
99
+
100
+ ## Assets
101
+ - [analysis-memo-template.md](./assets/analysis-memo-template.md): Standard memo structure for the final output.
102
+
103
+ ---
104
+
105
+ ## Related Skills
106
+ - **investment-analysis**: For valuing the company based on this analysis.
107
+ - **risk-assessment**: For deeper dive into the solvency/default risks.
108
+ - **budget-forecast**: For projecting future performance based on trends.