Files
lancedb/docs/src/js/interfaces/WriteProgress.md
Brendan Clement 049b0c8f09 feat(nodejs): add progress to Table.add (#3398)
### Summary

- Add an optional `progress` callback to `Table.add(data, { progress
})`. Callback fires once per batch written and once more with `done:
true` when the write completes.
- Errors thrown from the user's callback are logged with `console.warn`
and swallowed

### Testing
- npm test 
- ran smoke test script to verify functionality
2026-05-19 18:35:07 -07:00

1.1 KiB

@lancedb/lancedbDocs


@lancedb/lancedb / WriteProgress

Interface: WriteProgress

Progress snapshot for a write operation, delivered to the progress callback passed to Table.add.

Properties

activeTasks

activeTasks: number;

Number of parallel write tasks currently in flight.


done

done: boolean;

true for the final callback; false otherwise.


elapsedSeconds

elapsedSeconds: number;

Wall-clock seconds since the write started.


outputBytes

outputBytes: number;

Number of bytes written so far.


outputRows

outputRows: number;

Number of rows written so far.


totalRows?

optional totalRows: number;

Total rows expected, when the input source reports it.

Always set on the final callback (the one with done: true), falling back to the actual number of rows written when the source could not report a row count up front.


totalTasks

totalTasks: number;

Total number of parallel write tasks (the write parallelism).