@visactor/vmind
Version:
<div align="center"> <a href="https://github.com/VisActor#gh-light-mode-only" target="_blank"> <img alt="VisActor Logo" width="200" src="https://github.com/VisActor/.github/blob/main/profile/logo_500_200_light.svg"/> </a> <a href="https://githu
45 lines (44 loc) • 1.72 kB
TypeScript
import { AtomName, type DataExtractionCtx, type DataExtractionOptions, type BaseOptions } from '../../types/atom';
import { BaseAtom } from '../base';
import type { LLMMessage } from '../../types/llm';
import type { DataTable, FieldInfo } from '../../types';
export declare class DataExtractionAtom extends BaseAtom<DataExtractionCtx, DataExtractionOptions> {
name: AtomName;
isLLMAtom: boolean;
replaceData: {
template: string;
replace: string;
}[];
isTextReplaceStatus: boolean[];
constructor(context: DataExtractionCtx, option: BaseOptions);
buildDefaultContext(context: DataExtractionCtx): DataExtractionCtx;
buildDefaultOptions(): DataExtractionOptions;
shouldRunByContextUpdate(context: DataExtractionCtx): boolean;
revisedText(text: string): string;
getLLMMessages(query?: string): LLMMessage[];
revisedFieldInfo(dataTable: DataTable, fieldInfo: any[]): FieldInfo[];
parseSubText(text: string, textRange: [string, string]): string;
private parseMultipleResult;
parseLLMContent(resJson: any): DataExtractionCtx | {
thoughts: any;
datasets: {
text: string;
fieldInfo: FieldInfo[];
summary: string;
dataTable: DataTable;
textRange?: [string, string];
}[];
text: string;
fieldInfo?: FieldInfo[];
dataTable?: DataTable;
logId?: string;
id?: string;
query?: string;
response?: string;
error?: string;
usage?: import("../../types").Usage;
toolRes?: any;
};
protected _runWithOutLLM(): DataExtractionCtx;
}
export declare const registerDataExtractionAtom: () => void;