Harden pasted Scattermind thread handoffs
This commit is contained in:
@@ -1254,6 +1254,33 @@ try {
|
||||
assert.equal(threadsFallback.handoff.readiness.status, 'ready');
|
||||
assert.deepEqual(threadsFallback.handoff.warnings, []);
|
||||
|
||||
const pastedThreadOnlyResponse = await fetch(`${base}/api/rank-feedback`, {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
idea: `Scattermind export:\n\n\`\`\`json\n${JSON.stringify({
|
||||
sourceSummary: 'A source-summary-only Concept Map paste with action threads and no explicit reference code.',
|
||||
actionThreads: [
|
||||
'Start with a manual source-summary proof for one tired user.',
|
||||
'Validate whether the copied handoff tells the user what to do next.',
|
||||
'Hold for later: polished export styling after comprehension proof.',
|
||||
'Set aside: account dashboard with saved workspaces before proof.',
|
||||
],
|
||||
})}\n\`\`\``,
|
||||
context: 'Avoid account dashboards and saved workspaces before manual proof.',
|
||||
mode: 'mvp',
|
||||
}),
|
||||
});
|
||||
assert.equal(pastedThreadOnlyResponse.status, 200);
|
||||
const pastedThreadOnly = await pastedThreadOnlyResponse.json();
|
||||
assert.equal(pastedThreadOnly.input.embeddedPayloadSource, 'idea');
|
||||
assert.match(pastedThreadOnly.input.provenance.sourceSummary, /source-summary-only Concept Map/);
|
||||
assert.equal(pastedThreadOnly.input.optionCount, 4);
|
||||
assert.equal(pastedThreadOnly.ranked[0].id, 'action-thread-1');
|
||||
assert.equal(pastedThreadOnly.ranked.find(item => item.id === 'action-thread-4').lane.id, 'park');
|
||||
assert.equal(pastedThreadOnly.handoff.readiness.status, 'ready');
|
||||
assert.deepEqual(pastedThreadOnly.handoff.warnings, []);
|
||||
|
||||
const questionsFallbackResponse = await fetch(`${base}/api/rank-feedback`, {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
|
||||
Reference in New Issue
Block a user