mirror of
https://github.com/migatu/conjurer.git
synced 2026-07-15 22:32:10 +00:00
xd
This commit is contained in:
@@ -647,6 +647,7 @@ async def check_data():
|
|||||||
)
|
)
|
||||||
global LAST_SPONTANEOUS_CALL
|
global LAST_SPONTANEOUS_CALL
|
||||||
tdelta = datetime.now() - LAST_SPONTANEOUS_CALL
|
tdelta = datetime.now() - LAST_SPONTANEOUS_CALL
|
||||||
|
logger.info(TIME_BETWEEN_CALLS)
|
||||||
tdelta = tdelta.total_seconds()
|
tdelta = tdelta.total_seconds()
|
||||||
logger.info(tdelta)
|
logger.info(tdelta)
|
||||||
global TIME_BETWEEN_CALLS
|
global TIME_BETWEEN_CALLS
|
||||||
@@ -687,6 +688,7 @@ async def get_random_cyclic_message():
|
|||||||
"Opowiedz jakąś historię o naszym barze proszę", True, True, MESSAGE_TABLE, "Polish Hammer", "RANDOM"
|
"Opowiedz jakąś historię o naszym barze proszę", True, True, MESSAGE_TABLE, "Polish Hammer", "RANDOM"
|
||||||
)
|
)
|
||||||
logger.info(result)
|
logger.info(result)
|
||||||
|
asyncio.wait(7000)
|
||||||
else:
|
else:
|
||||||
logger.info("Wtracenie w dyskusje")
|
logger.info("Wtracenie w dyskusje")
|
||||||
messages = [message async for message in channel.history(limit=50)]
|
messages = [message async for message in channel.history(limit=50)]
|
||||||
@@ -697,6 +699,7 @@ async def get_random_cyclic_message():
|
|||||||
"A jaka jest Twoja opinia na temat dotychczasowej dyskusji?", True, True, MESSAGE_TABLE, "Polish Hammer", "RANDOM"
|
"A jaka jest Twoja opinia na temat dotychczasowej dyskusji?", True, True, MESSAGE_TABLE, "Polish Hammer", "RANDOM"
|
||||||
)
|
)
|
||||||
logger.info(result)
|
logger.info(result)
|
||||||
|
asyncio.wait(7000)
|
||||||
return result
|
return result
|
||||||
|
|
||||||
|
|
||||||
@@ -767,7 +770,7 @@ async def handle_response(prompt, vykidailo, bartender, history, username, reque
|
|||||||
history.append(temp)
|
history.append(temp)
|
||||||
|
|
||||||
final_prompt = username + ":" + prompt
|
final_prompt = username + ":" + prompt
|
||||||
logger.info(
|
logger.debug(
|
||||||
"Rozmiar zapytania przed dodaniem historii %s", chat_gpt_config_request_size
|
"Rozmiar zapytania przed dodaniem historii %s", chat_gpt_config_request_size
|
||||||
)
|
)
|
||||||
if request_type == "MUSIC":
|
if request_type == "MUSIC":
|
||||||
@@ -789,7 +792,7 @@ async def handle_response(prompt, vykidailo, bartender, history, username, reque
|
|||||||
temptable = []
|
temptable = []
|
||||||
for i in reversed(table):
|
for i in reversed(table):
|
||||||
temp_token = num_tokens_from_string(i, "gpt-4")
|
temp_token = num_tokens_from_string(i, "gpt-4")
|
||||||
logger.info(
|
logger.debug(
|
||||||
"Rozmiar zapytania %s prompt %s temp %s",
|
"Rozmiar zapytania %s prompt %s temp %s",
|
||||||
chat_gpt_config_request_size,
|
chat_gpt_config_request_size,
|
||||||
prompt_gpt_request_size,
|
prompt_gpt_request_size,
|
||||||
|
|||||||
Reference in New Issue
Block a user