Skip to content

Commit e52f5ef

Browse files
authored
Merge pull request #1197 from martindevans/batch_executor_neg_one
Conversation `-1` instead of `_end`
2 parents 81b022b + 3bfedda commit e52f5ef

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

LLama/Batched/Conversation.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ public void Dispose()
8484
_disposed = true;
8585

8686
// Remove this conversation from the KV cache
87-
Executor.Context.NativeHandle.KvCacheRemove(ConversationId, 0, _end);
87+
Executor.Context.NativeHandle.KvCacheRemove(ConversationId, -1, -1);
8888

8989
// Prevent finalizer from running
9090
GC.SuppressFinalize(this);
@@ -410,7 +410,7 @@ public void Remove(LLamaPos start, LLamaPos end)
410410
}
411411

412412
/// <summary>
413-
/// Removes all tokens starting from the given position
413+
/// Removes <see cref="count"/> tokens starting from <see cref="start"/>
414414
/// </summary>
415415
/// <param name="start">Start position (inclusive)</param>
416416
/// <param name="count">Number of tokens</param>

0 commit comments

Comments
 (0)