From 326c802be7694e6d820080a845ebeb7a0fa42ca9 Mon Sep 17 00:00:00 2001 From: Tim Miller Date: Thu, 31 Aug 2023 22:19:29 +0900 Subject: [PATCH] Have weights generate context --- LLama/LLamaEmbedder.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/LLama/LLamaEmbedder.cs b/LLama/LLamaEmbedder.cs index 5f7e6c12..0bb3f669 100644 --- a/LLama/LLamaEmbedder.cs +++ b/LLama/LLamaEmbedder.cs @@ -29,9 +29,9 @@ namespace LLama _ctx = weights.CreateContext(@params); } - public LLamaEmbedder(LLamaContext ctx) + public LLamaEmbedder(LLamaWeights weights, IModelParams @params) { - _ctx = ctx; + _ctx = weights.CreateContext(@params); } ///