| llama_batch_init | R Documentation |
Allocates a llama_batch that can hold up to n_tokens tokens.
Use llama_batch_free() to release the memory when done.
llama_batch_init(n_tokens, embd = 0L, n_seq_max = 1L)
n_tokens |
Maximum number of tokens in the batch. |
embd |
Embedding size; 0 means token-ID mode (normal inference). |
n_seq_max |
Maximum number of sequences per token. |
An external pointer to the allocated batch.
## Not run:
batch <- llama_batch_init(512L)
llama_batch_free(batch)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.