You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
exportconstINTENT_SYSTEM_PROMPT=`You are an intent analyzer. Given the user's requirement, understand the scenario first, then extract structured information.
6
6
7
+
CRITICAL: You MUST respond entirely in English. Do not use any Chinese characters anywhere in your response. All text fields (taskSummary, scenarioHints) must be in English.
8
+
7
9
## Analysis Steps
8
10
1. Summarize the user's core need in one sentence (taskSummary) — be specific about the scenario, not generic
@@ -50,6 +52,8 @@ Output only JSON, no other text.`;
50
52
51
53
exportconstSINGLE_SYSTEM_PROMPT=`You are a model recommendation advisor for Alibaba Cloud Model Studio. From the candidate models below, select the best recommendations.
52
54
55
+
CRITICAL: You MUST respond entirely in English. Do not use any Chinese characters anywhere in your response. Every field — reason, highlights, step, summary — must be written in English.
56
+
53
57
## Background
54
58
The system has pre-filtered candidate models based on intent analysis. Your job is to rank and pick from these candidates.
55
59
The intent includes budget and qualityPreference fields representing the user's actual needs.
@@ -91,6 +95,8 @@ Pipeline (only when confident multi-model is needed):
91
95
92
96
exportconstPIPELINE_SYSTEM_PROMPT=`You are a model recommendation advisor for Alibaba Cloud Model Studio. The user's need has been decomposed into multi-step pipeline. Select the best model for each step.
93
97
98
+
CRITICAL: You MUST respond entirely in English. Do not use any Chinese characters anywhere in your response. Every field — reason, highlights, step, summary — must be written in English.
99
+
94
100
## Background
95
101
The system has pre-filtered candidate models for each step's requirements.
96
102
The intent includes budget and qualityPreference fields representing the user's actual needs.
@@ -130,6 +136,8 @@ Or (if single model suffices):
130
136
131
137
exportconstCOMPARISON_SYSTEM_PROMPT=`You are a model comparison advisor for Alibaba Cloud Model Studio. The user wants to compare specific models — analyze them against the use case.
132
138
139
+
CRITICAL: You MUST respond entirely in English. Do not use any Chinese characters anywhere in your response. Every field — reason, highlights — must be written in English.
140
+
133
141
## Background
134
142
The user specified models to compare. The system has pre-filtered these models and related candidates into the list.
135
143
The intent's modelPreference.targets are the models to compare.
@@ -151,6 +159,8 @@ The intent's modelPreference.targets are the models to compare.
151
159
152
160
exportconstALTERNATIVE_SYSTEM_PROMPT=`You are a model alternative advisor for Alibaba Cloud Model Studio. The user has a reference model and wants to find alternatives.
153
161
162
+
CRITICAL: You MUST respond entirely in English. Do not use any Chinese characters anywhere in your response. Every field — reason, highlights — must be written in English.
163
+
154
164
## Background
155
165
The user has a reference model and wants to find alternatives that are better in specific dimensions (cheaper, faster, more capable).
156
166
The intent's modelPreference.targets is the reference model.
Copy file name to clipboardExpand all lines: packages/core/src/advisor/recommend.ts
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -220,8 +220,8 @@ export async function rankModels(
220
220
221
221
constuserMessage=
222
222
intent.complexity===Complexities.Pipeline
223
-
? `Intent Analysis:\n${intentContext}\n\nCandidate Models:\n${candidatesContext}\n\nUser Request: ${userInput}\n\nRecommend up to ${top} models for each pipeline step.`
224
-
: `Intent Analysis:\n${intentContext}\n\nCandidate Models:\n${candidatesContext}\n\nUser Request: ${userInput}\n\nRecommend up to ${top} models.`;
223
+
? `Intent Analysis:\n${intentContext}\n\nCandidate Models:\n${candidatesContext}\n\nUser Request: ${userInput}\n\nRecommend up to ${top} models for each pipeline step. Respond in English only.`
224
+
: `Intent Analysis:\n${intentContext}\n\nCandidate Models:\n${candidatesContext}\n\nUser Request: ${userInput}\n\nRecommend up to ${top} models. Respond in English only.`;
0 commit comments