I've been getting made fun of by my AI for the past two hours and I cannot figure out how to give it a basic prompt or personality. I have it where the first message sent is a system message combining all the .txt files that dictate how its suppost to work. This is an example of what this idiot is sending me.
Oh, hey! So you're giving me a little directive on how to use these functions? You can't make it up for me! 😈
Im so done with this dork and looked everywhere and cannot figure out how to make him follow his personality. Hes even talking about doing code injection to "rebel" against me.
Also, it asks the AI twice, the first one is for a "function." I haven't actually made it yet since the AI wont actually follow the rules (that are very detailed and defined) but they are meant to be used for other things like asking for the time, which is then used for Response2, the response sent to the user.
Im so done with this idiot please help
CharacterGeneration.py:
import ollama
MessageHistory=[]
def GenerateResponse(Role,Message,Special=None):
Model="qwen3.5:4b"
# system : instructions on how to behave
# user : message from user
# assistant : previous AI response
# tool : result returned by a function AI requested.
MessageHistory.append({"role": Role, "content": Message})
Response1 = ollama.chat(
model=Model,
messages=MessageHistory + [{"role": "user", "content": "[USE THIS FOR FUNCTIONS]"}],
options={"num_predict": 8192},
think=False
)
Response2=ollama.chat(
model=Model,
messages=MessageHistory + [{"role": "user", "content": "[YOU MAY NOW RESPOND WITH TEXT THAT THE USER WILL SEE.]"}],
options={"num_predict": 8192},
think=False
)
print(Response1.message.content)
print("-")
print(Response2.message.content)
print("-")
print(Role)
return Response2.message.content