MCPcopy Create free account
hub / github.com/Tiiny-AI/PowerInfer / llama_sampler_chain_get

Function llama_sampler_chain_get

smallthinker/src/llama-sampling.cpp:499–507  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

497}
498
499struct llama_sampler * llama_sampler_chain_get(const struct llama_sampler * chain, int32_t i) {
500 const auto * p = (const llama_sampler_chain *) chain->ctx;
501
502 if (i < 0 || (size_t) i >= p->samplers.size()) {
503 return nullptr;
504 }
505
506 return p->samplers[i];
507}
508
509struct llama_sampler * llama_sampler_chain_remove(struct llama_sampler * chain, int32_t i) {
510 auto * p = (llama_sampler_chain *) chain->ctx;

Callers 1

common_sampler_printFunction · 0.85

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected