8000 Add warning to documentation. · masmullin2000/llama_cpp-rs@f39e33b · GitHub
[go: up one dir, main page]

Skip to content

Commit f39e33b

Browse files
committed
Add warning to documentation.
1 parent 5a4f2d2 commit f39e33b

File tree

1 file changed

+3
-0
lines changed
  • crates/llama_cpp/src/session

1 file changed

+3
-0
lines changed

crates/llama_cpp/src/session/mod.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -377,6 +377,9 @@ impl LlamaSession {
377377
/// Removes all tokens within the given range without performing any prompt
378378
/// processing. If you remove tokens in the middle of context, it is recommended that you keep
379379
/// the first ~4 tokens of context when you do this, per <https://arxiv.org/abs/2309.17453>.
380+
///
381+
/// Note that calling this is not equivalent to calling [`LlamaSession::set_context`] with the
382+
/// same list of tokens that this method produces.
380383
pub fn remove_tokens_in_range(&mut self, range: impl RangeBounds<usize>) {
381384
let start_bound = match range.start_bound() {
382385
Bound::Included(i) => *i as i32,

0 commit comments

Comments
 (0)
0