private void BuildModel(long docId, long keyId, AnalyzedString tokens) { var ix = GetOrCreateIndex(keyId); foreach (var vector in tokens.Embeddings) { if (!VectorNodeWriter.Add(ix, new VectorNode(vector, docId), Similarity.Term)) { _merges++; } } }
public void Put(long docId, long keyId, string value) { AnalyzedString tokens = _tokenizer.Tokenize(value); BuildModel(docId, keyId, tokens); }