@thecodingwhale/cv-processor
Version:
CV Processor to extract structured data from PDF resumes using TypeScript
26 lines (25 loc) • 961 B
TypeScript
import { AccuracyScore, CVData, ProcessorOptions } from './types';
import { AIProvider, TokenUsageInfo } from './types/AIProvider';
/**
* Extract text from a PDF file using AI capabilities
*/
export declare function extractTextFromPDF(pdfPath: string, aiProvider: AIProvider): Promise<{
text: string;
tokenUsage?: TokenUsageInfo;
}>;
/**
* Calculate accuracy scores for the extracted CV data
*/
export declare function calculateAccuracy(cvData: CVData, options?: ProcessorOptions): AccuracyScore;
/**
* Check if CV data meets the minimum accuracy threshold
*/
export declare function meetsAccuracyThreshold(cvData: CVData, minAccuracyThreshold?: number): boolean;
/**
* Save CV data to a JSON file
*/
export declare function saveCVDataToJson(cvData: CVData, outputPath: string): void;
/**
* Process a CV using AI
*/
export declare function processCvWithAI(pdfPath: string, aiProvider: AIProvider, options?: ProcessorOptions): Promise<CVData>;