BaseSamplingPipeline
Namespace: LLama.Sampling
1 |
|
Inheritance Object → BaseSamplingPipeline
Implements ISamplingPipeline, IDisposable
Attributes NullableContextAttribute, NullableAttribute
Constructors
BaseSamplingPipeline()
Create a new sampler wrapping a llama.cpp sampler chain
1 |
|
Methods
CreateChain(SafeLLamaContextHandle)
Create a sampling chain. This will be called once, the base class will automatically dispose the chain.
1 |
|
Parameters
context
SafeLLamaContextHandle
Returns
Dispose()
1 |
|
Sample(SafeLLamaContextHandle, Int32)
1 |
|
Parameters
index
Int32
Returns
Apply(SafeLLamaContextHandle, LLamaTokenDataArray)
1 |
|
Parameters
data
LLamaTokenDataArray
Apply(SafeLLamaContextHandle, LLamaTokenDataArrayNative&)
Apply this sampling chain to a LLamaTokenDataArrayNative
1 |
|
Parameters
data
LLamaTokenDataArrayNative&
Reset()
1 |
|
Accept(LLamaToken)
1 |
|
Parameters
token
LLamaToken