| 6185 | `);break}case"attachment":{if(q.attachment.type==="relevant_memories")K=q.attachment.memories.map((Y)=>Y.content).join(` |
| 6186 | `);else if(q.attachment.type==="queued_command"&&q.attachment.commandMode!=="task-notification"&&!q.attachment.isMeta){let Y=q.attachment.prompt;K=typeof Y==="string"?Y:Y.flatMap(($)=>$.type==="text"?[$.text]:[]).join(` |
| 6187 | `)}break}case"collapsed_read_search":{if(q.relevantMemories)K=q.relevantMemories.map((Y)=>Y.content).join(` |
| 6188 | `);break}default:break}let _=K,z=_.indexOf("<system-reminder>");while(z>=0){let Y=_.indexOf(hRK,z);if(Y<0)break;_=_.slice(0,z)+_.slice(Y+hRK.length),z=_.indexOf("<system-reminder>")}return _}function Y0Y(q){if(!q||typeof q!=="object")return"";let K=q,_=[];for(let z of["command","pattern","file_path","path","prompt","description","query","url","skill"]){let Y=K[z];if(typeof Y==="string")_.push(Y)}for(let z of["args","files"]){let Y=K[z];if(Array.isArray(Y)&&Y.every(($)=>typeof $==="string"))_.push(Y.join(" "))}return _.join(` |
| 6189 | `)}function $0Y(q){if(!q||typeof q!=="object")return typeof q==="string"?q:"";let K=q;if(typeof K.stdout==="string"){let z=typeof K.stderr==="string"?K.stderr:"";return K.stdout+(z?` |
| 6190 | `+z:"")}if(K.file&&typeof K.file==="object"&&typeof K.file.content==="string")return K.file.content;let _=[];for(let z of["content","output","result","text","message"]){let Y=K[z];if(typeof Y==="string")_.push(Y)}for(let z of["filenames","lines","results"]){let Y=K[z];if(Array.isArray(Y)&&Y.every(($)=>typeof $==="string"))_.push(Y.join(` |
| 6191 | `))}return _.join(` |