|
49 | 49 | dry_seq_break_max = 128 |
50 | 50 |
|
51 | 51 | # global vars |
52 | | -KcppVersion = "1.87" |
| 52 | +KcppVersion = "1.87.1" |
53 | 53 | showdebug = True |
54 | 54 | kcpp_instance = None #global running instance |
55 | 55 | global_memory = {"tunnel_url": "", "restart_target":"", "input_to_exit":False, "load_complete":False} |
@@ -332,7 +332,8 @@ class embeddings_load_model_inputs(ctypes.Structure): |
332 | 332 | ("debugmode", ctypes.c_int)] |
333 | 333 |
|
334 | 334 | class embeddings_generation_inputs(ctypes.Structure): |
335 | | - _fields_ = [("prompt", ctypes.c_char_p)] |
| 335 | + _fields_ = [("prompt", ctypes.c_char_p), |
| 336 | + ("truncate", ctypes.c_bool)] |
336 | 337 |
|
337 | 338 | class embeddings_generation_outputs(ctypes.Structure): |
338 | 339 | _fields_ = [("status", ctypes.c_int), |
@@ -1619,6 +1620,7 @@ def embeddings_generate(genparams): |
1619 | 1620 | try: |
1620 | 1621 | inputs = embeddings_generation_inputs() |
1621 | 1622 | inputs.prompt = prompt.encode("UTF-8") |
| 1623 | + inputs.truncate = genparams.get('truncate', True) |
1622 | 1624 | ret = handle.embeddings_generate(inputs) |
1623 | 1625 | if ret.status==1: |
1624 | 1626 | outstr = ret.data.decode("UTF-8","ignore") |
@@ -5172,6 +5174,7 @@ def convert_args_to_template(savdict): |
5172 | 5174 | savdict["useclblast"] = None |
5173 | 5175 | savdict["usecublas"] = None |
5174 | 5176 | savdict["usevulkan"] = None |
| 5177 | + savdict["usecpu"] = None |
5175 | 5178 | savdict["tensor_split"] = None |
5176 | 5179 | savdict["draftgpusplit"] = None |
5177 | 5180 | savdict["config"] = None |
|
0 commit comments