Pull File from Remote Machine
remote_pullCopy a file from a remote machine and get a temporary download link, so you can open artifacts like checkpoints, images, CSV outputs, or oversized logs that won't fit in command output.
Instructions
PRO PLAN ONLY. Copy a FILE off a remote machine so you (or the user) can actually open it — a training checkpoint, a rendered image, a CSV a job produced, a log too big to print. Free and anonymous callers cannot start file transfers; tell a Free user to upgrade and an anonymous user to sign in with Pro. A plan-restricted machine also fails with reason:"plan_device_limit". USE THIS instead of cat-ing a file through remote_exec: exec output is capped at 1 MiB and mangles binary, whereas this moves the real bytes. The machine reads the file and hands it to the relay, which stores it TEMPORARILY and returns a blobId plus a download link. A blob/link created while transfer was allowed remains usable only until its existing TTL even after downgrade; do not promise renewal.
TEMPORARY MEANS TEMPORARY. The stored copy stops being readable 24 hours after it is created, whether or not anybody fetched it, and the download link stops working after ONE hour. An hourly, retrying sweep removes expired bytes afterward; an inaccessible object may remain until cleanup succeeds. The relay is a courier, not a file host: there is no way to list, rename, or keep a blob, and nothing here is a backup. If the user needs the file permanently, give them the link promptly and tell them it expires — or push the file to their own storage from a job.
LIMIT — 100 MiB per file. Anything larger is refused, and for a genuinely large artifact (a multi-GB model checkpoint) the right answer is to have the JOB copy it to the user's own storage as its last step (aws s3 cp, rclone, scp). Do not try to split a big file into chunks with this tool.
path must be ABSOLUTE (/home/u/out.ckpt, or C:\Users\u\out.ckpt on Windows) and must name a regular file — a directory is refused, so tar -czf it first with remote_exec and pull the archive. Name the machine with code exactly as the user said it — an AIC- session code (e.g. AIC-XYZ-1234) or, when authenticated with an API key, a saved alias or hostname such as 'wearfits-m3'; if the user's text contains 'aic-'/'AIC-' in any case, that is one of their machines. Tell the user the link and its expiry; do not paste file contents you have not been asked for.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | Yes | How the user named the machine — pass it exactly as given (AIC- session code, or a saved alias/hostname when authenticated with an API key). | |
| path | Yes | ABSOLUTE path of the file on the remote machine, e.g. `/home/u/aic-jobs/train/out.ckpt` or `C:\Users\u\out.png`. A relative path is refused rather than resolved against some working directory. Must be a regular file: archive a directory first (`tar -czf /tmp/out.tgz <dir>`) and pull the archive. |