The Baker-Akhiezer (BA) function theory was successfully developed in the mid 1970s. This theory brought very interesting and important results in the spectral theory of almost periodic operators and theory of completely integrable nonlinear equations such as Korteweg-de Vries equation, nonlinear Schrödinger equation, sine-Gordon equation, Kadomtsev-Petviashvili equation. Subsequently the theory was reproduced for the Ablowitz-Kaup-Newell-Segur (AKNS) hierarchies. However, extensions of the Baker-Akhiezer function for the Maxwell-Bloch (MB) system or for the Karpman-Kaup equations, which contain prescribed weight functions characterizing inhomogeneous broadening of the main frequency, are unknown. The main goal of the paper is to give a such of extension associated with the Maxwell-Bloch equations. Using different Riemann-Hilbert problems posed on the complex plane with a finite number of cuts we propose such a matrix function that has unit determinant and takes an explicit form through Cauchy integrals, hyperelliptic integrals and theta functions. The matrix BA function solves the AKNS equations (the Lax pair for MB system) and generates a quasi-periodic finite-gap solution to the Maxwell-Bloch equations. The suggested function will be useful in the study of the long time asymptotic behavior of solutions of different initial-boundary value problems for the MB equations using the Deift-Zhou method of steepest descent and for an investigation of rogue waves of the Maxwell-Bloch equations.