Split client and library