@inductiv/node-red-openai-api
Version:
Enhance your Node-RED projects with advanced AI capabilities.
88 lines (77 loc) • 3.34 kB
HTML
<section>
<details>
<summary style="font-weight: bold;">📦 Batch</summary>
<a href="https://developers.openai.com/api/reference/typescript/resources/batches/" target="_blank">Official Documentation
<i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
<h4 style="font-weight: bolder;"> ⋙ Create Batch</h4>
<p>Creates and executes a batch from an uploaded file of requests.</p>
<dl class="message-properties">
<h4>msg.payload Properties</h4>
<dt>
input_file_id
<span class="property-type">string</span>
</dt>
<dd>The ID of an uploaded file that contains requests for the new batch.</dd>
<dt>
endpoint
<span class="property-type">string</span>
</dt>
<dd>The endpoint to be used for all requests in the batch. Supported values include
<code>/v1/responses</code>, <code>/v1/chat/completions</code>, <code>/v1/embeddings</code>,
<code>/v1/completions</code>, <code>/v1/moderations</code>,
<code>/v1/images/generations</code>, <code>/v1/images/edits</code>, and
<code>/v1/videos</code>.
</dd>
<dt>
completion_window
<span class="property-type">string</span>
</dt>
<dd>
The time frame within which the batch should be processed. Currently only 24h is supported.
</dd>
<dt class="optional">
metadata
<span class="property-type">string</span>
</dt>
<dd>
Optional custom metadata for the batch.
</dd>
</dl>
<h4 style="font-weight: bolder;"> ⋙ Retrieve Batch</h4>
<p>Retrieves a batch.</p>
<dl class="message-properties">
<h4>msg.payload Properties</h4>
<dt>
batch_id
<span class="property-type">string</span>
</dt>
<dd>The ID of the batch to retrieve.</dd>
</dl>
<h4 style="font-weight: bolder;"> ⋙ Cancel Batch</h4>
<p>Cancels an in-progress batch.</p>
<dl class="message-properties">
<h4>msg.payload Properties</h4>
<dt>
batch_id
<span class="property-type">string</span>
</dt>
<dd>The ID of the batch to cancel.</dd>
</dl>
<h4 style="font-weight: bolder;"> ⋙ List Batch</h4>
<p>List your organization's batches.</p>
<dl class="message-properties">
<h4>msg.payload Properties</h4>
<dt class="optional">
after
<span class="property-type">string</span>
</dt>
<dd>A cursor for use in pagination. after is an object ID that defines your place in the list.</dd>
<dt class="optional">
limit
<span class="property-type">integer</span>
</dt>
<dd>A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is
20.</dd>
</dl>
</details>
</section>