Skip to content

feat: 'Path to Safe' reverse calculator with binary search#22

Open
HeetRanpura wants to merge 1 commit intoadvikdivekar:mainfrom
HeetRanpura:feature/path-to-safe-calculator
Open

feat: 'Path to Safe' reverse calculator with binary search#22
HeetRanpura wants to merge 1 commit intoadvikdivekar:mainfrom
HeetRanpura:feature/path-to-safe-calculator

Conversation

@HeetRanpura
Copy link
Copy Markdown
Contributor

  • Add PathToSafeOutput schema to schemas.py
  • Create path_to_safe.py with three binary search functions:
    1. Minimum down payment for safe status (precision: ₹1,000)
    2. Maximum property price at current down payment (precision: ₹10,000)
    3. Minimum monthly income needed (precision: ₹1,000)
  • 'Safe' = EMI ≤ 35% income AND all 5 stress scenarios survivable
  • Add POST /api/v1/path-to-safe/{session_id} endpoint
  • Pure math, zero LLM, sub-5ms execution
  • Returns human-readable explanation with exact rupee amounts

@HeetRanpura HeetRanpura force-pushed the feature/path-to-safe-calculator branch from fa5f197 to 684ec7b Compare April 23, 2026 20:52
- Add PathToSafeOutput schema to schemas.py
- Create path_to_safe.py with three binary search functions:
  1. Minimum down payment for safe status (precision: Rs 1,000)
  2. Maximum property price at current down payment (precision: Rs 10,000)
  3. Minimum monthly income needed (precision: Rs 1,000)
- 'Safe' = EMI <= 35% income AND all 5 stress scenarios survivable
- Add POST /api/v1/path-to-safe/{session_id} endpoint
- Pure math, zero LLM, sub-5ms execution
@HeetRanpura HeetRanpura force-pushed the feature/path-to-safe-calculator branch from 684ec7b to 3982a2a Compare April 23, 2026 21:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant