initial port of daitss libraries with modifications for use with rails project