Skip to content

Latest commit

 

History

History
150 lines (110 loc) · 5.52 KB

File metadata and controls

150 lines (110 loc) · 5.52 KB

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

[2.1.0] - 2026-06-10

Added

  • --source web|api flag to filter predictions by how they were created (web predictions are kept indefinitely by Replicate; API prediction data is deleted after ~1 hour)
  • Concurrent downloads with a bounded pool (downloadConcurrency, default 4) — large archives download several times faster
  • Extension fallback via the response Content-Type header for extensionless output URLs (no more hostname-garbage extensions)

Fixed

  • Outputs nested inside objects (e.g. {images: [...]}) are now downloaded; previously these predictions silently produced no files
  • Failed downloads (404/403/expired URLs) now error cleanly instead of saving the error response body as the output file
  • Downloads follow redirects
  • Reported file sizes are actual bytes written, not the (often missing) Content-Length header

Changed

  • Removed the fixed 100ms delay between downloads (replaced by the bounded concurrency pool)

[2.0.9] - 2026-06-10

Fixed

  • Per-model status counts in the metadata export were broken (successful always 0, succeeded: NaN); stats are now keyed by real API status values (succeeded/failed/canceled/etc.)
  • API errors (invalid token, rate limit, server errors) now fail loudly with status and detail instead of being silently reported as "No predictions found!"
  • --last-run state is no longer saved when a fetch ends early due to an error, so interrupted runs can't silently skip predictions on the next incremental download; the watermark is now the fetch start time rather than end-of-run
  • LICENSE copyright holder restored in the published package (the 2.0.8 publish shipped without it)

Changed

  • Date filtering now uses Replicate's documented created_after/created_before query parameters, so filtering happens server-side (the client-side filter remains as a safety net)
  • Authentication uses the documented Authorization: Bearer scheme (was the legacy Token scheme)
  • README documents Replicate's actual data retention policy: API predictions are removed after one hour by default; web predictions are kept indefinitely
  • Author credit updated to Hunter Shokrian

Added

  • Test suite (npm test, zero new dependencies via node:test) covering metadata stats, date filter params, auth/error handling, and incremental-state safety

[2.0.8] - 2026-02-04

Fixed

  • Main module check now works when invoked via relative paths

[2.0.7] - 2025-12-17

Changed

  • LICENSE copyright holder updated to closestfriend

Security

  • Fixed dependency vulnerabilities (glob, js-yaml)

[2.0.6] - 2025-10-05

Changed

  • Updated archiver to v7.0.1 to fix deprecated dependency warnings

[2.0.5] - 2025-10-05

Fixed

  • Version display now reads from package.json dynamically

[2.0.4] - 2025-10-04

Added

  • CLI bin mappings (replicate-downloader, replicate-predictions-downloader) with shebang, so the tool works via npx and global install

Changed

  • Clarified installation methods and usage instructions in README

[2.0.3] - 2025-09-08

Added

  • Relative date parsing: "yesterday", "N minutes/hours/days/weeks/months/years ago"
  • Client-side date filtering and early-stop pagination when bounds met
  • ESLint v9 flat config with scripts (lint, lint:fix)

Changed

  • Improved README and internal examples; underscore convention for intentionally-unused variables

Security

  • Ensure state file and outputs remain gitignored

[2.0.0] - 2024-12-15

Added

  • Complete rewrite with Commander.js CLI interface
  • Date filtering with --since, --until, and --last-run options
  • State tracking to prevent duplicate downloads
  • Flexible date parsing (ISO dates, relative dates, natural language)
  • Enhanced metadata collection and storage
  • ZIP archive creation for organized storage
  • Comprehensive CLI help and version commands
  • Progress tracking and detailed statistics
  • Intelligent filename generation from prompts

Changed

  • Breaking: Command-line interface completely redesigned
  • Breaking: Output structure now organized by model and date
  • Breaking: Requires Node.js 18+ (was 16+)
  • Improved error handling and retry logic
  • Better file organization and naming conventions
  • Enhanced logging and user feedback

Removed

  • Breaking: Old command-line arguments no longer supported
  • Legacy configuration options

Fixed

  • Rate limiting issues with Replicate API
  • File naming conflicts and special character handling
  • Memory usage optimization for large prediction sets
  • Duplicate download prevention

[1.x.x] - Previous versions

Legacy Features

  • Basic prediction downloading
  • Simple file organization
  • Manual duplicate management

Migration Guide from v1.x to v2.0

Command Line Changes

# Old v1.x usage
node script.js

# New v2.0 usage
node index.js
npm start
node index.js --since "2024-01-01"
node index.js --last-run

New Features to Explore

  • Use --last-run for daily/regular downloads
  • Try --since "1 week ago" for recent predictions
  • Check the new organized output structure
  • Explore enhanced metadata files

Configuration Changes

  • Review the CONFIG object in index.js for new options
  • Set up .env file for API token (recommended)
  • Note the new .replicate-downloader-state.json state file

For detailed usage instructions, see the README.md.