Do not leave the choice of a repository context up to the library consumer. Instead, provide a specific factory (*Persistence) for each module.