Add per-feature Cursor channel toggles for admin and runtime.
Memind CI / Test, build, and release guards (push) Has been cancelled

Expose page/data/scheduled-task/chat-bridge switches in the智趣体验通道 config so Tang can roll out Cursor paths independently with DeepSeek fallback.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
john
2026-08-31 09:40:52 +08:00
parent ac2c87be43
commit 617ff0d1dd
21 changed files with 915 additions and 127 deletions
+24
View File
@@ -128,6 +128,30 @@ test('page cursor default is disabled without env flag', () => {
assert.equal(isPageCursorDefaultCandidate(userMessage, { env: {} }), false);
});
test('page cursor default respects policy feature toggles', () => {
const userMessage = {
role: 'user',
content: [{ type: 'text', text: '帮我做一个调查问卷页面' }],
metadata: { displayText: '帮我做一个调查问卷页面' },
};
const policy = {
enabled: true,
features: {
pageGenerate: { enabled: false },
pageData: { enabled: false },
excelAnalysis: { enabled: false },
},
};
assert.equal(
isPageCursorDefaultCandidate(userMessage, {
env: enabledEnv,
channelEligible: true,
policy,
}),
false,
);
});
test('applyCursorFirstAgentExecution no longer forces cursor for generic agent tasks', () => {
const enabledEnv = {
MEMIND_CURSOR_EXECUTOR_ENABLED: '1',