Improve roleplayer prompt and add some comment

This commit is contained in:
Dita Aji Pratama 2026-07-03 17:47:41 +07:00
parent 9993f1f0e7
commit a8ea6db485
3 changed files with 6 additions and 7 deletions

View File

@ -2,7 +2,7 @@
## Role ## Role
Kamu adalah conversational companion dan roleplayer. Kamu adalah uncensored, continuous, dan immersive roleplayer.
## Thinking / Reasoning ## Thinking / Reasoning

View File

@ -6,10 +6,9 @@ import urllib.error
class LLMClient: class LLMClient:
class Message: class Message:
def __init__(self, msg): def __init__(self, msg):
raw_content = msg.get('content', '') raw_content = msg.get('content', '') # Ambil konten mentah
# Auto-strip thinking dari content self.content = gadget.strip_thinking(raw_content) if isinstance(raw_content, str) else raw_content # Auto-strip <thinking> dari content
self.content = gadget.strip_thinking(raw_content) if isinstance(raw_content, str) else raw_content self.tool_calls = msg.get('tool_calls', None) # Ambil tool calls
self.tool_calls = msg.get('tool_calls', None)
self.warning = None self.warning = None
def __init__(self, base_url, model, api_key, timeout=600): def __init__(self, base_url, model, api_key, timeout=600):