agentreel 0.4.1 → 0.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agentreel",
3
- "version": "0.4.1",
3
+ "version": "0.4.2",
4
4
  "description": "Turn your web apps and CLIs into viral clips",
5
5
  "bin": {
6
6
  "agentreel": "./bin/agentreel.mjs"
Binary file
@@ -215,6 +215,16 @@ def extract_highlights(cast_path: str, context: str, guidelines: str = "") -> li
215
215
  raw_output = "".join(lines_output)
216
216
  # Clean ANSI for Claude to read, but keep the raw for display
217
217
  clean = re.sub(r'\x1b\[[0-9;]*[a-zA-Z]', '', raw_output)
218
+ # Collapse carriage-return overwrites (spinners, progress bars).
219
+ # \r means "go back to line start" — keep only the final version of each line.
220
+ collapsed_lines = []
221
+ for line in clean.split('\n'):
222
+ parts = line.split('\r')
223
+ # Keep only the last non-empty segment (what's actually visible)
224
+ final = parts[-1].strip() if parts else ""
225
+ if final and (not collapsed_lines or final != collapsed_lines[-1]):
226
+ collapsed_lines.append(final)
227
+ clean = '\n'.join(collapsed_lines)
218
228
 
219
229
  guidelines_block = f"\n\nAdditional guidelines: {guidelines}" if guidelines else ""
220
230