fix: adjust kv_override member names to match llama.cpp

This commit is contained in:
Andrei Betlen 2024-05-29 02:28:58 -04:00
parent df45a4b3fe
commit 91d05aba46

View file

@ -613,17 +613,17 @@ LLAMA_KV_OVERRIDE_TYPE_STR = 3
# }; # };
class llama_model_kv_override_value(ctypes.Union): class llama_model_kv_override_value(ctypes.Union):
_fields_ = [ _fields_ = [
("int_value", ctypes.c_int64), ("val_i64", ctypes.c_int64),
("float_value", ctypes.c_double), ("val_f64", ctypes.c_double),
("bool_value", ctypes.c_bool), ("val_bool", ctypes.c_bool),
("str_value", ctypes.c_char * 128), ("val_str", ctypes.c_char * 128),
] ]
if TYPE_CHECKING: if TYPE_CHECKING:
int_value: int val_i64: int
float_value: float val_f64: float
bool_value: bool val_bool: bool
str_value: bytes val_str: bytes
class llama_model_kv_override(ctypes.Structure): class llama_model_kv_override(ctypes.Structure):