Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,12 @@ Categories:
- `integrate-*`: real-world integration guides (validated via `scenarios/` + E2E, but not requiring any test harness)

Examples:
- `generate-image`
- `transform-generate-image-with-transloadit`
- `transform-remove-background-with-transloadit`
- `transform-describe-image-with-transloadit`
- `transform-convert-markdown-to-pdf-with-transloadit`
- `transform-build-polaroid-collage-with-transloadit`
- `transform-build-mosaic-collage-with-transloadit`
- `integrate-uppy-transloadit-s3-uploading-to-nextjs`

The public catalog is whatever currently lives under [`skills/`](/Users/kvz/code/skills/skills).
Expand Down
15 changes: 0 additions & 15 deletions skills/generate-image/SKILL.md

This file was deleted.

63 changes: 63 additions & 0 deletions skills/transform-build-mosaic-collage-with-transloadit/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
---
name: transform-build-mosaic-collage-with-transloadit
description: One-off justified mosaic photo collage (N local images -> single image) using the official `@transloadit/node` CLI. Uses the `/image/merge` Robot's `mosaic` effect to build a tiled layout that keeps every photo fully visible, and downloads the result to an explicit output path via `--output`.
when_to_use: |
Triggers when the user asks to create a mosaic collage, tile photos edge-to-edge, build a justified photo grid, make a Flickr-style photo layout, or compose N photos into a clean editorial collage that keeps every photo fully visible. Choose this over the polaroid skill when the vibe is clean and editorial (product grids, portfolio hero sections, social previews from a batch), and over `transform-generate-image-with-transloadit` when the input is N existing photos rather than a text prompt.
---

# Inputs

- Two or more absolute paths to local input images
- Optional output path; default to an explicit `collage.jpg` in the current working directory
- Optional canvas size (`--width`, `--height`), default `1920×1200`
- Optional `--seed` for deterministic layout

# Prepare Instructions

Resolve credentials in this order:
- Shell environment variables
- The current working directory `.env` only
- `~/.transloadit/credentials`

If your `.env` lives in a parent directory, export the variables into the shell first.

# Run

```bash
npx -y @transloadit/node image merge \
--input ./photo-a.jpg \
--input ./photo-b.jpg \
--input ./photo-c.jpg \
--input ./photo-d.jpg \
--input ./photo-e.jpg \
--input ./photo-f.jpg \
--effect mosaic \
--width 1920 \
--height 1200 \
--border 12 \
--shuffle \
--format jpg \
--output ./collage.jpg
```

After the command finishes, confirm the image exists at the expected output path.

# Tuning

- `--border 12` sets both the outer canvas padding and the gutter width between tiles. Larger values give more breathing room.
- `--background '#eee5d3'` fills the gutters and canvas padding (default). Hex codes or named colors both work.
- `--background none` (with `--format png` or `--format webp`) produces a transparent canvas and transparent gutters.
- `--shuffle` lets the Robot reorder inputs before solving the layout; combine with `--seed` to pin the shuffle.
- `--seed 42` makes the mosaic solver deterministic — rerun with the same inputs to reproduce the same output.

# Debug If It Fails

```bash
npx -y @transloadit/node assemblies get <assemblyIdOrUrl> -j
```

Notes:
- Repeated `--input` values are bundled into a single `/image/merge` assembly.
- The mosaic effect reads each input's aspect ratio and solves for a justified tile layout — portrait + landscape mixes generally produce more interesting layouts than uniform sizes.
- Unlike the polaroid-stack effect, tiles are center-cropped to fit their allocated rectangle. Any portion of a photo can be cropped off — if every pixel matters, resize beforehand with `/image/resize` and `resize_strategy: fit`.
- Prefer an explicit output filename (e.g. `./collage.jpg` or `./collage.png`) over a directory output so the extension is deterministic.
61 changes: 61 additions & 0 deletions skills/transform-build-polaroid-collage-with-transloadit/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
---
name: transform-build-polaroid-collage-with-transloadit
description: One-off polaroid-stack photo collage (N local images -> single image) using the official `@transloadit/node` CLI. Uses the `/image/merge` Robot's `polaroid-stack` effect and downloads the result to an explicit output path via `--output`.
when_to_use: |
Triggers when the user asks to create a polaroid collage, build a polaroid stack, arrange photos as polaroids, make a scrapbook-style photo collage, or lay out tilted overlapping instant photos on a canvas. Choose this over the mosaic skill when the vibe is personal or scrapbook-ish (event recaps, "year in photos"), and over `transform-generate-image-with-transloadit` when the input is N existing photos rather than a text prompt.
---

# Inputs

- Two or more absolute paths to local input images
- Optional output path; default to an explicit `collage.png` in the current working directory
- Optional canvas size (`--width`, `--height`), default `1920×1200`
- Optional `--seed` for deterministic layout

# Prepare Instructions

Resolve credentials in this order:
- Shell environment variables
- The current working directory `.env` only
- `~/.transloadit/credentials`

If your `.env` lives in a parent directory, export the variables into the shell first.

# Run

```bash
npx -y @transloadit/node image merge \
--input ./photo-a.jpg \
--input ./photo-b.jpg \
--input ./photo-c.jpg \
--input ./photo-d.jpg \
--input ./photo-e.jpg \
--input ./photo-f.jpg \
--effect polaroid-stack \
--width 1920 \
--height 1200 \
--format png \
--output ./collage.png
```

After the command finishes, confirm the image exists at the expected output path.

# Tuning

- `--background '#eee5d3'` picks a warm beige canvas (default). Hex codes or named colors both work.
- `--background none` (with `--format png` or `--format webp`) produces a transparent canvas.
- `--coverage 1.5` is the default. Use `2.0`–`2.5` for bigger, more overlapping photos; `1.0` or below for smaller, more widely spaced polaroids.
- `--seed 42` makes the layout deterministic — rerun with the same inputs to reproduce the same output.
- `--shuffle` lets the Robot reorder inputs before laying them out.

# Debug If It Fails

```bash
npx -y @transloadit/node assemblies get <assemblyIdOrUrl> -j
```

Notes:
- Repeated `--input` values are bundled into a single `/image/merge` assembly.
- The polaroid-stack effect works best with 4–12 inputs. Fewer than four tends to look sparse; more than a dozen starts to occlude heavily.
- Each input is cropped to a square inside its polaroid frame — portrait or landscape originals both work.
- Prefer an explicit output filename (e.g. `./collage.png` or `./collage.jpg`) over a directory output so the extension is deterministic.
2 changes: 2 additions & 0 deletions skills/transform-generate-image-with-transloadit/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---
name: transform-generate-image-with-transloadit
description: One-off image generation (prompt -> image file) using Transloadit via the `transloadit` CLI. Prefer `image generate` for text-only and input-guided generation, and use `--output` when you need a deterministic path.
when_to_use: |
Triggers when the user asks to generate an image, create an image from a prompt, make an AI image, render a picture from text, or guide image generation with reference photos. Choose this for prompt-driven or prompt+input-guided generation of a local image file. Prefer this over the collage skills when the input is a text prompt rather than N existing photos to composite.
---

# Run
Expand Down
Loading