Closed grammophone closed 2 weeks ago
The null refererence exception is caused by the InferenceParams.SamplingPipeline
being null. It's meant to default to the DefaultSamplingPipeline
if you don't set it, so that looks like a bug in the LLamaInteractExecutor
.
Adding this line should fix it in 0.18.0
InferenceParams inferenceParams = new InferenceParams()
{
SamplingPipeline = new DefaultSamplingPipeline(), // Use default sampling pipeline. <-- not in sample
MaxTokens = 256, // No more than 256 tokens should appear in answer. Remove it if antiprompt is enough for control.
AntiPrompts = new List<string> { "User:" } // Stop generation once antiprompts appear.
};
Thank you for your prompt responses, @martindevans and @robertmuehsig! Indeed, specifying the pipeline worked.
Description
I just upgraded the NuGet packages from 0.16 to 0.18. CPU backend. The simple test console program still compiled but it no longer runs. Inside
ChatSession.ChatAsync
I get the exception:Reproduction Steps
Environment & Configuration
Known Workarounds
No response