125
*/
126
export function computeChunkedFourGramSurvival(aiChunks: readonly string[], currentText: string): number {
128
return 0;
129
}
130
131
const n = 4;
132
>
const fileNGrams = currentText.length >= n ? buildNGramSet(currentText, n) : undefined;
editSurvivalTracker.ts
133
>
134
>
let totalWeight = 0;
135
>
let weightedSum = 0;
136
>
for (const chunk of aiChunks) {
137
// Use n-gram count as the weight, with a floor of 1 for tiny
138
// chunks (so they still contribute their full presence signal