chore(pdf-parse): update PDF_PARSER_VERSION import to use api-contracts entrypoint
Standardize import of PDF_PARSER_VERSION across server modules to reference @openreader/compute-core/api-contracts. This clarifies versioning boundaries and improves maintainability by consolidating contract exports.
This commit is contained in:
parent
25342371a4
commit
c05a60a228
4 changed files with 5 additions and 3 deletions
|
|
@ -17,6 +17,7 @@ export type {
|
||||||
|
|
||||||
export const ALIGN_QUEUE_NAME = 'whisper-align';
|
export const ALIGN_QUEUE_NAME = 'whisper-align';
|
||||||
export const PDF_LAYOUT_QUEUE_NAME = 'pdf-layout';
|
export const PDF_LAYOUT_QUEUE_NAME = 'pdf-layout';
|
||||||
|
export { PDF_PARSER_VERSION } from '../pdf/parser-version';
|
||||||
|
|
||||||
export interface WhisperAlignJobBase {
|
export interface WhisperAlignJobBase {
|
||||||
text: string;
|
text: string;
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
import { createHash, randomUUID } from 'node:crypto';
|
import { createHash, randomUUID } from 'node:crypto';
|
||||||
import type { ComputeBackend, PdfLayoutInput, WhisperAlignInput, WhisperAlignResult } from '@/lib/server/compute/types';
|
import type { ComputeBackend, PdfLayoutInput, WhisperAlignInput, WhisperAlignResult } from '@/lib/server/compute/types';
|
||||||
import { parseSseEventId, parseSsePayload } from '@openreader/compute-core';
|
import { parseSseEventId, parseSsePayload } from '@openreader/compute-core';
|
||||||
import { getWorkerClientWaitTimeoutMs, PDF_PARSER_VERSION } from '@openreader/compute-core';
|
import { getWorkerClientWaitTimeoutMs } from '@openreader/compute-core';
|
||||||
|
import { PDF_PARSER_VERSION } from '@openreader/compute-core/api-contracts';
|
||||||
import { errorToLog, serverLogger } from '@/lib/server/logger';
|
import { errorToLog, serverLogger } from '@/lib/server/logger';
|
||||||
import { logDegraded, logServerError } from '@/lib/server/errors/logging';
|
import { logDegraded, logServerError } from '@/lib/server/errors/logging';
|
||||||
import type {
|
import type {
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ import {
|
||||||
PutObjectCommand,
|
PutObjectCommand,
|
||||||
} from '@aws-sdk/client-s3';
|
} from '@aws-sdk/client-s3';
|
||||||
import { getSignedUrl } from '@aws-sdk/s3-request-presigner';
|
import { getSignedUrl } from '@aws-sdk/s3-request-presigner';
|
||||||
import { PDF_PARSER_VERSION } from '@openreader/compute-core';
|
import { PDF_PARSER_VERSION } from '@openreader/compute-core/api-contracts';
|
||||||
import { getS3Client, getS3Config, getS3ProxyClient } from '@/lib/server/storage/s3';
|
import { getS3Client, getS3Config, getS3ProxyClient } from '@/lib/server/storage/s3';
|
||||||
|
|
||||||
const DOCUMENT_ID_REGEX = /^[a-f0-9]{64}$/i;
|
const DOCUMENT_ID_REGEX = /^[a-f0-9]{64}$/i;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { PDF_PARSER_VERSION } from '@openreader/compute-core';
|
import { PDF_PARSER_VERSION } from '@openreader/compute-core/api-contracts';
|
||||||
import {
|
import {
|
||||||
documentParsedKeyForVersion,
|
documentParsedKeyForVersion,
|
||||||
getParsedDocumentBlobByKey,
|
getParsedDocumentBlobByKey,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue