switch to sqlite, refactor along concerns
switch to sqlite, refactor along concerns;