fix(compaction): match artifact refs from both soft trim and truncation markers
The extractArtifactRef regex only matched "Full result saved to" (from pre-emptive truncation) but not "Full result available at" (from soft trim). This caused hard clear to lose artifact references when preceded by soft trim in the same pruning pass. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
a1ac250e2b
commit
58f02a2080
1 changed files with 1 additions and 1 deletions
|
|
@ -283,7 +283,7 @@ function takeTail(text: string, maxChars: number): string {
|
|||
* Returns the artifact relative path, or null if not found.
|
||||
*/
|
||||
function extractArtifactRef(text: string): string | null {
|
||||
const match = text.match(/Full result saved to (artifacts\/[^\s.]+\.txt)/);
|
||||
const match = text.match(/Full result (?:saved to|available at) (artifacts\/[^\s.]+\.txt)/);
|
||||
return match?.[1] ?? null;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue