Heegaard diagrams are used to describe a three-dimensional manifolds, a classical way to do so is to take $M={\displaystyle M\cong (H_{1}\cup H_{2})/{\sim }}$ as a topological quotient of the union of two handlebodies $H_1, H_2$ modulo a relation induced by boundary homeomorphism ${\displaystyle f:\partial H_{1}\rightarrow \partial H_{2}}$.
In paper "Bordered Heegaard Floer homology" by Lipshitz, Ozsváth and Thurston I found also this image which describes another way to think of Heegaard decomposition:
It is claimed that this is a completely equivalent viewpoint determined by certain data $\{\Sigma_g; \alpha_1, \alpha_2,..., \alpha_g; \beta_1,..., \beta_g\}$ where $\partial H_1 \cong \partial H_2 \cong \Sigma_g$ is a surface of genus $g$ and the additional data of sets of disjoint $\alpha_1,..., \alpha_g \subset H_1$ (respectively $\beta_1,..., \beta_g \subset H_2$) of pairwise non homotopical curves ("attaching circles").
unfortunately, I not understand how to "read" this image, ie what is concretly glued with what? My guess is: Do the blue curves represent one set $\alpha_1,..., \alpha_g$ and the red ones the other set $\beta_1,..., \beta_g $ and the pairs $\alpha_i$ and $\beta_i$ are glued by $f$ together?
If yes, why this uniquely determines $f$ and therefore also $ (H_{1}\cup H_{2})/{\sim }$?
