@gaiaverse/semantic-turning-point-detector
Version:
Detects key semantic turning points in conversations using recursive semantic distance analysis. Ideal for conversation analysis, dialogue segmentation, insight detection, and AI-assisted reasoning tasks.
13 lines • 494 B
TypeScript
/**
* Count tokens in a given string using OpenAI-compatible tokenization.
*
* @param text - The text to tokenize
* @returns Number of tokens
*/
export declare function countTokens(text: string): number;
/**
* Generates an embedding for a given text using the OpenAI API
* This provides the vector representation for semantic distance calculation
*/
export declare function generateEmbedding(text: string, model?: string): Promise<Float32Array>;
//# sourceMappingURL=tokensUtil.d.ts.map