@@ -363,7 +363,7 @@ def minigpt4_end_chat_image(self, ctx: MiniGPT4Context, n_threads: int = 0, temp
363
363
364
364
token = CHAR_PTR ()
365
365
self .panic_if_error (self .library .minigpt4_end_chat_image (ctx .ptr , ctypes .pointer (token ), n_threads , temp , top_k , top_p , tfs_z , typical_p , repeat_last_n , repeat_penalty , alpha_presence , alpha_frequency , mirostat , mirostat_tau , mirostat_eta , penalize_nl ))
366
- return ctypes .cast (token , ctypes .c_char_p ).value .decode ('utf-8' )
366
+ return ctypes .cast (token , ctypes .c_char_p ).value .decode ()
367
367
368
368
def minigpt4_system_prompt (self , ctx : MiniGPT4Context , n_threads : int = 0 ):
369
369
"""
@@ -417,7 +417,7 @@ def minigpt4_end_chat(self, ctx: MiniGPT4Context, n_threads: int = 0, temp: floa
417
417
418
418
token = CHAR_PTR ()
419
419
self .panic_if_error (self .library .minigpt4_end_chat (ctx .ptr , ctypes .pointer (token ), n_threads , temp , top_k , top_p , tfs_z , typical_p , repeat_last_n , repeat_penalty , alpha_presence , alpha_frequency , mirostat , mirostat_tau , mirostat_eta , penalize_nl ))
420
- return ctypes .cast (token , ctypes .c_char_p ).value .decode ('utf-8' )
420
+ return ctypes .cast (token , ctypes .c_char_p ).value .decode ()
421
421
422
422
def minigpt4_reset_chat (self , ctx : MiniGPT4Context ):
423
423
"""
@@ -498,7 +498,7 @@ def minigpt4_error_code_to_string(self, error_code: int) -> str:
498
498
str: Error string.
499
499
"""
500
500
501
- return self .library .minigpt4_error_code_to_string (error_code ).decode ('utf-8' )
501
+ return self .library .minigpt4_error_code_to_string (error_code ).decode ()
502
502
503
503
def minigpt4_quantize_model (self , in_path : str , out_path : str , data_type : DataType ):
504
504
"""
0 commit comments