From 328022b13d6afe399e7be2fe68b273a10f24dd5e Mon Sep 17 00:00:00 2001 From: Martin Evans Date: Thu, 19 Oct 2023 21:14:45 +0100 Subject: [PATCH] Fixed merge conflicts --- LLama.Examples/NewVersion/CodingAssistant.cs | 2 +- LLama/LLamaExecutorBase.cs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/LLama.Examples/NewVersion/CodingAssistant.cs b/LLama.Examples/NewVersion/CodingAssistant.cs index 9108e01d..727dd010 100644 --- a/LLama.Examples/NewVersion/CodingAssistant.cs +++ b/LLama.Examples/NewVersion/CodingAssistant.cs @@ -31,7 +31,7 @@ }; using var model = LLamaWeights.LoadFromFile(parameters); using var context = model.CreateContext(parameters); - var executor = new InstructExecutor(context, null!, InstructionPrefix, InstructionSuffix); + var executor = new InstructExecutor(context, InstructionPrefix, InstructionSuffix, null); Console.ForegroundColor = ConsoleColor.Yellow; Console.WriteLine("The executor has been enabled. In this example, the LLM will follow your instructions." + diff --git a/LLama/LLamaExecutorBase.cs b/LLama/LLamaExecutorBase.cs index 0c8e4679..1a12c6b2 100644 --- a/LLama/LLamaExecutorBase.cs +++ b/LLama/LLamaExecutorBase.cs @@ -75,8 +75,9 @@ namespace LLama /// /// /// - protected StatefulExecutorBase(LLamaContext context) + protected StatefulExecutorBase(LLamaContext context, ILogger? logger = null) { + _logger = logger; Context = context; _pastTokensCount = 0; _consumedTokensCount = 0;