lots of updates, moving intensive logic to backend.