The General Relativistic Atomic Structure package [GRASP2018, C. Froese Fischer, G. Gaigalas, P. Jönsson, and J. Bieroń, Comput. Phys. Commun. (2019), DOI: 10.1016/j.cpc.2018.10.032] is based on multiconfiguration Dirac– Hartree–Fock and relativistic configuration interaction (RCI) methods for energy structure calculations. The atomic state function used in the program is built from the set of configuration state functions (CSFs). The valence–valence, core–valence and core–core correlations are explicitly included through expansions over CSFs in RCI. We present a combination of RCI and the stationary second-order Rayleigh–Schrödinger many-body perturbation theory in an irreducible tensorial form to account for electron core–valence correlations when an atom or ion has any number of valence electrons. This newly developed method, which offers two ways of use, allows a significant reduction of the CSF space for complex atoms and ions. We also demonstrate how the method and program works for the energy structure calculation of Cl III ion.