toeverything/AFFiNE · error

transcript native recipe failed

Error message

transcript native recipe failed

What it means

Generic Error thrown in the transcript dispatch path when the action bridge emits an event with type 'error' or status 'failed' while executing the native transcript action. The message defaults to 'transcript native recipe failed' and is replaced by the event's errorMessage or errorCode when present; the task is then marked failed rather than ready.

Source

Thrown at packages/backend/server/src/plugins/copilot/transcript/service.ts:591

              workspace: task.workspaceId,
              taskId,
              billingUnitId: taskId,
              featureKind: 'transcript',
            },
          },
        },
        input => this.executeTranscriptAction(input, runtimePayload)
      )) {
        if (event.type === 'error' || event.status === 'failed') {
          bridgeFailed = true;
          bridgeError = event.errorMessage ?? event.errorCode ?? bridgeError;
        }
        if (event.type === 'action_done' && event.status === 'succeeded') {
          finalResult = event.result;
        }
      }
      if (bridgeFailed) {
        throw new Error(bridgeError);
      }
      const parsedResult = {
        ...TranscriptPayloadSchema.parse(finalResult),
        infos: payload.infos,
      } satisfies TranscriptionPayloadV2;
      const completed =
        await this.models.copilotTranscriptTask.completeDispatch(
          taskId,
          generation,
          actionRunId,
          {
            status: 'ready',
            publicMeta: this.buildTaskPublicMeta(parsedResult),
            protectedResult: parsedResult,
            errorCode: null,
          }
        );
      if (completed) {

View on GitHub (pinned to 591f874dad)

Solutions

  1. Check server logs immediately before this throw - the underlying event errorMessage/errorCode and debug logging of the action run identify the real cause
  2. Verify the native transcript action package/binary is installed and its version matches the server release
  3. Retry via retryTask once the environment issue is fixed - dispatch claims a new generation
  4. Reproduce with a small standard WAV/MP3 file to rule out input corruption
Defensive patterns

Strategy: retry

Type guard

const isBridgeError = (e: unknown): e is Error =>
  e instanceof Error && /transcript native recipe failed/i.test(e.message);

Try / catch

try {
  await dispatch(taskId);
} catch (e) {
  // task is now status 'failed'; inspect server logs for event.errorMessage/errorCode
  await backoff();
  await retryTask(userId, workspaceId, taskId); // claims a new generation
}

Prevention

When it happens

Trigger: Executing the native transcript action (dispatch flow around service.ts:540-602) when the action runner emits error events: native binding/module missing, model asset download failure, unreadable or unsupported audio input, or an exception inside the action implementation.

Common situations: Self-hosted deployment without the native transcript addon installed or with a version mismatch after a server upgrade; corrupted or zero-length audio blob fetched for the task; sandboxed environment blocking the native binary.

Related errors


AI-assisted analysis of toeverything/AFFiNE@591f874dad (2026-08-18). Data as JSON: /api/errors/e88911b824359c40. Report an issue: GitHub.