refactor citation service