This commit is contained in:
Igor Loskutov
2025-12-23 17:44:45 -05:00
parent e369ed66ca
commit f8c4f542c1
4 changed files with 9 additions and 17 deletions

View File

@@ -1,5 +1,5 @@
""" """
Run Hatchet workers for the diarization pipeline. Run Hatchet workers for the multitrack pipeline.
Runs as a separate process, just like Celery workers. Runs as a separate process, just like Celery workers.
Usage: Usage:
@@ -39,7 +39,7 @@ def main() -> None:
# Can't use lazy init: decorators need the client object when function is defined. # Can't use lazy init: decorators need the client object when function is defined.
from reflector.hatchet.client import HatchetClientManager # noqa: PLC0415 from reflector.hatchet.client import HatchetClientManager # noqa: PLC0415
from reflector.hatchet.workflows import ( # noqa: PLC0415 from reflector.hatchet.workflows import ( # noqa: PLC0415
diarization_pipeline, daily_multitrack_pipeline,
subject_workflow, subject_workflow,
topic_chunk_workflow, topic_chunk_workflow,
track_workflow, track_workflow,
@@ -54,7 +54,7 @@ def main() -> None:
worker = hatchet.worker( worker = hatchet.worker(
"reflector-pipeline-worker", "reflector-pipeline-worker",
workflows=[ workflows=[
diarization_pipeline, daily_multitrack_pipeline,
subject_workflow, subject_workflow,
topic_chunk_workflow, topic_chunk_workflow,
track_workflow, track_workflow,

View File

@@ -1,8 +1,8 @@
"""Hatchet workflow definitions.""" """Hatchet workflow definitions."""
from reflector.hatchet.workflows.diarization_pipeline import ( from reflector.hatchet.workflows.daily_multitrack_pipeline import (
PipelineInput, PipelineInput,
diarization_pipeline, daily_multitrack_pipeline,
) )
from reflector.hatchet.workflows.subject_processing import ( from reflector.hatchet.workflows.subject_processing import (
SubjectInput, SubjectInput,
@@ -15,7 +15,7 @@ from reflector.hatchet.workflows.topic_chunk_processing import (
from reflector.hatchet.workflows.track_processing import TrackInput, track_workflow from reflector.hatchet.workflows.track_processing import TrackInput, track_workflow
__all__ = [ __all__ = [
"diarization_pipeline", "daily_multitrack_pipeline",
"subject_workflow", "subject_workflow",
"topic_chunk_workflow", "topic_chunk_workflow",
"track_workflow", "track_workflow",

View File

@@ -108,7 +108,7 @@ class PipelineInput(BaseModel):
hatchet = HatchetClientManager.get_client() hatchet = HatchetClientManager.get_client()
daily_multitrack_pipeline = hatchet.workflow( daily_multitrack_pipeline = hatchet.workflow(
name="DailyMultitrackPipeline", input_validator=PipelineInput name="DiarizationPipeline", input_validator=PipelineInput
) )
@@ -1225,9 +1225,9 @@ async def post_zulip(input: PipelineInput, ctx: Context) -> ZulipResult:
@daily_multitrack_pipeline.task( @daily_multitrack_pipeline.task(
parents=[post_zulip], parents=[cleanup_consent],
execution_timeout=timedelta(seconds=TIMEOUT_MEDIUM), execution_timeout=timedelta(seconds=TIMEOUT_MEDIUM),
retries=30, retries=5,
) )
@with_error_handling("send_webhook", set_error_status=False) @with_error_handling("send_webhook", set_error_status=False)
async def send_webhook(input: PipelineInput, ctx: Context) -> WebhookResult: async def send_webhook(input: PipelineInput, ctx: Context) -> WebhookResult:

View File

@@ -24,14 +24,6 @@ from reflector.utils.webhook_outgoing_models import (
) )
__all__ = [ __all__ = [
"WebhookCalendarEventPayload",
"WebhookParticipantPayload",
"WebhookPayload",
"WebhookRoomPayload",
"WebhookTestPayload",
"WebhookTopicPayload",
"WebhookTranscriptPayload",
"_serialize_payload",
"build_transcript_webhook_payload", "build_transcript_webhook_payload",
"build_test_webhook_payload", "build_test_webhook_payload",
"build_webhook_headers", "build_webhook_headers",