Skip to content

Commit c07dec4

Browse files
committed
Add some context API funstion
1 parent df66fb0 commit c07dec4

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

llama_cpp/_internals.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,6 +300,18 @@ def __del__(self):
300300
def n_ctx(self) -> int:
301301
return llama_cpp.llama_n_ctx(self.ctx)
302302

303+
def n_batch(self) -> int:
304+
return llama_cpp.llama_n_batch(self.ctx)
305+
306+
def n_batch(self) -> int:
307+
return llama_cpp.llama_n_batch(self.ctx)
308+
309+
def n_ubatch(self) -> int:
310+
return llama_cpp.llama_n_ubatch(self.ctx)
311+
312+
def n_seq_max(self) -> int:
313+
return llama_cpp.llama_n_seq_max(self.ctx)
314+
303315
def pooling_type(self) -> int:
304316
return llama_cpp.llama_pooling_type(self.ctx)
305317

0 commit comments

Comments
 (0)