Apato is a subscription service built to give you an edge on the competitive real estate market. Apato lets you subscribe to certain areas of interest and pings you whenever a listing matching your investment criteria appears on the market. No more tedious manual searching and long hours of excel models.
- Get pinged when a investment opportunity appears on the market Let's you subscribe to a watchlist with your investment criteria (target IRR, size, location).
- Get accurate IRR immediately Calculates the Internal Rate of Return for all apartments listed in your watchlists.
- Notifies you whenever a new apartment that matches your criteria comes to market.
- Can handle multiple users, from multiple chats.
Technologies used:
Apato is designed using the Producer-Consumer pattern. High level functionality goes approximately like this:
- User subscribes to watchlist via Telegram.
- Producer pushes update and calculation tasks to the task queue.
- Consumer processes tasks. Sends update or calculates IRR for all apartments of given watchlist.
Apato uses real cash flow IRR calculations to estimate yield of investments.
The source code can be found in src/consumer/calculations.rs
.
IRR is a classic problem where one wants to find the roots of a polynomial of a high degree. In this case the degree is equal to the length of the loan (25 by default).
Apato solves for the roots by evaluating the eigenvalues of the companion matrix to the given cashflow.
To run locally, make sure to have Rust and Docker installed.
First, spin up the database.
docker-compose up -d
Run migrations:
diesel setup
Run Apato:
cargo run
Subscribe to a watchlist at location id
and set the wanted yield to be yield
/sub {location id} yield={yield} size={size}
Unsubscribe to a watchlist with watchlist id id
/unsub {watchlist_id}
Lists all the current watchlists of the caller
/listsubs
Get information about all apartments currently in the watchlist of interest.
/getall {watchlist_id}
Get information about all apartments matching your investment criteria in the watchlist of interest.
/getallvalid {watchlist_id}
Helper for all commands
/help
TODO