summaryrefslogtreecommitdiff
path: root/continuedev/src
diff options
context:
space:
mode:
authorLuna <git@l4.pm>2023-07-30 23:32:39 -0300
committerLuna <git@l4.pm>2023-07-30 23:32:39 -0300
commit685b1ce062a989490758c86f1cf2c187efafded8 (patch)
treedcea896f4cab87861c2b13626508c51df88a693f /continuedev/src
parentd451b92810d73ccbdbec64b4421b0dd172f28f7f (diff)
downloadsncontinue-685b1ce062a989490758c86f1cf2c187efafded8.tar.gz
sncontinue-685b1ce062a989490758c86f1cf2c187efafded8.tar.bz2
sncontinue-685b1ce062a989490758c86f1cf2c187efafded8.zip
let content_length be customized on GGML
Diffstat (limited to 'continuedev/src')
-rw-r--r--continuedev/src/continuedev/libs/llm/ggml.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/continuedev/src/continuedev/libs/llm/ggml.py b/continuedev/src/continuedev/libs/llm/ggml.py
index a760f7fb..378ec106 100644
--- a/continuedev/src/continuedev/libs/llm/ggml.py
+++ b/continuedev/src/continuedev/libs/llm/ggml.py
@@ -12,10 +12,13 @@ SERVER_URL = "http://localhost:8000"
class GGML(LLM):
+ # this is model-specific
+ max_context_length: int
_client_session: aiohttp.ClientSession = None
- def __init__(self, system_message: str = None):
+ def __init__(self, max_context_length: int = 2048, system_message: str = None):
+ self.max_context_length = max_context_length
self.system_message = system_message
async def start(self, **kwargs):
@@ -30,7 +33,7 @@ class GGML(LLM):
@property
def context_length(self):
- return 2048
+ return self.max_context_length
@property
def default_args(self):