You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
openai-cookbook/apps/file-q-and-a/nextjs-with-flask-server/client/src/types/file.ts

22 lines
549 B
TypeScript

export interface FileLite {
expanded?: boolean;
name: string;
url?: string;
type?: string;
score?: number;
size?: number;
embedding?: number[]; // The file embedding -- or mean embedding if there are multiple embeddings for the file
chunks?: TextEmbedding[]; // The chunks of text and their embeddings
extractedText?: string; // The extracted text from the file
}
export interface FileChunk extends TextEmbedding {
filename: string;
score?: number;
}
export interface TextEmbedding {
text: string;
embedding: number[];
}