Skip to content

Commit 71c7284

Browse files
authored
fix(test): use deterministic echo prompt for session scenarios (#5)
Align with Go/TS: 'Reply with exactly <marker>' instead of asking the model for a free-form introduction with a trailing marker. The old Chinese prompt gave the model room to refuse echoing the random string.
1 parent ed140d5 commit 71c7284

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

‎tests/support/scenarios/forward.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def session(client: Forward, context: Run) -> None:
4949
session_id = context.track("session", session.id, lambda: finish_session(client, context, session.id))
5050

5151
expected = marker()
52-
prompt = "请用一句话介绍你能提供什么帮助,并在末尾原样附上:" + expected
52+
prompt = "Reply with exactly " + expected
5353
context.output("user", prompt)
5454
sent = client.sessions.events.send(
5555
session_id,

‎tests/support/scenarios/managed.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ def session(client: Managed, context: Run) -> None:
4141
session_id = context.track("session", session.id, lambda: finish_session(client, context, session.id))
4242

4343
expected = marker()
44-
prompt = "请用一句话介绍你能提供什么帮助,并在末尾原样附上:" + expected
44+
prompt = "Reply with exactly " + expected
4545
context.output("user", prompt)
4646
sent = client.sessions.events.send(
4747
session_id,

0 commit comments

Comments
 (0)