  We construct a Kitaev model, consisting of a Hamiltonian which is the sum of
commuting local projectors, for surfaces with boundaries and defects of
dimension 0 and 1. More specifically, we show that one can consider cell
decompositions of surfaces whose 2-cells are labeled by semisimple Hopf
algebras and 1-cells are labeled by semisimple bicomodule algebras. We
introduce an algebra whose representations label the 0-cells and which reduces
to the Drinfeld double of a Hopf algebra in the absence of defects. In this way
we generalize the algebraic structure underlying the standard Kitaev model
without defects or boundaries, where all 1-cells and 2-cells are labeled by a
single Hopf algebra and where point defects are labeled by representations of
its Drinfeld double. In the standard case, commuting local projectors are
constructed using the Haar integral for semisimple Hopf algebras. A central
insight we gain in this paper is that in the presence of defects and
boundaries, the suitable generalization of the Haar integral is given by the
unique symmetric separability idempotent for a semisimple (bi-)comodule
algebra.
