<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def addGeneToPathway(self, gene_id, pathway_id):
 """ When adding a gene to a pathway, we create an intermediate 'gene product' that is involved in the pathway, through a blank node. gene_id RO:has_gene_product _gene_product _gene_product RO:involved_in pathway_id :param pathway_id: :param gene_id: :return: """


        gene_product = '_:'+re.sub(r':', '', gene_id) + 'product'
        self.model.addIndividualToGraph(
            gene_product, None, self.globaltt['gene_product'])
        self.graph.addTriple(
            gene_id, self.globaltt['has gene product'], gene_product)
        self.addComponentToPathway(gene_product, pathway_id)

        return