| 27 | } |
| 28 | |
| 29 | static void batch_add_seq(llama_batch & batch, const std::vector<int32_t> & tokens, llama_seq_id seq_id) { |
| 30 | size_t n_tokens = tokens.size(); |
| 31 | for (size_t i = 0; i < n_tokens; i++) { |
| 32 | common_batch_add(batch, tokens[i], i, { seq_id }, true); |
| 33 | } |
| 34 | } |
| 35 | |
| 36 | static void batch_decode(llama_context * ctx, llama_batch & batch, float * output, int n_seq, int n_embd, int embd_norm) { |
| 37 | const enum llama_pooling_type pooling_type = llama_pooling_type(ctx); |
no test coverage detected