add pipline

This commit is contained in:
ivankirpichnikov
2025-11-23 01:45:05 +03:00
parent ac32e89ada
commit 9e7515631e
@@ -10,6 +10,7 @@ from template_project.application.resume.entity import (
ResumeId, ResumeId,
ResumeProject, ResumeProject,
) )
from template_project.application.resume.interactors.resume_embedding import ResumeEmbeddingInteractor
@to_data_structure @to_data_structure
@@ -37,6 +38,8 @@ class ProjectInput:
class AddResumeInteractor: class AddResumeInteractor:
unit_of_work: UnitOfWork unit_of_work: UnitOfWork
identity_provider: IdentityProvider identity_provider: IdentityProvider
# TODO: переделать в фоновую таску
resume_embedding_interactor: ResumeEmbeddingInteractor
async def execute( async def execute(
self, self,
@@ -94,6 +97,8 @@ class AddResumeInteractor:
) )
await self.unit_of_work.add(resume_project) await self.unit_of_work.add(resume_project)
await self.resume_embedding_interactor.run(resume)
await self.unit_of_work.commit() await self.unit_of_work.commit()
return resume.id return resume.id