/faucet:faucet-tunefrom faucet
Tunes faucet data pipeline throughput by measuring bottlenecks, sizing batch/concurrency/sharding, and benchmarking write modes. Use when a pipeline is too slow or must fit a time window.
Ships in faucet. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Tuning is measurement first: find which side is slow, change one setting,
measure again. This skill is that loop. A run that is slow because it
failed, waited on a rate limit or lagged is a faucet-debug problem; start
there if the run is not healthy.
The project decides which faucet to use, not whatever is on the PATH: a
config written for a newer faucet can fail or be misread on an older one.
Find the pin: the "github:faucet-hq/faucet-stream" entry under [tools]
in the project's mise.toml (faucet init writes it). A config may also
carry requires_faucet: ">=X.Y". The pin is used in commands, URLs and
image tags below, so accept only a release version: it must match
^[0-9]+\.[0-9]+\.[0-9]+(-[0-9A-Za-z.]+)?$. Stop and ask the user about
anything else.
Run faucet --version. Use that binary if it equals the pin (with no pin:
if it satisfies every requires_faucet in the project).
Otherwise, if mise is installed, run mise install
in the project and prefix every command with mise exec --.
Otherwise use the pinned container image; its entrypoint is faucet:
docker run --rm --user "$(id -u):$(id -g)" -v "$PWD:/work" -w /work ghcr.io/faucet-hq/faucet-stream:<version> --version.
Otherwise download that version's archive for this platform, check it, and only then unpack it. Never pipe a download into a shell.
v=<version> # the checked pin
t=aarch64-apple-darwin # or x86_64-apple-darwin, x86_64-unknown-linux-gnu, aarch64-unknown-linux-gnu
printf '%s\n' "$v" | grep -Eqx '[0-9]+\.[0-9]+\.[0-9]+(-[0-9A-Za-z.]+)?' || exit 1
base="https://github.com/faucet-hq/faucet-stream/releases/download/faucet-cli-v$v"
curl --proto '=https' --tlsv1.2 -fLsS -O "$base/faucet-cli-$t.tar.xz" -O "$base/faucet-cli-$t.tar.xz.sha256"
shasum -a 256 -c "faucet-cli-$t.tar.xz.sha256"
gh attestation verify "faucet-cli-$t.tar.xz" --repo faucet-hq/faucet-stream # when gh is installed
tar -xJf "faucet-cli-$t.tar.xz" # the binary is faucet-cli-$t/faucet
If the checksum or the attestation does not verify, stop and tell the user.
With no pin at all, install the latest release the same way (the archive
and its .sha256 from releases/latest/download/) and pin it as described in
Pinning the faucet version.
Every version-specific fact (which connectors and blocks exist, config keys,
types, defaults, commands and flags) comes from that binary: faucet list,
faucet schema --help, faucet schema source|sink|transform <name>,
faucet <command> --help. Never from memory or from this skill. When a config
passes faucet validate, set its requires_faucet: to ">=<major>.<minor>"
of that binary; if validate rejects requires_faucet as an unknown field, the
binary predates it, so leave it out.
Pick a fixed, representative slice: one table (or a matrix row with
--select), and either a full refresh or a bounded window. Note its row
count.
Run it and keep the summary:
faucet run pipeline.yaml --select orders --output json --log-format json
Rows per second = rows written / duration from the summary.
Find the side that dominates. For a long-running faucet schedule or
faucet serve, compare the source page time with the sink write and
flush time in the metrics
(Finding the problem from metrics);
for a one-shot run, compare the page and write timings in the debug-level
logs of a short run, or run the source into a throwaway local file sink
and see whether it alone takes the time.
Rule out waiting: time slept on rate limits, retries and lock waits is
not a speed problem (faucet-debug, rate-limit recipe).
Do not change anything until you know the bottleneck side.
Read every setting's name, default and range from the binary:
faucet schema source <kind>, faucet schema sink <kind>,
faucet schema execution, faucet run --help. What each kind of knob does
is in Throughput tuning
and Performance tuning.
In rough order of payoff:
| Bottleneck | Try |
|---|---|
| Either side, many small round trips | The source page size and the sink batch size; or let faucet size sink batches (Adaptive batching) |
| Sink writes | The sink's bulk or staged load path if it has one, its connection pool or concurrency, then destination-side settings (indexes, logging) |
| Source reads, one large table | Shard the table across workers (Mode B); cli/examples/postgres_to_postgres_sharded.yaml |
| Many independent tables | More matrix rows in parallel (the execution block) |
| Write mode | Upsert costs a keyed merge per page; overwrite stages and swaps; append is cheapest. Change it only when the data's semantics allow (Upsert) |
After each change, rerun the baseline (Step 1) and keep the change only if it helps. Also check memory: a larger batch holds more rows at once.
Faster must not break the systems at either end:
faucet-api skill).The engine's own benchmark harness and its method are described under Measure, don't guess.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
faucet, pipeline-tuning, throughput, batch-sizing, benchmarking
npx claudepluginhub faucet-hq/faucet-stream --plugin faucet11 skills in this plugin
/faucet-apiUse when integrating an application or service with `faucet serve` over HTTP: discovering the server's API and auth model, choosing which role's token a caller needs, registering, testing and launching templates over HTTP, rolling out a source and sink template change together, triggering template runs or raw config runs programmatically with idempotency keys, labels and an execution pool, polling a run until it is terminal and mapping its status and per-row results, finding runs by label, and decoding a 401, 403, 409, 422, 429 or 503 response from the API./faucet-connectorUse when writing a new faucet source or sink connector in Rust: scaffolding a faucet-source-* or faucet-sink-* crate (or a faucet-common-* crate shared by a pair), implementing the Source or Sink trait from faucet-core, adding a config struct with a JSON Schema, streaming pages with bounded memory and resumable bookmarks, making a sink idempotent or effectively-once (keyed upsert or atomic watermark), mapping failures to typed FaucetError variants so retries behave, passing the faucet-conformance battery, publishing the crate to crates.io, running it from a custom faucet binary, or listing it in the connector registry index./faucet-debugUse when a faucet pipeline misbehaves: a `faucet run` failed or exited non-zero, a run is slow, stuck or behind its source (CDC / stream lag), the source is rate-limited or throttled, rows are missing or duplicated, rows landed in the dead-letter queue, wrong values landed in the destination, a bookmark needs moving or resetting, stored state will not read after an upgrade, a scheduled run was skipped, a run refuses to start because another holds the row, a connector fails with an auth or permission error, or a network failure: "error sending request", connection refused or reset, timeouts, DNS or TLS handshake errors, an IP allowlist, a proxy, or a connection that works locally but not in the cluster (or the reverse). Covers `faucet doctor`, `status`, `dlq`, `state`, `verify`, `rollback`, `profiling`, `explain`, `plan`, logs and Prometheus metrics./faucet-deployUse when deploying faucet to production or running it unattended: running pipelines on cron, systemd, Airflow, Dagster or Kubernetes (Job, CronJob, Deployment), using `faucet schedule`, standing up `faucet serve` with auth, RBAC, audit and run history, installing the Helm chart or choosing and building a container image, choosing a durable state backend, wiring Prometheus, OpenTelemetry, Grafana dashboards and alerts, setting up event triggers, checking that a build has the features a deployment needs, and hardening a deployment (TLS, secrets, log levels, network binds, least privilege)./faucet-migrateUse when migrating an existing Meltano project, Singer taps and targets, or Airbyte connections to faucet: reading and converting a meltano.yml (extractors, loaders, mappers, select and metadata, jobs, schedules, environments), choosing a native faucet connector, a Template Hub template or the Singer bridge for each tap and target, running an existing Singer tap or target inside faucet, moving incremental bookmarks and Singer state into faucet state so the first run does not re-sync, running old and new pipelines side by side, comparing them with `faucet verify`, and cutting over with a rollback path./faucet-operateUse when operating a running `faucet serve` (single node or `--cluster`): `/readyz` returning 503 or a member reported unhealthy, the run-history database degraded or unreachable, runs stuck in pending or running, queued runs piling up or a full queue, runs waiting on an execution pool no member serves, a cluster member gone or crashed, a run reclaimed or executed twice after a failover, cancelling, retrying or deleting runs, finding which member owns a run, draining a member, a rolling upgrade of a cluster, and querying or pruning run history.Other plugins' skills for the same job