UNPKG

@astermind/astermind-synthetic-data

Version:

OmegaSynth - Label-Conditioned Synthetic Data Generator for AsterMind ELM/KELM Pipelines

26 lines (25 loc) 715 B
/** * SequenceContext - Add sequence context to generation * Uses previous characters to inform next character prediction */ export declare class SequenceContext { private ngramPatterns; private n; constructor(n?: number); /** * Learn n-gram patterns from training data */ learnPatterns(samples: string[]): void; /** * Get next character probabilities given context */ getNextCharProbs(context: string): Map<string, number>; /** * Suggest next character based on context */ suggestNextChar(context: string): string | null; /** * Score how well a character fits the context */ scoreChar(context: string, char: string): number; }