docs: rebalance prose cleanup and add trimming skill

This commit is contained in:
Tianyi Cui
2026-07-13 23:27:00 +08:00
parent fcdc318dda
commit 148046b9c8
392 changed files with 2801 additions and 1754 deletions

View File

@@ -224,10 +224,8 @@ describe('dsh-tool-workflow', () => {
describe('composition with the REAL worker-thread engine (the mock above must stay honest)', () => {
it('an abort releases the tool even when the script parks on a promise no hook owns', async () => {
// Regression for the review-found turn wedge: the tool awaits run.result before its
// disposing finally, the registry and the loop await the tool — so if cancellation could
// not settle result (a script parked on `await new Promise(() => {})`), an aborted turn
// stayed wedged forever.
// The tool and loop await run.result before cleanup, so cancellation must settle a script
// parked on an unowned promise. Exercise that guarantee through the real registry and worker.
const ctx = new Context()
await ctx.plugin(SystemPrompt)
await ctx.plugin(ToolRegistry)