Categorize Airtable invoices with OpenAI and TOON token optimization — n8n ワークフロー
概要
> ⚠️ Notice:
> This workflow uses the CustomJS JSON to TOON node from CustomJS, which requires a self-hosted n8n instance and a CustomJS API key.
This workflow demonstrates how to automatically categorize invoices from Airtable using OpenAI, while significantly reducing token usage by converting structured data into TOON (Token-Optimized Object Notation) before sending it to the LLM.
Instead of passing large, nested JSON payloads (clients, invoices, invoice items) directly to OpenAI,
使用ノード
ワークフロープレビュー
仕組み
- 1
トリガー
このワークフローは トリガー トリガーで開始します。
- 2
処理
データは 12 個のノードを流れます, connecting @custom-js/n8n-nodes-pdf-toolkit.jsontotoon, @custom-js/n8n-nodes-pdf-toolkit.toontojson, aggregate。
- 3
出力
ワークフローは自動化を完了し、設定された宛先に結果を配信します。
ノード詳細 (12)
Airtable
airtable
OpenAI
n8n-nodes-langchain.openAi
このワークフローのインポート方法
- 1右側の JSONをダウンロード ボタンをクリックしてワークフローファイルを保存します。
- 2n8nインスタンスを開き、ワークフロー → 新規 → ファイルからインポート に進みます。
- 3ダウンロードした
categorize-airtable-invoices-with-openai-and-toon-token-optimizationファイルを選択し、インポートをクリックします。 - 4各サービスノードの 認証情報(APIキー、OAuthなど)を設定します。
- 5ワークフローをテスト をクリックして動作確認し、有効化します。
またはn8nの JSONからインポート に直接貼り付け:
インテグレーション
作成者
CustomJS
@customjs