MEDIUM SEVERITYCONFIRMED

_UPLOAD_SENTENCE_RE leaves garbled text when filename contains periods

Package
DeerFlow
Version
latest
Verified
2026-03-28

Description

DeerFlow's upload sentence regex fails to cleanly remove sentences containing filenames with periods. The regex matches up to the period in the filename extension, leaving a garbled fragment (`'pdf. They asked about Python.'`) after the sentence replacement.

Reproduction

# Input: 'The user uploaded a file called report.pdf. They asked about Python.'
# After regex substitution: 'pdf. They asked about Python.'
# Garbled fragment left behind
← All bugsScan your code →