@palasimi/ipa-cluster
Version:
Cluster words with similar IPA transcriptions together
14 lines • 389 B
TypeScript
export type Data = {
ipa: string;
language?: string;
};
export type Point = {
ipa: string[];
language?: string;
};
export type Metric = (p: Point, q: Point) => number;
export type ClusterOptions = {
epsilon?: number;
};
export declare function cluster<T extends Data>(dataset: T[], metric: Metric, options?: ClusterOptions): T[][];
//# sourceMappingURL=cluster.d.ts.map