@mudraforge/statutory 2.11.0 → 2.13.0

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 (176) hide show
  1. package/CHANGELOG.md +172 -1
  2. package/CONTRIBUTING.md +2 -2
  3. package/README.md +14 -1
  4. package/SECURITY.md +2 -2
  5. package/SKILL.md +1 -1
  6. package/bin/cli.js +288 -27
  7. package/docs/ACCOUNTING_ASSURANCE_AUDIT_DOSSIER.md +276 -0
  8. package/docs/ARCHITECTURE.md +76 -53
  9. package/docs/ARCHITECTURE_DECISIONS.md +22 -2
  10. package/docs/CASE_01_FORM_TEXT.txt +48 -0
  11. package/docs/CATALOG.md +405 -39
  12. package/docs/CA_PILOT_BENCHMARK_CASES.md +282 -0
  13. package/docs/CORPUS_QUALITY.md +31 -22
  14. package/docs/DOMAIN_BREADTH_AND_DEPTH_COMPARISON.md +5 -5
  15. package/docs/ENTERPRISE_GOVERNANCE.md +2 -1
  16. package/docs/OKF_MAINTENANCE_SOP.md +5 -5
  17. package/docs/PILOT_EVALUATION_GUIDE.md +5 -4
  18. package/docs/PROVENANCE.md +6 -6
  19. package/docs/VERIFICATION.md +6 -6
  20. package/okf/corporate_ma_restructuring/business_combinations_indas_103/ast.json +20 -0
  21. package/okf/corporate_ma_restructuring/business_combinations_indas_103/circulars/mca_notification_indas_103_business_combinations.md +41 -0
  22. package/okf/corporate_ma_restructuring/business_combinations_indas_103/forms/purchase_price_allocation_schedule.json +110 -0
  23. package/okf/corporate_ma_restructuring/business_combinations_indas_103/section.json +65 -0
  24. package/okf/corporate_ma_restructuring/impairment_of_assets_indas_36/ast.json +20 -0
  25. package/okf/corporate_ma_restructuring/impairment_of_assets_indas_36/circulars/mca_notification_indas_36_impairment.md +45 -0
  26. package/okf/corporate_ma_restructuring/impairment_of_assets_indas_36/forms/cgu_impairment_testing_register.json +53 -0
  27. package/okf/corporate_ma_restructuring/impairment_of_assets_indas_36/section.json +61 -0
  28. package/okf/corporate_ma_restructuring/loss_carryforward_sec79/ast.json +33 -0
  29. package/okf/corporate_ma_restructuring/share_based_payments_indas_102/ast.json +20 -0
  30. package/okf/corporate_ma_restructuring/share_based_payments_indas_102/circulars/icai_guidance_share_based_payments.md +37 -0
  31. package/okf/corporate_ma_restructuring/share_based_payments_indas_102/forms/esop_graded_vesting_amortization_schedule.json +49 -0
  32. package/okf/corporate_ma_restructuring/share_based_payments_indas_102/section.json +60 -0
  33. package/okf/corporate_ma_restructuring/slump_sale_50b/ast.json +21 -0
  34. package/okf/corporate_ma_restructuring/tax_clearance_sec281/ast.json +21 -0
  35. package/okf/direct_tax/corporate_tax_115baa_115jb/ast.json +23 -0
  36. package/okf/direct_tax/income_taxes_deferred_tax_indas_12/ast.json +20 -0
  37. package/okf/direct_tax/income_taxes_deferred_tax_indas_12/circulars/mca_notification_indas_12_income_taxes.md +40 -0
  38. package/okf/direct_tax/income_taxes_deferred_tax_indas_12/forms/deferred_tax_asset_liability_reconciliation_schedule.json +46 -0
  39. package/okf/direct_tax/income_taxes_deferred_tax_indas_12/section.json +61 -0
  40. package/okf/direct_tax/special_rates_non_filer_206ab/ast.json +26 -0
  41. package/okf/direct_tax/statutory_disallowance_43b/ast.json +35 -0
  42. package/okf/direct_tax/tcs_goods_206c_1h/ast.json +69 -0
  43. package/okf/direct_tax/tds_commission_194h/ast.json +60 -0
  44. package/okf/direct_tax/tds_commission_194h/section.json +5 -4
  45. package/okf/direct_tax/tds_contractor_194c/ast.json +71 -0
  46. package/okf/direct_tax/tds_contractor_194c/section.json +3 -3
  47. package/okf/direct_tax/tds_ecommerce_194o/ast.json +48 -0
  48. package/okf/direct_tax/tds_ecommerce_194o/section.json +3 -3
  49. package/okf/direct_tax/tds_goods_194q/ast.json +71 -0
  50. package/okf/direct_tax/tds_goods_194q/circulars/cbdt_circular_13_2021_guidelines.md +2 -2
  51. package/okf/direct_tax/tds_goods_194q/section.json +9 -3
  52. package/okf/direct_tax/tds_goods_393/ast.json +59 -0
  53. package/okf/direct_tax/tds_goods_393/section.json +6 -4
  54. package/okf/direct_tax/tds_individual_contract_194m/ast.json +59 -0
  55. package/okf/direct_tax/tds_individual_contract_194m/section.json +3 -3
  56. package/okf/direct_tax/tds_interest_194a/ast.json +59 -0
  57. package/okf/direct_tax/tds_interest_194a/section.json +7 -4
  58. package/okf/direct_tax/tds_perquisites_194r/ast.json +47 -0
  59. package/okf/direct_tax/tds_perquisites_194r/section.json +1 -1
  60. package/okf/direct_tax/tds_property_194ia/ast.json +70 -0
  61. package/okf/direct_tax/tds_property_194ia/section.json +3 -3
  62. package/okf/direct_tax/tds_rent_194i/ast.json +60 -0
  63. package/okf/direct_tax/tds_rent_194i/section.json +5 -4
  64. package/okf/direct_tax/tds_rent_individual_194ib/ast.json +59 -0
  65. package/okf/direct_tax/tds_rent_individual_194ib/section.json +2 -2
  66. package/okf/direct_tax/tds_services_194j/ast.json +60 -0
  67. package/okf/direct_tax/tds_services_194j/circulars/cbdt_circular_03_2020_fts_rate_cut.md +1 -1
  68. package/okf/direct_tax/tds_services_194j/section.json +10 -3
  69. package/okf/indirect_tax_gst/blocked_itc_17_5/ast.json +26 -0
  70. package/okf/indirect_tax_gst/common_itc_reversal_rule42_43/ast.json +26 -0
  71. package/okf/indirect_tax_gst/common_itc_reversal_rule42_43/circulars/cbic_circular_170_2022_itc_reporting.md +30 -0
  72. package/okf/indirect_tax_gst/common_itc_reversal_rule42_43/circulars/cbic_notification_18_2022_cutoff_amendment.md +26 -0
  73. package/okf/indirect_tax_gst/common_itc_reversal_rule42_43/forms/gstr_3b_table_4b1_reversal_schedule.json +101 -0
  74. package/okf/indirect_tax_gst/common_itc_reversal_rule42_43/forms/rule_42_43_annual_reconciliation_worksheet.json +87 -0
  75. package/okf/indirect_tax_gst/common_itc_reversal_rule42_43/section.json +65 -0
  76. package/okf/indirect_tax_gst/composite_mixed_supplies_sec8/ast.json +21 -0
  77. package/okf/indirect_tax_gst/composition_levy_sec10/ast.json +23 -0
  78. package/okf/indirect_tax_gst/credit_debit_notes_sec34/ast.json +21 -0
  79. package/okf/indirect_tax_gst/e_invoicing_rule48_4/ast.json +20 -0
  80. package/okf/indirect_tax_gst/export_services_lut_sec16/ast.json +20 -0
  81. package/okf/indirect_tax_gst/gst_tds_sec51/ast.json +23 -0
  82. package/okf/indirect_tax_gst/itc_eligibility_16_2/ast.json +20 -0
  83. package/okf/indirect_tax_gst/itc_reversal_rule37_37a/ast.json +45 -0
  84. package/okf/indirect_tax_gst/itc_reversal_rule37_37a/circulars/cbic_circular_192_2023_ecl_interest_calculation.md +36 -0
  85. package/okf/indirect_tax_gst/itc_reversal_rule37_37a/section.json +8 -1
  86. package/okf/indirect_tax_gst/rcm_liability_sec9_3/ast.json +26 -0
  87. package/okf/indirect_tax_gst/rcm_liability_sec9_3/circulars/cbic_notification_07_2025_composition_rent_exclusion.md +41 -0
  88. package/okf/indirect_tax_gst/rcm_liability_sec9_3/circulars/cbic_notification_09_2024_renting_rcm.md +37 -0
  89. package/okf/indirect_tax_gst/rcm_liability_sec9_3/circulars/gst_council_55th_meeting_renting_rcm_regularization.md +31 -0
  90. package/okf/indirect_tax_gst/rcm_liability_sec9_3/section.json +24 -2
  91. package/okf/international_tax/cross_border_remittance_195/ast.json +39 -0
  92. package/okf/international_tax/financial_instruments_ecl_indas_109/ast.json +24 -0
  93. package/okf/international_tax/financial_instruments_ecl_indas_109/circulars/mca_notification_indas_109_financial_instruments.md +43 -0
  94. package/okf/international_tax/financial_instruments_ecl_indas_109/forms/indas_109_ecl_provision_matrix_schedule.json +43 -0
  95. package/okf/international_tax/financial_instruments_ecl_indas_109/section.json +62 -0
  96. package/okf/international_tax/foreign_exchange_indas_21_109/ast.json +20 -0
  97. package/okf/international_tax/foreign_tax_credit_irc_901_904/ast.json +20 -0
  98. package/okf/international_tax/transfer_pricing_alp_92c/ast.json +25 -0
  99. package/okf/manifest.json +117 -20
  100. package/okf/msme_commercial/delayed_payments_15_16/ast.json +38 -0
  101. package/okf/msme_commercial/enterprise_classification_sec7/ast.json +25 -0
  102. package/okf/msme_commercial/lease_accounting_indas_116/ast.json +20 -0
  103. package/okf/msme_commercial/lease_accounting_indas_116/circulars/mca_notification_indas_116_leases.md +48 -0
  104. package/okf/msme_commercial/lease_accounting_indas_116/forms/lease_rou_asset_and_liability_schedule.json +55 -0
  105. package/okf/msme_commercial/lease_accounting_indas_116/section.json +67 -0
  106. package/okf/msme_commercial/mca_msme_1_filing/ast.json +20 -0
  107. package/okf/msme_commercial/provisions_contingencies_indas_37/ast.json +20 -0
  108. package/okf/msme_commercial/provisions_contingencies_indas_37/circulars/mca_notification_indas_37_provisions.md +36 -0
  109. package/okf/msme_commercial/provisions_contingencies_indas_37/forms/provisions_and_contingent_liabilities_register.json +38 -0
  110. package/okf/msme_commercial/provisions_contingencies_indas_37/section.json +61 -0
  111. package/okf/msme_commercial/revenue_recognition_indas_115/ast.json +20 -0
  112. package/okf/msme_commercial/revenue_recognition_indas_115/circulars/mca_notification_indas_115_revenue_contracts.md +56 -0
  113. package/okf/msme_commercial/revenue_recognition_indas_115/forms/revenue_contract_5step_allocation_schedule.json +54 -0
  114. package/okf/msme_commercial/revenue_recognition_indas_115/section.json +69 -0
  115. package/okf/msme_commercial/statutory_disclosures_sec22/ast.json +21 -0
  116. package/package.json +22 -1
  117. package/src/calculators.js +2195 -260
  118. package/src/constants.js +1 -1
  119. package/src/index.js +421 -23
  120. package/src/payroll.js +506 -0
  121. package/src/tally.js +812 -0
  122. package/src/usvm/evaluation_vm.js +504 -0
  123. package/src/usvm/index.js +65 -0
  124. package/src/usvm/math_rational.js +165 -0
  125. package/src/usvm/rules/sec_115baa_115jb_mat.json +23 -0
  126. package/src/usvm/rules/sec_192_salary_tds.json +23 -0
  127. package/src/usvm/rules/sec_194a_interest.json +59 -0
  128. package/src/usvm/rules/sec_194c_contractors.json +71 -0
  129. package/src/usvm/rules/sec_194h_commission.json +60 -0
  130. package/src/usvm/rules/sec_194i_rent.json +60 -0
  131. package/src/usvm/rules/sec_194ia_property.json +70 -0
  132. package/src/usvm/rules/sec_194ib_rent_ind.json +59 -0
  133. package/src/usvm/rules/sec_194j_services.json +60 -0
  134. package/src/usvm/rules/sec_194m_contract_ind.json +59 -0
  135. package/src/usvm/rules/sec_194o_ecommerce.json +48 -0
  136. package/src/usvm/rules/sec_194q_goods.json +71 -0
  137. package/src/usvm/rules/sec_194r_perquisites.json +47 -0
  138. package/src/usvm/rules/sec_195_cross_border.json +39 -0
  139. package/src/usvm/rules/sec_206ab_non_filer.json +26 -0
  140. package/src/usvm/rules/sec_206c1h_tcs.json +69 -0
  141. package/src/usvm/rules/sec_281_tax_clearance.json +21 -0
  142. package/src/usvm/rules/sec_393_goods.json +59 -0
  143. package/src/usvm/rules/sec_43bh_disallowance.json +35 -0
  144. package/src/usvm/rules/sec_50b_slump_sale.json +21 -0
  145. package/src/usvm/rules/sec_79_loss_continuity.json +33 -0
  146. package/src/usvm/rules/sec_92c_transfer_pricing.json +25 -0
  147. package/src/usvm/rules/sec_ftc_dtaa_relief.json +20 -0
  148. package/src/usvm/rules/sec_gst_blocked_itc_17_5.json +26 -0
  149. package/src/usvm/rules/sec_gst_composite_mixed_8.json +21 -0
  150. package/src/usvm/rules/sec_gst_composition_levy_10.json +23 -0
  151. package/src/usvm/rules/sec_gst_credit_debit_notes_34.json +21 -0
  152. package/src/usvm/rules/sec_gst_einvoicing_rule48_4.json +20 -0
  153. package/src/usvm/rules/sec_gst_ewaybill_rule138.json +21 -0
  154. package/src/usvm/rules/sec_gst_export_lut_16.json +20 -0
  155. package/src/usvm/rules/sec_gst_itc_eligibility_16_2.json +20 -0
  156. package/src/usvm/rules/sec_gst_itc_reversal_rule37_37a.json +45 -0
  157. package/src/usvm/rules/sec_gst_rcm_liability_9_3.json +26 -0
  158. package/src/usvm/rules/sec_gst_rule42_43_apportionment.json +26 -0
  159. package/src/usvm/rules/sec_gst_tds_sec51.json +23 -0
  160. package/src/usvm/rules/sec_indas102_esop.json +20 -0
  161. package/src/usvm/rules/sec_indas103_mna.json +20 -0
  162. package/src/usvm/rules/sec_indas109_ecl.json +24 -0
  163. package/src/usvm/rules/sec_indas115_revenue.json +20 -0
  164. package/src/usvm/rules/sec_indas116_leases.json +20 -0
  165. package/src/usvm/rules/sec_indas12_deferred_tax.json +20 -0
  166. package/src/usvm/rules/sec_indas21_fx_reval.json +20 -0
  167. package/src/usvm/rules/sec_indas36_impairment.json +20 -0
  168. package/src/usvm/rules/sec_indas37_provisions.json +20 -0
  169. package/src/usvm/rules/sec_msme_classification_sec7.json +25 -0
  170. package/src/usvm/rules/sec_msme_delayed_payments_15_16.json +38 -0
  171. package/src/usvm/rules/sec_msme_disclosures_sec22.json +21 -0
  172. package/src/usvm/rules/sec_msme_mca_form_1.json +20 -0
  173. package/src/usvm/schemas/statutory_ast_schema.js +203 -0
  174. package/src/usvm/usvm_domain_evaluators.js +1021 -0
  175. package/src/zoho_gstr2b.js +2964 -0
  176. package/types/index.d.ts +515 -0
@@ -82,14 +82,15 @@ To maintain institutional credibility, public documentation must never blur the
82
82
 
83
83
  | Subsystem / Capability | Architectural Layer | Operational Status | Availability / Access | Verification Evidence |
84
84
  | :--- | :--- | :--- | :--- | :--- |
85
- | **Bundled OKF Statutory Corpus (29 Provisions across 5 Domains)** | Layer 1: Public Package | `PUBLIC_BUNDLED` | Immediate (Local repo & release candidate) | 88/88 test suites passing; SHA-256 Merkle root verified |
85
+ | **Bundled OKF Statutory Corpus (46 Provisions across 5 Domains)** | Layer 1: Public Package | `PUBLIC_BUNDLED` | Immediate (Local repo & release candidate) | 166/166 test suites passing; SHA-256 Merkle root verified |
86
86
  | **Zero-Network CLI (`mudraforge-statutory`)** | Layer 1: Public Package | `PUBLIC_BUNDLED` | Immediate (Global / NPX) | `bin/cli.js` verified across Windows & Linux |
87
87
  | **Vendor-Neutral Conformance Suite** | Layer 1: Public Package | `PUBLIC_BUNDLED` | Immediate (`conformance/`) | 12/12 fixture tests passing |
88
88
  | **Local Query SDK (`src/index.js`)** | Layer 1: Public Package | `PUBLIC_BUNDLED` | Immediate (Node.js v18+) | Zero-dependency offline lookup and temporal checks |
89
89
  | **Synthetic AP Execution Trace (`examples/`)** | Layer 1: Public Package | `PUBLIC_DEMO_SYNTHETIC` | Immediate (`npm run example:trace`) | Modeled 7-stage lifecycle with synthetic test fixtures |
90
90
  | **Cloudflare Anycast Edge Sync** | Layer 2: Public Edge Service | `PUBLIC_EDGE_SYNC` | Free Beta (`api.mudraforge.in`) | Cloudflare Edge Worker manifest & bundle endpoints |
91
91
  | **Interactive API Documentation** | Layer 2: Public Edge Service | `PUBLIC_EDGE_SYNC` | Free Beta (`/api/v1/statutory/docs`) | OpenAPI 3.1 schema rendered live on Anycast edge |
92
- | **Deterministic Calculators (7 Pure Functions)** | Layer 1: Public Package | `PUBLIC_BUNDLED` | Immediate (`@mudraforge/statutory/calculators`) | Corporate tax MAT vs concessional, GST POS/LUT, TP ALP, Section 79, Ind AS 109, Section 288B |
92
+ | **Universal Statutory Virtual Machine (USVM Kernel & Rules)** | Layer 1: Public Package | `PUBLIC_BUNDLED` | Immediate (`@mudraforge/statutory/usvm`) | 48 pre-cached declarative AST rule packages, rational BigInt math (<15µs latency) |
93
+ | **Deterministic Corporate Finance Calculators** | Layer 1: Public Package | `PUBLIC_BUNDLED` | Immediate (`@mudraforge/statutory/calculators`) | Corporate tax MAT vs concessional, GST POS/LUT, TP ALP, Section 79, Ind AS 109, Section 288B |
93
94
  | **Hosted AP Engine & Cumulative Spend Tracking** | Layer 3: Enterprise Internal | `PILOT_STAGE_INTERNAL` | Metered Enterprise API (Selective) | Hosted cumulative Section 194Q thresholding & Section 16 MSMED interest |
94
95
  | **Dual-Custody Mobile Approval Harness** | Layer 4: Adesha Runtime | `INTERNAL_PROTOTYPE` | Enterprise License / Pilot Proposal | Mobile passkey approval prototype & TLA+ state machine |
95
96
  | **ERP Two-Way Connectors (SAP/Tally/Zoho)** | Layer 4: Adesha Runtime | `INTERNAL_DEVELOPMENT` | Custom Enterprise Pilot | Shadow-mode test connectors; no turnkey plug-ins shipped |
@@ -136,3 +137,22 @@ Prior to merging any composite transaction prototype into `main`, the implementa
136
137
  ### Consequences
137
138
  - **Positive**: Makes complex statutory relationships discoverable and machine-readable for AI agents without compromising open-source format purity or disclosing proprietary execution code.
138
139
  - **Lifecycle Management**: Implemented as an experimental prototype on a dedicated feature branch (`feature/composite-transaction-profiles`) and subjected to independent legal scenario benchmarking prior to promotion into public release `v2.5.0`. Release `v2.4.0` remains focused on the verified atomic statutory corpus.
140
+
141
+ ---
142
+
143
+ ## ADR-0007: Universal Statutory Virtual Machine (USVM) Declarative AST Kernel
144
+
145
+ ### Context
146
+ Historically, statutory tax calculations were coded as imperative JavaScript branching functions. As statutory provisions grew to 46+ sections across 5 domains, imperative functions introduced code duplication, maintenance overhead, and higher bundle sizes for edge and browser environments. Imperative procedural code also made independent statutory verification opaque for non-developer tax professionals and audit teams.
147
+
148
+ ### Decision
149
+ We introduce the Universal Statutory Virtual Machine (USVM) declarative Abstract Syntax Tree (AST) evaluation kernel:
150
+ 1. **Stateless AST Evaluation Kernel (`src/usvm/evaluation_vm.js`)**: A compact 355-line stateless virtual machine evaluating declarative AST rule definitions without imperative branching.
151
+ 2. **5-Stage Rational BigInt Arithmetic (`src/usvm/math_rational.js`)**: Arithmetic is evaluated using exact rational fractions (`[numerator, denominator]` pairs) to eliminate IEEE 754 floating-point precision loss.
152
+ 3. **Co-Located Declarative Rules**: 46 `ast.json` rule packages co-located within the 5 canonical OKF domains, alongside 48 pre-cached rules in `src/usvm/rules/*.json`.
153
+ 4. **Tree-Shakable Subpath (`@mudraforge/statutory/usvm`)**: Exposes `evaluateStatutoryAst`, `validateStatutoryAst`, and `toBigIntPaise` in an ultra-lightweight bundle (~12 kB GZIP vs 92.9 kB full library).
154
+ 5. **Fiduciary Statutory Invariant**: Every evaluation strictly enforces `isAuthorizedToDisburse: false`.
155
+
156
+ ### Consequences
157
+ - **Positive**: Replaces thousands of lines of imperative procedural code with declarative JSON AST definitions; achieves sub-microsecond evaluation latency (p50: 14.32 microseconds); enables tree-shakable client bundles.
158
+ - **Backward Compatibility**: Fully backward compatible with existing procedural API callers.
@@ -0,0 +1,48 @@
1
+ INWARD INVOICE SLIP (TAX INVOICE)
2
+ --------------------------------------------------------------------------------
3
+ Supplier: Precision Castings Pvt. Ltd. | GSTIN: 27AAACP1234F1ZV (Maharashtra)
4
+ PAN : AAACP1234F (Company) | MSME : UDYAM-MH-03-0019842 (Micro Mfr)
5
+ Inv No : PCPL/25-26/0541 | Date : 01-May-2025 (GRN: 01-May-2025)
6
+ Terms : PO-2025-0892 (Net 60 Days) | Supply: HSN 732599 (Valve Castings)
7
+ Basic : ₹20,00,000.00 | IGST 18%: ₹3,60,000.00
8
+ Total : ₹23,60,000.00 | Place of Supply: Gujarat (Interstate)
9
+
10
+ BUYER ERP CONTEXT (Zenith Engineering Pvt. Ltd.)
11
+ --------------------------------------------------------------------------------
12
+ Prior FY Turnover : ₹18.50 Crore (Exceeds ₹10 Cr 194Q Gate)
13
+ YTD Purchases : ₹45,00,000.00 prior to this bill (Excl. GST, on credit)
14
+ PAN Status : Active & Operative
15
+
16
+ MUDRAFORGE ENGINE OUTPUT (STATUTORY DETERMINATION)
17
+ --------------------------------------------------------------------------------
18
+ 1. Section 194Q TDS:
19
+ - Taxable Base : ₹15,00,000 (Excess over ₹50L; GST excluded per Cir 13/2021)
20
+ - TDS Rate : 0.1% (Standard operative PAN rate)
21
+ - TDS Amount : ₹1,500.00 (Exceeds ₹50L base; satisfies Section 288B multiple-of-10 rounding)
22
+
23
+ 2. MSMED Act Sec 15 & Sec 43B(h):
24
+ - Status : Micro Manufacturer (NIC 24311)
25
+ - Credit Term : 60-day term is void; capped at 45 days from GRN (01-May-2025)
26
+ - Cutoff Date : 15-June-2025 (To avoid Sec 16 interest & 43B(h) disallowance)
27
+
28
+ 3. General Ledger Posting:
29
+ - Dr. Expense ₹20,00,000 | Dr. IGST ₹3,60,000
30
+ - Cr. TDS Payable ₹1,500 | Cr. Vendor AP ₹23,58,500
31
+
32
+ SPREADSHEET COMPLIANCE FORMULAS
33
+ --------------------------------------------------------------------------------
34
+ 1. TDS WITHHOLDING (Section 194Q):
35
+ • Standard Excel (Generic All-in-One):
36
+ =IF(AND(BuyerTurnoverCr > 10, TxnDate >= DATE(2021,7,1)), ROUND((MAX(0, (PriorSpend + IF(IsAdvance, GrossAmt, GrossAmt - GstAmt)) - 5000000) - MAX(0, PriorSpend - 5000000)) * IF(HasOperativePAN, 0.1%, 5.0%), -1), 0)
37
+
38
+ • Standard Excel (Case 01 Values):
39
+ =IF(AND(18.5 > 10, DATE(2025,5,1) >= DATE(2021,7,1)), ROUND((MAX(0, (4500000 + IF(FALSE, 2360000, 2360000 - 360000)) - 5000000) - MAX(0, 4500000 - 5000000)) * IF(TRUE, 0.1%, 5.0%), -1), 0)
40
+
41
+ • MudraForge Add-in:
42
+ =MF.TDS("194Q", 2360000, 4500000, TRUE, "2025-05-01", 18.5, 360000, FALSE)
43
+ -> Result : ₹1,500.00
44
+
45
+ 2. STATUTORY DUE DATE (MSMED Act Section 15 & Section 43B(h)):
46
+ • Standard Excel : =DeliveryDate + MIN(AgreedContractDays, 45)
47
+ • MudraForge : =MF.MSME.DUEDATE("2025-05-01", TRUE, "2025-06-30")
48
+ -> Result : 15-June-2025