write-pipeline
できること
このスキルは、フロー1つではなく、共有ストレージとトリガーでつながった別々のスクリプトから、Windmillのデータパイプラインを構築する方法を説明します。データを段階的に移動し、変換する人向けです。
使う場面
- ✓Windmillで、データを複数のステップにわたって取り込み、変換し、実体化したいとき。
- ✓単一のフローではなく、データパイプラインを頼むとき。
- ✓DuckLakeのテーブルに書き込むDuckDBのスクリプトで、テーブルを作る必要があるとき。
スキルのリンク
https://github.com/windmill-labs/windmill/blob/main/system_prompts/auto-generated/skills/write-pipeline/SKILL.mdコピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。
使い方
いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。
貼り付け用メッセージ
Claude Code、Codex、Cursorの場合:プロジェクトのフォルダで実行するとスキルがインストールされます。
SKILL.mdをダウンロードして、エージェントのスキル用フォルダに入れてください。
AIへの頼み方の例
“販売のCSVを読み込んでテーブルに入れ、その後に月次の要約テーブルを作るWindmillのパイプラインを作ってください。”
毎週5つの新しいスキル。1分で読めます。
仕組み
スキルは、エージェントに小さなスクリプトを書かせます。各スクリプトには、何を読み、何を書くかを示す注記が付き、Windmillのパイプラインのビューがそれらをつなげます。
技術的な内容(元のSKILL.md)
作者による元のテキスト(英語)をGitHubからそのまま表示しています。
Data pipeline authoring
A data pipeline is NOT a flow. A flow is one runnable that orchestrates steps internally. A data pipeline is a set of independent scripts, each deployed on its own, that form a DAG by reading and writing shared storage assets (DuckLake tables, data tables, S3 objects, volumes, resources) and by declaring execution triggers. The pipeline is visualized and edited at /pipeline/<folder>; every node is a normal workspace script that happens to carry pipeline annotations. When the user asks for a "data pipeline" (or to "ingest / transform / materialize" data across steps), build pipeline-annotated scripts — do NOT build a flow.
Default to DuckDB + DuckLake
A pipeline node that produces a table should almost always be a duckdb node that materializes its output into a DuckLake table with -- materialize ducklake://<name>/<table> (in a DuckDB node the annotation uses SQL -- comment syntax; write the body as a bare SELECT and let the runtime do the write). DuckLake is the default lakehouse store for pipelines and is the shape the pipeline editor is built around, so prefer it unless the work specifically calls for something else:
postgresql/ data tables — only for row-level, OLTP-style mutations against an existing Postgres data table (frequent single-row upserts/updates, transactional reads that an app queries live).bun/python3— only for work that doesn't map to SQL: calling an external API, wrangling files, arbitrary glue. When such a node produces tabular data for downstream steps, write it straight into DuckLake (or a data table) from the same script — see "Ingesting from Python / TypeScript" below — rather than inventing a parallel store.
Do not spread a pipeline across postgres, S3, and DuckLake when one DuckLake lake would do; a consistent DuckLake lakehouse is the goal.
Ingesting from Python / TypeScript
A node that fetches data in code (an API, a SaaS export, a scraper) writes the rows directly into their DuckLake table with wmill.ducklake(), or into a data table with wmill.datatable(). DuckLake already stores every table as parquet files in the workspace object storage, so never stage the raw payload first — no intermediate JSON / CSV / parquet file in S3 and no second "load the raw file" node. One ingestion node, one table.
Pass the rows as a query argument (a list of dicts / array of objects is sent as JSON) and let SQL unnest them; declare the column types so the table gets a real schema:
# pipeline
# on schedule
import wmill
def main():
rows = fetch_charges() # list[dict]
lake = wmill.ducklake()
lake.query("""
CREATE OR REPLACE TABLE stripe_charges AS
SELECT unnest(from_json($rows, '[{"id":"VARCHAR","amount":"BIGINT","created":"BIGINT"}]'), recursive := true)
""", rows=rows).fetch()
// pipeline
// on schedule
import * as wmill from "windmill-client"
export async function main() {
const rows = await fetchCharges()
const lake = wmill.ducklake()
await lake`CREATE OR REPLACE TABLE stripe_charges AS
SELECT unnest(from_json(${rows}, '[{"id":"VARCHAR","amount":"BIGINT","created":"BIGINT"}]'), recursive := true)`.fetch()
}
- Use
INSERT INTO <table> SELECT ...instead ofCREATE OR REPLACEto append (an incremental pull), with a one-timeCREATE TABLE IF NOT EXISTSfirst. - Assign the client to a variable (
lake = wmill.ducklake()) and keep the SQL a string literal (Python) or a template withoutsql.raw(TS): that is what lets the graph record the node's write toducklake://main/<table>. A chainedwmill.ducklake().query(...)or SQL built in a variable records no output, so the downstream edge never forms. wmill.ducklake("<name>")targets a non-default catalog;wmill.datatable("<name>")writes a Postgres data table the same way (Pythondb.query(sql, *args)with$1placeholders, TS the same template form) — use it only when the data belongs in Postgres (see above).- The downstream node triggers on the table itself:
-- on ducklake://main/stripe_charges.
Storage prerequisites
A DuckLake pipeline only runs once the workspace has object storage (S3 / Azure Blob / GCS) and a DuckLake catalog configured — DuckLake tables and s3:// assets can't be materialized or read without it. Check which DuckLake catalogs the workspace has before you build.
wmill ducklake list lists them.
Drafting the annotated scripts does not
よくある質問
データパイプラインはフローと同じですか?
いいえ。パイプラインは共有テーブルでつながった別々のスクリプトの集まりですが、フローはステップを1つのランナブルの中で実行します。
DuckLakeとは何ですか?
スキルがパイプラインの出力に既定で使うレイクハウスのテーブルストアです。
パイプラインはどこで見られますか?
スクリプトを入れたフォルダーのパイプラインエディターで、Windmillが表示します。
詳細
作者による元の説明
MUST use when creating or modifying a data pipeline, a set of scripts marked `pipeline` and wired together by `on` / `materialize` annotations.
repo: windmill-labs/windmill
人気
- GitHubのスター
- 18k
- ランキング
- #10632
- ライセンス
- —
- 更新日
- 2026/11/2
コメント
- …
このリポジトリの他のスキル
commit
18kエージェントが、変更されたファイルだけをステージして、短い1行のgitコミットメッセージを、慣例的な形式で書くよう支援します。
pr
18kエージェントが、明確なタイトルと説明を付けて、GitHubで下書きのプルリクエストを開き、レビューのラウンドに従うよう支援します。
agents
18kエージェントが、独自のモデル、システムプロンプト、ツール、メモリを持つ、再利用可能なWindmillのAIエージェントを構築するよう支援します。
cli-commands
18kエージェントが、Windmillのコマンドラインツールを実行して、スクリプト、フロー、アプリ、ジョブの履歴を管理するよう支援します。
似ているスキル
discrawl
394k保存済みのローカルなDiscordメッセージのアーカイブを検索して要約し、その新しさを確認し、ダイレクトメッセージを読めるようエージェントを支援します。
clickhouse-io
280kエージェントがClickHouseデータベースのクエリとスキーマを最適化できるようにします。高性能な分析処理向けのベストプラクティスを適用します。分析クエリが遅すぎるときに使います。
scientific-db-pubmed-database
280kエージェントが生物医学分野の科学論文を検索するのに役立ちます。特定の医療情報が必要な研究に便利です。