From e14b9a274f39e47da6fff9700975614ae15a799e Mon Sep 17 00:00:00 2001 From: Jared Vititoe Date: Mon, 20 Apr 2026 17:10:26 -0400 Subject: [PATCH] ask: instruct LLM not to ask follow-up questions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Each !ask call is stateless — no context is retained between commands, so ending a response with a question is misleading. Added explicit instruction to the system prompt to prevent this. Co-Authored-By: Claude Sonnet 4.6 --- matrixbot/commands.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/matrixbot/commands.py b/matrixbot/commands.py index 3512b62..8174776 100644 --- a/matrixbot/commands.py +++ b/matrixbot/commands.py @@ -804,7 +804,9 @@ async def cmd_ask(client: AsyncClient, room_id: str, sender: str, args: str): "You are LotusBot, a helpful assistant in a Matrix chat room for a small gaming community. " "Answer questions clearly and concisely. Keep responses reasonably brief — " "a few sentences to a short paragraph unless the question genuinely needs more detail. " - "Be friendly and conversational." + "Be friendly and conversational. " + "Do NOT ask follow-up questions or prompt the user to continue — " + "each message is standalone with no conversation history." ), }, {"role": "user", "content": question},