Compare commits
2 Commits
6d5e90d278
...
3182959210
Author | SHA1 | Date | |
---|---|---|---|
|
3182959210 | ||
|
29c6ee9a90 |
@ -31,7 +31,7 @@ class IDGAFServer(BaseHTTPRequestHandler):
|
|||||||
print(command)
|
print(command)
|
||||||
if command['message']['command'] == 'aidgaf':
|
if command['message']['command'] == 'aidgaf':
|
||||||
[responseCode, json_response] = idgaf.parse_idgaf_request(command)
|
[responseCode, json_response] = idgaf.parse_idgaf_request(command)
|
||||||
json_response['hash'] = security.get_message_hash(json.dumps(response_body))
|
json_response['hash'] = security.get_message_hash(json.dumps(command))
|
||||||
response_body = json.dumps(json_response)
|
response_body = json.dumps(json_response)
|
||||||
self.handle_response(responseCode, response_body)
|
self.handle_response(responseCode, response_body)
|
||||||
|
|
||||||
@ -50,7 +50,7 @@ class IDGAFServer(BaseHTTPRequestHandler):
|
|||||||
self.send_response(code)
|
self.send_response(code)
|
||||||
self.send_header("Content-type", "text/html")
|
self.send_header("Content-type", "text/html")
|
||||||
self.end_headers()
|
self.end_headers()
|
||||||
print("sending:"+response_body)
|
print("sending:"+body)
|
||||||
self.wfile.write(bytes(body, UTF8))
|
self.wfile.write(bytes(body, UTF8))
|
||||||
|
|
||||||
def perform_sanity_checks(str_request):
|
def perform_sanity_checks(str_request):
|
||||||
|
@ -14,9 +14,9 @@ HASHKEY = bytes(os.getenv('HASHKEY'),UTF8) # shared secret for hmac of message
|
|||||||
|
|
||||||
# The prompts used for OpenAI.
|
# The prompts used for OpenAI.
|
||||||
PROMPTS = [
|
PROMPTS = [
|
||||||
# "Say \"USERNAME does not give a fuck\" as a haiku and mention that it is a haiku.",
|
"Say \"USERNAME does not give a fuck\" as a haiku and mention that it is a haiku.",
|
||||||
# "Say \"USERNAME does not give a fuck\" in a Dr Suess poem.",
|
"Say \"USERNAME does not give a fuck\" in a Dr Suess poem.",
|
||||||
# "Tell me a story about how \"USERNAME does not give a fuck\" using an outrageous situation where someone should care but they do not and thats fine.",
|
"Tell me a story about how \"USERNAME does not give a fuck\" using an outrageous situation where someone should care but they do not and thats fine.",
|
||||||
"Say \"USERNAME is completely apethetic and does not give a fuck\" in a verbose manner, using your most colorful words and one metaphor."
|
"Say \"USERNAME is completely apethetic and does not give a fuck\" in a verbose manner, using your most colorful words and one metaphor."
|
||||||
]
|
]
|
||||||
OPEN_AI_MAX_TOKENS = 500
|
OPEN_AI_MAX_TOKENS = 500
|
||||||
|
Loading…
x
Reference in New Issue
Block a user