From fc475844193e645ac5e5cc732c48281b862bef00 Mon Sep 17 00:00:00 2001 From: "Chang, Hui-Tang" Date: Fri, 3 Jan 2025 15:11:32 +0800 Subject: [PATCH] refactor(component): rename Instill Format to Instill Type (#951) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Because - we’d like to simplify the component definition structure This commit - renames Instill Format to Instill Type - removes outdated `instillAcceptFormats` and `instillUpstreamTypes` --- pkg/component/CONTRIBUTING.md | 169 +- .../ai/anthropic/v0/.compogen/bottom.mdx | 4 +- pkg/component/ai/anthropic/v0/README.mdx | 22 +- .../ai/anthropic/v0/config/setup.json | 19 - .../ai/anthropic/v0/config/setup.yaml | 6 +- .../ai/anthropic/v0/config/tasks.yaml | 68 +- pkg/component/ai/cohere/v0/README.mdx | 28 +- pkg/component/ai/cohere/v0/config/setup.yaml | 6 +- pkg/component/ai/cohere/v0/config/tasks.yaml | 166 +- .../ai/fireworksai/v0/.compogen/bottom.mdx | 2 +- pkg/component/ai/fireworksai/v0/README.mdx | 22 +- .../ai/fireworksai/v0/config/setup.yaml | 6 +- .../ai/fireworksai/v0/config/tasks.yaml | 91 +- pkg/component/ai/groq/v0/.compogen/bottom.mdx | 2 +- pkg/component/ai/groq/v0/README.mdx | 20 +- pkg/component/ai/groq/v0/config/setup.yaml | 6 +- pkg/component/ai/groq/v0/config/tasks.yaml | 77 +- pkg/component/ai/huggingface/v0/README.mdx | 128 +- .../ai/huggingface/v0/config/setup.yaml | 14 +- .../ai/huggingface/v0/config/tasks.yaml | 467 ++-- pkg/component/ai/instill/v0/README.mdx | 112 +- pkg/component/ai/instill/v0/config/tasks.yaml | 222 +- .../ai/mistralai/v0/.compogen/bottom.mdx | 20 +- pkg/component/ai/mistralai/v0/README.mdx | 44 +- .../ai/mistralai/v0/config/setup.yaml | 6 +- .../ai/mistralai/v0/config/tasks.yaml | 97 +- pkg/component/ai/ollama/v0/README.mdx | 20 +- pkg/component/ai/ollama/v0/config/setup.yaml | 10 +- pkg/component/ai/ollama/v0/config/tasks.yaml | 78 +- .../ai/openai/v0/.compogen/bottom.mdx | 10 +- pkg/component/ai/openai/v0/README.mdx | 60 +- pkg/component/ai/openai/v0/config/setup.yaml | 10 +- pkg/component/ai/openai/v0/config/tasks.json | 783 ------- pkg/component/ai/openai/v0/config/tasks.yaml | 258 +-- .../ai/perplexity/v0/.compogen/bottom.mdx | 2 +- pkg/component/ai/perplexity/v0/README.mdx | 26 +- .../ai/perplexity/v0/config/setup.yaml | 6 +- .../ai/perplexity/v0/config/tasks.yaml | 104 +- pkg/component/ai/stabilityai/v0/README.mdx | 24 +- .../ai/stabilityai/v0/config/setup.yaml | 6 +- .../ai/stabilityai/v0/config/stabilityai.yaml | 1939 ----------------- .../ai/stabilityai/v0/config/tasks.yaml | 165 +- pkg/component/ai/stabilityai/v0/main.go | 8 +- .../ai/universalai/v0/.compogen/bottom.mdx | 2 +- pkg/component/ai/universalai/v0/README.mdx | 24 +- .../ai/universalai/v0/config/setup.yaml | 14 +- .../ai/universalai/v0/config/tasks.yaml | 106 +- pkg/component/application/asana/v0/README.mdx | 78 +- .../application/asana/v0/config/setup.yaml | 6 +- .../application/asana/v0/config/tasks.yaml | 614 ++---- pkg/component/application/email/v0/README.mdx | 14 +- .../application/email/v0/config/setup.yaml | 18 +- .../application/email/v0/config/tasks.yaml | 82 +- .../application/freshdesk/v0/README.mdx | 68 +- .../freshdesk/v0/config/setup.yaml | 10 +- .../freshdesk/v0/config/tasks.yaml | 772 +++---- .../github/v0/.compogen/bottom.mdx | 12 +- .../application/github/v0/README.mdx | 217 +- .../application/github/v0/config/events.yaml | 368 ++-- .../application/github/v0/config/setup.yaml | 6 +- .../application/github/v0/config/tasks.yaml | 1027 +++++---- .../application/googlesearch/v0/README.mdx | 8 +- .../googlesearch/v0/config/setup.yaml | 6 +- .../googlesearch/v0/config/tasks.yaml | 44 +- .../application/hubspot/v0/README.mdx | 70 +- .../application/hubspot/v0/config/setup.yaml | 6 +- .../application/hubspot/v0/config/tasks.yaml | 575 ++--- .../application/jira/v0/.compogen/bottom.mdx | 6 +- pkg/component/application/jira/v0/README.mdx | 78 +- .../application/jira/v0/config/setup.yaml | 14 +- .../application/jira/v0/config/tasks.yaml | 332 ++- .../leadiq/v0/.compogen/bottom.mdx | 10 +- .../application/leadiq/v0/README.mdx | 26 +- .../application/leadiq/v0/config/setup.yaml | 6 +- .../application/leadiq/v0/config/tasks.yaml | 100 +- .../application/numbers/v0/README.mdx | 8 +- .../application/numbers/v0/config/setup.yaml | 6 +- .../application/numbers/v0/config/tasks.yaml | 48 +- .../application/slack/v0/.compogen/bottom.mdx | 6 +- pkg/component/application/slack/v0/README.mdx | 20 +- .../application/slack/v0/config/events.yaml | 30 +- .../application/slack/v0/config/setup.yaml | 10 +- .../application/slack/v0/config/tasks.yaml | 52 +- .../smartlead/v0/.compogen/bottom.mdx | 96 +- .../application/smartlead/v0/README.mdx | 144 +- .../smartlead/v0/config/setup.yaml | 6 +- .../smartlead/v0/config/tasks.yaml | 278 +-- .../application/whatsapp/v0/README.mdx | 38 +- .../application/whatsapp/v0/config/setup.yaml | 6 +- .../application/whatsapp/v0/config/tasks.yaml | 170 +- pkg/component/base/component.go | 86 +- pkg/component/base/migrate.go | 40 +- .../base/testdata/componentTasks.json | 49 - .../base/testdata/componentTasks.yaml | 7 +- .../base/testdata/operatorTasks.yaml | 11 - .../testdata/wantComponentDefinition.yaml | 44 +- .../base/testdata/wantOperatorDefinition.yaml | 21 - pkg/component/data/bigquery/v0/README.mdx | 10 +- .../data/bigquery/v0/config/setup.yaml | 18 +- .../data/bigquery/v0/config/tasks.yaml | 18 +- pkg/component/data/bigquery/v0/main.go | 6 +- pkg/component/data/chroma/v0/README.mdx | 28 +- .../data/chroma/v0/config/setup.yaml | 10 +- .../data/chroma/v0/config/tasks.yaml | 195 +- .../data/elasticsearch/v0/README.mdx | 38 +- .../data/elasticsearch/v0/config/setup.yaml | 10 +- .../data/elasticsearch/v0/config/tasks.yaml | 251 +-- .../data/googlecloudstorage/v0/README.mdx | 34 +- .../googlecloudstorage/v0/config/setup.yaml | 6 +- .../googlecloudstorage/v0/config/tasks.yaml | 136 +- pkg/component/data/googledrive/v0/README.mdx | 14 +- .../data/googledrive/v0/config/setup.yaml | 6 +- .../data/googledrive/v0/config/tasks.yaml | 38 +- pkg/component/data/googlesheets/v0/README.mdx | 88 +- .../data/googlesheets/v0/config/setup.yaml | 6 +- .../data/googlesheets/v0/config/tasks.yaml | 112 +- .../instillartifact/v0/.compogen/bottom.mdx | 12 +- .../data/instillartifact/v0/README.mdx | 64 +- .../data/instillartifact/v0/config/tasks.yaml | 292 +-- pkg/component/data/milvus/v0/README.mdx | 44 +- .../data/milvus/v0/config/setup.yaml | 14 +- .../data/milvus/v0/config/tasks.yaml | 242 +- pkg/component/data/mongodb/v0/README.mdx | 46 +- .../data/mongodb/v0/config/setup.yaml | 6 +- .../data/mongodb/v0/config/tasks.yaml | 291 +-- pkg/component/data/pinecone/v0/README.mdx | 22 +- .../data/pinecone/v0/config/setup.yaml | 10 +- .../data/pinecone/v0/config/tasks.yaml | 134 +- pkg/component/data/qdrant/v0/README.mdx | 28 +- .../data/qdrant/v0/config/setup.yaml | 10 +- .../data/qdrant/v0/config/tasks.yaml | 179 +- pkg/component/data/redis/v0/README.mdx | 20 +- pkg/component/data/redis/v0/config/setup.yaml | 22 +- pkg/component/data/redis/v0/config/tasks.yaml | 56 +- pkg/component/data/sql/v0/README.mdx | 36 +- pkg/component/data/sql/v0/config/setup.yaml | 50 +- pkg/component/data/sql/v0/config/tasks.yaml | 124 +- pkg/component/data/weaviate/v0/README.mdx | 28 +- .../data/weaviate/v0/config/setup.yaml | 10 +- .../data/weaviate/v0/config/tasks.yaml | 173 +- pkg/component/data/zilliz/v0/README.mdx | 36 +- .../data/zilliz/v0/config/setup.yaml | 10 +- .../data/zilliz/v0/config/tasks.yaml | 211 +- .../generic/collection/v0/README.mdx | 32 +- .../generic/collection/v0/config/tasks.yaml | 108 +- pkg/component/generic/http/v0/README.mdx | 38 +- .../generic/http/v0/config/setup.yaml | 36 +- .../generic/http/v0/config/tasks.yaml | 31 +- .../generic/scheduler/v0/config/events.yaml | 8 +- .../operator/audio/v0/.compogen/bottom.mdx | 2 +- pkg/component/operator/audio/v0/README.mdx | 14 +- .../operator/audio/v0/config/tasks.yaml | 42 +- pkg/component/operator/base64/v0/README.mdx | 8 +- .../operator/base64/v0/config/tasks.yaml | 20 +- .../operator/document/v0/.compogen/bottom.mdx | 4 +- pkg/component/operator/document/v0/README.mdx | 16 +- .../operator/document/v0/config/tasks.yaml | 78 +- pkg/component/operator/image/v0/README.mdx | 56 +- .../operator/image/v0/config/schema.yaml | 100 +- .../operator/image/v0/config/tasks.yaml | 180 +- .../operator/json/v0/.compogen/bottom.mdx | 4 +- pkg/component/operator/json/v0/README.mdx | 28 +- .../operator/json/v0/config/tasks.yaml | 69 +- pkg/component/operator/text/v0/README.mdx | 14 +- .../operator/text/v0/config/tasks.yaml | 80 +- pkg/component/operator/video/v0/README.mdx | 26 +- .../operator/video/v0/config/tasks.yaml | 99 +- .../operator/web/v0/.compogen/bottom.mdx | 2 +- pkg/component/operator/web/v0/README.mdx | 22 +- .../operator/web/v0/config/tasks.yaml | 124 +- pkg/component/resources/schemas/schema.yaml | 100 +- .../cmd/testdata/readme-component1.txt | 81 +- .../cmd/testdata/readme-component2.txt | 32 +- .../tools/compogen/pkg/gen/readme.go | 54 +- .../gen/resources/templates/readme.mdx.tmpl | 28 +- .../tools/compogen/pkg/gen/schema.go | 6 +- .../tools/compogen/pkg/gen/schema_test.go | 14 +- 177 files changed, 5501 insertions(+), 10477 deletions(-) delete mode 100644 pkg/component/ai/anthropic/v0/config/setup.json delete mode 100644 pkg/component/ai/openai/v0/config/tasks.json delete mode 100644 pkg/component/ai/stabilityai/v0/config/stabilityai.yaml delete mode 100644 pkg/component/base/testdata/componentTasks.json diff --git a/pkg/component/CONTRIBUTING.md b/pkg/component/CONTRIBUTING.md index 651ddffd6..5c264abd3 100644 --- a/pkg/component/CONTRIBUTING.md +++ b/pkg/component/CONTRIBUTING.md @@ -54,8 +54,8 @@ operator/hello/v0 ├──assets │ └──hello.svg ├──config - │ ├──definition.json - │ └──tasks.json + │ ├──definition.yaml + │ └──tasks.yaml ├──main.go ├──main_test.go └──README.mdx @@ -63,33 +63,30 @@ operator/hello/v0 ### Add the configuration files -Create a `config` directory and add the files `definition.json`, `tasks.json`, -and `setup.json` (optional). Together, these files define the behavior of the +Create a `config` directory and add the files `definition.yaml`, `tasks.yaml`, +and `setup.yaml` (optional). Together, these files define the behavior of the component. -#### `definition.json` +#### `definition.yaml` -The `definition.json` file describes the high-level information of the +The `definition.yaml` file describes the high-level information of the component. -```json -{ - "id": "hello", - "uid": "e05d3d71-779c-45f8-904d-e90a050ca3b2", - "title": "Hello", - "type": "COMPONENT_TYPE_OPERATOR", - "description": "'Hello, world' operator used as a template for adding components", - "spec": {}, - "availableTasks": [ - "TASK_GREET" - ], - "documentationUrl": "https://www.instill.tech/docs/component/operator/hello", - "icon": "assets/hello.svg", - "version": "0.1.0", - "sourceUrl": "https://github.com/instill-ai/pipeline-backend/pkg/component/blob/main/operator/hello/v0", - "releaseStage": "RELEASE_STAGE_ALPHA", - "public": true -} +```yaml +id: hello +uid: e05d3d71-779c-45f8-904d-e90a050ca3b2 +title: Hello +type: COMPONENT_TYPE_OPERATOR +description: "'Hello, world' operator used as a template for adding components" +spec: {} +availableTasks: + - TASK_GREET +documentationUrl: https://www.instill.tech/docs/component/operator/hello +icon: assets/hello.svg +version: 0.1.0 +sourceUrl: https://github.com/instill-ai/pipeline-backend/pkg/component/blob/main/operator/hello/v0 +releaseStage: RELEASE_STAGE_ALPHA +public: true ``` This file defines the component properties: @@ -106,7 +103,7 @@ This file defines the component properties: - **`availableTasks`** defines the tasks the component can perform. - When a component is created in a pipeline, one of the tasks has to be selected, i.e., a configured component can only execute one task. - - Task configurations are defined in `tasks.json`. + - Task configurations are defined in `tasks.yaml`. - **`documentationUrl`** points to the official documentation of the component. - **`icon`** is the local path to the icon that will be displayed in the console when creating the component. If left blank, a placeholder icon will be shown. @@ -124,57 +121,42 @@ This file defines the component properties: - **`public`** indicates whether the component is visible to the public. -#### `tasks.json` +#### `tasks.yaml` -The `tasks.json` file describes the task details of the component. The key +The `tasks.yaml` file describes the task details of the component. The key should be in the format `TASK_NAME`. -```json -{ - "TASK_GREET": { - "shortDescription": "Greet someone / something", - "title": "Greet", - "input": { - "description": "Input", - "uiOrder": 0, - "properties": { - "target": { - "uiOrder": 0, - "description": "The target of the greeting", - "acceptFormats": [ - "string" - ], - "title": "Greeting target", - "format": "string" - } - }, - "required": [ - "target" - ], - "title": "Input", - "type": "object" - }, - "output": { - "description": "The greeting sentence", - "uiOrder": 0, - "properties": { - "greeting": { - "description": "A greeting sentence addressed to the target", - "uiOrder": 0, - "required": [], - "title": "Greeting", - "type": "string", - "format": "string" - } - }, - "required": [ - "greeting" - ], - "title": "Output", - "type": "object" - } - } -} +```yaml +TASK_GREET: + shortDescription: Greet someone / something + title: Greet + input: + description: Input + uiOrder: 0 + properties: + target: + uiOrder: 0 + description: The target of the greeting + type: string + title: Greeting target + required: + - target + title: Input + type: object + output: + description: The greeting sentence + uiOrder: 0 + properties: + greeting: + description: A greeting sentence addressed to the target + uiOrder: 0 + required: [] + title: Greeting + type: string + required: + - greeting + title: Output + type: object ``` This file defines the input and output schema of each task: @@ -187,13 +169,13 @@ This file defines the input and output schema of each task: provide a description of the task in the component. If **`shortDescription`** does not exist, it will be the same as **`description`**. -- **`input`** is a JSON Schema that describes the input of the task. -- **`output`** is a JSON Schema that describes the output of the task. +- **`input`** is a schema that describes the input of the task. +- **`output`** is a schema that describes the output of the task. **Properties within `input` and `output` Objects** - **`required`** indicates whether the property is required. -- **`format`**: describes the format of this field, which could be `string`, +- **`type`**: describes the format of this field, which could be `string`, `number`, `boolean`, `file`, `document`, `image`, `video`, `audio`, `array`, or `object`. - **`title`** is used by the console to provide the title of the property in the component. @@ -207,16 +189,17 @@ This file defines the input and output schema of each task: **Properties within `input` Objects** -- **`acceptFormats`** is an array indicating the data types of acceptable - input fields. It should be an array of [**Instill - Format**](https://www.instill.tech/docs/vdp/instill-format). - - Currently, we do not support the `time` type. When the input is a `date` or `datetime`, it should be represented as a string. The `date` or `datetime` will be automatically parsed in UTC timezone by the YAML parser. Please ensure this point is noted in the documentation, specifically for the `start-to-read-date` in the Slack component. +- **`type`** indicates the data type of the output field, which should be one + of `string`, `number`, `boolean`, `file`, `document`, `image`, `video`, + `audio`, `array`, or `object`. Please refer to [**Instill + Format**](https://www.instill.tech/docs/vdp/instill-format) for more details. + - **`instillSecret`** indicates the data must reference the secrets and cannot be used in plaintext. **Properties within `output` Objects** -- **`format`** indicates the data type of the output field, which should be one +- **`type`** indicates the data type of the output field, which should be one of `string`, `number`, `boolean`, `file`, `document`, `image`, `video`, `audio`, `array`, or `object`. Please refer to [**Instill Format**](https://www.instill.tech/docs/vdp/instill-format) for more details. @@ -224,12 +207,12 @@ This file defines the input and output schema of each task: See the [example recipe](#example-recipe) to understand how these fields map to the recipe of a pipeline when configured to use this operator. -#### `setup.json` +#### `setup.yaml` For components that need to set up some configuration before execution (typically, components that connect with 3rd party applications or services that -need to set up a connection), `setup.json` can be used to describe these -configurations. The format is the same as the `input` objects in `tasks.json`. +need to set up a connection), `setup.yaml` can be used to describe these +configurations. The format is the same as the `input` objects in `tasks.yaml`. The setup of a component can be defined within the recipe as key-value fields, or as a reference to a **Connection** (see the @@ -237,7 +220,7 @@ or as a reference to a **Connection** (see the information). Certain components support OAuth 2.0 integrations. If you want your component to support this sort of connection: -- In `setup.json`, add the OAuth information under the `instillOAuthConfig` +- In `setup.yaml`, add the OAuth information under the `instillOAuthConfig` property. - `authUrl` contains the address where the authorization code can be requested. @@ -289,10 +272,10 @@ const ( ) var ( - //go:embed config/definition.json - definitionJSON []byte - //go:embed config/tasks.json - tasksJSON []byte + //go:embed config/definition.yaml + definitionYAML []byte + //go:embed config/tasks.yaml + tasksYAML []byte once sync.Once comp *component @@ -307,7 +290,7 @@ type component struct { func Init(bc base.Component) *component { once.Do(func() { comp = &component{Component: bc} - err := comp.LoadDefinition(definitionJSON, nil, tasksJSON, nil) + err := comp.LoadDefinition(definitionYAML, nil, tasksYAML, nil) if err != nil { panic(err) } @@ -619,8 +602,8 @@ output: Documentation helps user to integrate the component in their pipelines. A good component definition will have clear names for their fields, which will also -contain useful descriptions. The information described in `definition.json` and -`tasks.json` is enough to understand how a component should be used. `compogen` +contain useful descriptions. The information described in `definition.yaml` and +`tasks.yaml` is enough to understand how a component should be used. `compogen` is a tool that parses the component configuration and builds a `README.mdx` file document displaying its information in a human-readable way. To generate the document, just add the following line on top of `operator/hello/v0/main.go`: @@ -673,7 +656,7 @@ Semantic Versioning guidelines. It is recommended to start a component at `v0.1.0`. A major version 0 is intended for rapid development. -The `releaseStage` property in `definition.json` indicates the stability of a +The `releaseStage` property in `definition.yaml` indicates the stability of a component. - A component skeleton (with only the minimal configuration files and a dummy diff --git a/pkg/component/ai/anthropic/v0/.compogen/bottom.mdx b/pkg/component/ai/anthropic/v0/.compogen/bottom.mdx index cf17697bc..b51ded476 100644 --- a/pkg/component/ai/anthropic/v0/.compogen/bottom.mdx +++ b/pkg/component/ai/anthropic/v0/.compogen/bottom.mdx @@ -34,11 +34,11 @@ variable: repository-name: title: Repository Name description: Name of the repository i.e. instill-core - format: string + type: string repository-owner: title: Repository Owner description: Name of the repository owner i.e. instill-ai - format: string + type: string output: result: title: Result diff --git a/pkg/component/ai/anthropic/v0/README.mdx b/pkg/component/ai/anthropic/v0/README.mdx index 69ced0e4a..150b06a8c 100644 --- a/pkg/component/ai/anthropic/v0/README.mdx +++ b/pkg/component/ai/anthropic/v0/README.mdx @@ -36,7 +36,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key | `api-key` | string | Fill in your Anthropic API key. To find your keys, visit the Anthropic console page. | @@ -54,14 +54,14 @@ Anthropic's text generation models (often called generative pre-trained transfor
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_GENERATION_CHAT` | | Model Name (required) | `model-name` | string | The Anthropic model to be used.
Enum values
  • `claude-3-5-sonnet-latest`
  • `claude-3-5-sonnet-20241022`
  • `claude-3-5-sonnet-20240620`
  • `claude-3-opus-20240229`
  • `claude-3-sonnet-20240229`
  • `claude-3-haiku-20240307`
| | Prompt (required) | `prompt` | string | The prompt text. | | System Message | `system-message` | string | The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is set using a generic message as "You are a helpful assistant.". | | Prompt Images | `prompt-images` | array[string] | The prompt images (Note: The prompt images will be injected in the order they are provided to the 'prompt' message. Anthropic doesn't support sending images via image-url, use this field instead). | -| [Chat History](#text-generation-chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | +| [Chat History](#text-generation-chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | | Seed | `seed` | integer | The seed (Note: Not supported by Anthropic Models). | | Temperature | `temperature` | number | The temperature for sampling. | | Top K | `top-k` | integer | Top k for sampling. | @@ -74,11 +74,11 @@ Anthropic's text generation models (often called generative pre-trained transfor

Chat History

-Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. +Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#text-generation-chat-content) | `content` | array | The message content. | | Role | `role` | string | The message role, i.e. 'system', 'user' or 'assistant'. | @@ -89,7 +89,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#text-generation-chat-image-url) | `image-url` | object | The image URL. | | Text | `text` | string | The text content. | @@ -101,7 +101,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
@@ -111,7 +111,7 @@ The image URL.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Model Output. | | [Usage](#text-generation-chat-usage) (optional) | `usage` | object | Usage tokens in Anthropic. | @@ -124,7 +124,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Input Tokens | `input-tokens` | number | The input tokens used by Anthropic. | | Output Tokens | `output-tokens` | number | The output tokens used by Anthropic. | @@ -169,11 +169,11 @@ variable: repository-name: title: Repository Name description: Name of the repository i.e. instill-core - format: string + type: string repository-owner: title: Repository Owner description: Name of the repository owner i.e. instill-ai - format: string + type: string output: result: title: Result diff --git a/pkg/component/ai/anthropic/v0/config/setup.json b/pkg/component/ai/anthropic/v0/config/setup.json deleted file mode 100644 index a0dbdbbf6..000000000 --- a/pkg/component/ai/anthropic/v0/config/setup.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "additionalProperties": false, - "properties": { - "api-key": { - "description": "Fill in your Anthropic API key. To find your keys, visit the Anthropic console page.", - "acceptFormats": [ - "string" - ], - "instillSecret": true, - "instillCredential": true, - "uiOrder": 0, - "title": "API Key", - "format": "string" - } - }, - "required": [], - "title": "Anthropic Connection", - "format": "object" -} diff --git a/pkg/component/ai/anthropic/v0/config/setup.yaml b/pkg/component/ai/anthropic/v0/config/setup.yaml index 85e291856..1925c4877 100644 --- a/pkg/component/ai/anthropic/v0/config/setup.yaml +++ b/pkg/component/ai/anthropic/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: api-key: description: Fill in your Anthropic API key. To find your keys, visit the Anthropic console page. - acceptFormats: - - string + type: string instillSecret: true instillCredential: true uiOrder: 0 title: API Key - format: string required: [] title: Anthropic Connection -format: object +type: object diff --git a/pkg/component/ai/anthropic/v0/config/tasks.yaml b/pkg/component/ai/anthropic/v0/config/tasks.yaml index ac6b34947..e773370d6 100644 --- a/pkg/component/ai/anthropic/v0/config/tasks.yaml +++ b/pkg/component/ai/anthropic/v0/config/tasks.yaml @@ -8,18 +8,18 @@ $defs: description: Either a URL of the image or the base64 encoded image data. title: URL uiOrder: 0 - format: string + type: string required: - url title: Image URL description: The image URL. uiOrder: 0 - format: object + type: object text: description: The text content. title: Text uiOrder: 1 - format: string + type: string type: description: The type of the content part. enum: @@ -27,11 +27,11 @@ $defs: - image_url title: Type uiOrder: 2 - format: string + type: string required: - type - format: object - format: array + type: object + type: array chat-message: properties: content: @@ -43,12 +43,12 @@ $defs: description: The message role, i.e. 'system', 'user' or 'assistant'. uiOrder: 0 title: Role - format: string + type: string required: - role - content title: Chat Message - format: object + type: object usage: description: Usage tokens in Anthropic. uiOrder: 1 @@ -57,17 +57,17 @@ $defs: description: The input tokens used by Anthropic. uiOrder: 2 title: Input Tokens - format: number + type: number output-tokens: description: The output tokens used by Anthropic. uiOrder: 3 title: Output Tokens - format: number + type: number required: - input-tokens - output-tokens title: Usage - format: object + type: object TASK_TEXT_GENERATION_CHAT: shortDescription: Provide text outputs in response to text inputs. description: Anthropic's text generation models (often called generative pre-trained transformers or large language models) have been trained to understand @@ -80,25 +80,21 @@ TASK_TEXT_GENERATION_CHAT: properties: chat-history: description: 'Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be - ignored and will not have any effect when this field is populated. Each message should adhere to the format: : {"role": "The message role, i.e. + ignored and will not have any effect when this field is populated. Each message should adhere to the format: {"role": "The message role, i.e. ''system'', ''user'' or ''assistant''", "content": "message content"}.' - acceptFormats: - - object + type: array shortDescription: 'Incorporate external chat history, specifically previous messages within the conversation. (Note: Anthropic doesn''t support sending images via image-url, use the ''prompt-images'' field instead)' uiOrder: 4 items: $ref: '#/$defs/chat-message' title: Chat history - format: array max-new-tokens: default: 50 description: The maximum number of tokens for model to generate. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Max New Tokens - format: integer model-name: enum: - claude-3-5-sonnet-latest @@ -109,8 +105,7 @@ TASK_TEXT_GENERATION_CHAT: - claude-3-haiku-20240307 example: claude-3-5-sonnet-latest description: The Anthropic model to be used. - acceptFormats: - - string + type: string uiOrder: 0 instillCredentialMap: values: @@ -123,63 +118,50 @@ TASK_TEXT_GENERATION_CHAT: targets: - setup.api-key title: Model Name - format: string prompt: description: The prompt text. - acceptFormats: - - string + type: string uiOrder: 2 title: Prompt - format: string prompt-images: description: 'The prompt images (Note: The prompt images will be injected in the order they are provided to the ''prompt'' message. Anthropic doesn''t support sending images via image-url, use this field instead).' - acceptFormats: - - array + type: array uiOrder: 3 items: - format: string + type: string title: Prompt Images - format: array seed: description: 'The seed (Note: Not supported by Anthropic Models).' - acceptFormats: - - integer + type: integer uiOrder: 4 title: Seed - format: integer system-message: default: You are a helpful assistant. description: The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is set using a generic message as "You are a helpful assistant.". - acceptFormats: - - string + type: string shortDescription: The system message helps set the behavior of the assistant uiOrder: 2 title: System Message - format: string temperature: default: 0.7 description: The temperature for sampling. - acceptFormats: - - number + type: number uiOrder: 5 title: Temperature - format: number top-k: default: 10 description: Top k for sampling. - acceptFormats: - - integer + type: integer uiOrder: 5 title: Top K - format: integer required: - prompt - model-name title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -188,10 +170,10 @@ TASK_TEXT_GENERATION_CHAT: description: Model Output. uiOrder: 0 title: Text - format: string + type: string usage: $ref: '#/$defs/usage' required: - text title: Output - format: object + type: object diff --git a/pkg/component/ai/cohere/v0/README.mdx b/pkg/component/ai/cohere/v0/README.mdx index 2142e3c88..f9710cdd0 100644 --- a/pkg/component/ai/cohere/v0/README.mdx +++ b/pkg/component/ai/cohere/v0/README.mdx @@ -38,7 +38,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key | `api-key` | string | Fill in your Cohere API key. To find your keys, visit the Cohere dashboard page. | @@ -56,7 +56,7 @@ Cohere's text generation models (often called generative pre-trained transformer
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_GENERATION_CHAT` | | Model Name (required) | `model-name` | string | The Cohere command model to be used.
Enum values
  • `command-r-plus`
  • `command-r`
  • `command`
  • `command-nightly`
  • `command-light`
  • `command-light-nightly`
| @@ -81,7 +81,7 @@ Incorporate external chat history, specifically previous messages within the con
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#text-generation-chat-content) | `content` | array | The message content. | | Role | `role` | string | The message role, i.e. 'system', 'user' or 'assistant'. | @@ -92,7 +92,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#text-generation-chat-image-url) | `image-url` | object | The image URL. | | Text | `text` | string | The text content. | @@ -104,7 +104,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
@@ -114,7 +114,7 @@ The image URL.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Model Output. | | [Citations](#text-generation-chat-citations) (optional) | `citations` | array[object] | Citations. | @@ -128,7 +128,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | End | `end` | integer | The end position of the citation. | | Start | `start` | integer | The start position of the citation. | @@ -139,7 +139,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Input Tokens | `input-tokens` | number | The input tokens used by Cohere Models. | | Output Tokens | `output-tokens` | number | The output tokens generated by Cohere Models. | @@ -153,7 +153,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_EMBEDDINGS` | | Embedding Type (required) | `embedding-type` | string | Specifies the return type of embedding, Note that 'binary'/'ubinary' options means the component will return packed unsigned binary embeddings. The length of each binary embedding is 1/8 the length of the float embeddings of the provided model.
Enum values
  • `float`
  • `int8`
  • `uint8`
  • `binary`
  • `ubinary`
| @@ -169,7 +169,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Embedding | `embedding` | array[number] | Embedding of the input text. | | [Usage](#text-embeddings-usage) (optional) | `usage` | object | Token usage on the Cohere platform embed models. | @@ -182,7 +182,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Token Count | `tokens` | number | The token count used by Cohere Models. |
@@ -195,7 +195,7 @@ Rerank models sort text inputs by semantic relevance to a specified query. They
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_RERANKING` | | Model Name (required) | `model-name` | string | The Cohere rerank model to be used.
Enum values
  • `rerank-english-v3.0`
  • `rerank-multilingual-v3.0`
| @@ -212,7 +212,7 @@ Rerank models sort text inputs by semantic relevance to a specified query. They
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Reranked Documents | `ranking` | array[string] | Reranked documents. | | Reranked Documents Relevance (optional) | `relevance` | array[number] | The relevance scores of the reranked documents. | @@ -226,7 +226,7 @@ Rerank models sort text inputs by semantic relevance to a specified query. They
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Search Counts | `search-counts` | number | The search count used by Cohere Models. |
diff --git a/pkg/component/ai/cohere/v0/config/setup.yaml b/pkg/component/ai/cohere/v0/config/setup.yaml index 613364c10..692f9b360 100644 --- a/pkg/component/ai/cohere/v0/config/setup.yaml +++ b/pkg/component/ai/cohere/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: api-key: description: Fill in your Cohere API key. To find your keys, visit the Cohere dashboard page. - acceptFormats: - - string + type: string instillSecret: true instillCredential: true uiOrder: 0 title: API Key - format: string required: [] title: Cohere Connection -format: object +type: object diff --git a/pkg/component/ai/cohere/v0/config/tasks.yaml b/pkg/component/ai/cohere/v0/config/tasks.yaml index 2f4c48430..e40507701 100644 --- a/pkg/component/ai/cohere/v0/config/tasks.yaml +++ b/pkg/component/ai/cohere/v0/config/tasks.yaml @@ -8,18 +8,18 @@ $defs: description: Either a URL of the image or the base64 encoded image data. title: URL uiOrder: 0 - format: string + type: string required: - url title: Image URL description: The image URL. uiOrder: 0 - format: object + type: object text: description: The text content. title: Text uiOrder: 1 - format: string + type: string type: description: The type of the content part. enum: @@ -27,11 +27,11 @@ $defs: - image_url title: Type uiOrder: 2 - format: string + type: string required: - type - format: object - format: array + type: object + type: array chat-message: properties: content: @@ -43,64 +43,54 @@ $defs: description: The message role, i.e. 'system', 'user' or 'assistant'. uiOrder: 0 title: Role - format: string + type: string required: - role - content title: Chat Message - format: object + type: object common: description: Input. uiOrder: 0 properties: image-base64: description: Image base64. - acceptFormats: - - image/* + type: image uiOrder: 2 title: Image - format: string model-name: description: The Instill Model model to be used. - acceptFormats: - - string + type: string uiOrder: 0 title: Model Name - format: string required: - image-base64 - model-name title: Input - format: object + type: object citation: properties: start: description: The start position of the citation. - acceptFormats: - - integer + type: integer uiOrder: 0 title: Start - format: integer end: description: The end position of the citation. - acceptFormats: - - integer + type: integer uiOrder: 1 title: End - format: integer text: description: The text body of the citation. - acceptFormats: - - string + type: string uiOrder: 2 title: Text - format: string required: - start - end - text title: Citation - format: object + type: object command-usage: description: Token Usage on the Cohere Platform Command Models. uiOrder: 1 @@ -109,17 +99,17 @@ $defs: description: The input tokens used by Cohere Models. uiOrder: 2 title: Input Tokens - format: number + type: number output-tokens: description: The output tokens generated by Cohere Models. uiOrder: 3 title: Output Tokens - format: number + type: number required: - input-tokens - output-tokens title: Usage - format: object + type: object rerank-usage: description: Search Usage on the Cohere Platform Rerank Models. uiOrder: 1 @@ -128,11 +118,11 @@ $defs: description: The search count used by Cohere Models. uiOrder: 1 title: Search Counts - format: number + type: number required: - search-counts title: Usage - format: object + type: object embed-usage: description: Token usage on the Cohere platform embed models. uiOrder: 1 @@ -141,11 +131,11 @@ $defs: description: The token count used by Cohere Models. uiOrder: 1 title: Token Count - format: number + type: number required: - tokens title: Usage - format: object + type: object TASK_TEXT_GENERATION_CHAT: shortDescription: Provide text outputs in response to text inputs. description: Cohere's text generation models (often called generative pre-trained transformers or large language models) have been trained to understand @@ -159,23 +149,19 @@ TASK_TEXT_GENERATION_CHAT: chat-history: description: 'Incorporate external chat history, specifically previous messages within the conversation. Each message should adhere to the format: : {"role": "The message role, i.e. ''USER'' or ''CHATBOT''", "content": "message content"}.' - acceptFormats: - - object + type: array shortDescription: 'Incorporate external chat history, specifically previous messages within the conversation. (Note: As for 2024-06-24 Cohere models are not multimodal, so images will be ignored.)' uiOrder: 4 items: $ref: '#/$defs/chat-message' title: Chat history - format: array max-new-tokens: default: 50 description: The maximum number of tokens for model to generate (default=50). - acceptFormats: - - integer + type: integer uiOrder: 6 title: Max New Tokens - format: integer model-name: enum: - command-r-plus @@ -186,8 +172,7 @@ TASK_TEXT_GENERATION_CHAT: - command-light-nightly example: command-r-plus description: The Cohere command model to be used. - acceptFormats: - - string + type: string instillCredentialMap: values: - command-r-plus @@ -198,72 +183,57 @@ TASK_TEXT_GENERATION_CHAT: - setup.api-key uiOrder: 0 title: Model Name - format: string prompt: description: The prompt text. - acceptFormats: - - string + type: string uiOrder: 2 title: Prompt - format: string prompt-images: description: 'The prompt images (Note: As for 2024-06-24 Cohere models are not multimodal, so images will be ignored.).' - acceptFormats: - - array + type: array uiOrder: 3 items: - format: string + type: string title: Prompt Images - format: array seed: default: 42 description: The seed (default=42). - acceptFormats: - - integer + type: integer uiOrder: 4 title: Seed - format: integer system-message: default: You are a helpful assistant. description: The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is using a generic message as "You are a helpful assistant.". - acceptFormats: - - string + type: string shortDescription: The system message helps set the behavior of the assistant uiOrder: 2 title: System Message - format: string temperature: default: 0.7 description: The temperature for sampling (default=0.7). - acceptFormats: - - number + type: number uiOrder: 5 title: Temperature - format: number top-k: default: 10 description: Top k for sampling (default=10). - acceptFormats: - - integer + type: integer uiOrder: 5 title: Top K - format: integer documents: description: The documents to be used for the model, for optimal performance, the length of each document should be less than 300 words. - acceptFormats: - - array + type: array uiOrder: 3 items: - format: string + type: string title: Documents - format: array required: - prompt - model-name title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -272,23 +242,21 @@ TASK_TEXT_GENERATION_CHAT: description: Model Output. uiOrder: 0 title: Text - format: string + type: string citations: description: Citations. uiOrder: 1 - acceptFormats: - - array + type: array title: Citations items: $ref: '#/$defs/citation' - format: array usage: $ref: '#/$defs/command-usage' uiOrder: 2 required: - text title: Output - format: object + type: object TASK_TEXT_EMBEDDINGS: shortDescription: Turn text into a vector of numbers that capture its meaning, unlocking use cases like semantic search. description: An embedding is a list of floating point numbers that captures semantic information about the text that it represents. @@ -303,8 +271,7 @@ TASK_TEXT_EMBEDDINGS: - embed-multilingual-light-v3.0 example: embed-multilingual-v3.0 description: The Cohere embed model to be used. - acceptFormats: - - string + type: string instillCredentialMap: values: - embed-english-v3.0 @@ -315,14 +282,11 @@ TASK_TEXT_EMBEDDINGS: - setup.api-key uiOrder: 0 title: Model Name - format: string text: description: The text. - acceptFormats: - - string + type: string uiOrder: 1 title: Text - format: string input-type: enum: - search_document @@ -331,11 +295,9 @@ TASK_TEXT_EMBEDDINGS: - clustering example: search_document description: Specifies the type of input passed to the model. - acceptFormats: - - string + type: string uiOrder: 0 title: Input Type - format: string embedding-type: enum: - float @@ -346,35 +308,33 @@ TASK_TEXT_EMBEDDINGS: example: float description: Specifies the return type of embedding, Note that 'binary'/'ubinary' options means the component will return packed unsigned binary embeddings. The length of each binary embedding is 1/8 the length of the float embeddings of the provided model. - acceptFormats: - - string + type: string uiOrder: 0 title: Embedding Type - format: string required: - text - model-name - input-type - embedding-type title: Input - format: object + type: object output: uiOrder: 0 properties: embedding: items: title: Embedding - format: number + type: number description: Embedding of the input text. uiOrder: 0 title: Embedding - format: array + type: array usage: $ref: '#/$defs/embed-usage' required: - embedding title: Output - format: object + type: object TASK_TEXT_RERANKING: shortDescription: Sort text inputs by semantic relevance to a specified query. description: Rerank models sort text inputs by semantic relevance to a specified query. They are often used to sort search results returned from an existing @@ -388,8 +348,7 @@ TASK_TEXT_RERANKING: - rerank-multilingual-v3.0 example: rerank-multilingual-v3.0 description: The Cohere rerank model to be used. - acceptFormats: - - string + type: string instillCredentialMap: values: - rerank-english-v3.0 @@ -398,67 +357,58 @@ TASK_TEXT_RERANKING: - setup.api-key uiOrder: 0 title: Model Name - format: string query: description: The query. - acceptFormats: - - string + type: string uiOrder: 1 title: Query - format: string documents: description: The documents to be used for reranking. - acceptFormats: - - array + type: array uiOrder: 2 items: - format: string + type: string title: Documents - format: array top-n: default: 3 description: The number of most relevant documents or indices to return. Defaults to the length of the documents (default=3). - acceptFormats: - - integer + type: integer uiOrder: 3 title: Top N - format: integer max-chunks-per-doc: default: 10 description: The maximum number of chunks to produce internally from a document (default=10). - acceptFormats: - - integer + type: integer uiOrder: 4 title: Maximum number of chunks per document - format: integer required: - query - model-name - documents title: Input - format: object + type: object output: uiOrder: 0 properties: ranking: items: title: Documents - format: string + type: string description: Reranked documents. uiOrder: 0 title: Reranked documents - format: array + type: array usage: $ref: '#/$defs/rerank-usage' relevance: items: title: Relevance - format: number + type: number description: The relevance scores of the reranked documents. uiOrder: 0 title: Reranked documents relevance - format: array + type: array required: - ranking title: Output - format: object + type: object diff --git a/pkg/component/ai/fireworksai/v0/.compogen/bottom.mdx b/pkg/component/ai/fireworksai/v0/.compogen/bottom.mdx index cd7dc97b6..520c4d8ef 100644 --- a/pkg/component/ai/fireworksai/v0/.compogen/bottom.mdx +++ b/pkg/component/ai/fireworksai/v0/.compogen/bottom.mdx @@ -22,7 +22,7 @@ variable: prompt: title: prompt description: input prompt i.e. "寫一份生椰拿鐵文案", "write about horses" - format: string + type: string output: output: title: output diff --git a/pkg/component/ai/fireworksai/v0/README.mdx b/pkg/component/ai/fireworksai/v0/README.mdx index 701222808..99be53200 100644 --- a/pkg/component/ai/fireworksai/v0/README.mdx +++ b/pkg/component/ai/fireworksai/v0/README.mdx @@ -37,7 +37,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key | `api-key` | string | Fill in your Fireworks AI API key. To find your keys, visit the Fireworks AI API Keys page. | @@ -55,7 +55,7 @@ Fireworks AI's text generation models (often called generative pre-trained trans
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_GENERATION_CHAT` | | Model Name (required) | `model` | string | The OSS model to be used.
Enum values
  • `llama-v3p1-405b-instruct`
  • `llama-v3p1-70b-instruct`
  • `llama-v3p1-8b-instruct`
  • `llama-v3-70b-instruct`
  • `llama-v3-8b-instruct`
  • `firellava-13b`
  • `firefunction-v2`
  • `deepseek-coder-v2-instruct`
  • `deepseek-coder-v2-lite-instruct`
  • `starcoder-16b`
  • `starcoder-7b`
  • `phi-3-vision-128k-instruct`
  • `qwen2-72b-instruct`
  • `mythomax-l2-13b`
  • `yi-large`
| @@ -80,7 +80,7 @@ Incorporate external chat history, specifically previous messages within the con
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#text-generation-chat-content) | `content` | array | The message content. | | Role | `role` | string | The message role, i.e. 'system', 'user' or 'assistant'. | @@ -91,7 +91,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#text-generation-chat-image-url) | `image-url` | object | The image URL. | | Text | `text` | string | The text content. | @@ -103,7 +103,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
@@ -113,7 +113,7 @@ The image URL.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Model Output. | | [Usage](#text-generation-chat-usage) (optional) | `usage` | object | Token usage on the Fireworks AI platform text generation models. | @@ -126,7 +126,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Input Tokens | `input-tokens` | number | The input tokens used by Fireworks AI models. | | Output Tokens | `output-tokens` | number | The output tokens generated by Fireworks AI models. | @@ -140,7 +140,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_EMBEDDINGS` | | Model Name (required) | `model` | string | The OSS embedding model to be used.
Enum values
  • `nomic-ai/nomic-embed-text-v1.5`
  • `nomic-ai/nomic-embed-text-v1`
  • `WhereIsAI/UAE-Large-V1`
  • `thenlper/gte-large`
  • `thenlper/gte-base`
| @@ -154,7 +154,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Embedding | `embedding` | array[number] | Embedding of the input text. | | [Usage](#text-embeddings-usage) (optional) | `usage` | object | Token usage on the Fireworks AI platform embedding models. | @@ -167,7 +167,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Token Count | `tokens` | number | The token count used by Fireworks AI models. |
@@ -199,7 +199,7 @@ variable: prompt: title: prompt description: input prompt i.e. "寫一份生椰拿鐵文案", "write about horses" - format: string + type: string output: output: title: output diff --git a/pkg/component/ai/fireworksai/v0/config/setup.yaml b/pkg/component/ai/fireworksai/v0/config/setup.yaml index 53fb8bd5b..b60b9aabe 100644 --- a/pkg/component/ai/fireworksai/v0/config/setup.yaml +++ b/pkg/component/ai/fireworksai/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: api-key: description: Fill in your Fireworks AI API key. To find your keys, visit the Fireworks AI API Keys page. - acceptFormats: - - string + type: string instillSecret: true instillCredential: true uiOrder: 0 title: API Key - format: string required: [] title: Fireworks AI Connection -format: object +type: object diff --git a/pkg/component/ai/fireworksai/v0/config/tasks.yaml b/pkg/component/ai/fireworksai/v0/config/tasks.yaml index f7af48315..c347b57de 100644 --- a/pkg/component/ai/fireworksai/v0/config/tasks.yaml +++ b/pkg/component/ai/fireworksai/v0/config/tasks.yaml @@ -8,18 +8,18 @@ $defs: description: Either a URL of the image or the base64 encoded image data. title: URL uiOrder: 0 - format: string + type: string required: - url title: Image URL description: The image URL. uiOrder: 0 - format: object + type: object text: description: The text content. title: Text uiOrder: 1 - format: string + type: string type: description: The type of the content part. enum: @@ -27,11 +27,11 @@ $defs: - image_url title: Type uiOrder: 2 - format: string + type: string required: - type - format: object - format: array + type: object + type: array chat-message: properties: content: @@ -43,12 +43,12 @@ $defs: description: The message role, i.e. 'system', 'user' or 'assistant'. uiOrder: 0 title: Role - format: string + type: string required: - role - content title: Chat Message - format: object + type: object chat-usage: description: Token usage on the Fireworks AI platform text generation models. uiOrder: 1 @@ -57,17 +57,17 @@ $defs: description: The input tokens used by Fireworks AI models. uiOrder: 2 title: Input Tokens - format: number + type: number output-tokens: description: The output tokens generated by Fireworks AI models. uiOrder: 3 title: Output Tokens - format: number + type: number required: - input-tokens - output-tokens title: Usage - format: object + type: object embedding-usage: description: Token usage on the Fireworks AI platform embedding models. uiOrder: 1 @@ -76,11 +76,11 @@ $defs: description: The token count used by Fireworks AI models. uiOrder: 1 title: Token Count - format: number + type: number required: - tokens title: Usage - format: object + type: object TASK_TEXT_GENERATION_CHAT: shortDescription: Provide text outputs in response to text inputs. description: Fireworks AI's text generation models (often called generative pre-trained transformers or large language models) have been trained to understand @@ -95,8 +95,7 @@ TASK_TEXT_GENERATION_CHAT: description: 'Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : {"role": "The message role, i.e. ''system'', ''user'' or ''assistant''", "content": "message content"}.' - acceptFormats: - - object + type: array shortDescription: 'Incorporate external chat history, specifically previous messages within the conversation. (Note: According to Fireworks AI documentation on 2024-07-24, the total number of images included in a single API request should not exceed 30, and all the images should be smaller than 5MB in size)' @@ -104,15 +103,12 @@ TASK_TEXT_GENERATION_CHAT: items: $ref: '#/$defs/chat-message' title: Chat history - format: array max-new-tokens: default: 50 description: The maximum number of tokens for model to generate. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Max New Tokens - format: integer model: enum: - llama-v3p1-405b-instruct @@ -132,8 +128,7 @@ TASK_TEXT_GENERATION_CHAT: - yi-large example: llama-v3p1-8b-instruct description: The OSS model to be used. - acceptFormats: - - string + type: string uiOrder: 0 instillCredentialMap: values: @@ -154,74 +149,58 @@ TASK_TEXT_GENERATION_CHAT: targets: - setup.api-key title: Model Name - format: string prompt: description: The prompt text. - acceptFormats: - - string + type: string uiOrder: 2 title: Prompt - format: string prompt-images: description: 'The prompt images (Note: According to Fireworks AI documentation on 2024-07-24, the total number of images included in a single API request should not exceed 30, and all the images should be smaller than 5MB in size).' - acceptFormats: - - array + type: array uiOrder: 3 items: - format: string + type: string title: Prompt Images - format: array seed: description: The seed. - acceptFormats: - - integer + type: integer uiOrder: 4 title: Seed - format: integer system-message: default: You are a helpful assistant. description: The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is set using a generic message as "You are a helpful assistant.". - acceptFormats: - - string + type: string shortDescription: The system message helps set the behavior of the assistant uiOrder: 2 title: System Message - format: string temperature: default: 0.7 description: The temperature for sampling. - acceptFormats: - - number + type: number uiOrder: 5 title: Temperature - format: number top-k: default: 10 description: Integer to define the top tokens considered within the sample operation to create new text. - acceptFormats: - - integer + type: integer uiOrder: 5 title: Top K - format: integer top-p: default: 0.5 description: Float to define the tokens that are within the sample operation of text generation. Add tokens in the sample for more probable to least probable until the sum of the probabilities is greater than top-p (default=0.5). - acceptFormats: - - number - - integer + type: number shortDescription: Float to define the tokens that are within the sample operation of text generation uiOrder: 6 title: Top P - format: number required: - prompt - model title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -230,13 +209,13 @@ TASK_TEXT_GENERATION_CHAT: description: Model Output. uiOrder: 0 title: Text - format: string + type: string usage: $ref: '#/$defs/chat-usage' required: - text title: Output - format: object + type: object TASK_TEXT_EMBEDDINGS: shortDescription: Turn text into a vector of numbers that capture its meaning, unlocking use cases like semantic search. description: An embedding is a list of floating point numbers that captures semantic information about the text that it represents. @@ -252,8 +231,7 @@ TASK_TEXT_EMBEDDINGS: - thenlper/gte-base example: nomic-ai/nomic-embed-text-v1.5 description: The OSS embedding model to be used. - acceptFormats: - - string + type: string uiOrder: 0 title: Model Name instillCredentialMap: @@ -265,33 +243,30 @@ TASK_TEXT_EMBEDDINGS: - thenlper/gte-base targets: - setup.api-key - format: string text: description: The text. - acceptFormats: - - string + type: string uiOrder: 1 title: Text - format: string required: - text - model title: Input - format: object + type: object output: uiOrder: 0 properties: embedding: items: title: Embedding - format: number + type: number description: Embedding of the input text. uiOrder: 0 title: Embedding - format: array + type: array usage: $ref: '#/$defs/embedding-usage' required: - embedding title: Output - format: object + type: object diff --git a/pkg/component/ai/groq/v0/.compogen/bottom.mdx b/pkg/component/ai/groq/v0/.compogen/bottom.mdx index 26c1281b7..ffe80953b 100644 --- a/pkg/component/ai/groq/v0/.compogen/bottom.mdx +++ b/pkg/component/ai/groq/v0/.compogen/bottom.mdx @@ -26,7 +26,7 @@ variable: experience: title: experience description: describe your work experience - format: string + type: string instill-ui-multiline: true output: resume_format: diff --git a/pkg/component/ai/groq/v0/README.mdx b/pkg/component/ai/groq/v0/README.mdx index 8c01090b6..d9fd7eb98 100644 --- a/pkg/component/ai/groq/v0/README.mdx +++ b/pkg/component/ai/groq/v0/README.mdx @@ -36,7 +36,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key | `api-key` | string | Fill in your GroqCloud API key. To find your keys, visit the GroqCloud API Keys page. | @@ -54,14 +54,14 @@ Groq serves open source text generation models (often called generative pre-trai
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_GENERATION_CHAT` | | Model (required) | `model` | string | The OSS model to be used.
Enum values
  • `llama-3.1-405b-reasoning`
  • `llama-3.1-70b-versatile`
  • `llama-3.1-8b-instant`
  • `llama3-groq-70b-8192-tool-use-preview`
  • `llama3-groq-8b-8192-tool-use-preview`
  • `llama3-70b-8192`
  • `llama-guard-3-8b`
  • `llama3-8b-8192`
  • `mixtral-8x7b-32768`
  • `gemma2-9b-it`
  • `gemma-7b-it`
| | Prompt (required) | `prompt` | string | The prompt text. | | System Message | `system-message` | string | The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is set using a generic message as "You are a helpful assistant.". | | Prompt Images | `prompt-images` | array[string] | The prompt images (Note: Only a subset of OSS models support image inputs). | -| [Chat History](#text-generation-chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | +| [Chat History](#text-generation-chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | | Seed | `seed` | integer | The seed. | | Temperature | `temperature` | number | The temperature for sampling. | | Top K | `top-k` | integer | Integer to define the top tokens considered within the sample operation to create new text. | @@ -76,11 +76,11 @@ Groq serves open source text generation models (often called generative pre-trai

Chat History

-Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. +Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#text-generation-chat-content) | `content` | array | The message content. | | Role | `role` | string | The message role, i.e. 'system', 'user' or 'assistant'. | @@ -91,7 +91,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#text-generation-chat-image-url) | `image-url` | object | The image URL. | | Text | `text` | string | The text content. | @@ -103,7 +103,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
@@ -113,7 +113,7 @@ The image URL.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Model Output. | | [Usage](#text-generation-chat-usage) (optional) | `usage` | object | Token usage on the GroqCloud platform text generation models. | @@ -126,7 +126,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Input Tokens | `input-tokens` | number | The input tokens used by GroqCloud OSS models. | | Output Tokens | `output-tokens` | number | The output tokens generated by GroqCloud OSS models. | @@ -163,7 +163,7 @@ variable: experience: title: experience description: describe your work experience - format: string + type: string instill-ui-multiline: true output: resume_format: diff --git a/pkg/component/ai/groq/v0/config/setup.yaml b/pkg/component/ai/groq/v0/config/setup.yaml index 83545225d..d7fa8ed97 100644 --- a/pkg/component/ai/groq/v0/config/setup.yaml +++ b/pkg/component/ai/groq/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: api-key: description: Fill in your GroqCloud API key. To find your keys, visit the GroqCloud API Keys page. - acceptFormats: - - string + type: string instillSecret: true instillCredential: true uiOrder: 0 title: API Key - format: string required: [] title: GroqCloud Connection -format: object +type: object diff --git a/pkg/component/ai/groq/v0/config/tasks.yaml b/pkg/component/ai/groq/v0/config/tasks.yaml index 102cc576c..77ad32d6d 100644 --- a/pkg/component/ai/groq/v0/config/tasks.yaml +++ b/pkg/component/ai/groq/v0/config/tasks.yaml @@ -8,18 +8,18 @@ $defs: description: Either a URL of the image or the base64 encoded image data. title: URL uiOrder: 0 - format: string + type: string required: - url title: Image URL description: The image URL. uiOrder: 0 - format: object + type: object text: description: The text content. title: Text uiOrder: 1 - format: string + type: string type: description: The type of the content part. enum: @@ -27,11 +27,11 @@ $defs: - image_url title: Type uiOrder: 2 - format: string + type: string required: - type - format: object - format: array + type: object + type: array chat-message: properties: content: @@ -43,12 +43,12 @@ $defs: description: The message role, i.e. 'system', 'user' or 'assistant'. uiOrder: 0 title: Role - format: string + type: string required: - role - content title: Chat Message - format: object + type: object chat-usage: description: Token usage on the GroqCloud platform text generation models. uiOrder: 1 @@ -57,17 +57,17 @@ $defs: description: The input tokens used by GroqCloud OSS models. uiOrder: 2 title: Input Tokens - format: number + type: number output-tokens: description: The output tokens generated by GroqCloud OSS models. uiOrder: 3 title: Output Tokens - format: number + type: number required: - input-tokens - output-tokens title: Usage - format: object + type: object TASK_TEXT_GENERATION_CHAT: shortDescription: Provide text outputs in response to text inputs. description: Groq serves open source text generation models (often called generative pre-trained transformers or large language models) have been trained @@ -80,25 +80,21 @@ TASK_TEXT_GENERATION_CHAT: properties: chat-history: description: 'Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be - ignored and will not have any effect when this field is populated. Each message should adhere to the format: : {"role": "The message role, i.e. + ignored and will not have any effect when this field is populated. Each message should adhere to the format: {"role": "The message role, i.e. ''system'', ''user'' or ''assistant''", "content": "message content"}.' - acceptFormats: - - object + type: array shortDescription: 'Incorporate external chat history, specifically previous messages within the conversation. (Note: Only a subset of OSS models support image inputs)' uiOrder: 4 items: $ref: '#/$defs/chat-message' title: Chat history - format: array max-new-tokens: default: 50 description: The maximum number of tokens for model to generate. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Max New Tokens - format: integer model: enum: - llama-3.1-405b-reasoning @@ -114,8 +110,7 @@ TASK_TEXT_GENERATION_CHAT: - gemma-7b-it example: llama3-8b-8192 description: The OSS model to be used. - acceptFormats: - - string + type: string uiOrder: 0 instillCredentialMap: values: @@ -129,82 +124,64 @@ TASK_TEXT_GENERATION_CHAT: targets: - setup.api-key title: Model - format: string prompt: description: The prompt text. - acceptFormats: - - string + type: string uiOrder: 2 title: Prompt - format: string prompt-images: description: 'The prompt images (Note: Only a subset of OSS models support image inputs).' - acceptFormats: - - array + type: array uiOrder: 3 items: - format: string + type: string title: Prompt Images - format: array seed: description: The seed. - acceptFormats: - - integer + type: integer uiOrder: 4 title: Seed - format: integer system-message: default: You are a helpful assistant. description: The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is set using a generic message as "You are a helpful assistant.". - acceptFormats: - - string + type: string shortDescription: The system message helps set the behavior of the assistant uiOrder: 2 title: System Message - format: string temperature: default: 0.7 description: The temperature for sampling. - acceptFormats: - - number + type: number uiOrder: 5 title: Temperature - format: number top-k: default: 10 description: Integer to define the top tokens considered within the sample operation to create new text. - acceptFormats: - - integer + type: integer uiOrder: 5 title: Top K - format: integer top-p: default: 0.5 description: Float to define the tokens that are within the sample operation of text generation. Add tokens in the sample for more probable to least probable until the sum of the probabilities is greater than top-p (default=0.5). - acceptFormats: - - number - - integer + type: number shortDescription: Float to define the tokens that are within the sample operation of text generation uiOrder: 6 title: Top P - format: number user: default: instill-ai description: The user name passed to GroqPlatform. - acceptFormats: - - string + type: string shortDescription: A unique identifier representing your end-user, which can help Groq monitor and detect abuse. uiOrder: 7 title: User - format: string required: - prompt - model title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -213,10 +190,10 @@ TASK_TEXT_GENERATION_CHAT: description: Model Output. uiOrder: 0 title: Text - format: string + type: string usage: $ref: '#/$defs/chat-usage' required: - text title: Output - format: object + type: object diff --git a/pkg/component/ai/huggingface/v0/README.mdx b/pkg/component/ai/huggingface/v0/README.mdx index caac5a8d4..0bb29be78 100644 --- a/pkg/component/ai/huggingface/v0/README.mdx +++ b/pkg/component/ai/huggingface/v0/README.mdx @@ -52,7 +52,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key (required) | `api-key` | string | Fill in your Hugging face API token. To find your token, visit here. | | Base URL (required) | `base-url` | string | Hostname for the endpoint. To use Inference API set to here, for Inference Endpoint set to your custom endpoint. | @@ -72,7 +72,7 @@ Generating text is the task of producing new text. These models can, for example
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_GENERATION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -91,7 +91,7 @@ Parameters.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Do Sample | `do-sample` | boolean | Whether or not to use sampling, use greedy decoding otherwise. | | Max New Tokens | `max-new-tokens` | integer | The amount of new tokens to be generated, this does not include the input length it is a estimate of the size of generated text you want. Each new tokens slows down the request, so look for balance between response times and length of text generated. | @@ -109,7 +109,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -120,7 +120,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Generated Text | `generated-text` | string | The continuated string. |
@@ -132,7 +132,7 @@ Masked language modeling is the task of masking some of the words in a sentence
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_FILL_MASK` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -150,7 +150,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -161,7 +161,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Results](#fill-mask-results) | `results` | array[object] | Results. |
@@ -173,7 +173,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Score | `score` | number | The probability for this token. | | Sequence | `sequence` | string | The actual sequence of tokens that ran against the model (may contain special tokens). | @@ -189,7 +189,7 @@ Summarization is the task of producing a shorter version of a document while pre
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SUMMARIZATION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -208,7 +208,7 @@ Parameters.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Max Length | `max-length` | integer | Integer to define the maximum length in tokens of the output summary. | | Max Time | `max-time` | number | The amount of time in seconds that the query should take maximum. Network can cause some overhead so it will be a soft limit. | @@ -224,7 +224,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -235,7 +235,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Summary Text | `summary-text` | string | The string after summarization. |
@@ -247,7 +247,7 @@ Text Classification is the task of assigning a label or class to a given text. S
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_CLASSIFICATION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -265,7 +265,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -276,7 +276,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Results](#text-classification-results) | `results` | array[object] | Results. |
@@ -288,7 +288,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Label | `label` | string | The label for the class (model specific). | | Score | `score` | number | A floats that represents how likely is that the text belongs the this class. | @@ -302,7 +302,7 @@ Token classification is a natural language understanding task in which a label i
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TOKEN_CLASSIFICATION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -321,7 +321,7 @@ Parameters.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Aggregation Strategy | `aggregation-strategy` | string | There are several aggregation strategies: none: Every token gets classified without further aggregation. @@ -336,7 +336,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -347,7 +347,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Results](#token-classification-results) | `results` | array[object] | Results. |
@@ -359,7 +359,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | End | `end` | integer | The offset stringwise where the answer is located. Useful to disambiguate if word occurs multiple times. | | Entity Group | `entity-group` | string | The type for the entity being recognized (model specific). | @@ -376,7 +376,7 @@ Translation is the task of converting text from one language to another.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TRANSLATION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -394,7 +394,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -405,7 +405,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Translation Text | `translation-text` | string | The string after translation. |
@@ -417,7 +417,7 @@ Zero-shot text classification is a task in natural language processing where a m
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_ZERO_SHOT_CLASSIFICATION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -436,7 +436,7 @@ Parameters.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Candidate Labels | `candidate-labels` | array | a list of strings that are potential classes for inputs. (max 10 candidate-labels, for more, simply run multiple requests, results are going to be misleading if using too many candidate-labels anyway. If you want to keep the exact same, you can simply run multi-label=True and do the scaling on your end. ). | | Multi Label | `multi-label` | boolean | Boolean that is set to True if classes can overlap. | @@ -447,7 +447,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -458,7 +458,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Scores | `scores` | array[number] | a list of floats that correspond the the probability of label, in the same order as labels. | | Labels | `labels` | array[string] | The list of strings for labels that you sent (in order). | @@ -472,7 +472,7 @@ Question Answering models can retrieve the answer to a question from a given tex
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_QUESTION_ANSWERING` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -490,7 +490,7 @@ Inputs.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Context | `context` | string | The context for answering the question. | | Question | `question` | string | The question. | @@ -501,7 +501,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -512,7 +512,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Answer | `answer` | string | A string that’s the answer within the text. | | Stop (optional) | `stop` | integer | The index (string wise) of the stop of the answer within context. | @@ -527,7 +527,7 @@ Table Question Answering (Table QA) is the answering a question about an informa
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TABLE_QUESTION_ANSWERING` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -545,7 +545,7 @@ Inputs.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Query | `query` | string | The query in plain text that you want to ask the table. | | Table | `table` | object | A table of data represented as a dict of list where entries are headers and the lists are all the values, all lists must have the same size. | @@ -556,7 +556,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -567,7 +567,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Aggregator (optional) | `aggregator` | string | The aggregator used to get the answer. | | Answer | `answer` | string | The plaintext answer. | @@ -582,7 +582,7 @@ Sentence Similarity is the task of determining how similar two texts are. Senten
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SENTENCE_SIMILARITY` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -600,7 +600,7 @@ Inputs.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Sentences | `sentences` | array | A list of strings which will be compared against the source-sentence. | | Source Sentence | `source-sentence` | string | The string that you wish to compare the other strings with. This can be a phrase, sentence, or longer passage, depending on the model being used. | @@ -611,7 +611,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -622,7 +622,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Scores | `scores` | array[number] | The associated similarity score for each of the given strings. |
@@ -634,7 +634,7 @@ Conversational response modelling is the task of generating conversational text
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CONVERSATIONAL` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -653,7 +653,7 @@ Inputs.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Generated Responses | `generated-responses` | array | A list of strings corresponding to the earlier replies from the model. | | Past User Inputs | `past-user-inputs` | array | A list of strings corresponding to the earlier replies from the user. Should be of the same length of generated-responses. | @@ -665,7 +665,7 @@ Parameters.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Max Length | `max-length` | integer | Integer to define the maximum length in tokens of the output summary. | | Max Time | `max-time` | number | The amount of time in seconds that the query should take maximum. Network can cause some overhead so it will be a soft limit. | @@ -681,7 +681,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Use Cache | `use-cache` | boolean | There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. | | Wait For Model | `wait-for-model` | boolean | If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. | @@ -692,7 +692,7 @@ Options for the model.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Conversation](#conversational-conversation) (optional) | `conversation` | object | A facility dictionary to send back for the next input (with the new user input addition). | | Generated Text | `generated-text` | string | The answer of the bot. | @@ -705,7 +705,7 @@ Options for the model.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Generated Responses | `generated-responses` | array | List of strings. The last outputs from the model in the conversation, after the model has run. | | Past User Inputs | `past-user-inputs` | array | List of strings. The last inputs from the user in the conversation, after the model has run. | @@ -719,7 +719,7 @@ Image classification is the task of assigning a label or class to an entire imag
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_IMAGE_CLASSIFICATION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -733,7 +733,7 @@ Image classification is the task of assigning a label or class to an entire imag
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Classes](#image-classification-classes) | `classes` | array[object] | Classes. |
@@ -745,7 +745,7 @@ Image classification is the task of assigning a label or class to an entire imag
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Label | `label` | string | The label for the class (model specific). | | Score | `score` | number | A float that represents how likely it is that the image file belongs to this class. | @@ -759,7 +759,7 @@ Image Segmentation divides an image into segments where each pixel in the image
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_IMAGE_SEGMENTATION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -773,7 +773,7 @@ Image Segmentation divides an image into segments where each pixel in the image
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Segments](#image-segmentation-segments) | `segments` | array[object] | Segments. |
@@ -785,7 +785,7 @@ Image Segmentation divides an image into segments where each pixel in the image
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Label | `label` | string | The label for the class (model specific) of a segment. | | Mask | `mask` | image/png | A str (base64 str of a single channel black-and-white img) representing the mask of a segment. | @@ -800,7 +800,7 @@ Object Detection models allow users to identify objects of certain defined class
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_OBJECT_DETECTION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -814,7 +814,7 @@ Object Detection models allow users to identify objects of certain defined class
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Objects](#object-detection-objects) | `objects` | array[object] | Objects. |
@@ -826,7 +826,7 @@ Object Detection models allow users to identify objects of certain defined class
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Box](#object-detection-box) | `box` | object | A dict (with keys [xmin,ymin,xmax,ymax]) representing the bounding box of a detected object. | | Label | `label` | string | The label for the class (model specific) of a detected object. | @@ -837,7 +837,7 @@ Object Detection models allow users to identify objects of certain defined class
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | X Max | `xmax` | number | X max. | | X Min | `xmin` | number | X min. | @@ -853,7 +853,7 @@ Image to text models output a text from a given image. Image captioning or optic
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_IMAGE_TO_TEXT` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -867,7 +867,7 @@ Image to text models output a text from a given image. Image captioning or optic
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Generated text. |
@@ -879,7 +879,7 @@ Automatic Speech Recognition (ASR), also known as Speech to Text (STT), is the t
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SPEECH_RECOGNITION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -893,7 +893,7 @@ Automatic Speech Recognition (ASR), also known as Speech to Text (STT), is the t
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | The string that was recognized within the audio file. |
@@ -905,7 +905,7 @@ Audio classification is the task of assigning a label or class to a given audio.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_AUDIO_CLASSIFICATION` | | Model (required) | `model` | string | The Hugging Face model to be used. | @@ -919,7 +919,7 @@ Audio classification is the task of assigning a label or class to a given audio.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Classes](#audio-classification-classes) | `classes` | array[object] | Classes. |
@@ -931,7 +931,7 @@ Audio classification is the task of assigning a label or class to a given audio.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Label | `label` | string | The label for the class (model specific). | | Score | `score` | number | A float that represents how likely it is that the audio file belongs to this class. | diff --git a/pkg/component/ai/huggingface/v0/config/setup.yaml b/pkg/component/ai/huggingface/v0/config/setup.yaml index 704d6c48e..236c5106d 100644 --- a/pkg/component/ai/huggingface/v0/config/setup.yaml +++ b/pkg/component/ai/huggingface/v0/config/setup.yaml @@ -2,34 +2,28 @@ additionalProperties: false properties: api-key: description: Fill in your Hugging face API token. To find your token, visit here. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: API Key - format: string base-url: default: https://api-inference.huggingface.co description: Hostname for the endpoint. To use Inference API set to here, for Inference Endpoint set to your custom endpoint. - acceptFormats: - - string + type: string instillSecret: false uiOrder: 1 title: Base URL - format: string is-custom-endpoint: default: false description: Fill true if you are using a custom Inference Endpoint and not the Inference API. - acceptFormats: - - boolean + type: boolean instillSecret: false uiOrder: 2 title: Is Custom Endpoint - format: boolean required: - api-key - base-url - is-custom-endpoint title: Hugging Face Connection -format: object +type: object diff --git a/pkg/component/ai/huggingface/v0/config/tasks.yaml b/pkg/component/ai/huggingface/v0/config/tasks.yaml index 227bad854..3d8cef051 100644 --- a/pkg/component/ai/huggingface/v0/config/tasks.yaml +++ b/pkg/component/ai/huggingface/v0/config/tasks.yaml @@ -1,42 +1,34 @@ $defs: model: description: The Hugging Face model to be used. - acceptFormats: - - string + type: string title: Model - format: string options: properties: use-cache: description: There is a cache layer on the inference API to speedup requests we have already seen. Most models can use those results as is as models are deterministic (meaning the results will be the same anyway). However if you use a non deterministic model, you can set this parameter to prevent the caching mechanism from being used resulting in a real new query. - acceptFormats: - - boolean + type: boolean shortDescription: Enable the cache of inference API uiOrder: 1 title: Use Cache - format: boolean wait-for-model: description: If the model is not ready, wait for it instead of receiving 503. It limits the number of requests required to get your inference done. It is advised to only set this flag to true after receiving a 503 error as it will limit hanging in your application to known places. - acceptFormats: - - boolean + type: boolean shortDescription: Wait for model ready uiOrder: 0 title: Wait For Model - format: boolean required: [] description: Options for the model. title: Options - format: object + type: object string-input: description: String input. - acceptFormats: - - string + type: string uiOrder: 0 title: String Input - format: string TASK_AUDIO_CLASSIFICATION: shortDescription: Audio classification is the task of assigning a label or class to a given audio. description: Audio classification is the task of assigning a label or class to a given audio. It can be used for recognizing which command a user is giving @@ -46,11 +38,9 @@ TASK_AUDIO_CLASSIFICATION: properties: audio: description: The audio file. - acceptFormats: - - audio/* + type: string uiOrder: 1 title: Audio - format: string model: $ref: '#/$defs/model' uiOrder: 0 @@ -58,7 +48,7 @@ TASK_AUDIO_CLASSIFICATION: - audio - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -70,25 +60,25 @@ TASK_AUDIO_CLASSIFICATION: description: The label for the class (model specific). uiOrder: 0 title: Label - format: string + type: string score: description: A float that represents how likely it is that the audio file belongs to this class. uiOrder: 1 title: Score - format: number + type: number required: - label - score description: Class. title: Class - format: object + type: object description: Classes. title: Classes - format: array + type: array required: - classes title: Output - format: object + type: object TASK_CONVERSATIONAL: shortDescription: Conversational response modelling is the task of generating conversational text that is relevant, coherent and knowledgable given a prompt. @@ -102,37 +92,31 @@ TASK_CONVERSATIONAL: properties: generated-responses: description: A list of strings corresponding to the earlier replies from the model. - acceptFormats: - - array + type: array uiOrder: 0 items: description: Items. - format: string + type: string title: Generated Responses - format: array past-user-inputs: description: A list of strings corresponding to the earlier replies from the user. Should be of the same length of generated-responses. - acceptFormats: - - array + type: array shortDescription: A list of strings corresponding to the earlier replies from the user. uiOrder: 1 items: description: Items. - format: string + type: string title: Past User Inputs - format: array text: description: The last input from the user in the conversation. - acceptFormats: - - string + type: string uiOrder: 2 title: Text - format: string required: - text description: Inputs. title: Inputs - format: object + type: object model: $ref: '#/$defs/model' uiOrder: 0 @@ -144,78 +128,60 @@ TASK_CONVERSATIONAL: properties: max-length: description: Integer to define the maximum length in tokens of the output summary. - acceptFormats: - - integer + type: integer uiOrder: 0 title: Max Length - format: integer max-time: description: The amount of time in seconds that the query should take maximum. Network can cause some overhead so it will be a soft limit. - acceptFormats: - - number - - integer + type: number shortDescription: The amount of time in seconds that the query should take maximum. uiOrder: 1 maximum: 120.0 minimum: 0.0 title: Max Time - format: number min-length: description: Integer to define the minimum length in tokens of the output summary. - acceptFormats: - - integer + type: integer uiOrder: 2 title: Min Length - format: integer repetition-penalty: description: The more a token is used within generation the more it is penalized to not be picked in successive generation passes. - acceptFormats: - - number - - integer + type: number uiOrder: 3 maximum: 100.0 minimum: 0.0 title: Repetition Penalty - format: number temperature: default: 1.0 description: The temperature of the sampling operation. 1 means regular sampling, 0 means always take the highest score, 100.0 is getting closer to uniform probability. - acceptFormats: - - number - - integer + type: number shortDescription: The temperature of the sampling operation. uiOrder: 4 maximum: 100.0 minimum: 0.0 title: Temperature - format: number top-k: description: Integer to define the top tokens considered within the sample operation to create new text. - acceptFormats: - - integer + type: integer uiOrder: 5 title: Top K - format: integer top-p: description: Float to define the tokens that are within the sample operation of text generation. Add tokens in the sample for more probable to least probable until the sum of the probabilities is greater than top-p. - acceptFormats: - - number - - integer + type: number shortDescription: Float to define the tokens that are within the sample operation of text generation. uiOrder: 6 title: Top P - format: number required: [] description: Parameters. title: Parameters - format: object + type: object required: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -229,32 +195,32 @@ TASK_CONVERSATIONAL: items: title: Generated Response description: Generated Response. - format: string + type: string title: Generated Responses - format: array + type: array past-user-inputs: description: List of strings. The last inputs from the user in the conversation, after the model has run. uiOrder: 1 items: title: Past User Input description: Past User Input. - format: string + type: string title: Past User Inputs - format: array + type: array required: - generated-responses - past-user-inputs title: Conversation - format: object + type: object generated-text: description: The answer of the bot. uiOrder: 1 title: Generated Text - format: string + type: string required: - generated-text title: Output - format: object + type: object TASK_FILL_MASK: shortDescription: Masked language modeling is the task of masking some of the words in a sentence and predicting which words should replace those masks. description: Masked language modeling is the task of masking some of the words in a sentence and predicting which words should replace those masks. These @@ -276,7 +242,7 @@ TASK_FILL_MASK: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -288,33 +254,33 @@ TASK_FILL_MASK: description: The probability for this token. uiOrder: 0 title: Score - format: number + type: number sequence: description: The actual sequence of tokens that ran against the model (may contain special tokens). uiOrder: 1 title: Sequence - format: string + type: string token: description: The id of the token. uiOrder: 2 title: Token - format: integer + type: integer token-str: description: The string representation of the token. uiOrder: 3 title: Token Str - format: string + type: string description: Result. title: Result required: [] - format: object + type: object description: Results. title: Results - format: array + type: array required: - results title: Output - format: object + type: object TASK_IMAGE_CLASSIFICATION: shortDescription: Image classification is the task of assigning a label or class to an entire image. description: Image classification is the task of assigning a label or class to an entire image. Images are expected to have only one class for each image. @@ -324,11 +290,9 @@ TASK_IMAGE_CLASSIFICATION: properties: image: description: The image file. - acceptFormats: - - image/* + type: string uiOrder: 1 title: Image - format: string model: $ref: '#/$defs/model' uiOrder: 0 @@ -336,7 +300,7 @@ TASK_IMAGE_CLASSIFICATION: - image - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -348,25 +312,25 @@ TASK_IMAGE_CLASSIFICATION: description: The label for the class (model specific). uiOrder: 0 title: Label - format: string + type: string score: description: A float that represents how likely it is that the image file belongs to this class. uiOrder: 0 title: Score - format: number + type: number required: - label - score description: Class. title: Class - format: object + type: object description: Classes. title: Classes - format: array + type: array required: - classes title: Output - format: object + type: object TASK_IMAGE_SEGMENTATION: shortDescription: Image Segmentation divides an image into segments where each pixel in the image is mapped to an object. description: Image Segmentation divides an image into segments where each pixel in the image is mapped to an object. This task has multiple variants such @@ -376,11 +340,9 @@ TASK_IMAGE_SEGMENTATION: properties: image: description: The image file. - acceptFormats: - - image/* + type: string uiOrder: 1 title: Image - format: string model: $ref: '#/$defs/model' uiOrder: 0 @@ -388,7 +350,7 @@ TASK_IMAGE_SEGMENTATION: - image - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -400,31 +362,31 @@ TASK_IMAGE_SEGMENTATION: description: The label for the class (model specific) of a segment. uiOrder: 0 title: Label - format: string + type: string mask: description: A str (base64 str of a single channel black-and-white img) representing the mask of a segment. uiOrder: 1 title: Mask - format: image/png + type: image/png score: description: A float that represents how likely it is that the segment belongs to the given class. uiOrder: 2 title: Score - format: number + type: number required: - label - mask - score description: Segment. title: Segment - format: object + type: object description: Segments. title: Segments - format: array + type: array required: - segments title: Output - format: object + type: object TASK_IMAGE_TO_TEXT: shortDescription: Image to text models output a text from a given image. description: Image to text models output a text from a given image. Image captioning or optical character recognition can be considered as the most common @@ -434,11 +396,9 @@ TASK_IMAGE_TO_TEXT: properties: image: description: The image file. - acceptFormats: - - image/* + type: string uiOrder: 1 title: Image - format: string model: $ref: '#/$defs/model' uiOrder: 0 @@ -446,7 +406,7 @@ TASK_IMAGE_TO_TEXT: - image - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -454,11 +414,11 @@ TASK_IMAGE_TO_TEXT: description: Generated text. uiOrder: 0 title: Text - format: string + type: string required: - text title: Output - format: object + type: object TASK_OBJECT_DETECTION: shortDescription: Object Detection models allow users to identify objects of certain defined classes. description: Object Detection models allow users to identify objects of certain defined classes. Object detection models receive an image as input and @@ -468,11 +428,9 @@ TASK_OBJECT_DETECTION: properties: image: description: The image file. - acceptFormats: - - image/* + type: string uiOrder: 1 title: Image - format: string model: $ref: '#/$defs/model' uiOrder: 0 @@ -480,7 +438,7 @@ TASK_OBJECT_DETECTION: - image - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -496,53 +454,53 @@ TASK_OBJECT_DETECTION: description: X max. uiOrder: 0 title: X Max - format: number + type: number xmin: description: X min. uiOrder: 1 title: X Min - format: number + type: number ymax: description: Y Max. uiOrder: 2 title: Y Max - format: number + type: number ymin: description: Y min. uiOrder: 3 title: Y min - format: number + type: number required: - xmax - xmin - ymax - ymin title: Box - format: object + type: object label: description: The label for the class (model specific) of a detected object. uiOrder: 1 title: Label - format: string + type: string score: description: A float that represents how likely it is that the detected object belongs to the given class. uiOrder: 2 title: Score - format: number + type: number required: - box - label - score description: Object. title: Object - format: object + type: object description: Objects. title: Objects - format: array + type: array required: - objects title: Output - format: object + type: object TASK_QUESTION_ANSWERING: shortDescription: Question Answering models can retrieve the answer to a question from a given text, which is useful for searching for an answer in a document. @@ -556,24 +514,20 @@ TASK_QUESTION_ANSWERING: properties: context: description: The context for answering the question. - acceptFormats: - - string + type: string uiOrder: 0 title: Context - format: string question: description: The question. - acceptFormats: - - string + type: string uiOrder: 1 title: Question - format: string required: - question - context description: Inputs. title: Inputs - format: object + type: object model: $ref: '#/$defs/model' uiOrder: 0 @@ -584,7 +538,7 @@ TASK_QUESTION_ANSWERING: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -592,26 +546,26 @@ TASK_QUESTION_ANSWERING: description: A string that’s the answer within the text. uiOrder: 0 title: Answer - format: string + type: string score: description: A float that represents how likely that the answer is correct. uiOrder: 2 title: Score - format: number + type: number start: description: The index (string wise) of the start of the answer within context. uiOrder: 3 title: Start - format: integer + type: integer stop: description: The index (string wise) of the stop of the answer within context. uiOrder: 1 title: Stop - format: integer + type: integer required: - answer title: Output - format: object + type: object TASK_SENTENCE_SIMILARITY: shortDescription: Sentence Similarity is the task of determining how similar two texts are. description: Sentence Similarity is the task of determining how similar two texts are. Sentence similarity models convert input texts into vectors (embeddings) @@ -625,29 +579,25 @@ TASK_SENTENCE_SIMILARITY: properties: sentences: description: A list of strings which will be compared against the source-sentence. - acceptFormats: - - array + type: array uiOrder: 0 items: description: Items. - format: string + type: string title: Sentences - format: array source-sentence: description: The string that you wish to compare the other strings with. This can be a phrase, sentence, or longer passage, depending on the model being used. - acceptFormats: - - string + type: string shortDescription: The string that you wish to compare the other strings with. uiOrder: 1 title: Source Sentence - format: string required: - source-sentence - sentences description: Inputs. title: Inputs - format: object + type: object model: $ref: '#/$defs/model' uiOrder: 0 @@ -658,7 +608,7 @@ TASK_SENTENCE_SIMILARITY: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -668,13 +618,13 @@ TASK_SENTENCE_SIMILARITY: items: description: The associated similarity score for of the given string. title: Score - format: number + type: number title: Scores - format: array + type: array required: - scores title: Output - format: object + type: object TASK_SPEECH_RECOGNITION: shortDescription: Automatic Speech Recognition (ASR), also known as Speech to Text (STT), is the task of transcribing a given audio to text. description: Automatic Speech Recognition (ASR), also known as Speech to Text (STT), is the task of transcribing a given audio to text. It has many applications, @@ -684,11 +634,9 @@ TASK_SPEECH_RECOGNITION: properties: audio: description: The audio file. - acceptFormats: - - audio/* + type: string uiOrder: 1 title: Audio - format: string model: $ref: '#/$defs/model' uiOrder: 0 @@ -696,7 +644,7 @@ TASK_SPEECH_RECOGNITION: - audio - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -704,11 +652,11 @@ TASK_SPEECH_RECOGNITION: description: The string that was recognized within the audio file. uiOrder: 0 title: Text - format: string + type: string required: - text title: Output - format: object + type: object TASK_SUMMARIZATION: shortDescription: Summarization is the task of producing a shorter version of a document while preserving its important information. description: Summarization is the task of producing a shorter version of a document while preserving its important information. Some models can extract @@ -730,77 +678,59 @@ TASK_SUMMARIZATION: properties: max-length: description: Integer to define the maximum length in tokens of the output summary. - acceptFormats: - - integer + type: integer uiOrder: 0 title: Max Length - format: integer max-time: - acceptFormats: - - number - - integer + type: number uiOrder: 1 maximum: 120.0 minimum: 0.0 description: The amount of time in seconds that the query should take maximum. Network can cause some overhead so it will be a soft limit. title: Max Time - format: number min-length: description: Integer to define the minimum length in tokens of the output summary. - acceptFormats: - - integer + type: integer uiOrder: 2 title: Min Length - format: integer repetition-penalty: description: The more a token is used within generation the more it is penalized to not be picked in successive generation passes. - acceptFormats: - - number - - integer + type: number uiOrder: 3 maximum: 100.0 minimum: 0.0 title: Repetition Penalty - format: number temperature: default: 1.0 description: The temperature of the sampling operation. 1 means regular sampling, 0 means always take the highest score, 100.0 is getting closer to uniform probability. - acceptFormats: - - number - - integer + type: number shortDescription: The temperature of the sampling operation. uiOrder: 4 maximum: 100.0 minimum: 0.0 title: Temperature - format: number top-k: description: Integer to define the top tokens considered within the sample operation to create new text. - acceptFormats: - - integer + type: integer uiOrder: 5 title: Top K - format: integer top-p: description: Float to define the tokens that are within the sample operation of text generation. Add tokens in the sample for more probable to least probable until the sum of the probabilities is greater than top-p. - acceptFormats: - - number - - integer + type: number shortDescription: Float to define the tokens that are within the sample operation of text generation. uiOrder: 6 title: Top P - format: number required: [] description: Parameters. title: Parameters - format: object + type: object required: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -808,11 +738,11 @@ TASK_SUMMARIZATION: description: The string after summarization. uiOrder: 0 title: Summary Text - format: string + type: string required: - summary-text title: Output - format: object + type: object TASK_TABLE_QUESTION_ANSWERING: shortDescription: Table Question Answering (Table QA) is the answering a question about an information on a given table. input: @@ -823,26 +753,22 @@ TASK_TABLE_QUESTION_ANSWERING: properties: query: description: The query in plain text that you want to ask the table. - acceptFormats: - - string + type: string uiOrder: 0 title: Query - format: string table: description: A table of data represented as a dict of list where entries are headers and the lists are all the values, all lists must have the same size. - acceptFormats: - - '*' + type: object uiOrder: 1 required: [] title: Table - format: object required: - query - table description: Inputs. title: Inputs - format: object + type: object model: $ref: '#/$defs/model' uiOrder: 0 @@ -853,7 +779,7 @@ TASK_TABLE_QUESTION_ANSWERING: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -861,21 +787,21 @@ TASK_TABLE_QUESTION_ANSWERING: description: The aggregator used to get the answer. uiOrder: 0 title: Aggregator - format: string + type: string answer: description: The plaintext answer. uiOrder: 1 title: Answer - format: string + type: string cells: description: a list of coordinates of the cells contents. uiOrder: 2 items: description: coordinate of the cell content. title: Cell - format: string + type: string title: Cells - format: array + type: array coordinates: description: a list of coordinates of the cells referenced in the answer. uiOrder: 3 @@ -883,14 +809,14 @@ TASK_TABLE_QUESTION_ANSWERING: items: description: coordinate of the cell referenced in the answer. title: Coordinate - format: integer - format: array + type: integer + type: array title: Coordinates - format: array + type: array required: - answer title: Output - format: object + type: object TASK_TEXT_CLASSIFICATION: shortDescription: Text Classification is the task of assigning a label or class to a given text. description: Text Classification is the task of assigning a label or class to a given text. Some use cases are sentiment analysis, natural language inference, @@ -911,7 +837,7 @@ TASK_TEXT_CLASSIFICATION: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -923,25 +849,25 @@ TASK_TEXT_CLASSIFICATION: description: The label for the class (model specific). uiOrder: 0 title: Label - format: string + type: string score: description: A floats that represents how likely is that the text belongs the this class. uiOrder: 1 title: Score - format: number + type: number required: - label - score description: Result. title: Result - format: object + type: object description: Results. title: Results - format: array + type: array required: - results title: Output - format: object + type: object TASK_TEXT_GENERATION: shortDescription: Generating text is the task of producing new text. These models can, for example, fill in incomplete text or paraphrase. description: Generating text is the task of producing new text. These models can, for example, fill in incomplete text or paraphrase. @@ -962,88 +888,66 @@ TASK_TEXT_GENERATION: properties: do-sample: description: Whether or not to use sampling, use greedy decoding otherwise. - acceptFormats: - - boolean + type: boolean uiOrder: 0 title: Do Sample - format: boolean max-new-tokens: description: The amount of new tokens to be generated, this does not include the input length it is a estimate of the size of generated text you want. Each new tokens slows down the request, so look for balance between response times and length of text generated. - acceptFormats: - - integer + type: integer shortDescription: The amount of new tokens to be generated. uiOrder: 1 title: Max New Tokens - format: integer max-time: description: The amount of time in seconds that the query should take maximum. Network can cause some overhead so it will be a soft limit. Use that in combination with max-new-tokens for best results. - acceptFormats: - - number - - integer + type: number shortDescription: The amount of time in seconds that the query should take maximum. uiOrder: 2 title: Max Time - format: number num-return-sequences: description: The number of proposition you want to be returned. - acceptFormats: - - integer + type: integer uiOrder: 3 title: Num Return Sequences - format: integer repetition-penalty: description: The more a token is used within generation the more it is penalized to not be picked in successive generation passes. - acceptFormats: - - number - - integer + type: number uiOrder: 4 title: Repetition Penalty - format: number return-full-text: description: If set to False, the return results will not contain the original query making it easier for prompting. - acceptFormats: - - boolean + type: boolean uiOrder: 5 title: Return Full Text - format: boolean temperature: description: The temperature of the sampling operation. 1 means regular sampling, 0 means always take the highest score, 100.0 is getting closer to uniform probability. - acceptFormats: - - number - - integer + type: number shortDescription: The temperature of the sampling operation. uiOrder: 6 title: Temperature - format: number top-k: description: Integer to define the top tokens considered within the sample operation to create new text. - acceptFormats: - - integer + type: integer uiOrder: 7 title: Top K - format: integer top-p: description: Float to define the tokens that are within the sample operation of text generation. Add tokens in the sample for more probable to least probable until the sum of the probabilities is greater than top-p. - acceptFormats: - - number - - integer + type: number shortDescription: Float to define the tokens that are within the sample operation of text generation. uiOrder: 8 title: Top P - format: number required: [] description: Parameters. title: Parameters - format: object + type: object required: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -1051,11 +955,11 @@ TASK_TEXT_GENERATION: description: The continuated string. uiOrder: 1 title: Generated Text - format: string + type: string required: - generated-text title: Output - format: object + type: object TASK_TEXT_TO_IMAGE: shortDescription: Generates images from input text. description: Generates images from input text. These models can be used to generate and modify images based on text prompts. @@ -1076,49 +980,38 @@ TASK_TEXT_TO_IMAGE: properties: guidance-scale: description: Guidance scale. - acceptFormats: - - number - - integer + type: number uiOrder: 0 title: Guidance Scale - format: number height: description: Image Height. - acceptFormats: - - integer + type: integer uiOrder: 1 title: Height - format: integer negative-prompt: description: Negative prompt for generating the image. - acceptFormats: - - string + type: string uiOrder: 2 title: Negative Prompt - format: string num-inference-steps: description: Number of inference steps. - acceptFormats: - - integer + type: integer uiOrder: 3 title: Num Inference Steps - format: integer width: description: Image width. - acceptFormats: - - integer + type: integer uiOrder: 4 title: Width - format: integer required: [] description: Parameters. title: Parameters - format: object + type: object required: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -1126,11 +1019,11 @@ TASK_TEXT_TO_IMAGE: uiOrder: 0 description: Image. title: Image - format: image/jpeg + type: image/jpeg required: - image title: Output - format: object + type: object TASK_TOKEN_CLASSIFICATION: shortDescription: Token classification is a natural language understanding task in which a label is assigned to some tokens in a text. description: Token classification is a natural language understanding task in which a label is assigned to some tokens in a text. Some popular token classification @@ -1152,28 +1045,32 @@ TASK_TOKEN_CLASSIFICATION: uiOrder: 2 properties: aggregation-strategy: - description: |- - There are several aggregation strategies: + description: 'There are several aggregation strategies: + none: Every token gets classified without further aggregation. + simple: Entities are grouped according to the default schema (B-, I- tags get merged when the tag is similar). - first: Same as the simple strategy except words cannot end up with different tags. Words will use the tag of the first token when there is ambiguity. - average: Same as the simple strategy except words cannot end up with different tags. Scores are averaged across tokens and then the maximum label is applied. - max: Same as the simple strategy except words cannot end up with different tags. Word entity will be the token with the maximum score. - acceptFormats: - - string + + first: Same as the simple strategy except words cannot end up with different tags. Words will use the tag of the first token when there is + ambiguity. + + average: Same as the simple strategy except words cannot end up with different tags. Scores are averaged across tokens and then the maximum + label is applied. + + max: Same as the simple strategy except words cannot end up with different tags. Word entity will be the token with the maximum score.' + type: string shortDescription: 'There are several aggregation strategies: none, simple, first, average, and max.' uiOrder: 0 title: Aggregation Strategy - format: string required: [] description: Parameters. title: Parameters - format: object + type: object required: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -1185,37 +1082,37 @@ TASK_TOKEN_CLASSIFICATION: description: The offset stringwise where the answer is located. Useful to disambiguate if word occurs multiple times. uiOrder: 0 title: End - format: integer + type: integer entity-group: description: The type for the entity being recognized (model specific). uiOrder: 1 title: Entity Group - format: string + type: string score: description: How likely the entity was recognized. uiOrder: 2 title: Score - format: number + type: number start: description: The offset stringwise where the answer is located. Useful to disambiguate if word occurs multiple times. uiOrder: 3 title: Start - format: integer + type: integer word: description: The string that was captured. uiOrder: 4 title: Word - format: string + type: string required: [] title: Result - format: object + type: object description: Results. title: Results - format: array + type: array required: - results title: Output - format: object + type: object TASK_TRANSLATION: shortDescription: Translation is the task of converting text from one language to another. input: @@ -1234,7 +1131,7 @@ TASK_TRANSLATION: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -1242,11 +1139,11 @@ TASK_TRANSLATION: description: The string after translation. uiOrder: 0 title: Translation Text - format: string + type: string required: - translation-text title: Output - format: object + type: object TASK_ZERO_SHOT_CLASSIFICATION: shortDescription: Zero-shot text classification is a task in natural language processing where a model is trained on a set of labeled examples but is then able to classify new examples from previously unseen classes. @@ -1274,26 +1171,24 @@ TASK_ZERO_SHOT_CLASSIFICATION: items: description: a string that are potential class for inputs. title: candidate-label - format: string + type: string title: Candidate Labels - format: array + type: array multi-label: description: Boolean that is set to True if classes can overlap. - acceptFormats: - - boolean + type: boolean uiOrder: 1 title: Multi Label - format: boolean required: - candidate-labels description: Parameters. title: Parameters - format: object + type: object required: - inputs - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -1303,25 +1198,25 @@ TASK_ZERO_SHOT_CLASSIFICATION: items: description: The string for label that you sent (in order). title: Label - format: string + type: string title: Labels - format: array + type: array scores: description: a list of floats that correspond the the probability of label, in the same order as labels. uiOrder: 0 items: description: float that correspond the the probability of label. title: Score - format: number + type: number title: Scores - format: array + type: array sequence: description: The string sent as an input. uiOrder: 1 title: Sequence - format: string + type: string required: - labels - scores title: Output - format: object + type: object diff --git a/pkg/component/ai/instill/v0/README.mdx b/pkg/component/ai/instill/v0/README.mdx index a017cabca..2d1944076 100644 --- a/pkg/component/ai/instill/v0/README.mdx +++ b/pkg/component/ai/instill/v0/README.mdx @@ -46,7 +46,7 @@ Classify images into predefined categories.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CLASSIFICATION` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | @@ -60,7 +60,7 @@ Classify images into predefined categories.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Category | `category` | string | The predicted category of the input. | | Score | `score` | number | The confidence score of the predicted category of the input. | @@ -73,7 +73,7 @@ Detect, localize and delineate multiple objects in images.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INSTANCE_SEGMENTATION` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | @@ -87,7 +87,7 @@ Detect, localize and delineate multiple objects in images.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Objects](#instance-segmentation-objects) | `objects` | array[object] | A list of detected instance bounding boxes. |
@@ -99,7 +99,7 @@ Detect, localize and delineate multiple objects in images.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Bounding Box](#instance-segmentation-bounding-box) | `bounding-box` | object | The detected bounding box in (left, top, width, height) format. | | Category | `category` | string | The predicted category of the bounding box. | @@ -111,7 +111,7 @@ Detect, localize and delineate multiple objects in images.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Height | `height` | number | Bounding box height value | | Left | `left` | number | Bounding box left x-axis value | @@ -127,7 +127,7 @@ Detect and localize multiple keypoints of objects in images.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_KEYPOINT` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | @@ -141,7 +141,7 @@ Detect and localize multiple keypoints of objects in images.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Objects](#keypoint-objects) | `objects` | array[object] | A list of keypoint objects, a keypoint object includes all the pre-defined keypoints of a detected object. |
@@ -153,7 +153,7 @@ Detect and localize multiple keypoints of objects in images.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Bounding Box](#keypoint-bounding-box) | `bounding-box` | object | The detected bounding box in (left, top, width, height) format. | | [Keypoints](#keypoint-keypoints) | `keypoints` | array | A keypoint group is composed of a list of pre-defined keypoints of a detected object. | @@ -164,7 +164,7 @@ Detect and localize multiple keypoints of objects in images.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Visibility Score | `v` | number | visibility score of the keypoint. | | X Coordinate | `x` | number | x coordinate of the keypoint. | @@ -175,7 +175,7 @@ Detect and localize multiple keypoints of objects in images.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Height | `height` | number | Bounding box height value | | Left | `left` | number | Bounding box left x-axis value | @@ -191,7 +191,7 @@ Detect and localize multiple objects in images.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DETECTION` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | @@ -205,7 +205,7 @@ Detect and localize multiple objects in images.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Objects](#detection-objects) | `objects` | array[object] | A list of detected objects. |
@@ -217,7 +217,7 @@ Detect and localize multiple objects in images.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Bounding box](#detection-bounding-box) | `bounding-box` | object | The detected bounding box in (left, top, width, height) format. | | Category | `category` | string | The predicted category of the bounding box. | @@ -228,7 +228,7 @@ Detect and localize multiple objects in images.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Height | `height` | number | Bounding box height value | | Left | `left` | number | Bounding box left x-axis value | @@ -244,7 +244,7 @@ Detect and recognize text in images.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_OCR` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | @@ -258,7 +258,7 @@ Detect and recognize text in images.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Objects](#ocr-objects) | `objects` | array[object] | A list of detected bounding boxes. |
@@ -270,7 +270,7 @@ Detect and recognize text in images.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Bounding Box](#ocr-bounding-box) | `bounding-box` | object | The detected bounding box in (left, top, width, height) format. | | Score | `score` | number | The confidence score of the predicted object. | @@ -281,7 +281,7 @@ Detect and recognize text in images.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Height | `height` | number | Bounding box height value | | Left | `left` | number | Bounding box left x-axis value | @@ -297,7 +297,7 @@ Classify image pixels into predefined categories.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEMANTIC_SEGMENTATION` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | @@ -311,7 +311,7 @@ Classify image pixels into predefined categories.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Stuffs](#semantic-segmentation-stuffs) | `stuffs` | array[object] | A list of RLE binary masks. |
@@ -323,7 +323,7 @@ Classify image pixels into predefined categories.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Category | `category` | string | Category text string corresponding to each stuff mask. | | RLE | `rle` | string | Run Length Encoding (RLE) of each stuff mask within the image. | @@ -337,7 +337,7 @@ Generate texts from input text prompts.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_GENERATION` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | @@ -355,7 +355,7 @@ Generate texts from input text prompts.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Text. |
@@ -367,14 +367,14 @@ Generate texts from input text prompts and chat history.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_GENERATION_CHAT` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | | Prompt (required) | `prompt` | string | The prompt text. | | System Message | `system-message` | string | The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is using a generic message as "You are a helpful assistant.". | | Prompt Images | `prompt-images` | array[string] | The prompt images. | -| [Chat History](#text-generation-chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | +| [Chat History](#text-generation-chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | | Seed | `seed` | integer | The seed. | | Temperature | `temperature` | number | The temperature for sampling. | | Max New Tokens | `max-new-tokens` | integer | The maximum number of tokens for model to generate. | @@ -386,11 +386,11 @@ Generate texts from input text prompts and chat history.

Chat History

-Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. +Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#text-generation-chat-content) | `content` | array | The message content. | | Role | `role` | string | The message role, i.e. 'system', 'user' or 'assistant'. | @@ -401,7 +401,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#text-generation-chat-image-url) | `image-url` | object | The image URL | | Text | `text` | string | The text content. | @@ -413,7 +413,7 @@ The image URL
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
@@ -423,7 +423,7 @@ The image URL
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Text. |
@@ -435,7 +435,7 @@ Generate images from input text prompts.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_TO_IMAGE` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | @@ -453,7 +453,7 @@ Generate images from input text prompts.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Images | `images` | array[image/jpeg] | Images. |
@@ -465,14 +465,14 @@ Answer questions based on a prompt and an image.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_VISUAL_QUESTION_ANSWERING` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | | Prompt (required) | `prompt` | string | The prompt text. | | System Message | `system-message` | string | The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is using a generic message as "You are a helpful assistant.". | | Prompt Images | `prompt-images` | array[string] | The prompt images. | -| [Chat History](#visual-question-answering-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | +| [Chat History](#visual-question-answering-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | | Seed | `seed` | integer | The seed. | | Temperature | `temperature` | number | The temperature for sampling. | | Max New Tokens | `max-new-tokens` | integer | The maximum number of tokens for model to generate. | @@ -484,11 +484,11 @@ Answer questions based on a prompt and an image.

Chat History

-Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. +Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#visual-question-answering-content) | `content` | array | The message content. | | Role | `role` | string | The message role, i.e. 'system', 'user' or 'assistant'. | @@ -499,7 +499,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#visual-question-answering-image-url) | `image-url` | object | The image URL | | Text | `text` | string | The text content. | @@ -511,7 +511,7 @@ The image URL
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
@@ -521,7 +521,7 @@ The image URL
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Text. |
@@ -533,14 +533,14 @@ Generate texts from input text prompts and chat history.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CHAT` | | Model Name (required) | `model-name` | string | The Instill Model model to be used. | | Prompt (required) | `prompt` | string | The prompt text. | | System Message | `system-message` | string | The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is using a generic message as "You are a helpful assistant.". | | Prompt Images | `prompt-images` | array[string] | The prompt images. | -| [Chat History](#chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | +| [Chat History](#chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | | Seed | `seed` | integer | The seed. | | Temperature | `temperature` | number | The temperature for sampling. | | Max New Tokens | `max-new-tokens` | integer | The maximum number of tokens for model to generate. | @@ -552,11 +552,11 @@ Generate texts from input text prompts and chat history.

Chat History

-Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. +Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#chat-content) | `content` | array | The message content. | | Role | `role` | string | The message role, i.e. 'system', 'user' or 'assistant'. | @@ -567,7 +567,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#chat-image-url) | `image-url` | object | The image URL | | Text | `text` | string | The text content. | @@ -579,7 +579,7 @@ The image URL
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
@@ -589,7 +589,7 @@ The image URL
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Text. |
@@ -601,7 +601,7 @@ This task refers to the process of generating vector embeddings from input data,
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_EMBEDDING` | | [Data](#embedding-data) (required) | `data` | object | Input data. | @@ -618,7 +618,7 @@ Input data.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Embeddings](#embedding-embeddings) | `embeddings` | array | List of input data to be embedded. | | Model | `model` | string | The model to be used for generating embeddings. It should be `namespace/model-name/version`. i.e. `abrc/yolov7-stomata/v0.1.0`. You can see the version from the Versions tab of Model page. | @@ -629,7 +629,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Dimensions | `dimensions` | integer | Number of dimensions in the output embedding vectors. | | Data Format | `format` | string | The data format of the embeddings. Defaults to float.
Enum values
  • `float`
  • `base64`
| @@ -649,7 +649,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Text Content | `text` | string | When the input is text, the raw text is tokenized and processed into a dense, fixed-length vector that captures semantic information such as word meanings and relationships. These text embeddings enable tasks like sentiment analysis, search, or classification. | | Text | `type` | string | Must be `"text"` | @@ -659,7 +659,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Image URL | `image-url` | string | When the input is an image from a URL, the image is first fetched from the URL and then decoded into its original format. It is then processed into a fixed-length vector representing essential visual features like shapes and colors. These image embeddings are useful for tasks like image classification or similarity search, providing structured numerical data for complex visual inputs. | | Image URL | `type` | string | Must be `"image-url"` | @@ -669,7 +669,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Image File | `image-base64` | string | When the input is an image in base64 format, the base64-encoded data is first decoded into its original image form. The image is then processed and transformed into a dense, fixed-length numerical vector, capturing key visual features like shapes, colors, or textures. | | Image File | `type` | string | Must be `"image-base64"` | @@ -678,7 +678,7 @@ Input parameter.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Data](#embedding-data) | `data` | object | Output data. |
@@ -690,7 +690,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Embeddings](#embedding-embeddings) | `embeddings` | array | List of generated embeddings. |
@@ -699,7 +699,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Created | `created` | integer | The Unix timestamp (in seconds) of when the embedding was created. | | Index | `index` | integer | The index of the embedding vector in the array. | diff --git a/pkg/component/ai/instill/v0/config/tasks.yaml b/pkg/component/ai/instill/v0/config/tasks.yaml index db96a4381..9059c08fb 100644 --- a/pkg/component/ai/instill/v0/config/tasks.yaml +++ b/pkg/component/ai/instill/v0/config/tasks.yaml @@ -10,101 +10,97 @@ $defs: description: The message role, i.e. 'system', 'user' or 'assistant'. uiOrder: 0 title: Role - format: string + type: string required: - role - content title: Chat Message - format: object + type: object common: description: Input. uiOrder: 0 properties: image-base64: description: Image base64. - acceptFormats: - - image/* + type: string uiOrder: 2 title: Image - format: string model-name: description: The Instill Model model to be used. - acceptFormats: - - string + type: string uiOrder: 0 title: Model Name - format: string required: - image-base64 - model-name title: Input - format: object + type: object TASK_CLASSIFICATION: shortDescription: Classify images into predefined categories. input: $ref: '#/$defs/common' - format: object + type: object output: $ref: schema.yaml#/$defs/instill-types/classification description: Output. uiOrder: 0 title: Output - format: object + type: object TASK_DETECTION: shortDescription: Detect and localize multiple objects in images. input: $ref: '#/$defs/common' - format: object + type: object output: $ref: schema.yaml#/$defs/instill-types/detection description: Output. uiOrder: 0 title: Output - format: object + type: object TASK_INSTANCE_SEGMENTATION: shortDescription: Detect, localize and delineate multiple objects in images. input: $ref: '#/$defs/common' - format: object + type: object output: $ref: schema.yaml#/$defs/instill-types/instance-segmentation description: Output. uiOrder: 0 title: Output - format: object + type: object TASK_KEYPOINT: shortDescription: Detect and localize multiple keypoints of objects in images. input: $ref: '#/$defs/common' - format: object + type: object output: $ref: schema.yaml#/$defs/instill-types/keypoint description: Output. uiOrder: 0 title: Output - format: object + type: object TASK_OCR: shortDescription: Detect and recognize text in images. input: $ref: '#/$defs/common' - format: object + type: object output: $ref: schema.yaml#/$defs/instill-types/ocr description: Output. uiOrder: 0 title: Output - format: object + type: object TASK_SEMANTIC_SEGMENTATION: shortDescription: Classify image pixels into predefined categories. input: $ref: '#/$defs/common' - format: object + type: object output: $ref: schema.yaml#/$defs/instill-types/semantic-segmentation description: Output. uiOrder: 0 title: Output - format: object + type: object TASK_TEXT_GENERATION: shortDescription: Generate texts from input text prompts. input: @@ -114,56 +110,44 @@ TASK_TEXT_GENERATION: max-new-tokens: default: 50 description: The maximum number of tokens for model to generate. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Max New Tokens - format: integer model-name: description: The Instill Model model to be used. - acceptFormats: - - string + type: string uiOrder: 0 title: Model Name - format: string prompt: description: The prompt text. - acceptFormats: - - string + type: string uiOrder: 2 title: Prompt - format: string seed: description: The seed. - acceptFormats: - - integer + type: integer uiOrder: 4 title: Seed - format: integer system-message: default: You are a helpful assistant. description: The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is using a generic message as "You are a helpful assistant.". - acceptFormats: - - string + type: string shortDescription: The system message helps set the behavior of the assistant uiOrder: 2 title: System Message - format: string temperature: default: 0.7 description: The temperature for sampling. - acceptFormats: - - number + type: number uiOrder: 5 title: Temperature - format: number required: - prompt - model-name title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -172,11 +156,11 @@ TASK_TEXT_GENERATION: description: Text. uiOrder: 0 title: Text - format: string + type: string required: - text title: Output - format: object + type: object TASK_TEXT_GENERATION_CHAT: shortDescription: Generate texts from input text prompts and chat history. input: @@ -185,80 +169,64 @@ TASK_TEXT_GENERATION_CHAT: properties: chat-history: description: 'Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be - ignored and will not have any effect when this field is populated. Each message should adhere to the format: : {"role": "The message role, i.e. + ignored and will not have any effect when this field is populated. Each message should adhere to the format: {"role": "The message role, i.e. ''system'', ''user'' or ''assistant''", "content": "message content"}.' - acceptFormats: - - object + type: array shortDescription: 'Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will - be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : {"role": "The message role, - i.e. ''system'', ''user'' or ''assistant''", "content": "message content"}.' + be ignored and will not have any effect when this field is populated. Each message should adhere to the format: {"role": "The message role, i.e. + ''system'', ''user'' or ''assistant''", "content": "message content"}.' uiOrder: 4 items: $ref: '#/$defs/chat-message' title: Chat history - format: array max-new-tokens: default: 50 description: The maximum number of tokens for model to generate. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Max New Tokens - format: integer model-name: description: The Instill Model model to be used. - acceptFormats: - - string + type: string uiOrder: 0 title: Model Name - format: string prompt: description: The prompt text. - acceptFormats: - - string + type: string uiOrder: 2 title: Prompt - format: string prompt-images: description: The prompt images. - acceptFormats: - - array + type: array uiOrder: 3 items: - format: string + type: string title: Prompt Images - format: array seed: description: The seed. - acceptFormats: - - integer + type: integer uiOrder: 4 title: Seed - format: integer system-message: default: You are a helpful assistant. description: The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is using a generic message as "You are a helpful assistant.". - acceptFormats: - - string + type: string shortDescription: The system message helps set the behavior of the assistant uiOrder: 2 title: System Message - format: string temperature: default: 0.7 description: The temperature for sampling. - acceptFormats: - - number + type: number uiOrder: 5 title: Temperature - format: number required: - prompt - model-name title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -267,11 +235,11 @@ TASK_TEXT_GENERATION_CHAT: description: Text. uiOrder: 0 title: Text - format: string + type: string required: - text title: Output - format: object + type: object TASK_TEXT_TO_IMAGE: shortDescription: Generate images from input text prompts. input: @@ -280,46 +248,35 @@ TASK_TEXT_TO_IMAGE: properties: model-name: description: The Instill Model model to be used. - acceptFormats: - - string + type: string uiOrder: 0 title: Model Name - format: string prompt: description: The prompt text. - acceptFormats: - - string + type: string uiOrder: 2 title: Prompt - format: string samples: description: The number of generated samples, default is 1. - acceptFormats: - - integer + type: integer uiOrder: 5 title: Samples - format: integer seed: description: The seed, default is 0. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Seed - format: integer negative-prompt: title: Aspect ratio description: Keywords of what you do not wish to see in the output image. shortDescription: Keywords of what you do not wish to see in the output image. - acceptFormats: - - string + type: string uiOrder: 7 - format: string aspect-ratio: title: Aspect ratio description: Controls the aspect ratio of the generated image. Defaults to 1:1. shortDescription: Controls the aspect ratio of the generated image. Defaults to 1:1. - acceptFormats: - - string + type: string uiOrder: 8 default: '1:1' enum: @@ -332,12 +289,11 @@ TASK_TEXT_TO_IMAGE: - '5:4' - '9:16' - '9:21' - format: string required: - prompt - model-name title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -347,13 +303,13 @@ TASK_TEXT_TO_IMAGE: uiOrder: 0 items: title: Image - format: image/jpeg + type: image/jpeg title: Images - format: array + type: array required: - images title: Output - format: object + type: object TASK_VISUAL_QUESTION_ANSWERING: shortDescription: Answer questions based on a prompt and an image. $ref: '#/TASK_TEXT_GENERATION_CHAT' @@ -378,11 +334,9 @@ TASK_EMBEDDING: description: The model to be used for generating embeddings. It should be `namespace/model-name/version`. i.e. `abrc/yolov7-stomata/v0.1.0`. You can see the version from the Versions tab of Model page. shortDescription: The model to be used. - acceptFormats: - - string + type: string uiOrder: 0 title: Model - format: string embeddings: title: Embeddings items: @@ -393,24 +347,20 @@ TASK_EMBEDDING: description: When the input is text, the raw text is tokenized and processed into a dense, fixed-length vector that captures semantic information such as word meanings and relationships. These text embeddings enable tasks like sentiment analysis, search, or classification. shortDescription: Text content. - acceptFormats: - - string + type: string uiOrder: 1 - format: string type: title: Text description: Text input content type. shortDescription: Text input content type. - acceptFormats: - - string + type: string const: text uiOrder: 0 - format: string title: Text required: - text - type - format: object + type: object - properties: image-url: title: Image URL @@ -418,24 +368,20 @@ TASK_EMBEDDING: It is then processed into a fixed-length vector representing essential visual features like shapes and colors. These image embeddings are useful for tasks like image classification or similarity search, providing structured numerical data for complex visual inputs. shortDescription: Image content URL. - acceptFormats: - - string + type: string uiOrder: 1 - format: string type: title: Image URL description: Image URL input content type. shortDescription: Image URL input content type - acceptFormats: - - string + type: string const: image-url uiOrder: 0 - format: string title: Image URL required: - image-url - type - format: object + type: object - properties: image-base64: title: Image File @@ -443,39 +389,35 @@ TASK_EMBEDDING: image is then processed and transformed into a dense, fixed-length numerical vector, capturing key visual features like shapes, colors, or textures. shortDescription: Image file input. - acceptFormats: - - image/* + type: string uiOrder: 1 - format: string type: title: Image File description: Image file input content type. shortDescription: Image file input content type. - acceptFormats: - - string + type: string const: image-base64 uiOrder: 0 - format: string title: Image Base64 required: - image-base64 - type - format: object + type: object title: Embedding description: Input data to be embedded. uiOrder: 0 required: - type - format: object + type: object description: List of input data to be embedded. uiOrder: 1 - format: array + type: array required: - model - embeddings uiOrder: 0 title: Data - format: object + type: object parameter: description: Input parameter. shortDescription: Input parameter. @@ -484,51 +426,43 @@ TASK_EMBEDDING: title: Data Format description: The data format of the embeddings. Defaults to float. shortDescription: Data format - acceptFormats: - - string + type: string enum: - float - base64 default: float uiOrder: 0 - format: string dimensions: title: Dimensions description: Number of dimensions in the output embedding vectors. shortDescription: Number of dimensions - acceptFormats: - - integer + type: integer default: 512 uiOrder: 1 - format: integer input-type: title: Input Type description: The type of input data to be embedded (e.g., query, document). shortDescription: Type of input data - acceptFormats: - - string + type: string uiOrder: 2 - format: string truncate: title: Truncate description: How to handle inputs longer than the max token length. Defaults to 'End'. shortDescription: Truncation handling - acceptFormats: - - string + type: string enum: - None - End - Start default: End uiOrder: 3 - format: string title: Parameter uiOrder: 1 required: [] - format: object + type: object required: - data - format: object + type: object output: title: Embedding Output description: Output schema of the embedding task. @@ -549,33 +483,33 @@ TASK_EMBEDDING: description: The index of the embedding vector in the array. shortDescription: Index in the array uiOrder: 0 - format: integer + type: integer vector: title: Embedding Vector description: The embedding vector. shortDescription: Embedding vector. items: - format: number + type: number uiOrder: 1 - format: array + type: array created: title: Created description: The Unix timestamp (in seconds) of when the embedding was created. shortDescription: Timestamp of creation uiOrder: 2 - format: integer + type: integer required: - index - vector - created - format: object + type: object uiOrder: 0 - format: array + type: array required: - embeddings uiOrder: 0 title: Data - format: object + type: object required: - data - format: object + type: object diff --git a/pkg/component/ai/mistralai/v0/.compogen/bottom.mdx b/pkg/component/ai/mistralai/v0/.compogen/bottom.mdx index 77e3694ce..613207c07 100644 --- a/pkg/component/ai/mistralai/v0/.compogen/bottom.mdx +++ b/pkg/component/ai/mistralai/v0/.compogen/bottom.mdx @@ -40,32 +40,32 @@ variable: conflict: title: Conflict description: The main problem or challenge faced by the characters i.e. existential crisis - format: string + type: string duration: title: Duration description: Approximate length of the film in minutes i.e. 5 - format: string + type: string genre: title: Genre description: The type of genre for this film i.e. romance, comedy, horror, action, etc. - format: string + type: string num_actors: title: Num_actors description: The number of actors that will be in this film i.e. 2 - format: string + type: string setting: title: Setting description: | The primary location where the story takes place i.e. Rome - format: string + type: string theme: title: Theme description: Insert the main theme or central idea of the film i.e. time travelling - format: string + type: string time-period: title: Time Period description: The era or time frame of the story i.e. stone age, 20th century, etc. - format: string + type: string output: result: title: Result @@ -128,17 +128,17 @@ variable: colour: title: Colour description: Describe the main colour to use i.e. blue, random - format: string + type: string instill-ui-order: 1 period: title: Period description: | Input different Picasso periods i.e. Blue, Rose, African, Synthetic Cubism, etc. - format: string + type: string prompt: title: Prompt description: Input prompt here i.e. "A cute baby wombat" - format: string + type: string output: image: title: Image diff --git a/pkg/component/ai/mistralai/v0/README.mdx b/pkg/component/ai/mistralai/v0/README.mdx index c5e805aca..1ea7713f9 100644 --- a/pkg/component/ai/mistralai/v0/README.mdx +++ b/pkg/component/ai/mistralai/v0/README.mdx @@ -37,7 +37,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key | `api-key` | string | Fill in your Mistral API key. To find your keys, visit the Mistral AI platform page. | @@ -55,14 +55,14 @@ Mistral AI's text generation models (often called generative pre-trained transfo
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_GENERATION_CHAT` | | Model Name (required) | `model-name` | string | The Mistral model to be used.
Enum values
  • `open-mixtral-8x22b`
  • `open-mixtral-8x7b`
  • `open-mistral-7b`
  • `mistral-large-latest`
  • `mistral-small-latest`
  • `codestral-latest`
| | Prompt (required) | `prompt` | string | The prompt text. | | System Message | `system-message` | string | The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is set using a generic message as "You are a helpful assistant.". | | Prompt Images | `prompt-images` | array[string] | The prompt images (Note: The Mistral models are not trained to process images, thus images will be omitted). | -| [Chat History](#text-generation-chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | +| [Chat History](#text-generation-chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | | Seed | `seed` | integer | The seed. | | Temperature | `temperature` | number | The temperature for sampling. | | Top K | `top-k` | integer | Integer to define the top tokens considered within the sample operation to create new text (Note: The Mistral models does not support top-k sampling). | @@ -77,11 +77,11 @@ Mistral AI's text generation models (often called generative pre-trained transfo

Chat History

-Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. +Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#text-generation-chat-content) | `content` | array | The message content. | | Role | `role` | string | The message role, i.e. 'system', 'user' or 'assistant'. | @@ -92,7 +92,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#text-generation-chat-image-url) | `image-url` | object | The image URL. | | Text | `text` | string | The text content. | @@ -104,7 +104,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
@@ -114,7 +114,7 @@ The image URL.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Model Output. | | [Usage](#text-generation-chat-usage) (optional) | `usage` | object | Token usage on the Mistral platform text generation models. | @@ -127,7 +127,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Input Tokens | `input-tokens` | number | The input tokens used by Mistral models. | | Output Tokens | `output-tokens` | number | The output tokens generated by Mistral models. | @@ -141,7 +141,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_EMBEDDINGS` | | Model Name (required) | `model-name` | string | The Mistral embed model to be used.
Enum values
  • `mistral-embed`
| @@ -155,7 +155,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Embedding | `embedding` | array[number] | Embedding of the input text. | | [Usage](#text-embeddings-usage) (optional) | `usage` | object | Token usage on the Mistral platform embedding models. | @@ -168,7 +168,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Token Count | `tokens` | number | The token count used by Mistral models. |
@@ -218,32 +218,32 @@ variable: conflict: title: Conflict description: The main problem or challenge faced by the characters i.e. existential crisis - format: string + type: string duration: title: Duration description: Approximate length of the film in minutes i.e. 5 - format: string + type: string genre: title: Genre description: The type of genre for this film i.e. romance, comedy, horror, action, etc. - format: string + type: string num_actors: title: Num_actors description: The number of actors that will be in this film i.e. 2 - format: string + type: string setting: title: Setting description: | The primary location where the story takes place i.e. Rome - format: string + type: string theme: title: Theme description: Insert the main theme or central idea of the film i.e. time travelling - format: string + type: string time-period: title: Time Period description: The era or time frame of the story i.e. stone age, 20th century, etc. - format: string + type: string output: result: title: Result @@ -306,17 +306,17 @@ variable: colour: title: Colour description: Describe the main colour to use i.e. blue, random - format: string + type: string instill-ui-order: 1 period: title: Period description: | Input different Picasso periods i.e. Blue, Rose, African, Synthetic Cubism, etc. - format: string + type: string prompt: title: Prompt description: Input prompt here i.e. "A cute baby wombat" - format: string + type: string output: image: title: Image diff --git a/pkg/component/ai/mistralai/v0/config/setup.yaml b/pkg/component/ai/mistralai/v0/config/setup.yaml index f57ec69df..2acbadf51 100644 --- a/pkg/component/ai/mistralai/v0/config/setup.yaml +++ b/pkg/component/ai/mistralai/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: api-key: description: Fill in your Mistral API key. To find your keys, visit the Mistral AI platform page. - acceptFormats: - - string + type: string instillSecret: true instillCredential: true uiOrder: 0 title: API Key - format: string required: [] title: Mistral AI Connection -format: object +type: object diff --git a/pkg/component/ai/mistralai/v0/config/tasks.yaml b/pkg/component/ai/mistralai/v0/config/tasks.yaml index 83f22fb2e..b38990435 100644 --- a/pkg/component/ai/mistralai/v0/config/tasks.yaml +++ b/pkg/component/ai/mistralai/v0/config/tasks.yaml @@ -8,18 +8,18 @@ $defs: description: Either a URL of the image or the base64 encoded image data. title: URL uiOrder: 0 - format: string + type: string required: - url title: Image URL description: The image URL. uiOrder: 0 - format: object + type: object text: description: The text content. title: Text uiOrder: 1 - format: string + type: string type: description: The type of the content part. enum: @@ -27,11 +27,11 @@ $defs: - image_url title: Type uiOrder: 2 - format: string + type: string required: - type - format: object - format: array + type: object + type: array chat-message: properties: content: @@ -43,12 +43,12 @@ $defs: description: The message role, i.e. 'system', 'user' or 'assistant'. uiOrder: 0 title: Role - format: string + type: string required: - role - content title: Chat Message - format: object + type: object chat-usage: description: Token usage on the Mistral platform text generation models. uiOrder: 1 @@ -57,17 +57,17 @@ $defs: description: The input tokens used by Mistral models. uiOrder: 2 title: Input Tokens - format: number + type: number output-tokens: description: The output tokens generated by Mistral models. uiOrder: 3 title: Output Tokens - format: number + type: number required: - input-tokens - output-tokens title: Usage - format: object + type: object embedding-usage: description: Token usage on the Mistral platform embedding models. uiOrder: 1 @@ -76,11 +76,11 @@ $defs: description: The token count used by Mistral models. uiOrder: 1 title: Token Count - format: number + type: number required: - tokens title: Usage - format: object + type: object TASK_TEXT_GENERATION_CHAT: shortDescription: Provide text outputs in response to text inputs. description: Mistral AI's text generation models (often called generative pre-trained transformers or large language models) have been trained to understand @@ -93,25 +93,21 @@ TASK_TEXT_GENERATION_CHAT: properties: chat-history: description: 'Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be - ignored and will not have any effect when this field is populated. Each message should adhere to the format: : {"role": "The message role, i.e. + ignored and will not have any effect when this field is populated. Each message should adhere to the format: {"role": "The message role, i.e. ''system'', ''user'' or ''assistant''", "content": "message content"}.' - acceptFormats: - - object + type: array shortDescription: 'Incorporate external chat history, specifically previous messages within the conversation. (Note: The Mistral models are not trained to process images, thus images will be omitted)' uiOrder: 4 items: $ref: '#/$defs/chat-message' title: Chat history - format: array max-new-tokens: default: 50 description: The maximum number of tokens for model to generate. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Max New Tokens - format: integer model-name: enum: - open-mixtral-8x22b @@ -122,8 +118,7 @@ TASK_TEXT_GENERATION_CHAT: - codestral-latest example: open-mixtral-8x22b description: The Mistral model to be used. - acceptFormats: - - string + type: string uiOrder: 0 instillCredentialMap: values: @@ -136,81 +131,63 @@ TASK_TEXT_GENERATION_CHAT: targets: - setup.api-key title: Model Name - format: string prompt: description: The prompt text. - acceptFormats: - - string + type: string uiOrder: 2 title: Prompt - format: string prompt-images: description: 'The prompt images (Note: The Mistral models are not trained to process images, thus images will be omitted).' - acceptFormats: - - array + type: array uiOrder: 3 items: - format: string + type: string title: Prompt Images - format: array seed: description: The seed. - acceptFormats: - - integer + type: integer uiOrder: 4 title: Seed - format: integer system-message: default: You are a helpful assistant. description: The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is set using a generic message as "You are a helpful assistant.". - acceptFormats: - - string + type: string shortDescription: The system message helps set the behavior of the assistant uiOrder: 2 title: System Message - format: string temperature: default: 0.7 description: The temperature for sampling. - acceptFormats: - - number + type: number uiOrder: 5 title: Temperature - format: number top-k: default: 10 description: 'Integer to define the top tokens considered within the sample operation to create new text (Note: The Mistral models does not support top-k sampling).' - acceptFormats: - - integer + type: integer uiOrder: 5 title: Top K - format: integer top-p: default: 0.5 description: Float to define the tokens that are within the sample operation of text generation. Add tokens in the sample for more probable to least probable until the sum of the probabilities is greater than top-p (default=0.5). - acceptFormats: - - number - - integer + type: number shortDescription: Float to define the tokens that are within the sample operation of text generation uiOrder: 6 title: Top P - format: number safe: description: Safe generation mode. - acceptFormats: - - boolean + type: boolean uiOrder: 7 title: Safe - format: boolean required: - prompt - model-name title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -219,13 +196,13 @@ TASK_TEXT_GENERATION_CHAT: description: Model Output. uiOrder: 0 title: Text - format: string + type: string usage: $ref: '#/$defs/chat-usage' required: - text title: Output - format: object + type: object TASK_TEXT_EMBEDDINGS: shortDescription: Turn text into a vector of numbers that capture its meaning, unlocking use cases like semantic search. description: An embedding is a list of floating point numbers that captures semantic information about the text that it represents. @@ -237,8 +214,7 @@ TASK_TEXT_EMBEDDINGS: - mistral-embed example: mistral-embed description: The Mistral embed model to be used. - acceptFormats: - - string + type: string uiOrder: 0 title: Model Name instillCredentialMap: @@ -246,33 +222,30 @@ TASK_TEXT_EMBEDDINGS: - mistral-embed targets: - setup.api-key - format: string text: description: The text. - acceptFormats: - - string + type: string uiOrder: 1 title: Text - format: string required: - text - model-name title: Input - format: object + type: object output: uiOrder: 0 properties: embedding: items: title: Embedding - format: number + type: number description: Embedding of the input text. uiOrder: 0 title: Embedding - format: array + type: array usage: $ref: '#/$defs/embedding-usage' required: - embedding title: Output - format: object + type: object diff --git a/pkg/component/ai/ollama/v0/README.mdx b/pkg/component/ai/ollama/v0/README.mdx index 5d9f1f464..aebb58e0b 100644 --- a/pkg/component/ai/ollama/v0/README.mdx +++ b/pkg/component/ai/ollama/v0/README.mdx @@ -37,7 +37,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Endpoint (required) | `endpoint` | string | Fill in your Ollama hosting endpoint. ### WARNING ###: As of 2024-07-26, the Ollama component does not support authentication methods. To prevent unauthorized access to your Ollama serving resources, please implement additional security measures such as IP whitelisting. | | Model Auto-Pull (required) | `auto-pull` | boolean | Automatically pull the requested models from the Ollama server if the model is not found in the local cache. | @@ -56,14 +56,14 @@ Open-source large language models (OSS LLMs) are artificial intelligence models
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_GENERATION_CHAT` | | Model Name (required) | `model` | string | The OSS model to be used, check [here](https://ollama.com/library) for list of models available. | | Prompt (required) | `prompt` | string | The prompt text. | | System Message | `system-message` | string | The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is set using a generic message as "You are a helpful assistant.". | | Prompt Images | `prompt-images` | array[string] | The prompt images. | -| [Chat History](#text-generation-chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | +| [Chat History](#text-generation-chat-chat-history) | `chat-history` | array[object] | Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. | | Seed | `seed` | integer | The seed. | | Temperature | `temperature` | number | The temperature for sampling. | | Top K | `top-k` | integer | Top k for sampling. | @@ -76,11 +76,11 @@ Open-source large language models (OSS LLMs) are artificial intelligence models

Chat History

-Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: : \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}. +Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format: \{"role": "The message role, i.e. 'system', 'user' or 'assistant'", "content": "message content"\}.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#text-generation-chat-content) | `content` | array | The message content. | | Role | `role` | string | The message role, i.e. 'system', 'user' or 'assistant'. | @@ -91,7 +91,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#text-generation-chat-image-url) | `image-url` | object | The image URL. | | Text | `text` | string | The text content. | @@ -103,7 +103,7 @@ The image URL.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
@@ -113,7 +113,7 @@ The image URL.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Model Output. |
@@ -138,7 +138,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_EMBEDDINGS` | | Model Name (required) | `model` | string | The OSS model to be used, check [here](https://ollama.com/library) for list of models available. | @@ -152,7 +152,7 @@ An embedding is a list of floating point numbers that captures semantic informat
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Embedding | `embedding` | array[number] | Embedding of the input text. |
diff --git a/pkg/component/ai/ollama/v0/config/setup.yaml b/pkg/component/ai/ollama/v0/config/setup.yaml index 85c2fc46a..6d06edff2 100644 --- a/pkg/component/ai/ollama/v0/config/setup.yaml +++ b/pkg/component/ai/ollama/v0/config/setup.yaml @@ -3,21 +3,17 @@ properties: endpoint: description: 'Fill in your Ollama hosting endpoint. ### WARNING ###: As of 2024-07-26, the Ollama component does not support authentication methods. To prevent unauthorized access to your Ollama serving resources, please implement additional security measures such as IP whitelisting.' - acceptFormats: - - string + type: string default: http://localhost:11434 uiOrder: 0 title: Endpoint - format: string auto-pull: description: Automatically pull the requested models from the Ollama server if the model is not found in the local cache. - acceptFormats: - - boolean + type: boolean uiOrder: 1 title: Model Auto-Pull - format: boolean required: - endpoint - auto-pull title: Ollama Connection -format: object +type: object diff --git a/pkg/component/ai/ollama/v0/config/tasks.yaml b/pkg/component/ai/ollama/v0/config/tasks.yaml index c8fc476b4..c664b10af 100644 --- a/pkg/component/ai/ollama/v0/config/tasks.yaml +++ b/pkg/component/ai/ollama/v0/config/tasks.yaml @@ -8,18 +8,18 @@ $defs: description: Either a URL of the image or the base64 encoded image data. title: URL uiOrder: 0 - format: string + type: string required: - url title: Image URL description: The image URL. uiOrder: 0 - format: object + type: object text: description: The text content. title: Text uiOrder: 1 - format: string + type: string type: description: The type of the content part. enum: @@ -27,11 +27,11 @@ $defs: - image_url title: Type uiOrder: 2 - format: string + type: string required: - type - format: object - format: array + type: object + type: array chat-message: properties: content: @@ -43,12 +43,12 @@ $defs: description: The message role, i.e. 'system', 'user' or 'assistant'. uiOrder: 0 title: Role - format: string + type: string required: - role - content title: Chat Message - format: object + type: object TASK_TEXT_GENERATION_CHAT: shortDescription: Provide text outputs in response to text/image inputs. description: 'Open-source large language models (OSS LLMs) are artificial intelligence models with publicly accessible code and architecture, allowing @@ -60,87 +60,69 @@ TASK_TEXT_GENERATION_CHAT: properties: chat-history: description: 'Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be - ignored and will not have any effect when this field is populated. Each message should adhere to the format: : {"role": "The message role, i.e. + ignored and will not have any effect when this field is populated. Each message should adhere to the format: {"role": "The message role, i.e. ''system'', ''user'' or ''assistant''", "content": "message content"}.' - acceptFormats: - - object + type: array shortDescription: Incorporate external chat history, specifically previous messages within the conversation. uiOrder: 4 items: $ref: '#/$defs/chat-message' title: Chat history - format: array max-new-tokens: default: 50 description: The maximum number of tokens for model to generate. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Max New Tokens - format: integer model: example: moondream description: The OSS model to be used, check [here](https://ollama.com/library) for list of models available. - acceptFormats: - - string + type: string uiOrder: 0 title: Model Name - format: string prompt: description: The prompt text. - acceptFormats: - - string + type: string uiOrder: 2 title: Prompt - format: string prompt-images: description: The prompt images. - acceptFormats: - - array + type: array uiOrder: 3 items: - format: string + type: string title: Prompt Images - format: array seed: description: The seed. - acceptFormats: - - integer + type: integer uiOrder: 4 title: Seed - format: integer system-message: default: You are a helpful assistant. description: The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is set using a generic message as "You are a helpful assistant.". - acceptFormats: - - string + type: string shortDescription: The system message helps set the behavior of the assistant uiOrder: 2 title: System Message - format: string temperature: default: 0.7 description: The temperature for sampling. - acceptFormats: - - number + type: number uiOrder: 5 title: Temperature - format: number top-k: default: 10 description: Top k for sampling. - acceptFormats: - - integer + type: integer uiOrder: 5 title: Top K - format: integer required: - prompt - model title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -149,11 +131,11 @@ TASK_TEXT_GENERATION_CHAT: description: Model Output. uiOrder: 0 title: Text - format: string + type: string required: - text title: Output - format: object + type: object TASK_TEXT_EMBEDDINGS: shortDescription: Turn text into a vector of numbers that capture its meaning, unlocking use cases like semantic search. description: An embedding is a list of floating point numbers that captures semantic information about the text that it represents. @@ -163,34 +145,30 @@ TASK_TEXT_EMBEDDINGS: model: example: snowflake-arctic-embed:22m description: The OSS model to be used, check [here](https://ollama.com/library) for list of models available. - acceptFormats: - - string + type: string uiOrder: 0 title: Model Name - format: string text: description: The text. - acceptFormats: - - string + type: string uiOrder: 1 title: Text - format: string required: - text - model title: Input - format: object + type: object output: uiOrder: 0 properties: embedding: items: - format: number + type: number description: Embedding of the input text. uiOrder: 0 title: Embedding - format: array + type: array required: - embedding title: Output - format: object + type: object diff --git a/pkg/component/ai/openai/v0/.compogen/bottom.mdx b/pkg/component/ai/openai/v0/.compogen/bottom.mdx index 7b24436c3..3a94bdeae 100644 --- a/pkg/component/ai/openai/v0/.compogen/bottom.mdx +++ b/pkg/component/ai/openai/v0/.compogen/bottom.mdx @@ -56,17 +56,17 @@ variable: colour: title: Colour description: Describe the main colour to use i.e. blue, random - format: string + type: string instill-ui-order: 1 period: title: Period description: | Input different Picasso periods i.e. Blue, Rose, African, Synthetic Cubism, etc. - format: string + type: string prompt: title: Prompt description: Input prompt here i.e. "A cute baby wombat" - format: string + type: string output: image: title: Image @@ -98,11 +98,11 @@ variable: language: title: Language description: Input a language i.e. Chinese, Japanese, French, etc. - format: string + type: string prompt: title: Prompt description: Write the topic you want to ask about here i.e. "Tell me about small LLMs" - format: string + type: string output: result: title: Result diff --git a/pkg/component/ai/openai/v0/README.mdx b/pkg/component/ai/openai/v0/README.mdx index 9c7698cf4..87d07510e 100644 --- a/pkg/component/ai/openai/v0/README.mdx +++ b/pkg/component/ai/openai/v0/README.mdx @@ -40,7 +40,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key | `api-key` | string | Fill in your OpenAI API key. To find your keys, visit your OpenAI's API Keys page. | | Organization ID | `organization` | string | Specify which organization is used for the requests. Usage will count against the specified organization's subscription quota. | @@ -59,7 +59,7 @@ OpenAI's text generation models (often called generative pre-trained transformer
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_GENERATION` | | Model (required) | `model` | string | ID of the model to use.
Enum values
  • `o1-preview`
  • `o1-mini`
  • `gpt-4o-mini`
  • `gpt-4o`
  • `gpt-4o-2024-05-13`
  • `gpt-4o-2024-08-06`
  • `gpt-4-turbo`
  • `gpt-4-turbo-2024-04-09`
  • `gpt-4-0125-preview`
  • `gpt-4-turbo-preview`
  • `gpt-4-1106-preview`
  • `gpt-4-vision-preview`
  • `gpt-4`
  • `gpt-4-0314`
  • `gpt-4-0613`
  • `gpt-4-32k`
  • `gpt-4-32k-0314`
  • `gpt-4-32k-0613`
  • `gpt-3.5-turbo`
  • `gpt-3.5-turbo-16k`
  • `gpt-3.5-turbo-0301`
  • `gpt-3.5-turbo-0613`
  • `gpt-3.5-turbo-1106`
  • `gpt-3.5-turbo-0125`
  • `gpt-3.5-turbo-16k-0613`
| @@ -70,7 +70,7 @@ OpenAI's text generation models (often called generative pre-trained transformer | Temperature | `temperature` | number | What sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. We generally recommend altering this or `top-p` but not both. . | | N | `n` | integer | How many chat completion choices to generate for each input message. Note that you will be charged based on the number of generated tokens across all of the choices. Keep `n` as `1` to minimize costs. | | Max Tokens | `max-tokens` | integer | The maximum number of tokens that can be generated in the chat completion. The total length of input tokens and generated tokens is limited by the model's context length. | -| [Response Format](#text-generation-response-format) | `response-format` | object | Response format. | +| [Response Format](#text-generation-response-format) | `response-type` | object | Response format. | | Top P | `top-p` | number | An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered. We generally recommend altering this or `temperature` but not both. . | | Presence Penalty | `presence-penalty` | number | Number between -2.0 and 2.0. Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics. | | Frequency Penalty | `frequency-penalty` | number | Number between -2.0 and 2.0. Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim. | @@ -86,7 +86,7 @@ Incorporate external chat history, specifically previous messages within the con
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#text-generation-content) | `content` | array | The message content. | | Role | `role` | string | The message role, i.e. 'system', 'user' or 'assistant'. | @@ -97,7 +97,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#text-generation-image-url) | `image-url` | object | The image URL | | Text | `text` | string | The text content. | @@ -109,24 +109,24 @@ The image URL
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
-The response-format Object +The response-type Object -

Response Format

+

Response Type

-`response-format` must fulfill one of the following schemas: +`response-type` must fulfill one of the following schemas:
Text
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Type | `type` | string | Must be `"text"` |
@@ -135,7 +135,7 @@ The image URL
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Type | `type` | string | Must be `"json_object"` |
@@ -144,7 +144,7 @@ The image URL
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | JSON Schema | `json-schema` | string | Set up the schema of the structured output. | | Type | `type` | string | Must be `"json_schema"` | @@ -153,7 +153,7 @@ The image URL
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Texts | `texts` | array[string] | Texts. | | [Usage](#text-generation-usage) (optional) | `usage` | object | Usage statistics related to the query. | @@ -166,7 +166,7 @@ The image URL
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Completion tokens | `completion-tokens` | integer | Total number of tokens used (completion). | | Prompt tokens | `prompt-tokens` | integer | Total number of tokens used (prompt). | @@ -181,7 +181,7 @@ Turn text into numbers, unlocking use cases like search.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_EMBEDDINGS` | | Model (required) | `model` | string | ID of the model to use.
Enum values
  • `text-embedding-ada-002`
  • `text-embedding-3-small`
  • `text-embedding-3-large`
| @@ -196,7 +196,7 @@ Turn text into numbers, unlocking use cases like search.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Embedding | `embedding` | array[number] | Embedding of the input text. |
@@ -208,11 +208,11 @@ Turn audio into text.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SPEECH_RECOGNITION` | | Model (required) | `model` | string | ID of the model to use. Only `whisper-1` is currently available. .
Enum values
  • `whisper-1`
| -| Audio (required) | `audio` | string | The audio file object (not file name) to transcribe, in one of these formats: flac, mp3, mp4, mpeg, mpga, m4a, ogg, wav, or webm. . | +| Audio (required) | `audio` | audio/* | The audio file object (not file name) to transcribe, in one of these formats: flac, mp3, mp4, mpeg, mpga, m4a, ogg, wav, or webm. . | | Prompt | `prompt` | string | An optional text to guide the model's style or continue a previous audio segment. The prompt should match the audio language. . | | Language | `language` | string | The language of the input audio. Supplying the input language in ISO-639-1 format will improve accuracy and latency. . | | Temperature | `temperature` | number | The sampling temperature, between 0 and 1. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. If set to 0, the model will use log probability to automatically increase the temperature until certain thresholds are hit. . | @@ -225,7 +225,7 @@ Turn audio into text.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Text | `text` | string | Generated text. |
@@ -237,13 +237,13 @@ Turn text into lifelike spoken audio
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_TO_SPEECH` | | Model (required) | `model` | string | One of the available TTS models: `tts-1` or `tts-1-hd` .
Enum values
  • `tts-1`
  • `tts-1-hd`
| | Text (required) | `text` | string | The text to generate audio for. The maximum length is 4096 characters. | | Voice (required) | `voice` | string | The voice to use when generating the audio. Supported voices are `alloy`, `echo`, `fable`, `onyx`, `nova`, and `shimmer`.
Enum values
  • `alloy`
  • `echo`
  • `fable`
  • `onyx`
  • `nova`
  • `shimmer`
| -| Response Format | `response-format` | string | The format to audio in. Supported formats are `mp3`, `opus`, `aac`, and `flac`.
Enum values
  • `mp3`
  • `opus`
  • `aac`
  • `flac`
| +| Response Format | `response-type` | string | The format to audio in. Supported formats are `mp3`, `opus`, `aac`, and `flac`.
Enum values
  • `mp3`
  • `opus`
  • `aac`
  • `flac`
| | Speed | `speed` | number | The speed of the generated audio. Select a value from `0.25` to `4.0`. `1.0` is the default. |
@@ -254,7 +254,7 @@ Turn text into lifelike spoken audio
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Audio (optional) | `audio` | audio/wav | AI generated audio. |
@@ -266,7 +266,7 @@ Generate or manipulate images with DALL·E.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_TO_IMAGE` | | Model (required) | `model` | string | The model to use for image generation.
Enum values
  • `dall-e-2`
  • `dall-e-3`
| @@ -284,7 +284,7 @@ Generate or manipulate images with DALL·E.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Images](#text-to-image-images) | `results` | array[object] | Generated results. |
@@ -296,7 +296,7 @@ Generate or manipulate images with DALL·E.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Generated Image | `image` | image/webp | Generated image. | | Revised Prompt | `revised-prompt` | string | Revised prompt. | @@ -363,17 +363,17 @@ variable: colour: title: Colour description: Describe the main colour to use i.e. blue, random - format: string + type: string instill-ui-order: 1 period: title: Period description: | Input different Picasso periods i.e. Blue, Rose, African, Synthetic Cubism, etc. - format: string + type: string prompt: title: Prompt description: Input prompt here i.e. "A cute baby wombat" - format: string + type: string output: image: title: Image @@ -405,11 +405,11 @@ variable: language: title: Language description: Input a language i.e. Chinese, Japanese, French, etc. - format: string + type: string prompt: title: Prompt description: Write the topic you want to ask about here i.e. "Tell me about small LLMs" - format: string + type: string output: result: title: Result diff --git a/pkg/component/ai/openai/v0/config/setup.yaml b/pkg/component/ai/openai/v0/config/setup.yaml index 99da4f5c9..741843334 100644 --- a/pkg/component/ai/openai/v0/config/setup.yaml +++ b/pkg/component/ai/openai/v0/config/setup.yaml @@ -2,20 +2,16 @@ additionalProperties: false properties: api-key: description: Fill in your OpenAI API key. To find your keys, visit your OpenAI's API Keys page. - acceptFormats: - - string + type: string instillSecret: true instillCredential: true uiOrder: 0 title: API Key - format: string organization: description: Specify which organization is used for the requests. Usage will count against the specified organization's subscription quota. - acceptFormats: - - string + type: string uiOrder: 1 title: Organization ID - format: string required: [] title: OpenAI Connection -format: object +type: object diff --git a/pkg/component/ai/openai/v0/config/tasks.json b/pkg/component/ai/openai/v0/config/tasks.json deleted file mode 100644 index 2a803ba6d..000000000 --- a/pkg/component/ai/openai/v0/config/tasks.json +++ /dev/null @@ -1,783 +0,0 @@ -{ - "$defs": { - "chat-message": { - "properties": { - "content": { - "$ref": "schema.yaml#/$defs/instill-types/multi-modal-content", - "description": "The message content.", - "uiOrder": 1, - "title": "Content" - }, - "role": { - "description": "The message role, i.e. 'system', 'user' or 'assistant'.", - "uiOrder": 0, - "title": "Role", - "format": "string" - } - }, - "required": [ - "role", - "content" - ], - "title": "Chat Message", - "format": "object" - } - }, - "TASK_SPEECH_RECOGNITION": { - "shortDescription": "Turn audio into text.", - "input": { - "uiOrder": 0, - "properties": { - "audio": { - "description": "The audio file object (not file name) to transcribe, in one of these formats: flac, mp3, mp4, mpeg, mpga, m4a, ogg, wav, or webm.\n.", - "format": "string", - "acceptFormats": [ - "audio/*" - ], - "uiOrder": 1, - "title": "Audio" - }, - "language": { - "description": "The language of the input audio. Supplying the input language in ISO-639-1 format will improve accuracy and latency.\n.", - "acceptFormats": [ - "string" - ], - "shortDescription": "The language of the input audio.", - "uiOrder": 3, - "title": "Language", - "format": "string" - }, - "model": { - "description": "ID of the model to use. Only `whisper-1` is currently available.\n.", - "enum": [ - "whisper-1" - ], - "example": "whisper-1", - "acceptFormats": [ - "string" - ], - "shortDescription": "ID of the model to use", - "uiOrder": 0, - "instillCredentialMap": { - "values": [ - "whisper-1" - ], - "targets": [ - "setup.api-key" - ] - }, - "title": "Model", - "format": "string" - }, - "prompt": { - "description": "An optional text to guide the model's style or continue a previous audio segment. The prompt should match the audio language.\n.", - "acceptFormats": [ - "string" - ], - "shortDescription": "An optional text to guide the model's style or continue a previous audio segment.", - "uiOrder": 2, - "title": "Prompt", - "format": "string" - }, - "temperature": { - "default": 0, - "description": "The sampling temperature, between 0 and 1. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. If set to 0, the model will use log probability to automatically increase the temperature until certain thresholds are hit.\n.", - "acceptFormats": [ - "number", - "integer" - ], - "shortDescription": "The sampling temperature, between 0 and 1.", - "uiOrder": 4, - "title": "Temperature", - "format": "number" - } - }, - "required": [ - "audio", - "model" - ], - "title": "Input", - "format": "object" - }, - "output": { - "uiOrder": 0, - "properties": { - "text": { - "description": "Generated text.", - "uiOrder": 0, - "title": "Text", - "format": "string" - } - }, - "required": [ - "text" - ], - "title": "Output", - "format": "object" - } - }, - "TASK_TEXT_EMBEDDINGS": { - "shortDescription": "Turn text into numbers, unlocking use cases like search.", - "input": { - "uiOrder": 0, - "properties": { - "model": { - "description": "ID of the model to use.", - "enum": [ - "text-embedding-ada-002", - "text-embedding-3-small", - "text-embedding-3-large" - ], - "example": "text-embedding-3-small", - "acceptFormats": [ - "string" - ], - "shortDescription": "ID of the model to use", - "uiOrder": 0, - "instillCredentialMap": { - "values": [ - "text-embedding-3-small", - "text-embedding-3-large" - ], - "targets": [ - "setup.api-key" - ] - }, - "title": "Model", - "format": "string" - }, - "text": { - "description": "The text.", - "acceptFormats": [ - "string" - ], - "uiOrder": 1, - "title": "Text", - "format": "string" - }, - "dimensions": { - "description": "The number of dimensions the resulting output embeddings should have. Only supported in text-embedding-3 and later models.", - "acceptFormats": [ - "integer" - ], - "uiOrder": 2, - "title": "Dimensions", - "format": "integer" - } - }, - "required": [ - "text", - "model" - ], - "title": "Input", - "format": "object" - }, - "output": { - "uiOrder": 0, - "properties": { - "embedding": { - "$ref": "schema.yaml#/$defs/instill-types/embedding", - "description": "Embedding of the input text.", - "uiOrder": 0, - "title": "Embedding" - } - }, - "required": [ - "embedding" - ], - "title": "Output", - "format": "object" - } - }, - "TASK_TEXT_GENERATION": { - "shortDescription": "Provide text outputs in response to their inputs.", - "description": "OpenAI's text generation models (often called generative pre-trained transformers or large language models) have been trained to understand natural language, code, and images. The models provide text outputs in response to their inputs. The inputs to these models are also referred to as \"prompts\". Designing a prompt is essentially how you “program” a large language model model, usually by providing instructions or some examples of how to successfully complete a task.", - "input": { - "uiOrder": 0, - "properties": { - "chat-history": { - "description": "Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format {\"role\": \"The message role, i.e. 'system', 'user' or 'assistant'\", \"content\": \"message content\"}.", - "acceptFormats": [ - "object" - ], - "shortDescription": "Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should be an ojbect adhere to the format: {\"role\": \"The message role, i.e. 'system', 'user' or 'assistant'\", \"content\": \"message content\"}.", - "uiOrder": 4, - "items": { - "$ref": "#/$defs/chat-message" - }, - "title": "Chat history", - "format": "array" - }, - "frequency-penalty": { - "default": 0, - "description": "Number between -2.0 and 2.0. Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim.", - "maximum": 2, - "minimum": -2, - "nullable": true, - "acceptFormats": [ - "number", - "integer" - ], - "shortDescription": "Number between -2.0 and 2.0", - "uiOrder": 11, - "title": "Frequency Penalty", - "format": "number" - }, - "images": { - "description": "The images.", - "acceptFormats": [ - "array" - ], - "uiOrder": 3, - "items": { - "format": "string" - }, - "title": "Image", - "format": "array" - }, - "max-tokens": { - "description": "The maximum number of tokens that can be generated in the chat completion.\n\nThe total length of input tokens and generated tokens is limited by the model's context length.", - "nullable": true, - "acceptFormats": [ - "integer" - ], - "shortDescription": "The maximum number of tokens to generate in the chat completion.", - "uiOrder": 7, - "title": "Max Tokens", - "format": "integer" - }, - "model": { - "description": "ID of the model to use.", - "enum": [ - "o1-preview", - "o1-mini", - "gpt-4o-mini", - "gpt-4o", - "gpt-4o-2024-05-13", - "gpt-4o-2024-08-06", - "gpt-4-turbo", - "gpt-4-turbo-2024-04-09", - "gpt-4-0125-preview", - "gpt-4-turbo-preview", - "gpt-4-1106-preview", - "gpt-4-vision-preview", - "gpt-4", - "gpt-4-0314", - "gpt-4-0613", - "gpt-4-32k", - "gpt-4-32k-0314", - "gpt-4-32k-0613", - "gpt-3.5-turbo", - "gpt-3.5-turbo-16k", - "gpt-3.5-turbo-0301", - "gpt-3.5-turbo-0613", - "gpt-3.5-turbo-1106", - "gpt-3.5-turbo-0125", - "gpt-3.5-turbo-16k-0613" - ], - "example": "gpt-4o", - "acceptFormats": [ - "string" - ], - "shortDescription": "ID of the model to use", - "uiOrder": 0, - "instillCredentialMap": { - "values": [ - "o1-preview", - "o1-mini", - "gpt-4o", - "gpt-4o-2024-08-06", - "gpt-4-turbo", - "gpt-4-vision-preview", - "gpt-4", - "gpt-4-32k", - "gpt-3.5-turbo", - "gpt-4o-mini" - ], - "targets": [ - "setup.api-key" - ] - }, - "title": "Model", - "format": "string" - }, - "n": { - "default": 1, - "description": "How many chat completion choices to generate for each input message. Note that you will be charged based on the number of generated tokens across all of the choices. Keep `n` as `1` to minimize costs.", - "example": 1, - "maximum": 128, - "minimum": 1, - "nullable": true, - "acceptFormats": [ - "integer" - ], - "uiOrder": 6, - "title": "N", - "format": "integer" - }, - "presence-penalty": { - "default": 0, - "description": "Number between -2.0 and 2.0. Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics.", - "maximum": 2, - "minimum": -2, - "nullable": true, - "acceptFormats": [ - "number", - "integer" - ], - "shortDescription": "Number between -2.0 and 2.0", - "uiOrder": 10, - "title": "Presence Penalty", - "format": "number" - }, - "prompt": { - "description": "The prompt text.", - "acceptFormats": [ - "string" - ], - "uiOrder": 1, - "title": "Prompt", - "format": "string" - }, - "response-format": { - "description": "Response format.", - "uiOrder": 8, - "additionalProperties": true, - "required": [ - "type" - ], - "oneOf": [ - { - "properties": { - "type": { - "const": "text", - "title": "Type", - "description": "Text.", - "uiOrder": 0, - "format": "string" - } - }, - "required": [ - "type" - ], - "title": "Text", - "format": "object" - }, - { - "properties": { - "type": { - "const": "json_object", - "title": "Type", - "description": "JSON Object.", - "uiOrder": 0, - "format": "string" - } - }, - "required": [ - "type" - ], - "title": "JSON Object", - "format": "object" - }, - { - "properties": { - "type": { - "const": "json_schema", - "title": "Type", - "description": "JSON Schema.", - "uiOrder": 0, - "format": "string" - }, - "json-schema": { - "description": "Set up the schema of the structured output.", - "acceptFormats": [ - "string" - ], - "title": "JSON Schema", - "shortDescription": "Specify the schema of the structured output.", - "uiOrder": 1, - "format": "string" - } - }, - "required": [ - "type", - "json-schema" - ], - "title": "JSON Schema", - "format": "object" - } - ], - "title": "Response Format", - "format": "object" - }, - "system-message": { - "default": "You are a helpful assistant.", - "description": "The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is using a generic message as \"You are a helpful assistant.\".", - "acceptFormats": [ - "string" - ], - "shortDescription": "The system message helps set the behavior of the assistant", - "uiOrder": 2, - "title": "System Message", - "format": "string" - }, - "temperature": { - "default": 1, - "description": "What sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic.\n\nWe generally recommend altering this or `top-p` but not both.\n.", - "example": 1, - "maximum": 2, - "minimum": 0, - "nullable": true, - "acceptFormats": [ - "number", - "integer" - ], - "shortDescription": "What sampling temperature to use, between 0 and 2.", - "uiOrder": 5, - "title": "Temperature", - "format": "number" - }, - "top-p": { - "default": 1, - "description": "An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered.\n\nWe generally recommend altering this or `temperature` but not both.\n.", - "example": 1, - "maximum": 1, - "minimum": 0, - "nullable": true, - "acceptFormats": [ - "number", - "integer" - ], - "shortDescription": "An alternative to sampling with temperature, called nucleus sampling", - "uiOrder": 9, - "title": "Top P", - "format": "number" - } - }, - "required": [ - "model", - "prompt" - ], - "title": "Input", - "format": "object" - }, - "output": { - "uiOrder": 0, - "properties": { - "texts": { - "uiOrder": 0, - "items": { - "title": "Text", - "format": "string" - }, - "description": "Texts.", - "title": "Texts", - "format": "array" - }, - "usage": { - "description": "Usage statistics related to the query.", - "uiOrder": 1, - "properties": { - "total-tokens": { - "title": "Total tokens", - "description": "Total number of tokens used (prompt + completion).", - "uiOrder": 0, - "format": "integer" - }, - "completion-tokens": { - "title": "Completion tokens", - "description": "Total number of tokens used (completion).", - "uiOrder": 1, - "format": "integer" - }, - "prompt-tokens": { - "title": "Prompt tokens", - "description": "Total number of tokens used (prompt).", - "uiOrder": 2, - "format": "integer" - } - }, - "required": [ - "total-tokens" - ], - "title": "Usage", - "format": "object" - } - }, - "required": [ - "texts" - ], - "title": "Output", - "format": "object" - } - }, - "TASK_TEXT_TO_IMAGE": { - "shortDescription": "Generate or manipulate images with DALL·E.", - "input": { - "uiOrder": 0, - "properties": { - "model": { - "default": "dall-e-2", - "description": "The model to use for image generation.", - "enum": [ - "dall-e-2", - "dall-e-3" - ], - "example": "dall-e-3", - "nullable": true, - "instillCredentialMap": { - "values": [ - "dall-e-3" - ], - "targets": [ - "setup.api-key" - ] - }, - "acceptFormats": [ - "string" - ], - "shortDescription": "ID of the model to use", - "uiOrder": 0, - "title": "Model", - "format": "string" - }, - "n": { - "default": 1, - "description": "The number of images to generate. Must be between 1 and 10. For `dall-e-3`, only `n=1` is supported.", - "example": 1, - "maximum": 10, - "minimum": 1, - "nullable": true, - "acceptFormats": [ - "integer" - ], - "uiOrder": 2, - "title": "N", - "format": "integer" - }, - "prompt": { - "description": "A text description of the desired image(s). The maximum length is 1000 characters for `dall-e-2` and 4000 characters for `dall-e-3`.", - "example": "A cute baby sea otter", - "acceptFormats": [ - "string" - ], - "shortDescription": "A text description of the desired image(s).", - "uiOrder": 1, - "title": "Prompt", - "format": "string" - }, - "quality": { - "default": "standard", - "description": "The quality of the image that will be generated. `hd` creates images with finer details and greater consistency across the image. This param is only supported for `dall-e-3`.", - "enum": [ - "standard", - "hd" - ], - "example": "standard", - "acceptFormats": [ - "string" - ], - "shortDescription": "The quality of the image that will be generated.", - "uiOrder": 3, - "title": "Quality", - "format": "string" - }, - "size": { - "default": "1024x1024", - "description": "The size of the generated images. Must be one of `256x256`, `512x512`, or `1024x1024` for `dall-e-2`. Must be one of `1024x1024`, `1792x1024`, or `1024x1792` for `dall-e-3` models.", - "enum": [ - "256x256", - "512x512", - "1024x1024", - "1792x1024", - "1024x1792" - ], - "example": "1024x1024", - "nullable": true, - "acceptFormats": [ - "string" - ], - "shortDescription": "The size of the generated images.", - "uiOrder": 4, - "title": "Size", - "format": "string" - }, - "style": { - "default": "vivid", - "description": "The style of the generated images. Must be one of `vivid` or `natural`. Vivid causes the model to lean towards generating hyper-real and dramatic images. Natural causes the model to produce more natural, less hyper-real looking images. This param is only supported for `dall-e-3`.", - "enum": [ - "vivid", - "natural" - ], - "example": "vivid", - "nullable": true, - "acceptFormats": [ - "string" - ], - "shortDescription": "The style of the generated images.", - "uiOrder": 5, - "title": "N", - "format": "string" - } - }, - "required": [ - "prompt", - "model" - ], - "title": "Input", - "format": "object" - }, - "output": { - "uiOrder": 0, - "properties": { - "results": { - "description": "Generated results.", - "uiOrder": 0, - "items": { - "description": "Generated result.", - "properties": { - "image": { - "title": "Generated Image", - "description": "Generated image.", - "uiOrder": 0, - "format": "image/webp" - }, - "revised-prompt": { - "title": "Revised Prompt", - "description": "Revised prompt.", - "uiOrder": 1, - "format": "string" - } - }, - "required": [ - "image", - "revised-prompt" - ], - "title": "Image", - "format": "object" - }, - "title": "Images", - "format": "array" - } - }, - "required": [ - "results" - ], - "title": "Output", - "format": "object" - } - }, - "TASK_TEXT_TO_SPEECH": { - "shortDescription": "Turn text into lifelike spoken audio", - "input": { - "uiOrder": 0, - "properties": { - "model": { - "description": "One of the available TTS models: `tts-1` or `tts-1-hd`\n.", - "default": "tts-1", - "enum": [ - "tts-1", - "tts-1-hd" - ], - "acceptFormats": [ - "string" - ], - "instillCredentialMap": { - "values": [ - "tts-1", - "tts-1-hd" - ], - "targets": [ - "setup.api-key" - ] - }, - "shortDescription": "ID of the model to use", - "uiOrder": 0, - "title": "Model", - "format": "string" - }, - "response-format": { - "default": "mp3", - "description": "The format to audio in. Supported formats are `mp3`, `opus`, `aac`, and `flac`.", - "enum": [ - "mp3", - "opus", - "aac", - "flac" - ], - "acceptFormats": [ - "string" - ], - "shortDescription": "The format to audio", - "uiOrder": 3, - "title": "Response Format", - "format": "string" - }, - "speed": { - "default": 1, - "description": "The speed of the generated audio. Select a value from `0.25` to `4.0`. `1.0` is the default.", - "maximum": 4, - "minimum": 0.25, - "acceptFormats": [ - "number" - ], - "shortDescription": "The speed of the generated audio", - "uiOrder": 4, - "title": "Speed", - "format": "number" - }, - "text": { - "description": "The text to generate audio for. The maximum length is 4096 characters.", - "maxLength": 4096, - "acceptFormats": [ - "string" - ], - "shortDescription": "The text to generate audio for", - "uiOrder": 1, - "title": "Text", - "format": "string" - }, - "voice": { - "description": "The voice to use when generating the audio. Supported voices are `alloy`, `echo`, `fable`, `onyx`, `nova`, and `shimmer`.", - "enum": [ - "alloy", - "echo", - "fable", - "onyx", - "nova", - "shimmer" - ], - "acceptFormats": [ - "string" - ], - "default": "alloy", - "shortDescription": "The voice to use when generating the audio", - "uiOrder": 2, - "title": "Voice", - "format": "string" - } - }, - "required": [ - "text", - "model", - "voice" - ], - "title": "Input", - "format": "object" - }, - "output": { - "uiOrder": 0, - "properties": { - "audio": { - "description": "AI generated audio.", - "uiOrder": 0, - "title": "Audio", - "format": "audio/wav" - } - }, - "required": [], - "title": "Output", - "format": "object" - } - } -} diff --git a/pkg/component/ai/openai/v0/config/tasks.yaml b/pkg/component/ai/openai/v0/config/tasks.yaml index 8b05dfc0d..4609b192c 100644 --- a/pkg/component/ai/openai/v0/config/tasks.yaml +++ b/pkg/component/ai/openai/v0/config/tasks.yaml @@ -10,45 +10,41 @@ $defs: description: The message role, i.e. 'system', 'user' or 'assistant'. uiOrder: 0 title: Role - format: string + type: string required: - role - content title: Chat Message - format: object + type: object TASK_SPEECH_RECOGNITION: shortDescription: Turn audio into text. input: uiOrder: 0 properties: audio: - description: |- - The audio file object (not file name) to transcribe, in one of these formats: flac, mp3, mp4, mpeg, mpga, m4a, ogg, wav, or webm. - . - format: string - acceptFormats: - - audio/* + description: 'The audio file object (not file name) to transcribe, in one of these formats: flac, mp3, mp4, mpeg, mpga, m4a, ogg, wav, or webm. + + .' + type: audio/* uiOrder: 1 title: Audio language: - description: |- - The language of the input audio. Supplying the input language in ISO-639-1 format will improve accuracy and latency. - . - acceptFormats: - - string + description: 'The language of the input audio. Supplying the input language in ISO-639-1 + format will improve accuracy and latency. + + .' + type: string shortDescription: The language of the input audio. uiOrder: 3 title: Language - format: string model: - description: |- - ID of the model to use. Only `whisper-1` is currently available. - . + description: 'ID of the model to use. Only `whisper-1` is currently available. + + .' enum: - whisper-1 example: whisper-1 - acceptFormats: - - string + type: string shortDescription: ID of the model to use uiOrder: 0 instillCredentialMap: @@ -57,34 +53,30 @@ TASK_SPEECH_RECOGNITION: targets: - setup.api-key title: Model - format: string prompt: - description: |- - An optional text to guide the model's style or continue a previous audio segment. The prompt should match the audio language. - . - acceptFormats: - - string + description: 'An optional text to guide the model''s style or continue a previous audio segment. The prompt should match the audio language. + + .' + type: string shortDescription: An optional text to guide the model's style or continue a previous audio segment. uiOrder: 2 title: Prompt - format: string temperature: default: 0 - description: |- - The sampling temperature, between 0 and 1. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. If set to 0, the model will use log probability to automatically increase the temperature until certain thresholds are hit. - . - acceptFormats: - - number - - integer + description: 'The sampling temperature, between 0 and 1. Higher values like 0.8 will make the output more random, while lower values like 0.2 will + make it more focused and deterministic. If set to 0, the model will use log probability + to automatically increase the temperature until certain thresholds are hit. + + .' + type: number shortDescription: The sampling temperature, between 0 and 1. uiOrder: 4 title: Temperature - format: number required: - audio - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -92,11 +84,11 @@ TASK_SPEECH_RECOGNITION: description: Generated text. uiOrder: 0 title: Text - format: string + type: string required: - text title: Output - format: object + type: object TASK_TEXT_EMBEDDINGS: shortDescription: Turn text into numbers, unlocking use cases like search. input: @@ -109,8 +101,7 @@ TASK_TEXT_EMBEDDINGS: - text-embedding-3-small - text-embedding-3-large example: text-embedding-3-small - acceptFormats: - - string + type: string shortDescription: ID of the model to use uiOrder: 0 instillCredentialMap: @@ -120,26 +111,21 @@ TASK_TEXT_EMBEDDINGS: targets: - setup.api-key title: Model - format: string text: description: The text. - acceptFormats: - - string + type: string uiOrder: 1 title: Text - format: string dimensions: description: The number of dimensions the resulting output embeddings should have. Only supported in text-embedding-3 and later models. - acceptFormats: - - integer + type: integer uiOrder: 2 title: Dimensions - format: integer required: - text - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -151,7 +137,7 @@ TASK_TEXT_EMBEDDINGS: required: - embedding title: Output - format: object + type: object TASK_TEXT_GENERATION: shortDescription: Provide text outputs in response to their inputs. description: OpenAI's text generation models (often called generative pre-trained transformers or large language models) have been trained to understand @@ -165,8 +151,7 @@ TASK_TEXT_GENERATION: description: 'Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should adhere to the format {"role": "The message role, i.e. ''system'', ''user'' or ''assistant''", "content": "message content"}.' - acceptFormats: - - object + type: array shortDescription: 'Incorporate external chat history, specifically previous messages within the conversation. Please note that System Message will be ignored and will not have any effect when this field is populated. Each message should be an ojbect adhere to the format: {"role": "The message role, i.e. ''system'', ''user'' or ''assistant''", "content": "message content"}.' @@ -174,7 +159,6 @@ TASK_TEXT_GENERATION: items: $ref: '#/$defs/chat-message' title: Chat history - format: array frequency-penalty: default: 0 description: Number between -2.0 and 2.0. Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the @@ -182,34 +166,27 @@ TASK_TEXT_GENERATION: maximum: 2 minimum: -2 nullable: true - acceptFormats: - - number - - integer + type: number shortDescription: Number between -2.0 and 2.0 uiOrder: 11 title: Frequency Penalty - format: number images: description: The images. - acceptFormats: - - array + type: array uiOrder: 3 items: - format: string + type: string title: Image - format: array max-tokens: - description: |- - The maximum number of tokens that can be generated in the chat completion. + description: 'The maximum number of tokens that can be generated in the chat completion. + - The total length of input tokens and generated tokens is limited by the model's context length. + The total length of input tokens and generated tokens is limited by the model''s context length.' nullable: true - acceptFormats: - - integer + type: integer shortDescription: The maximum number of tokens to generate in the chat completion. uiOrder: 7 title: Max Tokens - format: integer model: description: ID of the model to use. enum: @@ -239,8 +216,7 @@ TASK_TEXT_GENERATION: - gpt-3.5-turbo-0125 - gpt-3.5-turbo-16k-0613 example: gpt-4o - acceptFormats: - - string + type: string shortDescription: ID of the model to use uiOrder: 0 instillCredentialMap: @@ -258,7 +234,6 @@ TASK_TEXT_GENERATION: targets: - setup.api-key title: Model - format: string n: default: 1 description: How many chat completion choices to generate for each input message. Note that you will be charged based on the number of generated @@ -267,11 +242,9 @@ TASK_TEXT_GENERATION: maximum: 128 minimum: 1 nullable: true - acceptFormats: - - integer + type: integer uiOrder: 6 title: N - format: integer presence-penalty: default: 0 description: Number between -2.0 and 2.0. Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's @@ -279,21 +252,16 @@ TASK_TEXT_GENERATION: maximum: 2 minimum: -2 nullable: true - acceptFormats: - - number - - integer + type: number shortDescription: Number between -2.0 and 2.0 uiOrder: 10 title: Presence Penalty - format: number prompt: description: The prompt text. - acceptFormats: - - string + type: string uiOrder: 1 title: Prompt - format: string - response-format: + response-type: description: Response format. uiOrder: 8 additionalProperties: true @@ -306,96 +274,90 @@ TASK_TEXT_GENERATION: title: Type description: Text. uiOrder: 0 - format: string + type: string required: - type title: Text - format: object + type: object - properties: type: const: json_object title: Type description: JSON Object. uiOrder: 0 - format: string + type: string required: - type title: JSON Object - format: object + type: object - properties: type: const: json_schema title: Type description: JSON Schema. uiOrder: 0 - format: string + type: string json-schema: description: Set up the schema of the structured output. - acceptFormats: - - string + type: string title: JSON Schema shortDescription: Specify the schema of the structured output. uiOrder: 1 - format: string required: - type - json-schema title: JSON Schema - format: object + type: object title: Response Format - format: object + type: object system-message: default: You are a helpful assistant. description: The system message helps set the behavior of the assistant. For example, you can modify the personality of the assistant or provide specific instructions about how it should behave throughout the conversation. By default, the model’s behavior is using a generic message as "You are a helpful assistant.". - acceptFormats: - - string + type: string shortDescription: The system message helps set the behavior of the assistant uiOrder: 2 title: System Message - format: string temperature: default: 1 - description: |- - What sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. + description: 'What sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like + 0.2 will make it more focused and deterministic. + We generally recommend altering this or `top-p` but not both. - . + + .' example: 1 maximum: 2 minimum: 0 nullable: true - acceptFormats: - - number - - integer + type: number shortDescription: What sampling temperature to use, between 0 and 2. uiOrder: 5 title: Temperature - format: number top-p: default: 1 - description: |- - An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered. + description: 'An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p + probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered. + We generally recommend altering this or `temperature` but not both. - . + + .' example: 1 maximum: 1 minimum: 0 nullable: true - acceptFormats: - - number - - integer + type: number shortDescription: An alternative to sampling with temperature, called nucleus sampling uiOrder: 9 title: Top P - format: number required: - model - prompt title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -403,10 +365,10 @@ TASK_TEXT_GENERATION: uiOrder: 0 items: title: Text - format: string + type: string description: Texts. title: Texts - format: array + type: array usage: description: Usage statistics related to the query. uiOrder: 1 @@ -415,25 +377,25 @@ TASK_TEXT_GENERATION: title: Total tokens description: Total number of tokens used (prompt + completion). uiOrder: 0 - format: integer + type: integer completion-tokens: title: Completion tokens description: Total number of tokens used (completion). uiOrder: 1 - format: integer + type: integer prompt-tokens: title: Prompt tokens description: Total number of tokens used (prompt). uiOrder: 2 - format: integer + type: integer required: - total-tokens title: Usage - format: object + type: object required: - texts title: Output - format: object + type: object TASK_TEXT_TO_IMAGE: shortDescription: Generate or manipulate images with DALL·E. input: @@ -452,12 +414,10 @@ TASK_TEXT_TO_IMAGE: - dall-e-3 targets: - setup.api-key - acceptFormats: - - string + type: string shortDescription: ID of the model to use uiOrder: 0 title: Model - format: string n: default: 1 description: The number of images to generate. Must be between 1 and 10. For `dall-e-3`, only `n=1` is supported. @@ -465,20 +425,16 @@ TASK_TEXT_TO_IMAGE: maximum: 10 minimum: 1 nullable: true - acceptFormats: - - integer + type: integer uiOrder: 2 title: N - format: integer prompt: description: A text description of the desired image(s). The maximum length is 1000 characters for `dall-e-2` and 4000 characters for `dall-e-3`. example: A cute baby sea otter - acceptFormats: - - string + type: string shortDescription: A text description of the desired image(s). uiOrder: 1 title: Prompt - format: string quality: default: standard description: The quality of the image that will be generated. `hd` creates images with finer details and greater consistency across the image. This @@ -487,12 +443,10 @@ TASK_TEXT_TO_IMAGE: - standard - hd example: standard - acceptFormats: - - string + type: string shortDescription: The quality of the image that will be generated. uiOrder: 3 title: Quality - format: string size: default: 1024x1024 description: The size of the generated images. Must be one of `256x256`, `512x512`, or `1024x1024` for `dall-e-2`. Must be one of `1024x1024`, `1792x1024`, @@ -505,12 +459,10 @@ TASK_TEXT_TO_IMAGE: - 1024x1792 example: 1024x1024 nullable: true - acceptFormats: - - string + type: string shortDescription: The size of the generated images. uiOrder: 4 title: Size - format: string style: default: vivid description: The style of the generated images. Must be one of `vivid` or `natural`. Vivid causes the model to lean towards generating hyper-real @@ -520,17 +472,15 @@ TASK_TEXT_TO_IMAGE: - natural example: vivid nullable: true - acceptFormats: - - string + type: string shortDescription: The style of the generated images. uiOrder: 5 title: N - format: string required: - prompt - model title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -544,38 +494,37 @@ TASK_TEXT_TO_IMAGE: title: Generated Image description: Generated image. uiOrder: 0 - format: image/webp + type: image/webp revised-prompt: title: Revised Prompt description: Revised prompt. uiOrder: 1 - format: string + type: string required: - image - revised-prompt title: Image - format: object + type: object title: Images - format: array + type: array required: - results title: Output - format: object + type: object TASK_TEXT_TO_SPEECH: shortDescription: Turn text into lifelike spoken audio input: uiOrder: 0 properties: model: - description: |- - One of the available TTS models: `tts-1` or `tts-1-hd` - . + description: 'One of the available TTS models: `tts-1` or `tts-1-hd` + + .' default: tts-1 enum: - tts-1 - tts-1-hd - acceptFormats: - - string + type: string instillCredentialMap: values: - tts-1 @@ -585,8 +534,7 @@ TASK_TEXT_TO_SPEECH: shortDescription: ID of the model to use uiOrder: 0 title: Model - format: string - response-format: + response-type: default: mp3 description: The format to audio in. Supported formats are `mp3`, `opus`, `aac`, and `flac`. enum: @@ -594,32 +542,26 @@ TASK_TEXT_TO_SPEECH: - opus - aac - flac - acceptFormats: - - string + type: string shortDescription: The format to audio uiOrder: 3 title: Response Format - format: string speed: default: 1 description: The speed of the generated audio. Select a value from `0.25` to `4.0`. `1.0` is the default. maximum: 4 minimum: 0.25 - acceptFormats: - - number + type: number shortDescription: The speed of the generated audio uiOrder: 4 title: Speed - format: number text: description: The text to generate audio for. The maximum length is 4096 characters. maxLength: 4096 - acceptFormats: - - string + type: string shortDescription: The text to generate audio for uiOrder: 1 title: Text - format: string voice: description: The voice to use when generating the audio. Supported voices are `alloy`, `echo`, `fable`, `onyx`, `nova`, and `shimmer`. enum: @@ -629,19 +571,17 @@ TASK_TEXT_TO_SPEECH: - onyx - nova - shimmer - acceptFormats: - - string + type: string default: alloy shortDescription: The voice to use when generating the audio uiOrder: 2 title: Voice - format: string required: - text - model - voice title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -649,7 +589,7 @@ TASK_TEXT_TO_SPEECH: description: AI generated audio. uiOrder: 0 title: Audio - format: audio/wav + type: audio/wav required: [] title: Output - format: object + type: object diff --git a/pkg/component/ai/perplexity/v0/.compogen/bottom.mdx b/pkg/component/ai/perplexity/v0/.compogen/bottom.mdx index 6d05440bd..a585e7749 100644 --- a/pkg/component/ai/perplexity/v0/.compogen/bottom.mdx +++ b/pkg/component/ai/perplexity/v0/.compogen/bottom.mdx @@ -6,7 +6,7 @@ version: v1beta variable: prompt: - format: string + type: string title: Prompt component: diff --git a/pkg/component/ai/perplexity/v0/README.mdx b/pkg/component/ai/perplexity/v0/README.mdx index 6b380dd2d..3361639cc 100644 --- a/pkg/component/ai/perplexity/v0/README.mdx +++ b/pkg/component/ai/perplexity/v0/README.mdx @@ -36,7 +36,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key | `api-key` | string | Fill in your API key from the vendor's platform. | @@ -54,7 +54,7 @@ Generate response base on conversation input.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CHAT` | | [Chat Data](#chat-chat-data) (required) | `data` | object | Input data. | @@ -71,7 +71,7 @@ Input data.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Chat Messages](#chat-chat-messages) | `messages` | array | List of chat messages. | | Model Name | `model` | string | The model to be used for `TASK_CHAT`.
Enum values
  • `llama-3.1-sonar-small-128k-online`
  • `llama-3.1-sonar-large-128k-online`
  • `llama-3.1-sonar-huge-128k-online`
| @@ -82,7 +82,7 @@ List of chat messages.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#chat-content) | `content` | array | The message content. | | Name | `name` | string | An optional name for the participant. Provides the model information to differentiate between participants of the same role. | @@ -94,7 +94,7 @@ The message content.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Text Message | `text` | string | Text message. | | Text | `type` | string | Text content type. | @@ -105,7 +105,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Frequency Penalty | `frequency-penalty` | number | A multiplicative penalty greater than 0. Values greater than 1.0 penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim. A value of 1.0 means no penalty. Incompatible with `presence_penalty`. | | Max New Tokens | `max-tokens` | integer | The maximum number of completion tokens returned by the API. The total number of tokens requested in max_tokens plus the number of prompt tokens sent in messages must not exceed the context window token limit of model requested. If left unspecified, then the model will generate tokens until either it reaches its stop token or the end of its context window. | @@ -123,7 +123,7 @@ Input parameter.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Output Data](#chat-output-data) | `data` | object | Output data. | | [Output Metadata](#chat-output-metadata) (optional) | `metadata` | object | Output metadata. | @@ -136,7 +136,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Choices](#chat-choices) | `choices` | array | List of chat completion choices. | | Citations | `citations` | array | List of citations. | @@ -146,7 +146,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Created | `created` | integer | The timestamp of when the chat completion was created. Format is in ISO 8601. Example: 2024-07-01T11:47:40.388Z. | | Finish Reason | `finish-reason` | string | The reason the model stopped generating tokens. | @@ -158,7 +158,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content | `content` | string | The contents of the message. | | Role | `role` | string | The role of the author of this message. | @@ -168,7 +168,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Usage](#chat-usage) | `usage` | object | Usage statistics for the request. |
@@ -177,7 +177,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Completion Tokens | `completion-tokens` | integer | Number of tokens in the generated response. | | Prompt Tokens | `prompt-tokens` | integer | Number of tokens in the prompt. | @@ -195,7 +195,7 @@ version: v1beta variable: prompt: - format: string + type: string title: Prompt component: diff --git a/pkg/component/ai/perplexity/v0/config/setup.yaml b/pkg/component/ai/perplexity/v0/config/setup.yaml index 1245d0bb8..968a1f22b 100644 --- a/pkg/component/ai/perplexity/v0/config/setup.yaml +++ b/pkg/component/ai/perplexity/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: api-key: description: Fill in your API key from the vendor's platform. - acceptFormats: - - string + type: string instillSecret: true instillCredential: true uiOrder: 0 title: API Key - format: string required: [] title: Perplexity Connection -format: object +type: object diff --git a/pkg/component/ai/perplexity/v0/config/tasks.yaml b/pkg/component/ai/perplexity/v0/config/tasks.yaml index 472e76136..b4f9d447c 100644 --- a/pkg/component/ai/perplexity/v0/config/tasks.yaml +++ b/pkg/component/ai/perplexity/v0/config/tasks.yaml @@ -14,8 +14,7 @@ TASK_CHAT: model: description: The model to be used for `TASK_CHAT`. shortDescription: The model to be used. - acceptFormats: - - string + type: string enum: - llama-3.1-sonar-small-128k-online - llama-3.1-sonar-large-128k-online @@ -27,7 +26,6 @@ TASK_CHAT: - llama-3.1-sonar-huge-128k-online title: Model Name uiOrder: 0 - format: string messages: title: Chat Messages items: @@ -42,56 +40,48 @@ TASK_CHAT: title: Text Message description: Text message. shortDescription: Text message. - acceptFormats: - - string + type: string uiOrder: 1 - format: string type: title: Text description: Text content type. shortDescription: Text content type. - acceptFormats: - - string + type: string const: text uiOrder: 0 - format: string required: [] title: Text - format: object + type: object uiOrder: 0 - format: array + type: array role: description: The message role, i.e. 'system', 'user' or 'assistant'. shortDescription: The message role, i.e. 'system', 'user' or 'assistant'. - acceptFormats: - - string + type: string title: Role enum: - system - user - assistant uiOrder: 1 - format: string name: description: An optional name for the participant. Provides the model information to differentiate between participants of the same role. shortDescription: An optional name for the participant. Provides the model information to differentiate between participants of the same role. - acceptFormats: - - string + type: string title: Name uiOrder: 2 - format: string required: - content - role - format: object + type: object uiOrder: 1 description: List of chat messages. - format: array + type: array required: - messages uiOrder: 0 - format: object + type: object parameter: description: Input parameter. shortDescription: Input parameter. @@ -102,89 +92,71 @@ TASK_CHAT: of prompt tokens sent in messages must not exceed the context window token limit of model requested. If left unspecified, then the model will generate tokens until either it reaches its stop token or the end of its context window. shortDescription: The maximum number of tokens for model to generate. - acceptFormats: - - integer + type: integer default: 50 uiOrder: 0 - format: integer temperature: title: Temperature description: The amount of randomness in the response, valued between 0 inclusive and 2 exclusive. Higher values are more random, and lower values are more deterministic. shortDescription: The temperature for sampling. - acceptFormats: - - number + type: number default: 0.2 uiOrder: 1 - format: number top-p: title: Top P description: The nucleus sampling threshold, valued between 0 and 1 inclusive. For each subsequent token, the model considers the results of the tokens with top_p probability mass. We recommend either altering top_k or top_p, but not both. shortDescription: Nucleus sampling. - acceptFormats: - - number + type: number default: 0.9 uiOrder: 2 - format: number stream: title: Stream description: If set, partial message deltas will be sent. Tokens will be sent as data-only server-sent events as they become available. shortDescription: If set, partial message deltas will be sent. - acceptFormats: - - boolean + type: boolean default: false uiOrder: 3 - format: boolean search-domain-filter: title: Search Domain Filter description: Given a list of domains, limit the citations used by the online model to URLs from the specified domains. Currently limited to only 3 domains for whitelisting and blacklisting. For blacklisting add a `-` to the beginning of the domain string. - acceptFormats: - - array + type: string uiOrder: 4 - format: string search-recency-filter: title: Search Recency Filter description: Returns search results within the specified time interval - does not apply to images. Values include `month`, `week`, `day`, `hour`. - acceptFormats: - - string + type: string uiOrder: 5 - format: string top-k: title: Top K description: The number of tokens to keep for highest top-k filtering, specified as an integer between 0 and 2048 inclusive. If set to 0, top-k filtering is disabled. We recommend either altering top_k or top_p, but not both. - acceptFormats: - - number + type: number default: 0 uiOrder: 6 - format: number presence-penalty: title: Presence Penalty description: A value between -2.0 and 2.0. Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics. Incompatible with `frequency_penalty`. - acceptFormats: - - number + type: number default: 0 uiOrder: 7 - format: number frequency-penalty: title: Frequency Penalty description: A multiplicative penalty greater than 0. Values greater than 1.0 penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim. A value of 1.0 means no penalty. Incompatible with `presence_penalty`. - acceptFormats: - - number + type: number default: 1 uiOrder: 8 - format: number required: [] uiOrder: 1 title: Input Parameter - format: object + type: object required: - data - format: object + type: object output: title: Chat Output description: Output schema of the chat task. @@ -205,13 +177,13 @@ TASK_CHAT: description: The reason the model stopped generating tokens. shortDescription: The reason the model stopped generating tokens. uiOrder: 0 - format: string + type: string index: title: Index description: The index of the choice in the list of choices. shortDescription: The index of the choice in the list of choices. uiOrder: 1 - format: integer + type: integer message: title: Message description: A chat message generated by the model. @@ -222,43 +194,43 @@ TASK_CHAT: description: The contents of the message. shortDescription: The contents of the message. uiOrder: 0 - format: string + type: string role: title: Role description: The role of the author of this message. shortDescription: The role of the author of this message. uiOrder: 1 - format: string + type: string required: [] uiOrder: 2 - format: object + type: object created: title: Created description: 'The timestamp of when the chat completion was created. Format is in ISO 8601. Example: 2024-07-01T11:47:40.388Z.' shortDescription: The Unix timestamp (in seconds) of when the chat completion was created. uiOrder: 3 - format: integer + type: integer required: - finish-reason - index - message - created - format: object + type: object uiOrder: 0 - format: array + type: array citations: title: Citations description: List of citations. shortDescription: List of citations. items: - format: string + type: string uiOrder: 1 - format: array + type: array required: - choices uiOrder: 0 title: Output Data - format: object + type: object metadata: description: Output metadata. shortDescription: Output metadata. @@ -272,30 +244,30 @@ TASK_CHAT: description: Number of tokens in the generated response. shortDescription: Number of tokens in the generated response. uiOrder: 0 - format: integer + type: integer prompt-tokens: title: Prompt Tokens description: Number of tokens in the prompt. shortDescription: Number of tokens in the prompt. uiOrder: 1 - format: integer + type: integer total-tokens: title: Total Tokens description: Total number of tokens used in the request (prompt + completion). shortDescription: Total number of tokens used in the request (prompt + completion). uiOrder: 2 - format: integer + type: integer required: - completion-tokens - prompt-tokens - total-tokens uiOrder: 0 title: Usage - format: object + type: object required: [] title: Output Metadata uiOrder: 1 - format: object + type: object required: - data - format: object + type: object diff --git a/pkg/component/ai/stabilityai/v0/README.mdx b/pkg/component/ai/stabilityai/v0/README.mdx index 6d2fddfe7..30ddd40ce 100644 --- a/pkg/component/ai/stabilityai/v0/README.mdx +++ b/pkg/component/ai/stabilityai/v0/README.mdx @@ -37,7 +37,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key | `api-key` | string | Fill in your Stability AI API key. To find your keys, visit here. | @@ -55,19 +55,19 @@ Generate a new image from a text prompt.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_TEXT_TO_IMAGE` | | Engine (required) | `engine` | string | Stability AI Engine (model) to be used.
Enum values
  • `stable-diffusion-xl-1024-v1-0`
  • `stable-diffusion-xl-1024-v0-9`
  • `stable-diffusion-v1-6`
  • `esrgan-v1-x2plus`
  • `stable-diffusion-512-v2-1`
  • `stable-diffusion-xl-beta-v2-2-2`
| -| Prompts (required) | `prompts` | array | An array of prompts to use for generation. | -| Weights | `weights` | array[float] | An array of weights to use for generation. | +| Prompts (required) | `prompts` | array[string] | An array of prompts to use for generation. | +| Weights | `weights` | array[number] | An array of weights to use for generation. | | CFG Scale | `cfg-scale` | number | How strictly the diffusion process adheres to the prompt text (higher values keep your image closer to your prompt) | | Clip Guidance Preset | `clip-guidance-preset` | string | Clip guidance preset.
Enum values
  • `FAST_BLUE`
  • `FAST_GREEN`
  • `NONE`
  • `SIMPLE`
  • `SLOW`
  • `SLOWER`
  • `SLOWEST`
| | Height | `height` | integer | Height of the image to generate, in pixels, in an increment divible by 64. Engine-specific dimension validation: - SDXL Beta: must be between 128x128 and 512x896 (or 896x512); only one dimension can be greater than 512. - SDXL v0.9: must be one of 1024x1024, 1152x896, 1216x832, 1344x768, 1536x640, 640x1536, 768x1344, 832x1216, or 896x1152 - SDXL v1.0: same as SDXL v0.9 - SD v1.6: must be between 320x320 and 1536x1536 | | Width | `width` | integer | Width of the image to generate, in pixels, in an increment divible by 64. Engine-specific dimension validation: - SDXL Beta: must be between 128x128 and 512x896 (or 896x512); only one dimension can be greater than 512. - SDXL v0.9: must be one of 1024x1024, 1152x896, 1216x832, 1344x768, 1536x640, 640x1536, 768x1344, 832x1216, or 896x1152 - SDXL v1.0: same as SDXL v0.9 - SD v1.6: must be between 320x320 and 1536x1536 | | Sampler | `sampler` | string | Which sampler to use for the diffusion process. If this value is omitted we'll automatically select an appropriate sampler for you.
Enum values
  • `DDIM`
  • `DDPM`
  • `K_DPMPP_2M`
  • `K_DPMPP_2S_ANCESTRAL`
  • `K_DPM_2`
  • `K_DPM_2_ANCESTRAL`
  • `K_EULER`
  • `K_EULER_ANCESTRAL`
  • `K_HEUN`
  • `K_LMS`
| | Samples | `samples` | integer | Number of images to generate | -| Seed | `seed` | integer | Random noise seed (omit this option or use `0` for a random seed) | +| Seed | `seed` | number | Random noise seed (omit this option or use `0` for a random seed) | | Steps | `steps` | integer | Number of diffusion steps to run. | | Style Preset | `style-preset` | string | Pass in a style preset to guide the image model towards a particular style. This list of style presets is subject to change.
Enum values
  • `enhance`
  • `anime`
  • `photographic`
  • `digital-art`
  • `comic-book`
  • `fantasy-art`
  • `line-art`
  • `analog-film`
  • `neon-punk`
  • `isometric`
  • `low-poly`
  • `origami`
  • `modeling-compound`
  • `cinematic`
  • `3d-model`
  • `pixel-art`
  • `tile-texture`
|
@@ -79,7 +79,7 @@ Generate a new image from a text prompt.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Images | `images` | array[image/png] | Generated images. | | Seeds | `seeds` | array[number] | Seeds of generated images. | @@ -92,24 +92,24 @@ Modify an image based on a text prompt.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_IMAGE_TO_IMAGE` | | Engine (required) | `engine` | string | Stability AI Engine (model) to be used.
Enum values
  • `stable-diffusion-xl-1024-v1-0`
  • `stable-diffusion-xl-1024-v0-9`
  • `stable-diffusion-v1-6`
  • `esrgan-v1-x2plus`
  • `stable-diffusion-512-v2-1`
  • `stable-diffusion-xl-beta-v2-2-2`
| | Prompts (required) | `prompts` | array[string] | An array of prompts to use for generation. | -| Init Image | `init-image` | image | Image used to initialize the diffusion process, in lieu of random noise. | -| Weights | `weights` | array | An array of weights to use for generation. If unspecified, the model will automatically assign a default weight of 1.0 to each prompt. | +| Init Image | `init-image` | image/* | Image used to initialize the diffusion process, in lieu of random noise. | +| Weights | `weights` | array[number] | An array of weights to use for generation. If unspecified, the model will automatically assign a default weight of 1.0 to each prompt. | | Clip Guidance Preset | `clip-guidance-preset` | string | Clip guidance preset.
Enum values
  • `FAST_BLUE`
  • `FAST_GREEN`
  • `NONE`
  • `SIMPLE`
  • `SLOW`
  • `SLOWER`
  • `SLOWEST`
| | Image Strength | `image-strength` | number | How much influence the `init_image` has on the diffusion process. Values close to `1` will yield images very similar to the `init_image` while values close to `0` will yield images wildly different than the `init_image`. The behavior of this is meant to mirror DreamStudio's "Image Strength" slider.

This parameter is just an alternate way to set `step_schedule_start`, which is done via the calculation `1 - image_strength`. For example, passing in an Image Strength of 35% (`0.35`) would result in a `step_schedule_start` of `0.65`. | | CFG Scale | `cfg-scale` | number | How strictly the diffusion process adheres to the prompt text (higher values keep your image closer to your prompt) | | Init Image Mode | `init-image-mode` | string | Whether to use `image_strength` or `step_schedule_*` to control how much influence the `init_image` has on the result.
Enum values
  • `IMAGE_STRENGTH`
  • `STEP_SCHEDULE`
| | Sampler | `sampler` | string | Which sampler to use for the diffusion process. If this value is omitted we'll automatically select an appropriate sampler for you.
Enum values
  • `DDIM`
  • `DDPM`
  • `K_DPMPP_2M`
  • `K_DPMPP_2S_ANCESTRAL`
  • `K_DPM_2`
  • `K_DPM_2_ANCESTRAL`
  • `K_EULER`
  • `K_EULER_ANCESTRAL`
  • `K_HEUN`
  • `K_LMS`
| | Samples | `samples` | integer | Number of images to generate | -| Seed | `seed` | integer | Random noise seed (omit this option or use `0` for a random seed) | +| Seed | `seed` | number | Random noise seed (omit this option or use `0` for a random seed) | | Step Schedule Start | `step-schedule-start` | number | Skips a proportion of the start of the diffusion steps, allowing the init_image to influence the final generated image. Lower values will result in more influence from the init_image, while higher values will result in more influence from the diffusion steps. (e.g. a value of `0` would simply return you the init_image, where a value of `1` would return you a completely different image.) | | Step Schedule End | `step-schedule-end` | number | Skips a proportion of the end of the diffusion steps, allowing the init_image to influence the final generated image. Lower values will result in more influence from the init_image, while higher values will result in more influence from the diffusion steps. | | Steps | `steps` | integer | Number of diffusion steps to run. | -| Style Preset | `style-preset` | any | Pass in a style preset to guide the image model towards a particular style. This list of style presets is subject to change.
Enum values
  • `enhance`
  • `anime`
  • `photographic`
  • `digital-art`
  • `comic-book`
  • `fantasy-art`
  • `line-art`
  • `analog-film`
  • `neon-punk`
  • `isometric`
  • `low-poly`
  • `origami`
  • `modeling-compound`
  • `cinematic`
  • `3d-model`
  • `pixel-art`
  • `tile-texture`
| +| Style Preset | `style-preset` | string | Pass in a style preset to guide the image model towards a particular style. This list of style presets is subject to change.
Enum values
  • `enhance`
  • `anime`
  • `photographic`
  • `digital-art`
  • `comic-book`
  • `fantasy-art`
  • `line-art`
  • `analog-film`
  • `neon-punk`
  • `isometric`
  • `low-poly`
  • `origami`
  • `modeling-compound`
  • `cinematic`
  • `3d-model`
  • `pixel-art`
  • `tile-texture`
|
@@ -119,7 +119,7 @@ Modify an image based on a text prompt.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Images | `images` | array[image/png] | Generated images. | | Seeds | `seeds` | array[number] | Seeds of generated images. | diff --git a/pkg/component/ai/stabilityai/v0/config/setup.yaml b/pkg/component/ai/stabilityai/v0/config/setup.yaml index c29df14b0..fc695e442 100644 --- a/pkg/component/ai/stabilityai/v0/config/setup.yaml +++ b/pkg/component/ai/stabilityai/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: api-key: description: Fill in your Stability AI API key. To find your keys, visit here. - acceptFormats: - - string + type: string instillSecret: true instillCredential: true uiOrder: 0 title: API Key - format: string required: [] title: Stability AI Connection -format: object +type: object diff --git a/pkg/component/ai/stabilityai/v0/config/stabilityai.yaml b/pkg/component/ai/stabilityai/v0/config/stabilityai.yaml deleted file mode 100644 index a918034f5..000000000 --- a/pkg/component/ai/stabilityai/v0/config/stabilityai.yaml +++ /dev/null @@ -1,1939 +0,0 @@ -components: - headers: - Content-Length: - required: true - schema: - type: integer - Content-Type: - required: true - schema: - enum: - - application/json - - image/png - type: string - Finish-Reason: - schema: - $ref: '#/components/schemas/FinishReason' - Seed: - description: The seed used to generate the image. This header is only present when the `Accept` is set to `image/png`. Otherwise it is returned - in the response body. - example: 3817857576 - schema: - example: 787078103 - type: integer - parameters: - accept: - allowEmptyValue: false - description: The format of the response. Leave blank for JSON, or set to 'image/png' for a PNG image. - in: header - name: Accept - schema: - default: application/json - enum: - - application/json - - image/png - type: string - engineID: - example: stable-diffusion-v1-6 - in: path - name: engine_id - required: true - schema: - example: stable-diffusion-v1-6 - type: string - organization: - allowEmptyValue: false - description: Allows for requests to be scoped to an organization other than the user's default. If not provided, the user's default organization - will be used. - example: org-123456 - in: header - name: Organization - schema: - type: string - x-go-name: OrganizationID - stabilityClientID: - allowEmptyValue: false - description: Used to identify the source of requests, such as the client application or sub-organization. Optional, but recommended for organizational - clarity. - example: my-great-plugin - in: header - name: Stability-Client-ID - schema: - type: string - stabilityClientVersion: - allowEmptyValue: false - description: Used to identify the version of the application or service making the requests. Optional, but recommended for organizational clarity. - example: 1.2.1 - in: header - name: Stability-Client-Version - schema: - type: string - upscaleEngineID: - examples: - ESRGAN_X2_PLUS: - description: ESRGAN x2 Upscaler - value: esrgan-v1-x2plus - LATENT_UPSCALER_X4: - description: Stable Diffusion x4 Latent Upscaler - value: stable-diffusion-x4-latent-upscaler - in: path - name: engine_id - required: true - schema: - type: string - responses: - 400FromGeneration: - content: - application/json: - example: - id: 296a972f-666a-44a1-a3df-c9c28a1f56c0 - message: 'init_image: is required' - name: bad_request - schema: - $ref: '#/components/schemas/Error' - description: "General error for invalid parameters, see below for specific errors.\n - bad_request: one or more provided parameters are invalid (see\ - \ error description for details)\n - invalid_samples: Sample count may only be greater than 1 when the accept header is set to `application/json`\n\ - \ - invalid_height_or_width: Height and width must be specified in increments of 64\n - invalid_file_size: The file size of one or more of the\ - \ provided files is invalid\n - invalid_mime_type: The mime type of one or more of the provided files is invalid\n - invalid_image_dimensions:\ - \ The dimensions of the provided `init_image` and `mask_image` do not match\n - invalid_mask_image: The parameter `mask_source` was set to `MASK_IMAGE_WHITE`\ - \ or `MASK_IMAGE_BLACK` but no `mask_image` was provided\n - invalid_prompts: One or more of the prompts contains filtered words\n - invalid_pixel_count:\ - \ Incorrect number of pixels specified.\n - invalid_sdxl_v222_dimensions: Incorrect dimensions specified for SDXL v2-2-2 engine. Requirements:\n\ - \ - Neither `height` nor `width` may be below 128\n - Only one of `height` or `width` may be above 512 (e.g. 512x768 is valid but 578x768\ - \ is not)\n - Maximum dimensions supported are 512x896 or 896x512 \n - invalid_sdxl_v1_dimensions: Incorrect dimensions specified for\ - \ SDXL v0.9 or v1.0 engine. Valid dimensions:\n - 1024x1024, 1152x896, 1216x832, 1344x768, 1536x640, 640x1536, 768x1344, 832x1216, or 896x1152" - 400FromUpscale: - content: - application/json: - example: - id: 296a972f-666a-44a1-a3df-c9c28a1f56c0 - message: 'image: is required' - name: bad_request - schema: - $ref: '#/components/schemas/Error' - description: |- - General error for invalid parameters, see below for specific errors. - - - bad_request: one or more provided parameters are invalid (see error description for details) - - invalid_file_size: The file size of one or more of the provided files is invalid - - invalid_mime_type: The mime type of one or more of the provided files is invalid - - invalid_pixel_count: The requested image would exceed the maximum pixel count of 4,194,304 - '401': - content: - application/json: - example: - id: 9160aa70-222f-4a36-9eb7-475e2668362a - message: missing authorization header - name: unauthorized - schema: - $ref: '#/components/schemas/Error' - description: 'unauthorized: API key missing or invalid' - '403': - content: - application/json: - example: - id: 5cf19777-d17f-49fe-9bd9-39ff0ec6bb50 - message: You do not have permission to access this resource - name: permission_denied - schema: - $ref: '#/components/schemas/Error' - description: 'permission_denied: You lack the necessary permissions to perform this action' - '404': - content: - application/json: - example: - id: 92b19e7f-22a2-4e71-a821-90edda229293 - message: The specified engine (ID some-fake-engine) was not found. - name: not_found - schema: - $ref: '#/components/schemas/Error' - description: 'not_found: The requested resource was not found (e.g. specifing a model that does not exist)' - '500': - content: - application/json: - example: - id: f81964d6-619b-453e-97bc-9fd7ac3f04e7 - message: An unexpected server error occurred, please try again. - name: server_error - schema: - $ref: '#/components/schemas/Error' - description: 'server_error: Some unexpected server error occurred' - GenerationResponse: - content: - application/json: - schema: - description: An array of results from the generation request, where each image is a base64 encoded PNG. - properties: - artifacts: - items: - $ref: '#/components/schemas/Image' - type: array - x-go-type-skip-optional-pointer: true - type: object - image/png: - example: The bytes of the generated image, what did you expect? - schema: - description: The bytes of the generated PNG image - format: binary - type: string - description: One or more images were successfully generated. - headers: - Content-Length: - $ref: '#/components/headers/Content-Length' - Content-Type: - $ref: '#/components/headers/Content-Type' - Finish-Reason: - $ref: '#/components/headers/Finish-Reason' - Seed: - $ref: '#/components/headers/Seed' - schemas: - AccountResponseBody: - properties: - email: - description: The user's email - example: example@stability.ai - format: email - type: string - id: - description: The user's ID - example: user-1234 - type: string - x-go-name: ID - organizations: - description: The user's organizations - example: - - id: org-5678 - is_default: true - name: Another Organization - role: MEMBER - - id: org-1234 - is_default: false - name: My Organization - role: MEMBER - items: - $ref: '#/components/schemas/OrganizationMembership' - type: array - profile_picture: - description: The user's profile picture - example: https://api.stability.ai/example.png - format: uri - type: string - required: - - id - - email - - organizations - type: object - BalanceResponseBody: - example: - credits: 0.07903292496944721 - properties: - credits: - description: The balance of the account/organization associated with the API key - example: 0.41122252265928866 - format: double - type: number - required: - - credits - type: object - CfgScale: - default: 7 - description: How strictly the diffusion process adheres to the prompt text (higher values keep your image closer to your prompt) - example: 7 - maximum: 35 - minimum: 0 - type: number - ClipGuidancePreset: - default: NONE - enum: - - FAST_BLUE - - FAST_GREEN - - NONE - - SIMPLE - - SLOW - - SLOWER - - SLOWEST - example: FAST_BLUE - type: string - DiffuseImageHeight: - default: 1024 - description: "Height of the image to generate, in pixels, in an increment divible by 64.\n\nEngine-specific dimension validation:\n- SDXL Beta: must\ - \ be between 128x128 and 512x896 (or 896x512); only one dimension can be greater than 512. \n- SDXL v0.9: must be one of 1024x1024, 1152x896, 1216x832,\ - \ 1344x768, 1536x640, 640x1536, 768x1344, 832x1216, or 896x1152\n- SDXL v1.0: same as SDXL v0.9\n- SD v1.6: must be between 320x320 and 1536x1536" - example: 1024 - minimum: 128 - multipleOf: 64 - type: integer - x-go-type: uint64 - DiffuseImageWidth: - default: 1024 - description: "Width of the image to generate, in pixels, in an increment divible by 64.\n\nEngine-specific dimension validation:\n- SDXL Beta: must\ - \ be between 128x128 and 512x896 (or 896x512); only one dimension can be greater than 512. \n- SDXL v0.9: must be one of 1024x1024, 1152x896, 1216x832,\ - \ 1344x768, 1536x640, 640x1536, 768x1344, 832x1216, or 896x1152\n- SDXL v1.0: same as SDXL v0.9\n- SD v1.6: must be between 320x320 and 1536x1536" - example: 1024 - minimum: 128 - multipleOf: 64 - type: integer - x-go-type: uint64 - Engine: - properties: - description: - type: string - id: - description: Unique identifier for the engine - example: stable-diffusion-v1-6 - type: string - x-go-name: ID - name: - description: Name of the engine - example: Stable Diffusion XL v1.0 - type: string - type: - description: The type of content this engine produces - enum: - - AUDIO - - CLASSIFICATION - - PICTURE - - STORAGE - - TEXT - - VIDEO - example: PICTURE - type: string - required: - - id - - name - - description - - type - type: object - Error: - properties: - id: - description: A unique identifier for this particular occurrence of the problem. - example: 296a972f-666a-44a1-a3df-c9c28a1f56c0 - type: string - x-go-name: ID - message: - description: A human-readable explanation specific to this occurrence of the problem. - example: Header parameter Authorization is required, but not found - type: string - name: - description: The short-name of this class of errors e.g. `bad_request`. - example: bad_request - type: string - required: - - name - - id - - message - - status - type: object - x-go-name: RESTError - Extras: - description: |- - Extra parameters passed to the engine. - These parameters are used for in-development or experimental features and may change - without warning, so please use with caution. - type: object - FinishReason: - description: |- - The result of the generation process. - - `SUCCESS` indicates success - - `ERROR` indicates an error - - `CONTENT_FILTERED` indicates the result affected by the content filter and may be blurred. - - This header is only present when the `Accept` is set to `image/png`. Otherwise it is returned in the response body. - enum: - - SUCCESS - - ERROR - - CONTENT_FILTERED - type: string - GenerationRequestOptionalParams: - description: Represents the optional parameters that can be passed to any generation request. - properties: - cfg_scale: - $ref: '#/components/schemas/CfgScale' - clip_guidance_preset: - $ref: '#/components/schemas/ClipGuidancePreset' - extras: - $ref: '#/components/schemas/Extras' - sampler: - $ref: '#/components/schemas/Sampler' - samples: - $ref: '#/components/schemas/Samples' - seed: - $ref: '#/components/schemas/Seed' - steps: - $ref: '#/components/schemas/Steps' - style_preset: - $ref: '#/components/schemas/StylePreset' - type: object - Image: - example: - - base64: '...very long string...' - finishReason: SUCCESS - seed: 1050625087 - - base64: '...very long string...' - finishReason: CONTENT_FILTERED - seed: 1229191277 - properties: - base64: - description: Image encoded in base64 - type: string - x-go-type-skip-optional-pointer: true - finishReason: - enum: - - SUCCESS - - ERROR - - CONTENT_FILTERED - example: CONTENT_FILTERED - type: string - x-go-type-skip-optional-pointer: true - seed: - description: The seed associated with this image - example: 1229191277 - type: number - x-go-type-skip-optional-pointer: true - type: object - ImageToImageRequestBody: - discriminator: - mapping: - IMAGE_STRENGTH: '#/components/schemas/ImageToImageUsingImageStrengthRequestBody' - STEP_SCHEDULE: '#/components/schemas/ImageToImageUsingStepScheduleRequestBody' - propertyName: init_image_mode - properties: - cfg_scale: - $ref: '#/components/schemas/CfgScale' - clip_guidance_preset: - $ref: '#/components/schemas/ClipGuidancePreset' - extras: - $ref: '#/components/schemas/Extras' - image_strength: - $ref: '#/components/schemas/InitImageStrength' - init_image: - $ref: '#/components/schemas/InitImage' - init_image_mode: - $ref: '#/components/schemas/InitImageMode' - sampler: - $ref: '#/components/schemas/Sampler' - samples: - $ref: '#/components/schemas/Samples' - seed: - $ref: '#/components/schemas/Seed' - step_schedule_end: - $ref: '#/components/schemas/StepScheduleEnd' - step_schedule_start: - $ref: '#/components/schemas/StepScheduleStart' - steps: - $ref: '#/components/schemas/Steps' - style_preset: - $ref: '#/components/schemas/StylePreset' - text_prompts: - $ref: '#/components/schemas/TextPrompts' - required: - - text_prompts - - init_image - type: object - ImageToImageUsingImageStrengthRequestBody: - allOf: - - properties: - image_strength: - $ref: '#/components/schemas/InitImageStrength' - init_image: - $ref: '#/components/schemas/InitImage' - init_image_mode: - $ref: '#/components/schemas/InitImageMode' - text_prompts: - $ref: '#/components/schemas/TextPrompts' - required: - - text_prompts - - init_image - type: object - - $ref: '#/components/schemas/GenerationRequestOptionalParams' - ImageToImageUsingStepScheduleRequestBody: - allOf: - - properties: - init_image: - $ref: '#/components/schemas/InitImage' - init_image_mode: - $ref: '#/components/schemas/InitImageMode' - step_schedule_end: - $ref: '#/components/schemas/StepScheduleEnd' - step_schedule_start: - $ref: '#/components/schemas/StepScheduleStart' - text_prompts: - $ref: '#/components/schemas/TextPrompts' - required: - - text_prompts - - init_image - type: object - - $ref: '#/components/schemas/GenerationRequestOptionalParams' - InitImage: - description: Image used to initialize the diffusion process, in lieu of random noise. - example: - format: binary - type: string - x-go-type: '[]byte' - InitImageMode: - default: IMAGE_STRENGTH - description: Whether to use `image_strength` or `step_schedule_*` to control how much influence the `init_image` has on the result. - enum: - - IMAGE_STRENGTH - - STEP_SCHEDULE - type: string - InitImageStrength: - default: 0.35 - description: | - How much influence the `init_image` has on the diffusion process. Values close to `1` will yield images very similar to the `init_image` while values close to `0` will yield images wildly different than the `init_image`. The behavior of this is meant to mirror DreamStudio's "Image Strength" slider.

This parameter is just an alternate way to set `step_schedule_start`, which is done via the calculation `1 - image_strength`. For example, passing in an Image Strength of 35% (`0.35`) would result in a `step_schedule_start` of `0.65`. - example: 0.4 - format: float - maximum: 1 - minimum: 0 - type: number - InputImage: - example: - format: binary - type: string - x-go-type: '[]byte' - LatentUpscalerUpscaleRequestBody: - properties: - cfg_scale: - $ref: '#/components/schemas/CfgScale' - height: - $ref: '#/components/schemas/UpscaleImageHeight' - image: - $ref: '#/components/schemas/InputImage' - seed: - $ref: '#/components/schemas/Seed' - steps: - $ref: '#/components/schemas/Steps' - text_prompts: - $ref: '#/components/schemas/TextPrompts' - width: - $ref: '#/components/schemas/UpscaleImageWidth' - required: - - image - type: object - ListEnginesResponseBody: - description: The engines available to your user/organization - example: - - description: Stability-AI Stable Diffusion v1.6 - id: stable-diffusion-v1-6 - name: Stable Diffusion v1.6 - type: PICTURE - - description: Stability-AI Stable Diffusion XL v1.0 - id: stable-diffusion-xl-1024-v1-0 - name: Stable Diffusion XL v1.0 - type: PICTURE - items: - $ref: '#/components/schemas/Engine' - type: array - MaskImage: - description: Optional grayscale mask that allows for influence over which pixels are eligible for diffusion and at what strength. Must be the same - dimensions as the `init_image`. Use the `mask_source` option to specify whether the white or black pixels should be inpainted. - example: - format: binary - type: string - x-go-type: '[]byte' - MaskSource: - description: |- - For any given pixel, the mask determines the strength of generation on a linear scale. This parameter determines where to source the mask from: - - `MASK_IMAGE_WHITE` will use the white pixels of the mask_image as the mask, where white pixels are completely replaced and black pixels are unchanged - - `MASK_IMAGE_BLACK` will use the black pixels of the mask_image as the mask, where black pixels are completely replaced and white pixels are unchanged - - `INIT_IMAGE_ALPHA` will use the alpha channel of the init_image as the mask, where fully transparent pixels are completely replaced and fully opaque pixels are unchanged - type: string - MaskingRequestBody: - discriminator: - mapping: - INIT_IMAGE_ALPHA: '#/components/schemas/MaskingUsingInitImageAlphaRequestBody' - MASK_IMAGE_BLACK: '#/components/schemas/MaskingUsingMaskImageRequestBody' - MASK_IMAGE_WHITE: '#/components/schemas/MaskingUsingMaskImageRequestBody' - propertyName: mask_source - properties: - cfg_scale: - $ref: '#/components/schemas/CfgScale' - clip_guidance_preset: - $ref: '#/components/schemas/ClipGuidancePreset' - extras: - $ref: '#/components/schemas/Extras' - init_image: - $ref: '#/components/schemas/InitImage' - mask_image: - $ref: '#/components/schemas/MaskImage' - mask_source: - $ref: '#/components/schemas/MaskSource' - sampler: - $ref: '#/components/schemas/Sampler' - samples: - $ref: '#/components/schemas/Samples' - seed: - $ref: '#/components/schemas/Seed' - steps: - $ref: '#/components/schemas/Steps' - style_preset: - $ref: '#/components/schemas/StylePreset' - text_prompts: - $ref: '#/components/schemas/TextPrompts' - required: - - text_prompts - - init_image - - mask_source - type: object - MaskingUsingInitImageAlphaRequestBody: - allOf: - - properties: - init_image: - $ref: '#/components/schemas/InitImage' - mask_source: - $ref: '#/components/schemas/MaskSource' - text_prompts: - $ref: '#/components/schemas/TextPrompts' - required: - - init_image - - text_prompts - - mask_source - type: object - - $ref: '#/components/schemas/GenerationRequestOptionalParams' - MaskingUsingMaskImageRequestBody: - allOf: - - properties: - init_image: - $ref: '#/components/schemas/InitImage' - mask_image: - $ref: '#/components/schemas/MaskImage' - mask_source: - $ref: '#/components/schemas/MaskSource' - text_prompts: - $ref: '#/components/schemas/TextPrompts' - required: - - init_image - - mask_image - - text_prompts - - mask_source - type: object - - $ref: '#/components/schemas/GenerationRequestOptionalParams' - OrganizationMembership: - properties: - id: - example: org-123456 - type: string - x-go-name: ID - is_default: - example: false - type: boolean - name: - example: My Organization - type: string - role: - example: MEMBER - type: string - required: - - id - - name - - role - - is_default - type: object - RealESRGANUpscaleRequestBody: - properties: - height: - $ref: '#/components/schemas/UpscaleImageHeight' - image: - $ref: '#/components/schemas/InputImage' - width: - $ref: '#/components/schemas/UpscaleImageWidth' - required: - - image - type: object - Sampler: - description: Which sampler to use for the diffusion process. If this value is omitted we'll automatically select an appropriate sampler for you. - enum: - - DDIM - - DDPM - - K_DPMPP_2M - - K_DPMPP_2S_ANCESTRAL - - K_DPM_2 - - K_DPM_2_ANCESTRAL - - K_EULER - - K_EULER_ANCESTRAL - - K_HEUN - - K_LMS - example: K_DPM_2_ANCESTRAL - type: string - Samples: - default: 1 - description: Number of images to generate - example: 1 - maximum: 10 - minimum: 1 - type: integer - x-go-type: uint64 - Seed: - default: 0 - description: Random noise seed (omit this option or use `0` for a random seed) - example: 0 - maximum: 4294967295 - minimum: 0 - type: integer - x-go-type: uint32 - StepScheduleEnd: - description: Skips a proportion of the end of the diffusion steps, allowing the init_image to influence the final generated image. Lower values will - result in more influence from the init_image, while higher values will result in more influence from the diffusion steps. - example: 0.01 - maximum: 1 - minimum: 0 - type: number - StepScheduleStart: - default: 0.65 - description: Skips a proportion of the start of the diffusion steps, allowing the init_image to influence the final generated image. Lower values - will result in more influence from the init_image, while higher values will result in more influence from the diffusion steps. (e.g. a value of - `0` would simply return you the init_image, where a value of `1` would return you a completely different image.) - example: 0.4 - maximum: 1 - minimum: 0 - type: number - Steps: - default: 30 - description: Number of diffusion steps to run. - example: 50 - maximum: 50 - minimum: 10 - type: integer - x-go-type: uint64 - StylePreset: - description: |- - Pass in a style preset to guide the image model towards a particular style. - This list of style presets is subject to change. - enum: - - enhance - - anime - - photographic - - digital-art - - comic-book - - fantasy-art - - line-art - - analog-film - - neon-punk - - isometric - - low-poly - - origami - - modeling-compound - - cinematic - - 3d-model - - pixel-art - - tile-texture - type: string - TextPrompt: - description: Text prompt for image generation - properties: - text: - description: The prompt itself - example: A lighthouse on a cliff - maxLength: 2000 - type: string - weight: - description: Weight of the prompt (use negative numbers for negative prompts) - example: 0.8167237 - format: float - type: number - required: - - text - type: object - TextPrompts: - description: "An array of text prompts to use for generation.\n\nDue to how arrays are represented in `multipart/form-data` requests, prompts must\ - \ adhere to the format `text_prompts[index][text|weight]`,\nwhere `index` is some integer used to tie the text and weight together. While `index`\ - \ does not have to be sequential, duplicate entries \nwill override previous entries, so it is recommended to use sequential indices.\n\nGiven a\ - \ text prompt with the text `A lighthouse on a cliff` and a weight of `0.5`, it would be represented as:\n```\ntext_prompts[0][text]: \"A lighthouse\ - \ on a cliff\"\ntext_prompts[0][weight]: 0.5\n```\n\nTo add another prompt to that request simply provide the values under a new `index`:\n\n```\n\ - text_prompts[0][text]: \"A lighthouse on a cliff\"\ntext_prompts[0][weight]: 0.5\ntext_prompts[1][text]: \"land, ground, dirt, grass\"\ntext_prompts[1][weight]:\ - \ -0.9\n```" - items: - $ref: '#/components/schemas/TextPrompt' - minItems: 1 - type: array - TextPromptsForTextToImage: - description: |- - An array of text prompts to use for generation. - - Given a text prompt with the text `A lighthouse on a cliff` and a weight of `0.5`, it would be represented as: - - ``` - "text_prompts": [ - { - "text": "A lighthouse on a cliff", - "weight": 0.5 - } - ] - ``` - items: - $ref: '#/components/schemas/TextPrompt' - minItems: 1 - title: TextPrompts - type: array - TextToImageRequestBody: - allOf: - - properties: - height: - $ref: '#/components/schemas/DiffuseImageHeight' - text_prompts: - $ref: '#/components/schemas/TextPromptsForTextToImage' - width: - $ref: '#/components/schemas/DiffuseImageWidth' - required: - - text_prompts - type: object - - $ref: '#/components/schemas/GenerationRequestOptionalParams' - example: - cfg_scale: 7 - clip_guidance_preset: FAST_BLUE - height: 512 - sampler: K_DPM_2_ANCESTRAL - samples: 1 - seed: 0 - steps: 30 - text_prompts: - - text: A lighthouse on a cliff - weight: 1 - width: 512 - required: - - text_prompts - type: object - UpscaleImageHeight: - description: Desired height of the output image. Only one of `width` or `height` may be specified. - minimum: 512 - type: integer - x-go-type: uint64 - UpscaleImageWidth: - description: Desired width of the output image. Only one of `width` or `height` may be specified. - minimum: 512 - type: integer - x-go-type: uint64 - securitySchemes: - STABILITY_API_KEY: - in: header - name: Authorization - type: apiKey -info: - description: "Welcome to the official Stability AI REST API!\n\n#### Authentication\n\nYou will need your Stability API key in order to make requests to this API.\nMake sure you never share your API key with anyone, and you never commit it to a public\ - \ repository. Include this key in \nthe `Authorization` header of your requests.\n\n#### Rate limiting\n\nThis API is rate-limited to 150 requests every\ - \ 10 seconds. If you exceed this limit, you will receive a `429` response.\nIf you find this limit too restrictive, please reach out to us via email\ - \ at [platform@stability.ai](mailto:platform@stability.ai).\n\n#### Support\n\nCheck our Status Page\ - \ to view the current health of our REST/gRPC APIs.\n\nIf you run into issues, please reach out to us:\n - Support Form\n - [platform@stability.ai](mailto:platform@stability.ai) \n - Discord\n" - termsOfService: https://platform.stability.ai/docs/terms-of-service - title: Stability.ai REST API - version: v1 - x-logo: - altText: Stability.ai REST API - url: /docs/StabilityLogo.png -openapi: 3.0.3 -paths: - /v1/engines/list: - get: - description: List all engines available to your organization/user - operationId: listEngines - parameters: - - $ref: '#/components/parameters/organization' - - $ref: '#/components/parameters/stabilityClientID' - - $ref: '#/components/parameters/stabilityClientVersion' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ListEnginesResponseBody' - description: OK response. - '401': - $ref: '#/components/responses/401' - '500': - $ref: '#/components/responses/500' - security: - - STABILITY_API_KEY: [] - summary: list - tags: - - v1/engines - x-codeSamples: - - lang: Python - source: |+ - import os - import requests - - api_host = os.getenv('API_HOST', 'https://api.stability.ai') - url = f"{api_host}/v1/engines/list" - - api_key = os.getenv("STABILITY_API_KEY") - if api_key is None: - raise Exception("Missing Stability API key.") - - response = requests.get(url, headers={ - "Authorization": f"Bearer {api_key}" - }) - - if response.status_code != 200: - raise Exception("Non-200 response: " + str(response.text)) - - # Do something with the payload... - payload = response.json() - - - label: TypeScript - lang: Javascript - source: | - import fetch from 'node-fetch' - - const apiHost = process.env.API_HOST ?? 'https://api.stability.ai' - const url = `${apiHost}/v1/engines/list` - - const apiKey = process.env.STABILITY_API_KEY - if (!apiKey) throw new Error('Missing Stability API key.') - - const response = await fetch(url, { - method: 'GET', - headers: { - Authorization: `Bearer ${apiKey}`, - }, - }) - - if (!response.ok) { - throw new Error(`Non-200 response: ${await response.text()}`) - } - - interface Payload { - engines: Array<{ - id: string - name: string - description: string - type: string - }> - } - - // Do something with the payload... - const payload = (await response.json()) as Payload - - lang: Go - source: "package main\n\nimport (\n\t\"io\"\n\t\"net/http\"\n\t\"os\"\n)\n\nfunc main() {\n\t// Build REST endpoint URL\n\tapiHost, hasApiHost\ - \ := os.LookupEnv(\"API_HOST\")\n\tif !hasApiHost {\n\t\tapiHost = \"https://api.stability.ai\"\n\t}\n\treqUrl := apiHost + \"/v1/engines/list\"\ - \n\n\t// Acquire an API key from the environment\n\tapiKey, hasAPIKey := os.LookupEnv(\"STABILITY_API_KEY\")\n\tif !hasAPIKey {\n\t\tpanic(\"\ - Missing STABILITY_API_KEY environment variable\")\n\t}\n\n\t// Execute the request & read all the bytes of the response\n\treq, _ := http.NewRequest(\"\ - GET\", reqUrl, nil)\n\treq.Header.Add(\"Authorization\", \"Bearer \"+apiKey)\n\tres, _ := http.DefaultClient.Do(req)\n\tdefer res.Body.Close()\n\ - \tbody, _ := io.ReadAll(res.Body)\n\n\tif res.StatusCode != 200 {\n\t\tpanic(\"Non-200 response: \" + string(body))\n\t}\n\n\t// Do something\ - \ with the payload...\n\t// payload := string(body)\n}\n" - - lang: cURL - source: | - if [ -z "$STABILITY_API_KEY" ]; then - echo "STABILITY_API_KEY environment variable is not set" - exit 1 - fi - - BASE_URL=${API_HOST:-https://api.stability.ai} - URL="$BASE_URL/v1/engines/list" - - curl -f -sS "$URL" \ - -H 'Accept: application/json' \ - -H "Authorization: Bearer $STABILITY_API_KEY" - /v1/generation/{engine_id}/image-to-image: - post: - description: Modify an image based on a text prompt - operationId: imageToImage - parameters: - - $ref: '#/components/parameters/engineID' - - $ref: '#/components/parameters/accept' - - $ref: '#/components/parameters/organization' - - $ref: '#/components/parameters/stabilityClientID' - - $ref: '#/components/parameters/stabilityClientVersion' - requestBody: - content: - multipart/form-data: - examples: - IMAGE_STRENGTH: - description: Request using 35% image_strength - summary: Using IMAGE_STRENGTH - value: - cfg_scale: 7 - clip_guidance_preset: FAST_BLUE - image_strength: 0.35 - init_image: - init_image_mode: IMAGE_STRENGTH - sampler: K_DPM_2_ANCESTRAL - samples: 3 - steps: 30 - text_prompts[0][text]: A dog space commander - text_prompts[0][weight]: 1 - STEP_SCHEDULE: - description: Equivalent request using step_schedule_start - summary: Using STEP_SCHEDULE - value: - cfg_scale: 7 - clip_guidance_preset: FAST_BLUE - init_image: - init_image_mode: STEP_SCHEDULE - sampler: K_DPM_2_ANCESTRAL - samples: 3 - step_schedule_start: 0.65 - steps: 30 - text_prompts[0][text]: A dog space commander - text_prompts[0][weight]: 1 - schema: - $ref: '#/components/schemas/ImageToImageRequestBody' - required: true - responses: - '200': - $ref: '#/components/responses/GenerationResponse' - '400': - $ref: '#/components/responses/400FromGeneration' - '401': - $ref: '#/components/responses/401' - '403': - $ref: '#/components/responses/403' - '404': - $ref: '#/components/responses/404' - '500': - $ref: '#/components/responses/500' - security: - - STABILITY_API_KEY: [] - summary: image-to-image - tags: - - v1/generation - x-codeSamples: - - lang: Python - source: | - import base64 - import os - import requests - - engine_id = "stable-diffusion-xl-1024-v1-0" - api_host = os.getenv("API_HOST", "https://api.stability.ai") - api_key = os.getenv("STABILITY_API_KEY") - - if api_key is None: - raise Exception("Missing Stability API key.") - - response = requests.post( - f"{api_host}/v1/generation/{engine_id}/image-to-image", - headers={ - "Accept": "application/json", - "Authorization": f"Bearer {api_key}" - }, - files={ - "init_image": open("../init_image_1024.png", "rb") - }, - data={ - "image_strength": 0.35, - "init_image_mode": "IMAGE_STRENGTH", - "text_prompts[0][text]": "Galactic dog with a cape", - "cfg_scale": 7, - "samples": 1, - "steps": 30, - } - ) - - if response.status_code != 200: - raise Exception("Non-200 response: " + str(response.text)) - - data = response.json() - - for i, image in enumerate(data["artifacts"]): - with open(f"./out/v1_img2img_{i}.png", "wb") as f: - f.write(base64.b64decode(image["base64"])) - - label: TypeScript - lang: Javascript - source: | - import fetch from 'node-fetch' - import FormData from 'form-data' - import fs from 'node:fs' - - const engineId = 'stable-diffusion-xl-1024-v1-0' - const apiHost = process.env.API_HOST ?? 'https://api.stability.ai' - const apiKey = process.env.STABILITY_API_KEY - - if (!apiKey) throw new Error('Missing Stability API key.') - - // NOTE: This example is using a NodeJS FormData library. - // Browsers should use their native FormData class. - // React Native apps should also use their native FormData class. - const formData = new FormData() - formData.append('init_image', fs.readFileSync('../init_image_1024.png')) - formData.append('init_image_mode', 'IMAGE_STRENGTH') - formData.append('image_strength', 0.35) - formData.append('text_prompts[0][text]', 'Galactic dog wearing a cape') - formData.append('cfg_scale', 7) - formData.append('samples', 1) - formData.append('steps', 30) - - const response = await fetch( - `${apiHost}/v1/generation/${engineId}/image-to-image`, - { - method: 'POST', - headers: { - ...formData.getHeaders(), - Accept: 'application/json', - Authorization: `Bearer ${apiKey}`, - }, - body: formData, - } - ) - - if (!response.ok) { - throw new Error(`Non-200 response: ${await response.text()}`) - } - - interface GenerationResponse { - artifacts: Array<{ - base64: string - seed: number - finishReason: string - }> - } - - const responseJSON = (await response.json()) as GenerationResponse - - responseJSON.artifacts.forEach((image, index) => { - fs.writeFileSync( - `out/v1_img2img_${index}.png`, - Buffer.from(image.base64, 'base64') - ) - }) - - lang: Go - source: "package main\n\nimport (\n\t\"bytes\"\n\t\"encoding/base64\"\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"io\"\n\t\"mime/multipart\"\n\t\"net/http\"\ - \n\t\"os\"\n)\n\ntype ImageToImageImage struct {\n\tBase64 string `json:\"base64\"`\n\tSeed uint32 `json:\"seed\"`\n\tFinishReason\ - \ string `json:\"finishReason\"`\n}\n\ntype ImageToImageResponse struct {\n\tImages []ImageToImageImage `json:\"artifacts\"`\n}\n\nfunc main()\ - \ {\n\tengineId := \"stable-diffusion-xl-1024-v1-0\"\n\n\t// Build REST endpoint URL\n\tapiHost, hasApiHost := os.LookupEnv(\"API_HOST\")\n\t\ - if !hasApiHost {\n\t\tapiHost = \"https://api.stability.ai\"\n\t}\n\treqUrl := apiHost + \"/v1/generation/\" + engineId + \"/image-to-image\"\ - \n\n\t// Acquire an API key from the environment\n\tapiKey, hasAPIKey := os.LookupEnv(\"STABILITY_API_KEY\")\n\tif !hasAPIKey {\n\t\tpanic(\"\ - Missing STABILITY_API_KEY environment variable\")\n\t}\n\n\tdata := &bytes.Buffer{}\n\twriter := multipart.NewWriter(data)\n\n\t// Write the\ - \ init image to the request\n\tinitImageWriter, _ := writer.CreateFormField(\"init_image\")\n\tinitImageFile, initImageErr := os.Open(\"../init_image_1024.png\"\ - )\n\tif initImageErr != nil {\n\t\tpanic(\"Could not open init_image.png\")\n\t}\n\t_, _ = io.Copy(initImageWriter, initImageFile)\n\n\t// Write\ - \ the options to the request\n\t_ = writer.WriteField(\"init_image_mode\", \"IMAGE_STRENGTH\")\n\t_ = writer.WriteField(\"image_strength\",\ - \ \"0.35\")\n\t_ = writer.WriteField(\"text_prompts[0][text]\", \"Galactic dog with a cape\")\n\t_ = writer.WriteField(\"cfg_scale\", \"7\"\ - )\n\t_ = writer.WriteField(\"samples\", \"1\")\n\t_ = writer.WriteField(\"steps\", \"30\")\n\twriter.Close()\n\n\t// Execute the request\n\t\ - payload := bytes.NewReader(data.Bytes())\n\treq, _ := http.NewRequest(\"POST\", reqUrl, payload)\n\treq.Header.Add(\"Content-Type\", writer.FormDataContentType())\n\ - \treq.Header.Add(\"Accept\", \"application/json\")\n\treq.Header.Add(\"Authorization\", \"Bearer \"+apiKey)\n\tres, _ := http.DefaultClient.Do(req)\n\ - \tdefer res.Body.Close()\n\n\tif res.StatusCode != 200 {\n\t\tvar body map[string]interface{}\n\t\tif err := json.NewDecoder(res.Body).Decode(&body);\ - \ err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\tpanic(fmt.Sprintf(\"Non-200 response: %s\", body))\n\t}\n\n\t// Decode the JSON body\n\tvar body\ - \ ImageToImageResponse\n\tif err := json.NewDecoder(res.Body).Decode(&body); err != nil {\n\t\tpanic(err)\n\t}\n\n\t// Write the images to disk\n\ - \tfor i, image := range body.Images {\n\t\toutFile := fmt.Sprintf(\"./out/v1_img2img_%d.png\", i)\n\t\tfile, err := os.Create(outFile)\n\t\t\ - if err != nil {\n\t\t\tpanic(err)\n\t\t}\n\n\t\timageBytes, err := base64.StdEncoding.DecodeString(image.Base64)\n\t\tif err != nil {\n\t\t\t\ - panic(err)\n\t\t}\n\n\t\tif _, err := file.Write(imageBytes); err != nil {\n\t\t\tpanic(err)\n\t\t}\n\n\t\tif err := file.Close(); err != nil\ - \ {\n\t\t\tpanic(err)\n\t\t}\n\t}\n}\n" - - lang: cURL - source: | - if [ -z "$STABILITY_API_KEY" ]; then - echo "STABILITY_API_KEY environment variable is not set" - exit 1 - fi - - OUTPUT_FILE=./out/v1_img2img.png - BASE_URL=${API_HOST:-https://api.stability.ai} - URL="$BASE_URL/v1/generation/stable-diffusion-xl-1024-v1-0/image-to-image" - - curl -f -sS -X POST "$URL" \ - -H 'Content-Type: multipart/form-data' \ - -H 'Accept: image/png' \ - -H "Authorization: Bearer $STABILITY_API_KEY" \ - -F 'init_image=@"../init_image_1024.png"' \ - -F 'init_image_mode=IMAGE_STRENGTH' \ - -F 'image_strength=0.35' \ - -F 'text_prompts[0][text]=A galactic dog in space' \ - -F 'cfg_scale=7' \ - -F 'samples=1' \ - -F 'steps=30' \ - -o "$OUTPUT_FILE" - /v1/generation/{engine_id}/image-to-image/masking: - post: - description: Selectively modify portions of an image using a mask - operationId: masking - parameters: - - example: stable-diffusion-xl-1024-v1-0 - in: path - name: engine_id - required: true - schema: - type: string - - $ref: '#/components/parameters/accept' - - $ref: '#/components/parameters/organization' - - $ref: '#/components/parameters/stabilityClientID' - - $ref: '#/components/parameters/stabilityClientVersion' - requestBody: - content: - multipart/form-data: - examples: - INIT_IMAGE_ALPHA: - value: - cfg_scale: 7 - clip_guidance_preset: FAST_BLUE - init_image: - mask_source: INIT_IMAGE_ALPHA - sampler: K_DPM_2_ANCESTRAL - samples: 3 - steps: 30 - text_prompts[0][text]: A dog space commander - text_prompts[0][weight]: 1 - MASK_IMAGE_BLACK: - value: - cfg_scale: 7 - clip_guidance_preset: FAST_BLUE - init_image: - mask_image: - mask_source: MASK_IMAGE_BLACK - sampler: K_DPM_2_ANCESTRAL - samples: 3 - steps: 30 - text_prompts[0][text]: A dog space commander - text_prompts[0][weight]: 1 - MASK_IMAGE_WHITE: - value: - cfg_scale: 7 - clip_guidance_preset: FAST_BLUE - init_image: - mask_image: - mask_source: MASK_IMAGE_WHITE - sampler: K_DPM_2_ANCESTRAL - samples: 3 - steps: 30 - text_prompts[0][text]: A dog space commander - text_prompts[0][weight]: 1 - schema: - $ref: '#/components/schemas/MaskingRequestBody' - required: true - responses: - '200': - $ref: '#/components/responses/GenerationResponse' - '400': - $ref: '#/components/responses/400FromGeneration' - '401': - $ref: '#/components/responses/401' - '403': - $ref: '#/components/responses/403' - '404': - $ref: '#/components/responses/404' - '500': - $ref: '#/components/responses/500' - security: - - STABILITY_API_KEY: [] - summary: image-to-image/masking - tags: - - v1/generation - x-codeSamples: - - lang: Python - source: | - import base64 - import os - import requests - - engine_id = "stable-diffusion-xl-1024-v1-0" - api_host = os.getenv('API_HOST', 'https://api.stability.ai') - api_key = os.getenv("STABILITY_API_KEY") - - if api_key is None: - raise Exception("Missing Stability API key.") - - response = requests.post( - f"{api_host}/v1/generation/{engine_id}/image-to-image/masking", - headers={ - "Accept": 'application/json', - "Authorization": f"Bearer {api_key}" - }, - files={ - 'init_image': open("../init_image_1024.png", 'rb'), - 'mask_image': open("../mask_image_black_1024.png", 'rb'), - }, - data={ - "mask_source": "MASK_IMAGE_BLACK", - "text_prompts[0][text]": "A large spiral galaxy with a bright central bulge and a ring of stars around it", - "cfg_scale": 7, - "clip_guidance_preset": "FAST_BLUE", - "samples": 1, - "steps": 30, - } - ) - - if response.status_code != 200: - raise Exception("Non-200 response: " + str(response.text)) - - data = response.json() - - for i, image in enumerate(data["artifacts"]): - with open(f"./out/v1_img2img_masking_{i}.png", "wb") as f: - f.write(base64.b64decode(image["base64"])) - - label: TypeScript - lang: Javascript - source: | - import fetch from 'node-fetch' - import FormData from 'form-data' - import fs from 'node:fs' - - const engineId = 'stable-diffusion-xl-1024-v1-0' - const apiHost = process.env.API_HOST ?? 'https://api.stability.ai' - const apiKey = process.env.STABILITY_API_KEY - - if (!apiKey) throw new Error('Missing Stability API key.') - - // NOTE: This example is using a NodeJS FormData library. Browser - // implementations should use their native FormData class. React Native - // implementations should also use their native FormData class. - const formData = new FormData() - formData.append('init_image', fs.readFileSync('../init_image_1024.png')) - formData.append('mask_image', fs.readFileSync('../mask_image_black_1024.png')) - formData.append('mask_source', 'MASK_IMAGE_BLACK') - formData.append( - 'text_prompts[0][text]', - 'A large spiral galaxy with a bright central bulge and a ring of stars around it' - ) - formData.append('cfg_scale', '7') - formData.append('clip_guidance_preset', 'FAST_BLUE') - formData.append('samples', 1) - formData.append('steps', 30) - - const response = await fetch( - `${apiHost}/v1/generation/${engineId}/image-to-image/masking`, - { - method: 'POST', - headers: { - ...formData.getHeaders(), - Accept: 'application/json', - Authorization: `Bearer ${apiKey}`, - }, - body: formData, - } - ) - - if (!response.ok) { - throw new Error(`Non-200 response: ${await response.text()}`) - } - - interface GenerationResponse { - artifacts: Array<{ - base64: string - seed: number - finishReason: string - }> - } - - const responseJSON = (await response.json()) as GenerationResponse - - responseJSON.artifacts.forEach((image, index) => { - fs.writeFileSync( - `out/v1_img2img_masking_${index}.png`, - Buffer.from(image.base64, 'base64') - ) - }) - - lang: Go - source: "package main\n\nimport (\n\t\"bytes\"\n\t\"encoding/base64\"\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"io\"\n\t\"mime/multipart\"\n\t\"net/http\"\ - \n\t\"os\"\n)\n\ntype MaskingImage struct {\n\tBase64 string `json:\"base64\"`\n\tSeed uint32 `json:\"seed\"`\n\tFinishReason\ - \ string `json:\"finishReason\"`\n}\n\ntype MaskingResponse struct {\n\tImages []MaskingImage `json:\"artifacts\"`\n}\n\nfunc main() {\n\tengineId\ - \ := \"stable-diffusion-xl-1024-v1-0\"\n\n\t// Build REST endpoint URL\n\tapiHost, hasApiHost := os.LookupEnv(\"API_HOST\")\n\tif !hasApiHost\ - \ {\n\t\tapiHost = \"https://api.stability.ai\"\n\t}\n\treqUrl := apiHost + \"/v1/generation/\" + engineId + \"/image-to-image/masking\"\n\n\ - \t// Acquire an API key from the environment\n\tapiKey, hasAPIKey := os.LookupEnv(\"STABILITY_API_KEY\")\n\tif !hasAPIKey {\n\t\tpanic(\"Missing\ - \ STABILITY_API_KEY environment variable\")\n\t}\n\n\tdata := &bytes.Buffer{}\n\twriter := multipart.NewWriter(data)\n\n\t// Write the init\ - \ image to the request\n\tinitImageWriter, _ := writer.CreateFormField(\"init_image\")\n\tinitImageFile, initImageErr := os.Open(\"../init_image_1024.png\"\ - )\n\tif initImageErr != nil {\n\t\tpanic(\"Could not open init_image.png\")\n\t}\n\t_, _ = io.Copy(initImageWriter, initImageFile)\n\n\t// Write\ - \ the mask image to the request\n\tmaskImageWriter, _ := writer.CreateFormField(\"mask_image\")\n\tmaskImageFile, maskImageErr := os.Open(\"\ - ../mask_image_black_1024.png\")\n\tif maskImageErr != nil {\n\t\tpanic(\"Could not open mask_image_white.png\")\n\t}\n\t_, _ = io.Copy(maskImageWriter,\ - \ maskImageFile)\n\n\t// Write the options to the request\n\t_ = writer.WriteField(\"mask_source\", \"MASK_IMAGE_BLACK\")\n\t_ = writer.WriteField(\"\ - text_prompts[0][text]\", \"A large spiral galaxy with a bright central bulge and a ring of stars around it\")\n\t_ = writer.WriteField(\"cfg_scale\"\ - , \"7\")\n\t_ = writer.WriteField(\"clip_guidance_preset\", \"FAST_BLUE\")\n\t_ = writer.WriteField(\"samples\", \"1\")\n\t_ = writer.WriteField(\"\ - steps\", \"30\")\n\twriter.Close()\n\n\t// Execute the request & read all the bytes of the response\n\tpayload := bytes.NewReader(data.Bytes())\n\ - \treq, _ := http.NewRequest(\"POST\", reqUrl, payload)\n\treq.Header.Add(\"Content-Type\", writer.FormDataContentType())\n\treq.Header.Add(\"\ - Accept\", \"application/json\")\n\treq.Header.Add(\"Authorization\", \"Bearer \"+apiKey)\n\tres, _ := http.DefaultClient.Do(req)\n\tdefer res.Body.Close()\n\ - \n\tif res.StatusCode != 200 {\n\t\tvar body map[string]interface{}\n\t\tif err := json.NewDecoder(res.Body).Decode(&body); err != nil {\n\t\ - \t\tpanic(err)\n\t\t}\n\t\tpanic(fmt.Sprintf(\"Non-200 response: %s\", body))\n\t}\n\n\t// Decode the JSON body\n\tvar body MaskingResponse\n\ - \tif err := json.NewDecoder(res.Body).Decode(&body); err != nil {\n\t\tpanic(err)\n\t}\n\n\t// Write the images to disk\n\tfor i, image := range\ - \ body.Images {\n\t\toutFile := fmt.Sprintf(\"./out/v1_img2img_masking_%d.png\", i)\n\t\tfile, err := os.Create(outFile)\n\t\tif err != nil\ - \ {\n\t\t\tpanic(err)\n\t\t}\n\n\t\timageBytes, err := base64.StdEncoding.DecodeString(image.Base64)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\ - \t\t}\n\n\t\tif _, err := file.Write(imageBytes); err != nil {\n\t\t\tpanic(err)\n\t\t}\n\n\t\tif err := file.Close(); err != nil {\n\t\t\t\ - panic(err)\n\t\t}\n\t}\n}\n" - - lang: cURL - source: | - #!/bin/sh - - set -e - - if [ -z "$STABILITY_API_KEY" ]; then - echo "STABILITY_API_KEY environment variable is not set" - exit 1 - fi - - OUTPUT_FILE=./out/v1_img2img_masking.png - BASE_URL=${API_HOST:-https://api.stability.ai} - URL="$BASE_URL/v1/generation/stable-diffusion-xl-1024-v1-0/image-to-image/masking" - - curl -f -sS -X POST "$URL" \ - -H 'Content-Type: multipart/form-data' \ - -H 'Accept: image/png' \ - -H "Authorization: Bearer $STABILITY_API_KEY" \ - -F 'init_image=@"../init_image_1024.png"' \ - -F 'mask_image=@"../mask_image_black_1024.png"' \ - -F 'mask_source=MASK_IMAGE_BLACK' \ - -F 'text_prompts[0][text]=A large spiral galaxy with a bright central bulge and a ring of stars around it' \ - -F 'cfg_scale=7' \ - -F 'clip_guidance_preset=FAST_BLUE' \ - -F 'samples=1' \ - -F 'steps=30' \ - -o "$OUTPUT_FILE" - /v1/generation/{engine_id}/image-to-image/upscale: - post: - description: | - Create a higher resolution version of an input image. - - This operation outputs an image with a maximum pixel count of **4,194,304**. This is equivalent to dimensions such as `2048x2048` and `4096x1024`. - - By default, the input image will be upscaled by a factor of 2. For additional control over the output dimensions, a `width` or `height` parameter may be specified. - - For upscaler engines that are ESRGAN-based, refer to the `RealESRGANUpscaleRequestBody` body option below. For upscaler engines that are Stable Diffusion Latent Upscaler-based, refer to the `LatentUpscalerUpscaleRequestBody` body option below. - - For more details on the upscaler engines, refer to the [documentation on the Platform site.](https://platform.stability.ai/docs/features/image-upscaling?tab=python) - operationId: upscaleImage - parameters: - - $ref: '#/components/parameters/upscaleEngineID' - - $ref: '#/components/parameters/accept' - - $ref: '#/components/parameters/organization' - - $ref: '#/components/parameters/stabilityClientID' - - $ref: '#/components/parameters/stabilityClientVersion' - requestBody: - content: - multipart/form-data: - examples: - DESIRED_HEIGHT: - description: Upscale input image to desired height with ESRGAN or the Latent Upscaler. - value: - height: 1024 - image: - DESIRED_WIDTH: - description: Upscale input image to desired width with ESRGAN or the Latent Upscaler. - value: - image: - width: 1024 - ESRGAN: - description: Upscale input image by 2x using ESRGAN. - value: - image: - LATENT_UPSCALER: - description: Request using the Latent Upscaler. Refer to the LatentUpscalerUpscaleRequestBody for reference. - value: - cfg_scale: 7 - image: - seed: 5555 - steps: 30 - text_prompts[0][text]: A dog space commander - text_prompts[0][weight]: 1 - schema: - oneOf: - - $ref: '#/components/schemas/RealESRGANUpscaleRequestBody' - - $ref: '#/components/schemas/LatentUpscalerUpscaleRequestBody' - required: true - responses: - '200': - $ref: '#/components/responses/GenerationResponse' - '400': - $ref: '#/components/responses/400FromUpscale' - '401': - $ref: '#/components/responses/401' - '403': - $ref: '#/components/responses/403' - '404': - $ref: '#/components/responses/404' - '500': - $ref: '#/components/responses/500' - security: - - STABILITY_API_KEY: [] - summary: image-to-image/upscale - tags: - - v1/generation - x-codeSamples: - - lang: Python - source: | - import os - import requests - - engine_id = "esrgan-v1-x2plus" - api_host = os.getenv("API_HOST", "https://api.stability.ai") - api_key = os.getenv("STABILITY_API_KEY") - - if api_key is None: - raise Exception("Missing Stability API key.") - - response = requests.post( - f"{api_host}/v1/generation/{engine_id}/image-to-image/upscale", - headers={ - "Accept": "image/png", - "Authorization": f"Bearer {api_key}" - }, - files={ - "image": open("../init_image.png", "rb") - }, - data={ - "width": 1024, - } - ) - - if response.status_code != 200: - raise Exception("Non-200 response: " + str(response.text)) - - with open(f"./out/v1_upscaled_image.png", "wb") as f: - f.write(response.content) - - label: TypeScript - lang: Javascript - source: | - import fetch from 'node-fetch' - import FormData from 'form-data' - import fs from 'node:fs' - - const engineId = 'esrgan-v1-x2plus' - const apiHost = process.env.API_HOST ?? 'https://api.stability.ai' - const apiKey = process.env.STABILITY_API_KEY - - if (!apiKey) throw new Error('Missing Stability API key.') - - // NOTE: This example is using a NodeJS FormData library. - // Browsers should use their native FormData class. - // React Native apps should also use their native FormData class. - const formData = new FormData() - formData.append('image', fs.readFileSync('../init_image.png')) - formData.append('width', 1024) - - const response = await fetch( - `${apiHost}/v1/generation/${engineId}/image-to-image/upscale`, - { - method: 'POST', - headers: { - ...formData.getHeaders(), - Accept: 'image/png', - Authorization: `Bearer ${apiKey}`, - }, - body: formData, - } - ) - - if (!response.ok) { - throw new Error(`Non-200 response: ${await response.text()}`) - } - - const image = await response.arrayBuffer() - fs.writeFileSync('./out/v1_upscaled_image.png', Buffer.from(image)) - - lang: Go - source: "package main\n\nimport (\n\t\"bytes\"\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"io\"\n\t\"mime/multipart\"\n\t\"net/http\"\n\t\"os\"\n)\n\n\ - func main() {\n\tengineId := \"esrgan-v1-x2plus\"\n\n\t// Build REST endpoint URL\n\tapiHost, hasApiHost := os.LookupEnv(\"API_HOST\")\n\tif\ - \ !hasApiHost {\n\t\tapiHost = \"https://api.stability.ai\"\n\t}\n\treqUrl := apiHost + \"/v1/generation/\" + engineId + \"/image-to-image/upscale\"\ - \n\n\t// Acquire an API key from the environment\n\tapiKey, hasAPIKey := os.LookupEnv(\"STABILITY_API_KEY\")\n\tif !hasAPIKey {\n\t\tpanic(\"\ - Missing STABILITY_API_KEY environment variable\")\n\t}\n\n\tdata := &bytes.Buffer{}\n\twriter := multipart.NewWriter(data)\n\n\t// Write the\ - \ init image to the request\n\tinitImageWriter, _ := writer.CreateFormField(\"image\")\n\tinitImageFile, initImageErr := os.Open(\"../init_image.png\"\ - )\n\tif initImageErr != nil {\n\t\tpanic(\"Could not open init_image.png\")\n\t}\n\t_, _ = io.Copy(initImageWriter, initImageFile)\n\n\t// Write\ - \ the options to the request\n\t_ = writer.WriteField(\"width\", \"1024\")\n\twriter.Close()\n\n\t// Execute the request\n\tpayload := bytes.NewReader(data.Bytes())\n\ - \treq, _ := http.NewRequest(\"POST\", reqUrl, payload)\n\treq.Header.Add(\"Content-Type\", writer.FormDataContentType())\n\treq.Header.Add(\"\ - Accept\", \"image/png\")\n\treq.Header.Add(\"Authorization\", \"Bearer \"+apiKey)\n\tres, _ := http.DefaultClient.Do(req)\n\tdefer res.Body.Close()\n\ - \n\tif res.StatusCode != 200 {\n\t\tvar body map[string]interface{}\n\t\tif err := json.NewDecoder(res.Body).Decode(&body); err != nil {\n\t\ - \t\tpanic(err)\n\t\t}\n\t\tpanic(fmt.Sprintf(\"Non-200 response: %s\", body))\n\t}\n\n\t// Write the response to a file\n\tout, err := os.Create(\"\ - ./out/v1_upscaled_image.png\")\n\tdefer out.Close()\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\t_, err = io.Copy(out, res.Body)\n\tif err !=\ - \ nil {\n\t\tpanic(err)\n\t}\n}\n" - - lang: cURL - source: | - if [ -z "$STABILITY_API_KEY" ]; then - echo "STABILITY_API_KEY environment variable is not set" - exit 1 - fi - - OUTPUT_FILE=./out/v1_upscaled_image.png - BASE_URL=${API_HOST:-https://api.stability.ai} - URL="$BASE_URL/v1/generation/esrgan-v1-x2plus/image-to-image/upscale" - - curl -f -sS -X POST "$URL" \ - -H 'Content-Type: multipart/form-data' \ - -H 'Accept: image/png' \ - -H "Authorization: Bearer $STABILITY_API_KEY" \ - -F 'image=@"../init_image.png"' \ - -F 'width=1024' \ - -o "$OUTPUT_FILE" - /v1/generation/{engine_id}/text-to-image: - post: - description: Generate a new image from a text prompt - operationId: textToImage - parameters: - - $ref: '#/components/parameters/engineID' - - $ref: '#/components/parameters/accept' - - $ref: '#/components/parameters/organization' - - $ref: '#/components/parameters/stabilityClientID' - - $ref: '#/components/parameters/stabilityClientVersion' - requestBody: - content: - application/json: - example: - cfg_scale: 7 - clip_guidance_preset: FAST_BLUE - height: 512 - sampler: K_DPM_2_ANCESTRAL - samples: 1 - steps: 30 - text_prompts: - - text: A lighthouse on a cliff - weight: 1 - width: 512 - schema: - $ref: '#/components/schemas/TextToImageRequestBody' - required: true - responses: - '200': - $ref: '#/components/responses/GenerationResponse' - '400': - $ref: '#/components/responses/400FromGeneration' - '401': - $ref: '#/components/responses/401' - '403': - $ref: '#/components/responses/403' - '404': - $ref: '#/components/responses/404' - '500': - $ref: '#/components/responses/500' - security: - - STABILITY_API_KEY: [] - summary: text-to-image - tags: - - v1/generation - x-codeSamples: - - lang: Python - source: | - import base64 - import os - import requests - - engine_id = "stable-diffusion-v1-6" - api_host = os.getenv('API_HOST', 'https://api.stability.ai') - api_key = os.getenv("STABILITY_API_KEY") - - if api_key is None: - raise Exception("Missing Stability API key.") - - response = requests.post( - f"{api_host}/v1/generation/{engine_id}/text-to-image", - headers={ - "Content-Type": "application/json", - "Accept": "application/json", - "Authorization": f"Bearer {api_key}" - }, - json={ - "text_prompts": [ - { - "text": "A lighthouse on a cliff" - } - ], - "cfg_scale": 7, - "height": 1024, - "width": 1024, - "samples": 1, - "steps": 30, - }, - ) - - if response.status_code != 200: - raise Exception("Non-200 response: " + str(response.text)) - - data = response.json() - - for i, image in enumerate(data["artifacts"]): - with open(f"./out/v1_txt2img_{i}.png", "wb") as f: - f.write(base64.b64decode(image["base64"])) - - label: TypeScript - lang: Javascript - source: | - import fetch from 'node-fetch' - import fs from 'node:fs' - - const engineId = 'stable-diffusion-v1-6' - const apiHost = process.env.API_HOST ?? 'https://api.stability.ai' - const apiKey = process.env.STABILITY_API_KEY - - if (!apiKey) throw new Error('Missing Stability API key.') - - const response = await fetch( - `${apiHost}/v1/generation/${engineId}/text-to-image`, - { - method: 'POST', - headers: { - 'Content-Type': 'application/json', - Accept: 'application/json', - Authorization: `Bearer ${apiKey}`, - }, - body: JSON.stringify({ - text_prompts: [ - { - text: 'A lighthouse on a cliff', - }, - ], - cfg_scale: 7, - height: 1024, - width: 1024, - steps: 30, - samples: 1, - }), - } - ) - - if (!response.ok) { - throw new Error(`Non-200 response: ${await response.text()}`) - } - - interface GenerationResponse { - artifacts: Array<{ - base64: string - seed: number - finishReason: string - }> - } - - const responseJSON = (await response.json()) as GenerationResponse - - responseJSON.artifacts.forEach((image, index) => { - fs.writeFileSync( - `./out/v1_txt2img_${index}.png`, - Buffer.from(image.base64, 'base64') - ) - }) - - lang: Go - source: "package main\n\nimport (\n\t\"bytes\"\n\t\"encoding/base64\"\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"net/http\"\n\t\"os\"\n)\n\ntype TextToImageImage\ - \ struct {\n\tBase64 string `json:\"base64\"`\n\tSeed uint32 `json:\"seed\"`\n\tFinishReason string `json:\"finishReason\"`\n\ - }\n\ntype TextToImageResponse struct {\n\tImages []TextToImageImage `json:\"artifacts\"`\n}\n\nfunc main() {\n\t// Build REST endpoint URL w/\ - \ specified engine\n\tengineId := \"stable-diffusion-v1-6\"\n\tapiHost, hasApiHost := os.LookupEnv(\"API_HOST\")\n\tif !hasApiHost {\n\t\tapiHost\ - \ = \"https://api.stability.ai\"\n\t}\n\treqUrl := apiHost + \"/v1/generation/\" + engineId + \"/text-to-image\"\n\n\t// Acquire an API key\ - \ from the environment\n\tapiKey, hasAPIKey := os.LookupEnv(\"STABILITY_API_KEY\")\n\tif !hasAPIKey {\n\t\tpanic(\"Missing STABILITY_API_KEY\ - \ environment variable\")\n\t}\n\n\tvar data = []byte(`{\n\t\t\"text_prompts\": [\n\t\t {\n\t\t\t\"text\": \"A lighthouse on a cliff\"\n\t\t\ - \ }\n\t\t],\n\t\t\"cfg_scale\": 7,\n\t\t\"height\": 1024,\n\t\t\"width\": 1024,\n\t\t\"samples\": 1,\n\t\t\"steps\": 30\n \t}`)\n\n\treq,\ - \ _ := http.NewRequest(\"POST\", reqUrl, bytes.NewBuffer(data))\n\treq.Header.Add(\"Content-Type\", \"application/json\")\n\treq.Header.Add(\"\ - Accept\", \"application/json\")\n\treq.Header.Add(\"Authorization\", \"Bearer \"+apiKey)\n\n\t// Execute the request & read all the bytes of\ - \ the body\n\tres, _ := http.DefaultClient.Do(req)\n\tdefer res.Body.Close()\n\n\tif res.StatusCode != 200 {\n\t\tvar body map[string]interface{}\n\ - \t\tif err := json.NewDecoder(res.Body).Decode(&body); err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\tpanic(fmt.Sprintf(\"Non-200 response: %s\"\ - , body))\n\t}\n\n\t// Decode the JSON body\n\tvar body TextToImageResponse\n\tif err := json.NewDecoder(res.Body).Decode(&body); err != nil\ - \ {\n\t\tpanic(err)\n\t}\n\n\t// Write the images to disk\n\tfor i, image := range body.Images {\n\t\toutFile := fmt.Sprintf(\"./out/v1_txt2img_%d.png\"\ - , i)\n\t\tfile, err := os.Create(outFile)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\n\t\timageBytes, err := base64.StdEncoding.DecodeString(image.Base64)\n\ - \t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\n\t\tif _, err := file.Write(imageBytes); err != nil {\n\t\t\tpanic(err)\n\t\t}\n\n\t\tif err\ - \ := file.Close(); err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t}\n}\n" - - lang: cURL - source: | - if [ -z "$STABILITY_API_KEY" ]; then - echo "STABILITY_API_KEY environment variable is not set" - exit 1 - fi - - OUTPUT_FILE=./out/v1_txt2img.png - BASE_URL=${API_HOST:-https://api.stability.ai} - URL="$BASE_URL/v1/generation/stable-diffusion-v1-6/text-to-image" - - curl -f -sS -X POST "$URL" \ - -H 'Content-Type: application/json' \ - -H 'Accept: image/png' \ - -H "Authorization: Bearer $STABILITY_API_KEY" \ - --data-raw '{ - "text_prompts": [ - { - "text": "A lighthouse on a cliff" - } - ], - "cfg_scale": 7, - "height": 1024, - "width": 1024, - "samples": 1, - "steps": 30 - }' \ - -o "$OUTPUT_FILE" - /v1/user/account: - get: - description: Get information about the account associated with the provided API key - operationId: userAccount - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/AccountResponseBody' - description: OK response. - '401': - $ref: '#/components/responses/401' - '500': - $ref: '#/components/responses/500' - security: - - STABILITY_API_KEY: [] - summary: account - tags: - - v1/user - x-codeSamples: - - lang: Python - source: |+ - import os - import requests - - api_host = os.getenv('API_HOST', 'https://api.stability.ai') - url = f"{api_host}/v1/user/account" - - api_key = os.getenv("STABILITY_API_KEY") - if api_key is None: - raise Exception("Missing Stability API key.") - - response = requests.get(url, headers={ - "Authorization": f"Bearer {api_key}" - }) - - if response.status_code != 200: - raise Exception("Non-200 response: " + str(response.text)) - - # Do something with the payload... - payload = response.json() - - - label: TypeScript - lang: Javascript - source: | - import fetch from 'node-fetch' - - const apiHost = process.env.API_HOST ?? 'https://api.stability.ai' - const url = `${apiHost}/v1/user/account` - - const apiKey = process.env.STABILITY_API_KEY - if (!apiKey) throw new Error('Missing Stability API key.') - - const response = await fetch(url, { - method: 'GET', - headers: { - Authorization: `Bearer ${apiKey}`, - }, - }) - - if (!response.ok) { - throw new Error(`Non-200 response: ${await response.text()}`) - } - - interface User { - id: string - profile_picture: string - email: string - organizations?: Array<{ - id: string - name: string - role: string - is_default: boolean - }> - } - - // Do something with the user... - const user = (await response.json()) as User - - lang: Go - source: "package main\n\nimport (\n\t\"io\"\n\t\"net/http\"\n\t\"os\"\n)\n\nfunc main() {\n\t// Build REST endpoint URL\n\tapiHost, hasApiHost\ - \ := os.LookupEnv(\"API_HOST\")\n\tif !hasApiHost {\n\t\tapiHost = \"https://api.stability.ai\"\n\t}\n\treqUrl := apiHost + \"/v1/user/account\"\ - \n\n\t// Acquire an API key from the environment\n\tapiKey, hasAPIKey := os.LookupEnv(\"STABILITY_API_KEY\")\n\tif !hasAPIKey {\n\t\tpanic(\"\ - Missing STABILITY_API_KEY environment variable\")\n\t}\n\n\t// Build the request\n\treq, _ := http.NewRequest(\"GET\", reqUrl, nil)\n\treq.Header.Add(\"\ - Authorization\", \"Bearer \"+apiKey)\n\n\t// Execute the request\n\tres, _ := http.DefaultClient.Do(req)\n\tdefer res.Body.Close()\n\tbody,\ - \ _ := io.ReadAll(res.Body)\n\n\tif res.StatusCode != 200 {\n\t\tpanic(\"Non-200 response: \" + string(body))\n\t}\n\n\t// Do something with\ - \ the payload...\n\t// payload := string(body)\n}\n" - - lang: cURL - source: | - if [ -z "$STABILITY_API_KEY" ]; then - echo "STABILITY_API_KEY environment variable is not set" - exit 1 - fi - - # Determine the URL to use for the request - BASE_URL=${API_HOST:-https://api.stability.ai} - URL="$BASE_URL/v1/user/account" - - curl -f -sS "$URL" \ - -H 'Accept: application/json' \ - -H "Authorization: Bearer $STABILITY_API_KEY" - /v1/user/balance: - get: - description: Get the credit balance of the account/organization associated with the API key - operationId: userBalance - parameters: - - $ref: '#/components/parameters/organization' - - $ref: '#/components/parameters/stabilityClientID' - - $ref: '#/components/parameters/stabilityClientVersion' - responses: - '200': - content: - application/json: - example: - credits: 0.6336833840314097 - schema: - $ref: '#/components/schemas/BalanceResponseBody' - description: OK response. - '401': - $ref: '#/components/responses/401' - '500': - $ref: '#/components/responses/500' - security: - - STABILITY_API_KEY: [] - summary: balance - tags: - - v1/user - x-codeSamples: - - lang: Python - source: |+ - import os - import requests - - api_host = os.getenv('API_HOST', 'https://api.stability.ai') - url = f"{api_host}/v1/user/balance" - - api_key = os.getenv("STABILITY_API_KEY") - if api_key is None: - raise Exception("Missing Stability API key.") - - response = requests.get(url, headers={ - "Authorization": f"Bearer {api_key}" - }) - - if response.status_code != 200: - raise Exception("Non-200 response: " + str(response.text)) - - # Do something with the payload... - payload = response.json() - - - label: TypeScript - lang: Javascript - source: | - import fetch from 'node-fetch' - - const apiHost = process.env.API_HOST ?? 'https://api.stability.ai' - const url = `${apiHost}/v1/user/balance` - - const apiKey = process.env.STABILITY_API_KEY - if (!apiKey) throw new Error('Missing Stability API key.') - - const response = await fetch(url, { - method: 'GET', - headers: { - Authorization: `Bearer ${apiKey}`, - }, - }) - - if (!response.ok) { - throw new Error(`Non-200 response: ${await response.text()}`) - } - - interface Balance { - credits: number - } - - // Do something with the balance... - const balance = (await response.json()) as Balance - - lang: Go - source: "package main\n\nimport (\n\t\"io\"\n\t\"net/http\"\n\t\"os\"\n)\n\nfunc main() {\n\t// Build REST endpoint URL\n\tapiHost, hasApiHost\ - \ := os.LookupEnv(\"API_HOST\")\n\tif !hasApiHost {\n\t\tapiHost = \"https://api.stability.ai\"\n\t}\n\treqUrl := apiHost + \"/v1/user/balance\"\ - \n\n\t// Acquire an API key from the environment\n\tapiKey, hasAPIKey := os.LookupEnv(\"STABILITY_API_KEY\")\n\tif !hasAPIKey {\n\t\tpanic(\"\ - Missing STABILITY_API_KEY environment variable\")\n\t}\n\n\t// Build the request\n\treq, _ := http.NewRequest(\"GET\", reqUrl, nil)\n\treq.Header.Add(\"\ - Authorization\", \"Bearer \"+apiKey)\n\n\t// Execute the request\n\tres, _ := http.DefaultClient.Do(req)\n\tdefer res.Body.Close()\n\tbody,\ - \ _ := io.ReadAll(res.Body)\n\n\tif res.StatusCode != 200 {\n\t\tpanic(\"Non-200 response: \" + string(body))\n\t}\n\n\t// Do something with\ - \ the payload...\n\t// payload := string(body)\n}\n" - - lang: cURL - source: | - if [ -z "$STABILITY_API_KEY" ]; then - echo "STABILITY_API_KEY environment variable is not set" - exit 1 - fi - - # Determine the URL to use for the request - BASE_URL=${API_HOST:-https://api.stability.ai} - URL="$BASE_URL/v1/user/balance" - - curl -f -sS "$URL" \ - -H 'Content-Type: application/json' \ - -H "Authorization: Bearer $STABILITY_API_KEY" -servers: - - url: https://api.stability.ai -tags: - - description: Manage your Stability.ai account, and view account/organization balances - name: v1/user - - description: Enumerate available engines - name: v1/engines - - description: Generate images from text, existing images, or both - name: v1/generation diff --git a/pkg/component/ai/stabilityai/v0/config/tasks.yaml b/pkg/component/ai/stabilityai/v0/config/tasks.yaml index 940b089ac..1d0f7e7b7 100644 --- a/pkg/component/ai/stabilityai/v0/config/tasks.yaml +++ b/pkg/component/ai/stabilityai/v0/config/tasks.yaml @@ -11,10 +11,7 @@ TASK_IMAGE_TO_IMAGE: example: 7 maximum: 35 minimum: 0 - format: number - acceptFormats: - - number - - integer + type: number uiOrder: 6 title: Cfg Scale clip-guidance-preset: @@ -28,10 +25,8 @@ TASK_IMAGE_TO_IMAGE: - SLOWER - SLOWEST example: FAST_BLUE - format: string + type: string description: Clip guidance preset. - acceptFormats: - - string uiOrder: 3 title: Clip Guidance Preset engine: @@ -44,30 +39,27 @@ TASK_IMAGE_TO_IMAGE: - esrgan-v1-x2plus - stable-diffusion-512-v2-1 - stable-diffusion-xl-beta-v2-2-2 - acceptFormats: - - string + type: string uiOrder: 0 title: Engine - format: string image-strength: default: 0.35 - description: | - How much influence the `init_image` has on the diffusion process. Values close to `1` will yield images very similar to the `init_image` while values close to `0` will yield images wildly different than the `init_image`. The behavior of this is meant to mirror DreamStudio's "Image Strength" slider.

This parameter is just an alternate way to set `step_schedule_start`, which is done via the calculation `1 - image_strength`. For example, passing in an Image Strength of 35% (`0.35`) would result in a `step_schedule_start` of `0.65`. + description: 'How much influence the `init_image` has on the diffusion process. Values close to `1` will yield images very similar to the `init_image` + while values close to `0` will yield images wildly different than the `init_image`. The behavior of this is meant to mirror DreamStudio''s "Image + Strength" slider.

This parameter is just an alternate way to set `step_schedule_start`, which is done via the calculation `1 - image_strength`. + For example, passing in an Image Strength of 35% (`0.35`) would result in a `step_schedule_start` of `0.65`. + + ' example: 0.4 maximum: 1 minimum: 0 - format: number - acceptFormats: - - number - - integer + type: number shortDescription: How much influence the `init-image` has on the diffusion process. uiOrder: 5 title: Image Strength init-image: description: Image used to initialize the diffusion process, in lieu of random noise. - format: image - acceptFormats: - - image/* + type: image/* uiOrder: 2 title: Init Image init-image-mode: @@ -76,24 +68,20 @@ TASK_IMAGE_TO_IMAGE: enum: - IMAGE_STRENGTH - STEP_SCHEDULE - format: string - acceptFormats: - - string + type: string uiOrder: 7 title: Init Image Mode prompts: description: An array of prompts to use for generation. - acceptFormats: - - array + type: array uiOrder: 1 items: description: The prompt itself example: A lighthouse on a cliff maxLength: 2000 - format: string + type: string minItems: 1 title: Prompts - format: array sampler: description: Which sampler to use for the diffusion process. If this value is omitted we'll automatically select an appropriate sampler for you. enum: @@ -108,9 +96,7 @@ TASK_IMAGE_TO_IMAGE: - K_HEUN - K_LMS example: K_DPM_2_ANCESTRAL - format: string - acceptFormats: - - string + type: string shortDescription: Which sampler to use for the diffusion process uiOrder: 8 title: Sampler @@ -120,9 +106,7 @@ TASK_IMAGE_TO_IMAGE: example: 1 maximum: 10 minimum: 1 - format: integer - acceptFormats: - - integer + type: integer uiOrder: 9 title: Samples seed: @@ -131,10 +115,7 @@ TASK_IMAGE_TO_IMAGE: example: 0 maximum: 4294967295 minimum: 0 - format: integer - acceptFormats: - - number - - integer + type: number uiOrder: 10 title: Seed step-schedule-end: @@ -143,10 +124,7 @@ TASK_IMAGE_TO_IMAGE: example: 0.01 maximum: 1 minimum: 0 - format: number - acceptFormats: - - number - - integer + type: number shortDescription: Skips a proportion of the end of the diffusion steps uiOrder: 12 title: Step Schedule End @@ -158,10 +136,7 @@ TASK_IMAGE_TO_IMAGE: example: 0.4 maximum: 1 minimum: 0 - format: number - acceptFormats: - - number - - integer + type: number shortDescription: Skips a proportion of the start of the diffusion steps uiOrder: 11 title: Step Schedule Start @@ -171,15 +146,13 @@ TASK_IMAGE_TO_IMAGE: example: 50 maximum: 50 minimum: 10 - format: integer - acceptFormats: - - integer + type: integer uiOrder: 13 title: Steps style-preset: - description: |- - Pass in a style preset to guide the image model towards a particular style. - This list of style presets is subject to change. + description: 'Pass in a style preset to guide the image model towards a particular style. + + This list of style presets is subject to change.' enum: - enhance - anime @@ -198,29 +171,24 @@ TASK_IMAGE_TO_IMAGE: - 3d-model - pixel-art - tile-texture - acceptFormats: - - string + type: string uiOrder: 14 title: Style Preset weights: description: An array of weights to use for generation. If unspecified, the model will automatically assign a default weight of 1.0 to each prompt. - acceptFormats: - - array + type: array uiOrder: 2 items: description: Weight of the prompt (use negative numbers for negative prompts) example: 0.8167237 - acceptFormats: - - number - - integer + type: number minItems: 1 title: Weights - format: array required: - prompts - engine title: Input - format: object + type: object output: $ref: '#/TASK_TEXT_TO_IMAGE/output' TASK_TEXT_TO_IMAGE: @@ -236,10 +204,7 @@ TASK_TEXT_TO_IMAGE: example: 7 maximum: 35 minimum: 0 - format: number - acceptFormats: - - number - - integer + type: number uiOrder: 3 title: CFG Scale clip-guidance-preset: @@ -253,10 +218,8 @@ TASK_TEXT_TO_IMAGE: - SLOWER - SLOWEST example: FAST_BLUE - format: string + type: string description: Clip guidance preset. - acceptFormats: - - string uiOrder: 4 title: Clip Guidance Preset engine: @@ -275,11 +238,9 @@ TASK_TEXT_TO_IMAGE: - stable-diffusion-v1-6 targets: - setup.api-key - acceptFormats: - - string + type: string uiOrder: 0 title: Engine - format: string height: default: 1024 description: "Height of the image to generate, in pixels, in an increment divible by 64.\n\nEngine-specific dimension validation:\n- SDXL Beta:\ @@ -289,25 +250,20 @@ TASK_TEXT_TO_IMAGE: example: 1024 minimum: 128 multipleOf: 64 - format: integer - acceptFormats: - - integer + type: integer uiOrder: 5 title: Height prompts: description: An array of prompts to use for generation. - acceptFormats: - - array + type: array uiOrder: 1 items: description: The prompt itself example: A lighthouse on a cliff maxLength: 2000 - acceptFormats: - - string + type: string minItems: 1 title: Prompts - format: array sampler: description: Which sampler to use for the diffusion process. If this value is omitted we'll automatically select an appropriate sampler for you. enum: @@ -322,9 +278,7 @@ TASK_TEXT_TO_IMAGE: - K_HEUN - K_LMS example: K_DPM_2_ANCESTRAL - format: string - acceptFormats: - - string + type: string uiOrder: 6 title: Sampler samples: @@ -333,9 +287,7 @@ TASK_TEXT_TO_IMAGE: example: 1 maximum: 10 minimum: 1 - format: integer - acceptFormats: - - integer + type: integer uiOrder: 7 title: Samples seed: @@ -344,10 +296,7 @@ TASK_TEXT_TO_IMAGE: example: 0 maximum: 4294967295 minimum: 0 - format: integer - acceptFormats: - - number - - integer + type: number uiOrder: 8 title: Seed steps: @@ -356,15 +305,13 @@ TASK_TEXT_TO_IMAGE: example: 50 maximum: 50 minimum: 10 - format: integer - acceptFormats: - - integer + type: integer uiOrder: 9 title: Steps style-preset: - description: |- - Pass in a style preset to guide the image model towards a particular style. - This list of style presets is subject to change. + description: 'Pass in a style preset to guide the image model towards a particular style. + + This list of style presets is subject to change.' enum: - enhance - anime @@ -383,26 +330,19 @@ TASK_TEXT_TO_IMAGE: - 3d-model - pixel-art - tile-texture - format: string - acceptFormats: - - string + type: string uiOrder: 10 title: Style Preset weights: description: An array of weights to use for generation. - acceptFormats: - - array + type: array uiOrder: 2 items: description: Weight of the prompt (use negative numbers for negative prompts) example: 0.8167237 - format: float - acceptFormats: - - number - - integer + type: number minItems: 1 title: Weights - format: array width: default: 1024 description: "Width of the image to generate, in pixels, in an increment divible by 64.\n\nEngine-specific dimension validation:\n- SDXL Beta: must\ @@ -412,16 +352,14 @@ TASK_TEXT_TO_IMAGE: example: 1024 minimum: 128 multipleOf: 64 - format: integer - acceptFormats: - - integer + type: integer uiOrder: 5 title: Width required: - prompts - engine title: Input - format: object + type: object output: additionalProperties: false description: Output. @@ -432,25 +370,22 @@ TASK_TEXT_TO_IMAGE: uiOrder: 0 items: title: Image - format: image/png + type: image/png title: Images - format: array + type: array seeds: description: Seeds of generated images. uiOrder: 1 items: description: The seed associated with this image example: 1229191277 - format: number - acceptFormats: - - number - - integer + type: number title: Seed x-go-type-skip-optional-pointer: true title: Seeds - format: array + type: array required: - images - seeds title: Output - format: object + type: object diff --git a/pkg/component/ai/stabilityai/v0/main.go b/pkg/component/ai/stabilityai/v0/main.go index 9fd99f614..09162ec23 100644 --- a/pkg/component/ai/stabilityai/v0/main.go +++ b/pkg/component/ai/stabilityai/v0/main.go @@ -30,10 +30,8 @@ var ( setupYAML []byte //go:embed config/tasks.yaml tasksYAML []byte - //go:embed config/stabilityai.yaml - stabilityaiJSON []byte - once sync.Once - comp *component + once sync.Once + comp *component ) // Component executes queries against StabilityAI. @@ -47,7 +45,7 @@ type component struct { func Init(bc base.Component) *component { once.Do(func() { comp = &component{Component: bc} - err := comp.LoadDefinition(definitionYAML, setupYAML, tasksYAML, nil, map[string][]byte{"stabilityai.yaml": stabilityaiJSON}) + err := comp.LoadDefinition(definitionYAML, setupYAML, tasksYAML, nil, nil) if err != nil { panic(err) } diff --git a/pkg/component/ai/universalai/v0/.compogen/bottom.mdx b/pkg/component/ai/universalai/v0/.compogen/bottom.mdx index bb054696d..629a67cf3 100644 --- a/pkg/component/ai/universalai/v0/.compogen/bottom.mdx +++ b/pkg/component/ai/universalai/v0/.compogen/bottom.mdx @@ -10,7 +10,7 @@ variable: prompt: title: Prompt description: "User input message to be sent to the AI model." - format: string + type: string output: ai-output: diff --git a/pkg/component/ai/universalai/v0/README.mdx b/pkg/component/ai/universalai/v0/README.mdx index 95395916c..312dfaab2 100644 --- a/pkg/component/ai/universalai/v0/README.mdx +++ b/pkg/component/ai/universalai/v0/README.mdx @@ -37,7 +37,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Model Name (required) | `model` | string | The model to be used. Now, it only supports OpenAI model, and will support more models in the future.
Enum values
  • `o1-preview`
  • `o1-mini`
  • `gpt-4o-mini`
  • `gpt-4o`
  • `gpt-4o-2024-05-13`
  • `gpt-4o-2024-08-06`
  • `gpt-4-turbo`
  • `gpt-4-turbo-2024-04-09`
  • `gpt-4-0125-preview`
  • `gpt-4-turbo-preview`
  • `gpt-4-1106-preview`
  • `gpt-4-vision-preview`
  • `gpt-4`
  • `gpt-4-0314`
  • `gpt-4-0613`
  • `gpt-4-32k`
  • `gpt-4-32k-0314`
  • `gpt-4-32k-0613`
  • `gpt-3.5-turbo`
  • `gpt-3.5-turbo-16k`
  • `gpt-3.5-turbo-0301`
  • `gpt-3.5-turbo-0613`
  • `gpt-3.5-turbo-1106`
  • `gpt-3.5-turbo-0125`
  • `gpt-3.5-turbo-16k-0613`
| | API Key | `api-key` | string | Fill in your API key from the vendor's platform. | @@ -57,7 +57,7 @@ Generate response base on conversation input
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CHAT` | | [Chat Data](#chat-chat-data) (required) | `data` | object | Input data. | @@ -74,7 +74,7 @@ Input data.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Chat Messages](#chat-chat-messages) | `messages` | array | List of chat messages. |
@@ -84,7 +84,7 @@ List of chat messages.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#chat-content) | `content` | array | The message content. | | Name | `name` | string | An optional name for the participant. Provides the model information to differentiate between participants of the same role. | @@ -96,7 +96,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Max New Tokens | `max-tokens` | integer | The maximum number of tokens for model to generate. | | Number of Choices | `n` | integer | How many chat completion choices to generate for each input message. | @@ -111,7 +111,7 @@ Input parameter.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Output Data](#chat-output-data) | `data` | object | Output data. | | [Output Metadata](#chat-output-metadata) (optional) | `metadata` | object | Output metadata. | @@ -124,7 +124,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Choices](#chat-choices) | `choices` | array | List of chat completion choices. |
@@ -133,7 +133,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Created | `created` | integer | The Unix timestamp (in seconds) of when the chat completion was created. | | Finish Reason | `finish-reason` | string | The reason the model stopped generating tokens. | @@ -145,7 +145,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content | `content` | string | The contents of the message. | | Role | `role` | string | The role of the author of this message. | @@ -155,7 +155,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Usage](#chat-usage) | `usage` | object | Usage statistics for the request. |
@@ -164,7 +164,7 @@ Input parameter.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Completion Tokens | `completion-tokens` | integer | Number of tokens in the generated response. | | Prompt Tokens | `prompt-tokens` | integer | Number of tokens in the prompt. | @@ -186,7 +186,7 @@ variable: prompt: title: Prompt description: "User input message to be sent to the AI model." - format: string + type: string output: ai-output: diff --git a/pkg/component/ai/universalai/v0/config/setup.yaml b/pkg/component/ai/universalai/v0/config/setup.yaml index 1627f04bd..0c5d79557 100644 --- a/pkg/component/ai/universalai/v0/config/setup.yaml +++ b/pkg/component/ai/universalai/v0/config/setup.yaml @@ -3,8 +3,7 @@ properties: model: description: The model to be used. Now, it only supports OpenAI model, and will support more models in the future. shortDescription: The model to be used. - acceptFormats: - - string + type: string enum: - o1-preview - o1-mini @@ -47,24 +46,19 @@ properties: - setup.api-key uiOrder: 0 title: Model Name - format: string api-key: description: Fill in your API key from the vendor's platform. - acceptFormats: - - string + type: string instillSecret: true instillCredential: true uiOrder: 1 title: API Key - format: string organization: description: Specify which organization is used for the requests. Usage will count against the specified organization's subscription quota. - acceptFormats: - - string + type: string uiOrder: 2 title: Organization ID - format: string required: - model title: Universal AI Connection -format: object +type: object diff --git a/pkg/component/ai/universalai/v0/config/tasks.yaml b/pkg/component/ai/universalai/v0/config/tasks.yaml index 44da07290..1208766ab 100644 --- a/pkg/component/ai/universalai/v0/config/tasks.yaml +++ b/pkg/component/ai/universalai/v0/config/tasks.yaml @@ -26,106 +26,90 @@ TASK_CHAT: title: Text Message description: Text message. shortDescription: Text message. - acceptFormats: - - string + type: string uiOrder: 1 - format: string type: title: Text description: Text content type. shortDescription: Text content type. - acceptFormats: - - string + type: string const: text uiOrder: 0 - format: string required: - text - type title: Text - format: object + type: object - properties: image-url: title: Image URL description: Image message URL. shortDescription: Image message URL. - acceptFormats: - - string + type: string uiOrder: 1 - format: string type: title: Image URL description: Image URL content type. shortDescription: Image URL content type - acceptFormats: - - string + type: string const: image-url uiOrder: 0 - format: string required: - image-url - type title: Image URL - format: object + type: object - properties: image-base64: title: Image Base64 description: Image base64 encoded string. shortDescription: Image base64 encoded string. - acceptFormats: - - image/* + type: string uiOrder: 1 - format: string type: title: Image File description: Image file input content type. shortDescription: Image file input content type - acceptFormats: - - string + type: string const: image-base64 uiOrder: 0 - format: string required: - image-base64 - type title: Image Base64 - format: object + type: object required: [] - format: object + type: object uiOrder: 0 - format: array + type: array role: description: The message role, i.e. 'system', 'user' or 'assistant'. shortDescription: The message role, i.e. 'system', 'user' or 'assistant' - acceptFormats: - - string + type: string title: Role enum: - system - user - assistant uiOrder: 1 - format: string name: description: An optional name for the participant. Provides the model information to differentiate between participants of the same role. shortDescription: An optional name for the participant. Provides the model information to differentiate between participants of the same role. - acceptFormats: - - string + type: string title: Name uiOrder: 2 - format: string required: - content - role - format: object + type: object uiOrder: 0 description: List of chat messages. - format: array + type: array required: - messages uiOrder: 0 - format: object + type: object parameter: description: Input parameter. shortDescription: Input parameter @@ -134,65 +118,53 @@ TASK_CHAT: title: Max New Tokens description: The maximum number of tokens for model to generate. shortDescription: The maximum number of tokens for model to generate - acceptFormats: - - integer + type: integer default: 50 uiOrder: 0 - format: integer seed: title: Seed description: The seed, default is 0. shortDescription: The seed, default is 0 - acceptFormats: - - integer + type: integer default: 0 uiOrder: 1 - format: integer n: title: Number of Choices description: How many chat completion choices to generate for each input message. shortDescription: How many chat completion choices to generate for each input message. - acceptFormats: - - integer + type: integer default: 1 uiOrder: 2 - format: integer temperature: title: Temperature description: The temperature for sampling. shortDescription: The temperature for sampling - acceptFormats: - - number + type: number default: 0.7 uiOrder: 3 - format: number top-p: title: Top P description: An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered. We generally recommend altering this or temperature but not both. shortDescription: Nucleus sampling - acceptFormats: - - number + type: number default: 1 uiOrder: 4 - format: number stream: title: Stream description: If set, partial message deltas will be sent. Tokens will be sent as data-only server-sent events as they become available. shortDescription: If set, partial message deltas will be sent - acceptFormats: - - boolean + type: boolean default: false uiOrder: 5 - format: boolean required: [] uiOrder: 1 title: Input Parameter - format: object + type: object required: - data - format: object + type: object output: title: Chat output description: Output schema of the chat task. @@ -213,13 +185,13 @@ TASK_CHAT: description: The reason the model stopped generating tokens. shortDescription: The reason the model stopped generating tokens. uiOrder: 0 - format: string + type: string index: title: Index description: The index of the choice in the list of choices. shortDescription: The index of the choice in the list of choices. uiOrder: 1 - format: integer + type: integer message: title: Message description: A chat message generated by the model. @@ -230,35 +202,35 @@ TASK_CHAT: description: The contents of the message. shortDescription: The contents of the message. uiOrder: 0 - format: string + type: string role: title: Role description: The role of the author of this message. shortDescription: The role of the author of this message. uiOrder: 1 - format: string + type: string required: [] uiOrder: 2 - format: object + type: object created: title: Created description: The Unix timestamp (in seconds) of when the chat completion was created. shortDescription: The Unix timestamp (in seconds) of when the chat completion was created. uiOrder: 3 - format: integer + type: integer required: - finish-reason - index - message - created - format: object + type: object uiOrder: 0 - format: array + type: array required: - choices uiOrder: 0 title: Output Data - format: object + type: object metadata: description: Output metadata. shortDescription: Output metadata @@ -272,30 +244,30 @@ TASK_CHAT: description: Number of tokens in the generated response. shortDescription: Number of tokens in the generated response. uiOrder: 0 - format: integer + type: integer prompt-tokens: title: Prompt Tokens description: Number of tokens in the prompt. shortDescription: Number of tokens in the prompt. uiOrder: 1 - format: integer + type: integer total-tokens: title: Total Tokens description: Total number of tokens used in the request (prompt + completion). shortDescription: Total number of tokens used in the request (prompt + completion). uiOrder: 2 - format: integer + type: integer required: - completion-tokens - prompt-tokens - total-tokens uiOrder: 0 title: Usage - format: object + type: object required: [] title: Output Metadata uiOrder: 1 - format: object + type: object required: - data - format: object + type: object diff --git a/pkg/component/application/asana/v0/README.mdx b/pkg/component/application/asana/v0/README.mdx index 6dd2fe857..1ba9e800f 100644 --- a/pkg/component/application/asana/v0/README.mdx +++ b/pkg/component/application/asana/v0/README.mdx @@ -39,7 +39,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Token (required) | `token` | string | Fill in your Asana Personal Access Token (PAT). You can generate one from developer console. | @@ -57,7 +57,7 @@ Create, Update, Delete, Read and Duplicate goal in Asana.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CRUD_GOAL` | | [Action](#crud-goal-action) | `action` | object | action. | @@ -79,7 +79,7 @@ Get Goal.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"get"` | | Goal ID | `goal-gid` | string | Globally unique identifier (GID) for the goal. You can find the GID of a goal from the URL of the goal in Asana. For example, if the URL of the goal is https://app.asana.com/0/goal/1234567890, then the GID is 1234567890. | @@ -91,7 +91,7 @@ Update Goal.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"update"` | | Due Date | `due-on` | string | The date on which the goal is due. In the format YYYY-MM-DD. | @@ -109,7 +109,7 @@ Delete Goal.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"delete"` | | Goal ID | `goal-gid` | string | Globally unique identifier (GID) for the goal. You can find the GID of a goal from the URL of the goal in Asana. For example, if the URL of the goal is https://app.asana.com/0/goal/1234567890, then the GID is 1234567890. | @@ -121,7 +121,7 @@ Create Goal.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"create"` | | Due Date | `due-on` | string | The date on which the goal is due. In the format YYYY-MM-DD. | @@ -137,7 +137,7 @@ Create Goal.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Goal ID (optional) | `gid` | string | Globally unique identifier (GID) for the goal. | | Goal Name (optional) | `name` | string | The name of the goal. | @@ -157,7 +157,7 @@ Create Goal.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Owner ID | `gid` | string | Globally unique identifier (GID) for the owner. | | Owner Name | `name` | string | The name of the owner. | @@ -167,7 +167,7 @@ Create Goal.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Like ID | `like-gid` | string | Globally unique identifier (GID) for the like. | | User Name | `name` | string | The name of the user. | @@ -182,7 +182,7 @@ Create, Update, Delete, Read and Duplicate Task in Asana.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CRUD_TASK` | | [Action](#crud-task-action) | `action` | object | Action. | @@ -204,7 +204,7 @@ Get Task.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"get"` | | Task ID | `task-gid` | string | Globally unique identifier (GID) for the task. | @@ -216,7 +216,7 @@ Update Task.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"update"` | | Approval Status | `approval-status` | string | The approval status of the task. If you set completed to true, this field will be set to approved.
Enum values
  • `pending`
  • `approved`
  • `rejected`
  • `changes_requested`
| @@ -236,7 +236,7 @@ Delete Task.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"delete"` | | Task ID | `task-gid` | string | Globally unique identifier (GID) for the task. | @@ -248,7 +248,7 @@ Create Task.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"create"` | | Approval Status | `approval-status` | string | The approval status of the task. If you set completed to true, this field will be set to approved.
Enum values
  • `pending`
  • `approved`
  • `rejected`
  • `changes_requested`
| @@ -270,7 +270,7 @@ Duplicate Task.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"duplicate"` | | Name | `name` | string | Name of the new task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | @@ -283,7 +283,7 @@ Set Parent Task.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"set parent"` | | Parent Task | `parent` | string | GID of the parent task. | @@ -296,7 +296,7 @@ Edit Tag.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"edit tag"` | | Edit option | `edit-option` | string | Edit option. You can choose to add or remove the tag.
Enum values
  • `add`
  • `remove`
| @@ -310,7 +310,7 @@ Edit Follower.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"edit follower"` | | Edit option | `edit-option` | string | Edit option. You can choose to add or remove the follower.
Enum values
  • `add`
  • `remove`
| @@ -324,7 +324,7 @@ Edit Project.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"edit project"` | | Edit option | `edit-option` | string | Edit option. You can choose to add or remove the project.
Enum values
  • `add`
  • `remove`
| @@ -335,7 +335,7 @@ Edit Project.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (optional) | `gid` | string | Globally unique identifier (GID) for the task. | | Task Name (optional) | `name` | string | The name of the task. | @@ -360,7 +360,7 @@ Edit Project.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Project ID | `gid` | string | Globally unique identifier (GID) for the project. | | Project Name | `name` | string | The name of the project. | @@ -370,7 +370,7 @@ Edit Project.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Like ID | `like-gid` | string | Globally unique identifier (GID) for the like. | | User Name | `name` | string | The name of the user. | @@ -385,7 +385,7 @@ Create, Update, Delete, Read and Duplicate project in Asana.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CRUD_PROJECT` | | [Action](#crud-project-action) | `action` | object | action. | @@ -407,7 +407,7 @@ Get Project.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"get"` | | Project ID | `project-gid` | string | Globally unique identifier (GID) for the project. | @@ -419,7 +419,7 @@ Update Project.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"update"` | | Archived | `archived` | boolean | Whether the project is archived. | @@ -438,7 +438,7 @@ Delete Project.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"delete"` | | Project ID | `project-gid` | string | Globally unique identifier (GID) for the project. | @@ -450,7 +450,7 @@ Create Project.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"create"` | | Update Color | `color` | string | The color of the project.
Enum values
  • `dark-pink`
  • `dark-green`
  • `dark-blue`
  • `dark-red`
  • `dark-teal`
  • `dark-brown`
  • `dark-orange`
  • `dark-purple`
  • `dark-warm-gray`
  • `light-pink`
  • `light-green`
  • `light-blue`
  • `light-red`
  • `light-teal`
  • `light-brown`
  • `light-orange`
  • `light-purple`
  • `light-warm-gray`
  • `none`
  • `null`
| @@ -469,7 +469,7 @@ Duplicate Project.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"duplicate"` | | Due Date | `due-on` | string | Sets the last due date in the duplicated project to the given date. The rest of the due dates will be offset by the same amount as the due dates in the original project. In the format YYYY-MM-DD. | @@ -483,7 +483,7 @@ Duplicate Project.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Project ID (optional) | `gid` | string | Globally unique identifier (GID) for the project. | | Project Name (optional) | `name` | string | The name of the project. | @@ -510,7 +510,7 @@ Duplicate Project.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Owner ID | `gid` | string | Globally unique identifier (GID) for the owner. | | Owner Name | `name` | string | The name of the owner. | @@ -520,7 +520,7 @@ Duplicate Project.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | User ID | `gid` | string | Globally unique identifier (GID) for the user. | | User Name | `name` | string | The name of the user. | @@ -534,7 +534,7 @@ Create, Update, Delete and Read portfolio in Asana.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CRUD_PORTFOLIO` | | [Action](#crud-portfolio-action) | `action` | object | action. | @@ -556,7 +556,7 @@ Get Portfolio.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"get"` | | Portfolio ID | `portfolio-gid` | string | Globally unique identifier (GID) for the portfolio. | @@ -568,7 +568,7 @@ Update Portfolio.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"update"` | | Update Color | `color` | string | The color of the portfolio.
Enum values
  • `dark-pink`
  • `dark-green`
  • `dark-blue`
  • `dark-red`
  • `dark-teal`
  • `dark-brown`
  • `dark-orange`
  • `dark-purple`
  • `dark-warm-gray`
  • `light-pink`
  • `light-green`
  • `light-blue`
  • `light-red`
  • `light-teal`
  • `light-brown`
  • `light-orange`
  • `light-purple`
  • `light-warm-gray`
  • `none`
  • `null`
| @@ -584,7 +584,7 @@ Delete Portfolio.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"delete"` | | Portfolio ID | `portfolio-gid` | string | Globally unique identifier (GID) for the portfolio. | @@ -596,7 +596,7 @@ Create Portfolio.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Action | `action` | string | Must be `"create"` | | Color | `color` | string | The color of the portfolio.
Enum values
  • `dark-pink`
  • `dark-green`
  • `dark-blue`
  • `dark-red`
  • `dark-teal`
  • `dark-brown`
  • `dark-orange`
  • `dark-purple`
  • `dark-warm-gray`
  • `light-pink`
  • `light-green`
  • `light-blue`
  • `light-red`
  • `light-teal`
  • `light-brown`
  • `light-orange`
  • `light-purple`
  • `light-warm-gray`
  • `none`
  • `null`
| @@ -608,7 +608,7 @@ Create Portfolio.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Portfolio ID (optional) | `gid` | string | Globally unique identifier (GID) for the portfolio. | | Portfolio Name (optional) | `name` | string | The name of the portfolio. | @@ -630,7 +630,7 @@ Create Portfolio.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Owner ID | `gid` | string | Globally unique identifier (GID) for the owner. | | Owner Name | `name` | string | The name of the owner. | @@ -640,7 +640,7 @@ Create Portfolio.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | User ID | `gid` | string | Globally unique identifier (GID) for the user. | | User Name | `name` | string | The name of the user. | diff --git a/pkg/component/application/asana/v0/config/setup.yaml b/pkg/component/application/asana/v0/config/setup.yaml index 83900adf5..8b2eb1051 100644 --- a/pkg/component/application/asana/v0/config/setup.yaml +++ b/pkg/component/application/asana/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: token: description: Fill in your Asana Personal Access Token (PAT). You can generate one from developer console. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: Token - format: string required: - token title: Asana Connection -format: object +type: object diff --git a/pkg/component/application/asana/v0/config/tasks.yaml b/pkg/component/application/asana/v0/config/tasks.yaml index b896d4596..e78f5f5a5 100644 --- a/pkg/component/application/asana/v0/config/tasks.yaml +++ b/pkg/component/application/asana/v0/config/tasks.yaml @@ -19,79 +19,65 @@ TASK_CRUD_GOAL: const: get description: Get Goal. uiOrder: 0 - format: string + type: string goal-gid: description: Globally unique identifier (GID) for the goal. You can find the GID of a goal from the URL of the goal in Asana. For example, if the URL of the goal is https://app.asana.com/0/goal/1234567890, then the GID is 1234567890. shortDescription: Goal ID uiOrder: 0 title: Goal ID - acceptFormats: - - string - format: string + type: string required: - action - goal-gid title: Get description: Get Goal. uiOrder: 0 - format: object + type: object - properties: action: title: Action const: update description: Update Goal. uiOrder: 0 - format: string + type: string goal-gid: description: Globally unique identifier (GID) for the goal. You can find the GID of a goal from the URL of the goal in Asana. For example, if the URL of the goal is https://app.asana.com/0/goal/1234567890, then the GID is 1234567890. shortDescription: Goal ID uiOrder: 0 title: Goal ID - acceptFormats: - - string - format: string + type: string name: description: The name of the goal. shortDescription: Update Goal Name uiOrder: 1 title: Goal Name - acceptFormats: - - string - format: string + type: string notes: description: The notes of the goal. shortDescription: Update Goal Note uiOrder: 2 title: Goal Note - acceptFormats: - - string - format: string + type: string due-on: description: The date on which the goal is due. In the format YYYY-MM-DD. shortDescription: Update Due Date uiOrder: 2 title: Due Date - acceptFormats: - - string - format: string + type: string start-on: description: The date on which the goal starts. In the format YYYY-MM-DD. shortDescription: Update Start Date uiOrder: 3 title: Start Date - acceptFormats: - - string - format: string + type: string liked: description: Whether the goal is liked by the user. shortDescription: Liked uiOrder: 4 title: Liked - acceptFormats: - - boolean - format: boolean + type: boolean status: description: The current status of this goal. When the goal is open, its status can be green, yellow, and red to reflect "On Track", "At Risk", and "Off Track", respectively. When the goal is closed, the value can be missed, achieved, partial, or dropped. @@ -106,9 +92,7 @@ TASK_CRUD_GOAL: - partial - dropped title: Status - acceptFormats: - - string - format: string + type: string required: - action - goal-gid @@ -116,104 +100,86 @@ TASK_CRUD_GOAL: title: Update description: Update Goal. uiOrder: 0 - format: object + type: object - properties: action: title: Action const: delete uiOrder: 0 description: Delete goal. - format: string + type: string goal-gid: description: Globally unique identifier (GID) for the goal. You can find the GID of a goal from the URL of the goal in Asana. For example, if the URL of the goal is https://app.asana.com/0/goal/1234567890, then the GID is 1234567890. shortDescription: Goal ID uiOrder: 0 title: Goal ID - acceptFormats: - - string - format: string + type: string required: - action - goal-gid title: Delete description: Delete Goal. uiOrder: 0 - format: object + type: object - properties: action: title: Action const: create description: Create Goal. uiOrder: 0 - format: string + type: string name: description: The name of the goal. shortDescription: Goal Name uiOrder: 1 title: Goal Name - acceptFormats: - - string - format: string + type: string notes: description: The notes of the goal. shortDescription: Goal Note uiOrder: 2 title: Goal Note - acceptFormats: - - string - format: string + type: string due-on: description: The date on which the goal is due. In the format YYYY-MM-DD. shortDescription: Due Date uiOrder: 2 title: Due Date - acceptFormats: - - string - format: string + type: string start-on: description: The date on which the goal starts. In the format YYYY-MM-DD. shortDescription: Start Date uiOrder: 3 title: Start Date - acceptFormats: - - string - format: string + type: string liked: description: Whether the goal is liked by the user. shortDescription: Liked uiOrder: 4 title: Liked - acceptFormats: - - boolean - format: boolean + type: boolean workspace: description: GID of the workspace. You can find one by filling the access token in the Asana API Playground. shortDescription: GID of the workspace uiOrder: 5 title: Workspace - acceptFormats: - - string - format: string + type: string time-period: description: GID of the time period. You can find one by filling the workspace id in the Asana API Playground. shortDescription: Time Period uiOrder: 6 title: Time Period - acceptFormats: - - string - format: string + type: string owner: description: User GID of the Owner. You can find one by filling the workspace id in the Asana API Playground. shortDescription: Owner uiOrder: 7 title: Owner - acceptFormats: - - string - format: string + type: string required: - action - name @@ -221,11 +187,11 @@ TASK_CRUD_GOAL: title: Create description: Create Goal. uiOrder: 0 - format: object - format: object + type: object + type: object required: [] title: Input - format: object + type: object output: description: Goal. uiOrder: 0 @@ -235,13 +201,13 @@ TASK_CRUD_GOAL: shortDescription: Goal ID uiOrder: 0 title: Goal ID - format: string + type: string name: description: The name of the goal. shortDescription: Goal Name uiOrder: 1 title: Goal Name - format: string + type: string owner: description: The owner of the goal. shortDescription: The owner of the goal. @@ -253,47 +219,47 @@ TASK_CRUD_GOAL: shortDescription: Owner ID uiOrder: 0 title: Owner ID - format: string + type: string name: description: The name of the owner. shortDescription: Owner Name uiOrder: 1 title: Owner Name - format: string + type: string required: - gid - name - format: object + type: object notes: description: The notes of the goal. shortDescription: The notes of the goal. uiOrder: 2 title: Goal Note - format: string + type: string html-notes: description: The notes of the goal in HTML format. shortDescription: The notes of the goal in HTML format. uiOrder: 3 title: Goal HTML Note - format: string + type: string due-on: description: The date on which the goal is due. In the format YYYY-MM-DD. shortDescription: Due Date uiOrder: 4 title: Due Date - format: string + type: string start-on: description: The date on which the goal starts. In the format YYYY-MM-DD. shortDescription: Start Date uiOrder: 5 title: Start Date - format: string + type: string liked: description: Whether the goal is liked by the user. shortDescription: Liked uiOrder: 6 title: Liked - format: boolean + type: boolean likes: description: The users who likes the goal. shortDescription: The users who likes the goal. @@ -306,28 +272,28 @@ TASK_CRUD_GOAL: shortDescription: Like ID uiOrder: 0 title: Like ID - format: string + type: string user-gid: description: Globally unique identifier (GID) for the user. shortDescription: User ID uiOrder: 0 title: User ID - format: string + type: string name: description: The name of the user. shortDescription: User Name uiOrder: 1 title: User Name - format: string + type: string required: - like-gid - user-gid - name - format: object - format: array + type: object + type: array required: [] title: Output - format: object + type: object TASK_CRUD_TASK: description: Create, Update, Delete, Read and Duplicate Task in Asana. shortDescription: Task Related Task, including get, update, delete, create, duplicate @@ -350,46 +316,40 @@ TASK_CRUD_TASK: const: get description: Get Task. uiOrder: 0 - format: string + type: string task-gid: description: Globally unique identifier (GID) for the task. shortDescription: Task ID uiOrder: 0 title: Task ID - acceptFormats: - - string - format: string + type: string required: - action - task-gid title: Get description: Get Task. uiOrder: 0 - format: object + type: object - properties: action: title: Action const: update description: Update Task. uiOrder: 0 - format: string + type: string task-gid: description: Globally unique identifier (GID) for the task. shortDescription: Task ID uiOrder: 0 title: Task ID - acceptFormats: - - string - format: string + type: string name: description: Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. shortDescription: Name of the task uiOrder: 1 title: Name of the task - acceptFormats: - - string - format: string + type: string resource-subtype: description: The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. @@ -402,9 +362,7 @@ TASK_CRUD_TASK: - section - approval - custom - acceptFormats: - - string - format: string + type: string approval-status: description: The approval status of the task. If you set completed to true, this field will be set to approved. shortDescription: The approval status of the task @@ -415,49 +373,37 @@ TASK_CRUD_TASK: - approved - rejected - changes_requested - acceptFormats: - - string - format: string + type: string completed: description: Whether the task is currently marked complete. shortDescription: Whether the task is currently marked complete uiOrder: 4 title: Completed - acceptFormats: - - boolean - format: boolean + type: boolean liked: description: Whether the task is liked by the user. shortDescription: Whether the task is liked by the user uiOrder: 5 title: Liked - acceptFormats: - - boolean - format: boolean + type: boolean notes: description: Free-form textual information associated with the task (i.e. its description). shortDescription: Notes of the task uiOrder: 6 title: Notes of the task - acceptFormats: - - string - format: string + type: string assignee: description: GID of the assignee. shortDescription: GID of the assignee uiOrder: 7 title: Assignee - acceptFormats: - - string - format: string + type: string parent: description: GID of the parent task. shortDescription: GID of the parent task uiOrder: 8 title: Parent Task - acceptFormats: - - string - format: string + type: string required: - action - task-gid @@ -465,52 +411,46 @@ TASK_CRUD_TASK: description: Update Task. uiOrder: 0 title: Update - format: object + type: object - properties: action: title: Action const: delete description: Delete Task. uiOrder: 0 - format: string + type: string task-gid: description: Globally unique identifier (GID) for the task. shortDescription: Task ID uiOrder: 0 title: Task ID - acceptFormats: - - string - format: string + type: string required: - action - task-gid description: Delete Task. uiOrder: 0 title: Delete - format: object + type: object - properties: action: title: Action const: create description: Create Task. uiOrder: 0 - format: string + type: string name: description: The name of the task. shortDescription: Task Name uiOrder: 1 title: Task Name - acceptFormats: - - string - format: string + type: string notes: description: The notes of the task. shortDescription: Task Notes uiOrder: 2 title: Task Notes - acceptFormats: - - string - format: string + type: string resource-subtype: default: default_task description: The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in @@ -524,9 +464,7 @@ TASK_CRUD_TASK: - section - approval - custom - acceptFormats: - - string - format: string + type: string approval-status: description: The approval status of the task. If you set completed to true, this field will be set to approved. shortDescription: The approval status of the task @@ -537,68 +475,52 @@ TASK_CRUD_TASK: - approved - rejected - changes_requested - acceptFormats: - - string - format: string + type: string completed: description: Whether the task is currently marked complete. shortDescription: Whether the task is currently marked complete uiOrder: 4 title: Completed - acceptFormats: - - boolean - format: boolean + type: boolean liked: description: Whether the task is liked by the user. shortDescription: Whether the task is liked by the user uiOrder: 5 title: Liked - acceptFormats: - - boolean - format: boolean + type: boolean assignee: description: GID of the assignee. shortDescription: GID of the assignee uiOrder: 7 title: Assignee - acceptFormats: - - string - format: string + type: string parent: description: GID of the parent task. shortDescription: GID of the parent task uiOrder: 8 title: Parent Task - acceptFormats: - - string - format: string + type: string start-at: description: The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC. shortDescription: Start Date & Time. In format like 2021-09-01T00:00:00Z uiOrder: 9 title: Start Date & Time - acceptFormats: - - string - format: string + type: string due-at: description: Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC. shortDescription: Due Date & Time. In format like 2021-09-01T00:00:00Z uiOrder: 10 title: Due Date & Time - acceptFormats: - - string - format: string + type: string workspace: description: GID of the workspace. You can find one by filling the access token in the Asana API Playground. shortDescription: GID of the workspace uiOrder: 11 title: Workspace - acceptFormats: - - string - format: string + type: string required: - action - workspace @@ -607,31 +529,27 @@ TASK_CRUD_TASK: description: Create Task. uiOrder: 0 title: Create - format: object + type: object - properties: action: title: Action const: duplicate description: Duplicate Task. uiOrder: 0 - format: string + type: string task-gid: description: Globally unique identifier (GID) for the task. shortDescription: Task ID uiOrder: 0 title: Task ID - acceptFormats: - - string - format: string + type: string name: description: Name of the new task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. shortDescription: Name of the new task uiOrder: 1 title: Name - acceptFormats: - - string - format: string + type: string required: - action - task-gid @@ -639,30 +557,26 @@ TASK_CRUD_TASK: description: Duplicate Task. uiOrder: 0 title: Duplicate - format: object + type: object - properties: action: title: Action const: set parent description: Set Parent Task. uiOrder: 0 - format: string + type: string task-gid: description: Globally unique identifier (GID) for the task. shortDescription: Task ID uiOrder: 0 title: Task ID - acceptFormats: - - string - format: string + type: string parent: description: GID of the parent task. shortDescription: GID of the parent task uiOrder: 1 title: Parent Task - acceptFormats: - - string - format: string + type: string required: - action - task-gid @@ -670,30 +584,26 @@ TASK_CRUD_TASK: description: Set Parent Task. uiOrder: 0 title: Set Parent - format: object + type: object - properties: action: title: Action const: edit tag description: Edit Tag. uiOrder: 0 - format: string + type: string task-gid: description: Globally unique identifier (GID) for the task. shortDescription: Task ID uiOrder: 0 title: Task ID - acceptFormats: - - string - format: string + type: string tag-gid: description: Globally unique identifier (GID) for the tag. shortDescription: Tag ID uiOrder: 1 title: Tag ID - acceptFormats: - - string - format: string + type: string edit-option: default: add description: Edit option. You can choose to add or remove the tag. @@ -703,9 +613,7 @@ TASK_CRUD_TASK: enum: - add - remove - acceptFormats: - - string - format: string + type: string required: - action - task-gid @@ -714,30 +622,26 @@ TASK_CRUD_TASK: description: Edit Tag. uiOrder: 0 title: Edit Tag - format: object + type: object - properties: action: title: Action const: edit follower description: Edit follower. uiOrder: 0 - format: string + type: string task-gid: description: Globally unique identifier (GID) for the task. shortDescription: Task ID uiOrder: 0 title: Task ID - acceptFormats: - - string - format: string + type: string followers: description: This can either be the string "me", an email, or the gid of a user. For multiple followers, separate them with commas. shortDescription: Followers' Identifications, can either be the string "me", an email, or the gid of a user. uiOrder: 1 title: Followers - acceptFormats: - - string - format: string + type: string edit-option: default: add description: Edit option. You can choose to add or remove the follower. @@ -747,9 +651,7 @@ TASK_CRUD_TASK: enum: - add - remove - acceptFormats: - - string - format: string + type: string required: - action - task-gid @@ -758,30 +660,26 @@ TASK_CRUD_TASK: description: Edit Follower. uiOrder: 0 title: Edit Follower - format: object + type: object - properties: action: title: Action const: edit project description: Edit project. uiOrder: 0 - format: string + type: string task-gid: description: Globally unique identifier (GID) for the task. shortDescription: Task ID uiOrder: 0 title: Task ID - acceptFormats: - - string - format: string + type: string project-gid: description: Globally unique identifier (GID) for the project. shortDescription: Project ID uiOrder: 1 title: Project ID - acceptFormats: - - string - format: string + type: string edit-option: default: add description: Edit option. You can choose to add or remove the project. @@ -791,9 +689,7 @@ TASK_CRUD_TASK: enum: - add - remove - acceptFormats: - - string - format: string + type: string required: - action - task-gid @@ -802,11 +698,11 @@ TASK_CRUD_TASK: description: Edit Project. uiOrder: 0 title: Edit Project - format: object - format: object + type: object + type: object required: [] title: Input - format: object + type: object output: description: Task. uiOrder: 0 @@ -816,25 +712,25 @@ TASK_CRUD_TASK: shortDescription: Task ID uiOrder: 0 title: Task ID - format: string + type: string name: description: The name of the task. shortDescription: Task Name uiOrder: 1 title: Task Name - format: string + type: string notes: description: The notes of the task. shortDescription: Task Notes uiOrder: 2 title: Task Notes - format: string + type: string html-notes: description: The notes of the task in HTML format. shortDescription: Task Notes in HTML format uiOrder: 3 title: Task Notes in HTML format - format: string + type: string projects: description: The projects of the task. shortDescription: The projects of the task. @@ -847,36 +743,36 @@ TASK_CRUD_TASK: shortDescription: Project ID uiOrder: 0 title: Project ID - format: string + type: string name: description: The name of the project. shortDescription: Project Name uiOrder: 1 title: Project Name - format: string + type: string required: - gid - name - format: object - format: array + type: object + type: array due-on: description: The date on which the task is due. In the format YYYY-MM-DD. shortDescription: Due Date uiOrder: 4 title: Due Date - format: string + type: string start-on: description: The date on which the task starts. In the format YYYY-MM-DD. shortDescription: Start Date uiOrder: 5 title: Start Date - format: string + type: string liked: description: Whether the task is liked by the user. shortDescription: Liked uiOrder: 6 title: Liked - format: boolean + type: boolean likes: description: The users who likes the task. shortDescription: The users who likes the task. @@ -889,59 +785,59 @@ TASK_CRUD_TASK: shortDescription: Like ID uiOrder: 0 title: Like ID - format: string + type: string user-gid: description: Globally unique identifier (GID) for the user. shortDescription: User ID uiOrder: 0 title: User ID - format: string + type: string name: description: The name of the user. shortDescription: User Name uiOrder: 1 title: User Name - format: string + type: string required: - like-gid - user-gid - name - format: object - format: array + type: object + type: array approval-status: description: The approval status of the task. If you set completed to true, this field will be set to approved. shortDescription: The approval status of the task uiOrder: 8 title: Approval Status - format: string + type: string resource-subtype: description: The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. shortDescription: The subtype of this resource uiOrder: 9 title: Resource Subtype - format: string + type: string completed: description: Whether the task is currently marked complete. shortDescription: Whether the task is currently marked complete uiOrder: 10 title: Completed - format: boolean + type: boolean assignee: description: GID of the assignee. shortDescription: GID of the assignee uiOrder: 11 title: Assignee - format: string + type: string parent: description: GID of the parent task. shortDescription: GID of the parent task uiOrder: 12 title: Parent Task - format: string + type: string required: [] title: Output - format: object + type: object TASK_CRUD_PROJECT: description: Create, Update, Delete, Read and Duplicate project in Asana. shortDescription: Project Related Task, including get, update, delete, create, duplicate @@ -963,69 +859,57 @@ TASK_CRUD_PROJECT: const: get description: Get Project. uiOrder: 0 - format: string + type: string project-gid: description: Globally unique identifier (GID) for the project. shortDescription: Project ID uiOrder: 0 title: Project ID - acceptFormats: - - string - format: string + type: string required: - action - project-gid description: Get Project. uiOrder: 0 title: Get - format: object + type: object - properties: action: title: Action const: update description: Update Project. uiOrder: 0 - format: string + type: string project-gid: description: Globally unique identifier (GID) for the project. shortDescription: Project ID uiOrder: 0 title: Project ID - acceptFormats: - - string - format: string + type: string name: description: The name of the project. shortDescription: Update Project Name uiOrder: 1 title: Project Name - acceptFormats: - - string - format: string + type: string notes: description: The notes of the project. shortDescription: Update Project Note uiOrder: 2 title: Project Note - acceptFormats: - - string - format: string + type: string due-on: description: The date on which the project is due. In the format YYYY-MM-DD. shortDescription: Update Due Date uiOrder: 2 title: Due Date - acceptFormats: - - string - format: string + type: string start-on: description: The date on which the project starts. In the format YYYY-MM-DD. shortDescription: Update Start Date uiOrder: 3 title: Start Date - acceptFormats: - - string - format: string + type: string color: description: The color of the project. shortDescription: Update Color @@ -1052,9 +936,7 @@ TASK_CRUD_PROJECT: - none - 'null' title: Update Color - acceptFormats: - - string - format: string + type: string privacy-setting: description: The privacy setting of the project. shortDescription: Update Privacy Setting @@ -1064,17 +946,13 @@ TASK_CRUD_PROJECT: - public to workspace - private to team - private - acceptFormats: - - string - format: string + type: string archived: description: Whether the project is archived. shortDescription: Whether the project is archived uiOrder: 7 title: Archived - acceptFormats: - - boolean - format: boolean + type: boolean required: - action - project-gid @@ -1082,68 +960,58 @@ TASK_CRUD_PROJECT: description: Update Project. uiOrder: 0 title: Update - format: object + type: object - properties: action: title: Action const: delete description: Delete project. uiOrder: 0 - format: string + type: string project-gid: description: Globally unique identifier (GID) for the project. shortDescription: Project ID uiOrder: 0 title: Project ID - acceptFormats: - - string - format: string + type: string required: - action - project-gid description: Delete Project. uiOrder: 0 title: Delete - format: object + type: object - properties: action: title: Action const: create description: Create project. uiOrder: 0 - format: string + type: string name: description: The name of the project. shortDescription: Update Project Name uiOrder: 1 title: Project Name - acceptFormats: - - string - format: string + type: string notes: description: The notes of the project. shortDescription: Update Project Note uiOrder: 2 title: Project Note - acceptFormats: - - string - format: string + type: string due-on: description: The date on which the project is due. In the format YYYY-MM-DD. shortDescription: Update Due Date uiOrder: 2 title: Due Date - acceptFormats: - - string - format: string + type: string start-on: description: The date on which the project starts. In the format YYYY-MM-DD. shortDescription: Update Start Date uiOrder: 3 title: Start Date - acceptFormats: - - string - format: string + type: string color: description: The color of the project. shortDescription: Update Color @@ -1170,9 +1038,7 @@ TASK_CRUD_PROJECT: - none - 'null' title: Update Color - acceptFormats: - - string - format: string + type: string privacy-setting: description: The privacy setting of the project. shortDescription: Update Privacy Setting @@ -1182,92 +1048,74 @@ TASK_CRUD_PROJECT: - public to workspace - private to team - private - acceptFormats: - - string - format: string + type: string workspace: description: Globally unique identifier (GID) for the workspace. You can find one by filling the access token in the Asana API Playground. shortDescription: Workspace ID uiOrder: 7 title: Workspace ID - acceptFormats: - - string - format: string + type: string team: description: Globally unique identifier (GID) for the team of the new project. shortDescription: Team ID of the new project uiOrder: 8 title: Team ID - acceptFormats: - - string - format: string + type: string required: - action - name description: Create Project. uiOrder: 0 title: Create - format: object + type: object - properties: action: title: Action const: duplicate description: Duplicate project. uiOrder: 0 - format: string + type: string project-gid: description: Globally unique identifier (GID) for the project. You can find the GID of a goal from the URL of the project in Asana. For example, if the URL of the project is https://app.asana.com/0/goal/1234567890, then the GID is 1234567890. shortDescription: Project ID uiOrder: 0 title: Project ID - acceptFormats: - - string - format: string + type: string name: description: The name of the new project. shortDescription: New Project Name uiOrder: 1 title: New Project Name - acceptFormats: - - string - format: string + type: string team: description: Globally unique identifier (GID) for the team of the new project. If team is not defined, the new project will be in the same team as the the original project. shortDescription: Team ID of the new project uiOrder: 2 title: Team ID - acceptFormats: - - string - format: string + type: string due-on: description: Sets the last due date in the duplicated project to the given date. The rest of the due dates will be offset by the same amount as the due dates in the original project. In the format YYYY-MM-DD. shortDescription: Due Date (You should only specify exactly one of due-on or start-on) uiOrder: 3 title: Due Date - acceptFormats: - - string - format: string + type: string start-on: description: Sets the first start date in the duplicated project to the given date. The rest of the start dates will be offset by the same amount as the start dates in the original project. In the format YYYY-MM-DD. shortDescription: Start Date (You should only specify exactly one of due-on or start-on) uiOrder: 4 title: Start Date - acceptFormats: - - string - format: string + type: string should-skip-weekends: description: Determines if the auto-shifted dates should skip weekends. shortDescription: Determines if the auto-shifted dates should skip weekends. uiOrder: 5 title: Should Skip Weekends (For auto-shifted dates) - acceptFormats: - - boolean - format: boolean + type: boolean required: - action - project-gid @@ -1275,11 +1123,11 @@ TASK_CRUD_PROJECT: description: Duplicate Project. uiOrder: 0 title: Duplicate - format: object - format: object + type: object + type: object required: [] title: Input - format: object + type: object output: description: Project. uiOrder: 0 @@ -1289,13 +1137,13 @@ TASK_CRUD_PROJECT: shortDescription: Project ID uiOrder: 0 title: Project ID - format: string + type: string name: description: The name of the project. shortDescription: Project Name uiOrder: 1 title: Project Name - format: string + type: string owner: description: The owner of the project. shortDescription: The owner of the project. @@ -1307,65 +1155,65 @@ TASK_CRUD_PROJECT: shortDescription: Owner ID uiOrder: 0 title: Owner ID - format: string + type: string name: description: The name of the owner. shortDescription: Owner Name uiOrder: 1 title: Owner Name - format: string + type: string required: - gid - name - format: object + type: object notes: description: The notes of the project. shortDescription: The notes of the project. uiOrder: 2 title: Project Note - format: string + type: string html-notes: description: The notes of the project in HTML format. shortDescription: The notes of the project in HTML format. uiOrder: 3 title: Project HTML Note - format: string + type: string due-on: description: The date on which the project is due. In the format YYYY-MM-DD. shortDescription: Due Date uiOrder: 4 title: Due Date - format: string + type: string start-on: description: The date on which the project starts. In the format YYYY-MM-DD. shortDescription: Start Date uiOrder: 5 title: Start Date - format: string + type: string completed: description: Whether the project is completed. shortDescription: Whether the project is completed uiOrder: 6 title: Completed - format: boolean + type: boolean color: description: The color of the project. shortDescription: Color uiOrder: 7 title: Color - format: string + type: string privacy-setting: description: The privacy setting of the project. shortDescription: Privacy Setting uiOrder: 8 title: Privacy Setting - format: string + type: string archived: description: Whether the project is archived. shortDescription: Whether the project is archived uiOrder: 9 title: Archived - format: boolean + type: boolean completed-by: description: The user who completed the project. shortDescription: The user who completed the project. @@ -1377,17 +1225,17 @@ TASK_CRUD_PROJECT: shortDescription: User ID uiOrder: 0 title: User ID - format: string + type: string name: description: The name of the user. shortDescription: User Name uiOrder: 1 title: User Name - format: string + type: string required: - gid - name - format: object + type: object current-status: description: The current status of the project. shortDescription: The current status of the project. @@ -1397,8 +1245,8 @@ TASK_CRUD_PROJECT: items: properties: {} required: [] - format: json - format: array + type: json + type: array custom-fields: description: The custom fields of the project. shortDescription: The custom fields of the project. @@ -1408,8 +1256,8 @@ TASK_CRUD_PROJECT: items: properties: {} required: [] - format: json - format: array + type: json + type: array custom-field-settings: description: The custom field settings of the project. shortDescription: The custom field settings of the project. @@ -1419,17 +1267,17 @@ TASK_CRUD_PROJECT: items: properties: {} required: [] - format: json - format: array + type: json + type: array modified-at: description: The time at which the project was last modified. shortDescription: The time at which the project was last modified. uiOrder: 14 title: Modified At - format: string + type: string required: [] title: Output - format: object + type: object TASK_CRUD_PORTFOLIO: description: Create, Update, Delete and Read portfolio in Asana. shortDescription: Portfolio Related Task, including get, update, delete, create @@ -1451,45 +1299,39 @@ TASK_CRUD_PORTFOLIO: const: get description: Get portfolio. uiOrder: 0 - format: string + type: string portfolio-gid: description: Globally unique identifier (GID) for the portfolio. shortDescription: Portfolio ID uiOrder: 0 title: Portfolio ID - acceptFormats: - - string - format: string + type: string required: - action - portfolio-gid description: Get Portfolio. uiOrder: 0 title: Get - format: object + type: object - properties: action: title: Action const: update description: Update portfolio. uiOrder: 0 - format: string + type: string portfolio-gid: description: Globally unique identifier (GID) for the portfolio. shortDescription: Portfolio ID uiOrder: 0 title: Portfolio ID - acceptFormats: - - string - format: string + type: string name: description: The name of the portfolio. shortDescription: Update Portfolio Name uiOrder: 1 title: Portfolio Name - acceptFormats: - - string - format: string + type: string color: description: The color of the portfolio. shortDescription: Update Color @@ -1516,69 +1358,59 @@ TASK_CRUD_PORTFOLIO: - none - 'null' title: Update Color - acceptFormats: - - string - format: string + type: string public: description: Whether the portfolio is public. shortDescription: Whether the portfolio is public uiOrder: 6 title: Public - acceptFormats: - - boolean - format: boolean + type: boolean workspace: description: The workspace of the portfolio. Please fill in the Globally unique identifier (GID) for the workspace. shortDescription: The workspace of the portfolio. uiOrder: 7 title: Workspace - acceptFormats: - - string - format: string + type: string required: - action - portfolio-gid description: Update Portfolio. uiOrder: 0 title: Update - format: object + type: object - properties: action: title: Action const: delete description: Delete portfolio. uiOrder: 0 - format: string + type: string portfolio-gid: description: Globally unique identifier (GID) for the portfolio. shortDescription: Portfolio ID uiOrder: 0 title: Portfolio ID - acceptFormats: - - string - format: string + type: string required: - action - portfolio-gid description: Delete Portfolio. uiOrder: 0 title: Delete - format: object + type: object - properties: action: title: Action const: create description: Create portfolio. uiOrder: 0 - format: string + type: string name: description: The name of the portfolio. shortDescription: Portfolio Name uiOrder: 1 title: Portfolio Name - acceptFormats: - - string - format: string + type: string color: description: The color of the portfolio. shortDescription: Color @@ -1605,25 +1437,19 @@ TASK_CRUD_PORTFOLIO: - none - 'null' title: Color - acceptFormats: - - string - format: string + type: string public: description: Whether the portfolio is public. shortDescription: Whether the portfolio is public uiOrder: 6 title: Public - acceptFormats: - - boolean - format: boolean + type: boolean workspace: description: The workspace of the portfolio. Please fill in the Globally unique identifier (GID) for the workspace. shortDescription: The workspace of the portfolio. uiOrder: 7 title: Workspace - acceptFormats: - - string - format: string + type: string required: - action - workspace @@ -1632,11 +1458,11 @@ TASK_CRUD_PORTFOLIO: description: Create Portfolio. uiOrder: 0 title: Create - format: object - format: object + type: object + type: object required: [] title: Input - format: object + type: object output: description: Portfolio. uiOrder: 0 @@ -1646,13 +1472,13 @@ TASK_CRUD_PORTFOLIO: shortDescription: Portfolio ID uiOrder: 0 title: Portfolio ID - format: string + type: string name: description: The name of the portfolio. shortDescription: Portfolio Name uiOrder: 1 title: Portfolio Name - format: string + type: string owner: description: The owner of the portfolio. shortDescription: The owner of the portfolio. @@ -1664,41 +1490,41 @@ TASK_CRUD_PORTFOLIO: shortDescription: Owner ID uiOrder: 0 title: Owner ID - format: string + type: string name: description: The name of the owner. shortDescription: Owner Name uiOrder: 1 title: Owner Name - format: string + type: string required: - gid - name - format: object + type: object due-on: description: The date on which the portfolio is due. In the format YYYY-MM-DD. shortDescription: Due Date uiOrder: 4 title: Due Date - format: string + type: string start-on: description: The date on which the portfolio starts. In the format YYYY-MM-DD. shortDescription: Start Date uiOrder: 5 title: Start Date - format: string + type: string color: description: The color of the portfolio. shortDescription: Color uiOrder: 7 title: Color - format: string + type: string public: description: Whether the portfolio is public. shortDescription: Whether the portfolio is public uiOrder: 8 title: Public - format: boolean + type: boolean created-by: description: The user who created the portfolio. shortDescription: The user who created the portfolio. @@ -1710,17 +1536,17 @@ TASK_CRUD_PORTFOLIO: shortDescription: User ID uiOrder: 0 title: User ID - format: string + type: string name: description: The name of the user. shortDescription: User Name uiOrder: 1 title: User Name - format: string + type: string required: - gid - name - format: object + type: object current-status: description: The current status of the portfolio. shortDescription: The current status of the portfolio. @@ -1730,8 +1556,8 @@ TASK_CRUD_PORTFOLIO: items: properties: {} required: [] - format: json - format: array + type: json + type: array custom-fields: description: The custom fields of the portfolio. shortDescription: The custom fields of the portfolio. @@ -1741,8 +1567,8 @@ TASK_CRUD_PORTFOLIO: items: properties: {} required: [] - format: json - format: array + type: json + type: array custom-field-settings: description: The custom field settings of the portfolio. shortDescription: The custom field settings of the portfolio. @@ -1752,8 +1578,8 @@ TASK_CRUD_PORTFOLIO: items: properties: {} required: [] - format: json - format: array + type: json + type: array required: [] title: Output - format: object + type: object diff --git a/pkg/component/application/email/v0/README.mdx b/pkg/component/application/email/v0/README.mdx index 9c3bf935d..7e191f9da 100644 --- a/pkg/component/application/email/v0/README.mdx +++ b/pkg/component/application/email/v0/README.mdx @@ -40,7 +40,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Server Address (required) | `server-address` | string | The address of the email server. | | Server Port (required) | `server-port` | integer | The port of the email server. | @@ -86,7 +86,7 @@ Send an email to recipients
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEND_EMAIL` | | Recipient (required) | `recipients` | array[string] | The email addresses of the recipients. | @@ -103,7 +103,7 @@ Send an email to recipients
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Result | `result` | string | The result of sending the email. |
@@ -115,7 +115,7 @@ Read emails from a mailbox
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_READ_EMAILS` | | [Search](#read-emails-search) | `search` | object | The search criteria for the emails. | @@ -131,7 +131,7 @@ The search criteria for the emails.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Search Date | `date` | string | Search for emails with the date the email was sent. | | Limit | `limit` | integer | The maximum number of emails to search for. | @@ -147,7 +147,7 @@ The search criteria for the emails.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Emails](#read-emails-emails) | `emails` | array[object] | The emails that match the search criteria. |
@@ -159,7 +159,7 @@ The search criteria for the emails.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Date | `date` | string | The date the email was sent. | | From | `from` | string | The email address of the sender. | diff --git a/pkg/component/application/email/v0/config/setup.yaml b/pkg/component/application/email/v0/config/setup.yaml index 1ccb57db0..6a656852c 100644 --- a/pkg/component/application/email/v0/config/setup.yaml +++ b/pkg/component/application/email/v0/config/setup.yaml @@ -2,38 +2,30 @@ additionalProperties: false properties: email-address: description: The email address of the user. - acceptFormats: - - string + type: string instillSecret: false uiOrder: 2 title: Email Address - format: string password: description: The password of the App passwords in Gmail settings. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 3 title: App Password - format: string server-address: description: The address of the email server. - acceptFormats: - - string + type: string uiOrder: 0 title: Server Address - format: string server-port: description: The port of the email server. - acceptFormats: - - integer + type: integer uiOrder: 1 title: Server Port - format: integer required: - email-address - password - server-address - server-port title: Email -format: object +type: object diff --git a/pkg/component/application/email/v0/config/tasks.yaml b/pkg/component/application/email/v0/config/tasks.yaml index 6fbf71c1a..61e080edc 100644 --- a/pkg/component/application/email/v0/config/tasks.yaml +++ b/pkg/component/application/email/v0/config/tasks.yaml @@ -1,46 +1,34 @@ $defs: search-subject: description: Search for emails with a specific subject. - acceptFormats: - - string + type: string uiOrder: 4 title: Search Subject - format: string search-from: description: Search for emails from a specific email address. - acceptFormats: - - string + type: string uiOrder: 2 title: Search From - format: string search-to: description: Search for emails to a specific email address. - acceptFormats: - - string + type: string uiOrder: 3 title: Search To - format: string limit: description: The maximum number of emails to search for. - acceptFormats: - - integer + type: integer uiOrder: 5 title: Limit - format: integer date: description: Search for emails with the date the email was sent. - acceptFormats: - - string + type: string uiOrder: 6 title: Search Date - format: string search-email-message: description: Search for emails with a specific message. - acceptFormats: - - string + type: string uiOrder: 7 title: Search Message - format: string TASK_SEND_EMAIL: shortDescription: Send an email to recipients input: @@ -49,50 +37,40 @@ TASK_SEND_EMAIL: properties: recipients: description: The email addresses of the recipients. - acceptFormats: - - array + type: array items: - format: string + type: string uiOrder: 2 title: Recipient - format: array cc: description: The email addresses for Carbon Copy. - acceptFormats: - - array + type: array items: - format: string + type: string uiOrder: 3 title: Cc - format: array bcc: description: The email addresses for Blind Carbon Copy. - acceptFormats: - - array + type: array items: - format: string + type: string uiOrder: 4 title: Bcc - format: array subject: description: The subject of the email. - acceptFormats: - - string + type: string uiOrder: 5 title: Subject - format: string message: description: The message to be sent. - acceptFormats: - - string + type: string uiOrder: 6 title: Message - format: string required: - recipients - message title: Input - format: object + type: object output: description: The result of sending the email. uiOrder: 0 @@ -101,11 +79,11 @@ TASK_SEND_EMAIL: description: The result of sending the email. uiOrder: 0 title: Result - format: string + type: string required: - result title: Output - format: object + type: object TASK_READ_EMAILS: shortDescription: Read emails from a mailbox input: @@ -118,11 +96,9 @@ TASK_READ_EMAILS: properties: mailbox: description: The mailbox to search for emails. - acceptFormats: - - string + type: string uiOrder: 1 title: Mailbox - format: string search-subject: $ref: '#/$defs/search-subject' search-from: @@ -138,10 +114,10 @@ TASK_READ_EMAILS: required: - mailbox title: Search - format: object + type: object required: [] title: Input - format: object + type: object output: description: The emails that match the search criteria. uiOrder: 0 @@ -155,35 +131,35 @@ TASK_READ_EMAILS: description: The date the email was sent. uiOrder: 0 title: Date - format: string + type: string from: description: The email address of the sender. uiOrder: 1 title: From - format: string + type: string to: description: The email addresses of the recipient. uiOrder: 2 items: description: The email address of the recipient. - format: string + type: string title: To - format: array + type: array subject: description: The subject of the email. uiOrder: 3 title: Subject - format: string + type: string message: description: The message of the email. uiOrder: 4 title: Message - format: string + type: string required: [] - format: object + type: object title: Emails - format: array + type: array required: - emails title: Output - format: object + type: object diff --git a/pkg/component/application/freshdesk/v0/README.mdx b/pkg/component/application/freshdesk/v0/README.mdx index bfeb7b980..7fa977f62 100644 --- a/pkg/component/application/freshdesk/v0/README.mdx +++ b/pkg/component/application/freshdesk/v0/README.mdx @@ -50,7 +50,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key (required) | `api-key` | string | Fill in your Freshdesk API key. To find your key, go to profile settigs and on the right pane, you can get your key once you have completed the captcha verification. | | Domain (required) | `domain` | string | Your Freshdesk domain. You can find this by going to Admin -> Search for "Portals" -> Portal URL. Your portal URL will look like "yourdomain.freshdesk.com". Please only input your domain and not the whole URL. | @@ -69,7 +69,7 @@ Get ticket using ID
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_TICKET` | | Ticket ID (required) | `ticket-id` | integer | The ID of the ticket. | @@ -82,7 +82,7 @@ Get ticket using ID
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Subject | `subject` | string | Subject of the ticket. | | Description Text | `description-text` | string | Content of the ticket. | @@ -125,7 +125,7 @@ Get ticket using ID
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Attachment Content Type | `content-type` | string | The type of the file. | | Attachment Name | `name` | string | The name of the file. | @@ -140,7 +140,7 @@ Create ticket
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_TICKET` | | Requester ID | `requester-id` | integer | ID of the requester. Must be an existing contact. If you fill in this field, you don't need to fill in the email field. Only one of the two fields is required. | @@ -168,7 +168,7 @@ Create ticket
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Ticket ID | `ticket-id` | integer | The ID of the ticket. | | Created At | `created-at` | string | Timestamp that denotes when the ticket/conversation was created. In UTC format. | @@ -181,7 +181,7 @@ Reply to a ticket thread.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_REPLY_TO_TICKET` | | Body (required) | `body` | string | Content of the reply. Can be in HTML format. | @@ -199,7 +199,7 @@ Reply to a ticket thread.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Conversation ID | `conversation-id` | integer | The ID of the note or reply that is associated with the ticket. | | Created At | `created-at` | string | Timestamp that denotes when the ticket/conversation was created. In UTC format. | @@ -212,7 +212,7 @@ Create a private/public note on a ticket thread.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_TICKET_NOTE` | | Ticket ID (required) | `ticket-id` | integer | The ID of the ticket. | @@ -230,7 +230,7 @@ Create a private/public note on a ticket thread.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Conversation ID | `conversation-id` | integer | The ID of the note or reply that is associated with the ticket. | | Created At | `created-at` | string | Timestamp that denotes when the ticket/conversation was created. In UTC format. | @@ -243,7 +243,7 @@ Get all the conversations in a ticket. (Conversations are replies and notes that
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_ALL_CONVERSATIONS` | | Ticket ID (required) | `ticket-id` | integer | Ticket ID. | @@ -256,7 +256,7 @@ Get all the conversations in a ticket. (Conversations are replies and notes that
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Conversations](#get-all-conversations-conversations) | `conversations` | array[object] | An array of conversations. | | Conversations Length | `conversations-length` | integer | Number of conversations. | @@ -269,7 +269,7 @@ Get all the conversations in a ticket. (Conversations are replies and notes that
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | BCC Emails | `bcc-emails` | array | Email addresses added in the 'bcc' field of the incoming ticket email. | | Body Text | `body-text` | string | Content of the conversation. | @@ -292,7 +292,7 @@ Get contact using ID
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_CONTACT` | | Contact ID (required) | `contact-id` | integer | ID of the contact. | @@ -305,7 +305,7 @@ Get contact using ID
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Name | `name` | string | Name of the contact. | | Email (optional) | `email` | string | The primary email address of the contact. | @@ -338,7 +338,7 @@ Get contact using ID
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Company ID | `company-id` | integer | ID of the company. | | View All Tickets | `view-all-tickets` | boolean | Set to true if the contact can see all the tickets that are associated with the company. | @@ -352,7 +352,7 @@ Create contact
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_CONTACT` | | Name (required) | `name` | string | Name of the contact. | @@ -381,7 +381,7 @@ Create contact
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Contact ID | `contact-id` | integer | ID of the contact. | | Created At | `created-at` | string | Timestamp that denotes when the contact was created. In UTC format. | @@ -394,7 +394,7 @@ Get company using ID
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_COMPANY` | | Company ID (required) | `company-id` | integer | ID of the primary company to which the contact belongs. | @@ -407,7 +407,7 @@ Get company using ID
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Name | `name` | string | Name of the company. | | Description (optional) | `description` | string | Description of the company. | @@ -429,7 +429,7 @@ Create company
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_COMPANY` | | Name (required) | `name` | string | Name of the company. | @@ -449,7 +449,7 @@ Create company
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Company ID | `company-id` | integer | ID of the company. | | Created At | `created-at` | string | Timestamp that denotes when the company was created. In UTC format. | @@ -462,7 +462,7 @@ Task to get all the IDs of existing contacts, companies, tickets, products, agen
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_ALL` | | Object Type (required) | `object-type` | string | Type of object to get IDs for.
Enum values
  • `Contacts`
  • `Companies`
  • `Tickets`
  • `Products`
  • `Agents`
  • `Roles`
  • `Skills`
| @@ -476,7 +476,7 @@ Task to get all the IDs of existing contacts, companies, tickets, products, agen
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | IDs | `ids` | array[integer] | List of IDs. | | ID Length | `id-length` | integer | Number of IDs. | @@ -489,7 +489,7 @@ Get product using ID. This task will only work if you have admin privileges.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_PRODUCT` | | Product ID (required) | `product-id` | integer | Product ID. | @@ -502,7 +502,7 @@ Get product using ID. This task will only work if you have admin privileges.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Name | `name` | string | Name of the product. | | Description | `description` | string | Description of the product. | @@ -519,7 +519,7 @@ Get agent using ID. This task will only work if you have admin privileges. Agent
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_AGENT` | | Agent ID (required) | `agent-id` | integer | Agent ID. | @@ -532,7 +532,7 @@ Get agent using ID. This task will only work if you have admin privileges. Agent
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Name (optional) | `name` | string | Name of the agent. | | Active (optional) | `active` | boolean | Set to true if the agent is verified. | @@ -563,7 +563,7 @@ Get role using ID. This task will only work if you have admin privileges. Roles
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_ROLE` | | Role ID (required) | `role-id` | integer | Role ID. | @@ -576,7 +576,7 @@ Get role using ID. This task will only work if you have admin privileges. Roles
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Name | `name` | string | Name of the role. | | Description | `description` | string | Description of the role. | @@ -593,7 +593,7 @@ Get group using ID. This task will only work if you have admin privileges. Agent
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_GROUP` | | Group ID (required) | `group-id` | integer | Group ID. | @@ -606,7 +606,7 @@ Get group using ID. This task will only work if you have admin privileges. Agent
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Name | `name` | string | Name of the group. | | Description | `description` | string | Description of the group. | @@ -627,7 +627,7 @@ Get skill using ID. This task will only work if you have admin privileges. Agent
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_SKILL` | | Skill ID (required) | `skill-id` | integer | Skill ID. | @@ -640,7 +640,7 @@ Get skill using ID. This task will only work if you have admin privileges. Agent
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Name | `name` | string | Name of the skill. | | Rank | `rank` | integer | Rank of the skill. | diff --git a/pkg/component/application/freshdesk/v0/config/setup.yaml b/pkg/component/application/freshdesk/v0/config/setup.yaml index 56ded0bfc..0feab2c71 100644 --- a/pkg/component/application/freshdesk/v0/config/setup.yaml +++ b/pkg/component/application/freshdesk/v0/config/setup.yaml @@ -3,23 +3,19 @@ properties: api-key: description: Fill in your Freshdesk API key. To find your key, go to profile settigs and on the right pane, you can get your key once you have completed the captcha verification. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: API key - format: string domain: description: Your Freshdesk domain. You can find this by going to Admin -> Search for "Portals" -> Portal URL. Your portal URL will look like "yourdomain.freshdesk.com". Please only input your domain and not the whole URL. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 1 title: Domain - format: string required: - api-key - domain title: Freshdesk Connection -format: object +type: object diff --git a/pkg/component/application/freshdesk/v0/config/tasks.yaml b/pkg/component/application/freshdesk/v0/config/tasks.yaml index edb984a73..bb6d36177 100644 --- a/pkg/component/application/freshdesk/v0/config/tasks.yaml +++ b/pkg/component/application/freshdesk/v0/config/tasks.yaml @@ -201,288 +201,288 @@ $defs: ticket-id: description: The ID of the ticket. title: Ticket ID - format: integer + type: integer subject: description: Subject of the ticket. title: Subject - format: string + type: string description-text: description: Content of the ticket. title: Description Text - format: string + type: string source: description: 'Source of the ticket. Eg: Email.' title: Source - format: string + type: string status: description: 'Status of the ticket. Eg: Pending.' title: Status - format: string + type: string priority: description: 'Priority of the ticket. Eg: Medium.' title: Priority - format: string + type: string ticket-type: description: Used to categorize the ticket. To check the possible types a ticket can have, please go to Admin -> Ticket Fields. title: Ticket Type - format: string + type: string association-type: description: Used to determine whether a ticket is a parent, child, tracker or related ticket. title: Association Type - format: string + type: string associated-ticket-list: description: List of associated ticket IDs. title: Associated Ticket List - format: array + type: array tags: description: Tags associated with the ticket. title: Tags - format: array + type: array cc-emails: description: Email addresses added in the 'cc' field of the incoming ticket email. title: CC Emails - format: array + type: array bcc-emails: description: Email addresses added in the 'bcc' field of the incoming ticket email. title: BCC Emails - format: array + type: array forward-emails: description: Email addresses added while forwarding a ticket. title: Forward Emails - format: array + type: array reply-cc-emails: description: Email addresses added while replying to a ticket. title: Reply CC Emails - format: array + type: array requester-id: description: ID of the requester. title: Requester ID - format: integer + type: integer responder-id: description: ID of the agent to whom the ticket has been assigned. List of agents can be found in Admin -> Agents. title: Responder ID - format: integer + type: integer company-id: description: ID of the company to which this ticket belongs. title: Company ID - format: integer + type: integer group-id: description: ID of the group to which the ticket has been assigned. List of groups can be found in Admin -> Groups. title: Group ID - format: integer + type: integer product-id: description: ID of the product to which the ticket is associated. List of products can be found in Admin -> Multiple Products. title: Product ID - format: integer + type: integer support-email: description: Support email address. You can find it in Admin -> Email (under channel). title: Support Email - format: string + type: string to-emails: description: Email addresses to which the ticket was originally sent. title: To Emails - format: array + type: array spam: description: Set to true if the ticket is marked as spam. title: Spam - format: boolean + type: boolean due-by: description: Timestamp that denotes when the ticket is due to be resolved. In UTC format. title: Due By - format: string + type: string is-escalated: description: Set to true if the ticket has been escalated. title: Is Escalated - format: boolean + type: boolean first-response-due-by: description: Timestamp that denotes when the first response is due. In UTC format. You can adjust this by going to Admin -> SLA policy (under Workflows). title: First Response Due By - format: string + type: string first-response-escalated: description: Set to true if the ticket has been escalated as the result of first response time being breached. title: First Response Escalated - format: boolean + type: boolean next-response-due-by: description: Timestamp that denotes when the next response is due. In UTC format. You can adjust this by going to Admin -> SLA policy (under Workflows). title: Next Response Due By - format: string + type: string next-response-escalated: description: Set to true if the ticket has been escalated as the result of next response time being breached. title: Next Response Escalated - format: boolean + type: boolean created-at: description: Timestamp that denotes when the ticket/conversation was created. In UTC format. title: Created At - format: string + type: string updated-at: description: Timestamp that denotes when the ticket was last updated. In UTC format. title: Updated At - format: string + type: string attachments: description: Ticket attachments (cannot be more than 20MB). title: Attachments - format: array + type: array sentiment-score: description: Freshdesk uses AI to assess the emotional tone and attitude expressed in customer interaction. title: Sentiment Score - format: integer + type: integer initial-sentiment-score: description: The initial sentiment score of the ticket. title: Initial Sentiment Score - format: integer + type: integer custom-fields: description: Custom fields that the ticket have. Custom fields can be created or modified in Admin -> Ticket Fields. title: Custom Fields - format: object + type: object conversation-id: description: The ID of the note or reply that is associated with the ticket. title: Conversation ID - format: integer + type: integer contact: contact-id: description: ID of the contact. title: Contact ID - format: integer + type: integer name: description: Name of the contact. title: Name - format: string + type: string email: description: The primary email address of the contact. title: Email - format: string + type: string phone: description: Telephone number of the contact. title: Phone - format: string + type: string mobile: description: Mobile number of the contact. title: Mobile - format: string + type: string description: description: Description of the contact. title: Description - format: string + type: string address: description: Address of the contact. title: Address - format: string + type: string job-title: description: Job title of the contact. title: Job Title - format: string + type: string tags: description: Tags associated with the contact. title: Tags - format: array + type: array language: description: Language of the contact. title: Language - format: string + type: string time-zone: description: Time zone of the contact. title: Time Zone - format: string + type: string company-id: description: ID of the primary company to which the contact belongs. title: Company ID - format: integer + type: integer unique-external-id: description: Unique external ID of the contact which be assigned by the user(agent). title: Unique External ID - format: string + type: string twitter-id: description: Twitter ID of the contact. title: Twitter ID - format: string + type: string view-all-tickets: description: Set to true if the contact can see all the tickets that are associated with the primary company. title: View All Tickets - format: boolean + type: boolean deleted: description: Set to true if the contact is deleted. title: Deleted - format: boolean + type: boolean active: description: Set to true if the contact has been verified. title: Active - format: boolean + type: boolean other-emails: description: List of other email addresses of the contact. title: Other Emails - format: array + type: array other-companies: description: List of other companies to which the contact belongs. title: Other Companies - format: array + type: array other-phone-numbers: description: List of other phone numbers of the contact. title: Other Phone Numbers - format: array + type: array created-at: description: Timestamp that denotes when the contact was created. In UTC format. title: Created At - format: string + type: string updated-at: description: Timestamp that denotes when the contact was last updated. In UTC format. title: Updated At - format: string + type: string custom-fields: description: Custom fields that the contact have. Custom fields can be created or modified in Admin -> Customer Fields. title: Custom Fields - format: object + type: object company: company-id: description: ID of the company. title: Company ID - format: integer + type: integer name: description: Name of the company. title: Name - format: string + type: string description: description: Description of the company. title: Description - format: string + type: string note: description: Note about the company. title: Note - format: string + type: string domains: description: Domains of the company. title: Domains - format: array + type: array health-score: description: 'The strength of your relationship with the company. To look at all the possible values or create custom values, please go to Admin -> Customer Fields. Default values: "At risk", "Doing okay", "Happy".' title: Health Score - format: string + type: string account-tier: description: 'Classification based on how much value the company brings to your business. To look at all the possible values or create custom values, please go to Admin -> Customer Fields. Default values: "Basic", "Premium", "Enterprise".' title: Account Tier - format: string + type: string renewal-date: description: Date when your contract or relationship with the company is due for renewal. title: Renewal Date - format: string + type: string industry: description: The industry in which the company operates. To look at all the possible values or create custom values, please go to Admin -> Customer Fields. title: Industry - format: string + type: string created-at: description: Timestamp that denotes when the company was created. In UTC format. title: Created At - format: string + type: string updated-at: description: Timestamp that denotes when the company was last updated. In UTC format. title: Updated At - format: string + type: string custom-fields: description: Custom fields that the company have. Custom fields can be created or modified in Admin -> Customer Fields. title: Custom Fields - format: object + type: object TASK_GET_TICKET: shortDescription: Get ticket using ID input: @@ -491,13 +491,12 @@ TASK_GET_TICKET: properties: ticket-id: $ref: '#/$defs/ticket/ticket-id' - acceptFormats: - - integer + type: integer uiOrder: 0 required: - ticket-id title: Input - format: object + type: object output: description: Ticket information. uiOrder: 0 @@ -505,139 +504,139 @@ TASK_GET_TICKET: subject: $ref: '#/$defs/ticket/subject' uiOrder: 0 - format: string + type: string description-text: $ref: '#/$defs/ticket/description-text' uiOrder: 1 - format: string + type: string source: $ref: '#/$defs/ticket/source' uiOrder: 2 - format: string + type: string status: $ref: '#/$defs/ticket/status' uiOrder: 3 - format: string + type: string priority: $ref: '#/$defs/ticket/priority' uiOrder: 4 - format: string + type: string ticket-type: $ref: '#/$defs/ticket/ticket-type' uiOrder: 5 - format: string + type: string association-type: $ref: '#/$defs/ticket/association-type' uiOrder: 6 - format: string + type: string associated-ticket-list: $ref: '#/$defs/ticket/associated-ticket-list' items: title: Associated Ticket description: The ID of the ticket associated with the current ticket. - format: integer + type: integer uiOrder: 7 - format: array + type: array tags: $ref: '#/$defs/ticket/tags' items: title: Tag description: Tag associated with the ticket. - format: string + type: string uiOrder: 8 - format: array + type: array cc-emails: $ref: '#/$defs/ticket/cc-emails' items: title: CC Email description: One of the email address added in the 'cc' field of the incoming ticket email. - format: string + type: string uiOrder: 9 - format: array + type: array forward-emails: $ref: '#/$defs/ticket/forward-emails' items: title: Forward Email description: One of the email address added while forwarding a ticket. - format: string + type: string uiOrder: 10 - format: array + type: array reply-cc-emails: $ref: '#/$defs/ticket/reply-cc-emails' items: title: Reply CC Email description: One of the email address added while replying to a ticket. - format: string + type: string uiOrder: 11 - format: array + type: array requester-id: $ref: '#/$defs/ticket/requester-id' uiOrder: 12 - format: integer + type: integer responder-id: $ref: '#/$defs/ticket/responder-id' uiOrder: 13 - format: integer + type: integer company-id: $ref: '#/$defs/ticket/company-id' uiOrder: 14 - format: integer + type: integer group-id: $ref: '#/$defs/ticket/group-id' uiOrder: 15 - format: integer + type: integer product-id: $ref: '#/$defs/ticket/product-id' uiOrder: 16 - format: integer + type: integer support-email: $ref: '#/$defs/ticket/support-email' uiOrder: 17 - format: string + type: string to-emails: $ref: '#/$defs/ticket/to-emails' items: title: To Email description: One of the email address to which the ticket was originally sent. - format: string + type: string uiOrder: 18 - format: array + type: array spam: $ref: '#/$defs/ticket/spam' uiOrder: 19 - format: boolean + type: boolean due-by: $ref: '#/$defs/ticket/due-by' uiOrder: 20 - format: string + type: string is-escalated: $ref: '#/$defs/ticket/is-escalated' uiOrder: 21 - format: boolean + type: boolean first-response-due-by: $ref: '#/$defs/ticket/first-response-due-by' uiOrder: 22 - format: string + type: string first-response-escalated: $ref: '#/$defs/ticket/first-response-escalated' uiOrder: 23 - format: boolean + type: boolean next-response-due-by: $ref: '#/$defs/ticket/next-response-due-by' uiOrder: 24 - format: string + type: string next-response-escalated: $ref: '#/$defs/ticket/next-response-escalated' uiOrder: 25 - format: boolean + type: boolean created-at: $ref: '#/$defs/ticket/created-at' uiOrder: 26 - format: string + type: string updated-at: $ref: '#/$defs/ticket/updated-at' uiOrder: 27 - format: string + type: string attachments: $ref: '#/$defs/ticket/attachments' items: @@ -647,37 +646,37 @@ TASK_GET_TICKET: description: The name of the file. uiOrder: 0 title: Attachment Name - format: string + type: string content-type: description: The type of the file. uiOrder: 1 title: Attachment Content Type - format: string + type: string url: description: The URL to the attachment. uiOrder: 2 title: Attachment URL - format: string + type: string required: - name - content-type - url - format: object + type: object uiOrder: 28 - format: array + type: array sentiment-score: $ref: '#/$defs/ticket/sentiment-score' uiOrder: 29 - format: integer + type: integer initial-sentiment-score: $ref: '#/$defs/ticket/initial-sentiment-score' uiOrder: 30 - format: integer + type: integer custom-fields: $ref: '#/$defs/ticket/custom-fields' required: [] uiOrder: 31 - format: json + type: json required: - requester-id - subject @@ -688,7 +687,7 @@ TASK_GET_TICKET: - created-at - updated-at title: Output - format: object + type: object TASK_CREATE_TICKET: shortDescription: Create ticket input: @@ -700,29 +699,22 @@ TASK_CREATE_TICKET: the two fields is required. title: Requester ID uiOrder: 0 - acceptFormats: - - integer - format: integer + type: integer email: description: Email address of the requester. If you fill in the Requester ID above, it will be ignored. Only one of the two fields is required. If no contact exists with this email address in Freshdesk, it will be added as a new contact. title: Email uiOrder: 1 - acceptFormats: - - string - format: string + type: string subject: $ref: '#/$defs/ticket/subject' uiOrder: 2 - acceptFormats: - - string + type: string description: description: Content of the ticket. You can use HTML tags in the content. title: Description uiOrder: 3 - acceptFormats: - - string - format: string + type: string source: $ref: '#/$defs/ticket/source' enum: @@ -737,8 +729,7 @@ TASK_CREATE_TICKET: - Ecommerce example: Portal uiOrder: 4 - acceptFormats: - - string + type: string status: $ref: '#/$defs/ticket/status' enum: @@ -750,8 +741,7 @@ TASK_CREATE_TICKET: - Waiting on Third Party example: Open uiOrder: 5 - acceptFormats: - - string + type: string priority: $ref: '#/$defs/ticket/priority' enum: @@ -761,63 +751,51 @@ TASK_CREATE_TICKET: - Urgent example: Low uiOrder: 6 - acceptFormats: - - string + type: string ticket-type: $ref: '#/$defs/ticket/ticket-type' uiOrder: 7 - acceptFormats: - - string + type: string company-id: $ref: '#/$defs/ticket/company-id' uiOrder: 8 - acceptFormats: - - integer + type: integer product-id: $ref: '#/$defs/ticket/product-id' uiOrder: 9 - acceptFormats: - - integer + type: integer group-id: $ref: '#/$defs/ticket/group-id' uiOrder: 10 - acceptFormats: - - integer + type: integer responder-id: $ref: '#/$defs/ticket/responder-id' uiOrder: 11 - acceptFormats: - - integer + type: integer tags: $ref: '#/$defs/ticket/tags' uiOrder: 12 - acceptFormats: - - array + type: array items: - format: string + type: string cc-emails: $ref: '#/$defs/ticket/cc-emails' uiOrder: 13 - acceptFormats: - - array + type: array items: - format: string + type: string parent-id: description: ID of the parent ticket. Need to be filled out if you want to create a child ticket. title: Parent ID uiOrder: 14 - acceptFormats: - - integer - format: integer + type: integer related-ticket-ids: description: List of related ticket IDs. Need to be filled out if you want to create a tracker ticket. title: Related Ticket IDs uiOrder: 15 - acceptFormats: - - array + type: array items: - format: integer - format: array + type: integer required: - subject - description @@ -825,7 +803,7 @@ TASK_CREATE_TICKET: - status - priority title: Input - format: object + type: object output: description: Ticket ID and create date. uiOrder: 0 @@ -833,16 +811,16 @@ TASK_CREATE_TICKET: ticket-id: $ref: '#/$defs/ticket/ticket-id' uiOrder: 0 - format: integer + type: integer created-at: $ref: '#/$defs/ticket/created-at' uiOrder: 1 - format: string + type: string required: - ticket-id - created-at title: Output - format: object + type: object TASK_REPLY_TO_TICKET: shortDescription: Reply to a ticket thread. input: @@ -852,53 +830,42 @@ TASK_REPLY_TO_TICKET: ticket-id: $ref: '#/$defs/ticket/ticket-id' uiOrder: 0 - acceptFormats: - - integer + type: integer body: description: Content of the reply. Can be in HTML format. title: Body uiOrder: 0 - acceptFormats: - - string - format: string + type: string from-email: description: Email address that is replying to the ticket. You need to have this email address registered in Freshdesk by going to Admin -> Emails. If you leave this field empty, the global support email will be used. title: From Email uiOrder: 1 - acceptFormats: - - string - format: string + type: string user-id: description: ID of the agent/contact replying to the ticket. If you fill this field using a contact ID, there will be no email sent to the requester. title: User ID uiOrder: 2 - acceptFormats: - - integer - format: integer + type: integer cc-emails: description: Email addresses added in the 'cc' field of the outgoing ticket email. title: CC Emails uiOrder: 3 - acceptFormats: - - array + type: array items: - format: string - format: array + type: string bcc-emails: description: Email addresses added in the 'bcc' field of the outgoing ticket email. title: BCC Emails uiOrder: 4 - acceptFormats: - - array + type: array items: - format: string - format: array + type: string required: - ticket-id - body title: Input - format: object + type: object output: description: Conversation ID, Ticket ID and created date. uiOrder: 0 @@ -906,16 +873,16 @@ TASK_REPLY_TO_TICKET: conversation-id: $ref: '#/$defs/ticket/conversation-id' uiOrder: 0 - format: integer + type: integer created-at: $ref: '#/$defs/ticket/created-at' uiOrder: 1 - format: string + type: string required: - conversation-id - created-at title: Output - format: object + type: object TASK_CREATE_TICKET_NOTE: shortDescription: Create a private/public note on a ticket thread. input: @@ -925,51 +892,40 @@ TASK_CREATE_TICKET_NOTE: ticket-id: $ref: '#/$defs/ticket/ticket-id' uiOrder: 0 - acceptFormats: - - integer + type: integer body: description: Content of the note. Can be in HTML format. title: Body uiOrder: 1 - acceptFormats: - - string - format: string + type: string notify-emails: description: Email addresses of agents/users who need to be notified about this note. The emails need to exist in Freshdesk agent. Agent list can be seen in Admin -> Agents. title: Notify Emails uiOrder: 2 - acceptFormats: - - array + type: array items: - format: string - format: array + type: string user-id: description: ID of the agent/contact who is adding the note. title: User ID uiOrder: 3 - acceptFormats: - - integer - format: integer + type: integer private: description: Set to true if the note is private. title: Private uiOrder: 4 - acceptFormats: - - boolean - format: boolean + type: boolean incoming: description: Set to true if a particular note should appear as being created from outside (i.e., not through web portal). title: Incoming uiOrder: 5 - acceptFormats: - - boolean - format: boolean + type: boolean required: - ticket-id - body title: Input - format: object + type: object output: description: Conversation ID, Ticket ID and created date. uiOrder: 0 @@ -977,16 +933,16 @@ TASK_CREATE_TICKET_NOTE: conversation-id: $ref: '#/$defs/ticket/conversation-id' uiOrder: 0 - format: integer + type: integer created-at: $ref: '#/$defs/ticket/created-at' uiOrder: 1 - format: string + type: string required: - conversation-id - created-at title: Output - format: object + type: object TASK_GET_ALL_CONVERSATIONS: shortDescription: Get all the conversations in a ticket. (Conversations are replies and notes that are added to a ticket) input: @@ -997,13 +953,11 @@ TASK_GET_ALL_CONVERSATIONS: description: Ticket ID. title: Ticket ID uiOrder: 2 - acceptFormats: - - integer - format: integer + type: integer required: - ticket-id title: Input - format: object + type: object output: description: Conversations. uiOrder: 0 @@ -1019,15 +973,15 @@ TASK_GET_ALL_CONVERSATIONS: description: Content of the conversation. title: Body Text uiOrder: 0 - format: string + type: string conversation-id: $ref: '#/$defs/ticket/conversation-id' uiOrder: 1 - format: integer + type: integer support-email: $ref: '#/$defs/ticket/support-email' uiOrder: 2 - format: string + type: string to-emails: description: Email addresses of agents/users who need to be notified about this conversation. title: To Emails @@ -1035,65 +989,63 @@ TASK_GET_ALL_CONVERSATIONS: items: title: To Email description: One of the email addresses of agents/users who need to be notified about this conversation. - format: string - format: array + type: string + type: array from-email: description: Email address that is replying to the ticket or adding the note. title: From Email uiOrder: 4 - acceptFormats: - - string - format: string + type: string cc-emails: $ref: '#/$defs/ticket/cc-emails' uiOrder: 5 items: title: CC Email description: One of the email address added in the 'cc' field of the incoming ticket email. - format: string - format: array + type: string + type: array bcc-emails: $ref: '#/$defs/ticket/bcc-emails' uiOrder: 6 items: title: BCC Email description: One of the email address added in the 'bcc' field of the incoming ticket email. - format: string - format: array + type: string + type: array incoming: description: Set to true if a particular conversation should appear as being created from outside. title: Incoming uiOrder: 7 - format: boolean + type: boolean private: description: Set to true if a note is private. Can be set only for notes. title: Incoming uiOrder: 8 - format: boolean + type: boolean user-id: description: ID of the agent/contact replying to the ticket. title: Incoming uiOrder: 9 - format: integer + type: integer created-at: $ref: '#/$defs/ticket/created-at' uiOrder: 10 - format: string + type: string required: - body-text - created-at - format: object - format: array + type: object + type: array conversations-length: description: Number of conversations. title: Conversations Length uiOrder: 1 - format: integer + type: integer required: - conversations - conversations-length title: Output - format: object + type: object TASK_GET_CONTACT: shortDescription: Get contact using ID input: @@ -1102,13 +1054,12 @@ TASK_GET_CONTACT: properties: contact-id: $ref: '#/$defs/contact/contact-id' - acceptFormats: - - integer + type: integer uiOrder: 0 required: - contact-id title: Input - format: object + type: object output: description: Contact information. uiOrder: 0 @@ -1116,79 +1067,79 @@ TASK_GET_CONTACT: name: $ref: '#/$defs/contact/name' uiOrder: 0 - format: string + type: string email: $ref: '#/$defs/contact/email' uiOrder: 1 - format: string + type: string phone: $ref: '#/$defs/contact/phone' uiOrder: 2 - format: string + type: string mobile: $ref: '#/$defs/contact/mobile' uiOrder: 3 - format: string + type: string description: $ref: '#/$defs/contact/description' uiOrder: 4 - format: string + type: string address: $ref: '#/$defs/contact/address' uiOrder: 5 - format: string + type: string job-title: $ref: '#/$defs/contact/job-title' uiOrder: 6 - format: string + type: string tags: $ref: '#/$defs/contact/tags' items: title: Tag description: Tag associated with the contact. - format: string + type: string uiOrder: 7 - format: array + type: array language: $ref: '#/$defs/contact/language' uiOrder: 8 - format: string + type: string time-zone: $ref: '#/$defs/contact/time-zone' uiOrder: 9 - format: string + type: string company-id: $ref: '#/$defs/contact/company-id' uiOrder: 10 - format: integer + type: integer unique-external-id: $ref: '#/$defs/contact/unique-external-id' uiOrder: 11 - format: string + type: string twitter-id: $ref: '#/$defs/contact/twitter-id' uiOrder: 12 - format: string + type: string view-all-tickets: $ref: '#/$defs/contact/view-all-tickets' uiOrder: 13 - format: boolean + type: boolean deleted: $ref: '#/$defs/contact/deleted' uiOrder: 14 - format: boolean + type: boolean active: $ref: '#/$defs/contact/active' uiOrder: 15 - format: boolean + type: boolean other-emails: $ref: '#/$defs/contact/other-emails' items: title: Other Email description: The other email addresses of the contact. - format: string + type: string uiOrder: 16 - format: array + type: array other-companies: $ref: '#/$defs/contact/other-companies' items: @@ -1198,43 +1149,43 @@ TASK_GET_CONTACT: description: ID of the company. uiOrder: 0 title: Company ID - format: integer + type: integer view-all-tickets: description: Set to true if the contact can see all the tickets that are associated with the company. uiOrder: 1 title: View All Tickets - format: boolean + type: boolean required: - company-id - view-all-tickets - format: object + type: object uiOrder: 17 - format: array + type: array other-phone-numbers: $ref: '#/$defs/contact/other-phone-numbers' items: title: Other Phone Number description: The other phone number of the contact. - format: string + type: string uiOrder: 18 - format: array + type: array created-at: $ref: '#/$defs/contact/created-at' uiOrder: 19 - format: string + type: string updated-at: $ref: '#/$defs/contact/updated-at' uiOrder: 20 - format: string + type: string custom-fields: $ref: '#/$defs/contact/custom-fields' required: [] uiOrder: 21 - format: json + type: json required: - name title: Output - format: object + type: object TASK_CREATE_CONTACT: shortDescription: Create contact input: @@ -1244,110 +1195,91 @@ TASK_CREATE_CONTACT: name: $ref: '#/$defs/contact/name' uiOrder: 0 - acceptFormats: - - string + type: string email: $ref: '#/$defs/contact/email' uiOrder: 1 - acceptFormats: - - string + type: string phone: $ref: '#/$defs/contact/phone' uiOrder: 2 - acceptFormats: - - string + type: string mobile: $ref: '#/$defs/contact/mobile' uiOrder: 3 - acceptFormats: - - string + type: string description: $ref: '#/$defs/contact/description' uiOrder: 4 - acceptFormats: - - string + type: string address: $ref: '#/$defs/contact/address' uiOrder: 5 - acceptFormats: - - string + type: string job-title: $ref: '#/$defs/contact/job-title' uiOrder: 6 - acceptFormats: - - string + type: string tags: $ref: '#/$defs/contact/tags' uiOrder: 7 - acceptFormats: - - array + type: array items: - format: string + type: string language: description: Language of the contact. title: Language $ref: '#/$defs/language' uiOrder: 8 - acceptFormats: - - string - format: string + type: string time-zone: description: Time zone of the contact. title: Time Zone $ref: '#/$defs/time-zone' uiOrder: 9 - acceptFormats: - - string - format: string + type: string company-id: $ref: '#/$defs/contact/company-id' uiOrder: 10 - acceptFormats: - - integer + type: integer unique-external-id: $ref: '#/$defs/contact/unique-external-id' uiOrder: 11 - acceptFormats: - - string + type: string twitter-id: $ref: '#/$defs/contact/twitter-id' uiOrder: 12 - acceptFormats: - - string + type: string view-all-tickets: description: 'Used to determine if the contact can see all the tickets that are associated with the primary company. Note: this property will be ignored if the Company ID is not provided.' title: View All Tickets uiOrder: 13 - acceptFormats: - - boolean - format: boolean + type: boolean other-emails: $ref: '#/$defs/contact/other-emails' uiOrder: 14 - acceptFormats: - - array + type: array items: - format: string + type: string other-companies: title: Other Companies description: 'List of other companies to which the contact belongs. Each company should be in the format of company-id;view-all-tickets(boolean "true"/"false") Example: 123;true.' items: - format: string + type: string uiOrder: 15 - format: array + type: array other-phone-numbers: $ref: '#/$defs/contact/other-phone-numbers' uiOrder: 16 - acceptFormats: - - array + type: array items: - format: string + type: string required: - name title: Input - format: object + type: object output: description: Contact ID and create date. uiOrder: 0 @@ -1355,16 +1287,16 @@ TASK_CREATE_CONTACT: contact-id: $ref: '#/$defs/contact/contact-id' uiOrder: 0 - format: integer + type: integer created-at: $ref: '#/$defs/contact/created-at' uiOrder: 1 - format: string + type: string required: - contact-id - created-at title: Output - format: object + type: object TASK_GET_COMPANY: shortDescription: Get company using ID input: @@ -1373,13 +1305,12 @@ TASK_GET_COMPANY: properties: company-id: $ref: '#/$defs/contact/company-id' - acceptFormats: - - integer + type: integer uiOrder: 0 required: - company-id title: Input - format: object + type: object output: description: Company information. uiOrder: 0 @@ -1387,58 +1318,58 @@ TASK_GET_COMPANY: name: $ref: '#/$defs/company/name' uiOrder: 0 - format: string + type: string description: $ref: '#/$defs/company/description' uiOrder: 1 - format: string + type: string note: $ref: '#/$defs/company/note' uiOrder: 2 - format: string + type: string domains: $ref: '#/$defs/company/domains' items: title: Domain description: Domain of the company. - format: string + type: string uiOrder: 3 - format: array + type: array health-score: $ref: '#/$defs/company/health-score' uiOrder: 4 - format: string + type: string account-tier: $ref: '#/$defs/company/account-tier' uiOrder: 5 - format: string + type: string renewal-date: $ref: '#/$defs/company/renewal-date' uiOrder: 6 - format: string + type: string industry: $ref: '#/$defs/company/industry' uiOrder: 7 - format: string + type: string created-at: $ref: '#/$defs/company/created-at' uiOrder: 8 - format: string + type: string updated-at: $ref: '#/$defs/company/updated-at' uiOrder: 9 - format: string + type: string custom-fields: $ref: '#/$defs/company/custom-fields' required: [] uiOrder: 10 - format: json + type: json required: - name - created-at - updated-at title: Output - format: object + type: object TASK_CREATE_COMPANY: shortDescription: Create company input: @@ -1448,51 +1379,42 @@ TASK_CREATE_COMPANY: name: $ref: '#/$defs/company/name' uiOrder: 0 - acceptFormats: - - string + type: string description: $ref: '#/$defs/company/description' uiOrder: 1 - acceptFormats: - - string + type: string note: $ref: '#/$defs/company/note' uiOrder: 2 - acceptFormats: - - string + type: string domains: $ref: '#/$defs/company/domains' uiOrder: 3 - acceptFormats: - - array + type: array items: - format: string + type: string health-score: $ref: '#/$defs/company/health-score' uiOrder: 4 - acceptFormats: - - string + type: string account-tier: $ref: '#/$defs/company/account-tier' uiOrder: 5 - acceptFormats: - - string + type: string renewal-date: description: Date when your contract or relationship with the company is due for renewal. Enter in the format YYYY-MM-DD. title: Renewal Date uiOrder: 6 - acceptFormats: - - string - format: string + type: string industry: $ref: '#/$defs/company/industry' uiOrder: 7 - acceptFormats: - - string + type: string required: - name title: Input - format: object + type: object output: description: Company ID and create date. uiOrder: 0 @@ -1500,16 +1422,16 @@ TASK_CREATE_COMPANY: company-id: $ref: '#/$defs/company/company-id' uiOrder: 0 - format: integer + type: integer created-at: $ref: '#/$defs/company/created-at' uiOrder: 1 - format: string + type: string required: - company-id - created-at title: Output - format: object + type: object TASK_GET_ALL: shortDescription: 'Task to get all the IDs of existing contacts, companies, tickets, products, agents, roles, or skills. Note: products, agents, roles, and skills require admin privileges. Some of these might not work, depending on the plan you are on.' @@ -1529,22 +1451,18 @@ TASK_GET_ALL: - Roles - Skills uiOrder: 0 - acceptFormats: - - string - format: string + type: string length: description: The maximum number of IDs allowed is 500. The most recent IDs will be retrieved. default: 500 title: Length uiOrder: 1 - acceptFormats: - - integer - format: integer + type: integer required: - object-type - length title: Input - format: object + type: object output: description: IDs of the object. uiOrder: 0 @@ -1555,19 +1473,19 @@ TASK_GET_ALL: items: title: ID description: ID of the object. - format: integer + type: integer uiOrder: 0 - format: array + type: array id-length: description: Number of IDs. title: ID Length uiOrder: 1 - format: integer + type: integer required: - ids - id-length title: Output - format: object + type: object TASK_GET_PRODUCT: shortDescription: Get product using ID. This task will only work if you have admin privileges. input: @@ -1578,13 +1496,11 @@ TASK_GET_PRODUCT: description: Product ID. title: Product ID uiOrder: 0 - acceptFormats: - - integer - format: integer + type: integer required: - product-id title: Input - format: object + type: object output: description: Product information. uiOrder: 0 @@ -1593,32 +1509,32 @@ TASK_GET_PRODUCT: description: Name of the product. title: Name uiOrder: 0 - format: string + type: string description: description: Description of the product. title: Description uiOrder: 1 - format: string + type: string primary-email: description: Primary email of the product. title: Primary Email uiOrder: 2 - format: string + type: string created-at: description: Timestamp that denotes when the product was created. title: Created At uiOrder: 3 - format: string + type: string updated-at: description: Timestamp that denotes when the product was last updated. title: Updated At uiOrder: 4 - format: string + type: string default: description: Set to true if the product is the default product. title: Default uiOrder: 5 - format: boolean + type: boolean required: - name - description @@ -1627,7 +1543,7 @@ TASK_GET_PRODUCT: - updated-at - default title: Output - format: object + type: object TASK_GET_AGENT: shortDescription: Get agent using ID. This task will only work if you have admin privileges. Agents are those in your team who will login to Freshdesk. input: @@ -1638,13 +1554,11 @@ TASK_GET_AGENT: description: Agent ID. title: Agent ID uiOrder: 0 - acceptFormats: - - integer - format: integer + type: integer required: - agent-id title: Input - format: object + type: object output: description: Agent information. uiOrder: 0 @@ -1653,52 +1567,52 @@ TASK_GET_AGENT: description: Name of the agent. title: Name uiOrder: 0 - format: string + type: string active: description: Set to true if the agent is verified. title: Active uiOrder: 1 - format: boolean + type: boolean email: description: Email of the agent. title: Email uiOrder: 2 - format: string + type: string job-title: description: Job title of the agent. title: Job Title uiOrder: 3 - format: string + type: string language: description: Language of the agent. title: Language uiOrder: 4 - format: string + type: string mobile: description: Mobile number of the agent. title: Mobile uiOrder: 5 - format: string + type: string phone: description: Telephone number of the agent. title: Phone uiOrder: 6 - format: string + type: string time-zone: description: Time zone of the agent. title: Time Zone uiOrder: 7 - format: string + type: string ticket-scope: description: Ticket permission of the agent. Can be "Global Access", "Group Access" or "Restricted Access". title: Ticket Scope uiOrder: 9 - format: string + type: string available: description: Set to true if the agent is in a group that has enabled "Automatic Ticket Assignment". title: Available uiOrder: 10 - format: boolean + type: boolean group-ids: description: Group IDs of the agent. title: Group IDs @@ -1706,8 +1620,8 @@ TASK_GET_AGENT: items: title: Group ID description: ID of the group. - format: integer - format: array + type: integer + type: array role-ids: description: Role IDs of the agent. title: Role IDs @@ -1715,8 +1629,8 @@ TASK_GET_AGENT: items: title: Role ID description: ID of the role. - format: integer - format: array + type: integer + type: array skill-ids: description: Skill IDs of the agent. title: Skill IDs @@ -1724,50 +1638,50 @@ TASK_GET_AGENT: items: title: Skill ID description: ID of the skill. - format: integer - format: array + type: integer + type: array occasional: description: Set to true if the agent is not working full-time. title: Occasional uiOrder: 14 - format: boolean + type: boolean signature: description: Signature of the agent in HTML format. title: Signature uiOrder: 15 - format: string + type: string focus-mode: description: Set to true if the agent is in focus mode. title: Focus Mode uiOrder: 16 - format: boolean + type: boolean deactivated: description: Set to true if the agent is deactivated. title: Deactivated uiOrder: 17 - format: boolean + type: boolean created-at: description: Timestamp that denotes when the agent was created. title: Created At uiOrder: 18 - format: string + type: string updated-at: description: Timestamp that denotes when the agent was last updated. title: Updated At uiOrder: 19 - format: string + type: string type: description: Type of the agent. Can be "Support Agent", "Field Agent" or "Collaborator". title: Type uiOrder: 8 - format: string + type: string required: - email - type - ticket-scope - occasional title: Output - format: object + type: object TASK_GET_ROLE: shortDescription: Get role using ID. This task will only work if you have admin privileges. Roles allow agents/collaborators to have different privileges. input: @@ -1778,13 +1692,11 @@ TASK_GET_ROLE: description: Role ID. title: Role ID uiOrder: 0 - acceptFormats: - - integer - format: integer + type: integer required: - role-id title: Input - format: object + type: object output: description: Role information. uiOrder: 0 @@ -1793,32 +1705,32 @@ TASK_GET_ROLE: description: Name of the role. title: Name uiOrder: 0 - format: string + type: string description: description: Description of the role. title: Description uiOrder: 1 - format: string + type: string default: description: Set to true if the role is the default role. title: Default uiOrder: 2 - format: boolean + type: boolean agent-type: description: Type of the agent. Can be "Support Agent", "Field Agent" or "Collaborator". title: Agent Type uiOrder: 3 - format: string + type: string created-at: description: Timestamp that denotes when the role was created. title: Created At uiOrder: 4 - format: string + type: string updated-at: description: Timestamp that denotes when the role was last updated. title: Updated At uiOrder: 5 - format: string + type: string required: - name - description @@ -1827,7 +1739,7 @@ TASK_GET_ROLE: - created-at - updated-at title: Output - format: object + type: object TASK_GET_GROUP: shortDescription: Get group using ID. This task will only work if you have admin privileges. Agents can be classified into groups such as Customer Support. input: @@ -1838,13 +1750,11 @@ TASK_GET_GROUP: description: Group ID. title: Group ID uiOrder: 0 - acceptFormats: - - integer - format: integer + type: integer required: - group-id title: Input - format: object + type: object output: description: Group information. uiOrder: 0 @@ -1853,12 +1763,12 @@ TASK_GET_GROUP: description: Name of the group. title: Name uiOrder: 0 - format: string + type: string description: description: Description of the group. title: Description uiOrder: 1 - format: string + type: string agent-ids: description: Agent IDs of the group. title: Agent IDs @@ -1866,43 +1776,43 @@ TASK_GET_GROUP: items: title: Agent ID description: ID of the agent. - format: integer - format: array + type: integer + type: array auto-ticket-assign: description: The type of automatic ticket assignment set for the group. title: Auto Ticket Assign uiOrder: 3 - format: string + type: string escalate-to: description: The ID of the user to whom an escalation email is sent if a ticket is unassigned. title: Escalate To uiOrder: 4 - format: integer + type: integer unassigned-duration: description: The duration for which a ticket is unassigned before it is escalated. title: Unassigned Duration uiOrder: 5 - format: string + type: string group-type: description: Group type. Can be "support_agent_group" or "field_agent_group". title: Group Type uiOrder: 6 - format: string + type: string agent-availability-status: description: The availability status of the agent in the group. Automatically set to true if the group has enabled "Automatic Ticket Assignment". title: Agent Availability Status uiOrder: 7 - format: boolean + type: boolean created-at: description: Timestamp that denotes when the group was created. title: Created At uiOrder: 8 - format: string + type: string updated-at: description: Timestamp that denotes when the group was last updated. title: Updated At uiOrder: 9 - format: string + type: string required: - name - description @@ -1910,7 +1820,7 @@ TASK_GET_GROUP: - created-at - updated-at title: Output - format: object + type: object TASK_GET_SKILL: shortDescription: Get skill using ID. This task will only work if you have admin privileges. Agents can be assigned skills, and it is possible for tickets to be automatically assigned to agents based on the skills they have. @@ -1922,13 +1832,11 @@ TASK_GET_SKILL: description: Skill ID. title: Skill ID uiOrder: 0 - acceptFormats: - - integer - format: integer + type: integer required: - skill-id title: Input - format: object + type: object output: description: Skill information. uiOrder: 0 @@ -1937,35 +1845,35 @@ TASK_GET_SKILL: description: Name of the skill. title: Name uiOrder: 0 - format: string + type: string rank: description: Rank of the skill. title: Rank uiOrder: 1 - format: integer + type: integer condition-match-type: description: Type of condition match. Can be "all" or "any". title: Condition Match Type uiOrder: 2 - format: string + type: string conditions: description: Conditions for the skill. title: Conditions items: title: Condition - format: json + type: json uiOrder: 3 - format: array + type: array created-at: description: Timestamp that denotes when the skill was created. title: Created At uiOrder: 4 - format: string + type: string updated-at: description: Timestamp that denotes when the skill was last updated. title: Updated At uiOrder: 5 - format: string + type: string required: - name - rank @@ -1974,4 +1882,4 @@ TASK_GET_SKILL: - created-at - updated-at title: Output - format: object + type: object diff --git a/pkg/component/application/github/v0/.compogen/bottom.mdx b/pkg/component/application/github/v0/.compogen/bottom.mdx index 4161482f8..681194bd9 100644 --- a/pkg/component/application/github/v0/.compogen/bottom.mdx +++ b/pkg/component/application/github/v0/.compogen/bottom.mdx @@ -210,11 +210,11 @@ variable: repository-name: title: Repository Name description: Name of the repository i.e. instill-core - format: string + type: string repository-owner: title: Repository Owner description: Name of the repository owner i.e. instill-ai - format: string + type: string output: result: title: Result @@ -237,22 +237,22 @@ on: variable: repository: title: repository - format: string + type: string listen: - ${on.github-0.message.repository.full-name} user: title: user - format: string + type: string listen: - ${on.github-0.message.sender.login} description: title: user - format: string + type: string listen: - ${on.github-0.message.repository.description} stargazers-count: title: stargazers-count - format: number + type: number listen: - ${on.github-0.message.repository.stargazers-count} diff --git a/pkg/component/application/github/v0/README.mdx b/pkg/component/application/github/v0/README.mdx index b9bafc637..768339049 100644 --- a/pkg/component/application/github/v0/README.mdx +++ b/pkg/component/application/github/v0/README.mdx @@ -14,6 +14,8 @@ It can carry out the following tasks: - [Create Review Comment](#create-review-comment) - [List Issues](#list-issues) - [Get Issue](#get-issue) +- [Get User](#get-user) +- [Get Organization](#get-organization) - [Create Issue](#create-issue) - [Create Webhook](#create-webhook) @@ -44,7 +46,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Token (required) | `token` | string | Fill in your GitHub access token for advanced usages. For more information about how to create tokens, please refer to the github settings. | @@ -62,7 +64,7 @@ Get the list of all pull requests in a repository. Detailed information about ea
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_LIST_PULL_REQUESTS` | | Owner (required) | `owner` | string | Owner of the repository. | @@ -81,7 +83,7 @@ Get the list of all pull requests in a repository. Detailed information about ea
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Pull Requests](#list-pull-requests-pull-requests) | `pull-requests` | array[object] | An array of PRs. |
@@ -93,7 +95,7 @@ Get the list of all pull requests in a repository. Detailed information about ea
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | PR base | `base` | string | Base commit of the PR (in SHA value). | | PR body | `body` | string | Body of the PR. | @@ -113,7 +115,7 @@ Get the list of all pull requests in a repository. Detailed information about ea
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Files](#list-pull-requests-files) | `files` | array | Files in the commit. | | Commit message | `message` | string | Message of the commit. | @@ -125,7 +127,7 @@ Get the list of all pull requests in a repository. Detailed information about ea
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Additions | `additions` | integer | Number of additions in the commit. | | Total changes | `changes` | integer | Total number of changes in the commit. | @@ -136,7 +138,7 @@ Get the list of all pull requests in a repository. Detailed information about ea
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Additions | `additions` | integer | Number of additions in the commit. | | Total changes | `changes` | integer | Total number of changes in the commit. | @@ -153,7 +155,7 @@ Get a pull request from a repository, given the PR number. This will default to
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_PULL_REQUEST` | | Owner (required) | `owner` | string | Owner of the repository. | @@ -168,7 +170,7 @@ Get a pull request from a repository, given the PR number. This will default to
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | PR ID (optional) | `id` | integer | ID of the PR. | | PR Number (optional) | `number` | integer | Number of the PR. | @@ -191,7 +193,7 @@ Get a pull request from a repository, given the PR number. This will default to
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Files](#get-pull-request-files) | `files` | array | Files in the commit. | | Commit message | `message` | string | Message of the commit. | @@ -203,7 +205,7 @@ Get a pull request from a repository, given the PR number. This will default to
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Additions | `additions` | integer | Number of additions in the commit. | | Total changes | `changes` | integer | Total number of changes in the commit. | @@ -214,7 +216,7 @@ Get a pull request from a repository, given the PR number. This will default to
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Additions | `additions` | integer | Number of additions in the commit. | | Total changes | `changes` | integer | Total number of changes in the commit. | @@ -231,7 +233,7 @@ Get a commit from a repository, given the commit SHA
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_COMMIT` | | Owner (required) | `owner` | string | Owner of the repository. | @@ -246,7 +248,7 @@ Get a commit from a repository, given the commit SHA
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Commit SHA (optional) | `sha` | string | SHA of the commit. | | Commit Message (optional) | `message` | string | Message of the commit. | @@ -261,7 +263,7 @@ Get a commit from a repository, given the commit SHA
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Additions | `additions` | integer | Number of additions in the commit. | | Total changes | `changes` | integer | Total number of changes in the commit. | @@ -272,7 +274,7 @@ Get a commit from a repository, given the commit SHA
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Additions | `additions` | integer | Number of additions in the commit. | | Total changes | `changes` | integer | Total number of changes in the commit. | @@ -289,7 +291,7 @@ Get the review comments in a pull request. The comments can be on a specific lin
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_LIST_REVIEW_COMMENTS` | | Owner (required) | `owner` | string | Owner of the repository. | @@ -309,7 +311,7 @@ Get the review comments in a pull request. The comments can be on a specific lin
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Comments](#list-review-comments-comments) | `comments` | array[object] | An array of comments. |
@@ -321,7 +323,7 @@ Get the review comments in a pull request. The comments can be on a specific lin
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Comment body | `body` | string | Body of the comment. | | Commit SHA | `commit-id` | string | SHA of the commit on which you want to comment. | @@ -342,7 +344,7 @@ Get the review comments in a pull request. The comments can be on a specific lin
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | User id | `id` | integer | ID of the user. | | User URL | `url` | string | URL of the user. | @@ -356,7 +358,7 @@ Create a review comment in a pull request. The comment can be a general comment
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_REVIEW_COMMENT` | | Owner (required) | `owner` | string | Owner of the repository. | @@ -375,7 +377,7 @@ The comment to be added.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Comment body | `body` | string | Body of the comment. | | Commit SHA | `commit-id` | string | SHA of the commit on which you want to comment. | @@ -392,7 +394,7 @@ The comment to be added.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Comment ID (optional) | `id` | integer | ID of the comment. | | In Reply To (optional) | `in-reply-to-id` | integer | ID of the comment this comment is in reply to. | @@ -416,7 +418,7 @@ The comment to be added.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | User id | `id` | integer | ID of the user. | | User URL | `url` | string | URL of the user. | @@ -430,7 +432,7 @@ Get the list of all issues in a repository,This can be a pull request or a gener
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_LIST_ISSUES` | | Owner (required) | `owner` | string | Owner of the repository. | @@ -451,7 +453,7 @@ Get the list of all issues in a repository,This can be a pull request or a gener
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Issues](#list-issues-issues) | `issues` | array[object] | An array of issues. |
@@ -463,7 +465,7 @@ Get the list of all issues in a repository,This can be a pull request or a gener
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Assignee | `assignee` | string | Assignee of the issue. | | Assignees | `assignees` | array | Assignees of the issue. | @@ -483,7 +485,7 @@ Get an issue. This can be a pull request or a general issue, and you can tell by
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_ISSUE` | | Owner (required) | `owner` | string | Owner of the repository. | @@ -498,7 +500,7 @@ Get an issue. This can be a pull request or a general issue, and you can tell by
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Issue Number (optional) | `number` | integer | Number of the issue. | | Issue State (optional) | `state` | string | State of the issue. | @@ -511,13 +513,148 @@ Get an issue. This can be a pull request or a general issue, and you can tell by
+### Get User + +Get a user by name or ID. + +
+ +| Input | Field ID | Type | Description | +| :--- | :--- | :--- | :--- | +| Task ID (required) | `task` | string | `TASK_GET_USER` | +| Name | `name` | string | The GitHub username of the user. | +| ID | `id` | integer | The GitHub user ID. If both `name` and `id` are provided, `id` takes precedence. | +
+ + + + + + +
+ +| Output | Field ID | Type | Description | +| :--- | :--- | :--- | :--- | +| User (optional) | `user` | any | The GitHub user information. | +
+ + +### Get Organization + +Get an organization by name or ID. + +
+ +| Input | Field ID | Type | Description | +| :--- | :--- | :--- | :--- | +| Task ID (required) | `task` | string | `TASK_GET_ORGANIZATION` | +| Name | `name` | string | The GitHub organization name. | +| ID | `id` | integer | The GitHub organization ID. If both `name` and `id` are provided, `id` takes precedence. | +
+ + + + + + +
+ +| Output | Field ID | Type | Description | +| :--- | :--- | :--- | :--- | +| [Organization Full](#get-organization-organization-full) (optional) | `organization` | object | Organization Full | +
+ +
+ Output Objects in Get Organization + +

Organization Full

+ +
+ +| Field | Field ID | Type | Note | +| :--- | :--- | :--- | :--- | +| Advanced Security Enabled For New Repositories | `advanced-security-enabled-for-new-repositories` | boolean | Whether GitHub Advanced Security is enabled for new repositories. | +| Archived At | `archived-at` | string | The timestamp when the organization was archived, if applicable. | +| Avatar URL | `avatar-url` | string | The URL of the organization's avatar image. | +| Billing Email | `billing-email` | string | The billing email address for the organization. | +| Blog | `blog` | string | The blog URL of the organization. | +| Collaborators | `collaborators` | integer | The number of collaborators on private repositories. | +| Company | `company` | string | The company name associated with the organization. | +| Created At | `created-at` | string | The timestamp when the organization was created. | +| Default Repository Permission | `default-repository-permission` | string | The default repository permission level for organization members. | +| Dependabot Alerts Enabled For New Repositories | `dependabot-alerts-enabled-for-new-repositories` | boolean | Whether Dependabot alerts are enabled for new repositories. | +| Dependabot Security Updates Enabled For New Repositories | `dependabot-security-updates-enabled-for-new-repositories` | boolean | Whether Dependabot security updates are enabled for new repositories. | +| Dependency Graph Enabled For New Repositories | `dependency-graph-enabled-for-new-repositories` | boolean | Whether dependency graph is enabled for new repositories. | +| Deploy Keys Enabled For Repositories | `deploy-keys-enabled-for-repositories` | boolean | Controls whether or not deploy keys may be added and used for repositories in the organization. | +| Description | `description` | string | The description of the organization. | +| Disk Usage | `disk-usage` | integer | The amount of disk space used by the organization. | +| Email | `email` | string | The public email address of the organization. | +| Events URL | `events-url` | string | The URL of the organization's events API endpoint. | +| Followers | `followers` | integer | The number of followers. | +| Following | `following` | integer | The number of users the organization is following. | +| Has Organization Projects | `has-organization-projects` | boolean | Whether organization projects are enabled. | +| Has Repository Projects | `has-repository-projects` | boolean | Whether repository projects are enabled. | +| Hooks URL | `hooks-url` | string | The URL of the organization's webhooks API endpoint. | +| HTML URL | `html-url` | string | The URL of the organization's GitHub homepage. | +| ID | `id` | integer | The unique identifier of the organization. | +| Is Verified | `is-verified` | boolean | Whether the organization is verified by GitHub. | +| Issues URL | `issues-url` | string | The URL of the organization's issues API endpoint. | +| Location | `location` | string | The location of the organization. | +| Login | `login` | string | The organization's username. | +| Members Allowed Repository Creation Type | `members-allowed-repository-creation-type` | string | The type of repositories members are allowed to create. | +| Members Can Create Internal Repositories | `members-can-create-internal-repositories` | boolean | Whether members can create internal repositories. | +| Members Can Create Pages | `members-can-create-pages` | boolean | Whether members can create GitHub Pages sites. | +| Members Can Create Private Pages | `members-can-create-private-pages` | boolean | Whether members can create private GitHub Pages sites. | +| Members Can Create Private Repositories | `members-can-create-private-repositories` | boolean | Whether members can create private repositories. | +| Members Can Create Public Pages | `members-can-create-public-pages` | boolean | Whether members can create public GitHub Pages sites. | +| Members Can Create Public Repositories | `members-can-create-public-repositories` | boolean | Whether members can create public repositories. | +| Members Can Create Repositories | `members-can-create-repositories` | boolean | Whether organization members can create repositories. | +| Members Can Fork Private Repositories | `members-can-fork-private-repositories` | boolean | Whether members can fork private repositories. | +| Members URL | `members-url` | string | The URL of the organization's members API endpoint. | +| Name | `name` | string | The display name of the organization. | +| Node ID | `node-id` | string | The GraphQL node ID of the organization. | +| Owned Private Repositories | `owned-private-repos` | integer | The number of private repositories owned by the organization. | +| [Plan](#get-organization-plan) | `plan` | object | The organization's plan details. | +| Private Gists | `private-gists` | integer | The number of private gists. | +| Public Gists | `public-gists` | integer | The number of public gists. | +| Public Members URL | `public-members-url` | string | The URL of the organization's public members API endpoint. | +| Public Repositories | `public-repos` | integer | The number of public repositories. | +| Repositories URL | `repos-url` | string | The URL of the organization's repositories API endpoint. | +| Secret Scanning Enabled For New Repositories | `secret-scanning-enabled-for-new-repositories` | boolean | Whether secret scanning is enabled for new repositories. | +| Secret Scanning Push Protection Custom Link | `secret-scanning-push-protection-custom-link` | string | An optional URL string to display to contributors who are blocked from pushing a secret. | +| Secret Scanning Push Protection Custom Link Enabled | `secret-scanning-push-protection-custom-link-enabled` | boolean | Whether a custom link is shown to contributors who are blocked from pushing a secret by push protection. | +| Secret Scanning Push Protection Enabled For New Repositories | `secret-scanning-push-protection-enabled-for-new-repositories` | boolean | Whether secret scanning push protection is enabled for new repositories. | +| Total Private Repositories | `total-private-repos` | integer | The total number of private repositories. | +| Twitter Username | `twitter-username` | string | The Twitter username of the organization. | +| Two Factor Requirement Enabled | `two-factor-requirement-enabled` | boolean | Whether two-factor authentication is required for all members. | +| Type | `type` | string | The type of the account. | +| Updated At | `updated-at` | string | The timestamp when the organization was last updated. | +| URL | `url` | string | The URL of the organization's API endpoint. | +| Web Commit Signoff Required | `web-commit-signoff-required` | boolean | Whether web commit sign-off is required. | +
+ +

Plan

+ +
+ +| Field | Field ID | Type | Note | +| :--- | :--- | :--- | :--- | +| Filled Seats | `filled-seats` | integer | The number of filled seats in the plan. | +| Name | `name` | string | The name of the plan. | +| Private Repositories | `private-repos` | integer | The number of private repositories included in the plan. | +| Seats | `seats` | integer | The total number of seats in the plan. | +| Space | `space` | integer | The amount of disk space included in the plan. | +
+
+ + ### Create Issue Create an issue.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_ISSUE` | | Owner (required) | `owner` | string | Owner of the repository. | @@ -535,7 +672,7 @@ Create an issue.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Issue Number (optional) | `number` | integer | Number of the issue. | | Issue State (optional) | `state` | string | State of the issue. | @@ -554,7 +691,7 @@ Create a webhook for a repository.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_WEBHOOK` | | Owner (required) | `owner` | string | Owner of the repository. | @@ -573,7 +710,7 @@ Create a webhook for a repository.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Webhook ID (optional) | `id` | integer | ID of the webhook. | | Webhook URL (optional) | `url` | string | URL of the webhook. | @@ -589,7 +726,7 @@ Create a webhook for a repository.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content Type | `content-type` | string | Content type of the webhook. | | Insecure SSL | `insecure-ssl` | string | Whether the webhook is insecure. | @@ -811,11 +948,11 @@ variable: repository-name: title: Repository Name description: Name of the repository i.e. instill-core - format: string + type: string repository-owner: title: Repository Owner description: Name of the repository owner i.e. instill-ai - format: string + type: string output: result: title: Result @@ -838,22 +975,22 @@ on: variable: repository: title: repository - format: string + type: string listen: - ${on.github-0.message.repository.full-name} user: title: user - format: string + type: string listen: - ${on.github-0.message.sender.login} description: title: user - format: string + type: string listen: - ${on.github-0.message.repository.description} stargazers-count: title: stargazers-count - format: number + type: number listen: - ${on.github-0.message.repository.stargazers-count} diff --git a/pkg/component/application/github/v0/config/events.yaml b/pkg/component/application/github/v0/config/events.yaml index ed07776b2..134d3c61e 100644 --- a/pkg/component/application/github/v0/config/events.yaml +++ b/pkg/component/application/github/v0/config/events.yaml @@ -4,8 +4,8 @@ EVENT_STAR_CREATED: configSchema: properties: repository: - format: string - format: object + type: string + type: object messageSchema: $schema: http://json-schema.org/draft-07/schema required: @@ -17,9 +17,9 @@ EVENT_STAR_CREATED: action: enum: - created - format: string + type: string starred-at: - format: string + type: string description: "The time the star was created. This is a timestamp in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. Will be `null` for the `deleted` action." repository: $schema: http://json-schema.org/draft-07/schema @@ -105,19 +105,19 @@ EVENT_STAR_CREATED: properties: id: description: Unique identifier of the repository - format: integer + type: integer node-id: description: The GraphQL identifier of the repository. - format: string + type: string name: description: The name of the repository. - format: string + type: string full-name: description: The full, globally unique, name of the repository. - format: string + type: string private: description: Whether the repository is private or public. - format: boolean + type: boolean owner: $schema: http://json-schema.org/draft-07/schema required: @@ -141,246 +141,240 @@ EVENT_STAR_CREATED: - site-admin properties: login: - format: string + type: string id: - format: integer + type: integer node-id: - format: string + type: string name: - format: string + type: string email: - format: - - string - - "null" + type: string avatar-url: - format: string + type: string gravatar-id: - format: string + type: string url: - format: string + type: string html-url: - format: string + type: string followers-url: - format: string + type: string following-url: - format: string + type: string gists-url: - format: string + type: string starred-url: - format: string + type: string subscriptions-url: - format: string + type: string organizations-url: - format: string + type: string repos-url: - format: string + type: string events-url: - format: string + type: string received-events-url: - format: string + type: string site-admin: - format: boolean + type: boolean type: enum: - Bot - User - Organization - format: string + type: string additionalProperties: false title: User - format: object + type: object html-url: - format: string + type: string description: The URL to view the repository on GitHub.com. description: description: The repository description. - format: - - string - - "null" + type: string fork: description: Whether the repository is a fork. - format: boolean + type: boolean url: - format: string + type: string description: The URL to get more information about the repository from the GitHub API. forks-url: - format: string + type: string description: The API URL to list the forks of the repository. keys-url: - format: string + type: string description: A template for the API URL to get information about deploy keys on the repository. collaborators-url: - format: string + type: string description: A template for the API URL to get information about collaborators of the repository. teams-url: - format: string + type: string description: The API URL to list the teams on the repository. hooks-url: - format: string + type: string description: The API URL to list the hooks on the repository. issue-events-url: - format: string + type: string description: A template for the API URL to get information about issue events on the repository. events-url: - format: string + type: string description: The API URL to list the events of the repository. assignees-url: - format: string + type: string description: A template for the API URL to list the available assignees for issues in the repository. branches-url: - format: string + type: string description: A template for the API URL to get information about branches in the repository. tags-url: - format: string + type: string description: The API URL to get information about tags on the repository. blobs-url: - format: string + type: string description: A template for the API URL to create or retrieve a raw Git blob in the repository. git-tags-url: - format: string + type: string description: A template for the API URL to get information about Git tags of the repository. git-refs-url: - format: string + type: string description: A template for the API URL to get information about Git refs of the repository. trees-url: - format: string + type: string description: A template for the API URL to create or retrieve a raw Git tree of the repository. statuses-url: - format: string + type: string description: A template for the API URL to get information about statuses of a commit. languages-url: - format: string + type: string description: The API URL to get information about the languages of the repository. stargazers-url: - format: string + type: string description: The API URL to list the stargazers on the repository. contributors-url: - format: string + type: string description: A template for the API URL to list the contributors to the repository. subscribers-url: - format: string + type: string description: The API URL to list the subscribers on the repository. subscription-url: - format: string + type: string description: The API URL to subscribe to notifications for this repository. commits-url: - format: string + type: string description: A template for the API URL to get information about commits on the repository. git-commits-url: - format: string + type: string description: A template for the API URL to get information about Git commits of the repository. comments-url: - format: string + type: string description: A template for the API URL to get information about comments on the repository. issue-comment-url: - format: string + type: string description: A template for the API URL to get information about issue comments on the repository. contents-url: - format: string + type: string description: A template for the API URL to get the contents of the repository. compare-url: - format: string + type: string description: A template for the API URL to compare two commits or refs. merges-url: - format: string + type: string description: The API URL to merge branches in the repository. archive-url: - format: string + type: string description: A template for the API URL to download the repository as an archive. downloads-url: - format: string + type: string description: The API URL to list the downloads on the repository. issues-url: - format: string + type: string description: A template for the API URL to get information about issues on the repository. pulls-url: - format: string + type: string description: A template for the API URL to get information about pull requests on the repository. milestones-url: - format: string + type: string description: A template for the API URL to get information about milestones of the repository. notifications-url: - format: string + type: string description: A template for the API URL to get information about notifications on the repository. labels-url: - format: string + type: string description: A template for the API URL to get information about labels of the repository. releases-url: - format: string + type: string description: A template for the API URL to get information about releases on the repository. deployments-url: - format: string + type: string description: The API URL to list the deployments of the repository. created-at: oneOf: - - format: integer - - format: string + - type: integer + - type: string updated-at: - format: string + type: string pushed-at: oneOf: - - format: integer - - format: string - - format: "null" + - type: integer + - type: string + - type: 'null' git-url: - format: string + type: string ssh-url: - format: string + type: string clone-url: - format: string + type: string svn-url: - format: string + type: string homepage: - format: + type: - string - "null" size: - format: integer + type: integer stargazers-count: - format: integer + type: integer watchers-count: - format: integer + type: integer language: - format: + type: - string - "null" has-issues: description: Whether issues are enabled. default: true - format: boolean + type: boolean has-projects: description: Whether projects are enabled. default: true - format: boolean + type: boolean has-downloads: description: Whether downloads are enabled. default: true - format: boolean + type: boolean has-wiki: description: Whether the wiki is enabled. default: true - format: boolean + type: boolean has-pages: - format: boolean + type: boolean has-discussions: description: Whether discussions are enabled. default: true - format: boolean + type: boolean forks-count: - format: integer + type: integer mirror-url: - format: - - string - - "null" + type: string archived: description: Whether the repository is archived. default: false - format: boolean + type: boolean disabled: description: Returns whether or not this repository is disabled. - format: boolean + type: boolean open-issues-count: - format: integer + type: integer license: oneOf: - $schema: http://json-schema.org/draft-07/schema @@ -392,83 +386,80 @@ EVENT_STAR_CREATED: - node-id properties: key: - format: string + type: string name: - format: string + type: string spdx-id: - format: string + type: string url: - format: - - string - - "null" + type: string node-id: - format: string + type: string additionalProperties: false title: License - format: object - - format: "null" + type: object forks: - format: integer + type: integer open-issues: - format: integer + type: integer watchers: - format: integer + type: integer stargazers: - format: integer + type: integer default-branch: description: The default branch of the repository. - format: string + type: string allow-squash-merge: description: Whether to allow squash merges for pull requests. default: true - format: boolean + type: boolean allow-merge-commit: description: Whether to allow merge commits for pull requests. default: true - format: boolean + type: boolean allow-rebase-merge: description: Whether to allow rebase merges for pull requests. default: true - format: boolean + type: boolean allow-auto-merge: description: Whether to allow auto-merge for pull requests. default: false - format: boolean + type: boolean allow-forking: description: Whether to allow private forks - format: boolean + type: boolean allow-update-branch: - format: boolean + type: boolean use-squash-pr-title-as-default: - format: boolean + type: boolean squash-merge-commit-message: - format: string + type: string squash-merge-commit-title: - format: string + type: string merge-commit-message: - format: string + type: string merge-commit-title: - format: string + type: string is-template: - format: boolean + type: boolean web-commit-signoff-required: - format: boolean + type: boolean topics: items: - format: string - format: array + type: string + type: array visibility: enum: - public - private - internal - format: string + type: string delete-branch-on-merge: description: Whether to delete head branches when pull requests are merged default: false - format: boolean + type: boolean master-branch: - format: string + type: string permissions: required: - pull @@ -476,33 +467,32 @@ EVENT_STAR_CREATED: - admin properties: pull: - format: boolean + type: boolean push: - format: boolean + type: boolean admin: - format: boolean + type: boolean maintain: - format: boolean + type: boolean triage: - format: boolean + type: boolean additionalProperties: false - format: object + type: object public: - format: boolean + type: boolean organization: - format: string + type: string custom-properties: additionalProperties: oneOf: - - format: "null" - - format: string + - type: string - items: - format: string - format: array - format: object + type: string + type: array + type: object additionalProperties: false title: Repository - format: object + type: object sender: $schema: http://json-schema.org/draft-07/schema required: @@ -526,54 +516,52 @@ EVENT_STAR_CREATED: - site-admin properties: login: - format: string + type: string id: - format: integer + type: integer node-id: - format: string + type: string name: - format: string + type: string email: - format: - - string - - "null" + type: string avatar-url: - format: string + type: string gravatar-id: - format: string + type: string url: - format: string + type: string html-url: - format: string + type: string followers-url: - format: string + type: string following-url: - format: string + type: string gists-url: - format: string + type: string starred-url: - format: string + type: string subscriptions-url: - format: string + type: string organizations-url: - format: string + type: string repos-url: - format: string + type: string events-url: - format: string + type: string received-events-url: - format: string + type: string site-admin: - format: boolean + type: boolean type: enum: - Bot - User - Organization - format: string + type: string additionalProperties: false title: User - format: object + type: object organization: $schema: http://json-schema.org/draft-07/schema required: @@ -591,36 +579,34 @@ EVENT_STAR_CREATED: - description properties: login: - format: string + type: string id: - format: integer + type: integer node-id: - format: string + type: string url: - format: string + type: string html-url: - format: string + type: string repos-url: - format: string + type: string events-url: - format: string + type: string hooks-url: - format: string + type: string issues-url: - format: string + type: string members-url: - format: string + type: string public-members-url: - format: string + type: string avatar-url: - format: string + type: string description: - format: - - string - - "null" + type: string additionalProperties: false title: Organization - format: object + type: object installation: $schema: http://json-schema.org/draft-07/schema description: Installation @@ -630,15 +616,15 @@ EVENT_STAR_CREATED: properties: id: description: The ID of the installation. - format: integer + type: integer node-id: - format: string + type: string additionalProperties: false title: InstallationLite - format: object + type: object additionalProperties: false title: star created event - format: object + type: object messageExamples: - action: created starred-at: "2019-05-15T15:20:40Z" diff --git a/pkg/component/application/github/v0/config/setup.yaml b/pkg/component/application/github/v0/config/setup.yaml index 7dc5bb093..4e927286a 100644 --- a/pkg/component/application/github/v0/config/setup.yaml +++ b/pkg/component/application/github/v0/config/setup.yaml @@ -3,12 +3,10 @@ properties: token: description: Fill in your GitHub access token for advanced usages. For more information about how to create tokens, please refer to the github settings. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: Token - format: string required: - token instillOAuthConfig: @@ -18,4 +16,4 @@ instillOAuthConfig: - repo - admin:repo_hook title: GitHub Connection -format: object +type: object diff --git a/pkg/component/application/github/v0/config/tasks.yaml b/pkg/component/application/github/v0/config/tasks.yaml index 75351e952..5f7910732 100644 --- a/pkg/component/application/github/v0/config/tasks.yaml +++ b/pkg/component/application/github/v0/config/tasks.yaml @@ -6,12 +6,12 @@ $defs: description: SHA of the commit. uiOrder: 1 title: Commit SHA - format: string + type: string message: description: Message of the commit. uiOrder: 2 title: Commit message - format: string + type: string stats: uiOrder: 3 $ref: "#/$defs/commitStats" @@ -24,10 +24,10 @@ $defs: $ref: "#/$defs/commitFile" required: [] description: A file in the commit. - format: array + type: array required: [] title: Commit - format: object + type: object commitStats: description: Stats of changes. uiOrder: 1 @@ -36,20 +36,20 @@ $defs: description: Number of additions in the commit. uiOrder: 1 title: Additions - format: integer + type: integer deletions: description: Number of deletions in the commit. uiOrder: 2 title: Deletions - format: integer + type: integer changes: description: Total number of changes in the commit. uiOrder: 3 title: Total changes - format: integer + type: integer required: [] title: Commit stats - format: object + type: object commitFile: description: A commit file object. properties: @@ -57,16 +57,16 @@ $defs: description: Name of the file. uiOrder: 1 title: File name - format: string + type: string $ref: "#/$defs/commitStats/properties" patch: description: Patch of the file. uiOrder: 3 title: Patch - format: string + type: string required: [] title: Commit File - format: object + type: object issue: description: An issue object. properties: @@ -74,203 +74,278 @@ $defs: description: Number of the issue. uiOrder: 2 title: Issue Number - format: integer + type: integer state: description: State of the issue. uiOrder: 3 title: Issue state - format: string + type: string title: description: Title of the issue. uiOrder: 4 title: Issue title - format: string + type: string body: description: Body of the issue. uiOrder: 5 title: Issue body - format: string + type: string assignee: description: Assignee of the issue. uiOrder: 6 title: Assignee - format: string + type: string assignees: description: Assignees of the issue. uiOrder: 7 title: Assignees items: - format: string - format: array + type: string + type: array labels: description: Labels of the issue. uiOrder: 8 title: Labels items: - format: string - format: array + type: string + type: array is-pull-request: description: Whether the issue is a pull request. uiOrder: 9 title: Is Pull Request - format: boolean + type: boolean title: Issue - format: object + type: object organization: description: Organization Full properties: login: - format: string # type: string + description: The organization's username. + title: Login + type: string # type: string examples: [github] uiOrder: 0 id: - format: integer # type: integer + description: The unique identifier of the organization. + title: ID + type: integer # type: integer examples: [1] uiOrder: 1 node-id: - format: string # type: string + description: The GraphQL node ID of the organization. + title: Node ID + type: string # type: string examples: [MDEyOk9yZ2FuaXphdGlvbjE=] uiOrder: 2 url: - format: string # type: string, format: uri + description: The URL of the organization's API endpoint. + title: URL + type: string # type: string, format: uri examples: ["https://api.github.com/orgs/github"] uiOrder: 3 repos-url: - format: string # type: string, format: uri + description: The URL of the organization's repositories API endpoint. + title: Repositories URL + type: string # type: string, format: uri examples: ["https://api.github.com/orgs/github/repos"] uiOrder: 4 events-url: - format: string # type: string, format: uri + description: The URL of the organization's events API endpoint. + title: Events URL + type: string # type: string, format: uri examples: ["https://api.github.com/orgs/github/events"] uiOrder: 5 hooks-url: - format: string # type: string + description: The URL of the organization's webhooks API endpoint. + title: Hooks URL + type: string # type: string examples: ["https://api.github.com/orgs/github/hooks"] uiOrder: 6 issues-url: - format: string # type: string + description: The URL of the organization's issues API endpoint. + title: Issues URL + type: string # type: string examples: ["https://api.github.com/orgs/github/issues"] uiOrder: 7 members-url: - format: string # type: string + description: The URL of the organization's members API endpoint. + title: Members URL + type: string # type: string examples: ["https://api.github.com/orgs/github/members{/member}"] uiOrder: 8 public-members-url: - format: string # type: string + description: The URL of the organization's public members API endpoint. + title: Public Members URL + type: string # type: string examples: ["https://api.github.com/orgs/github/public_members{/member}"] uiOrder: 9 avatar-url: - format: string # type: string + description: The URL of the organization's avatar image. + title: Avatar URL + type: string # type: string examples: ["https://github.com/images/error/octocat_happy.gif"] uiOrder: 10 description: - format: string # type: [string, null] + description: The description of the organization. + title: Description + type: string # type: [string, null] examples: [A great organization] uiOrder: 11 name: - format: string # type: string + description: The display name of the organization. + title: Name + type: string # type: string examples: [github] uiOrder: 12 company: - format: string # type: string + description: The company name associated with the organization. + title: Company + type: string # type: string examples: [GitHub] uiOrder: 13 blog: - format: string # type: string, format: uri + description: The blog URL of the organization. + title: Blog + type: string # type: string, format: uri examples: ["https://github.com/blog"] uiOrder: 14 location: - format: string # type: string + description: The location of the organization. + title: Location + type: string # type: string examples: [San Francisco] uiOrder: 15 email: - format: string # type: string, format: email + description: The public email address of the organization. + title: Email + type: string # type: string, format: email examples: [octocat@github.com] uiOrder: 16 twitter-username: - format: string # type: [string, null] + description: The Twitter username of the organization. + title: Twitter Username + type: string # type: [string, null] examples: [github] uiOrder: 17 is-verified: - format: boolean # type: boolean + description: Whether the organization is verified by GitHub. + title: Is Verified + type: boolean # type: boolean examples: [true] uiOrder: 18 has-organization-projects: - format: boolean # type: boolean + description: Whether organization projects are enabled. + title: Has Organization Projects + type: boolean # type: boolean examples: [true] uiOrder: 19 has-repository-projects: - format: boolean # type: boolean + description: Whether repository projects are enabled. + title: Has Repository Projects + type: boolean # type: boolean examples: [true] uiOrder: 20 public-repos: - format: integer # type: integer + description: The number of public repositories. + title: Public Repositories + type: integer # type: integer examples: [2] uiOrder: 21 public-gists: - format: integer # type: integer + description: The number of public gists. + title: Public Gists + type: integer # type: integer examples: [1] uiOrder: 22 followers: - format: integer # type: integer + description: The number of followers. + title: Followers + type: integer # type: integer examples: [20] uiOrder: 23 following: - format: integer # type: integer + description: The number of users the organization is following. + title: Following + type: integer # type: integer examples: [0] uiOrder: 24 html-url: - format: string # type: string, format: uri + description: The URL of the organization's GitHub homepage. + title: HTML URL + type: string # type: string, format: uri examples: ["https://github.com/octocat"] uiOrder: 25 type: - format: string # type: string + description: The type of the account. + title: Type + type: string # type: string examples: [Organization] uiOrder: 26 total-private-repos: - format: integer # type: integer + description: The total number of private repositories. + title: Total Private Repositories + type: integer # type: integer examples: [100] uiOrder: 27 owned-private-repos: - format: integer # type: integer + description: The number of private repositories owned by the organization. + title: Owned Private Repositories + type: integer # type: integer examples: [100] uiOrder: 28 private-gists: - format: integer # type: [integer, null] + description: The number of private gists. + title: Private Gists + type: integer # type: [integer, null] examples: [81] uiOrder: 29 disk-usage: - format: integer # type: [integer, null] + description: The amount of disk space used by the organization. + title: Disk Usage + type: integer # type: [integer, null] examples: [10000] uiOrder: 30 collaborators: - format: integer # type: [integer, null] - description: > - The number of collaborators on private repositories. - This field may be null if the number of private repositories is over 50,000. + description: The number of collaborators on private repositories. + title: Collaborators + type: integer # type: [integer, null] examples: [8] uiOrder: 31 billing-email: - format: string # type: [string, null], format: email + description: The billing email address for the organization. + title: Billing Email + type: string # type: [string, null], format: email examples: [org@example.com] uiOrder: 32 plan: - format: object # type: object + description: The organization's plan details. + title: Plan + type: object # type: object properties: name: - format: string # type: string + description: The name of the plan. + title: Name + type: string # type: string uiOrder: 0 space: - format: integer # type: integer + description: The amount of disk space included in the plan. + title: Space + type: integer # type: integer uiOrder: 1 private-repos: - format: integer # type: integer + description: The number of private repositories included in the plan. + title: Private Repositories + type: integer # type: integer uiOrder: 2 filled-seats: - format: integer # type: integer + description: The number of filled seats in the plan. + title: Filled Seats + type: integer # type: integer uiOrder: 3 seats: - format: integer # type: integer + description: The total number of seats in the plan. + title: Seats + type: integer # type: integer uiOrder: 4 required: - name @@ -278,129 +353,150 @@ $defs: - private-repos uiOrder: 33 default-repository-permission: - format: string # type: [string, null] + description: The default repository permission level for organization members. + title: Default Repository Permission + type: string # type: [string, null] uiOrder: 34 members-can-create-repositories: - format: boolean # type: [boolean, null] + description: Whether organization members can create repositories. + title: Members Can Create Repositories + type: boolean # type: [boolean, null] examples: [true] uiOrder: 35 two-factor-requirement-enabled: - format: boolean # type: [boolean, null] + description: Whether two-factor authentication is required for all members. + title: Two Factor Requirement Enabled + type: boolean # type: [boolean, null] examples: [true] uiOrder: 36 members-allowed-repository-creation-type: - format: string # type: string + description: The type of repositories members are allowed to create. + title: Members Allowed Repository Creation Type + type: string # type: string examples: [all] uiOrder: 37 members-can-create-public-repositories: - format: boolean # type: boolean + description: Whether members can create public repositories. + title: Members Can Create Public Repositories + type: boolean # type: boolean examples: [true] uiOrder: 38 members-can-create-private-repositories: - format: boolean # type: boolean + description: Whether members can create private repositories. + title: Members Can Create Private Repositories + type: boolean # type: boolean examples: [true] uiOrder: 39 members-can-create-internal-repositories: - format: boolean # type: boolean + description: Whether members can create internal repositories. + title: Members Can Create Internal Repositories + type: boolean # type: boolean examples: [true] uiOrder: 40 members-can-create-pages: - format: boolean # type: boolean + description: Whether members can create GitHub Pages sites. + title: Members Can Create Pages + type: boolean # type: boolean examples: [true] uiOrder: 41 members-can-create-public-pages: - format: boolean # type: boolean + description: Whether members can create public GitHub Pages sites. + title: Members Can Create Public Pages + type: boolean # type: boolean examples: [true] uiOrder: 42 members-can-create-private-pages: - format: boolean # type: boolean + description: Whether members can create private GitHub Pages sites. + title: Members Can Create Private Pages + type: boolean # type: boolean examples: [true] uiOrder: 43 members-can-fork-private-repositories: - format: boolean # type: [boolean, null] + description: Whether members can fork private repositories. + title: Members Can Fork Private Repositories + type: boolean # type: [boolean, null] examples: [false] uiOrder: 44 web-commit-signoff-required: - format: boolean # type: boolean + description: Whether web commit sign-off is required. + title: Web Commit Signoff Required + type: boolean # type: boolean examples: [false] uiOrder: 45 advanced-security-enabled-for-new-repositories: - format: boolean # type: boolean - description: > - **Endpoint closing down notice.** Please use [code security configurations](https://docs.github.com/rest/code-security/configurations) instead. - Whether GitHub Advanced Security is enabled for new repositories and repositories transferred to this organization. - This field is only visible to organization owners or members of a team with the security manager role. - examples: [false] + description: Whether GitHub Advanced Security is enabled for new repositories. + title: Advanced Security Enabled For New Repositories + type: boolean # type: boolean deprecated: true + examples: [false] uiOrder: 46 dependabot-alerts-enabled-for-new-repositories: - format: boolean # type: boolean - description: > - **Endpoint closing down notice.** Please use [code security configurations](https://docs.github.com/rest/code-security/configurations) instead. - Whether Dependabot alerts are automatically enabled for new repositories and repositories transferred to this organization. - This field is only visible to organization owners or members of a team with the security manager role. - examples: [false] + description: Whether Dependabot alerts are enabled for new repositories. + title: Dependabot Alerts Enabled For New Repositories + type: boolean # type: boolean deprecated: true + examples: [false] uiOrder: 47 dependabot-security-updates-enabled-for-new-repositories: - format: boolean # type: boolean - description: > - **Endpoint closing down notice.** Please use [code security configurations](https://docs.github.com/rest/code-security/configurations) instead. - Whether Dependabot security updates are automatically enabled for new repositories and repositories transferred to this organization. - This field is only visible to organization owners or members of a team with the security manager role. - examples: [false] + description: Whether Dependabot security updates are enabled for new repositories. + title: Dependabot Security Updates Enabled For New Repositories + type: boolean # type: boolean deprecated: true + examples: [false] uiOrder: 48 dependency-graph-enabled-for-new-repositories: - format: boolean # type: boolean - description: > - **Endpoint closing down notice.** Please use [code security configurations](https://docs.github.com/rest/code-security/configurations) instead. - Whether dependency graph is automatically enabled for new repositories and repositories transferred to this organization. - This field is only visible to organization owners or members of a team with the security manager role. - examples: [false] + description: Whether dependency graph is enabled for new repositories. + title: Dependency Graph Enabled For New Repositories + type: boolean # type: boolean deprecated: true + examples: [false] uiOrder: 49 secret-scanning-enabled-for-new-repositories: - format: boolean # type: boolean - description: > - **Endpoint closing down notice.** Please use [code security configurations](https://docs.github.com/rest/code-security/configurations) instead. - Whether secret scanning is automatically enabled for new repositories and repositories transferred to this organization. - This field is only visible to organization owners or members of a team with the security manager role. - examples: [false] + description: Whether secret scanning is enabled for new repositories. + title: Secret Scanning Enabled For New Repositories + type: boolean # type: boolean deprecated: true + examples: [false] uiOrder: 50 secret-scanning-push-protection-enabled-for-new-repositories: - format: boolean # type: boolean - description: > - **Endpoint closing down notice.** Please use [code security configurations](https://docs.github.com/rest/code-security/configurations) instead. - Whether secret scanning push protection is automatically enabled for new repositories and repositories transferred to this organization. - This field is only visible to organization owners or members of a team with the security manager role. - examples: [false] + description: Whether secret scanning push protection is enabled for new repositories. + title: Secret Scanning Push Protection Enabled For New Repositories + type: boolean # type: boolean deprecated: true + examples: [false] uiOrder: 51 secret-scanning-push-protection-custom-link-enabled: - format: boolean # type: boolean description: Whether a custom link is shown to contributors who are blocked from pushing a secret by push protection. + title: Secret Scanning Push Protection Custom Link Enabled + type: boolean # type: boolean examples: [false] uiOrder: 52 secret-scanning-push-protection-custom-link: - format: string # type: [string, null] description: An optional URL string to display to contributors who are blocked from pushing a secret. + title: Secret Scanning Push Protection Custom Link + type: string # type: [string, null] examples: ["https://github.com/test-org/test-repo/blob/main/README.md"] uiOrder: 53 created-at: - format: string # type: string, format: date-time + description: The timestamp when the organization was created. + title: Created At + type: string # type: string, format: date-time examples: ["2008-01-14T04:33:35Z"] uiOrder: 54 updated-at: - format: string # type: string, format: date-time + description: The timestamp when the organization was last updated. + title: Updated At + type: string # type: string, format: date-time uiOrder: 55 archived-at: - format: string # type: [string, null], format: date-time + description: The timestamp when the organization was archived, if applicable. + title: Archived At + type: string # type: [string, null], format: date-time uiOrder: 56 deploy-keys-enabled-for-repositories: - format: boolean # type: boolean description: Controls whether or not deploy keys may be added and used for repositories in the organization. + title: Deploy Keys Enabled For Repositories + type: boolean # type: boolean examples: [false] uiOrder: 57 required: @@ -428,7 +524,7 @@ $defs: - updated-at - archived-at title: Organization Full - format: object # type: object + type: object # type: object pageOptions: title: Page Options description: Options for listing pages. @@ -438,18 +534,14 @@ $defs: description: Page number of the results to fetch. Default is 1. uiOrder: 100 title: Page - acceptFormats: - - integer - format: integer + type: integer per-page: default: 30 description: Number of results to fetch per page. Default is 30. uiOrder: 101 title: Per Page - acceptFormats: - - integer - format: integer - format: object + type: integer + type: object pullRequest: description: A pull request object. properties: @@ -457,57 +549,57 @@ $defs: description: ID of the PR. uiOrder: 1 title: PR id - format: integer + type: integer number: description: Number of the PR. uiOrder: 2 title: PR number - format: integer + type: integer state: description: State of the PR. uiOrder: 3 title: PR state - format: string + type: string title: description: Title of the PR. uiOrder: 4 title: PR Title - format: string + type: string body: description: Body of the PR. uiOrder: 5 title: PR body - format: string + type: string diff-url: description: URL to the diff of the PR. uiOrder: 6 title: PR diff url - format: string + type: string head: description: Head commit of the PR (in SHA value). uiOrder: 8 title: PR head - format: string + type: string base: description: Base commit of the PR (in SHA value). uiOrder: 9 title: PR base - format: string + type: string comments-num: description: Number of comments on the PR. uiOrder: 10 title: Number of PR comments - format: integer + type: integer commits-num: description: Number of commits in the PR. uiOrder: 11 title: Number of PR commits - format: integer + type: integer review-comments-num: description: Number of review comments in the PR. uiOrder: 12 title: Number of PR review comments - format: integer + type: integer commits: description: Commits in the PR. uiOrder: 13 @@ -516,25 +608,21 @@ $defs: $ref: "#/$defs/commit" required: [] description: A commit in the PR. - format: array + type: array required: [] title: Pull Request - format: object + type: object repositoryInfo: owner: description: Owner of the repository. uiOrder: 0 - acceptFormats: - - string + type: string title: Owner - format: string repository: description: Repository name. uiOrder: 1 - acceptFormats: - - string + type: string title: Repository - format: string reviewComments: description: A review comment object. properties: @@ -542,39 +630,39 @@ $defs: description: ID of the comment. uiOrder: 1 title: Comment id - format: integer + type: integer in-reply-to-id: description: ID of the comment this comment is in reply to. uiOrder: 2 title: In Reply To - format: integer + type: integer commit-id: description: SHA of the commit on which you want to comment. uiOrder: 3 title: Commit SHA - format: string + type: string body: description: Body of the comment. uiOrder: 4 title: Comment body - format: string + type: string path: description: Path of the file the comment is on. uiOrder: 5 title: Comment path - format: string + type: string line: shortDescription: The last line of the range that your comment applies to. Your comment will be placed under this line. description: The line of the blob in the pull request diff that the comment applies to. For a multi-line comment, the last line of the range that your comment applies to. uiOrder: 6 title: Comment end line - format: integer + type: integer start-line: description: The first line in the pull request diff that your multi-line comment applies to. Only multi-line comment needs to fill this field. uiOrder: 7 title: Comment start line - format: integer + type: integer side: shortDescription: "Side of the end line, can be one of: LEFT, RIGHT, side. Default is side." description: "Side of the end line, can be one of: LEFT, RIGHT, side. LEFT is the left side of the diff (deletion), RIGHT is the right side of the\ @@ -586,7 +674,7 @@ $defs: - side uiOrder: 8 title: Comment end side - format: string + type: string start-side: shortDescription: "Side of the start line, can be one of: LEFT, RIGHT, side. Default is side." description: "Side of the start line, can be one of: LEFT, RIGHT, side. LEFT is the left side of the diff (deletion), RIGHT is the right side of\ @@ -598,7 +686,7 @@ $defs: - side uiOrder: 9 title: Comment start side - format: string + type: string subject-type: description: "Subject type of the comment, can be one of: line, file. Default is line." uiOrder: 10 @@ -607,17 +695,17 @@ $defs: enum: - line - file - format: string + type: string created-at: description: Time the comment was created. uiOrder: 11 title: Comment created at - format: string + type: string updated-at: description: Time the comment was updated. uiOrder: 12 title: Comment updated at - format: string + type: string user: description: User who created the comment. uiOrder: 13 @@ -627,193 +715,283 @@ $defs: description: ID of the user. uiOrder: 14 title: User id - format: integer + type: integer url: description: URL of the user. uiOrder: 15 title: User URL - format: string + type: string required: [] - format: object + type: object title: Review Comment - format: object + type: object user: oneOf: - title: Private User description: Private User - format: object # type: object + type: object # type: object properties: login: - format: string # type: string + type: string # type: string + title: Username + description: The user's username/login examples: [octocat] uiOrder: 0 id: - format: integer # type: integer, format: int64 + type: integer # type: integer, format: int64 + title: User ID + description: The unique identifier of the user examples: [1] uiOrder: 1 user_view_type: - format: string # type: string + type: string # type: string + title: User View Type + description: The type of view for this user uiOrder: 2 node_id: - format: string # type: string + type: string # type: string + title: Node ID + description: The GraphQL node ID of the user examples: [MDQ6VXNlcjE=] uiOrder: 3 avatar_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Avatar URL + description: URL of the user's avatar image examples: ["https://github.com/images/error/octocat_happy.gif"] uiOrder: 4 gravatar_id: - format: string # type: [string, null] + type: string # type: [string, null] + title: Gravatar ID + description: The user's Gravatar ID examples: [41d064eb2195891e12d0413f63227ea7] uiOrder: 5 url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: API URL + description: The URL to the user's GitHub API endpoint examples: ["https://api.github.com/users/octocat"] uiOrder: 6 html_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Profile URL + description: The URL to the user's GitHub profile examples: ["https://github.com/octocat"] uiOrder: 7 followers_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Followers URL + description: The URL to the user's followers list examples: ["https://api.github.com/users/octocat/followers"] uiOrder: 8 following_url: - format: string # type: string + type: string # type: string + title: Following URL + description: The URL to the user's following list examples: ["https://api.github.com/users/octocat/following{/other_user}"] uiOrder: 9 gists_url: - format: string # type: string + type: string # type: string + title: Gists URL + description: The URL to the user's gists examples: ["https://api.github.com/users/octocat/gists{/gist_id}"] uiOrder: 10 starred_url: - format: string # type: string + type: string # type: string + title: Starred URL + description: The URL to the user's starred repositories examples: ["https://api.github.com/users/octocat/starred{/owner}{/repo}"] uiOrder: 11 subscriptions_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Subscriptions URL + description: The URL to the user's repository subscriptions examples: ["https://api.github.com/users/octocat/subscriptions"] uiOrder: 12 organizations_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Organizations URL + description: The URL to the user's organizations examples: ["https://api.github.com/users/octocat/orgs"] uiOrder: 13 repos_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Repositories URL + description: The URL to the user's repositories examples: ["https://api.github.com/users/octocat/repos"] uiOrder: 14 events_url: - format: string # type: string + type: string # type: string + title: Events URL + description: The URL to the user's events examples: ["https://api.github.com/users/octocat/events{/privacy}"] uiOrder: 15 received_events_url: - format: string # type: string, format: uri + type: string # type: string, type: uri + title: Received Events URL + description: The URL to events received by the user examples: ["https://api.github.com/users/octocat/received_events"] uiOrder: 16 type: - format: string # type: string + type: string # type: string + title: User Type + description: The type of GitHub user account examples: [User] uiOrder: 17 site_admin: - format: boolean # type: boolean + type: boolean # type: boolean + title: Site Admin + description: Whether the user is a GitHub site admin uiOrder: 18 name: - format: string # type: [string, null] + type: string # type: [string, null] + title: Full Name + description: The user's full name examples: [monalisa octocat] uiOrder: 19 company: - format: string # type: [string, null] + type: string # type: [string, null] + title: Company + description: The user's company or organization examples: [GitHub] uiOrder: 20 blog: - format: string # type: [string, null] + type: string # type: [string, null] + title: Blog URL + description: The URL to the user's blog examples: ["https://github.com/blog"] uiOrder: 21 location: - format: string # type: [string, null] + type: string # type: [string, null] + title: Location + description: The user's geographical location examples: [San Francisco] uiOrder: 22 email: - format: string # type: [string, null], format: email + type: string # type: [string, null], format: email + title: Email + description: The user's primary email address examples: [octocat@github.com] uiOrder: 23 notification_email: - format: string # type: [string, null], format: email + type: string # type: [string, null], format: email + title: Notification Email + description: The email address used for notifications examples: [octocat@github.com] uiOrder: 24 hireable: - format: boolean # type: [boolean, null] + type: boolean # type: [boolean, null] + title: Hireable Status + description: Whether the user is available for hire uiOrder: 25 bio: - format: string # type: [string, null] + type: string # type: [string, null] + title: Biography + description: The user's biography or profile description examples: [There once was...] uiOrder: 26 twitter_username: - format: string # type: [string, null] + type: string # type: [string, null] + title: Twitter Username + description: The user's Twitter username examples: [monalisa] uiOrder: 27 public_repos: - format: integer # type: integer + type: integer # type: integer + title: Public Repositories + description: Number of public repositories owned by the user examples: [2] uiOrder: 28 public_gists: - format: integer # type: integer + type: integer # type: integer + title: Public Gists + description: Number of public gists owned by the user examples: [1] uiOrder: 29 followers: - format: integer # type: integer + type: integer # type: integer + title: Followers Count + description: Number of users following this user examples: [20] uiOrder: 30 following: - format: integer # type: integer + type: integer # type: integer + title: Following Count + description: Number of users this user is following examples: [0] uiOrder: 31 created_at: - format: string # type: string, format: date-time + type: string # type: string, format: date-time + title: Account Created At + description: Timestamp when the user account was created examples: ["2008-01-14T04:33:35Z"] uiOrder: 32 updated_at: - format: string # type: string, format: date-time + type: string # type: string, format: date-time + title: Account Updated At + description: Timestamp when the user account was last updated examples: ["2008-01-14T04:33:35Z"] uiOrder: 33 private_gists: - format: integer # type: integer + type: integer # type: integer + title: Private Gists + description: Number of private gists owned by the user examples: [81] uiOrder: 34 total_private_repos: - format: integer # type: integer + type: integer # type: integer + title: Total Private Repositories + description: Total number of private repositories examples: [100] uiOrder: 35 owned_private_repos: - format: integer # type: integer + type: integer # type: integer + title: Owned Private Repositories + description: Number of private repositories owned by the user examples: [100] uiOrder: 36 disk_usage: - format: integer # type: integer + type: integer # type: integer + title: Disk Usage + description: Amount of disk space used by the user's repositories examples: [10000] uiOrder: 37 collaborators: - format: integer # type: integer + type: integer # type: integer + title: Collaborators + description: Number of collaborators across all repositories examples: [8] uiOrder: 38 two_factor_authentication: - format: boolean # type: boolean + type: boolean # type: boolean + title: Two Factor Authentication + description: Whether two-factor authentication is enabled examples: [true] uiOrder: 39 plan: - format: object # type: object + type: object # type: object + title: GitHub Plan + description: The user's GitHub plan details properties: collaborators: - format: integer # type: integer + type: integer # type: integer + title: Plan Collaborators + description: Number of collaborators allowed under the plan uiOrder: 0 name: - format: string # type: string + type: string # type: string + title: Plan Name + description: Name of the GitHub plan uiOrder: 1 space: - format: integer # type: integer + type: integer # type: integer + title: Plan Space + description: Amount of space included in the plan uiOrder: 2 private_repos: - format: integer # type: integer + type: integer # type: integer + title: Plan Private Repositories + description: Number of private repositories allowed under the plan uiOrder: 3 required: - collaborators @@ -822,10 +1000,14 @@ $defs: - private_repos uiOrder: 40 business_plus: - format: boolean # type: boolean + type: boolean # type: boolean + title: Business Plus + description: Whether the user has GitHub Business Plus uiOrder: 41 ldap_dn: - format: string # type: string + type: string # type: string + title: LDAP DN + description: The user's LDAP Distinguished Name uiOrder: 42 required: - avatar_url @@ -867,124 +1049,202 @@ $defs: - two_factor_authentication - title: Public User description: Public User - format: object # type: object + type: object # type: object properties: login: - format: string # type: string + type: string # type: string + title: Username + description: The user's username/login uiOrder: 0 id: - format: integer # type: integer, format: int64 + type: integer # type: integer, format: int64 + title: User ID + description: The unique identifier of the user uiOrder: 1 user_view_type: - format: string # type: string + type: string # type: string + title: User View Type + description: The type of view for this user uiOrder: 2 node_id: - format: string # type: string + type: string # type: string + title: Node ID + description: The GraphQL node ID of the user uiOrder: 3 avatar_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Avatar URL + description: URL of the user's avatar image uiOrder: 4 gravatar_id: - format: string # type: [string, null] + type: string # type: [string, null] + title: Gravatar ID + description: The user's Gravatar ID uiOrder: 5 url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: API URL + description: The URL to the user's GitHub API endpoint uiOrder: 6 html_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Profile URL + description: The URL to the user's GitHub profile uiOrder: 7 followers_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Followers URL + description: The URL to get the user's followers uiOrder: 8 following_url: - format: string # type: string + type: string # type: string + title: Following URL + description: The URL to get who the user is following uiOrder: 9 gists_url: - format: string # type: string + type: string # type: string + title: Gists URL + description: The URL to get the user's gists uiOrder: 10 starred_url: - format: string # type: string + type: string # type: string + title: Starred URL + description: The URL to get the user's starred repositories uiOrder: 11 subscriptions_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Subscriptions URL + description: The URL to get the user's subscriptions uiOrder: 12 organizations_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Organizations URL + description: The URL to get the user's organizations uiOrder: 13 repos_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Repositories URL + description: The URL to get the user's repositories uiOrder: 14 events_url: - format: string # type: string + type: string # type: string + title: Events URL + description: The URL to get the user's events uiOrder: 15 received_events_url: - format: string # type: string, format: uri + type: string # type: string, format: uri + title: Received Events URL + description: The URL to get events received by the user uiOrder: 16 type: - format: string # type: string + type: string # type: string + title: User Type + description: The type of user account uiOrder: 17 site_admin: - format: boolean # type: boolean + type: boolean # type: boolean + title: Site Admin + description: Whether the user is a GitHub site admin uiOrder: 18 name: - format: string # type: [string, null] + type: string # type: [string, null] + title: Name + description: The user's full name uiOrder: 19 company: - format: string # type: [string, null] + type: string # type: [string, null] + title: Company + description: The user's company uiOrder: 20 blog: - format: string # type: [string, null] + type: string # type: [string, null] + title: Blog + description: The user's blog URL uiOrder: 21 location: - format: string # type: [string, null] + type: string # type: [string, null] + title: Location + description: The user's location uiOrder: 22 email: - format: string # type: [string, null], format: email + type: string # type: [string, null], format: email + title: Email + description: The user's email address uiOrder: 23 notification_email: - format: string # type: [string, null], format: email + type: string # type: [string, null], format: email + title: Notification Email + description: The user's notification email address uiOrder: 24 hireable: - format: boolean # type: [boolean, null] + type: boolean # type: [boolean, null] + title: Hireable + description: Whether the user is available for hire uiOrder: 25 bio: - format: string # type: [string, null] + type: string # type: [string, null] + title: Bio + description: The user's biography uiOrder: 26 twitter_username: - format: string # type: [string, null] + type: string # type: [string, null] + title: Twitter Username + description: The user's Twitter username uiOrder: 27 public_repos: - format: integer # type: integer + type: integer # type: integer + title: Public Repositories + description: Number of public repositories uiOrder: 28 public_gists: - format: integer # type: integer + type: integer # type: integer + title: Public Gists + description: Number of public gists uiOrder: 29 followers: - format: integer # type: integer + type: integer # type: integer + title: Followers + description: Number of followers uiOrder: 30 following: - format: integer # type: integer + type: integer # type: integer + title: Following + description: Number of users being followed uiOrder: 31 created_at: - format: string # type: string, format: date-time + type: string # type: string, format: date-time + title: Created At + description: When the user account was created uiOrder: 32 updated_at: - format: string # type: string, format: date-time + type: string # type: string, format: date-time + title: Updated At + description: When the user account was last updated uiOrder: 33 plan: - format: object # type: object + type: object # type: object + title: Plan + description: The user's GitHub plan properties: collaborators: - format: integer # type: integer + type: integer # type: integer + title: Collaborators + description: Number of collaborators allowed uiOrder: 0 name: - format: string # type: string + type: string # type: string + title: Plan Name + description: Name of the GitHub plan uiOrder: 1 space: - format: integer # type: integer + type: integer # type: integer + title: Space + description: Space allowed in the plan uiOrder: 2 private_repos: - format: integer # type: integer + type: integer # type: integer + title: Private Repositories + description: Number of private repositories allowed uiOrder: 3 required: - collaborators @@ -993,23 +1253,33 @@ $defs: - private_repos uiOrder: 34 private_gists: - format: integer # type: integer + type: integer # type: integer + title: Private Gists + description: Number of private gists examples: [1] uiOrder: 35 total_private_repos: - format: integer # type: integer + type: integer # type: integer + title: Total Private Repositories + description: Total number of private repositories examples: [2] uiOrder: 36 owned_private_repos: - format: integer # type: integer + type: integer # type: integer + title: Owned Private Repositories + description: Number of private repositories owned examples: [2] uiOrder: 37 disk_usage: - format: integer # type: integer + type: integer # type: integer + title: Disk Usage + description: Amount of disk space used examples: [1] uiOrder: 38 collaborators: - format: integer # type: integer + type: integer # type: integer + title: Collaborators + description: Number of collaborators examples: [3] uiOrder: 39 required: @@ -1054,28 +1324,24 @@ TASK_CREATE_ISSUE: $ref: "#/$defs/repositoryInfo" title: $ref: "#/$defs/issue/properties/title" - acceptFormats: - - string + type: string uiOrder: 3 body: $ref: "#/$defs/issue/properties/body" - acceptFormats: - - string + type: string uiOrder: 4 assignees: $ref: "#/$defs/issue/properties/assignees" - acceptFormats: - - array + type: array items: - format: string + type: string title: Assignees uiOrder: 5 labels: $ref: "#/$defs/issue/properties/labels" - acceptFormats: - - array + type: array items: - format: string + type: string title: Labels uiOrder: 6 required: @@ -1084,7 +1350,7 @@ TASK_CREATE_ISSUE: - title - body title: Input - format: object + type: object output: description: The created issue. uiOrder: 0 @@ -1092,7 +1358,7 @@ TASK_CREATE_ISSUE: $ref: "#/$defs/issue/properties" required: [] title: Output - format: object + type: object TASK_CREATE_REVIEW_COMMENT: shortDescription: Create a review comment in pull request. description: Create a review comment in a pull request. The comment can be a general comment or a review comment. The comment can be on a specific line @@ -1105,10 +1371,8 @@ TASK_CREATE_REVIEW_COMMENT: pr-number: title: PR Number description: Number of the PR. - acceptFormats: - - integer + type: integer uiOrder: 3 - format: integer comment: title: Comment description: The comment to be added. @@ -1116,56 +1380,40 @@ TASK_CREATE_REVIEW_COMMENT: properties: commit-id: $ref: "#/$defs/reviewComments/properties/commit-id" - acceptFormats: - - string uiOrder: 0 body: $ref: "#/$defs/reviewComments/properties/body" - acceptFormats: - - string uiOrder: 1 path: $ref: "#/$defs/reviewComments/properties/path" - acceptFormats: - - string uiOrder: 2 start-line: $ref: "#/$defs/reviewComments/properties/start-line" - acceptFormats: - - integer uiOrder: 3 line: $ref: "#/$defs/reviewComments/properties/line" - acceptFormats: - - integer uiOrder: 4 start-side: $ref: "#/$defs/reviewComments/properties/start-side" - acceptFormats: - - string uiOrder: 5 side: $ref: "#/$defs/reviewComments/properties/side" - acceptFormats: - - string uiOrder: 6 subject-type: $ref: "#/$defs/reviewComments/properties/subject-type" - acceptFormats: - - string uiOrder: 7 required: - body - path - commit-id - format: object + type: object required: - owner - repository - pr-number - comment title: Input - format: object + type: object output: description: The created comment. uiOrder: 0 @@ -1173,7 +1421,7 @@ TASK_CREATE_REVIEW_COMMENT: $ref: "#/$defs/reviewComments/properties" required: [] title: Output - format: object + type: object TASK_CREATE_WEBHOOK: description: Create a webhook for a repository. input: @@ -1184,30 +1432,22 @@ TASK_CREATE_WEBHOOK: hook-url: title: Webhook URL description: URL to send the payload to. - acceptFormats: - - string + type: string uiOrder: 3 - format: string events: title: Events description: Events to trigger the webhook. Please see the github document for more information. - acceptFormats: - - array + type: array uiOrder: 4 items: - acceptFormats: - - string - format: string - format: array + type: string active: title: Active default: false description: Whether the webhook is active. Default is false. - acceptFormats: - - boolean + type: boolean uiOrder: 5 - format: boolean content-type: default: json title: Content Type @@ -1215,26 +1455,22 @@ TASK_CREATE_WEBHOOK: enum: - json - form - acceptFormats: - - string + type: string uiOrder: 6 - format: string hook-secret: title: Hook Secret description: If provided, the secret will be used as the key to generate the HMAC hex digest value for delivery signature headers. (see the document). instillSecret: true - acceptFormats: - - string + type: string uiOrder: 7 - format: string required: - owner - repository - hook-url - events title: Input - format: object + type: object output: description: The created webhook. uiOrder: 0 @@ -1243,22 +1479,22 @@ TASK_CREATE_WEBHOOK: description: ID of the webhook. uiOrder: 1 title: Webhook ID - format: integer + type: integer url: description: URL of the webhook. uiOrder: 2 title: Webhook URL - format: string + type: string ping-url: description: URL to ping the webhook. uiOrder: 3 title: Ping URL - format: string + type: string test-url: description: URL to test the webhook. uiOrder: 4 title: Test URL - format: string + type: string config: description: Configuration of the webhook. uiOrder: 6 @@ -1268,22 +1504,22 @@ TASK_CREATE_WEBHOOK: description: URL of the webhook. uiOrder: 1 title: Webhook URL - format: string + type: string content-type: description: Content type of the webhook. uiOrder: 2 title: Content Type - format: string + type: string insecure-ssl: description: Whether the webhook is insecure. uiOrder: 3 title: Insecure SSL - format: string + type: string required: [] - format: object + type: object required: [] title: Output - format: object + type: object TASK_GET_COMMIT: shortDescription: Get a commit from a repository, given the commit SHA input: @@ -1293,15 +1529,14 @@ TASK_GET_COMMIT: $ref: "#/$defs/repositoryInfo" sha: $ref: "#/$defs/commit/properties/sha" - acceptFormats: - - string + type: string uiOrder: 3 required: - owner - repository - sha title: Input - format: object + type: object output: description: The specific commit in GitHub repository. uiOrder: 0 @@ -1309,7 +1544,7 @@ TASK_GET_COMMIT: $ref: "#/$defs/commit/properties" required: [] title: Output - format: object + type: object TASK_GET_ISSUE: description: Get an issue. This can be a pull request or a general issue, and you can tell by the `is-pull-request` field. shortDescription: Get an issue. @@ -1322,16 +1557,14 @@ TASK_GET_ISSUE: default: 0 title: Issue Number description: Number of the issue. - acceptFormats: - - integer + type: integer uiOrder: 4 - format: integer required: - owner - repository - issue-number title: Input - format: object + type: object output: description: The specific issue in GitHub repository. uiOrder: 0 @@ -1339,47 +1572,35 @@ TASK_GET_ISSUE: $ref: "#/$defs/issue/properties" required: [] title: Output - format: object + type: object TASK_GET_ORGANIZATION: description: Get an organization by name or ID. shortDescription: Get an organization by name or ID. input: description: Please input either the organization name or organization ID. - editOnNodeFields: - - name - - id properties: name: title: Name description: The GitHub organization name. - format: string - acceptFormats: - - string - upstreamTypes: - - value - - reference + type: string uiOrder: 0 id: title: ID description: The GitHub organization ID. If both `name` and `id` are provided, `id` takes precedence. - format: integer - acceptFormats: - - integer - upstreamTypes: - - value - - reference + type: integer uiOrder: 1 required: [] title: Input - format: object + type: object output: description: The GitHub organization information. properties: organization: $ref: "#/$defs/organization" + uiOrder: 0 required: [] title: Output - format: object + type: object TASK_GET_PULL_REQUEST: shortDescription: Get a pull request from a repository, given the PR number. This will default to the latest PR if no PR number is provided. input: @@ -1391,62 +1612,50 @@ TASK_GET_PULL_REQUEST: default: 0 title: PR Number description: Number of the PR. `0` for the latest PR. - acceptFormats: - - integer + type: integer uiOrder: 4 - format: integer required: - owner - repository title: Input - format: object + type: object output: description: The specific pr in GitHub repository. uiOrder: 0 $ref: "#/$defs/pullRequest" required: [] title: Output - format: object + type: object TASK_GET_USER: description: Get a user by name or ID. shortDescription: Get a user by name or ID. input: description: Please input either the username or user ID. - editOnNodeFields: - - name - - id properties: name: title: Name description: The GitHub username of the user. - format: string - acceptFormats: - - string - upstreamTypes: - - value - - reference + type: string uiOrder: 0 id: title: ID description: The GitHub user ID. If both `name` and `id` are provided, `id` takes precedence. - format: integer - acceptFormats: - - integer - upstreamTypes: - - value - - reference + type: integer uiOrder: 1 required: [] title: Input - format: object + type: object output: description: The GitHub user information. properties: user: $ref: "#/$defs/user" + title: User + description: The GitHub user information. + uiOrder: 0 required: [] title: Output - format: object + type: object TASK_LIST_ISSUES: description: Get the list of all issues in a repository,This can be a pull request or a general issue, and you can tell by the `is-pull-request` field. shortDescription: Get the list of all issues in a repository @@ -1463,10 +1672,8 @@ TASK_LIST_ISSUES: - open - closed - all - acceptFormats: - - string + type: string uiOrder: 10 - format: string sort: default: created title: Sort @@ -1476,10 +1683,8 @@ TASK_LIST_ISSUES: - updated - popularity - long-running - acceptFormats: - - string + type: string uiOrder: 11 - format: string direction: default: desc title: Direction @@ -1487,47 +1692,37 @@ TASK_LIST_ISSUES: enum: - asc - desc - acceptFormats: - - string + type: string uiOrder: 12 - format: string since: default: "2021-01-01" title: Since description: Date (in `YYYY-MM-DD` format) from which issues will start to be fetched. The date will be in the UTC timezone. - acceptFormats: - - string + type: string uiOrder: 13 - format: string no-pull-request: title: No Pull Request description: Whether to `not` include pull requests in the response. Since issue and pr use the same indexing system in GitHub, the API returns all relevant objects (issues and pr). Default is false. - acceptFormats: - - boolean + type: boolean uiOrder: 14 - format: boolean page: default: 1 description: Page number of the results to fetch. Default is 1. uiOrder: 100 title: Page - acceptFormats: - - integer - format: integer + type: integer per-page: default: 30 description: Number of results to fetch per page. Default is 30. uiOrder: 101 title: Per Page - acceptFormats: - - integer - format: integer + type: integer required: - owner - repository title: Input - format: object + type: object output: description: All issues in GitHub repository. uiOrder: 0 @@ -1540,11 +1735,11 @@ TASK_LIST_ISSUES: $ref: "#/$defs/issue" required: [] description: An issue in GitHub. - format: array + type: array required: - issues title: Output - format: object + type: object TASK_LIST_PULL_REQUESTS: shortDescription: Get the list of all pull requests in a repository description: Get the list of all pull requests in a repository. Detailed information about each commit in a PR is omitted, please use the `Get Commit` @@ -1562,10 +1757,8 @@ TASK_LIST_PULL_REQUESTS: - open - closed - all - acceptFormats: - - string + type: string uiOrder: 10 - format: string sort: default: created title: Sort @@ -1575,10 +1768,8 @@ TASK_LIST_PULL_REQUESTS: - updated - popularity - long-running - acceptFormats: - - string + type: string uiOrder: 11 - format: string direction: default: desc title: Direction @@ -1586,31 +1777,25 @@ TASK_LIST_PULL_REQUESTS: enum: - asc - desc - acceptFormats: - - string + type: string uiOrder: 12 - format: string page: default: 1 description: Page number of the results to fetch. Default is 1. uiOrder: 100 title: Page - acceptFormats: - - integer - format: integer + type: integer per-page: default: 30 description: Number of results to fetch per page. Default is 30. uiOrder: 101 title: Per Page - acceptFormats: - - integer - format: integer + type: integer required: - owner - repository title: Input - format: object + type: object output: description: All PRs in GitHub repository. uiOrder: 0 @@ -1623,11 +1808,11 @@ TASK_LIST_PULL_REQUESTS: $ref: "#/$defs/pullRequest" required: [] description: A pull request in GitHub. - format: array + type: array required: - pull-requests title: Output - format: object + type: object TASK_LIST_REVIEW_COMMENTS: shortDescription: Get the review comments in a pull request description: Get the review comments in a pull request. The comments can be on a specific line or on the PR as a whole. @@ -1640,10 +1825,8 @@ TASK_LIST_REVIEW_COMMENTS: default: 0 title: PR Number description: Number of the PR. Default is `0`, which retrieves all comments on all PRs in the repository. - acceptFormats: - - integer + type: integer uiOrder: 4 - format: integer sort: default: created title: Sort @@ -1651,10 +1834,8 @@ TASK_LIST_REVIEW_COMMENTS: enum: - created - updated - acceptFormats: - - string + type: string uiOrder: 11 - format: string direction: default: desc title: Direction @@ -1662,39 +1843,31 @@ TASK_LIST_REVIEW_COMMENTS: enum: - asc - desc - acceptFormats: - - string + type: string uiOrder: 12 - format: string since: default: "2021-01-01" title: Since description: Date (in `YYYY-MM-DD` format) from which comments will start to be fetched. The date will be in the UTC timezone. - acceptFormats: - - string + type: string uiOrder: 13 - format: string page: default: 1 description: Page number of the results to fetch. Default is 1. uiOrder: 100 title: Page - acceptFormats: - - integer - format: integer + type: integer per-page: default: 30 description: Number of results to fetch per page. Default is 30. uiOrder: 101 title: Per Page - acceptFormats: - - integer - format: integer + type: integer required: - owner - repository title: Input - format: object + type: object output: description: Comments in the PR. uiOrder: 0 @@ -1708,8 +1881,8 @@ TASK_LIST_REVIEW_COMMENTS: required: [] uiOrder: 1 description: Comments in the PR. - format: array + type: array required: - comments title: Output - format: object + type: object diff --git a/pkg/component/application/googlesearch/v0/README.mdx b/pkg/component/application/googlesearch/v0/README.mdx index aa1b4796c..2dbec00ee 100644 --- a/pkg/component/application/googlesearch/v0/README.mdx +++ b/pkg/component/application/googlesearch/v0/README.mdx @@ -36,7 +36,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key (required) | `api-key` | string | API Key for the Google Custom Search API. You can create one here. | | Search Engine ID (required) | `cse-id` | string | ID of the Search Engine to use. Before using the Custom Search JSON API you will first need to create and configure your Programmable Search Engine. If you have not already created a Programmable Search Engine, you can start by visiting [the Programmable Search Engine control panel](https://programmablesearchengine.google.com/controlpanel/all).
You can find this in the URL of your Search Engine. For example, if the URL of your search engine is `https://cse.google.com/cse.js?cx=012345678910`, the ID value is: `012345678910`. | @@ -55,7 +55,7 @@ Search data via Google Search Engine.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEARCH` | | Query (required) | `query` | string | The search query for Google. | @@ -71,7 +71,7 @@ Search data via Google Search Engine.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Results](#search-results) | `results` | array[object] | The returned search results from Google. |
@@ -83,7 +83,7 @@ Search data via Google Search Engine.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Link | `link` | string | The full URL to which the search result is pointing, e.g., http://www.example.com/foo/bar. | | Link HTML | `link-html` | string | The scraped raw html of the link associated with this search result. | diff --git a/pkg/component/application/googlesearch/v0/config/setup.yaml b/pkg/component/application/googlesearch/v0/config/setup.yaml index d9811e038..606a82afe 100644 --- a/pkg/component/application/googlesearch/v0/config/setup.yaml +++ b/pkg/component/application/googlesearch/v0/config/setup.yaml @@ -5,7 +5,7 @@ properties: instillSecret: true uiOrder: 0 title: API Key - format: string + type: string cse-id: description: 'ID of the Search Engine to use. Before using the Custom Search JSON API you will first need to create and configure your Programmable Search Engine. If you have not already created a Programmable Search Engine, you can start by visiting [the Programmable Search Engine control panel](https://programmablesearchengine.google.com/controlpanel/all). @@ -14,9 +14,9 @@ properties: instillSecret: false uiOrder: 1 title: Search Engine ID - format: string + type: string required: - api-key - cse-id title: Google Search Connection -format: object +type: object diff --git a/pkg/component/application/googlesearch/v0/config/tasks.yaml b/pkg/component/application/googlesearch/v0/config/tasks.yaml index 848804782..45943055d 100644 --- a/pkg/component/application/googlesearch/v0/config/tasks.yaml +++ b/pkg/component/application/googlesearch/v0/config/tasks.yaml @@ -3,45 +3,35 @@ $defs: properties: link: description: The full URL to which the search result is pointing, e.g., http://www.example.com/foo/bar. - acceptFormats: - - string + type: string uiOrder: 1 title: Link - format: string link-html: description: The scraped raw html of the link associated with this search result. - acceptFormats: - - string + type: string uiOrder: 4 title: Link HTML - format: string link-text: description: The scraped text of the link associated with this search result, in plain text. - acceptFormats: - - string + type: string uiOrder: 3 title: Link Text - format: string snippet: description: The snippet from the page associated with this search result, in plain text. - acceptFormats: - - string + type: string uiOrder: 2 title: Snippet - format: string title: description: The title of a search result, in plain text. - acceptFormats: - - string + type: string uiOrder: 0 title: Title - format: string required: - title - link - snippet title: Result - format: object + type: object TASK_SEARCH: shortDescription: Search data via Google Search Engine. input: @@ -50,40 +40,32 @@ TASK_SEARCH: include-link-html: default: false description: Indicate whether to scrape the link and include the raw HTML of the link associated with this search result in the 'link-html' field. - acceptFormats: - - boolean + type: boolean uiOrder: 3 title: Include Link HTML - format: boolean include-link-text: default: false description: Indicate whether to scrape the link and include the text of the link associated with this search result in the 'link-text' field. - acceptFormats: - - boolean + type: boolean uiOrder: 2 title: Include Link Text - format: boolean query: description: The search query for Google. - acceptFormats: - - string + type: string uiOrder: 0 title: Query - format: string top-k: default: 10 description: The number of results to return for each query. - acceptFormats: - - integer + type: integer uiOrder: 1 maximum: 100 minimum: 1 title: Top K - format: integer required: - query title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -93,8 +75,8 @@ TASK_SEARCH: items: $ref: '#/$defs/result' title: Results - format: array + type: array required: - results title: Output - format: object + type: object diff --git a/pkg/component/application/hubspot/v0/README.mdx b/pkg/component/application/hubspot/v0/README.mdx index f8f8c5718..e70ec33cf 100644 --- a/pkg/component/application/hubspot/v0/README.mdx +++ b/pkg/component/application/hubspot/v0/README.mdx @@ -50,7 +50,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Token (required) | `token` | string | Fill in your HubSpot private app access token. Go here for [more information](https://developers.hubspot.com/docs/api/private-apps). | @@ -68,7 +68,7 @@ Get contact information using contact ID or Email
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_CONTACT` | | Contact ID or Email (required) | `contact-id-or-email` | string | Input contact ID or email. If the input has @, it will search the contact using email. | @@ -81,7 +81,7 @@ Get contact information using contact ID or Email
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Owner ID (optional) | `owner-id` | string | The user who is assigned to the object. | | Email Address (optional) | `email` | string | Email address. | @@ -102,7 +102,7 @@ Create new contact
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_CONTACT` | | Owner ID | `owner-id` | string | The user who is assigned to the object. | @@ -126,7 +126,7 @@ Create new contact
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Contact ID | `contact-id` | string | Contact ID. |
@@ -138,7 +138,7 @@ Get deal information using deal ID
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_DEAL` | | Deal ID (required) | `deal-id` | string | Input deal ID. | @@ -151,7 +151,7 @@ Get deal information using deal ID
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Owner ID (optional) | `owner-id` | string | The user who is assigned to the object. | | Deal Name | `deal-name` | string | Deal name. | @@ -171,7 +171,7 @@ Create new deal
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_DEAL` | | Owner ID | `owner-id` | string | The user who is assigned to the object. | @@ -191,7 +191,7 @@ Create new deal
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Deal ID | `deal-id` | string | Deal ID. |
@@ -203,7 +203,7 @@ Update existing deal
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE_DEAL` | | Deal ID (required) | `deal-id` | string | Input deal ID. | @@ -224,7 +224,7 @@ Update existing deal
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Updated by User ID | `updated-by-user-id` | string | User ID that updated the deal. | | Updated At | `updated-at` | string | The time when the deal was updated. | @@ -237,7 +237,7 @@ Get company information using company ID
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_COMPANY` | | Company ID (required) | `company-id` | string | Input company ID. | @@ -250,7 +250,7 @@ Get company information using company ID
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Owner ID (optional) | `owner-id` | string | The user who is assigned to the object. | | Company Name (optional) | `company-name` | string | Company name. | @@ -277,7 +277,7 @@ Create new company
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_COMPANY` | | Owner ID | `owner-id` | string | The user who is assigned to the object. | @@ -304,7 +304,7 @@ Create new company
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Company ID | `company-id` | string | Company ID. |
@@ -316,7 +316,7 @@ Get ticket information using ticket ID
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_TICKET` | | Ticket ID (required) | `ticket-id` | string | Input ticket ID. | @@ -329,7 +329,7 @@ Get ticket information using ticket ID
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Owner ID (optional) | `owner-id` | string | The user who is assigned to the object. | | Ticket Name | `ticket-name` | string | Ticket name. | @@ -351,7 +351,7 @@ Create new ticket
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_TICKET` | | Owner ID | `owner-id` | string | The user who is assigned to the object. | @@ -371,7 +371,7 @@ Create new ticket
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Ticket ID | `ticket-id` | string | Ticket ID. |
@@ -383,7 +383,7 @@ Update existing ticket
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE_TICKET` | | Owner ID | `owner-id` | string | The user who is assigned to the object. | @@ -404,7 +404,7 @@ Update existing ticket
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Updated At | `updated-at` | string | The time when the ticket was updated. |
@@ -416,7 +416,7 @@ Retrieve all the messages inside a thread (conversation inbox). The messages wil
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_THREAD` | | Thread ID (required) | `thread-id` | string | Input thread ID. | @@ -429,7 +429,7 @@ Retrieve all the messages inside a thread (conversation inbox). The messages wil
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Messages](#get-thread-messages) | `results` | array[object] | An array of messages. | | Number of Messages | `no-of-messages` | integer | The number of messages in a thread. | @@ -442,7 +442,7 @@ Retrieve all the messages inside a thread (conversation inbox). The messages wil
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Channel Account ID | `channel-account-id` | string | The ID of an account that is part of the channel-id channel. | | Channel ID | `channel-id` | string | The ID of a generic channel returned from the channels endpoint, like 1000 for live chat, 1001 for Facebook Messenger, 1002 for email, etc. | @@ -457,7 +457,7 @@ Retrieve all the messages inside a thread (conversation inbox). The messages wil
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Actor ID | `sender-actor-id` | string | The actor ID of the sender. | | Name | `sender-name` | string | The name of the sender. | @@ -469,7 +469,7 @@ Retrieve all the messages inside a thread (conversation inbox). The messages wil
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Name | `name` | string | The name of the recipient. | | Type | `type` | string | Specify the category of recipient information. | @@ -484,7 +484,7 @@ Insert message into a thread (only support email thread)
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INSERT_MESSAGE` | | Thread ID (required) | `thread-id` | string | Input thread ID. | @@ -502,7 +502,7 @@ Insert message into a thread (only support email thread)
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | The message status. |
@@ -514,7 +514,7 @@ Get the object IDs associated with contact ID (contact->objects). If you are try
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_RETRIEVE_ASSOCIATION` | | Contact ID (required) | `contact-id` | string | Input contact ID. | @@ -528,7 +528,7 @@ Get the object IDs associated with contact ID (contact->objects). If you are try
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Object ID Array | `object-ids` | array[string] | An array of object ID associated with the contact. | | Object IDs Length | `object-ids-length` | integer | The number of object IDs. | @@ -541,7 +541,7 @@ Get information about HubSpot owner using either owner ID or user ID. For more i
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_OWNER` | | ID Type (required) | `id-type` | string | Specify the type of ID you will use to get owner's information.
Enum values
  • `Owner ID`
  • `User ID`
| @@ -555,7 +555,7 @@ Get information about HubSpot owner using either owner ID or user ID. For more i
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | First Name | `first-name` | string | First name. | | Last Name | `last-name` | string | Last name. | @@ -575,7 +575,7 @@ Get information about HubSpot owner using either owner ID or user ID. For more i
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Team ID | `team-id` | string | The ID of the team. | | Team Name | `team-name` | string | The name of the team. | @@ -590,7 +590,7 @@ Get all the IDs for a specific object (e.g. all contact IDs)
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_ALL` | | Object Type (required) | `object-type` | string | The object which you want to get all IDs for.
Enum values
  • `Contacts`
  • `Deals`
  • `Companies`
  • `Tickets`
  • `Threads`
  • `Owners`
| @@ -603,7 +603,7 @@ Get all the IDs for a specific object (e.g. all contact IDs)
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Object ID Array | `object-ids` | array[string] | An array of object ID. | | Object IDs Length | `object-ids-length` | integer | The number of object IDs. | diff --git a/pkg/component/application/hubspot/v0/config/setup.yaml b/pkg/component/application/hubspot/v0/config/setup.yaml index f484ea118..79c1da511 100644 --- a/pkg/component/application/hubspot/v0/config/setup.yaml +++ b/pkg/component/application/hubspot/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: token: description: Fill in your HubSpot private app access token. Go here for [more information](https://developers.hubspot.com/docs/api/private-apps). - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: Token - format: string required: - token title: HubSpot Connection -format: object +type: object diff --git a/pkg/component/application/hubspot/v0/config/tasks.yaml b/pkg/component/application/hubspot/v0/config/tasks.yaml index fafc6a024..ef83eda47 100644 --- a/pkg/component/application/hubspot/v0/config/tasks.yaml +++ b/pkg/component/application/hubspot/v0/config/tasks.yaml @@ -4,251 +4,243 @@ $defs: description: The user who is assigned to the object. title: Owner ID uiOrder: 0 - format: string + type: string associated-contact-ids: description: Contact IDs associated with the object. title: Associated Contact IDs items: title: Associated Contact ID description: Contact ID associated with the object. - format: string - format: array + type: string + type: array create-contacts-association: description: Existing contact IDs to be associated with the object. title: Create Object -> Contact Association using contact IDs - acceptFormats: - - array + type: array items: - format: string - format: array + type: string create-deals-association: description: Existing deal IDs to be associated with the object. title: Create Object -> Deal Association using deal IDs - acceptFormats: - - array + type: array items: - format: string - format: array + type: string create-companies-association: description: Existing company IDs to be associated with the object. title: Create Object -> Company Association using company IDs - acceptFormats: - - array + type: array items: - format: string - format: array + type: string create-tickets-association: description: Existing ticket IDs to be associated with the object. title: Create Object -> Ticket Association using ticket IDs - acceptFormats: - - array + type: array items: - format: string - format: array + type: string contact: email: description: Email address. uiOrder: 1 title: Email Address - format: string + type: string first-name: description: First name. uiOrder: 2 title: First Name - format: string + type: string last-name: description: Last name. uiOrder: 3 title: Last Name - format: string + type: string phone-number: description: 'Phone number. If you plan to use the number formatting feature in HubSpot, use country code + phone number. Example: +886xxxxxxxxx.' uiOrder: 4 title: Phone Number - format: string + type: string company: description: Company. uiOrder: 5 title: Company - format: string + type: string job-title: description: Job title. uiOrder: 6 title: Job Title - format: string + type: string lifecycle-stage: description: 'Lifecycle stages are used to track how contacts or companies move forward in your process. Default format is in small letters, all words are combined. Example: salesqualifiedlead. However, remember to check internal value for custom fields.' uiOrder: 7 title: Lifecycle Stage - format: string + type: string lead-status: description: 'The contact''s sales, prospecting or outreach status. Default format is in capital letters, with _ as space. Example: IN_PROGRESS. However, remember to check internal value for custom fields.' uiOrder: 8 title: Lead Status - format: string + type: string deal: deal-name: description: Deal name. uiOrder: 1 title: Deal Name - format: string + type: string pipeline: description: A pipeline is the place where you document and manage how your prospects move through the steps of your sales process. HubSpot uses interval value rather than the name displayed in the view. uiOrder: 2 title: Pipeline - format: string + type: string deal-stage: description: 'Deal stages allow you to categorize and track the progress of the deals that you are working on. Default format is in small letters, all words are combined. Example: qualifiedtobuy. However, remember to check internal value for custom fields.' uiOrder: 3 title: Deal Stage - format: string + type: string amount: description: The total amount of the deal. uiOrder: 4 title: Amount - format: number + type: number deal-type: description: 'The type of deal. Default format is in small letters, all words are combined. Example: newbusiness. However, remember to check internal value for custom fields.' uiOrder: 5 title: Deal Type - format: string + type: string close-date: description: 'Date the deal was closed. Set automatically by HubSpot. Format is in ISO 8601. Example: 2024-07-01T11:47:40.388Z.' uiOrder: 6 title: Close Date - format: string + type: string create-date: description: 'Create date. Format is in ISO 8601. Example: 2024-07-01T11:47:40.388Z.' uiOrder: 7 title: Create Date - format: string + type: string company: company-name: description: Company name. uiOrder: 1 title: Company Name - format: string + type: string company-domain: description: The domain name of the company. uiOrder: 2 title: Company Domain - format: string + type: string description: description: Description of the company. uiOrder: 3 title: Description - format: string + type: string phone-number: description: 'Phone number of the company. If you plan to use the number formatting feature in HubSpot, use country code + phone number. Example: +886xxxxxxxxx.' uiOrder: 4 title: Phone Number - format: string + type: string industry: description: 'The industry the company belongs to. Default format is in capital letters, with _ as space. Example: BROADCAST_MEDIA.' uiOrder: 5 title: Industry - format: string + type: string company-type: description: 'Type of company. Default format is capital letter. Example: RESELLER.' uiOrder: 6 title: Company Type - format: string + type: string city: description: City. uiOrder: 7 title: City - format: string + type: string state: description: State. uiOrder: 8 title: State - format: string + type: string country: description: Country. uiOrder: 9 title: Country - format: string + type: string postal-code: description: Postal code. uiOrder: 10 title: Postal Code - format: string + type: string time-zone: description: Time zone. uiOrder: 11 title: Time Zone - format: string + type: string annual-revenue: description: Annual revenue. uiOrder: 12 title: Annual Revenue - format: number + type: number total-revenue: description: Total revenue. Calculated automatically by HubSpot. uiOrder: 13 title: Total Revenue - format: number + type: number linkedin-page: description: Linkedin page of the company. uiOrder: 14 title: Linkedin Page - format: string + type: string ticket: ticket-name: description: Ticket name. uiOrder: 1 title: Ticket Name - format: string + type: string ticket-status: description: 'The pipeline stage that contains this ticket. Default format is number. Example: 1. However, remember to check internal value for custom fields. Note: In Instill AI, ticket-status is displayed as string because of the possible custom internal value.' uiOrder: 2 title: Ticket Status - format: string + type: string pipeline: description: A pipeline organizes and tracks the progression of tickets through various stages of resolution within your support process. HubSpot uses interval value rather than the name displayed in the view. uiOrder: 3 title: Pipeline - format: string + type: string categories: description: 'The main reason customer reached out for help. Default format is in capital letters. Example: BILLING_ISSUE. However, remember to check internal value for custom fields.' uiOrder: 4 title: Categories - format: array + type: array priority: description: 'The level of attention needed on the ticket. Default format is in capital letters. Example: MEDIUM. However, remember to check internal value for custom fields.' uiOrder: 5 title: Priority - format: string + type: string source: description: 'Channel where ticket was originally submitted. Default format is in capital letters. Example: EMAIL.' uiOrder: 6 title: Source - format: string + type: string record-source: description: How this record was created. uiOrder: 7 title: Record Source - format: string + type: string create-date: description: 'Create date. Format is in ISO 8601. Example: 2024-07-01T11:47:40.388Z.' uiOrder: 8 title: Create Date - format: string + type: string last-modified-date: description: 'Last modified date. Format is in ISO 8601. Example: 2024-07-01T11:47:40.388Z.' uiOrder: 9 title: Last Modified Date - format: string + type: string TASK_GET_CONTACT: shortDescription: Get contact information using contact ID or Email input: @@ -257,15 +249,13 @@ TASK_GET_CONTACT: properties: contact-id-or-email: description: Input contact ID or email. If the input has @, it will search the contact using email. - acceptFormats: - - string + type: string uiOrder: 0 title: Contact ID or Email - format: string required: - contact-id-or-email title: Input - format: object + type: object output: description: Contact information. uiOrder: 0 @@ -273,49 +263,49 @@ TASK_GET_CONTACT: owner-id: $ref: '#/$defs/common/owner-id' required: [] - format: string + type: string email: $ref: '#/$defs/contact/email' required: [] - format: string + type: string first-name: $ref: '#/$defs/contact/first-name' required: [] - format: string + type: string last-name: $ref: '#/$defs/contact/last-name' required: [] - format: string + type: string phone-number: $ref: '#/$defs/contact/phone-number' required: [] - format: string + type: string company: $ref: '#/$defs/contact/company' required: [] - format: string + type: string job-title: $ref: '#/$defs/contact/job-title' required: [] - format: string + type: string lifecycle-stage: $ref: '#/$defs/contact/lifecycle-stage' required: [] - format: string + type: string lead-status: $ref: '#/$defs/contact/lead-status' required: [] - format: string + type: string contact-id: description: Contact ID. uiOrder: 9 required: [] title: Contact ID - format: string + type: string required: - contact-id title: Output - format: object + type: object TASK_CREATE_CONTACT: shortDescription: Create new contact input: @@ -324,40 +314,31 @@ TASK_CREATE_CONTACT: properties: owner-id: $ref: '#/$defs/common/owner-id' - acceptFormats: - - string + type: string email: $ref: '#/$defs/contact/email' - acceptFormats: - - string + type: string first-name: $ref: '#/$defs/contact/first-name' - acceptFormats: - - string + type: string last-name: $ref: '#/$defs/contact/last-name' - acceptFormats: - - string + type: string phone-number: $ref: '#/$defs/contact/phone-number' - acceptFormats: - - string + type: string company: $ref: '#/$defs/contact/company' - acceptFormats: - - string + type: string job-title: $ref: '#/$defs/contact/job-title' - acceptFormats: - - string + type: string lifecycle-stage: $ref: '#/$defs/contact/lifecycle-stage' - acceptFormats: - - string + type: string lead-status: $ref: '#/$defs/contact/lead-status' - acceptFormats: - - string + type: string create-deals-association: $ref: '#/$defs/common/create-deals-association' uiOrder: 9 @@ -370,7 +351,7 @@ TASK_CREATE_CONTACT: required: - email title: Input - format: object + type: object output: description: Obtain contact ID. uiOrder: 0 @@ -380,11 +361,11 @@ TASK_CREATE_CONTACT: uiOrder: 0 required: [] title: Contact ID - format: string + type: string required: - contact-id title: Output - format: object + type: object TASK_GET_DEAL: shortDescription: Get deal information using deal ID input: @@ -393,15 +374,13 @@ TASK_GET_DEAL: properties: deal-id: description: Input deal ID. - acceptFormats: - - string + type: string uiOrder: 0 title: Deal ID - format: string required: - deal-id title: Input - format: object + type: object output: description: Deal information. uiOrder: 0 @@ -409,35 +388,35 @@ TASK_GET_DEAL: owner-id: $ref: '#/$defs/common/owner-id' required: [] - format: string + type: string deal-name: $ref: '#/$defs/deal/deal-name' required: [] - format: string + type: string pipeline: $ref: '#/$defs/deal/pipeline' required: [] - format: string + type: string deal-stage: $ref: '#/$defs/deal/deal-stage' required: [] - format: string + type: string amount: $ref: '#/$defs/deal/amount' required: [] - format: number + type: number deal-type: $ref: '#/$defs/deal/deal-type' required: [] - format: string + type: string create-date: $ref: '#/$defs/deal/create-date' required: [] - format: string + type: string close-date: $ref: '#/$defs/deal/close-date' required: [] - format: string + type: string associated-contact-ids: $ref: '#/$defs/common/associated-contact-ids' uiOrder: 8 @@ -446,7 +425,7 @@ TASK_GET_DEAL: - pipeline - deal-stage title: Output - format: object + type: object TASK_CREATE_DEAL: shortDescription: Create new deal input: @@ -455,32 +434,25 @@ TASK_CREATE_DEAL: properties: owner-id: $ref: '#/$defs/common/owner-id' - acceptFormats: - - string + type: string deal-name: $ref: '#/$defs/deal/deal-name' - acceptFormats: - - string + type: string pipeline: $ref: '#/$defs/deal/pipeline' - acceptFormats: - - string + type: string deal-stage: $ref: '#/$defs/deal/deal-stage' - acceptFormats: - - string + type: string amount: $ref: '#/$defs/deal/amount' - acceptFormats: - - number + type: number deal-type: $ref: '#/$defs/deal/deal-type' - acceptFormats: - - string + type: string close-date: $ref: '#/$defs/deal/close-date' - acceptFormats: - - string + type: string create-contacts-association: $ref: '#/$defs/common/create-contacts-association' uiOrder: 7 @@ -489,7 +461,7 @@ TASK_CREATE_DEAL: - pipeline - deal-stage title: Input - format: object + type: object output: description: Obtain deal ID. uiOrder: 0 @@ -499,11 +471,11 @@ TASK_CREATE_DEAL: uiOrder: 0 required: [] title: Deal ID - format: string + type: string required: - deal-id title: Output - format: object + type: object TASK_UPDATE_DEAL: shortDescription: Update existing deal input: @@ -512,46 +484,37 @@ TASK_UPDATE_DEAL: properties: deal-id: description: Input deal ID. - acceptFormats: - - string + type: string uiOrder: 0 title: Deal ID - format: string owner-id: $ref: '#/$defs/common/owner-id' - acceptFormats: - - string + type: string deal-name: $ref: '#/$defs/deal/deal-name' - acceptFormats: - - string + type: string pipeline: $ref: '#/$defs/deal/pipeline' - acceptFormats: - - string + type: string deal-stage: $ref: '#/$defs/deal/deal-stage' - acceptFormats: - - string + type: string amount: $ref: '#/$defs/deal/amount' - acceptFormats: - - number + type: number deal-type: $ref: '#/$defs/deal/deal-type' - acceptFormats: - - string + type: string close-date: $ref: '#/$defs/deal/close-date' - acceptFormats: - - string + type: string create-contacts-association: $ref: '#/$defs/common/create-contacts-association' uiOrder: 7 required: - deal-id title: Input - format: object + type: object output: description: Obtain user ID that updated the deal and its update time. uiOrder: 0 @@ -561,18 +524,18 @@ TASK_UPDATE_DEAL: uiOrder: 0 required: [] title: Updated By User ID - format: string + type: string updated-at: description: The time when the deal was updated. uiOrder: 1 required: [] title: Updated At - format: string + type: string required: - updated-by-user-id - updated-at title: Output - format: object + type: object TASK_GET_COMPANY: shortDescription: Get company information using company ID input: @@ -581,15 +544,13 @@ TASK_GET_COMPANY: properties: company-id: description: Input company ID. - acceptFormats: - - string + type: string uiOrder: 0 title: Company ID - format: string required: - company-id title: Input - format: object + type: object output: description: Company information. uiOrder: 0 @@ -597,69 +558,69 @@ TASK_GET_COMPANY: owner-id: $ref: '#/$defs/common/owner-id' required: [] - format: string + type: string company-name: $ref: '#/$defs/company/company-name' required: [] - format: string + type: string company-domain: $ref: '#/$defs/company/company-domain' required: [] - format: string + type: string description: $ref: '#/$defs/company/description' required: [] - format: string + type: string phone-number: $ref: '#/$defs/company/phone-number' required: [] - format: string + type: string industry: $ref: '#/$defs/company/industry' required: [] - format: string + type: string company-type: $ref: '#/$defs/company/company-type' required: [] - format: string + type: string city: $ref: '#/$defs/company/city' required: [] - format: string + type: string state: $ref: '#/$defs/company/state' required: [] - format: string + type: string country: $ref: '#/$defs/company/country' required: [] - format: string + type: string postal-code,: $ref: '#/$defs/company/postal-code' required: [] - format: string + type: string time-zone: $ref: '#/$defs/company/time-zone' required: [] - format: string + type: string annual-revenue: $ref: '#/$defs/company/annual-revenue' required: [] - format: number + type: number total-revenue: $ref: '#/$defs/company/total-revenue' required: [] - format: number + type: number linkedin-page: $ref: '#/$defs/company/linkedin-page' required: [] - format: string + type: string associated-contact-ids: $ref: '#/$defs/common/associated-contact-ids' uiOrder: 15 required: [] title: Output - format: object + type: object TASK_CREATE_COMPANY: shortDescription: Create new company input: @@ -668,67 +629,53 @@ TASK_CREATE_COMPANY: properties: owner-id: $ref: '#/$defs/common/owner-id' - acceptFormats: - - string + type: string company-name: $ref: '#/$defs/company/company-name' - acceptFormats: - - string + type: string company-domain: $ref: '#/$defs/company/company-domain' - acceptFormats: - - string + type: string description: $ref: '#/$defs/company/description' - acceptFormats: - - string + type: string phone-number: $ref: '#/$defs/company/phone-number' - acceptFormats: - - string + type: string industry: $ref: '#/$defs/company/industry' - acceptFormats: - - string + type: string company-type: $ref: '#/$defs/company/company-type' - acceptFormats: - - string + type: string city: $ref: '#/$defs/company/city' - acceptFormats: - - string + type: string state: $ref: '#/$defs/company/state' - acceptFormats: - - string + type: string country: $ref: '#/$defs/company/country' - acceptFormats: - - string + type: string postal-code,: $ref: '#/$defs/company/postal-code' - acceptFormats: - - string + type: string time-zone: $ref: '#/$defs/company/time-zone' - acceptFormats: - - string + type: string annual-revenue: $ref: '#/$defs/company/annual-revenue' - acceptFormats: - - number + type: number linkedin-page: $ref: '#/$defs/company/linkedin-page' - acceptFormats: - - string + type: string create-contacts-association: $ref: '#/$defs/common/create-contacts-association' uiOrder: 15 required: - company-domain title: Input - format: object + type: object output: description: Obtain company ID. uiOrder: 0 @@ -738,11 +685,11 @@ TASK_CREATE_COMPANY: uiOrder: 0 required: [] title: Company ID - format: string + type: string required: - company-id title: Output - format: object + type: object TASK_GET_TICKET: shortDescription: Get ticket information using ticket ID input: @@ -751,15 +698,13 @@ TASK_GET_TICKET: properties: ticket-id: description: Input ticket ID. - acceptFormats: - - string + type: string uiOrder: 0 title: Ticket ID - format: string required: - ticket-id title: Input - format: object + type: object output: description: Ticket information. uiOrder: 0 @@ -767,46 +712,46 @@ TASK_GET_TICKET: owner-id: $ref: '#/$defs/common/owner-id' required: [] - format: string + type: string ticket-name: $ref: '#/$defs/ticket/ticket-name' required: [] - format: string + type: string ticket-status: $ref: '#/$defs/ticket/ticket-status' required: [] - format: string + type: string pipeline: $ref: '#/$defs/ticket/pipeline' required: [] - format: string + type: string categories: $ref: '#/$defs/ticket/categories' items: title: Category Value description: Category value. - format: string - format: array + type: string + type: array priority: $ref: '#/$defs/ticket/priority' required: [] - format: string + type: string source: $ref: '#/$defs/ticket/source' required: [] - format: string + type: string record-source: $ref: '#/$defs/ticket/record-source' required: [] - format: string + type: string create-date: $ref: '#/$defs/ticket/create-date' required: [] - format: string + type: string last-modified-date: $ref: '#/$defs/ticket/last-modified-date' required: [] - format: string + type: string associated-contact-ids: $ref: '#/$defs/common/associated-contact-ids' uiOrder: 10 @@ -815,7 +760,7 @@ TASK_GET_TICKET: - ticket-status - pipeline title: Output - format: object + type: object TASK_CREATE_TICKET: shortDescription: Create new ticket input: @@ -824,34 +769,27 @@ TASK_CREATE_TICKET: properties: owner-id: $ref: '#/$defs/common/owner-id' - acceptFormats: - - string + type: string ticket-name: $ref: '#/$defs/ticket/ticket-name' - acceptFormats: - - string + type: string ticket-status: $ref: '#/$defs/ticket/ticket-status' - acceptFormats: - - string + type: string pipeline: $ref: '#/$defs/ticket/pipeline' - acceptFormats: - - string + type: string categories: $ref: '#/$defs/ticket/categories' - acceptFormats: - - array + type: array items: - format: string + type: string priority: $ref: '#/$defs/ticket/priority' - acceptFormats: - - string + type: string source: $ref: '#/$defs/ticket/source' - acceptFormats: - - string + type: string create-contacts-association: $ref: '#/$defs/common/create-contacts-association' uiOrder: 7 @@ -860,7 +798,7 @@ TASK_CREATE_TICKET: - ticket-status - pipeline title: Input - format: object + type: object output: description: Obtain ticket ID. uiOrder: 0 @@ -870,11 +808,11 @@ TASK_CREATE_TICKET: uiOrder: 0 required: [] title: Ticket ID - format: string + type: string required: - ticket-id title: Output - format: object + type: object TASK_UPDATE_TICKET: shortDescription: Update existing ticket input: @@ -883,48 +821,39 @@ TASK_UPDATE_TICKET: properties: ticket-id: description: Input ticket ID. - acceptFormats: - - string + type: string uiOrder: 0 title: Ticket ID - format: string owner-id: $ref: '#/$defs/common/owner-id' - acceptFormats: - - string + type: string ticket-name: $ref: '#/$defs/ticket/ticket-name' - acceptFormats: - - string + type: string ticket-status: $ref: '#/$defs/ticket/ticket-status' - acceptFormats: - - string + type: string pipeline: $ref: '#/$defs/ticket/pipeline' - acceptFormats: - - string + type: string categories: $ref: '#/$defs/ticket/categories' - acceptFormats: - - array + type: array items: - format: string + type: string priority: $ref: '#/$defs/ticket/priority' - acceptFormats: - - string + type: string source: $ref: '#/$defs/ticket/source' - acceptFormats: - - string + type: string create-contacts-association: $ref: '#/$defs/common/create-contacts-association' uiOrder: 7 required: - ticket-id title: Input - format: object + type: object output: description: Update time. uiOrder: 0 @@ -934,11 +863,11 @@ TASK_UPDATE_TICKET: uiOrder: 0 required: [] title: Updated At - format: string + type: string required: - updated-at title: Output - format: object + type: object TASK_GET_THREAD: shortDescription: 'Retrieve all the messages inside a thread (conversation inbox). The messages will be sorted from most recent to least recent. Note: This task uses Conversation API from HubSpot, which is still in BETA.' @@ -948,15 +877,13 @@ TASK_GET_THREAD: properties: thread-id: description: Input thread ID. - acceptFormats: - - string + type: string uiOrder: 0 title: Thread ID - format: string required: - thread-id title: Input - format: object + type: object output: description: All messages in the thread. uiOrder: 0 @@ -972,7 +899,7 @@ TASK_GET_THREAD: description: message to start a conversation. uiOrder: 0 title: Start Conversation Message - format: string + type: string sender: description: Sender's information. uiOrder: 1 @@ -982,25 +909,25 @@ TASK_GET_THREAD: description: The name of the sender. uiOrder: 0 title: Name - format: string + type: string sender-type: description: Specify the category of sender information. uiOrder: 1 title: Type - format: string + type: string sender-value: description: 'Contains the actual sender information (e.g.: email address).' uiOrder: 2 title: Value - format: string + type: string sender-actor-id: description: The actor ID of the sender. uiOrder: 3 title: Actor ID - format: string + type: string required: - sender-actor-id - format: object + type: object recipients: description: Recipients' information. uiOrder: 2 @@ -1012,63 +939,63 @@ TASK_GET_THREAD: description: The name of the recipient. uiOrder: 0 title: Name - format: string + type: string value: description: 'Contains the actual recipient information (e.g.: email address).' uiOrder: 2 title: Value - format: string + type: string type: description: Specify the category of recipient information. uiOrder: 1 title: Type - format: string + type: string required: [] - format: object - format: array + type: object + type: array text: description: The content of the message. uiOrder: 3 required: [] title: Text - format: string + type: string subject: description: The subject of the message. uiOrder: 4 required: [] title: Subject - format: string + type: string channel-id: description: The ID of a generic channel returned from the channels endpoint, like 1000 for live chat, 1001 for Facebook Messenger, 1002 for email, etc. uiOrder: 5 required: [] title: Channel ID - format: string + type: string channel-account-id: description: The ID of an account that is part of the channel-id channel. uiOrder: 6 required: [] title: Channel Account ID - format: string + type: string required: - created-at - text - channel-id - channel-account-id - format: object - format: array + type: object + type: array no-of-messages: description: The number of messages in a thread. uiOrder: 1 required: [] title: Number of Messages - format: integer + type: integer required: - results - no-of-messages title: Output - format: object + type: object TASK_INSERT_MESSAGE: shortDescription: Insert message into a thread (only support email thread) input: @@ -1077,50 +1004,38 @@ TASK_INSERT_MESSAGE: properties: thread-id: description: Input thread ID. - acceptFormats: - - string + type: string uiOrder: 0 title: Thread ID - format: string sender-actor-id: description: 'Input sender actor id. Example: A-12345678. To obtain this, it is recommended to use and copy the ''Get Thread task'' sender output. For [more information](https://developers.hubspot.com/beta-docs/guides/api/conversations/inbox-and-messages#get-actors) about actor id.' - acceptFormats: - - string + type: string uiOrder: 1 title: Sender Actor ID - format: string recipients: description: Recipients of the message. title: Recipients - acceptFormats: - - array + type: array uiOrder: 2 items: - format: string - format: array + type: string channel-account-id: description: The ID of an account that is part of the channel-id channel. On an existing thread, it is recommended to copy channel-account-id of the most recent message on the thread. - acceptFormats: - - string + type: string uiOrder: 3 title: Channel Account ID - format: string subject: description: The subject of the message. - acceptFormats: - - string + type: string uiOrder: 4 title: Subject - format: string text: description: The body of the message. - acceptFormats: - - string + type: string uiOrder: 5 title: Text - format: string required: - thread-id - sender-actor-id @@ -1129,7 +1044,7 @@ TASK_INSERT_MESSAGE: - subject - text title: Input - format: object + type: object output: description: Status of the message. uiOrder: 0 @@ -1139,11 +1054,11 @@ TASK_INSERT_MESSAGE: uiOrder: 0 required: [] title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_RETRIEVE_ASSOCIATION: shortDescription: 'Get the object IDs associated with contact ID (contact->objects). If you are trying to do the opposite (object->contacts), it is possible using the other tasks. Example: Go to get deal task to obtain deal->contacts. Remember to check that the contact ID you input exists, because there @@ -1154,11 +1069,9 @@ TASK_RETRIEVE_ASSOCIATION: properties: contact-id: description: Input contact ID. - acceptFormats: - - string + type: string uiOrder: 0 title: Contact ID - format: string object-type: enum: - Deals @@ -1167,16 +1080,14 @@ TASK_RETRIEVE_ASSOCIATION: - Threads example: Deals description: 'Input object type (CRM objects or ''Threads''). Note: CRM objects include ''Deals'', ''Companies'', ''Tickets'', etc.' - acceptFormats: - - string + type: string uiOrder: 1 title: Object Type - format: string required: - contact-id - object-type title: Input - format: object + type: object output: description: All object IDs. uiOrder: 0 @@ -1188,19 +1099,19 @@ TASK_RETRIEVE_ASSOCIATION: items: title: Object ID description: The object ID associated with the contact. - format: string - format: array + type: string + type: array object-ids-length: description: The number of object IDs. uiOrder: 1 required: [] title: Object IDs Length - format: integer + type: integer required: - object-ids - object-ids-length title: Output - format: object + type: object TASK_GET_OWNER: shortDescription: Get information about HubSpot owner using either owner ID or user ID. For more information about owner, please go to [here](https://developers.hubspot.com/docs/api/crm/owners) input: @@ -1213,23 +1124,19 @@ TASK_GET_OWNER: - User ID example: Owner ID description: Specify the type of ID you will use to get owner's information. - acceptFormats: - - string + type: string uiOrder: 0 title: ID Type - format: string id: description: Can either be owner ID or user ID; according to the ID type you selected. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string required: - id-type - id title: Input - format: object + type: object output: description: Owner's detailed information. uiOrder: 0 @@ -1239,31 +1146,31 @@ TASK_GET_OWNER: uiOrder: 0 required: [] title: First Name - format: string + type: string last-name: description: Last name. uiOrder: 1 required: [] title: Last Name - format: string + type: string email: description: Email. uiOrder: 2 required: [] title: Email - format: string + type: string owner-id: description: Owner ID. Usually used to associate the owner with other objects. uiOrder: 3 required: [] title: Owner ID - format: string + type: string user-id: description: User ID. Usually used to indicate the owner who performed the action. User ID can be seen in Update Deal task output. uiOrder: 4 required: [] title: User ID - format: string + type: string teams: description: The owner's teams information. uiOrder: 5 @@ -1275,41 +1182,41 @@ TASK_GET_OWNER: description: The name of the team. uiOrder: 0 title: Team Name - format: string + type: string team-id: description: The ID of the team. uiOrder: 1 title: Team ID - format: string + type: string team-primary: description: Indicate whether this team is the primary team of the owner. uiOrder: 2 title: Team Primary - format: boolean + type: boolean required: - team-name - team-id - team-primary - format: object - format: array + type: object + type: array created-at: description: Created at. uiOrder: 6 required: [] title: Created At - format: string + type: string updated-at: description: Updated at. uiOrder: 7 required: [] title: Updated At - format: string + type: string archived: description: Archived. uiOrder: 8 required: [] title: Archived - format: boolean + type: boolean required: - first-name - last-name @@ -1320,7 +1227,7 @@ TASK_GET_OWNER: - updated-at - archived title: Output - format: object + type: object TASK_GET_ALL: shortDescription: Get all the IDs for a specific object (e.g. all contact IDs) input: @@ -1337,15 +1244,13 @@ TASK_GET_ALL: - Owners example: Contacts description: The object which you want to get all IDs for. - acceptFormats: - - string + type: string uiOrder: 0 title: Object Type - format: string required: - object-type title: Input - format: object + type: object output: description: All the IDs of the object. uiOrder: 0 @@ -1357,16 +1262,16 @@ TASK_GET_ALL: items: title: Object ID description: Object ID. - format: string - format: array + type: string + type: array object-ids-length: description: The number of object IDs. uiOrder: 1 required: [] title: Object IDs Length - format: integer + type: integer required: - object-ids - object-ids-length title: Output - format: object + type: object diff --git a/pkg/component/application/jira/v0/.compogen/bottom.mdx b/pkg/component/application/jira/v0/.compogen/bottom.mdx index fda9c0cbc..c27ad6033 100644 --- a/pkg/component/application/jira/v0/.compogen/bottom.mdx +++ b/pkg/component/application/jira/v0/.compogen/bottom.mdx @@ -49,17 +49,17 @@ variable: description: |+ Your Jira base URL i.e. https://<_YOUR_COMPANY_>.atlassian.net - format: string + type: string board-name: title: Jira Board Name description: |+ The name of your Jira board i.e. "KANBAN board". - format: string + type: string jira-email: title: Jira Email description: The email you are using for Jira i.e. hello@world.com - format: string + type: string output: output: title: Output diff --git a/pkg/component/application/jira/v0/README.mdx b/pkg/component/application/jira/v0/README.mdx index cb16b7025..7685228da 100644 --- a/pkg/component/application/jira/v0/README.mdx +++ b/pkg/component/application/jira/v0/README.mdx @@ -44,7 +44,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Token (required) | `token` | string | Fill in your Jira API token. You can generate one from your Jira account "settings > security > API tokens". | | Base URL (required) | `base-url` | string | Fill in your Jira base URL. For example, if your Jira URL is "https://mycompany.atlassian.net/...", then your base URL is https://mycompany.atlassian.net. | @@ -64,7 +64,7 @@ Create an issue in Jira.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_ISSUE` | | Project Key (required) | `project-key` | string | The key of the project, e.g. `INS`. | @@ -89,7 +89,7 @@ Epic.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Issue Type | `issue-type` | string | Must be `"Epic"` |
@@ -100,7 +100,7 @@ Task.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Issue Type | `issue-type` | string | Must be `"Task"` |
@@ -111,7 +111,7 @@ Subtask.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Issue Type | `issue-type` | string | Must be `"Subtask"` | | Parent Key | `parent-key` | string | The key of the parent issue, e.g. `JRA-1330`. | @@ -123,7 +123,7 @@ Other.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Issue Type | `custom-issue-type` | string | The type of the issue, can be: `Task`, `Epic`, `Subtask`, etc. | | Issue Type | `issue-type` | string | Must be `"Other"` | @@ -132,7 +132,7 @@ Other.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | ID | `id` | string | The ID of the issue. | | Key | `key` | string | The key of the issue, e.g. `JRA-1330`. | @@ -151,7 +151,7 @@ Create a sprint in Jira.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_SPRINT` | | Board Name (required) | `board-name` | string | The name of the board. | @@ -168,7 +168,7 @@ Create a sprint in Jira.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | ID | `id` | integer | The ID of the sprint. | | Self | `self` | string | The URL of the sprint. | @@ -188,7 +188,7 @@ Get an issue in Jira. The issue will only be returned if the user has permission
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_ISSUE` | | Issue Key (required) | `issue-key` | string | The key of the issue, e.g. `JRA-1330`. | @@ -202,7 +202,7 @@ Get an issue in Jira. The issue will only be returned if the user has permission
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | ID | `id` | string | The ID of the issue. | | Key | `key` | string | The key of the issue, e.g. `JRA-1330`. | @@ -221,7 +221,7 @@ Get a sprint in Jira. The sprint will only be returned if the user can view the
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_SPRINT` | | Sprint ID (required) | `sprint-id` | integer | The ID of the sprint. The sprint will only be returned if you can view the board that the sprint was created on, or view at least one of the issues in the sprint. | @@ -234,7 +234,7 @@ Get a sprint in Jira. The sprint will only be returned if the user can view the
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | ID (optional) | `id` | integer | The ID of the sprint. | | Self (optional) | `self` | string | The URL of the sprint. | @@ -254,7 +254,7 @@ List all boards in Jira
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_LIST_BOARDS` | | Project Key or ID | `project-key-or-id` | string | This filters results to boards that are relevant to a project. Relevance meaning that the JQL filter defined in board contains a reference to a project. | @@ -271,7 +271,7 @@ List all boards in Jira
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Boards](#list-boards-boards) (optional) | `boards` | array[object] | A array of boards in Jira. | | Start At | `start-at` | integer | The starting index of the returned boards. Base index: 0. | @@ -287,7 +287,7 @@ List all boards in Jira
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | ID | `id` | integer | The ID of the board. | | Name | `name` | string | The name of the board. | @@ -303,7 +303,7 @@ List issues in Jira.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_LIST_ISSUES` | | Board Name (required) | `board-name` | string | The name of the board. | @@ -328,7 +328,7 @@ All issues.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Range | `range` | string | Must be `"All"` |
@@ -339,7 +339,7 @@ Standard issues.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Range | `range` | string | Must be `"Standard Issues"` |
@@ -350,7 +350,7 @@ Epics only.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Range | `range` | string | Must be `"Epics only"` |
@@ -361,7 +361,7 @@ In backlog only.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Range | `range` | string | Must be `"In backlog only"` |
@@ -372,7 +372,7 @@ Issues of an epic.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Epic Key | `epic-key` | string | The Key of the epic, e.g. `JRA-1330`. | | Range | `range` | string | Must be `"Issues of an epic"` | @@ -384,7 +384,7 @@ Issues of a sprint.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Range | `range` | string | Must be `"Issues of a sprint"` | | Sprint Name | `sprint-name` | string | The name of the sprint. | @@ -396,7 +396,7 @@ Issues without Epic Assigned.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Range | `range` | string | Must be `"Issues without epic assigned"` |
@@ -407,7 +407,7 @@ JQL query.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | JQL | `jql` | string | The JQL query. For example, `type = "Task" AND status = "Done"`. For more information, see Advanced searching. | | Range | `range` | string | Must be `"JQL query"` | @@ -416,7 +416,7 @@ JQL query.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Issues](#list-issues-issues) (optional) | `issues` | array[object] | A array of issues in Jira. | | Start At | `start-at` | integer | The starting index of the returned boards. Base index: 0. | @@ -431,7 +431,7 @@ JQL query.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Description | `description` | string | The description of the issue. | | Fields | `fields` | json | The fields of the issue. All navigable and Agile fields are returned. | @@ -451,7 +451,7 @@ List sprints in Jira.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_LIST_SPRINTS` | | Board ID (required) | `board-id` | integer | The ID of the board. | @@ -466,7 +466,7 @@ List sprints in Jira.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Sprints](#list-sprints-sprints) (optional) | `sprints` | array[object] | A array of sprints in Jira. | | Start At | `start-at` | integer | The starting index of the returned boards. Base index: 0. | @@ -481,7 +481,7 @@ List sprints in Jira.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Complete Date | `complete-date` | string | The complete date of the sprint, e.g. 2018-03-05 (default 00:00 UTC+0). To adjust your time zone, please provide a more detailed RFC3339 format like `2018-03-05T09:00:00Z0000`. | | End Date | `end-date` | string | The end date of the sprint, e.g. 2018-03-05 (default 00:00 UTC+0). To adjust your time zone, please provide a more detailed RFC3339 format like `2018-03-05T09:00:00Z0000`. | @@ -502,7 +502,7 @@ Update an issue in Jira.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE_ISSUE` | | Issue Key (required) | `issue-key` | string | The key of the issue, e.g. `JRA-1330`. | @@ -526,7 +526,7 @@ Custom update.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Update | `update` | string | Must be `"Custom Update"` | | Update Fields | `update-fields` | array | The fields to update. | @@ -538,7 +538,7 @@ Move issue to epic.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Epic Key | `epic-key` | string | The key of the epic, e.g. `JRA-1330`. | | Update | `update` | string | Must be `"Move Issue to Epic"` | @@ -547,7 +547,7 @@ Move issue to epic.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | ID | `id` | string | The ID of the issue. | | Key | `key` | string | The key of the issue, e.g. `JRA-1330`. | @@ -566,7 +566,7 @@ Update a sprint in Jira.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE_SPRINT` | | Sprint ID (required) | `sprint-id` | integer | The ID of the sprint. | @@ -585,7 +585,7 @@ Update a sprint in Jira.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | ID | `id` | integer | The ID of the sprint. | | Self | `self` | string | The URL of the sprint. | @@ -651,17 +651,17 @@ variable: description: |+ Your Jira base URL i.e. https://<_YOUR_COMPANY_>.atlassian.net - format: string + type: string board-name: title: Jira Board Name description: |+ The name of your Jira board i.e. "KANBAN board". - format: string + type: string jira-email: title: Jira Email description: The email you are using for Jira i.e. hello@world.com - format: string + type: string output: output: title: Output diff --git a/pkg/component/application/jira/v0/config/setup.yaml b/pkg/component/application/jira/v0/config/setup.yaml index e522d7a0e..dd41e4c56 100644 --- a/pkg/component/application/jira/v0/config/setup.yaml +++ b/pkg/component/application/jira/v0/config/setup.yaml @@ -2,29 +2,23 @@ additionalProperties: false properties: token: description: Fill in your Jira API token. You can generate one from your Jira account "settings > security > API tokens". - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: Token - format: string email: description: Fill in your Jira email address. - acceptFormats: - - string + type: string uiOrder: 1 title: Email - format: string base-url: description: Fill in your Jira base URL. For example, if your Jira URL is "https://mycompany.atlassian.net/...", then your base URL is https://mycompany.atlassian.net. - acceptFormats: - - string + type: string uiOrder: 1 title: Base URL - format: string required: - token - email - base-url title: Jira Connection -format: object +type: object diff --git a/pkg/component/application/jira/v0/config/tasks.yaml b/pkg/component/application/jira/v0/config/tasks.yaml index ffa8d24ec..9cefa048e 100644 --- a/pkg/component/application/jira/v0/config/tasks.yaml +++ b/pkg/component/application/jira/v0/config/tasks.yaml @@ -5,132 +5,124 @@ $defs: description: 'The starting index of the returned boards. Base index: 0. Default is 0.' uiOrder: 3 title: Start At - acceptFormats: - - integer - format: integer + type: integer max-results: default: 50 description: The maximum number of boards to return. Default is 50. uiOrder: 4 title: Max Results - acceptFormats: - - integer - format: integer + type: integer update-history: description: Whether the action taken is added to the user's Recent history, as shown under `Your Work` in Jira. title: Update History uiOrder: 5 - acceptFormats: - - boolean - format: boolean + type: boolean issue: properties: id: description: The ID of the issue. uiOrder: 0 title: ID - format: string + type: string key: title: Key description: The key of the issue, e.g. `JRA-1330`. shortDescription: The key of the issue uiOrder: 1 - acceptFormats: - - string - format: string + type: string self: description: The URL of the issue. uiOrder: 2 title: Self - format: string + type: string fields: description: The fields of the issue. All navigable and Agile fields are returned. uiOrder: 3 title: Fields required: [] - format: json + type: json issue-type: description: 'The type of the issue, can be: `Task`, `Epic`.' uiOrder: 4 title: Issue Type - format: string + type: string summary: description: The summary of the issue. uiOrder: 5 title: Summary - format: string + type: string description: description: The description of the issue. uiOrder: 6 title: Description - format: string + type: string status: description: 'The status of the issue, can be: `To Do`, `In Progress`, `Done`.' uiOrder: 7 title: Status - format: string + type: string required: - id - key - self - fields title: Issue - format: object + type: object sprint: properties: id: title: ID description: The ID of the sprint. uiOrder: 0 - format: integer + type: integer self: title: Self description: The URL of the sprint. uiOrder: 1 - format: string + type: string state: title: State description: 'The state of the sprint, can be: `active`, `closed`, `future`.' uiOrder: 2 - format: string + type: string name: title: Name description: The name of the sprint. uiOrder: 3 - format: string + type: string start-date: title: Start Date description: The start date of the sprint, e.g. 2018-03-05 (default 00:00 UTC+0). To adjust your time zone, please provide a more detailed RFC3339 format like `2018-03-05T09:00:00Z0000`. uiOrder: 4 - format: string + type: string end-date: title: End Date description: The end date of the sprint, e.g. 2018-03-05 (default 00:00 UTC+0). To adjust your time zone, please provide a more detailed RFC3339 format like `2018-03-05T09:00:00Z0000`. uiOrder: 5 - format: string + type: string complete-date: title: Complete Date description: The complete date of the sprint, e.g. 2018-03-05 (default 00:00 UTC+0). To adjust your time zone, please provide a more detailed RFC3339 format like `2018-03-05T09:00:00Z0000`. uiOrder: 6 - format: string + type: string origin-board-id: title: Origin Board ID description: The ID of the origin board. uiOrder: 7 - format: integer + type: integer goal: title: Goal description: The Goal of the sprint. uiOrder: 8 - format: string + type: string required: - id - self title: Sprint - format: object + type: object TASK_CREATE_ISSUE: description: Create an issue in Jira. shortDescription: Create an issue in Jira @@ -143,9 +135,7 @@ TASK_CREATE_ISSUE: description: The key of the project, e.g. `INS`. shortDescription: The key of the project uiOrder: 0 - acceptFormats: - - string - format: string + type: string issue-type: title: Issue Type description: 'The type of the issue, can be: `Task`, `Epic`, `Subtask`, etc.' @@ -160,99 +150,91 @@ TASK_CREATE_ISSUE: const: Epic description: Epic. uiOrder: 0 - format: string + type: string required: - issue-type description: Epic. uiOrder: 0 title: Epic - format: object + type: object - properties: issue-type: title: Issue Type const: Task description: Task. uiOrder: 0 - format: string + type: string required: - issue-type description: Task. uiOrder: 0 title: Task - format: object + type: object - properties: issue-type: title: Issue Type const: Subtask description: Subtask. uiOrder: 0 - format: string + type: string parent-key: title: Parent Key description: The key of the parent issue, e.g. `JRA-1330`. shortDescription: The key of the parent issue uiOrder: 10 - acceptFormats: - - string - format: string + type: string required: - issue-type - parent-key description: Subtask. uiOrder: 0 title: Subtask - format: object + type: object - properties: issue-type: title: Issue Type const: Other description: Other. uiOrder: 0 - format: string + type: string custom-issue-type: title: Issue Type description: 'The type of the issue, can be: `Task`, `Epic`, `Subtask`, etc.' shortDescription: The type of the issue uiOrder: 1 - acceptFormats: - - string - format: string + type: string required: - issue-type - custom-issue-type description: Other. uiOrder: 0 title: Other - format: object - format: object + type: object + type: object summary: title: Summary description: The summary of the issue. shortDescription: The summary of the issue uiOrder: 2 - acceptFormats: - - string - format: string + type: string description: title: Description description: The description of the issue. shortDescription: The description of the issue uiOrder: 3 - acceptFormats: - - string - format: string + type: string required: - project-key - issue-type title: Input - format: object + type: object output: description: Create an issue in Jira. uiOrder: 0 $ref: '#/$defs/issue' title: Output - format: object - format: object + type: object + type: object TASK_CREATE_SPRINT: description: Create a sprint in Jira. shortDescription: Create a sprint in Jira @@ -265,43 +247,33 @@ TASK_CREATE_SPRINT: description: The name of the board. shortDescription: The name of the board uiOrder: 0 - acceptFormats: - - string - format: string + type: string name: title: Name description: The name of the sprint. shortDescription: The name of the sprint uiOrder: 1 - acceptFormats: - - string - format: string + type: string goal: title: Goal description: The goal of the sprint. shortDescription: The goal of the sprint uiOrder: 2 - acceptFormats: - - string - format: string + type: string start-date: title: Start Date description: The start date of the sprint, e.g. 2018-03-05 (default 00:00 UTC+0). To adjust your time zone, please provide a more detailed RFC3339 format like `2018-03-05T09:00:00Z0000`. shortDescription: The start date of the sprint uiOrder: 3 - acceptFormats: - - string - format: string + type: string end-date: title: End Date description: The end date of the sprint, e.g. 2018-03-05 (default 00:00 UTC+0). To adjust your time zone, please provide a more detailed RFC3339 format like `2018-03-05T09:00:00Z0000`. shortDescription: The end date of the sprint uiOrder: 4 - acceptFormats: - - string - format: string + type: string required: - board-name - name @@ -309,14 +281,14 @@ TASK_CREATE_SPRINT: - start-date - end-date title: Input - format: object + type: object output: description: Create a sprint in Jira. uiOrder: 0 $ref: '#/$defs/sprint' title: Output - format: object - format: object + type: object + type: object TASK_GET_ISSUE: description: Get an issue in Jira. The issue will only be returned if the user has permission to view it. Issues returned from this resource include Agile fields, like sprint, closedSprints, flagged, and epic. @@ -330,23 +302,21 @@ TASK_GET_ISSUE: description: The key of the issue, e.g. `JRA-1330`. shortDescription: The key of the issue uiOrder: 0 - acceptFormats: - - string - format: string + type: string update-history: $ref: '#/$defs/common-query-params/update-history' uiOrder: 1 required: - issue-key title: Input - format: object + type: object output: description: Get an issue in Jira. uiOrder: 0 $ref: '#/$defs/issue' title: Output - format: object - format: object + type: object + type: object TASK_GET_SPRINT: description: Get a sprint in Jira. The sprint will only be returned if the user can view the board that the sprint was created on, or view at least one of the issues in the sprint. @@ -361,21 +331,19 @@ TASK_GET_SPRINT: of the issues in the sprint. shortDescription: The ID of the sprint uiOrder: 0 - acceptFormats: - - integer - format: integer + type: integer required: - sprint-id title: Input - format: object + type: object output: description: Get an sprint in Jira. uiOrder: 0 $ref: '#/$defs/sprint' required: [] title: Output - format: object - format: object + type: object + type: object TASK_LIST_BOARDS: shortDescription: List all boards in Jira input: @@ -389,9 +357,7 @@ TASK_LIST_BOARDS: to a project. shortDescription: The project key or ID, e.g. `INS`. Default is empty uiOrder: 0 - acceptFormats: - - string - format: string + type: string board-type: default: simple description: 'The type of board, can be: scrum, kanban, simple. Default is simple.' @@ -401,17 +367,13 @@ TASK_LIST_BOARDS: - kanban - simple title: Board Type - acceptFormats: - - string - format: string + type: string name: default: '' description: Name filters results to boards that match or partially match the specified name. Default is empty. uiOrder: 2 title: Name - acceptFormats: - - string - format: string + type: string start-at: $ref: '#/$defs/common-query-params/start-at' uiOrder: 3 @@ -420,7 +382,7 @@ TASK_LIST_BOARDS: uiOrder: 4 required: [] title: Input - format: object + type: object output: description: List all boards in Jira. uiOrder: 0 @@ -435,57 +397,57 @@ TASK_LIST_BOARDS: description: The ID of the board. uiOrder: 0 title: ID - format: integer + type: integer name: description: The name of the board. uiOrder: 1 title: Name - format: string + type: string self: description: The URL of the board. uiOrder: 3 title: Self - format: string + type: string type: description: The type of the board. uiOrder: 2 title: Type - format: string + type: string required: - id - name - type - self - format: object - format: array + type: object + type: array start-at: description: 'The starting index of the returned boards. Base index: 0.' uiOrder: 2 title: Start At - format: integer + type: integer max-results: description: The maximum number of boards. uiOrder: 3 title: Max Results - format: integer + type: integer total: description: The total number of boards. uiOrder: 4 title: Total - format: integer + type: integer is-last: description: Whether the last board is reached. uiOrder: 5 title: Is Last - format: boolean + type: boolean required: - start-at - max-results - total - is-last title: Output - format: object - format: object + type: object + type: object TASK_LIST_ISSUES: description: List issues in Jira. shortDescription: List issues in Jira @@ -498,9 +460,7 @@ TASK_LIST_ISSUES: description: The name of the board. shortDescription: The name of the board uiOrder: 0 - acceptFormats: - - string - format: string + type: string range: title: Range description: Choose the range of issues to return. Default is `all`. @@ -515,133 +475,127 @@ TASK_LIST_ISSUES: const: All description: All issues. uiOrder: 0 - format: string + type: string required: - range description: All issues. uiOrder: 0 title: All - format: object + type: object - properties: range: title: Range const: Standard Issues description: Standard issues. uiOrder: 0 - format: string + type: string required: - range description: Standard issues. uiOrder: 0 title: Standard Issues - format: object + type: object - properties: range: title: Range const: Epics only description: Epics only. uiOrder: 0 - format: string + type: string required: - range description: Epics only. uiOrder: 0 title: Epics only - format: object + type: object - properties: range: title: Range const: In backlog only description: In backlog only. uiOrder: 0 - format: string + type: string required: - range description: In backlog only. uiOrder: 0 title: In Backlog Only - format: object + type: object - properties: range: title: Range const: Issues of an epic description: Issues of an epic. uiOrder: 0 - format: string + type: string epic-key: title: Epic Key description: The Key of the epic, e.g. `JRA-1330`. shortDescription: The Key of the epic uiOrder: 10 - acceptFormats: - - string - format: string + type: string required: - range - epic-key description: Issues of an epic. uiOrder: 0 title: Issues of an Epic - format: object + type: object - properties: range: title: Range const: Issues of a sprint description: Issues of a sprint. uiOrder: 0 - format: string + type: string sprint-name: title: Sprint Name description: The name of the sprint. shortDescription: The Name of the sprint uiOrder: 10 - acceptFormats: - - string - format: string + type: string required: - range - sprint-name description: Issues of a sprint. uiOrder: 0 title: Issues of a Sprint - format: object + type: object - properties: range: title: Range const: Issues without epic assigned description: Issues without epic assigned. uiOrder: 0 - format: string + type: string required: - range description: Issues without Epic Assigned. uiOrder: 0 title: Issues without Epic Assigned - format: object + type: object - properties: range: title: Range const: JQL query description: JQL query. uiOrder: 0 - format: string + type: string jql: title: JQL description: The JQL query. For example, `type = "Task" AND status = "Done"`. For more information, see Advanced searching. shortDescription: The JQL query uiOrder: 10 - acceptFormats: - - string - format: string + type: string required: - range - jql description: JQL query. uiOrder: 0 title: JQL Query - format: object - format: object + type: object + type: object start-at: $ref: '#/$defs/common-query-params/start-at' uiOrder: 3 @@ -651,7 +605,7 @@ TASK_LIST_ISSUES: required: - board-name title: Input - format: object + type: object output: description: Get issues in Jira. uiOrder: 0 @@ -662,29 +616,29 @@ TASK_LIST_ISSUES: title: Issues items: $ref: '#/$defs/issue' - format: array + type: array start-at: description: 'The starting index of the returned boards. Base index: 0.' uiOrder: 2 title: Start At - format: integer + type: integer max-results: description: The maximum number of boards. uiOrder: 3 title: Max Results - format: integer + type: integer total: description: The total number of boards. uiOrder: 4 title: Total - format: integer + type: integer required: - start-at - max-results - total title: Output - format: object - format: object + type: object + type: object TASK_LIST_SPRINTS: description: List sprints in Jira. shortDescription: List sprints in Jira @@ -697,9 +651,7 @@ TASK_LIST_SPRINTS: description: The ID of the board. shortDescription: The ID of the board uiOrder: 0 - acceptFormats: - - integer - format: integer + type: integer start-at: $ref: '#/$defs/common-query-params/start-at' uiOrder: 1 @@ -709,7 +661,7 @@ TASK_LIST_SPRINTS: required: - board-id title: Input - format: object + type: object output: description: Get sprints in Jira. uiOrder: 0 @@ -720,29 +672,29 @@ TASK_LIST_SPRINTS: title: Sprints items: $ref: '#/$defs/sprint' - format: array + type: array start-at: description: 'The starting index of the returned boards. Base index: 0.' uiOrder: 2 title: Start At - format: integer + type: integer max-results: description: The maximum number of boards. uiOrder: 3 title: Max Results - format: integer + type: integer total: description: The total number of boards. uiOrder: 4 title: Total - format: integer + type: integer required: - start-at - max-results - total title: Output - format: object - format: object + type: object + type: object TASK_UPDATE_ISSUE: description: Update an issue in Jira. shortDescription: Update an issue in Jira @@ -758,9 +710,7 @@ TASK_UPDATE_ISSUE: title: Notify Users description: Whether to notify users. uiOrder: 1 - acceptFormats: - - boolean - format: boolean + type: boolean update: title: Update description: Update an issue in Jira. @@ -775,12 +725,11 @@ TASK_UPDATE_ISSUE: const: Custom Update description: Custom update. uiOrder: 0 - format: string + type: string update-fields: title: Update Fields description: The fields to update. - acceptFormats: - - array + type: array items: properties: action: @@ -793,64 +742,61 @@ TASK_UPDATE_ISSUE: - set uiOrder: 3 title: Action - format: string + type: string field-name: description: The name of the field to update. uiOrder: 4 title: Field Name - format: string + type: string value: description: The value of the field to update. uiOrder: 5 title: Value - format: string + type: string required: - action - field-name - format: object + type: object uiOrder: 1 - format: array required: - update - update-fields description: Custom update. uiOrder: 0 title: Custom Update - format: object + type: object - properties: update: title: Update const: Move Issue to Epic description: Move issue to epic. uiOrder: 0 - format: string + type: string epic-key: title: Epic Key description: The key of the epic, e.g. `JRA-1330`. shortDescription: The key of the epic uiOrder: 11 - acceptFormats: - - string - format: string + type: string required: - update - epic-key description: Move issue to epic. uiOrder: 0 title: Move Issue to Epic - format: object - format: object + type: object + type: object required: - issue-key title: Input - format: object + type: object output: description: Update an issue in Jira. uiOrder: 0 $ref: '#/$defs/issue' title: Output - format: object - format: object + type: object + type: object TASK_UPDATE_SPRINT: description: Update a sprint in Jira. shortDescription: Update a sprint in Jira @@ -863,59 +809,45 @@ TASK_UPDATE_SPRINT: description: The ID of the sprint. shortDescription: The ID of the sprint uiOrder: 0 - acceptFormats: - - integer - format: integer + type: integer name: title: Name description: The name of the sprint. shortDescription: The name of the sprint uiOrder: 1 - acceptFormats: - - string - format: string + type: string goal: title: Goal description: The goal of the sprint. shortDescription: The goal of the sprint uiOrder: 2 - acceptFormats: - - string - format: string + type: string start-date: title: Start Date description: The start date of the sprint, e.g. 2018-03-05 (default 00:00 UTC+0). To adjust your time zone, please provide a more detailed RFC3339 format like `2018-03-05T09:00:00Z0000`. shortDescription: The start date of the sprint uiOrder: 3 - acceptFormats: - - string - format: string + type: string end-date: title: End Date description: The end date of the sprint, e.g. 2018-03-05 (default 00:00 UTC+0). To adjust your time zone, please provide a more detailed RFC3339 format like `2018-03-05T09:00:00Z0000`. shortDescription: The end date of the sprint uiOrder: 4 - acceptFormats: - - string - format: string + type: string current-state: title: Current State description: 'The current state of the sprint, can be: `future`, `active`, `closed`.' shortDescription: The current state of the sprint uiOrder: 5 - acceptFormats: - - string - format: string + type: string enter-next-state: title: Enter Next State description: Whether to enter the next state. If `true`, the sprint will enter the next state, i.e., `future` -> `active` -> `closed`. shortDescription: Whether to enter the next state uiOrder: 6 - acceptFormats: - - boolean - format: boolean + type: boolean required: - sprint-id - name @@ -923,11 +855,11 @@ TASK_UPDATE_SPRINT: - end-date - current-state title: Input - format: object + type: object output: description: Update a sprint in Jira. uiOrder: 0 $ref: '#/$defs/sprint' title: Output - format: object - format: object + type: object + type: object diff --git a/pkg/component/application/leadiq/v0/.compogen/bottom.mdx b/pkg/component/application/leadiq/v0/.compogen/bottom.mdx index 6071d7439..e87b4738e 100644 --- a/pkg/component/application/leadiq/v0/.compogen/bottom.mdx +++ b/pkg/component/application/leadiq/v0/.compogen/bottom.mdx @@ -7,23 +7,23 @@ version: v1beta variable: city: title: City - format: string + type: string default: "London" country: title: Country - format: string + type: string default: "United Kingdom" industry: title: Industry - format: string + type: string default: "Software Development" description: title: Description - format: string + type: string default: "AI" technology: title: Technology - format: string + type: string default: "HTTP" component: diff --git a/pkg/component/application/leadiq/v0/README.mdx b/pkg/component/application/leadiq/v0/README.mdx index a1b3c3651..4916c9a05 100644 --- a/pkg/component/application/leadiq/v0/README.mdx +++ b/pkg/component/application/leadiq/v0/README.mdx @@ -36,7 +36,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key (required) | `api-key` | string | Fill in your LeadIQ Secret Base64 API key, you can find it in [API Key](https://account.leadiq.com/app/settings/api-keys). | @@ -54,7 +54,7 @@ Find prospects' contact information based on the company name you provide. And,
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_FIND_PROSPECTS` | | [Company](#find-prospects-company) (required) | `company` | object | Provide the company information for which you want to find prospects. | @@ -72,7 +72,7 @@ Provide the company information for which you want to find prospects.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Cities | `cities` | array | Provide the cities of the company you want to find prospects. If you don't provide any value, it will return all the prospects. | | Countries | `countries` | array | Provide the countries of the company you want to find prospects. If you don't provide any value, it will return all the prospects. | @@ -89,7 +89,7 @@ Provide the min or max revenue size of the company you want to find prospects. I
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Max | `max` | integer | Provide the maximum revenue size of the company you want to find prospects. | | Min | `min` | integer | Provide the minimum revenue size of the company you want to find prospects. | @@ -100,7 +100,7 @@ Provide the information about the prospects you want to filter. You can filter t
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Function | `function` | string | Provide the function of the prospects you want to filter with [regular expression](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_expressions). | | Job Title | `job-title` | string | Provide the job title of the prospects you want to filter with [regular expression](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_expressions). | @@ -112,7 +112,7 @@ Provide the information about the prospects you want to filter. You can filter t
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Prospects](#find-prospects-prospects) (optional) | `prospects` | array[object] | The list of prospects' contact information based on the company information you provide. |
@@ -124,7 +124,7 @@ Provide the information about the prospects you want to filter. You can filter t
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Company Address | `company-address` | string | The address of the company from LeadIQ. It combines the city, state, and country. | | Company Description | `company-description` | string | The description of the company from LeadIQ. | @@ -144,7 +144,7 @@ Provide the information about the prospects you want to filter. You can filter t
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Description | `description` | string | The description of the revenue size of the company from LeadIQ. | | Max | `max` | integer | The maximum revenue size of the company from LeadIQ. | @@ -186,23 +186,23 @@ version: v1beta variable: city: title: City - format: string + type: string default: "London" country: title: Country - format: string + type: string default: "United Kingdom" industry: title: Industry - format: string + type: string default: "Software Development" description: title: Description - format: string + type: string default: "AI" technology: title: Technology - format: string + type: string default: "HTTP" component: diff --git a/pkg/component/application/leadiq/v0/config/setup.yaml b/pkg/component/application/leadiq/v0/config/setup.yaml index c625699ab..c79a044e0 100644 --- a/pkg/component/application/leadiq/v0/config/setup.yaml +++ b/pkg/component/application/leadiq/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: api-key: description: Fill in your LeadIQ Secret Base64 API key, you can find it in [API Key](https://account.leadiq.com/app/settings/api-keys). - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: API Key - format: string required: - api-key title: LeadIQ Connection -format: object +type: object diff --git a/pkg/component/application/leadiq/v0/config/tasks.yaml b/pkg/component/application/leadiq/v0/config/tasks.yaml index 8081d7c13..08d32ef48 100644 --- a/pkg/component/application/leadiq/v0/config/tasks.yaml +++ b/pkg/component/application/leadiq/v0/config/tasks.yaml @@ -14,10 +14,8 @@ TASK_FIND_PROSPECTS: names: title: Names description: Provide the company names for which you want to find prospects. - acceptFormats: - - array + type: array uiOrder: 0 - format: array revenue-size: title: Revenue Size description: Provide the min or max revenue size of the company you want to find prospects. If you don't provide any value, it will return all @@ -26,67 +24,51 @@ TASK_FIND_PROSPECTS: min: title: Min description: Provide the minimum revenue size of the company you want to find prospects. - acceptFormats: - - integer + type: integer uiOrder: 0 - format: integer max: title: Max description: Provide the maximum revenue size of the company you want to find prospects. - acceptFormats: - - integer + type: integer uiOrder: 1 - format: integer required: [] uiOrder: 1 - format: object + type: object countries: title: Countries description: Provide the countries of the company you want to find prospects. If you don't provide any value, it will return all the prospects. - acceptFormats: - - array + type: array uiOrder: 2 - format: array states: title: States description: Provide the states of the company you want to find prospects. If you don't provide any value, it will return all the prospects. - acceptFormats: - - array + type: array uiOrder: 3 - format: array cities: title: Cities description: Provide the cities of the company you want to find prospects. If you don't provide any value, it will return all the prospects. - acceptFormats: - - array + type: array uiOrder: 4 - format: array industries: title: Industries description: Provide the industries of the company you want to find prospects. If you don't provide any value, it will return all the prospects. - acceptFormats: - - array + type: array uiOrder: 5 - format: array descriptions: title: Descriptions description: Provide the descriptions of the company you want to find prospects. In LeadIQ, it will return the similar companies based on the descriptions. - acceptFormats: - - array + type: array uiOrder: 6 - format: array technologies: title: Technologies description: Provide the technologies used by the company you want to find prospects. If you don't provide any value, it will return all the prospects. - acceptFormats: - - array + type: array uiOrder: 7 - format: array required: [] uiOrder: 0 - format: object + type: object limit: title: Limit description: Provide the number of prospects you want to find. If you don't provide any value, it will return 10 prospects. The maximum limit is @@ -94,10 +76,8 @@ TASK_FIND_PROSPECTS: default: 10 maximum: 60 minimum: 1 - acceptFormats: - - integer + type: integer uiOrder: 1 - format: integer filter-by: title: Filter By description: Provide the information about the prospects you want to filter. You can filter the prospects based on job title, name, seniority, and @@ -106,15 +86,12 @@ TASK_FIND_PROSPECTS: job-title: title: Job Title description: Provide the job title of the prospects you want to filter with [regular expression](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_expressions). - acceptFormats: - - string + type: string uiOrder: 0 - format: string seniorities: title: Seniorities description: Provide the seniorities of the prospects you want to filter. - acceptFormats: - - array + type: array enum: - Executive - Director @@ -123,22 +100,19 @@ TASK_FIND_PROSPECTS: - Manager - Other uiOrder: 1 - format: array function: title: Function description: Provide the function of the prospects you want to filter with [regular expression](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_expressions). - acceptFormats: - - string + type: string uiOrder: 2 - format: string required: [] uiOrder: 2 - format: object + type: object uiOrder: 0 required: - company - limit - format: object + type: object output: title: Output description: The output will be the list of prospects' contact information based on the company name you provide. It will include the name, job title, @@ -153,57 +127,57 @@ TASK_FIND_PROSPECTS: title: Name description: The name of the prospect. uiOrder: 0 - format: string + type: string job-title: title: Job Title description: The job title of the prospect. uiOrder: 1 - format: string + type: string seniority: title: Seniority description: The seniority of the prospect. uiOrder: 2 - format: string + type: string email: title: Email description: The email address of the prospect. uiOrder: 3 - format: string + type: string linkedin-url: title: LinkedIn URL description: The LinkedIn URL of the prospect. uiOrder: 4 - format: string + type: string company-name: title: Company Name description: The company name of the prospect. uiOrder: 5 - format: string + type: string company-description: title: Company Description description: The description of the company from LeadIQ. uiOrder: 6 - format: string + type: string company-industry: title: Company Industry description: The industry of the company from LeadIQ. uiOrder: 7 - format: string + type: string company-address: title: Company Address description: The address of the company from LeadIQ. It combines the city, state, and country. uiOrder: 8 - format: string + type: string company-technologies: title: Company Technologies description: The technologies used by the company from LeadIQ. uiOrder: 9 - format: array + type: array company-technology-categories: title: Company Technology Categories description: The technology categories of the company from LeadIQ. uiOrder: 10 - format: array + type: array revenue-size: title: Revenue Size description: The revenue size of the company from LeadIQ. @@ -211,29 +185,25 @@ TASK_FIND_PROSPECTS: min: title: Min description: The minimum revenue size of the company from LeadIQ. - acceptFormats: - - integer + type: integer uiOrder: 0 - format: integer max: title: Max description: The maximum revenue size of the company from LeadIQ. - acceptFormats: - - integer + type: integer uiOrder: 1 - format: integer description: title: Description description: The description of the revenue size of the company from LeadIQ. uiOrder: 2 - format: string + type: string required: [] uiOrder: 11 - format: object + type: object required: [] - format: object + type: object uiOrder: 0 - format: array + type: array required: [] uiOrder: 1 - format: object + type: object diff --git a/pkg/component/application/numbers/v0/README.mdx b/pkg/component/application/numbers/v0/README.mdx index c232a878d..71b86f6e3 100644 --- a/pkg/component/application/numbers/v0/README.mdx +++ b/pkg/component/application/numbers/v0/README.mdx @@ -36,7 +36,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Capture Token (required) | `capture-token` | string | Fill in your Capture token in the Capture App. To access your tokens, you need a Capture App account and you can sign in with email or wallet to acquire the Capture Token. | @@ -54,7 +54,7 @@ Register a file into NumbersProtocol Chain.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_REGISTER` | | Images (required) | `images` | array[string] | The images you want to upload to blockchain. | @@ -77,7 +77,7 @@ License.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | License Document | `document` | string | URL of the license file. | | License Name | `name` | string | License of the asset file. | @@ -88,7 +88,7 @@ License.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Asset URLs | `asset-urls` | array[string] | Asset Urls. |
diff --git a/pkg/component/application/numbers/v0/config/setup.yaml b/pkg/component/application/numbers/v0/config/setup.yaml index 6898b3c5f..f408b26f5 100644 --- a/pkg/component/application/numbers/v0/config/setup.yaml +++ b/pkg/component/application/numbers/v0/config/setup.yaml @@ -3,13 +3,11 @@ properties: capture-token: description: Fill in your Capture token in the Capture App. To access your tokens, you need a Capture App account and you can sign in with email or wallet to acquire the Capture Token. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: Capture token - format: string required: - capture-token title: Numbers Protocol Connection -format: object +type: object diff --git a/pkg/component/application/numbers/v0/config/tasks.yaml b/pkg/component/application/numbers/v0/config/tasks.yaml index b79bdceba..573098477 100644 --- a/pkg/component/application/numbers/v0/config/tasks.yaml +++ b/pkg/component/application/numbers/v0/config/tasks.yaml @@ -6,35 +6,27 @@ TASK_REGISTER: properties: images: description: The images you want to upload to blockchain. - acceptFormats: - - array + type: array uiOrder: 0 items: contentEncoding: base64 - format: string + type: string title: Images - format: array headline: description: Headline of the asset. - acceptFormats: - - string + type: string uiOrder: 2 title: Headline - format: string caption: description: Caption of the asset. - acceptFormats: - - string + type: string uiOrder: 1 title: Caption - format: string asset-creator: description: Name of the asset creator. - acceptFormats: - - string + type: string uiOrder: 2 title: Asset Creator - format: string digital-source-type: default: trainedAlgorithmicMedia description: Specify the type of the source. More details here. @@ -44,40 +36,32 @@ TASK_REGISTER: - digitalCapture - digitalArt - algorithmicMedia - acceptFormats: - - string + type: string uiOrder: 5 title: Digital Source Type - format: string generated-by: description: The AI model used to generate the content. - acceptFormats: - - string + type: string uiOrder: 6 title: Generated By - format: string license: description: License. uiOrder: 7 properties: document: description: URL of the license file. - acceptFormats: - - string + type: string instillEnableCopyButton: true uiOrder: 0 title: License Document - format: string name: description: License of the asset file. - acceptFormats: - - string + type: string uiOrder: 1 title: License Name - format: string required: [] title: License - format: object + type: object mining-preference: default: notAllowed description: Designates the selection made by the asset creators or licensed owners to decide if the asset is suitable for inclusion in a data mining @@ -90,16 +74,14 @@ TASK_REGISTER: - aiGenerativeTrainingWithAuthorship - aiTraining - aiTrainingWithAuthorship - acceptFormats: - - string + type: string shortDescription: Designates the selection made by the asset creators or licensed owners. More details here uiOrder: 8 title: Mining Preference - format: string required: - images title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -111,10 +93,10 @@ TASK_REGISTER: items: instillEnableCopyButton: true title: Asset Url - format: string + type: string title: Asset Urls - format: array + type: array required: - asset-urls title: Output - format: object + type: object diff --git a/pkg/component/application/slack/v0/.compogen/bottom.mdx b/pkg/component/application/slack/v0/.compogen/bottom.mdx index ad652d867..63f10c3a4 100644 --- a/pkg/component/application/slack/v0/.compogen/bottom.mdx +++ b/pkg/component/application/slack/v0/.compogen/bottom.mdx @@ -76,17 +76,17 @@ on: variable: message: title: message - format: string + type: string listen: - ${on.slack-0.message.text} user: title: user - format: string + type: string listen: - ${on.slack-0.message.user.name} channel: title: channel - format: string + type: string listen: - ${on.slack-0.message.channel.name} diff --git a/pkg/component/application/slack/v0/README.mdx b/pkg/component/application/slack/v0/README.mdx index 5e052172e..6eb863777 100644 --- a/pkg/component/application/slack/v0/README.mdx +++ b/pkg/component/application/slack/v0/README.mdx @@ -37,7 +37,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Bot OAuth Token (required) | `bot-token` | string | Token associated to the application bot. | | User OAuth Token | `user-token` | string | Token to act on behalf of a Slack user. | @@ -78,7 +78,7 @@ Get the latest message since specific date
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_READ_MESSAGE` | | Channel Name (required) | `channel-name` | string | Channel name, as displayed on Slack. | @@ -92,7 +92,7 @@ Get the latest message since specific date
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Conversations](#read-message-conversations) | `conversations` | array[object] | An array of conversations with thread messages. |
@@ -104,7 +104,7 @@ Get the latest message since specific date
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Last Date | `last-date` | string | Date of the last message. | | Start Conversation Message | `message` | string | message to start a conversation. | @@ -118,7 +118,7 @@ Get the latest message since specific date
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Replied Time | `datetime` | string | replied datetime. | | Replied Message | `message` | string | message to reply a conversation. | @@ -134,7 +134,7 @@ send message to a specific channel
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_WRITE_MESSAGE` | | Channel Name (required) | `channel-name` | string | Channel name, as displayed on Slack. | @@ -149,7 +149,7 @@ send message to a specific channel
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Result | `result` | string | Result of the message delivery. |
@@ -234,17 +234,17 @@ on: variable: message: title: message - format: string + type: string listen: - ${on.slack-0.message.text} user: title: user - format: string + type: string listen: - ${on.slack-0.message.user.name} channel: title: channel - format: string + type: string listen: - ${on.slack-0.message.channel.name} diff --git a/pkg/component/application/slack/v0/config/events.yaml b/pkg/component/application/slack/v0/config/events.yaml index ba33e2aed..246de1074 100644 --- a/pkg/component/application/slack/v0/config/events.yaml +++ b/pkg/component/application/slack/v0/config/events.yaml @@ -7,16 +7,16 @@ EVENT_NEW_MESSAGE: description: Names of the Slack channels to listen to. title: Channel Names items: - format: string - format: array - format: object + type: string + type: array + type: object messageSchema: description: A new message event from Slack. properties: timestamp: description: Timestamp of the message. title: Timestamp - format: string + type: string channel: description: Channel information. uiOrder: 1 @@ -24,16 +24,16 @@ EVENT_NEW_MESSAGE: id: description: Unique ID of the Slack channel. title: Channel ID - format: string + type: string name: description: Name of the Slack channel. title: Channel Name - format: string + type: string required: - id - name title: Channel - format: object + type: object user: description: User information. uiOrder: 2 @@ -41,44 +41,44 @@ EVENT_NEW_MESSAGE: id: description: Unique ID of the Slack user. title: User ID - format: string + type: string name: description: Username of the Slack user. title: User Name - format: string + type: string real-name: description: Real name of the Slack user. title: Real Name - format: string + type: string profile: description: User profile information. properties: display-name: description: Display name of the Slack user. title: Display Name - format: string + type: string required: - display-name title: Profile - format: object + type: object required: - id - name - real-name - profile title: User - format: object + type: object text: description: Content of the message. title: Message Text - format: string + type: string required: - timestamp - channel - user - text title: New Message Event - format: object + type: object messageExamples: - timestamp: '1715159446.644219' channel: diff --git a/pkg/component/application/slack/v0/config/setup.yaml b/pkg/component/application/slack/v0/config/setup.yaml index 11e049196..46d289d56 100644 --- a/pkg/component/application/slack/v0/config/setup.yaml +++ b/pkg/component/application/slack/v0/config/setup.yaml @@ -2,20 +2,16 @@ additionalProperties: false properties: bot-token: description: Token associated to the application bot. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: Bot OAuth Token - format: string user-token: description: Token to act on behalf of a Slack user. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 1 title: User OAuth Token - format: string required: - bot-token instillOAuthConfig: @@ -31,4 +27,4 @@ instillOAuthConfig: - users:read.email - users.profile:read title: Slack Connection -format: object +type: object diff --git a/pkg/component/application/slack/v0/config/tasks.yaml b/pkg/component/application/slack/v0/config/tasks.yaml index 30b5dc98c..762637a43 100644 --- a/pkg/component/application/slack/v0/config/tasks.yaml +++ b/pkg/component/application/slack/v0/config/tasks.yaml @@ -3,12 +3,12 @@ $defs: description: unique id from Slack. uiOrder: 0 title: User UID - format: string + type: string user-name: description: user name in Slack. uiOrder: 1 title: User Name - format: string + type: string TASK_READ_MESSAGE: shortDescription: Get the latest message since specific date input: @@ -17,23 +17,19 @@ TASK_READ_MESSAGE: properties: channel-name: description: Channel name, as displayed on Slack. - acceptFormats: - - string + type: string uiOrder: 0 title: Channel Name - format: string start-to-read-date: description: Date (in `YYYY-MM-DD` format) from which messages will start to be fetched. If not provided, it will be 7 days before the current date. The date will be in the UTC timezone. - acceptFormats: - - string + type: string uiOrder: 1 title: Start to read date - format: string required: - channel-name title: Input - format: object + type: object output: description: All messages in Slack channel. uiOrder: 0 @@ -53,19 +49,19 @@ TASK_READ_MESSAGE: description: message to start a conversation. uiOrder: 2 title: Start Conversation Message - format: string + type: string start-date: description: when a conversation starts. uiOrder: 3 required: [] title: Start Date - format: string + type: string last-date: description: Date of the last message. uiOrder: 4 required: [] title: Last Date - format: string + type: string thread-reply-messages: description: replies in a conversation. uiOrder: 5 @@ -81,28 +77,28 @@ TASK_READ_MESSAGE: description: replied datetime. uiOrder: 2 title: Replied Time - format: string + type: string message: description: message to reply a conversation. uiOrder: 3 title: Replied Message - format: string + type: string required: - user-id - datetime - message - format: object - format: array + type: object + type: array required: - user-id - message - start-date - format: object - format: array + type: object + type: array required: - conversations title: Output - format: object + type: object TASK_WRITE_MESSAGE: shortDescription: send message to a specific channel title: Send Message @@ -112,31 +108,25 @@ TASK_WRITE_MESSAGE: properties: channel-name: description: Channel name, as displayed on Slack. - acceptFormats: - - string + type: string uiOrder: 0 title: Channel Name - format: string message: description: The message to be sent to the target channel. - acceptFormats: - - string + type: string uiOrder: 1 title: Message - format: string as-user: default: false description: Send the message on behalf of the user identified by the setup.user-token field. uiOrder: 2 title: Send As User - acceptFormats: - - boolean - format: boolean + type: boolean required: - channel-name - message title: Input - format: object + type: object output: description: The greeting sentence. uiOrder: 0 @@ -146,8 +136,8 @@ TASK_WRITE_MESSAGE: uiOrder: 0 required: [] title: Result - format: string + type: string required: - result title: Output - format: object + type: object diff --git a/pkg/component/application/smartlead/v0/.compogen/bottom.mdx b/pkg/component/application/smartlead/v0/.compogen/bottom.mdx index 905d77e28..f25e2b936 100644 --- a/pkg/component/application/smartlead/v0/.compogen/bottom.mdx +++ b/pkg/component/application/smartlead/v0/.compogen/bottom.mdx @@ -9,40 +9,40 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string timezone: title: Timezone - format: string + type: string days-of-week: title: Days of Week - format: array:string + type: array:string start-hour: title: Start Hour - format: string + type: string end-hour: title: End Hour - format: string + type: string schedule-start-time: title: Schedule Start Time - format: string + type: string stop-lead-settings: title: Stop Lead Settings - format: string + type: string send-as-plain-text: title: Send as Plain Text - format: boolean + type: boolean min-time-btw-emails: title: Min Time Between Emails - format: number + type: number max-new-leads-per-day: title: Max New Leads Per Days - format: number + type: number email-body: title: Email Body - format: string + type: string subject: title: Subject - format: string + type: string component: create-campaign: @@ -114,25 +114,25 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string company: title: Company - format: string + type: string custom-keys: title: Custom Keys - format: array:string + type: array:string custom-values: title: Custom Values - format: array:string + type: array:string emails: title: Emails - format: array:string + type: array:string first-names: title: First Names - format: array:string + type: array:string last-names: title: Last Names - format: array:string + type: array:string component: @@ -179,13 +179,13 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string email: title: Email - format: string + type: string status: title: Status - format: string + type: string component: add-sender: @@ -228,7 +228,7 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string component: create-campaign: @@ -257,34 +257,34 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string timezone: title: Timezone - format: string + type: string days-of-week: title: Days of Week - format: array:string + type: array:string start-hour: title: Start Hour - format: string + type: string end-hour: title: End Hour - format: string + type: string schedule-start-time: title: Schedule Start Time - format: string + type: string stop-lead-settings: title: Stop Lead Settings - format: string + type: string send-as-plain-text: title: Send as Plain Text - format: boolean + type: boolean min-time-btw-emails: title: Min Time Between Emails - format: number + type: number max-new-leads-per-day: title: Max New Leads Per Days - format: number + type: number component: setup-campaign: @@ -323,7 +323,7 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string component: get-sequence: @@ -350,13 +350,13 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string email-body: title: Email Body - format: string + type: string subject: title: Subject - format: string + type: string component: save-sequence: @@ -391,16 +391,16 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string company: title: Company - format: string + type: string subject: title: Subject - format: string + type: string body: title: Body - format: string + type: string component: add-leads: @@ -442,10 +442,10 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string email: title: Email - format: string + type: string component: add-sender: @@ -472,10 +472,10 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string status: title: Status - format: string + type: string component: update-campaign-status: @@ -502,7 +502,7 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string component: @@ -529,10 +529,10 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string limit: title: Limit - format: number + type: number component: get-leads: diff --git a/pkg/component/application/smartlead/v0/README.mdx b/pkg/component/application/smartlead/v0/README.mdx index bf7ee7755..a2762906c 100644 --- a/pkg/component/application/smartlead/v0/README.mdx +++ b/pkg/component/application/smartlead/v0/README.mdx @@ -53,7 +53,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key (required) | `api-key` | string | Fill in your Smartlead API key. You can generate one from your [Smartlead account](https://app.smartlead.ai/app/settings/profile). | @@ -71,7 +71,7 @@ Create a new campaign. You have to create a campaign before you can start adding
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_CAMPAIGN` | | Name (required) | `name` | string | Name of the campaign. | @@ -84,7 +84,7 @@ Create a new campaign. You have to create a campaign before you can start adding
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | ID | `id` | string | ID of the campaign. | | Created At | `created-at` | string | Created at timestamp of the campaign. | @@ -97,7 +97,7 @@ Setup a campaign. You can update campaign settings to this campaign. For Smartle
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SETUP_CAMPAIGN` | | Campaign Name (required) | `campaign-name` | string | Name of the campaign. | @@ -123,7 +123,7 @@ Setup a campaign. You can update campaign settings to this campaign. For Smartle
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Result (optional) | `result` | string | Result of setting up a campaign. |
@@ -135,7 +135,7 @@ Save sequences to a campaign. A Smartlead sequence is a series of automated emai
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SAVE_SEQUENCES` | | Campaign Name (required) | `campaign-name` | string | Name of the campaign. | @@ -152,7 +152,7 @@ A Smartlead sequence is a series of automated emails sent to potential customers
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Email Body | `email-body` | string | Body of the email. If you want to set the variable according to different leads, you can use `{{variable_name}}`. It will be replaced by the actual value from the lead. | | Sequence Number | `seq-number` | number | Sequence number means the order of the sequence. If you don't specify this, it will be automatically assigned by the order of the sequences. | @@ -165,7 +165,7 @@ A Smartlead sequence is a series of automated emails sent to potential customers
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Result | `result` | string | Result of saving sequences. |
@@ -177,7 +177,7 @@ Get sequences of a campaign. If you want to add more sequences to the campaign,
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_SEQUENCES` | | Campaign Name (required) | `campaign-name` | string | Name of the campaign. | @@ -190,7 +190,7 @@ Get sequences of a campaign. If you want to add more sequences to the campaign,
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Sequences](#get-sequences-sequences) | `sequences` | array[object] | Sequences of the campaign. |
@@ -202,7 +202,7 @@ Get sequences of a campaign. If you want to add more sequences to the campaign,
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Email Body | `email-body` | string | Body of the email when you save the sequence. | | Sequence ID | `seq-id` | string | ID of the sequence. | @@ -219,7 +219,7 @@ Add leads to a campaign.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_ADD_LEADS` | | Campaign Name (required) | `campaign-name` | string | Name of the campaign. | @@ -237,7 +237,7 @@ Leads to add to the campaign.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Company | `company` | string | Company name of the lead. | | Custom Fields | `custom-fields` | array | Custom fields of the lead. You can use custom fields to store additional information about the lead, which can be used in the variable in the sequence email template. | @@ -252,7 +252,7 @@ Settings for adding leads.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Ignore Community Bounce List | `ignore-community-bounce-list` | boolean | Ignore the community bounce list and add the lead. If true, uploaded leads will BYPASS any leads that bounced across Smartlead entire user base and be uploaded to the campaign. | | Ignore Duplicate Leads in Other Campaign | `ignore-duplicate-leads-in-other-campaign` | boolean | Ignore duplicate leads in other campaigns and add the lead. If true, leads will NOT BYPASS the comparison with other campaigns and NOT be added to the campaign if they are part of any other campaign. | @@ -265,7 +265,7 @@ Settings for adding leads.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Upload Count | `upload-count` | number | Number of leads uploaded. | | Total Leads | `total-leads` | number | Total number of leads in the campaign. | @@ -281,7 +281,7 @@ Add a sender email to the campaign. You have to configure the sender email in Sm
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_ADD_SENDER_EMAIL` | | Campaign Name (required) | `campaign-name` | string | Name of the campaign. | @@ -295,7 +295,7 @@ Add a sender email to the campaign. You have to configure the sender email in Sm
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Result | `result` | string | Result of adding a sender email. If you don't configure your sender email in Smartlead console, you will get an error. |
@@ -307,7 +307,7 @@ Update the status of a campaign. You need to start a campaign to send the emails
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE_CAMPAIGN_STATUS` | | Campaign Name (required) | `campaign-name` | string | Name of the campaign. | @@ -321,7 +321,7 @@ Update the status of a campaign. You need to start a campaign to send the emails
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Result | `result` | string | Result of updating the status of a campaign. |
@@ -333,7 +333,7 @@ Get the metrics of a campaign. You can get the metrics like open count, click co
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_CAMPAIGN_METRIC` | | Campaign Name (required) | `campaign-name` | string | Name of the campaign. | @@ -346,7 +346,7 @@ Get the metrics of a campaign. You can get the metrics like open count, click co
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Sent Count (optional) | `sent-count` | number | Number of emails sent. | | Unique Sent Count (optional) | `unique-sent-count` | number | Number of unique emails sent. | @@ -366,7 +366,7 @@ List the status of leads in a campaign. You can get the status of leads like 'ST
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_LIST_LEADS_STATUS` | | Campaign Name (required) | `campaign-name` | string | Name of the campaign. | @@ -380,7 +380,7 @@ List the status of leads in a campaign. You can get the status of leads like 'ST
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Leads](#list-leads-status-leads) | `leads` | array[object] | Lead status in the campaign. |
@@ -392,7 +392,7 @@ List the status of leads in a campaign. You can get the status of leads like 'ST
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Email | `email` | string | Email of the lead. | | Status | `status` | string | Status of the lead. | @@ -412,40 +412,40 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string timezone: title: Timezone - format: string + type: string days-of-week: title: Days of Week - format: array:string + type: array:string start-hour: title: Start Hour - format: string + type: string end-hour: title: End Hour - format: string + type: string schedule-start-time: title: Schedule Start Time - format: string + type: string stop-lead-settings: title: Stop Lead Settings - format: string + type: string send-as-plain-text: title: Send as Plain Text - format: boolean + type: boolean min-time-btw-emails: title: Min Time Between Emails - format: number + type: number max-new-leads-per-day: title: Max New Leads Per Days - format: number + type: number email-body: title: Email Body - format: string + type: string subject: title: Subject - format: string + type: string component: create-campaign: @@ -517,25 +517,25 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string company: title: Company - format: string + type: string custom-keys: title: Custom Keys - format: array:string + type: array:string custom-values: title: Custom Values - format: array:string + type: array:string emails: title: Emails - format: array:string + type: array:string first-names: title: First Names - format: array:string + type: array:string last-names: title: Last Names - format: array:string + type: array:string component: @@ -582,13 +582,13 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string email: title: Email - format: string + type: string status: title: Status - format: string + type: string component: add-sender: @@ -631,7 +631,7 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string component: create-campaign: @@ -660,34 +660,34 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string timezone: title: Timezone - format: string + type: string days-of-week: title: Days of Week - format: array:string + type: array:string start-hour: title: Start Hour - format: string + type: string end-hour: title: End Hour - format: string + type: string schedule-start-time: title: Schedule Start Time - format: string + type: string stop-lead-settings: title: Stop Lead Settings - format: string + type: string send-as-plain-text: title: Send as Plain Text - format: boolean + type: boolean min-time-btw-emails: title: Min Time Between Emails - format: number + type: number max-new-leads-per-day: title: Max New Leads Per Days - format: number + type: number component: setup-campaign: @@ -726,7 +726,7 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string component: get-sequence: @@ -753,13 +753,13 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string email-body: title: Email Body - format: string + type: string subject: title: Subject - format: string + type: string component: save-sequence: @@ -794,16 +794,16 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string company: title: Company - format: string + type: string subject: title: Subject - format: string + type: string body: title: Body - format: string + type: string component: add-leads: @@ -845,10 +845,10 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string email: title: Email - format: string + type: string component: add-sender: @@ -875,10 +875,10 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string status: title: Status - format: string + type: string component: update-campaign-status: @@ -905,7 +905,7 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string component: @@ -932,10 +932,10 @@ version: v1beta variable: campaign-name: title: Campaign Name - format: string + type: string limit: title: Limit - format: number + type: number component: get-leads: diff --git a/pkg/component/application/smartlead/v0/config/setup.yaml b/pkg/component/application/smartlead/v0/config/setup.yaml index 96c2c786f..de60611e3 100644 --- a/pkg/component/application/smartlead/v0/config/setup.yaml +++ b/pkg/component/application/smartlead/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: api-key: description: Fill in your Smartlead API key. You can generate one from your [Smartlead account](https://app.smartlead.ai/app/settings/profile). - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: API Key - format: string required: - api-key title: Smartlead Connection -format: object +type: object diff --git a/pkg/component/application/smartlead/v0/config/tasks.yaml b/pkg/component/application/smartlead/v0/config/tasks.yaml index 0c44386fa..d2a1c86da 100644 --- a/pkg/component/application/smartlead/v0/config/tasks.yaml +++ b/pkg/component/application/smartlead/v0/config/tasks.yaml @@ -8,13 +8,11 @@ TASK_CREATE_CAMPAIGN: name: title: Name description: Name of the campaign. - acceptFormats: - - string + type: string uiOrder: 0 - format: string required: - name - format: object + type: object output: title: Output description: Output for creating a campaign. You can use this output in the next task. @@ -23,16 +21,16 @@ TASK_CREATE_CAMPAIGN: title: ID description: ID of the campaign. uiOrder: 0 - format: string + type: string created-at: title: Created At description: Created at timestamp of the campaign. uiOrder: 1 - format: string + type: string required: - id - created-at - format: object + type: object TASK_SETUP_CAMPAIGN: title: Setup Campaign shortDescription: Setup a campaign. You can update campaign settings to this campaign. For Smartlead campaign, you will need to setup the schedule settings @@ -44,63 +42,47 @@ TASK_SETUP_CAMPAIGN: campaign-name: title: Campaign Name description: Name of the campaign. - acceptFormats: - - string + type: string uiOrder: 0 - format: string timezone: title: Timezone description: Timezone of the campaign. Please choose the value in [List of Timezones](https://help.smartlead.ai/Timezones-20fcff9ddbb5441790c7c8e5ce0e9233). - acceptFormats: - - string + type: string uiOrder: 1 - format: string days-of-the-week: title: Days of the Week description: Days of the week when the campaign will run. A number value ranging from 0 to 6; i.e [0,1,2,3,4,5,6]. 0 is Sunday, 1 is Monday, and so on. items: - acceptFormats: - - number - format: number + type: number uiOrder: 2 - format: array + type: array start-hour: title: Start Hour description: Start hour of the campaign. Time to start the campaign in 24-hour format (HH:MM). - acceptFormats: - - string + type: string uiOrder: 3 - format: string end-hour: title: End Hour description: End hour of the campaign. Time to end the campaign in 24-hour format (HH:MM). - acceptFormats: - - string + type: string uiOrder: 4 - format: string min-time-btw-emails: title: Minimum Time Between Emails description: Minimum time between emails in minutes. The minimum value is 3 minutes. - acceptFormats: - - number + type: number minimum: 3 uiOrder: 5 - format: number max-new-leads-per-day: title: Maximum New Leads Per Day description: Maximum new leads per day. - acceptFormats: - - number + type: number uiOrder: 6 - format: number schedule-start-time: title: Schedule Start Time description: Schedule start time of the campaign. Please specify the campaign start time in standard ISO 8601 format. e.g. 2024-11-27T07:29:25.978Z. - acceptFormats: - - string + type: string uiOrder: 7 - format: string track-settings: title: Track Settings enum: @@ -109,9 +91,9 @@ TASK_SETUP_CAMPAIGN: - DONT_TRACK_REPLY_TO_AN_EMAIL description: Tracking settings like not tracking opens or link clicks. items: - format: string + type: string uiOrder: 8 - format: array + type: array stop-lead-settings: title: Stop Lead Settings description: Stops lead if they do the action specified. @@ -119,29 +101,27 @@ TASK_SETUP_CAMPAIGN: - CLICK_ON_A_LINK - OPEN_AN_EMAIL uiOrder: 9 - format: string + type: string send-as-plain-text: title: Send as Plain Text description: Send emails as plain text. uiOrder: 10 - format: boolean + type: boolean follow-up-percentage: title: Follow Up Percentage description: Specifies the percentage of leads in a campaign who should receive follow-up emails. - acceptFormats: - - number + type: number uiOrder: 11 - format: number add-unsubscribe-tag: title: Add Unsubscribe Tag description: Add an unsubscribe tag to the email. uiOrder: 12 - format: boolean + type: boolean ignore-ss-mailbox-sending-limit: title: Ignore Mailbox Sending Limit description: Ignore mailbox sending limits, used when creating a subsequence. uiOrder: 13 - format: boolean + type: boolean required: - campaign-name - timezone @@ -151,7 +131,7 @@ TASK_SETUP_CAMPAIGN: - min-time-btw-emails - max-new-leads-per-day - schedule-start-time - format: object + type: object output: title: Output description: Output for setting up a campaign. @@ -160,11 +140,11 @@ TASK_SETUP_CAMPAIGN: title: Result description: Result of setting up a campaign. uiOrder: 0 - format: string + type: string required: - schedule-setting-result - general-setting-result - format: object + type: object TASK_SAVE_SEQUENCES: title: Save Sequences shortDescription: Save sequences to a campaign. A Smartlead sequence is a series of automated emails sent to potential customers based on specific actions, @@ -176,57 +156,45 @@ TASK_SAVE_SEQUENCES: campaign-name: title: Campaign Name description: Name of the campaign. - acceptFormats: - - string + type: string uiOrder: 0 - format: string sequences: title: Sequences description: A Smartlead sequence is a series of automated emails sent to potential customers based on specific actions, or triggers. - acceptFormats: - - array + type: array items: properties: seq-number: title: Sequence Number description: Sequence number means the order of the sequence. If you don't specify this, it will be automatically assigned by the order of the sequences. - acceptFormats: - - number + type: number uiOrder: 0 - format: number sequence-delay-days: title: Sequence Delay Days description: Number of days to wait before sending the next email. If you don't specify this, the default value is 1 day. - acceptFormats: - - number + type: number uiOrder: 1 default: 1 - format: number subject: title: Subject description: Subject of the email. If you want to set the variable according to different leads, you can use {{variable_name}}. It will be replaced by the actual value from the lead. - acceptFormats: - - string + type: string uiOrder: 2 - format: string email-body: title: Email Body description: Body of the email. If you want to set the variable according to different leads, you can use {{variable_name}}. It will be replaced by the actual value from the lead. - acceptFormats: - - string + type: string uiOrder: 3 - format: string required: [] - format: object + type: object uiOrder: 1 - format: array required: - campaign-name - sequences - format: object + type: object output: title: Output description: Output for saving sequences. @@ -235,10 +203,10 @@ TASK_SAVE_SEQUENCES: title: Result description: Result of saving sequences. uiOrder: 0 - format: string + type: string required: - result - format: object + type: object TASK_GET_SEQUENCES: title: Get Sequences shortDescription: Get sequences of a campaign. If you want to add more sequences to the campaign, you can get the existing sequences and add new sequences @@ -250,13 +218,11 @@ TASK_GET_SEQUENCES: campaign-name: title: Campaign Name description: Name of the campaign. - acceptFormats: - - string + type: string uiOrder: 0 - format: string required: - campaign-name - format: object + type: object output: title: Output description: Output for getting sequences. @@ -264,52 +230,40 @@ TASK_GET_SEQUENCES: sequences: title: Sequences description: Sequences of the campaign. - acceptFormats: - - array + type: array items: properties: seq-id: title: Sequence ID description: ID of the sequence. - acceptFormats: - - string + type: string uiOrder: 0 - format: string seq-number: title: Sequence Number description: Sequence number means the order of the sequence. - acceptFormats: - - number + type: number uiOrder: 0 - format: number sequence-delay-days: title: Sequence Delay Days description: Number of days to wait before sending the next email. - acceptFormats: - - number + type: number uiOrder: 1 - format: number subject: title: Subject description: Subject of the email when you save the sequence. - acceptFormats: - - string + type: string uiOrder: 2 - format: string email-body: title: Email Body description: Body of the email when you save the sequence. - acceptFormats: - - string + type: string uiOrder: 3 - format: string required: [] - format: object + type: object uiOrder: 1 - format: array required: - sequences - format: object + type: object TASK_ADD_LEADS: title: Add Leads shortDescription: Add leads to a campaign. @@ -320,52 +274,39 @@ TASK_ADD_LEADS: campaign-name: title: Campaign Name description: Name of the campaign. - acceptFormats: - - string + type: string uiOrder: 0 - format: string leads: title: Leads description: Leads to add to the campaign. - acceptFormats: - - array + type: array items: properties: email: title: Email description: Email of the lead. - acceptFormats: - - string + type: string uiOrder: 0 - format: string first-name: title: First Name description: First name of the lead. - acceptFormats: - - string + type: string uiOrder: 1 - format: string last-name: title: Last Name description: Last name of the lead. - acceptFormats: - - string + type: string uiOrder: 2 - format: string company: title: Company description: Company name of the lead. - acceptFormats: - - string + type: string uiOrder: 3 - format: string location: title: Location description: Location of the lead. - acceptFormats: - - string + type: string uiOrder: 4 - format: string custom-fields: title: Custom Fields description: Custom fields of the lead. You can use custom fields to store additional information about the lead, which can be used in the @@ -375,28 +316,23 @@ TASK_ADD_LEADS: key: title: Key description: Key of the custom field. - acceptFormats: - - string + type: string uiOrder: 0 - format: string value: title: Value description: Value of the custom field. - acceptFormats: - - string + type: string uiOrder: 1 - format: string required: - key - value required: [] uiOrder: 5 - format: array + type: array required: - email - format: object + type: object uiOrder: 1 - format: array settings: title: Settings description: Settings for adding leads. @@ -405,42 +341,34 @@ TASK_ADD_LEADS: title: Ignore Global Block List description: Ignore the global block list and add the lead. If true, uploaded leads will BYPASS the global block list and be uploaded to the campaign. - acceptFormats: - - boolean + type: boolean uiOrder: 0 - format: boolean ignore-unsubscribe-list: title: Ignore Unsubscribe List description: Ignore the unsubscribe list and add the lead. If true, leads will BYPASS the comparison with unsubscribed leads and be uploaded to the campaign. - acceptFormats: - - boolean + type: boolean uiOrder: 1 - format: boolean ignore-community-bounce-list: title: Ignore Community Bounce List description: Ignore the community bounce list and add the lead. If true, uploaded leads will BYPASS any leads that bounced across Smartlead entire user base and be uploaded to the campaign. - acceptFormats: - - boolean + type: boolean uiOrder: 2 - format: boolean ignore-duplicate-leads-in-other-campaign: title: Ignore Duplicate Leads in Other Campaign description: 'Ignore duplicate leads in other campaigns and add the lead. If true, leads will NOT BYPASS the comparison with other campaigns and NOT be added to the campaign if they are part of any other campaign. ' - acceptFormats: - - boolean + type: boolean uiOrder: 3 - format: boolean uiOrder: 2 required: - ignore-duplicate-leads-in-other-campaign - format: object + type: object required: - campaign-name - leads - format: object + type: object output: title: Output description: Output for adding leads. @@ -449,33 +377,33 @@ TASK_ADD_LEADS: title: Upload Count description: Number of leads uploaded. uiOrder: 0 - format: number + type: number total-leads: title: Total Leads description: Total number of leads in the campaign. uiOrder: 1 - format: number + type: number already-added-to-campaign: title: Already Added to Campaign description: Number of leads already added to the campaign. uiOrder: 2 - format: number + type: number invalid-email-count: title: Invalid Email Count description: Number of leads with invalid email. uiOrder: 3 - format: number + type: number error: title: Error description: Error message from Smartlead if any. uiOrder: 4 - format: string + type: string required: - upload-count - total-leads - already-added-to-campaign - invalid-email-count - format: object + type: object TASK_ADD_SENDER_EMAIL: title: Add Sender Email shortDescription: Add a sender email to the campaign. You have to configure the sender email in Smartlead console before adding it to the campaign. @@ -486,22 +414,18 @@ TASK_ADD_SENDER_EMAIL: campaign-name: title: Campaign Name description: Name of the campaign. - acceptFormats: - - string + type: string uiOrder: 0 - format: string sender-email: title: Sender Email description: Email address of the sender. You need to configure the sender email in [Smartlead console](https://app.smartlead.ai/app/email-accounts) before adding it to the campaign. - acceptFormats: - - string + type: string uiOrder: 1 - format: string required: - campaign-name - sender-email - format: object + type: object output: title: Output description: Output for adding a sender email. @@ -510,10 +434,10 @@ TASK_ADD_SENDER_EMAIL: title: Result description: Result of adding a sender email. If you don't configure your sender email in Smartlead console, you will get an error. uiOrder: 0 - format: string + type: string required: - result - format: object + type: object TASK_UPDATE_CAMPAIGN_STATUS: title: Update Campaign Status shortDescription: Update the status of a campaign. You need to start a campaign to send the emails to the leads. @@ -524,10 +448,8 @@ TASK_UPDATE_CAMPAIGN_STATUS: campaign-name: title: Campaign Name description: Name of the campaign. - acceptFormats: - - string + type: string uiOrder: 0 - format: string status: title: Status description: Status of the campaign. @@ -536,11 +458,11 @@ TASK_UPDATE_CAMPAIGN_STATUS: - PAUSED - STOPPED uiOrder: 1 - format: string + type: string required: - campaign-name - status - format: object + type: object output: title: Output description: Output for updating the status of a campaign. @@ -549,10 +471,10 @@ TASK_UPDATE_CAMPAIGN_STATUS: title: Result description: Result of updating the status of a campaign. uiOrder: 0 - format: string + type: string required: - result - format: object + type: object TASK_GET_CAMPAIGN_METRIC: title: Get Campaign Metric shortDescription: Get the metrics of a campaign. You can get the metrics like open count, click count, and reply count of the campaign. @@ -563,13 +485,11 @@ TASK_GET_CAMPAIGN_METRIC: campaign-name: title: Campaign Name description: Name of the campaign. - acceptFormats: - - string + type: string uiOrder: 0 - format: string required: - campaign-name - format: object + type: object output: title: Output description: Output for getting the metrics of a campaign. @@ -578,49 +498,49 @@ TASK_GET_CAMPAIGN_METRIC: title: Sent Count description: Number of emails sent. uiOrder: 0 - format: number + type: number unique-sent-count: title: Unique Sent Count description: Number of unique emails sent. uiOrder: 1 - format: number + type: number open-count: title: Open Count description: Number of emails opened. uiOrder: 2 - format: number + type: number unique-open-count: title: Unique Open Count description: Number of unique emails opened. uiOrder: 3 - format: number + type: number click-count: title: Click Count description: Number of emails clicked. uiOrder: 4 - format: number + type: number unique-click-count: title: Unique Click Count description: Number of unique emails clicked. uiOrder: 5 - format: number + type: number reply-count: title: Reply Count description: Number of emails replied. uiOrder: 6 - format: number + type: number total-count: title: Total Count description: Total number of emails. uiOrder: 7 - format: number + type: number bounce-count: title: Bounce Count description: Number of emails bounced. uiOrder: 8 - format: number + type: number required: [] - format: object + type: object TASK_LIST_LEADS_STATUS: title: List Leads Status shortDescription: List the status of leads in a campaign. You can get the status of leads like 'STARTED', 'INPROGRESS', 'COMPLETED', 'PAUSED', 'STOPPED'. @@ -631,22 +551,18 @@ TASK_LIST_LEADS_STATUS: campaign-name: title: Campaign Name description: Name of the campaign. - acceptFormats: - - string + type: string uiOrder: 0 - format: string limit: title: Limit description: Number of leads to list. The minimum value is 1. minimum: 1 - acceptFormats: - - number + type: number uiOrder: 1 - format: number required: - campaign-name - limit - format: object + type: object output: title: Output description: Output for listing the status of leads. @@ -660,18 +576,18 @@ TASK_LIST_LEADS_STATUS: title: Email description: Email of the lead. uiOrder: 0 - format: string + type: string status: title: Status description: Status of the lead. uiOrder: 1 - format: string + type: string required: - email - status - format: object + type: object uiOrder: 0 - format: array + type: array required: - leads - format: object + type: object diff --git a/pkg/component/application/whatsapp/v0/README.mdx b/pkg/component/application/whatsapp/v0/README.mdx index 1cd4df68a..3a8fb3b7d 100644 --- a/pkg/component/application/whatsapp/v0/README.mdx +++ b/pkg/component/application/whatsapp/v0/README.mdx @@ -44,7 +44,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Token (required) | `token` | string | Fill in your WhatsApp access token. Go [here](https://developers.facebook.com/docs/whatsapp/cloud-api/get-started) for more information. | @@ -62,7 +62,7 @@ Send text-based template message. This task support header(text), body and butto
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEND_TEXT_BASED_TEMPLATE_MESSAGE` | | Phone Number ID (required) | `phone-number-id` | string | Phone Number ID. Obtainable through the app dashboard. Note: This is for sender. | @@ -81,7 +81,7 @@ Send text-based template message. This task support header(text), body and butto
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Recipient WhatsApp ID | `recipient-wa-id` | string | The WhatsApp ID of the recipient. Most likely the same with their phone number. | | Message ID | `message-id` | string | The ID of the message. | @@ -95,7 +95,7 @@ Send media-based template message. This task support header(image, document & vi
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEND_MEDIA_BASED_TEMPLATE_MESSAGE` | | Phone Number ID (required) | `phone-number-id` | string | Phone Number ID. Obtainable through the app dashboard. Note: This is for sender. | @@ -116,7 +116,7 @@ Send media-based template message. This task support header(image, document & vi
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Recipient WhatsApp ID | `recipient-wa-id` | string | The WhatsApp ID of the recipient. Most likely the same with their phone number. | | Message ID | `message-id` | string | The ID of the message. | @@ -130,7 +130,7 @@ Send location-based template message. This task support header(location), body a
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEND_LOCATION_BASED_TEMPLATE_MESSAGE` | | Phone Number ID (required) | `phone-number-id` | string | Phone Number ID. Obtainable through the app dashboard. Note: This is for sender. | @@ -152,7 +152,7 @@ Send location-based template message. This task support header(location), body a
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Recipient WhatsApp ID | `recipient-wa-id` | string | The WhatsApp ID of the recipient. Most likely the same with their phone number. | | Message ID | `message-id` | string | The ID of the message. | @@ -166,7 +166,7 @@ Send authentication template message with one-time password button (The button i
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEND_AUTHENTICATION_TEMPLATE_MESSAGE` | | Phone Number ID (required) | `phone-number-id` | string | Phone Number ID. Obtainable through the app dashboard. Note: This is for sender. | @@ -183,7 +183,7 @@ Send authentication template message with one-time password button (The button i
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Recipient WhatsApp ID | `recipient-wa-id` | string | The WhatsApp ID of the recipient. Most likely the same with their phone number. | | Message ID | `message-id` | string | The ID of the message. | @@ -197,7 +197,7 @@ Send text message. Note: Message can only be sent when the 24-hour customer serv
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEND_TEXT_MESSAGE` | | Phone Number ID (required) | `phone-number-id` | string | Phone Number ID. Obtainable through the app dashboard. Note: This is for sender. | @@ -213,7 +213,7 @@ Send text message. Note: Message can only be sent when the 24-hour customer serv
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Recipient WhatsApp ID | `recipient-wa-id` | string | The WhatsApp ID of the recipient. Most likely the same with their phone number. | | Message ID | `message-id` | string | The ID of the message. | @@ -226,7 +226,7 @@ Send media message. Media supported: video, audio, document, image. Note: Messag
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEND_MEDIA_MESSAGE` | | Phone Number ID (required) | `phone-number-id` | string | Phone Number ID. Obtainable through the app dashboard. Note: This is for sender. | @@ -244,7 +244,7 @@ Send media message. Media supported: video, audio, document, image. Note: Messag
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Recipient WhatsApp ID | `recipient-wa-id` | string | The WhatsApp ID of the recipient. Most likely the same with their phone number. | | Message ID | `message-id` | string | The ID of the message. | @@ -257,7 +257,7 @@ Send location message. Note: Message can only be sent when the 24-hour customer
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEND_LOCATION_MESSAGE` | | Phone Number ID (required) | `phone-number-id` | string | Phone Number ID. Obtainable through the app dashboard. Note: This is for sender. | @@ -275,7 +275,7 @@ Send location message. Note: Message can only be sent when the 24-hour customer
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Recipient WhatsApp ID | `recipient-wa-id` | string | The WhatsApp ID of the recipient. Most likely the same with their phone number. | | Message ID | `message-id` | string | The ID of the message. | @@ -288,7 +288,7 @@ Send contact message. Note: Message can only be sent when the 24-hour customer s
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEND_CONTACT_MESSAGE` | | Phone Number ID (required) | `phone-number-id` | string | Phone Number ID. Obtainable through the app dashboard. Note: This is for sender. | @@ -310,7 +310,7 @@ Send contact message. Note: Message can only be sent when the 24-hour customer s
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Recipient WhatsApp ID | `recipient-wa-id` | string | The WhatsApp ID of the recipient. Most likely the same with their phone number. | | Message ID | `message-id` | string | The ID of the message. | @@ -323,7 +323,7 @@ Send interactive Call-To-Action URL button message. Note: Message can only be se
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEND_INTERACTIVE_CALL_TO_ACTION_URL_BUTTON_MESSAGE` | | Phone Number ID (required) | `phone-number-id` | string | Phone Number ID. Obtainable through the app dashboard. Note: This is for sender. | @@ -342,7 +342,7 @@ Send interactive Call-To-Action URL button message. Note: Message can only be se
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Recipient WhatsApp ID | `recipient-wa-id` | string | The WhatsApp ID of the recipient. Most likely the same with their phone number. | | Message ID | `message-id` | string | The ID of the message. | diff --git a/pkg/component/application/whatsapp/v0/config/setup.yaml b/pkg/component/application/whatsapp/v0/config/setup.yaml index e7b36caa7..123cd5100 100644 --- a/pkg/component/application/whatsapp/v0/config/setup.yaml +++ b/pkg/component/application/whatsapp/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: token: description: Fill in your WhatsApp access token. Go [here](https://developers.facebook.com/docs/whatsapp/cloud-api/get-started) for more information. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: Token - format: string required: - token title: WhatsApp Connection -format: object +type: object diff --git a/pkg/component/application/whatsapp/v0/config/tasks.yaml b/pkg/component/application/whatsapp/v0/config/tasks.yaml index 780a55088..97526cb65 100644 --- a/pkg/component/application/whatsapp/v0/config/tasks.yaml +++ b/pkg/component/application/whatsapp/v0/config/tasks.yaml @@ -2,39 +2,31 @@ $defs: def-input: phone-number-id: description: 'Phone Number ID. Obtainable through the app dashboard. Note: This is for sender.' - acceptFormats: - - string + type: string uiOrder: 0 title: Phone Number ID - format: string to: description: The number of the recipient you are sending the message to. - acceptFormats: - - string + type: string uiOrder: 1 title: Recipient Phone Number - format: string template: name: description: Name of the template. - acceptFormats: - - string + type: string title: Template Name - format: string language-code: description: The code of the language in which the template is used. [Supported languages](https://developers.facebook.com/docs/whatsapp/api/messages/message-templates#supported-languages). - acceptFormats: - - string + type: string title: Language Code - format: string body-parameters: description: Specify the parameters for the body section of the template. Leave this blank if there is no parameter. title: Body Parameters items: title: Body Parameter description: Body parameter. - format: string - format: array + type: string + type: array button-parameters: description: 'Specify the parameters for button(s). Leave this blank if there is no parameter. Follow this format or it won''t work: button_index;button_type;value_of_the_parameter. The seperator is a semicolon. button_index starts at 0. Example: 0;quick_reply;randomvalue. Note: This button parameter only support three types @@ -43,63 +35,49 @@ $defs: items: title: Button Parameter description: Button parameter. - format: string - format: array + type: string + type: array media: id-or-link: description: Input either ID or link of the media. If the input has 'http', it will be considered as a link. - acceptFormats: - - string - format: string + type: string caption: description: Media asset caption. Description of the media. This property cannot be used when the media type is audio. If audio tried to use this property, it will be ignored. - acceptFormats: - - string - format: string + type: string filename: description: The filename of the document. Only document can use this property. This property will specify what format the document is displayed as in WhatsApp. If other media type tried to use this property, it will be ignored. - acceptFormats: - - string - format: string + type: string location: latitude: description: Location latitude. - acceptFormats: - - number - format: number + type: number longitude: description: Location longitude. - acceptFormats: - - number - format: number + type: number location-name: description: Name of the location. - acceptFormats: - - string - format: string + type: string address: description: Address of the location. - acceptFormats: - - string - format: string + type: string def-output: recipient-wa-id: description: The WhatsApp ID of the recipient. Most likely the same with their phone number. uiOrder: 0 title: Recipient WhatsApp ID - format: string + type: string message-id: description: The ID of the message. uiOrder: 1 title: Message ID - format: string + type: string message-status: description: The status of the message. uiOrder: 2 title: Message Status - format: string + type: string TASK_SEND_TEXT_BASED_TEMPLATE_MESSAGE: shortDescription: Send text-based template message. This task support header(text), body and button parameters. input: @@ -123,8 +101,8 @@ TASK_SEND_TEXT_BASED_TEMPLATE_MESSAGE: items: title: Header Parameter description: Header parameter. - format: string - format: array + type: string + type: array body-parameters: $ref: '#/$defs/def-input/template/body-parameters' uiOrder: 5 @@ -137,7 +115,7 @@ TASK_SEND_TEXT_BASED_TEMPLATE_MESSAGE: - name - language-code title: Input - format: object + type: object output: description: API response. uiOrder: 0 @@ -153,7 +131,7 @@ TASK_SEND_TEXT_BASED_TEMPLATE_MESSAGE: - message-id - message-status title: Output - format: object + type: object TASK_SEND_MEDIA_BASED_TEMPLATE_MESSAGE: shortDescription: Send media-based template message. This task support header(image, document & video), body and button parameters. input: @@ -177,11 +155,9 @@ TASK_SEND_MEDIA_BASED_TEMPLATE_MESSAGE: - document example: none description: Specify the header(media) type for the header section of the template. - acceptFormats: - - string + type: string uiOrder: 4 title: Header Type - format: string id-or-link: title: ID Or Link (Header Parameter) $ref: '#/$defs/def-input/media/id-or-link' @@ -204,7 +180,7 @@ TASK_SEND_MEDIA_BASED_TEMPLATE_MESSAGE: - media-type - id-or-link title: Input - format: object + type: object output: description: API response. uiOrder: 0 @@ -220,7 +196,7 @@ TASK_SEND_MEDIA_BASED_TEMPLATE_MESSAGE: - message-id - message-status title: Output - format: object + type: object TASK_SEND_LOCATION_BASED_TEMPLATE_MESSAGE: shortDescription: Send location-based template message. This task support header(location), body and button parameters. input: @@ -269,7 +245,7 @@ TASK_SEND_LOCATION_BASED_TEMPLATE_MESSAGE: - location-name - address title: Input - format: object + type: object output: description: API response. uiOrder: 0 @@ -285,7 +261,7 @@ TASK_SEND_LOCATION_BASED_TEMPLATE_MESSAGE: - message-id - message-status title: Output - format: object + type: object TASK_SEND_AUTHENTICATION_TEMPLATE_MESSAGE: shortDescription: Send authentication template message with one-time password button (The button is used to copy the password to clipboard). Authentication template has no header parameters. @@ -305,11 +281,9 @@ TASK_SEND_AUTHENTICATION_TEMPLATE_MESSAGE: uiOrder: 3 one-time-password: description: One-time password to be sent to the recipient. Maximum 15 characters. - acceptFormats: - - string + type: string uiOrder: 4 title: One-Time Password - format: string required: - phone-number-id - to @@ -317,7 +291,7 @@ TASK_SEND_AUTHENTICATION_TEMPLATE_MESSAGE: - language-code - one-time-password title: Input - format: object + type: object output: description: API response. uiOrder: 0 @@ -333,7 +307,7 @@ TASK_SEND_AUTHENTICATION_TEMPLATE_MESSAGE: - message-id - message-status title: Output - format: object + type: object TASK_SEND_TEXT_MESSAGE: shortDescription: 'Send text message. Note: Message can only be sent when the 24-hour customer service window is open. For more information, please visit [here](https://developers.facebook.com/docs/whatsapp/cloud-api/guides/send-messages#customer-service-windows)' @@ -347,29 +321,25 @@ TASK_SEND_TEXT_MESSAGE: $ref: '#/$defs/def-input/to' body: description: Body of the message. - acceptFormats: - - string + type: string uiOrder: 2 title: Text - format: string preview-url: enum: - 'false' - 'true' example: 'false' description: Specify whether URL should be previewed or not. This will have no affect if the message does not contain any URL. - acceptFormats: - - string + type: string uiOrder: 3 title: Preview URL - format: string required: - phone-number-id - to - body - preview-url title: Input - format: object + type: object output: description: API response. uiOrder: 0 @@ -382,7 +352,7 @@ TASK_SEND_TEXT_MESSAGE: - recipient-wa-id - message-id title: Output - format: object + type: object TASK_SEND_MEDIA_MESSAGE: shortDescription: 'Send media message. Media supported: video, audio, document, image. Note: Message can only be sent when the 24-hour customer service window is open. For more information, please visit [here](https://developers.facebook.com/docs/whatsapp/cloud-api/guides/send-messages#customer-service-windows)' @@ -402,11 +372,9 @@ TASK_SEND_MEDIA_MESSAGE: - video example: image description: Specify what media to send. - acceptFormats: - - string + type: string uiOrder: 2 title: Media Type - format: string id-or-link: title: ID Or Link $ref: '#/$defs/def-input/media/id-or-link' @@ -425,7 +393,7 @@ TASK_SEND_MEDIA_MESSAGE: - media-type - id-or-link title: Input - format: object + type: object output: description: API response. uiOrder: 0 @@ -438,7 +406,7 @@ TASK_SEND_MEDIA_MESSAGE: - recipient-wa-id - message-id title: Output - format: object + type: object TASK_SEND_LOCATION_MESSAGE: shortDescription: 'Send location message. Note: Message can only be sent when the 24-hour customer service window is open. For more information, please visit [here](https://developers.facebook.com/docs/whatsapp/cloud-api/guides/send-messages#customer-service-windows)' @@ -474,7 +442,7 @@ TASK_SEND_LOCATION_MESSAGE: - location-name - address title: Input - format: object + type: object output: description: API response. uiOrder: 0 @@ -487,7 +455,7 @@ TASK_SEND_LOCATION_MESSAGE: - recipient-wa-id - message-id title: Output - format: object + type: object TASK_SEND_CONTACT_MESSAGE: shortDescription: 'Send contact message. Note: Message can only be sent when the 24-hour customer service window is open. For more information, please visit [here](https://developers.facebook.com/docs/whatsapp/cloud-api/guides/send-messages#customer-service-windows)' @@ -501,32 +469,24 @@ TASK_SEND_CONTACT_MESSAGE: $ref: '#/$defs/def-input/to' first-name: description: First name of the contact. - acceptFormats: - - string + type: string uiOrder: 2 title: First Name - format: string middle-name: description: Middle name of the contact. - acceptFormats: - - string + type: string uiOrder: 3 title: Middle Name - format: string last-name: description: Last name of the contact. - acceptFormats: - - string + type: string uiOrder: 4 title: Last Name - format: string phone-number: description: Phone number of the contact. - acceptFormats: - - string + type: string uiOrder: 5 title: Phone Number - format: string phone-number-type: enum: - none @@ -537,18 +497,14 @@ TASK_SEND_CONTACT_MESSAGE: - WORK example: none description: Phone number type of the contact. If there is no phone number, pick none. - acceptFormats: - - string + type: string uiOrder: 6 title: Phone Number Type - format: string email: description: Email of the contact. - acceptFormats: - - string + type: string uiOrder: 7 title: Email - format: string email-type: enum: - none @@ -556,24 +512,20 @@ TASK_SEND_CONTACT_MESSAGE: - WORK example: none description: Email type of the contact. If there is no email, pick none. - acceptFormats: - - string + type: string uiOrder: 8 title: Email Type - format: string birthday: description: Birthday of the contact. Format is in 'YYYY-MM-DD'. - acceptFormats: - - string + type: string uiOrder: 9 title: Birthday - format: string required: - phone-number-id - to - first-name title: Input - format: object + type: object output: description: API response. uiOrder: 0 @@ -586,7 +538,7 @@ TASK_SEND_CONTACT_MESSAGE: - recipient-wa-id - message-id title: Output - format: object + type: object TASK_SEND_INTERACTIVE_CALL_TO_ACTION_URL_BUTTON_MESSAGE: shortDescription: 'Send interactive Call-To-Action URL button message. Note: Message can only be sent when the 24-hour customer service window is open. For more information, please visit [here](https://developers.facebook.com/docs/whatsapp/cloud-api/guides/send-messages#customer-service-windows).' @@ -600,39 +552,29 @@ TASK_SEND_INTERACTIVE_CALL_TO_ACTION_URL_BUTTON_MESSAGE: $ref: '#/$defs/def-input/to' header-text: description: Message header text. - acceptFormats: - - string + type: string uiOrder: 2 title: Header Text - format: string body-text: description: Message body text. - acceptFormats: - - string + type: string uiOrder: 3 title: Body Text - format: string footer-text: description: Message footer text. - acceptFormats: - - string + type: string uiOrder: 4 title: Footer Text - format: string button-display-text: description: The text displayed on the button. - acceptFormats: - - string + type: string uiOrder: 5 title: Button Display Text - format: string button-url: description: URL to load when the user tapped the button. - acceptFormats: - - string + type: string uiOrder: 6 title: Button URL - format: string required: - phone-number-id - to @@ -640,7 +582,7 @@ TASK_SEND_INTERACTIVE_CALL_TO_ACTION_URL_BUTTON_MESSAGE: - button-display-text - button-url title: Input - format: object + type: object output: description: API response. uiOrder: 0 @@ -653,4 +595,4 @@ TASK_SEND_INTERACTIVE_CALL_TO_ACTION_URL_BUTTON_MESSAGE: - recipient-wa-id - message-id title: Output - format: object + type: object diff --git a/pkg/component/base/component.go b/pkg/component/base/component.go index c7497cc39..fef921477 100644 --- a/pkg/component/base/component.go +++ b/pkg/component/base/component.go @@ -30,7 +30,7 @@ const conditionJSON = ` { "uiOrder": 1, "shortDescription": "config whether the component will be executed or skipped", - "acceptFormats": ["string"], + "type": "string", "upstreamTypes": ["value", "template"] } ` @@ -212,7 +212,7 @@ func convertDataSpecToCompSpec(dataSpec *structpb.Struct) (*structpb.Struct, err } } - if compSpec.Fields["format"] != nil && compSpec.Fields["format"].GetStringValue() == "object" { + if compSpec.Fields["type"] != nil && compSpec.Fields["type"].GetStringValue() == "object" { // Always add required field for object type if missing if _, ok := compSpec.Fields["required"]; !ok { compSpec.Fields["required"] = structpb.NewListValue(&structpb.ListValue{Values: []*structpb.Value{}}) @@ -297,72 +297,6 @@ func convertDataSpecToCompSpec(dataSpec *structpb.Struct) (*structpb.Struct, err if _, ok := compSpec.Fields["uiOrder"]; !ok { compSpec.Fields["uiOrder"] = structpb.NewNumberValue(0) } - if compSpec.Fields["acceptFormats"] != nil { - - original := proto.Clone(compSpec).(*structpb.Struct) - delete(original.Fields, "title") - delete(original.Fields, "description") - delete(original.Fields, "shortDescription") - delete(original.Fields, "acceptFormats") - delete(original.Fields, "uiOrder") - delete(original.Fields, "upstreamTypes") - - newCompSpec := &structpb.Struct{Fields: make(map[string]*structpb.Value)} - newCompSpec.Fields["acceptFormats"] = structpb.NewListValue(compSpec.Fields["acceptFormats"].GetListValue()) - - newCompSpec.Fields["title"] = structpb.NewStringValue(compSpec.Fields["title"].GetStringValue()) - newCompSpec.Fields["description"] = structpb.NewStringValue(compSpec.Fields["description"].GetStringValue()) - if _, ok := compSpec.Fields["shortDescription"]; ok { - newCompSpec.Fields["shortDescription"] = compSpec.Fields["shortDescription"] - } else { - newCompSpec.Fields["shortDescription"] = newCompSpec.Fields["description"] - } - newCompSpec.Fields["uiOrder"] = structpb.NewNumberValue(compSpec.Fields["uiOrder"].GetNumberValue()) - - if _, ok := newCompSpec.Fields["acceptFormats"]; ok { - newCompSpec.Fields["upstreamTypes"] = structpb.NewListValue(&structpb.ListValue{Values: []*structpb.Value{ - structpb.NewStringValue("value"), - structpb.NewStringValue("reference"), - structpb.NewStringValue("template"), - }}) - newCompSpec.Fields["anyOf"] = structpb.NewListValue(&structpb.ListValue{Values: []*structpb.Value{}}) - for _, v := range newCompSpec.Fields["upstreamTypes"].GetListValue().GetValues() { - - if v.GetStringValue() == "value" { - original.Fields["upstreamType"] = v - newCompSpec.Fields["anyOf"].GetListValue().Values = append(newCompSpec.Fields["anyOf"].GetListValue().Values, structpb.NewStructValue(original)) - } - if v.GetStringValue() == "reference" { - item, err := structpb.NewValue( - map[string]any{ - "type": "string", - "pattern": "^\\{.*\\}$", - "upstreamType": "reference", - }, - ) - if err != nil { - return nil, err - } - newCompSpec.Fields["anyOf"].GetListValue().Values = append(newCompSpec.Fields["anyOf"].GetListValue().Values, item) - } - if v.GetStringValue() == "template" { - item, err := structpb.NewValue( - map[string]any{ - "type": "string", - "upstreamType": "template", - }, - ) - if err != nil { - return nil, err - } - newCompSpec.Fields["anyOf"].GetListValue().Values = append(newCompSpec.Fields["anyOf"].GetListValue().Values, item) - } - - } - } - - compSpec = newCompSpec - } return compSpec, nil } @@ -440,7 +374,7 @@ func generateComponentSpec(title string, tasks []*pb.ComponentTask, taskStructs var err error componentSpec := &structpb.Struct{Fields: map[string]*structpb.Value{}} componentSpec.Fields["title"] = structpb.NewStringValue(fmt.Sprintf("%s Component", title)) - componentSpec.Fields["format"] = structpb.NewStringValue("object") + componentSpec.Fields["type"] = structpb.NewStringValue("object") oneOfList := &structpb.ListValue{ Values: []*structpb.Value{}, @@ -449,7 +383,7 @@ func generateComponentSpec(title string, tasks []*pb.ComponentTask, taskStructs taskName := task.Name oneOf := &structpb.Struct{Fields: map[string]*structpb.Value{}} - oneOf.Fields["format"] = structpb.NewStringValue("object") + oneOf.Fields["type"] = structpb.NewStringValue("object") oneOf.Fields["properties"] = structpb.NewStructValue(&structpb.Struct{Fields: make(map[string]*structpb.Value)}) oneOf.Fields["properties"].GetStructValue().Fields["task"], err = structpb.NewValue(map[string]any{ @@ -718,26 +652,26 @@ func (c *Component) GetDefinition(sysVars map[string]any, compConfig *ComponentC var err error definition := proto.Clone(c.definition).(*pb.ComponentDefinition) - definition.Spec.ComponentSpecification, err = convertFormatFields(definition.Spec.ComponentSpecification) + definition.Spec.ComponentSpecification, err = convertFormatFields(definition.Spec.ComponentSpecification, true) if err != nil { return nil, err } for k := range definition.Spec.DataSpecifications { - definition.Spec.DataSpecifications[k].Input, err = convertFormatFields(definition.Spec.DataSpecifications[k].Input) + definition.Spec.DataSpecifications[k].Input, err = convertFormatFields(definition.Spec.DataSpecifications[k].Input, false) if err != nil { return nil, err } - definition.Spec.DataSpecifications[k].Output, err = convertFormatFields(definition.Spec.DataSpecifications[k].Output) + definition.Spec.DataSpecifications[k].Output, err = convertFormatFields(definition.Spec.DataSpecifications[k].Output, false) if err != nil { return nil, err } } for k := range definition.Spec.EventSpecifications { - definition.Spec.EventSpecifications[k].ConfigSchema, err = convertFormatFields(definition.Spec.EventSpecifications[k].ConfigSchema) + definition.Spec.EventSpecifications[k].ConfigSchema, err = convertFormatFields(definition.Spec.EventSpecifications[k].ConfigSchema, false) if err != nil { return nil, err } - definition.Spec.EventSpecifications[k].MessageSchema, err = convertFormatFields(definition.Spec.EventSpecifications[k].MessageSchema) + definition.Spec.EventSpecifications[k].MessageSchema, err = convertFormatFields(definition.Spec.EventSpecifications[k].MessageSchema, false) if err != nil { return nil, err } @@ -1002,7 +936,7 @@ func (c *Component) traverseSecretField(input *structpb.Value, prefix string, se secretFields = append(secretFields, fmt.Sprintf("%s%s", prefix, key)) } } - if tp, ok := v.GetStructValue().GetFields()["format"]; ok { + if tp, ok := v.GetStructValue().GetFields()["type"]; ok { if tp.GetStringValue() == "object" { if l, ok := v.GetStructValue().GetFields()["oneOf"]; ok { for _, v := range l.GetListValue().Values { diff --git a/pkg/component/base/migrate.go b/pkg/component/base/migrate.go index a4aada59b..0e7098571 100644 --- a/pkg/component/base/migrate.go +++ b/pkg/component/base/migrate.go @@ -8,25 +8,21 @@ import ( // convertFormatFields converts component definition fields from the new format to the legacy format. // This maintains backwards compatibility while we transition the API to use the new field names. // The main changes are: -// - format -> type + instillFormat -// - acceptFormats -> instillAcceptFormats -// - upstreamTypes -> instillUpstreamTypes // - uiOrder -> instillUiOrder // - shortDescription -> instillShortDescription // This function will be removed once the API is updated to use the new field names directly. -func convertFormatFields(input *structpb.Struct) (*structpb.Struct, error) { +func convertFormatFields(input *structpb.Struct, isCompSpec bool) (*structpb.Struct, error) { if input == nil { return nil, nil } output := proto.Clone(input).(*structpb.Struct) - convertFormatFieldsRecursive(output) + convertFormatFieldsRecursive(output, isCompSpec) return output, nil } -func convertFormatFieldsRecursive(s *structpb.Struct) { - // return +func convertFormatFieldsRecursive(s *structpb.Struct, isCompSpec bool) { if s == nil { return @@ -36,13 +32,6 @@ func convertFormatFieldsRecursive(s *structpb.Struct) { for key, value := range fields { switch { - case key == "format": - fields["type"] = value - fields["instillFormat"] = value - delete(fields, "format") - case key == "acceptFormats": - fields["instillAcceptFormats"] = value - delete(fields, "acceptFormats") case key == "upstreamTypes": fields["instillUpstreamTypes"] = value delete(fields, "upstreamTypes") @@ -61,34 +50,15 @@ func convertFormatFieldsRecursive(s *structpb.Struct) { fields["instillShortDescription"] = fields["description"] } } - if _, ok := fields["type"]; !ok { - if _, ok := fields["instillFormat"]; ok { - f := fields["instillFormat"].GetStringValue() - switch f { - case "file", "document", "image", "audio", "video": - f = "string" - } - fields["type"] = structpb.NewStringValue(f) - } - - if _, ok := fields["instillAcceptFormats"]; ok { - f := fields["instillAcceptFormats"].GetListValue().Values[0].GetStringValue() - switch f { - case "file", "document", "image", "audio", "video": - f = "string" - } - fields["type"] = structpb.NewStringValue(f) - } - } // Recursively process nested structures switch { case value.GetStructValue() != nil: - convertFormatFieldsRecursive(value.GetStructValue()) + convertFormatFieldsRecursive(value.GetStructValue(), isCompSpec) case value.GetListValue() != nil: for idx := range value.GetListValue().Values { if value.GetListValue().Values[idx].GetStructValue() != nil { - convertFormatFieldsRecursive(value.GetListValue().Values[idx].GetStructValue()) + convertFormatFieldsRecursive(value.GetListValue().Values[idx].GetStructValue(), isCompSpec) } } } diff --git a/pkg/component/base/testdata/componentTasks.json b/pkg/component/base/testdata/componentTasks.json deleted file mode 100644 index 70ed0fdd6..000000000 --- a/pkg/component/base/testdata/componentTasks.json +++ /dev/null @@ -1,49 +0,0 @@ -{ - "TASK_TEXT_EMBEDDINGS": { - "shortDescription": "Turn text into numbers, unlocking use cases like search.", - "input": { - "uiOrder": 0, - "properties": { - "model": { - "$ref": "additional.yaml#/components/schemas/CreateEmbeddingRequest/properties/model", - "acceptFormats": [ - "string" - ], - "shortDescription": "ID of the model to use", - "uiOrder": 0, - "title": "Model" - }, - "text": { - "description": "The text", - "acceptFormats": [ - "string" - ], - "uiOrder": 1, - "title": "Text", - "type": "string" - } - }, - "required": [ - "text", - "model" - ], - "title": "Input", - "type": "object" - }, - "output": { - "uiOrder": 0, - "properties": { - "embedding": { - "$ref": "schema.yaml#/$defs/instill-types/embedding", - "uiOrder": 0, - "title": "Embedding" - } - }, - "required": [ - "embedding" - ], - "title": "Output", - "type": "object" - } - } -} diff --git a/pkg/component/base/testdata/componentTasks.yaml b/pkg/component/base/testdata/componentTasks.yaml index dea0dbd76..9d953dba7 100644 --- a/pkg/component/base/testdata/componentTasks.yaml +++ b/pkg/component/base/testdata/componentTasks.yaml @@ -5,18 +5,15 @@ TASK_TEXT_EMBEDDINGS: properties: model: $ref: additional.yaml#/components/schemas/CreateEmbeddingRequest/properties/model - acceptFormats: - - string + type: string shortDescription: ID of the model to use uiOrder: 0 title: Model text: description: The text - acceptFormats: - - string + type: string uiOrder: 1 title: Text - type: string required: - text - model diff --git a/pkg/component/base/testdata/operatorTasks.yaml b/pkg/component/base/testdata/operatorTasks.yaml index 161c4618a..0f431d502 100644 --- a/pkg/component/base/testdata/operatorTasks.yaml +++ b/pkg/component/base/testdata/operatorTasks.yaml @@ -1,17 +1,10 @@ TASK_MARSHAL: input: description: Input - instillEditOnNodeFields: - - object uiOrder: 0 properties: object: description: Json object to be marshaled - instillAcceptFormats: - - object - - semi-structured/* - - structured/* - instillEditOnNodeFields: [] uiOrder: 0 instillUpstreamTypes: - reference @@ -24,14 +17,10 @@ TASK_MARSHAL: type: object output: description: Output - instillEditOnNodeFields: - - string uiOrder: 0 properties: string: description: Data - instillFormat: string - instillUIMultiline: true uiOrder: 0 title: Data type: string diff --git a/pkg/component/base/testdata/wantComponentDefinition.yaml b/pkg/component/base/testdata/wantComponentDefinition.yaml index 635fb4513..4b9fb34e8 100644 --- a/pkg/component/base/testdata/wantComponentDefinition.yaml +++ b/pkg/component/base/testdata/wantComponentDefinition.yaml @@ -6,13 +6,9 @@ documentationUrl: https://www.instill.tech/docs/component/ai/openai icon: OpenAI/openai.svg spec: componentSpecification: - instillFormat: object oneOf: - - instillFormat: object - properties: + - properties: condition: - instillAcceptFormats: - - string instillShortDescription: config whether the component will be executed or skipped instillUIOrder: 1 instillUpstreamTypes: @@ -23,45 +19,17 @@ spec: instillUIOrder: 0 properties: model: - anyOf: - - enum: - - text-embedding-ada-002 - instillUpstreamType: value - type: string - - instillUpstreamType: reference - pattern: ^\{.*\}$ - type: string - - instillUpstreamType: template - type: string + enum: + - text-embedding-ada-002 description: ID of the model to use - instillAcceptFormats: - - string instillShortDescription: ID of the model to use instillUIOrder: 0 - instillUpstreamTypes: - - value - - reference - - template title: Model type: string text: - anyOf: - - instillUpstreamType: value - type: string - - instillUpstreamType: reference - pattern: ^\{.*\}$ - type: string - - instillUpstreamType: template - type: string description: The text - instillAcceptFormats: - - string instillShortDescription: The text instillUIOrder: 1 - instillUpstreamTypes: - - value - - reference - - template title: Text type: string required: @@ -99,8 +67,6 @@ spec: properties: model: description: ID of the model to use - instillAcceptFormats: - - string enum: - text-embedding-ada-002 instillShortDescription: ID of the model to use @@ -109,8 +75,6 @@ spec: type: string text: description: The text - instillAcceptFormats: - - string instillShortDescription: The text instillUIOrder: 1 title: Text @@ -125,9 +89,7 @@ spec: properties: embedding: instillUIOrder: 0 - instillFormat: array items: - instillFormat: number title: Embedding type: number title: Embedding diff --git a/pkg/component/base/testdata/wantOperatorDefinition.yaml b/pkg/component/base/testdata/wantOperatorDefinition.yaml index 2f95bd8f6..8851b0875 100644 --- a/pkg/component/base/testdata/wantOperatorDefinition.yaml +++ b/pkg/component/base/testdata/wantOperatorDefinition.yaml @@ -9,32 +9,17 @@ spec: oneOf: - properties: condition: - instillAcceptFormats: - - string instillShortDescription: config whether the component will be executed or skipped instillUIOrder: 1 - instillUpstreamTypes: - - value - - template type: string input: description: Input instillUIOrder: 0 properties: object: - anyOf: - - instillUpstreamType: reference - pattern: ^\{.*\}$ - type: string description: Json object to be marshaled - instillAcceptFormats: - - object - - semi-structured/* - - structured/* instillShortDescription: Json object to be marshaled instillUIOrder: 0 - instillUpstreamTypes: - - reference title: Object required: - object @@ -55,13 +40,7 @@ spec: properties: object: description: Json object to be marshaled - instillAcceptFormats: - - object - - semi-structured/* - - structured/* instillUIOrder: 0 - instillUpstreamTypes: - - reference required: [] title: Object type: object diff --git a/pkg/component/data/bigquery/v0/README.mdx b/pkg/component/data/bigquery/v0/README.mdx index 148a57daf..f2f95fc37 100644 --- a/pkg/component/data/bigquery/v0/README.mdx +++ b/pkg/component/data/bigquery/v0/README.mdx @@ -37,7 +37,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | JSON Key File Contents (required) | `json-key` | string | Contents of the JSON key file with access to the bucket. | | BigQuery Project ID (required) | `project-id` | string | Fill in your BigQuery Project ID. | @@ -58,7 +58,7 @@ Insert data to BigQuery.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INSERT` | | Data | `data` | object | The data to be inserted to BigQuery. | @@ -71,7 +71,7 @@ Insert data to BigQuery.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Status of the upload operation. |
@@ -83,7 +83,7 @@ Read data from BigQuery.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_READ` | | Filtering | `filtering` | string | The filter to be applied to the data with SQL syntax, which starts with WHERE clause. | @@ -96,7 +96,7 @@ Read data from BigQuery.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Data](#read-data) | `data` | array[object] | The data to be read from BigQuery. |
diff --git a/pkg/component/data/bigquery/v0/config/setup.yaml b/pkg/component/data/bigquery/v0/config/setup.yaml index d0587c9b5..6ae4f3a23 100644 --- a/pkg/component/data/bigquery/v0/config/setup.yaml +++ b/pkg/component/data/bigquery/v0/config/setup.yaml @@ -2,37 +2,29 @@ additionalProperties: false properties: dataset-id: description: Fill in your BigQuery Dataset ID. - acceptFormats: - - string + type: string uiOrder: 2 title: BigQuery Dataset ID - format: string json-key: description: Contents of the JSON key file with access to the bucket. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: JSON Key File contents - format: string project-id: description: Fill in your BigQuery Project ID. - acceptFormats: - - string + type: string uiOrder: 1 title: BigQuery Project ID - format: string table-name: description: Fill in your BigQuery Table Name. - acceptFormats: - - string + type: string uiOrder: 3 title: BigQuery Table Name - format: string required: - json-key - project-id - dataset-id - table-name title: BigQuery Connection -format: object +type: object diff --git a/pkg/component/data/bigquery/v0/config/tasks.yaml b/pkg/component/data/bigquery/v0/config/tasks.yaml index bff3aabd1..335757553 100644 --- a/pkg/component/data/bigquery/v0/config/tasks.yaml +++ b/pkg/component/data/bigquery/v0/config/tasks.yaml @@ -10,10 +10,10 @@ TASK_INSERT: uiOrder: 0 required: [] title: Data - format: object + type: object required: [] title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -21,11 +21,11 @@ TASK_INSERT: description: Status of the upload operation. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_READ: shortDescription: Read data from BigQuery. input: @@ -37,10 +37,10 @@ TASK_READ: uiOrder: 0 required: [] title: Filtering - format: string + type: string required: [] title: Input - format: object + type: object output: uiOrder: 0 description: The data to be read from BigQuery. @@ -52,9 +52,9 @@ TASK_READ: items: title: Data item required: [] - format: object - format: array + type: object + type: array required: - data title: Output - format: object + type: object diff --git a/pkg/component/data/bigquery/v0/main.go b/pkg/component/data/bigquery/v0/main.go index 3328ca8b8..f70fb3d39 100644 --- a/pkg/component/data/bigquery/v0/main.go +++ b/pkg/component/data/bigquery/v0/main.go @@ -281,11 +281,9 @@ func constructTableProperties(tables []TableColumns) ([]*structpb.Struct, error) "title": column.Name, "uiOrder": idx, "description": "Column " + column.Name + " of table " + table.TableName, - "format": getInstillAcceptFormat(column.Type), + "type": getInstillType(column.Type), "upstreamTypes": instillUpstreamTypes, - "acceptFormats": []string{getInstillAcceptFormat(column.Type)}, "required": []string{}, - "type": getInstillAcceptFormat(column.Type), } } propertyStructPB, err := base.ConvertToStructpb(propertiesMap) @@ -298,7 +296,7 @@ func constructTableProperties(tables []TableColumns) ([]*structpb.Struct, error) return tableProperties, nil } -func getInstillAcceptFormat(tableType string) string { +func getInstillType(tableType string) string { switch tableType { case "STRING": return "string" diff --git a/pkg/component/data/chroma/v0/README.mdx b/pkg/component/data/chroma/v0/README.mdx index 728f22414..b9f0f6cc6 100644 --- a/pkg/component/data/chroma/v0/README.mdx +++ b/pkg/component/data/chroma/v0/README.mdx @@ -41,7 +41,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key (required) | `api-key` | string | Fill in your Chroma API key. | | Chroma URL Endpoint (required) | `url` | string | Fill in your Chroma hosted public URL endpoint with port, e.g http://1.2.3:8000. | @@ -60,7 +60,7 @@ Upsert multiple vector items into a collection, existing items will be updated
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_BATCH_UPSERT` | | Collection Name (required) | `collection-name` | string | The name of the collection to upsert the item into. | @@ -78,7 +78,7 @@ Upsert multiple vector items into a collection, existing items will be updated
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Batch add status. |
@@ -90,7 +90,7 @@ Upsert a vector item into a collection, existing item will be updated
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPSERT` | | Collection Name (required) | `collection-name` | string | The name of the collection to upsert the item into. | @@ -108,7 +108,7 @@ Upsert a vector item into a collection, existing item will be updated
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Add status. |
@@ -120,7 +120,7 @@ Perform a vector search on a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_QUERY` | | Collection Name (required) | `collection-name` | string | The name of the collection to perform vector similarity search on. | @@ -138,7 +138,7 @@ Perform a vector search on a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Result](#query-result) | `result` | object | Result of the vector search operation. | | Status | `status` | string | Vector search status. | @@ -151,7 +151,7 @@ Perform a vector search on a collection
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | IDs | `ids` | array | The ids returned from the vector search operation. | | [Items](#query-items) | `items` | array | The items returned from the vector search operation. | @@ -167,7 +167,7 @@ Delete vector items from a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE` | | Collection Name (required) | `collection-name` | string | The name of the collection to delete the object from. | @@ -183,7 +183,7 @@ Delete vector items from a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete status. |
@@ -195,7 +195,7 @@ Create a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_COLLECTION` | | Collection Name (required) | `collection-name` | string | The name of the collection to create. | @@ -211,7 +211,7 @@ Create a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Create collection status. |
@@ -223,7 +223,7 @@ Delete a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE_COLLECTION` | | Collection Name (required) | `collection-name` | string | The name of the collection to delete. | @@ -236,7 +236,7 @@ Delete a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete collection status. |
diff --git a/pkg/component/data/chroma/v0/config/setup.yaml b/pkg/component/data/chroma/v0/config/setup.yaml index 5457b8dc6..568f051ef 100644 --- a/pkg/component/data/chroma/v0/config/setup.yaml +++ b/pkg/component/data/chroma/v0/config/setup.yaml @@ -2,22 +2,18 @@ additionalProperties: false properties: api-key: description: Fill in your Chroma API key. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: API Key - format: string url: description: Fill in your Chroma hosted public URL endpoint with port, e.g http://1.2.3:8000. - acceptFormats: - - string + type: string instillSecret: false uiOrder: 1 title: Chroma URL Endpoint - format: string required: - api-key - url title: Chroma Connection -format: object +type: object diff --git a/pkg/component/data/chroma/v0/config/tasks.yaml b/pkg/component/data/chroma/v0/config/tasks.yaml index 5ae684abb..a8911ab86 100644 --- a/pkg/component/data/chroma/v0/config/tasks.yaml +++ b/pkg/component/data/chroma/v0/config/tasks.yaml @@ -5,65 +5,51 @@ TASK_QUERY: properties: collection-name: description: The name of the collection to perform vector similarity search on. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string vector: description: An array of dimensions for the vector query. - acceptFormats: - - array - - array + type: array uiOrder: 1 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Vector - format: array n-results: description: The N amount of items to return from the vector search operation. - acceptFormats: - - integer + type: integer uiOrder: 2 title: N Results - format: integer filter: description: The metadata filter to be applied to the data with Chroma where filter, please refer to [using-where-filters](https://docs.trychroma.com/guides#using-where-filters). - acceptFormats: - - json - - object + type: object uiOrder: 3 title: Filter required: [] - format: object filter-document: description: The document content filter to be applied to the data, please refer to [filtering-by-document-contents](https://docs.trychroma.com/guides#filtering-by-document-contents). - acceptFormats: - - string + type: string uiOrder: 4 title: Filter Document - format: string fields: description: The fields to be returned from the vector search operation. - acceptFormats: - - array + type: array uiOrder: 5 items: description: A field to be returned. example: field - format: string + type: string minItems: 1 title: Fields - format: array required: - collection-name - vector - n-results title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -71,7 +57,7 @@ TASK_QUERY: description: Vector search status. uiOrder: 0 title: Status - format: string + type: string result: description: Result of the vector search operation. uiOrder: 0 @@ -85,8 +71,8 @@ TASK_QUERY: items: description: An id of the item. example: c8faa-4b3b-4b3b-4b3b - format: string - format: array + type: string + type: array items: description: The items returned from the vector search operation. uiOrder: 1 @@ -94,9 +80,9 @@ TASK_QUERY: title: Items items: title: Point - format: object + type: object required: [] - format: array + type: array vectors: description: The vectors returned from the vector search operation. uiOrder: 2 @@ -108,9 +94,9 @@ TASK_QUERY: items: description: A dimension of the vector. example: 0.8167237 - format: number - format: array - format: array + type: number + type: array + type: array metadata: description: The metadata returned from the vector search operation. uiOrder: 3 @@ -118,16 +104,16 @@ TASK_QUERY: required: [] items: title: Metadatum - format: object + type: object required: [] - format: array + type: array required: [] - format: object + type: object required: - status - result title: Output - format: object + type: object TASK_BATCH_UPSERT: shortDescription: Upsert multiple vector items into a collection, existing items will be updated input: @@ -135,30 +121,22 @@ TASK_BATCH_UPSERT: properties: collection-name: description: The name of the collection to upsert the item into. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string array-id: description: The array of id. - acceptFormats: - - array + type: array uiOrder: 1 items: description: An id of the point. example: 1 - format: string + type: string minItems: 1 title: Array ID - format: array array-metadata: description: The array of vector metadata. - acceptFormats: - - array - - array - - array - - array + type: array uiOrder: 2 minItems: 1 title: Array Metadata @@ -166,56 +144,46 @@ TASK_BATCH_UPSERT: description: The vector metadata. title: Metadatum required: [] - format: object - format: array + type: object array-vector: description: The array of vector values. - acceptFormats: - - array + type: array uiOrder: 3 items: description: An array of dimensions for the vector value. - acceptFormats: - - array - - array + type: array items: description: A dimension of the vector. example: 0.8167237 - format: number - format: array + type: number minItems: 1 title: Array Vector - format: array array-document: description: The array of document string values. - acceptFormats: - - array + type: array uiOrder: 4 items: description: A document string value. example: document - format: string + type: string minItems: 1 title: Array Document - format: array array-uri: description: The array of uri. - acceptFormats: - - array + type: array uiOrder: 5 items: description: An uri of the point. - format: string + type: string minItems: 1 title: Array URI - format: array required: - collection-name - array-id - array-metadata - array-vector title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -223,11 +191,11 @@ TASK_BATCH_UPSERT: description: Batch add status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_UPSERT: shortDescription: Upsert a vector item into a collection, existing item will be updated input: @@ -235,61 +203,47 @@ TASK_UPSERT: properties: collection-name: description: The name of the collection to upsert the item into. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string id: description: The ID of the item. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string metadata: description: The vector metadata. - acceptFormats: - - json - - object + type: object uiOrder: 2 title: Metadata required: [] - format: object vector: description: An array of dimensions for the vector value. - acceptFormats: - - array - - array + type: array uiOrder: 3 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Vector - format: array document: description: The document string value. - acceptFormats: - - string + type: string uiOrder: 4 title: Document - format: string uri: description: The uri of the item. - acceptFormats: - - string + type: string uiOrder: 5 title: URI - format: string required: - collection-name - id - metadata - vector title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -297,11 +251,11 @@ TASK_UPSERT: description: Add status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DELETE: shortDescription: Delete vector items from a collection input: @@ -309,38 +263,29 @@ TASK_DELETE: properties: collection-name: description: The name of the collection to delete the object from. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string id: description: The ID of the item. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string filter: description: The metadata filter to be applied to the data with Chroma where filter, please refer to [using-where-filters](https://docs.trychroma.com/guides#using-where-filters). - acceptFormats: - - json - - object + type: object uiOrder: 2 title: Filter required: [] - format: object filter-document: description: The document content filter to be applied to the data, please refer to [filtering-by-document-contents](https://docs.trychroma.com/guides#filtering-by-document-contents). - acceptFormats: - - string + type: string uiOrder: 3 title: Filter Document - format: string required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -348,11 +293,11 @@ TASK_DELETE: description: Delete status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_CREATE_COLLECTION: shortDescription: Create a collection input: @@ -360,41 +305,31 @@ TASK_CREATE_COLLECTION: properties: collection-name: description: The name of the collection to create. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string metadata: description: The metadata of the collection. Please refer to [creating-inspecting-and-deleting-collection](https://docs.trychroma.com/guides#creating,-inspecting,-and-deleting-collections). - acceptFormats: - - json - - object + type: object uiOrder: 1 title: Config required: [] - format: object configuration: description: The configuration of the collection. Please refer to [creating-inspecting-and-deleting-collection](https://docs.trychroma.com/guides#creating,-inspecting,-and-deleting-collections). - acceptFormats: - - json - - object + type: object uiOrder: 2 title: Configuration required: [] - format: object get-or-create: description: If true, the collection will be created if it does not exist. - acceptFormats: - - boolean + type: boolean uiOrder: 3 title: Get or Create default: false - format: boolean required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -402,11 +337,11 @@ TASK_CREATE_COLLECTION: description: Create collection status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DELETE_COLLECTION: shortDescription: Delete a collection input: @@ -414,15 +349,13 @@ TASK_DELETE_COLLECTION: properties: collection-name: description: The name of the collection to delete. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -430,8 +363,8 @@ TASK_DELETE_COLLECTION: description: Delete collection status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object diff --git a/pkg/component/data/elasticsearch/v0/README.mdx b/pkg/component/data/elasticsearch/v0/README.mdx index 3fef0508b..9a90c9ef5 100644 --- a/pkg/component/data/elasticsearch/v0/README.mdx +++ b/pkg/component/data/elasticsearch/v0/README.mdx @@ -43,7 +43,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Cloud ID (required) | `cloud-id` | string | Fill in the Cloud ID for the Elasticsearch instance. | | API Key (required) | `api-key` | string | Fill in the API key for the Elasticsearch instance (please use encoded one). | @@ -62,7 +62,7 @@ Search for documents in Elasticsearch, support full text search
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEARCH` | | Index Name (required) | `index-name` | string | Name of the Elasticsearch index. | @@ -82,7 +82,7 @@ Search for documents in Elasticsearch, support full text search
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Search operation status. | | [Result](#search-result) | `result` | object | Result of the search operation. | @@ -95,7 +95,7 @@ Search for documents in Elasticsearch, support full text search
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Data](#search-data) | `data` | array | The data returned from the search operation. | | [Documents](#search-documents) | `documents` | array | The documents returned from the search operation. | @@ -110,7 +110,7 @@ Search for vector similarity search in Elasticsearch
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_VECTOR_SEARCH` | | Index Name (required) | `index-name` | string | Name of the Elasticsearch index. | @@ -131,7 +131,7 @@ Search for vector similarity search in Elasticsearch
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Search operation status. | | [Result](#vector-search-result) | `result` | object | Result of the vector search operation. | @@ -144,7 +144,7 @@ Search for vector similarity search in Elasticsearch
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Documents](#vector-search-documents) | `documents` | array | The documents returned from the vector search operation. | | IDs | `ids` | array | The ids returned from the vector search operation. | @@ -160,7 +160,7 @@ Index a document into Elasticsearch
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INDEX` | | Index Name (required) | `index-name` | string | Name of the Elasticsearch index. | @@ -175,7 +175,7 @@ Index a document into Elasticsearch
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Index operation status. |
@@ -187,7 +187,7 @@ Index multiple documents into Elasticsearch with bulk API
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_MULTI_INDEX` | | Index Name (required) | `index-name` | string | Name of the Elasticsearch index. | @@ -202,7 +202,7 @@ Index multiple documents into Elasticsearch with bulk API
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Index operation status. |
@@ -214,7 +214,7 @@ Update a document in Elasticsearch
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE` | | Index Name (required) | `index-name` | string | Name of the Elasticsearch index. | @@ -232,7 +232,7 @@ Update a document in Elasticsearch
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Update operation status. |
@@ -244,7 +244,7 @@ Delete documents from Elasticsearch
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE` | | Index Name (required) | `index-name` | string | Name of the Elasticsearch index. | @@ -261,7 +261,7 @@ Delete documents from Elasticsearch
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete operation status. |
@@ -273,7 +273,7 @@ Create an index in Elasticsearch
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_INDEX` | | Index Name (required) | `index-name` | string | Name of the Elasticsearch index. | @@ -287,7 +287,7 @@ Create an index in Elasticsearch
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Create index operation status. |
@@ -299,7 +299,7 @@ Delete an index in Elasticsearch
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE_INDEX` | | Index Name (required) | `index-name` | string | Name of the Elasticsearch index. | @@ -312,7 +312,7 @@ Delete an index in Elasticsearch
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete index operation status. |
diff --git a/pkg/component/data/elasticsearch/v0/config/setup.yaml b/pkg/component/data/elasticsearch/v0/config/setup.yaml index 0dae05871..1be709c2d 100644 --- a/pkg/component/data/elasticsearch/v0/config/setup.yaml +++ b/pkg/component/data/elasticsearch/v0/config/setup.yaml @@ -2,22 +2,18 @@ additionalProperties: false properties: api-key: description: Fill in the API key for the Elasticsearch instance (please use encoded one). - acceptFormats: - - string + type: string instillSecret: true uiOrder: 1 title: API Key - format: string cloud-id: description: Fill in the Cloud ID for the Elasticsearch instance. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: Cloud ID - format: string required: - api-key - cloud-id title: Elasticsearch Connection -format: object +type: object diff --git a/pkg/component/data/elasticsearch/v0/config/tasks.yaml b/pkg/component/data/elasticsearch/v0/config/tasks.yaml index 41670ff14..42ff315d4 100644 --- a/pkg/component/data/elasticsearch/v0/config/tasks.yaml +++ b/pkg/component/data/elasticsearch/v0/config/tasks.yaml @@ -5,32 +5,25 @@ TASK_INDEX: properties: index-name: description: Name of the Elasticsearch index. - acceptFormats: - - string + type: string uiOrder: 0 title: Index Name - format: string id: description: The ID of the document. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string data: description: Data to be indexed. - acceptFormats: - - json - - object + type: object uiOrder: 2 title: Data required: [] - format: object required: - index-name - data title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -39,11 +32,11 @@ TASK_INDEX: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_MULTI_INDEX: shortDescription: Index multiple documents into Elasticsearch with bulk API input: @@ -51,44 +44,35 @@ TASK_MULTI_INDEX: properties: index-name: description: Name of the Elasticsearch index. - acceptFormats: - - string + type: string uiOrder: 0 title: Index Name - format: string array-id: description: The array of id. - acceptFormats: - - array + type: array uiOrder: 1 items: description: An id of the document. example: 1 - format: string + type: string minItems: 1 title: Array ID - format: array array-data: description: Array data to be indexed. - acceptFormats: - - array - - array - - array - - array + type: array uiOrder: 2 title: Array Data items: description: The data to be inserted. title: Data required: [] - format: object + type: object minItems: 1 - format: array required: - index-name - array-data title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -97,11 +81,11 @@ TASK_MULTI_INDEX: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_UPDATE: shortDescription: Update a document in Elasticsearch input: @@ -109,58 +93,44 @@ TASK_UPDATE: properties: index-name: description: Name of the Elasticsearch index. - acceptFormats: - - string + type: string uiOrder: 0 title: Index Name - format: string id: description: The ID of the document. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string query: description: Full text search query for update task, query will be prioritised over filter if both are provided, if both query and filter are not provided, all documents will be selected. - acceptFormats: - - string + type: string shortDescription: Full text search query, (empty for all documents) uiOrder: 2 title: Query - format: string filter: description: The query dsl filter which starts with "query" field, please refer to [here](https://www.elastic.co/guide/en/elasticsearch/reference/current/query-filter-context.html). - acceptFormats: - - json - - object + type: object uiOrder: 3 title: Filter required: [] - format: object filter-sql: shortDescription: The filter sql to be applied to the data, if filter or id is provided, this field will be ignored description: The filter to be applied to the data with SQL syntax, which starts with WHERE clause, empty for no filter. uiOrder: 4 - acceptFormats: - - string + type: string title: Filter SQL - format: string update-data: description: Update data. - acceptFormats: - - json - - object + type: object uiOrder: 4 title: Update required: [] - format: object required: - index-name - update-data title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -169,11 +139,11 @@ TASK_UPDATE: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_SEARCH: shortDescription: Search for documents in Elasticsearch, support full text search input: @@ -181,76 +151,59 @@ TASK_SEARCH: properties: index-name: description: Name of the Elasticsearch index. - acceptFormats: - - string + type: string uiOrder: 1 title: Index Name - format: string id: description: The ID of the document. - acceptFormats: - - string + type: string uiOrder: 2 title: ID - format: string query: description: Full text search query for search task, query will be prioritised over filter if both are provided, if both query and filter are not provided, all documents will be selected. - acceptFormats: - - string + type: string shortDescription: Full text search query, (empty for all documents) uiOrder: 3 title: Query - format: string filter: description: The query dsl filter which starts with "query" field, please refer to [here](https://www.elastic.co/guide/en/elasticsearch/reference/current/query-filter-context.html). - acceptFormats: - - json - - object + type: object uiOrder: 4 title: Filter required: [] - format: object filter-sql: shortDescription: The filter sql to be applied to the data, if filter or id is provided, this field will be ignored description: The filter to be applied to the data with SQL syntax, which starts with WHERE clause, empty for no filter. uiOrder: 5 - acceptFormats: - - string + type: string title: Filter SQL - format: string size: description: Number of documents to return. If empty then all documents will be returned. - acceptFormats: - - integer + type: integer shortDescription: Size of documents to return, (empty for all documents) uiOrder: 6 title: Size - format: integer fields: description: The fields to return in the documents. If empty then all fields will be returned. - acceptFormats: - - array + type: array shortDescription: Fields to be returned, empty for all fields uiOrder: 7 title: Fields items: title: Field - format: string + type: string minItems: 1 - format: array min-score: description: Minimum score to consider for search results. If empty then no minimum score will be considered. - acceptFormats: - - number + type: number shortDescription: Minimum Score uiOrder: 8 title: Minimum Score - format: number required: - index-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -259,7 +212,7 @@ TASK_SEARCH: required: [] uiOrder: 0 title: Status - format: string + type: string result: description: Result of the search operation. uiOrder: 1 @@ -273,8 +226,8 @@ TASK_SEARCH: items: description: An id of the document. example: c8faa-4b3b-4b3b-4b3b - format: string - format: array + type: string + type: array documents: description: The documents returned from the search operation. uiOrder: 1 @@ -282,9 +235,9 @@ TASK_SEARCH: title: Documents items: title: Document - format: object + type: object required: [] - format: array + type: array data: description: The data returned from the search operation. uiOrder: 2 @@ -292,16 +245,16 @@ TASK_SEARCH: required: [] items: title: Datum - format: object + type: object required: [] - format: array + type: array required: [] - format: object + type: object required: - result - status title: Output - format: object + type: object TASK_VECTOR_SEARCH: shortDescription: Search for vector similarity search in Elasticsearch input: @@ -309,91 +262,71 @@ TASK_VECTOR_SEARCH: properties: index-name: description: Name of the Elasticsearch index. - acceptFormats: - - string + type: string uiOrder: 1 title: Index Name - format: string field: description: Field name of the vector to search for similar vectors. - acceptFormats: - - string + type: string shortDescription: Field name of the vector uiOrder: 2 title: Field - format: string query-vector: description: Query vector to search for similar vectors. - acceptFormats: - - array - - array + type: array shortDescription: '' uiOrder: 3 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Query Vector - format: array k: description: K of documents to do kNN vector search. - acceptFormats: - - integer + type: integer shortDescription: K of documents to return uiOrder: 4 title: K - format: integer num-candidates: description: Number of candidates to be considered for kNN vector search. Default to 2 times of k. - acceptFormats: - - integer + type: integer shortDescription: Number of candidates to be considered for kNN, default to 2 times of k uiOrder: 5 title: Num Candidates - format: integer filter: description: The query dsl filter which starts with "filter" field, please refer to [here](https://www.elastic.co/guide/en/elasticsearch/reference/current/knn-search.html#knn-search-filter-example). - acceptFormats: - - json - - object + type: object uiOrder: 6 title: Filter required: [] - format: object filter-sql: shortDescription: The filter sql to be applied to the data, if filter or id is provided, this field will be ignored description: The filter to be applied to the data with SQL syntax, which starts with WHERE clause, empty for no filter. uiOrder: 7 - acceptFormats: - - string + type: string title: Filter SQL - format: string fields: description: The fields to return in the documents. If empty then all fields will be returned. - acceptFormats: - - array + type: array shortDescription: Fields to be returned, empty for all fields uiOrder: 8 title: Fields items: title: Field - format: string + type: string minItems: 1 - format: array min-score: description: Minimum score to consider for search results. If empty then no minimum score will be considered. - acceptFormats: - - number + type: number shortDescription: Minimum Score uiOrder: 9 title: Minimum Score - format: number required: - index-name - field title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -402,7 +335,7 @@ TASK_VECTOR_SEARCH: required: [] uiOrder: 0 title: Status - format: string + type: string result: description: Result of the vector search operation. uiOrder: 1 @@ -416,8 +349,8 @@ TASK_VECTOR_SEARCH: items: description: An id of the document. example: c8faa-4b3b-4b3b-4b3b - format: string - format: array + type: string + type: array documents: description: The documents returned from the vector search operation. uiOrder: 1 @@ -425,9 +358,9 @@ TASK_VECTOR_SEARCH: title: Documents items: title: Document - format: object + type: object required: [] - format: array + type: array vectors: description: The vectors returned from the vector search operation. uiOrder: 2 @@ -439,9 +372,9 @@ TASK_VECTOR_SEARCH: items: description: A dimension of the vector. example: 0.8167237 - format: number - format: array - format: array + type: number + type: array + type: array metadata: description: The metadata returned from the vector search operation. uiOrder: 3 @@ -449,16 +382,16 @@ TASK_VECTOR_SEARCH: required: [] items: title: Metadatum - format: object + type: object required: [] - format: array + type: array required: [] - format: object + type: object required: - result - status title: Output - format: object + type: object TASK_DELETE: shortDescription: Delete documents from Elasticsearch input: @@ -466,49 +399,38 @@ TASK_DELETE: properties: index-name: description: Name of the Elasticsearch index. - acceptFormats: - - string + type: string uiOrder: 0 title: Index Name - format: string id: description: The ID of the document. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string query: description: Full text search query for delete task, query will be prioritised over filter if both are provided, if both query and filter are not provided, all documents will be selected. - acceptFormats: - - string + type: string shortDescription: Full text search query, (empty for all documents) uiOrder: 2 title: Query - format: string filter: description: The query dsl filter which starts with "query" field, please refer to [here](https://www.elastic.co/guide/en/elasticsearch/reference/current/query-filter-context.html). - acceptFormats: - - json - - object + type: object uiOrder: 3 title: Filter required: [] - format: object filter-sql: shortDescription: The filter sql to be applied to the data, if filter or id is provided, this field will be ignored description: The filter to be applied to the data with SQL syntax, which starts with WHERE clause, empty for no filter. uiOrder: 4 - acceptFormats: - - string + type: string required: [] title: Filter SQL - format: string required: - index-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -517,11 +439,11 @@ TASK_DELETE: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_CREATE_INDEX: shortDescription: Create an index in Elasticsearch input: @@ -529,25 +451,20 @@ TASK_CREATE_INDEX: properties: index-name: description: Name of the Elasticsearch index. - acceptFormats: - - string + type: string uiOrder: 0 title: Index Name - format: string mappings: description: Index mappings which starts with {"mappings":{"properties"}} field, please refer to [here](https://www.elastic.co/guide/en/elasticsearch/reference/current/dense-vector.html) for vector search and [here](https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-types.html) for other mappings. - acceptFormats: - - json - - object + type: object uiOrder: 1 title: Mappings required: [] - format: object required: - index-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -556,11 +473,11 @@ TASK_CREATE_INDEX: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DELETE_INDEX: shortDescription: Delete an index in Elasticsearch input: @@ -568,15 +485,13 @@ TASK_DELETE_INDEX: properties: index-name: description: Name of the Elasticsearch index. - acceptFormats: - - string + type: string uiOrder: 0 title: Index Name - format: string required: - index-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -585,8 +500,8 @@ TASK_DELETE_INDEX: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object diff --git a/pkg/component/data/googlecloudstorage/v0/README.mdx b/pkg/component/data/googlecloudstorage/v0/README.mdx index cbd60f2ec..b697371e3 100644 --- a/pkg/component/data/googlecloudstorage/v0/README.mdx +++ b/pkg/component/data/googlecloudstorage/v0/README.mdx @@ -38,7 +38,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | JSON Key File Contents (required) | `json-key` | string | Contents of the JSON key file with access to the bucket. | @@ -56,7 +56,7 @@ Upload data to Google Cloud Storage.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPLOAD` | | Bucket Name (required) | `bucket-name` | string | Name of the bucket to be used for object storage. | @@ -71,7 +71,7 @@ Upload data to Google Cloud Storage.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Authenticated URL (optional) | `authenticated-url` | string | Only users granted permission can access the object with this link. | | Gsutil URI (optional) | `gsutil-uri` | string | File path to this resource in Cloud Storage. | @@ -87,7 +87,7 @@ Read objects from Google Cloud Storage.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_READ_OBJECTS` | | Bucket Name (required) | `bucket-name` | string | Name of the bucket to be used for object storage. | @@ -108,7 +108,7 @@ Read objects from Google Cloud Storage.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Text Objects](#read-objects-text-objects) (optional) | `text-objects` | array[object] | The text objects in the bucket. | | [Image Objects](#read-objects-image-objects) (optional) | `image-objects` | array[object] | The image objects in the bucket. | @@ -124,7 +124,7 @@ Read objects from Google Cloud Storage.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Attributes](#read-objects-attributes) | `attributes` | object | The attributes of the object. | | Data | `data` | string | The data of the object. | @@ -134,7 +134,7 @@ Read objects from Google Cloud Storage.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content Disposition | `content-disposition` | string | The content disposition of the object. | | Content Encoding | `content-encoding` | string | The content encoding of the object. | @@ -152,7 +152,7 @@ Read objects from Google Cloud Storage.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Attributes](#read-objects-attributes) | `attributes` | object | The attributes of the object. | | Data | `data` | string | The data of the object. | @@ -162,7 +162,7 @@ Read objects from Google Cloud Storage.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content Disposition | `content-disposition` | string | The content disposition of the object. | | Content Encoding | `content-encoding` | string | The content encoding of the object. | @@ -180,7 +180,7 @@ Read objects from Google Cloud Storage.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Attributes](#read-objects-attributes) | `attributes` | object | The attributes of the object. | | Data | `data` | string | The data of the object. | @@ -190,7 +190,7 @@ Read objects from Google Cloud Storage.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content Disposition | `content-disposition` | string | The content disposition of the object. | | Content Encoding | `content-encoding` | string | The content encoding of the object. | @@ -208,7 +208,7 @@ Read objects from Google Cloud Storage.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Attributes](#read-objects-attributes) | `attributes` | object | The attributes of the object. | | Data | `data` | string | The data of the object. | @@ -218,7 +218,7 @@ Read objects from Google Cloud Storage.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content Disposition | `content-disposition` | string | The content disposition of the object. | | Content Encoding | `content-encoding` | string | The content encoding of the object. | @@ -236,7 +236,7 @@ Read objects from Google Cloud Storage.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Attributes](#read-objects-attributes) | `attributes` | object | The attributes of the object. | | Data | `data` | string | The data of the object. | @@ -246,7 +246,7 @@ Read objects from Google Cloud Storage.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content Disposition | `content-disposition` | string | The content disposition of the object. | | Content Encoding | `content-encoding` | string | The content encoding of the object. | @@ -268,7 +268,7 @@ Read objects from Google Cloud Storage.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_BUCKET` | | Bucket Name (required) | `bucket-name` | string | Name of the bucket to be used for object storage. | @@ -283,7 +283,7 @@ Read objects from Google Cloud Storage.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Result (optional) | `result` | string | The result of the operation. | | Bucket Name (optional) | `name` | string | The name of the bucket. | diff --git a/pkg/component/data/googlecloudstorage/v0/config/setup.yaml b/pkg/component/data/googlecloudstorage/v0/config/setup.yaml index 2a09e9b79..9ae1b8f2f 100644 --- a/pkg/component/data/googlecloudstorage/v0/config/setup.yaml +++ b/pkg/component/data/googlecloudstorage/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: json-key: description: Contents of the JSON key file with access to the bucket. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 1 title: JSON Key File contents - format: string required: - json-key title: Google Cloud Storage Connection -format: object +type: object diff --git a/pkg/component/data/googlecloudstorage/v0/config/tasks.yaml b/pkg/component/data/googlecloudstorage/v0/config/tasks.yaml index a21f396e6..24198e343 100644 --- a/pkg/component/data/googlecloudstorage/v0/config/tasks.yaml +++ b/pkg/component/data/googlecloudstorage/v0/config/tasks.yaml @@ -1,17 +1,15 @@ $defs: bucket-name: description: Name of the bucket to be used for object storage. - acceptFormats: - - string + type: string instillSecret: false uiOrder: 0 title: Bucket Name - format: string data: description: The data of the object. uiOrder: 0 title: Data - format: string + type: string attributes: description: The attributes of the object. properties: @@ -19,59 +17,57 @@ $defs: description: The name of the object. uiOrder: 0 title: Object Name - format: string + type: string content-type: description: The content type of the object. uiOrder: 1 title: Content Type - format: string + type: string content-language: description: The content language of the object. uiOrder: 2 title: Content Language - format: string + type: string owner: description: The owner of the object. uiOrder: 3 title: Owner - format: string + type: string size: description: The size of the object. uiOrder: 4 title: Size - format: integer + type: integer content-encoding: description: The content encoding of the object. uiOrder: 5 title: Content Encoding - format: string + type: string content-disposition: description: The content disposition of the object. uiOrder: 6 title: Content Disposition - format: string + type: string media-link: description: The media link of the object. uiOrder: 7 title: Media Link - format: string + type: string metadata: description: The object metadata. uiOrder: 8 title: Metadata required: [] - format: object + type: object storage-class: description: The storage class of the object. uiOrder: 9 title: Storage Class - format: string - acceptFormats: - - object + type: string + type: object required: [] uiOrder: 1 title: Attributes - format: object TASK_UPLOAD: shortDescription: Upload data to Google Cloud Storage. input: @@ -81,56 +77,52 @@ TASK_UPLOAD: $ref: '#/$defs/bucket-name' data: description: The data to be saved in the object. - acceptFormats: - - '*' + type: string uiOrder: 1 title: Data - format: string object-name: description: The name of the object to be created. - acceptFormats: - - string + type: string uiOrder: 0 title: Object Name - format: string required: - object-name - bucket-name - data title: Input - format: object + type: object output: uiOrder: 0 properties: authenticated-url: description: Only users granted permission can access the object with this link. - format: string + type: string uiOrder: 0 title: Authenticated URL gsutil-uri: description: File path to this resource in Cloud Storage. - format: string + type: string uiOrder: 1 title: Gsutil URI public-access: description: Whether the object is publicly accessible. uiOrder: 2 title: Public Access - format: boolean + type: boolean public-url: description: Anyone with this link can access the object on the public Internet. uiOrder: 3 title: Public URL - format: string + type: string status: description: Status of the upload operation. uiOrder: 4 title: Upload Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_READ_OBJECTS: shortDescription: Read objects from Google Cloud Storage. input: @@ -140,71 +132,54 @@ TASK_READ_OBJECTS: $ref: '#/$defs/bucket-name' delimiter: description: The delimiter to use when listing objects. - acceptFormats: - - string + type: string uiOrder: 1 title: Delimiter - format: string prefix: description: The prefix to use when listing objects. - acceptFormats: - - string + type: string uiOrder: 2 title: Prefix - format: string versions: description: Whether to list all versions of an object. - acceptFormats: - - boolean + type: boolean uiOrder: 3 title: Versions - format: boolean start-offset: description: The offset to start listing objects from. - acceptFormats: - - string + type: string uiOrder: 4 title: Start Offset - format: string end-offset: description: The offset to stop listing objects at. - acceptFormats: - - string + type: string uiOrder: 5 title: End Offset - format: string include-trailing-delimiter: description: Whether to include the delimiter in the object name. - acceptFormats: - - boolean + type: boolean uiOrder: 6 title: Include Trailing Delimiter - format: boolean match-glob: description: Whether to match objects using a glob pattern. - acceptFormats: - - string + type: string uiOrder: 7 title: Match Glob - format: string include-folders-as-prefixes: description: Whether to include folders as prefixes. - acceptFormats: - - boolean + type: boolean uiOrder: 8 title: Include Folders As Prefixes - format: boolean required: - bucket-name title: Input - format: object + type: object output: uiOrder: 0 properties: text-objects: description: The text objects in the bucket. - acceptFormats: - - array + type: array uiOrder: 0 title: Text Objects items: @@ -214,12 +189,10 @@ TASK_READ_OBJECTS: attributes: $ref: '#/$defs/attributes' required: [] - format: object - format: array + type: object image-objects: description: The image objects in the bucket. - acceptFormats: - - array + type: array uiOrder: 1 title: Image Objects items: @@ -229,12 +202,10 @@ TASK_READ_OBJECTS: attributes: $ref: '#/$defs/attributes' required: [] - format: object - format: array + type: object document-objects: description: The document objects in the bucket. - acceptFormats: - - array + type: array uiOrder: 2 title: Document Objects items: @@ -245,12 +216,10 @@ TASK_READ_OBJECTS: $ref: '#/$defs/attributes' required: [] title: Object - format: object - format: array + type: object audio-objects: description: The audio objects in the bucket. - acceptFormats: - - array + type: array uiOrder: 3 title: Audio Objects items: @@ -261,12 +230,10 @@ TASK_READ_OBJECTS: $ref: '#/$defs/attributes' required: [] title: Object - format: object - format: array + type: object video-objects: description: The video objects in the bucket. - acceptFormats: - - array + type: array uiOrder: 4 title: Video Objects items: @@ -277,11 +244,10 @@ TASK_READ_OBJECTS: $ref: '#/$defs/attributes' required: [] title: Object - format: object - format: array + type: object required: [] title: Output - format: object + type: object TASK_CREATE_BUCKET: shortDescription: Read objects from Google Cloud Storage. input: @@ -291,23 +257,19 @@ TASK_CREATE_BUCKET: $ref: '#/$defs/bucket-name' project-id: description: The project ID to create the bucket in. - acceptFormats: - - string + type: string uiOrder: 1 title: Project ID - format: string location: description: The location to create the bucket in. - acceptFormats: - - string + type: string uiOrder: 2 title: Location - format: string required: - bucket-name - project-id title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -315,17 +277,17 @@ TASK_CREATE_BUCKET: description: The result of the operation. uiOrder: 0 title: Result - format: string + type: string name: description: The name of the bucket. uiOrder: 1 title: Bucket Name - format: string + type: string location: description: The location of the bucket. uiOrder: 2 title: Location - format: string + type: string required: [] title: Output - format: object + type: object diff --git a/pkg/component/data/googledrive/v0/README.mdx b/pkg/component/data/googledrive/v0/README.mdx index d815edb5d..d1551e6f9 100644 --- a/pkg/component/data/googledrive/v0/README.mdx +++ b/pkg/component/data/googledrive/v0/README.mdx @@ -38,7 +38,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Refresh Token | `refresh-token` | string | Refresh token for the Google Drive API. For more information about how to create tokens, please refer to the Google Drive API documentation and OAuth 2.0 documentation. | @@ -56,7 +56,7 @@ Read a file content and metadata from Google Drive.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_READ_FILE` | | File ID (required) | `shared-link` | string | Shared link of the file. You can get the shared link by right-clicking on the file and selecting `Copy link`. | @@ -69,7 +69,7 @@ Read a file content and metadata from Google Drive.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [File](#read-file-file) | `file` | object | File in Google Drive. |
@@ -81,7 +81,7 @@ Read a file content and metadata from Google Drive.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content | `content` | string | Base64 encoded content of the binary file without the `data:[MIME_TYPE];base64,` prefix. Google Sheets will be exported as CSV, Google Docs as PDF, and Google Slides as PDF. If the file is not a Google file, the content will be the same as the original file. | | Created time | `created-time` | string | Time when the file was created. Format: `YYYY-MM-DDTHH:MM:SSZ`. | @@ -104,7 +104,7 @@ Read metadata and content of files under the specified folder in Google Drive.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_READ_FOLDER` | | File ID (required) | `shared-link` | string | Shared link of the file. You can get the shared link by right-clicking on the file and selecting `Copy link`. | @@ -118,7 +118,7 @@ Read metadata and content of files under the specified folder in Google Drive.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Files](#read-folder-files) | `files` | array[object] | List of files under the specified folder. |
@@ -130,7 +130,7 @@ Read metadata and content of files under the specified folder in Google Drive.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content | `content` | string | Base64 encoded content of the binary file without the `data:[MIME_TYPE];base64,` prefix. Google Sheets will be exported as CSV, Google Docs as PDF, and Google Slides as PDF. If the file is not a Google file, the content will be the same as the original file. | | Created time | `created-time` | string | Time when the file was created. Format: `YYYY-MM-DDTHH:MM:SSZ`. | diff --git a/pkg/component/data/googledrive/v0/config/setup.yaml b/pkg/component/data/googledrive/v0/config/setup.yaml index dbe993ac1..33b9ffcf9 100644 --- a/pkg/component/data/googledrive/v0/config/setup.yaml +++ b/pkg/component/data/googledrive/v0/config/setup.yaml @@ -2,12 +2,10 @@ properties: refresh-token: description: Refresh token for the Google Drive API. For more information about how to create tokens, please refer to the Google Drive API documentation and OAuth 2.0 documentation. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 1 title: Refresh Token - format: string required: [] instillOAuthConfig: authUrl: https://accounts.google.com/o/oauth2/auth @@ -18,4 +16,4 @@ instillOAuthConfig: - https://www.googleapis.com/auth/userinfo.email - https://www.googleapis.com/auth/userinfo.profile title: Google Drive Connection -format: object +type: object diff --git a/pkg/component/data/googledrive/v0/config/tasks.yaml b/pkg/component/data/googledrive/v0/config/tasks.yaml index 8b0144cf4..de58691a7 100644 --- a/pkg/component/data/googledrive/v0/config/tasks.yaml +++ b/pkg/component/data/googledrive/v0/config/tasks.yaml @@ -7,60 +7,60 @@ $defs: description: Unique ID of the file. uiOrder: 0 title: ID - format: string + type: string name: description: Name of the file. The file extension will be added automatically based on the exported MIME type. For example, Google Sheets will be exported as CSV, Google Docs as PDF, and Google Slides as PDF. If the file is a Google Sheet and the name is `MySheet`, the exported file will be `MySheet.csv`. If the file is not a Google file, the name will be used as is. uiOrder: 1 title: Name - format: string + type: string content: description: Base64 encoded content of the binary file without the `data:[MIME_TYPE];base64,` prefix. Google Sheets will be exported as CSV, Google Docs as PDF, and Google Slides as PDF. If the file is not a Google file, the content will be the same as the original file. uiOrder: 2 title: Content - format: string + type: string created-time: description: 'Time when the file was created. Format: `YYYY-MM-DDTHH:MM:SSZ`.' uiOrder: 3 title: Created time - format: string + type: string modified-time: description: 'Time when the file was last modified. Format: `YYYY-MM-DDTHH:MM:SSZ`.' uiOrder: 4 title: Modified time - format: string + type: string size: description: Size of the file in bytes. uiOrder: 5 title: Size - format: integer + type: integer mime-type: description: MIME type of the file. For example, `application/pdf`, `text/csv`, `image/jpeg`, etc. uiOrder: 6 title: MIME type - format: string + type: string md5-checksum: description: MD5 checksum of the file. This reflects every change made to the file on the server, even those not visible to the user. uiOrder: 7 title: MD5 checksum - format: string + type: string version: description: Version of the file in Google Drive. uiOrder: 8 title: Version - format: integer + type: integer web-view-link: description: Link for opening the file in a relevant Google editor or viewer in a browser. Usually, web view link is same as shared link. uiOrder: 9 title: Web View Link - format: string + type: string web-content-link: description: Link for downloading the content of the file in a browser. uiOrder: 10 title: Web Content Link - format: string + type: string required: - id - name @@ -71,12 +71,12 @@ $defs: - version - web-view-link title: File - format: object + type: object shared-link: description: Shared link of the file. You can get the shared link by right-clicking on the file and selecting `Copy link`. uiOrder: 0 title: File ID - format: string + type: string TASK_READ_FILE: shortDescription: Read a file content and metadata from Google Drive. input: @@ -88,7 +88,7 @@ TASK_READ_FILE: required: - shared-link title: Input - format: object + type: object output: uiOrder: 1 properties: @@ -97,7 +97,7 @@ TASK_READ_FILE: required: - file title: Output - format: object + type: object TASK_READ_FOLDER: shortDescription: Read metadata and content of files under the specified folder in Google Drive. input: @@ -110,11 +110,11 @@ TASK_READ_FOLDER: description: Whether to read the content of the files under the folder. uiOrder: 1 title: Read Content - format: boolean + type: boolean required: - shared-link title: Input - format: object + type: object output: description: Output. uiOrder: 1 @@ -126,8 +126,8 @@ TASK_READ_FOLDER: $ref: '#/$defs/file' required: [] title: Files - format: array + type: array required: - files title: Output - format: object + type: object diff --git a/pkg/component/data/googlesheets/v0/README.mdx b/pkg/component/data/googlesheets/v0/README.mdx index 016af00e0..65cd1b21f 100644 --- a/pkg/component/data/googlesheets/v0/README.mdx +++ b/pkg/component/data/googlesheets/v0/README.mdx @@ -51,7 +51,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Refresh Token | `refresh-token` | string | Refresh token for the Google Sheets API. For more information about how to create tokens, please refer to the Google Sheets API documentation and OAuth 2.0 documentation. | @@ -69,7 +69,7 @@ Create a new Google Sheets spreadsheet with multiple sheets.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_SPREADSHEET` | | Title | `title` | string | Title of the new spreadsheet. | @@ -86,7 +86,7 @@ Configuration for sheets to create.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Headers | `headers` | array | Column headers for the sheet. | | Sheet Name | `name` | string | Name of the sheet. | @@ -97,7 +97,7 @@ Configuration for sheets to create.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Spreadsheet ID | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. |
@@ -109,7 +109,7 @@ Delete a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE_SPREADSHEET` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -122,7 +122,7 @@ Delete a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Success | `success` | boolean | Result of the operation. |
@@ -134,7 +134,7 @@ Add a new sheet to an existing Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_ADD_SHEET` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -149,7 +149,7 @@ Add a new sheet to an existing Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Success | `success` | boolean | Result of the operation. |
@@ -161,7 +161,7 @@ Remove a sheet from a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE_SHEET` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -175,7 +175,7 @@ Remove a sheet from a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Success | `success` | boolean | Result of the operation. |
@@ -187,7 +187,7 @@ Add a new column to a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_SPREADSHEET_COLUMN` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -202,7 +202,7 @@ Add a new column to a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Success | `success` | boolean | Result of the operation. |
@@ -214,7 +214,7 @@ Delete a column from a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE_SPREADSHEET_COLUMN` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -229,7 +229,7 @@ Delete a column from a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Success | `success` | boolean | Result of the operation. |
@@ -241,7 +241,7 @@ List all rows in a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_LIST_ROWS` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -257,7 +257,7 @@ List all rows in a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Rows Data](#list-rows-rows-data) | `rows` | array[object] | Multiple rows data with row numbers and data. |
@@ -269,7 +269,7 @@ List all rows in a Google Sheets spreadsheet.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Row Number | `row-number` | number | Row number to update (1-based index) | | Row Data | `row-value` | json | Row data in JSON format where keys are column names and values are the corresponding cell values | @@ -283,7 +283,7 @@ Find multiple rows based on column value in a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_LOOKUP_ROWS` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -299,7 +299,7 @@ Find multiple rows based on column value in a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Rows Data](#lookup-rows-rows-data) | `rows` | array[object] | Multiple rows data with row numbers and data. |
@@ -311,7 +311,7 @@ Find multiple rows based on column value in a Google Sheets spreadsheet.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Row Number | `row-number` | number | Row number to update (1-based index) | | Row Data | `row-value` | json | Row data in JSON format where keys are column names and values are the corresponding cell values | @@ -325,7 +325,7 @@ Get a single row from a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_ROW` | | Row Number (required) | `row-number` | number | The row number to retrieve (1-based index). | @@ -340,7 +340,7 @@ Get a single row from a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Row Data](#get-row-row-data) | `row` | object | Row data with row number and data. |
@@ -352,7 +352,7 @@ Get a single row from a Google Sheets spreadsheet.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Row Number | `row-number` | number | Row number to update (1-based index) | | Row Data | `row-value` | json | Row data in JSON format where keys are column names and values are the corresponding cell values | @@ -366,7 +366,7 @@ Get multiple rows from a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_MULTIPLE_ROWS` | | Row Numbers (required) | `row-numbers` | array[integer] | The row numbers to retrieve (1-based indices). | @@ -381,7 +381,7 @@ Get multiple rows from a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Rows Data](#get-multiple-rows-rows-data) | `rows` | array[object] | Multiple rows data with row numbers and data. |
@@ -393,7 +393,7 @@ Get multiple rows from a Google Sheets spreadsheet.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Row Number | `row-number` | number | Row number to update (1-based index) | | Row Data | `row-value` | json | Row data in JSON format where keys are column names and values are the corresponding cell values | @@ -407,7 +407,7 @@ Insert a single row into a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INSERT_ROW` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -422,7 +422,7 @@ Insert a single row into a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Row Data](#insert-row-row-data) | `row` | object | Row data with row number and data. |
@@ -434,7 +434,7 @@ Insert a single row into a Google Sheets spreadsheet.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Row Number | `row-number` | number | Row number to update (1-based index) | | Row Data | `row-value` | json | Row data in JSON format where keys are column names and values are the corresponding cell values | @@ -448,7 +448,7 @@ Insert multiple rows into a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INSERT_MULTIPLE_ROWS` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -463,7 +463,7 @@ Insert multiple rows into a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Rows Data](#insert-multiple-rows-rows-data) | `rows` | array[object] | Multiple rows data with row numbers and data. |
@@ -475,7 +475,7 @@ Insert multiple rows into a Google Sheets spreadsheet.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Row Number | `row-number` | number | Row number to update (1-based index) | | Row Data | `row-value` | json | Row data in JSON format where keys are column names and values are the corresponding cell values | @@ -489,7 +489,7 @@ Update a row in a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE_ROW` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -507,7 +507,7 @@ Row data with row number and data.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Row Number | `row-number` | number | Row number to update (1-based index) | | Row Data | `row-value` | json | Row data in JSON format where keys are column names and values are the corresponding cell values | @@ -518,7 +518,7 @@ Row data with row number and data.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Row Data](#update-row-row-data) | `row` | object | Row data with row number and data. |
@@ -530,7 +530,7 @@ Row data with row number and data.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Row Number | `row-number` | number | Row number to update (1-based index) | | Row Data | `row-value` | json | Row data in JSON format where keys are column names and values are the corresponding cell values | @@ -544,7 +544,7 @@ Update multiple rows in a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE_MULTIPLE_ROWS` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -562,7 +562,7 @@ Multiple rows data with row numbers and data.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Row Number | `row-number` | number | Row number to update (1-based index) | | Row Data | `row-value` | json | Row data in JSON format where keys are column names and values are the corresponding cell values | @@ -573,7 +573,7 @@ Multiple rows data with row numbers and data.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Rows Data](#update-multiple-rows-rows-data) | `rows` | array[object] | Multiple rows data with row numbers and data. |
@@ -585,7 +585,7 @@ Multiple rows data with row numbers and data.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Row Number | `row-number` | number | Row number to update (1-based index) | | Row Data | `row-value` | json | Row data in JSON format where keys are column names and values are the corresponding cell values | @@ -599,7 +599,7 @@ Delete a row from a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE_ROW` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -614,7 +614,7 @@ Delete a row from a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Success | `success` | boolean | Result of the operation. |
@@ -626,7 +626,7 @@ Delete multiple rows from a Google Sheets spreadsheet.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE_MULTIPLE_ROWS` | | Spreadsheet ID (required) | `shared-link` | string | Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. | @@ -641,7 +641,7 @@ Delete multiple rows from a Google Sheets spreadsheet.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Success | `success` | boolean | Result of the operation. |
diff --git a/pkg/component/data/googlesheets/v0/config/setup.yaml b/pkg/component/data/googlesheets/v0/config/setup.yaml index 25b883b66..56b15716f 100644 --- a/pkg/component/data/googlesheets/v0/config/setup.yaml +++ b/pkg/component/data/googlesheets/v0/config/setup.yaml @@ -2,12 +2,10 @@ properties: refresh-token: description: Refresh token for the Google Sheets API. For more information about how to create tokens, please refer to the Google Sheets API documentation and OAuth 2.0 documentation. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 1 title: Refresh Token - format: string required: [] instillOAuthConfig: authUrl: https://accounts.google.com/o/oauth2/auth @@ -18,4 +16,4 @@ instillOAuthConfig: - https://www.googleapis.com/auth/userinfo.email - https://www.googleapis.com/auth/userinfo.profile title: Google Drive Connection -format: object +type: object diff --git a/pkg/component/data/googlesheets/v0/config/tasks.yaml b/pkg/component/data/googlesheets/v0/config/tasks.yaml index 7acfc791d..f0c0c389e 100644 --- a/pkg/component/data/googlesheets/v0/config/tasks.yaml +++ b/pkg/component/data/googlesheets/v0/config/tasks.yaml @@ -3,45 +3,45 @@ $defs: description: Shared link of the spreadsheet. You can get the shared link by clicking 'Share' button and selecting 'Copy link'. uiOrder: 0 title: Spreadsheet ID - format: string + type: string headers: description: Column headers for the sheet. items: - format: string + type: string uiOrder: 1 title: Headers - format: array + type: array sheet-name: description: Name of the sheet. uiOrder: 2 title: Sheet Name - format: string + type: string column-name: description: Name of the column. uiOrder: 3 title: Column Name - format: string + type: string row-number: description: Row number to update (1-based index). uiOrder: 4 title: Row Number - format: number + type: number row-numbers: description: Row numbers to update (1-based indices). items: - format: integer + type: integer uiOrder: 5 title: Row Numbers - format: array + type: array row-value: description: Row data in JSON format where keys are column names and values are the corresponding cell values title: Row Data uiOrder: 6 additionalProperties: description: Cell value for the corresponding column - format: string + type: string required: [] - format: json + type: json row: description: Row data with row number and data. uiOrder: 7 @@ -51,26 +51,26 @@ $defs: description: Row number to update (1-based index) title: Row Number uiOrder: 0 - format: number + type: number row-value: $ref: '#/$defs/row-value' uiOrder: 1 required: - row-number - data - format: object + type: object rows: description: Multiple rows data with row numbers and data. items: $ref: '#/$defs/row' uiOrder: 8 title: Rows Data - format: array + type: array success: description: Result of the operation. uiOrder: 9 title: Success - format: boolean + type: boolean TASK_CREATE_SPREADSHEET: shortDescription: Create a new Google Sheets spreadsheet with multiple sheets. input: @@ -80,7 +80,7 @@ TASK_CREATE_SPREADSHEET: description: Title of the new spreadsheet. uiOrder: 0 title: Title - format: string + type: string sheets: title: Sheets description: Configuration for sheets to create. @@ -92,14 +92,14 @@ TASK_CREATE_SPREADSHEET: $ref: '#/$defs/headers' required: - name - format: object + type: object uiOrder: 1 - format: array + type: array required: - name - sheets title: Input - format: object + type: object output: properties: shared-link: @@ -107,7 +107,7 @@ TASK_CREATE_SPREADSHEET: required: - shared-link title: Output - format: object + type: object TASK_DELETE_SPREADSHEET: shortDescription: Delete a Google Sheets spreadsheet. input: @@ -118,7 +118,7 @@ TASK_DELETE_SPREADSHEET: required: - shared-link title: Input - format: object + type: object output: properties: success: @@ -126,7 +126,7 @@ TASK_DELETE_SPREADSHEET: required: - success title: Output - format: object + type: object TASK_ADD_SHEET: shortDescription: Add a new sheet to an existing Google Sheets spreadsheet. input: @@ -142,7 +142,7 @@ TASK_ADD_SHEET: - shared-link - sheet-name title: Input - format: object + type: object output: properties: success: @@ -150,7 +150,7 @@ TASK_ADD_SHEET: required: - success title: Output - format: object + type: object TASK_DELETE_SHEET: shortDescription: Remove a sheet from a Google Sheets spreadsheet. input: @@ -164,7 +164,7 @@ TASK_DELETE_SHEET: - shared-link - sheet-name title: Input - format: object + type: object output: properties: success: @@ -172,7 +172,7 @@ TASK_DELETE_SHEET: required: - success title: Output - format: object + type: object TASK_CREATE_SPREADSHEET_COLUMN: shortDescription: Add a new column to a Google Sheets spreadsheet. input: @@ -189,7 +189,7 @@ TASK_CREATE_SPREADSHEET_COLUMN: - column-name - sheet-name title: Input - format: object + type: object output: properties: success: @@ -197,7 +197,7 @@ TASK_CREATE_SPREADSHEET_COLUMN: required: - success title: Output - format: object + type: object TASK_DELETE_SPREADSHEET_COLUMN: shortDescription: Delete a column from a Google Sheets spreadsheet. input: @@ -214,7 +214,7 @@ TASK_DELETE_SPREADSHEET_COLUMN: - column-name - sheet-name title: Input - format: object + type: object output: properties: success: @@ -222,7 +222,7 @@ TASK_DELETE_SPREADSHEET_COLUMN: required: - success title: Output - format: object + type: object TASK_GET_ROW: shortDescription: Get a single row from a Google Sheets spreadsheet. input: @@ -237,13 +237,13 @@ TASK_GET_ROW: minimum: 1 title: Row Number uiOrder: 0 - format: number + type: number required: - shared-link - row-number - sheet-name title: Input - format: object + type: object output: properties: row: @@ -251,7 +251,7 @@ TASK_GET_ROW: required: - row title: Output - format: object + type: object TASK_GET_MULTIPLE_ROWS: shortDescription: Get multiple rows from a Google Sheets spreadsheet. input: @@ -265,16 +265,16 @@ TASK_GET_MULTIPLE_ROWS: description: The row numbers to retrieve (1-based indices). items: minimum: 1 - format: integer + type: integer title: Row Numbers uiOrder: 0 - format: array + type: array required: - shared-link - row-numbers - sheet-name title: Input - format: object + type: object output: properties: rows: @@ -282,7 +282,7 @@ TASK_GET_MULTIPLE_ROWS: required: - rows title: Output - format: object + type: object TASK_LIST_ROWS: shortDescription: List all rows in a Google Sheets spreadsheet. input: @@ -298,18 +298,18 @@ TASK_LIST_ROWS: default: 2 title: Start Row uiOrder: 0 - format: number + type: number end-row: description: The ending row number to retrieve (1-based index). minimum: 1 title: End Row uiOrder: 1 - format: number + type: number required: - shared-link - sheet-name title: Input - format: object + type: object output: properties: rows: @@ -317,7 +317,7 @@ TASK_LIST_ROWS: required: - rows title: Output - format: object + type: object TASK_LOOKUP_ROWS: shortDescription: Find multiple rows based on column value in a Google Sheets spreadsheet. input: @@ -333,14 +333,14 @@ TASK_LOOKUP_ROWS: description: Value to search for in the specified column. title: Search Value uiOrder: 10 - format: string + type: string required: - shared-link - column-name - value - sheet-name title: Input - format: object + type: object output: properties: rows: @@ -348,7 +348,7 @@ TASK_LOOKUP_ROWS: required: - rows title: Output - format: object + type: object TASK_INSERT_ROW: shortDescription: Insert a single row into a Google Sheets spreadsheet. input: @@ -365,7 +365,7 @@ TASK_INSERT_ROW: - row - sheet-name title: Input - format: object + type: object output: properties: row: @@ -374,7 +374,7 @@ TASK_INSERT_ROW: - row - row-number title: Output - format: object + type: object TASK_INSERT_MULTIPLE_ROWS: shortDescription: Insert multiple rows into a Google Sheets spreadsheet. input: @@ -390,13 +390,13 @@ TASK_INSERT_MULTIPLE_ROWS: $ref: '#/$defs/row-value' uiOrder: 2 title: Row Values - format: array + type: array required: - shared-link - rows - sheet-name title: Input - format: object + type: object output: properties: rows: @@ -404,7 +404,7 @@ TASK_INSERT_MULTIPLE_ROWS: required: - rows title: Output - format: object + type: object TASK_UPDATE_ROW: shortDescription: Update a row in a Google Sheets spreadsheet. input: @@ -422,7 +422,7 @@ TASK_UPDATE_ROW: - row - sheet-name title: Input - format: object + type: object output: properties: row: @@ -430,7 +430,7 @@ TASK_UPDATE_ROW: required: - row title: Output - format: object + type: object TASK_UPDATE_MULTIPLE_ROWS: shortDescription: Update multiple rows in a Google Sheets spreadsheet. input: @@ -448,7 +448,7 @@ TASK_UPDATE_MULTIPLE_ROWS: - rows - sheet-name title: Input - format: object + type: object output: properties: rows: @@ -456,7 +456,7 @@ TASK_UPDATE_MULTIPLE_ROWS: required: - rows title: Output - format: object + type: object TASK_DELETE_ROW: shortDescription: Delete a row from a Google Sheets spreadsheet. input: @@ -473,7 +473,7 @@ TASK_DELETE_ROW: - row-number - sheet-name title: Input - format: object + type: object output: properties: success: @@ -481,7 +481,7 @@ TASK_DELETE_ROW: required: - success title: Output - format: object + type: object TASK_DELETE_MULTIPLE_ROWS: shortDescription: Delete multiple rows from a Google Sheets spreadsheet. input: @@ -498,7 +498,7 @@ TASK_DELETE_MULTIPLE_ROWS: - row-numbers - sheet-name title: Input - format: object + type: object output: properties: success: @@ -506,4 +506,4 @@ TASK_DELETE_MULTIPLE_ROWS: required: - success title: Output - format: object + type: object diff --git a/pkg/component/data/instillartifact/v0/.compogen/bottom.mdx b/pkg/component/data/instillartifact/v0/.compogen/bottom.mdx index 01a937d97..570eb9416 100644 --- a/pkg/component/data/instillartifact/v0/.compogen/bottom.mdx +++ b/pkg/component/data/instillartifact/v0/.compogen/bottom.mdx @@ -17,15 +17,15 @@ variable: catalog_name: title: catalog-name description: The name of your catalog i.e. "instill-ai" - format: string + type: string namespace: title: namespace description: The namespace of your catalog i.e. "instill-ai" - format: string + type: string question: title: question description: The question to ask your catalog i.e. "What is Instill AI doing?", "What is Artifact?" - format: string + type: string output: answer: title: answer @@ -42,13 +42,13 @@ version: v1beta variable: namespace: title: Namespace - format: string + type: string catalog: title: Catalog - format: string + type: string folder-link: title: Folder Link - format: string + type: string component: read-folder: diff --git a/pkg/component/data/instillartifact/v0/README.mdx b/pkg/component/data/instillartifact/v0/README.mdx index 637c1675e..3623b241c 100644 --- a/pkg/component/data/instillartifact/v0/README.mdx +++ b/pkg/component/data/instillartifact/v0/README.mdx @@ -46,7 +46,7 @@ Upload and process the files into chunks into Catalog.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPLOAD_FILE` | | [Options](#upload-file-options) (required) | `options` | object | Choose to upload the files to existing catalog or create a new catalog. | @@ -66,7 +66,7 @@ Upload and process the files into chunks into Catalog.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Catalog ID | `catalog-id` | string | Catalog ID that you input in the Catalog. | | File | `file` | string | Base64 encoded PDF/DOCX/DOC/PPTX/PPT/HTML file to be uploaded into catalog. | @@ -79,7 +79,7 @@ Upload and process the files into chunks into Catalog.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Catalog ID | `catalog-id` | string | Catalog ID for new catalog you want to create. | | Description | `description` | string | Description of the catalog. | @@ -93,7 +93,7 @@ Upload and process the files into chunks into Catalog.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [File](#upload-file-file) | `file` | object | Result of uploading file into catalog. | | Status | `status` | boolean | The status of trigger file processing, if succeeded, return true. | @@ -106,7 +106,7 @@ Upload and process the files into chunks into Catalog.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Catalog ID | `catalog-id` | string | ID of the catalog that you upload files. | | Create Time | `create-time` | string | Creation time of the file in ISO 8601 format. | @@ -125,7 +125,7 @@ Upload and process the files into chunks into Catalog.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPLOAD_FILES` | | [Options](#upload-files-options) (required) | `options` | object | Choose to upload the files to existing catalog or create a new catalog. | @@ -145,7 +145,7 @@ Upload and process the files into chunks into Catalog.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Catalog ID | `catalog-id` | string | Catalog ID that you input in the Catalog. | | File Names | `file-names` | array | Name of the file, including the extension (e.g. `example.pdf`). The length of this field is limited to 100 characters. | @@ -158,7 +158,7 @@ Upload and process the files into chunks into Catalog.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Catalog ID | `catalog-id` | string | Catalog ID for new catalog you want to create. | | Description | `description` | string | Description of the catalog. | @@ -172,7 +172,7 @@ Upload and process the files into chunks into Catalog.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Files](#upload-files-files) | `files` | array[object] | Files metadata in catalog. | | Status | `status` | boolean | The status of trigger file processing, if ALL succeeded, return true. | @@ -185,7 +185,7 @@ Upload and process the files into chunks into Catalog.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Catalog ID | `catalog-id` | string | ID of the catalog that you upload files. | | Create Time | `create-time` | string | Creation time of the file in ISO 8601 format. | @@ -204,7 +204,7 @@ get the metadata of the files in the catalog.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_FILES_METADATA` | | Namespace (required) | `namespace` | string | Fill in your namespace, you can get namespace through the tab of switching namespace. | @@ -218,7 +218,7 @@ get the metadata of the files in the catalog.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Files](#get-files-metadata-files) | `files` | array[object] | Files metadata in catalog. |
@@ -230,7 +230,7 @@ get the metadata of the files in the catalog.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Catalog ID | `catalog-id` | string | ID of the catalog that you upload files. | | Create Time | `create-time` | string | Creation time of the file in ISO 8601 format. | @@ -249,7 +249,7 @@ get the metadata of the chunks from a file in the catalog.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_CHUNKS_METADATA` | | Catalog ID (required) | `catalog-id` | string | Catalog ID that you input to search files in the Catalog. | @@ -264,7 +264,7 @@ get the metadata of the chunks from a file in the catalog.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Chunks](#get-chunks-metadata-chunks) | `chunks` | array[object] | Chunks metadata of the file in catalog. |
@@ -276,7 +276,7 @@ get the metadata of the chunks from a file in the catalog.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Chunk UID | `chunk-uid` | string | The unique identifier of the chunk. | | Create Time | `create-time` | string | The creation time of the chunk in ISO 8601 format. | @@ -295,7 +295,7 @@ get the file content in markdown format.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET_FILE_IN_MARKDOWN` | | Catalog ID (required) | `catalog-id` | string | Catalog ID that you input to search files in the Catalog. | @@ -310,7 +310,7 @@ get the file content in markdown format.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | File UID | `original-file-uid` | string | The unique identifier of the file. | | Content | `content` | string | The content of the file in markdown format. | @@ -325,7 +325,7 @@ Check if the specified file's processing status is done.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_MATCH_FILE_STATUS` | | Catalog ID (required) | `catalog-id` | string | Catalog ID that you input to check files' processing status in the Catalog. | @@ -340,7 +340,7 @@ Check if the specified file's processing status is done.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `succeeded` | boolean | The status of the file processing, if succeeded, return true. |
@@ -352,7 +352,7 @@ search the chunks in the catalog.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_RETRIEVE` | | Catalog ID (required) | `catalog-id` | string | Catalog ID that you input to search files in the Catalog. | @@ -368,7 +368,7 @@ search the chunks in the catalog.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Chunks](#retrieve-chunks) | `chunks` | array[object] | Chunks data from smart search. |
@@ -380,7 +380,7 @@ search the chunks in the catalog.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Chunk UID | `chunk-uid` | string | The unique identifier of the chunk. | | Similarity | `similarity-score` | number | The similarity score of the chunk. | @@ -396,7 +396,7 @@ Reply the questions based on the files in the catalog.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_ASK` | | Catalog ID (required) | `catalog-id` | string | Catalog ID that you input to search files in the Catalog. | @@ -412,7 +412,7 @@ Reply the questions based on the files in the catalog.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Answer | `answer` | string | Answers data from smart search. | | [Chunks](#ask-chunks) (optional) | `chunks` | array[object] | Chunks data to answer question. | @@ -425,7 +425,7 @@ Reply the questions based on the files in the catalog.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Chunk UID | `chunk-uid` | string | The unique identifier of the chunk. | | Similarity | `similarity-score` | number | The similarity score of the chunk. | @@ -455,15 +455,15 @@ variable: catalog_name: title: catalog-name description: The name of your catalog i.e. "instill-ai" - format: string + type: string namespace: title: namespace description: The namespace of your catalog i.e. "instill-ai" - format: string + type: string question: title: question description: The question to ask your catalog i.e. "What is Instill AI doing?", "What is Artifact?" - format: string + type: string output: answer: title: answer @@ -480,13 +480,13 @@ version: v1beta variable: namespace: title: Namespace - format: string + type: string catalog: title: Catalog - format: string + type: string folder-link: title: Folder Link - format: string + type: string component: read-folder: diff --git a/pkg/component/data/instillartifact/v0/config/tasks.yaml b/pkg/component/data/instillartifact/v0/config/tasks.yaml index f983d46db..bc5ee47f9 100644 --- a/pkg/component/data/instillartifact/v0/config/tasks.yaml +++ b/pkg/component/data/instillartifact/v0/config/tasks.yaml @@ -2,159 +2,152 @@ $defs: file: description: Base64 encoded PDF/DOCX/DOC/PPTX/PPT/HTML file to be uploaded into catalog. uiOrder: 2 - acceptFormats: - - '*/*' + type: string title: File - format: string files: description: Base64 encoded PDF/DOCX/DOC/PPTX/PPT/HTML files to be uploaded into catalog. uiOrder: 2 - acceptFormats: - - array + type: array items: - format: string + type: string title: Files - format: array file-item: properties: file-uid: description: Unique identifier of the file. uiOrder: 0 title: File UID - format: string + type: string file-name: description: Name of the file. uiOrder: 1 title: File Name - format: string + type: string file-type: description: Type of the file. uiOrder: 2 title: Type - format: string + type: string create-time: description: Creation time of the file in ISO 8601 format. uiOrder: 3 title: Create Time - format: string + type: string update-time: description: Update time of the file in ISO 8601 format. uiOrder: 4 title: Update Time - format: string + type: string size: description: Size of the file in bytes. uiOrder: 5 title: Size - format: number + type: number catalog-id: description: ID of the catalog that you upload files. uiOrder: 8 title: Catalog ID - format: string + type: string required: - catalog-id title: File - format: object + type: object chunk-item: properties: chunk-uid: description: The unique identifier of the chunk. uiOrder: 0 title: Chunk UID - format: string + type: string similarity-score: description: The similarity score of the chunk. uiOrder: 1 title: Similarity - format: number + type: number text-content: description: The text content of the chunk. uiOrder: 2 title: Text Content - format: string + type: string source-file-name: description: The name of the source file. uiOrder: 3 title: Source File Name - format: string + type: string required: - chunk-uid - similarity-score - text-content - source-file-name title: Chunk - format: object + type: object namespace: description: Fill in your namespace, you can get namespace through the tab of switching namespace. - acceptFormats: - - string + type: string uiOrder: 0 title: Namespace - format: string third-party-files: description: File contents and metadata from third-part data storage. uiOrder: 2 - acceptFormats: - - array + type: array items: properties: id: description: Unique ID of the file from third-party data storage. uiOrder: 0 title: ID - format: string + type: string name: description: Name of the file from third-party data storage. uiOrder: 1 title: Name - format: string + type: string content: description: Base64 encoded content of the binary file without the `data:[MIME_TYPE];base64,` prefix. uiOrder: 2 title: Content - format: string + type: string created-time: description: 'Time when the file was created. Format: `YYYY-MM-DDTHH:MM:SSZ`.' uiOrder: 3 title: Created time - format: string + type: string modified-time: description: 'Time when the file was last modified. Format: `YYYY-MM-DDTHH:MM:SSZ`. It will be used to check if the file has been updated.' uiOrder: 4 title: Modified time - format: string + type: string size: description: Size of the file in bytes. uiOrder: 5 title: Size - format: integer + type: integer mime-type: description: MIME type of the file. uiOrder: 6 title: MIME type - format: string + type: string md5-checksum: description: MD5 checksum of the file. This reflects every change made to the file on the server, even those not visible to the user. uiOrder: 7 title: MD5 checksum - format: string + type: string version: description: Version of the file. uiOrder: 8 title: Version - format: integer + type: integer web-view-link: description: Link for opening the file in a relevant third-party data storage editor or viewer in a browser. It will be used to check the source of the file. uiOrder: 9 title: Web View Link - format: string + type: string web-content-link: description: Link for downloading the content of the file in a browser. uiOrder: 10 title: Web Content Link - format: string + type: string required: - id - name @@ -165,9 +158,8 @@ $defs: - version - web-view-link title: Third Party File - format: object + type: object title: Third Party Files - format: array TASK_UPLOAD_FILE: shortDescription: Upload and process the files into chunks into Catalog. input: @@ -188,25 +180,21 @@ TASK_UPLOAD_FILE: title: Option description: Existing catalog. uiOrder: 0 - format: string + type: string namespace: $ref: '#/$defs/namespace' catalog-id: description: Catalog ID that you input in the Catalog. uiOrder: 1 - acceptFormats: - - string + type: string title: Catalog ID - format: string file: $ref: '#/$defs/file' file-name: description: Name of the file, including the extension (e.g. `example.pdf`). The length of this field is limited to 100 characters. uiOrder: 2 - acceptFormats: - - string + type: string title: File Name - format: string required: - option - namespace @@ -214,48 +202,40 @@ TASK_UPLOAD_FILE: - file - file-name title: Existing Catalog - format: object + type: object - properties: option: const: create new catalog title: Option description: Create new catalog. uiOrder: 0 - format: string + type: string namespace: $ref: '#/$defs/namespace' catalog-id: description: Catalog ID for new catalog you want to create. uiOrder: 1 - acceptFormats: - - string + type: string title: Catalog ID - format: string file: $ref: '#/$defs/file' file-name: description: Name of the file, including the extension (e.g. `example.pdf`). The length of this field is limited to 100 characters. uiOrder: 3 - acceptFormats: - - string + type: string title: File Name - format: string description: description: Description of the catalog. uiOrder: 4 - acceptFormats: - - string + type: string title: Description - format: string tags: description: Tags for the catalog. uiOrder: 5 - acceptFormats: - - array + type: array items: - format: string + type: string title: Tags - format: array required: - option - namespace @@ -263,12 +243,12 @@ TASK_UPLOAD_FILE: - file - file-name title: Create New Catalog - format: object - format: object + type: object + type: object required: - options title: Input - format: object + type: object output: description: Result of uploading file into catalog. properties: @@ -286,17 +266,17 @@ TASK_UPLOAD_FILE: - size - catalog-id title: File - format: object + type: object status: description: The status of trigger file processing, if succeeded, return true. uiOrder: 1 title: Status - format: boolean + type: boolean required: - file - status title: Output - format: object + type: object TASK_UPLOAD_FILES: shortDescription: Upload and process the files into chunks into Catalog. input: @@ -317,27 +297,23 @@ TASK_UPLOAD_FILES: title: Option description: Existing catalog. uiOrder: 0 - format: string + type: string namespace: $ref: '#/$defs/namespace' catalog-id: description: Catalog ID that you input in the Catalog. uiOrder: 1 - acceptFormats: - - string + type: string title: Catalog ID - format: string files: $ref: '#/$defs/files' file-names: description: Name of the file, including the extension (e.g. `example.pdf`). The length of this field is limited to 100 characters. uiOrder: 2 - acceptFormats: - - array + type: array items: - format: string + type: string title: File Names - format: array required: - option - namespace @@ -345,50 +321,42 @@ TASK_UPLOAD_FILES: - files - file-names title: Existing Catalog - format: object + type: object - properties: option: const: create new catalog title: Option description: Create new catalog. uiOrder: 0 - format: string + type: string namespace: $ref: '#/$defs/namespace' catalog-id: description: Catalog ID for new catalog you want to create. uiOrder: 1 - acceptFormats: - - string + type: string title: Catalog ID - format: string files: $ref: '#/$defs/files' file-names: description: Name of the file, including the extension (e.g. `example.pdf`). The length of this field is limited to 100 characters. uiOrder: 3 - acceptFormats: - - array + type: array items: - format: string + type: string title: File Names - format: array description: description: Description of the catalog. uiOrder: 4 - acceptFormats: - - string + type: string title: Description - format: string tags: description: Tags for the catalog. uiOrder: 5 - acceptFormats: - - array + type: array items: - format: string + type: string title: Tags - format: array required: - option - namespace @@ -396,12 +364,12 @@ TASK_UPLOAD_FILES: - files - file-names title: Create New Catalog - format: object - format: object + type: object + type: object required: - options title: Input - format: object + type: object output: description: Result of uploading files into catalog. properties: @@ -411,17 +379,17 @@ TASK_UPLOAD_FILES: items: $ref: '#/$defs/file-item' title: Files - format: array + type: array status: description: The status of trigger file processing, if ALL succeeded, return true. uiOrder: 1 title: Status - format: boolean + type: boolean required: - files - status title: Output - format: object + type: object TASK_GET_FILES_METADATA: shortDescription: get the metadata of the files in the catalog. input: @@ -432,15 +400,13 @@ TASK_GET_FILES_METADATA: catalog-id: description: Catalog ID that you input to search files in the Catalog. uiOrder: 1 - acceptFormats: - - string + type: string title: Catalog ID - format: string required: - namespace - catalog-id title: Input - format: object + type: object output: description: Files metadata into catalog. uiOrder: 1 @@ -451,11 +417,11 @@ TASK_GET_FILES_METADATA: items: $ref: '#/$defs/file-item' title: Files - format: array + type: array required: - files title: Output - format: object + type: object TASK_GET_CHUNKS_METADATA: shortDescription: get the metadata of the chunks from a file in the catalog. input: @@ -466,23 +432,19 @@ TASK_GET_CHUNKS_METADATA: catalog-id: description: Catalog ID that you input to search files in the Catalog. uiOrder: 0 - acceptFormats: - - string + type: string title: Catalog ID - format: string file-uid: description: The unique identifier of the file. uiOrder: 1 - acceptFormats: - - string + type: string title: File UID - format: string required: - namespace - catalog-id - file-uid title: Input - format: object + type: object output: description: Chunks metadata of the file in catalog. uiOrder: 1 @@ -496,37 +458,37 @@ TASK_GET_CHUNKS_METADATA: description: The unique identifier of the chunk. uiOrder: 0 title: Chunk UID - format: string + type: string retrievable: description: The retrievable status of the chunk. uiOrder: 1 title: Retrievable - format: boolean + type: boolean start-position: description: The start position of the chunk in the file. uiOrder: 2 title: Start Position - format: integer + type: integer end-position: description: The end position of the chunk in the file. uiOrder: 3 title: End Position - format: integer + type: integer token-count: description: The token count of the chunk. uiOrder: 4 title: Token Count - format: integer + type: integer create-time: description: The creation time of the chunk in ISO 8601 format. uiOrder: 5 title: Create Time - format: string + type: string original-file-uid: description: The unique identifier of the file. uiOrder: 6 title: File UID - format: string + type: string required: - chunk-uid - retrievable @@ -536,13 +498,13 @@ TASK_GET_CHUNKS_METADATA: - create-time - original-file-uid title: Chunk - format: object + type: object title: Chunks - format: array + type: array required: - chunks title: Output - format: object + type: object TASK_GET_FILE_IN_MARKDOWN: shortDescription: get the file content in markdown format. input: @@ -553,23 +515,19 @@ TASK_GET_FILE_IN_MARKDOWN: catalog-id: description: Catalog ID that you input to search files in the Catalog. uiOrder: 0 - acceptFormats: - - string + type: string title: Catalog ID - format: string file-uid: description: The unique identifier of the file. uiOrder: 1 - acceptFormats: - - string + type: string title: File UID - format: string required: - namespace - catalog-id - file-uid title: Input - format: object + type: object output: description: File content in markdown format. uiOrder: 1 @@ -578,29 +536,29 @@ TASK_GET_FILE_IN_MARKDOWN: description: The unique identifier of the file. uiOrder: 0 title: File UID - format: string + type: string content: description: The content of the file in markdown format. uiOrder: 1 title: Content - format: string + type: string create-time: description: The creation time of the source file in ISO 8601 format. uiOrder: 2 title: Create Time - format: string + type: string update-time: description: The update time of the source file in ISO 8601 format. uiOrder: 3 title: Update Time - format: string + type: string required: - original-file-uid - content - create-time - update-time title: Output - format: object + type: object TASK_RETRIEVE: shortDescription: search the chunks in the catalog. input: @@ -611,31 +569,25 @@ TASK_RETRIEVE: catalog-id: description: Catalog ID that you input to search files in the Catalog. uiOrder: 0 - acceptFormats: - - string + type: string title: Catalog ID - format: string text-prompt: description: The prompt string to search the chunks. uiOrder: 1 - acceptFormats: - - string + type: string title: Text Prompt - format: string top-k: description: The number of top chunks to return. The range is from 1~20, and default is 5. default: 5 uiOrder: 2 - acceptFormats: - - integer + type: integer title: Top K - format: integer required: - namespace - catalog-id - text-prompt title: Input - format: object + type: object output: uiOrder: 1 properties: @@ -645,11 +597,11 @@ TASK_RETRIEVE: items: $ref: '#/$defs/chunk-item' title: Chunks - format: array + type: array required: - chunks title: Output - format: object + type: object TASK_ASK: shortDescription: Reply the questions based on the files in the catalog. input: @@ -660,31 +612,25 @@ TASK_ASK: catalog-id: description: Catalog ID that you input to search files in the Catalog. uiOrder: 0 - acceptFormats: - - string + type: string title: Catalog ID - format: string question: description: The question to reply. uiOrder: 1 - acceptFormats: - - string + type: string title: Question - format: string top-k: description: The number of top answers to return. The range is from 1~20, and default is 5. default: 5 uiOrder: 2 - acceptFormats: - - integer + type: integer title: Top K - format: integer required: - namespace - catalog-id - question title: Input - format: object + type: object output: uiOrder: 1 properties: @@ -692,18 +638,18 @@ TASK_ASK: description: Answers data from smart search. uiOrder: 0 title: Answer - format: string + type: string chunks: description: Chunks data to answer question. uiOrder: 1 items: $ref: '#/$defs/chunk-item' title: Chunks - format: array + type: array required: - answer title: Output - format: object + type: object TASK_MATCH_FILE_STATUS: shortDescription: Check if the specified file's processing status is done. input: @@ -714,23 +660,19 @@ TASK_MATCH_FILE_STATUS: catalog-id: description: Catalog ID that you input to check files' processing status in the Catalog. uiOrder: 0 - acceptFormats: - - string + type: string title: Catalog ID - format: string file-uid: description: The unique identifier of the file. uiOrder: 1 - acceptFormats: - - string + type: string title: File UID - format: string required: - namespace - catalog-id - file-uid title: Input - format: object + type: object output: uiOrder: 1 properties: @@ -738,11 +680,11 @@ TASK_MATCH_FILE_STATUS: description: The status of the file processing, if succeeded, return true. uiOrder: 0 title: Status - format: boolean + type: boolean required: - succeeded title: Output - format: object + type: object TASK_SYNC_FILES: shortDescription: This task synchronizes files from third-party storage to Instill Catalog. New files are uploaded, and updated files are overwritten based on third-party metadata. Files added through other channels, like the Artifact API or additional storage services, will not be removed. Currently, @@ -755,10 +697,8 @@ TASK_SYNC_FILES: catalog-id: description: Catalog ID that you input to synchronize files from third-party data storage to catalog. uiOrder: 1 - acceptFormats: - - string + type: string title: Catalog ID - format: string third-party-files: $ref: '#/$defs/third-party-files' required: @@ -766,7 +706,7 @@ TASK_SYNC_FILES: - catalog-id - third-party-files title: Input - format: object + type: object output: uiOrder: 1 properties: @@ -776,33 +716,33 @@ TASK_SYNC_FILES: items: $ref: '#/$defs/file-item' title: Uploaded Files - format: array + type: array updated_files: description: Files that were updated. The metadata here is from Instill Artifact rather than third-party storage. uiOrder: 1 items: $ref: '#/$defs/file-item' title: Updated Files - format: array + type: array failure-files: description: Files that failed to upload or overwrite. The metadata here is from third-party storage. uiOrder: 2 items: $ref: '#/$defs/third-party-files/items' title: Failure Files - format: array + type: array error-messages: description: Error messages for files that failed to upload or overwrite. uiOrder: 3 items: - format: string + type: string title: Error Messages - format: array + type: array status: description: The status of the triggering processing files, if succeeded, return true. uiOrder: 4 title: Status - format: boolean + type: boolean required: [] title: Output - format: object + type: object diff --git a/pkg/component/data/milvus/v0/README.mdx b/pkg/component/data/milvus/v0/README.mdx index fd05703d6..16e784646 100644 --- a/pkg/component/data/milvus/v0/README.mdx +++ b/pkg/component/data/milvus/v0/README.mdx @@ -45,7 +45,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Milvus URL Endpoint (required) | `url` | string | Fill in your Milvus public URL endpoint with port number, e.g http://3.25.202.142:19530. | | Milvus Username (required) | `username` | string | Fill in your Milvus username. | @@ -65,7 +65,7 @@ Perform a vector search on a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_VECTOR_SEARCH` | | Collection Name (required) | `collection-name` | string | The name of the collection to perform vector search on. | @@ -87,7 +87,7 @@ Perform a vector search on a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Result](#vector-search-result) | `result` | object | Result of the vector search operation. | | Status | `status` | string | Vector search status. | @@ -100,7 +100,7 @@ Perform a vector search on a collection
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Data](#vector-search-data) | `data` | array | The points returned from the vector search operation. | | IDs | `ids` | array | The ids returned from the vector search operation. | @@ -116,7 +116,7 @@ Insert a vector data into a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPSERT` | | Collection Name (required) | `collection-name` | string | The name of the collection to upsert the data into. | @@ -131,7 +131,7 @@ Insert a vector data into a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Upsert status. |
@@ -143,7 +143,7 @@ Insert a batch of vector data into a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_BATCH_UPSERT` | | Collection Name (required) | `collection-name` | string | The name of the collection to upsert the data into. | @@ -158,7 +158,7 @@ Insert a batch of vector data into a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Batch upsert status. |
@@ -170,7 +170,7 @@ Delete vector data from a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE` | | Collection Name (required) | `collection-name` | string | The name of the collection to delete the data from. | @@ -185,7 +185,7 @@ Delete vector data from a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete status. |
@@ -197,7 +197,7 @@ Create a collectio, please refer to [Create-Collection](https://milvus.io/docs/m
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_COLLECTION` | | Collection Name (required) | `collection-name` | string | The name of the collection to create. | @@ -217,7 +217,7 @@ Create a collectio, please refer to [Create-Collection](https://milvus.io/docs/m
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Create collection status. |
@@ -229,7 +229,7 @@ Drop a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DROP_COLLECTION` | | Collection Name (required) | `collection-name` | string | The name of the collection to drop. | @@ -242,7 +242,7 @@ Drop a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Drop collection status. |
@@ -254,7 +254,7 @@ Create a partition in a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_PARTITION` | | Collection Name (required) | `collection-name` | string | The name of the collection to create the partition in. | @@ -268,7 +268,7 @@ Create a partition in a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Create partition status. |
@@ -280,7 +280,7 @@ Drop a partition from a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DROP_PARTITION` | | Collection Name (required) | `collection-name` | string | The name of the collection to drop the partition from. | @@ -294,7 +294,7 @@ Drop a partition from a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Drop partition status. |
@@ -306,7 +306,7 @@ Create an index in a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_INDEX` | | Collection Name (required) | `collection-name` | string | The name of the collection to create the index in. | @@ -320,7 +320,7 @@ Create an index in a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Create index status. |
@@ -332,7 +332,7 @@ Drop an index from a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DROP_INDEX` | | Collection Name (required) | `collection-name` | string | The name of the collection to drop the index from. | @@ -346,7 +346,7 @@ Drop an index from a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Drop index status. |
diff --git a/pkg/component/data/milvus/v0/config/setup.yaml b/pkg/component/data/milvus/v0/config/setup.yaml index 2e5acff19..e720901a5 100644 --- a/pkg/component/data/milvus/v0/config/setup.yaml +++ b/pkg/component/data/milvus/v0/config/setup.yaml @@ -2,31 +2,25 @@ additionalProperties: false properties: url: description: Fill in your Milvus public URL endpoint with port number, e.g http://3.25.202.142:19530. - acceptFormats: - - string + type: string instillSecret: false uiOrder: 0 title: Milvus URL Endpoint - format: string username: description: Fill in your Milvus username. - acceptFormats: - - string + type: string instillSecret: false uiOrder: 1 title: Milvus Username - format: string password: description: Fill in your Milvus password. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 2 title: Milvus Password - format: string required: - url - username - password title: Milvus Connection -format: object +type: object diff --git a/pkg/component/data/milvus/v0/config/tasks.yaml b/pkg/component/data/milvus/v0/config/tasks.yaml index 4660bcbf9..7947dd028 100644 --- a/pkg/component/data/milvus/v0/config/tasks.yaml +++ b/pkg/component/data/milvus/v0/config/tasks.yaml @@ -5,94 +5,72 @@ TASK_VECTOR_SEARCH: properties: collection-name: description: The name of the collection to perform vector search on. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to vector search the data from. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string vector: description: An array of dimensions for the vector search. - acceptFormats: - - array - - array + type: array uiOrder: 2 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Vector - format: array vector-field: description: The name of the field to perform vector search on. - acceptFormats: - - string + type: string uiOrder: 3 title: Vector Field - format: string limit: description: The limit of the data to return. - acceptFormats: - - integer + type: integer uiOrder: 4 title: Limit - format: integer fields: description: The fields to return in the data. If empty then all fields will be returned. - acceptFormats: - - array + type: array shortDescription: Fields to be returned, empty for all fields uiOrder: 4 title: Fields minItems: 1 items: title: Field - format: string - format: array + type: string filter: description: The properties filter to be applied to the data with milvus scalar filter, please refer to [filter-search](https://milvus.io/docs/single-vector-search.md#Filtered-search). uiOrder: 5 - acceptFormats: - - string + type: string title: Filter - format: string offset: description: The offset of the data to return. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Offset - format: integer grouping-field: description: The name of the field to group the data by, please refer to [Grouping-search](https://milvus.io/docs/single-vector-search.md#Grouping-search). - acceptFormats: - - string + type: string uiOrder: 7 title: Grouping Field - format: string search-params: description: The search parameters to be applied to the data with milvus search parameters, please refer to [Search-parameters](https://milvus.io/docs/single-vector-search.md#Search-parameters). uiOrder: 8 - acceptFormats: - - json - - object + type: object title: Search Parameters required: [] - format: object required: - collection-name - vector - vector-field - limit title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -100,7 +78,7 @@ TASK_VECTOR_SEARCH: description: Vector search status. uiOrder: 0 title: Status - format: string + type: string result: description: Result of the vector search operation. uiOrder: 0 @@ -114,8 +92,8 @@ TASK_VECTOR_SEARCH: items: description: An id of the point. example: c8faa-4b3b-4b3b-4b3b - format: string - format: array + type: string + type: array data: description: The points returned from the vector search operation. uiOrder: 1 @@ -123,9 +101,9 @@ TASK_VECTOR_SEARCH: title: Data items: title: Datum - format: object + type: object required: [] - format: array + type: array vectors: description: The vectors returned from the vector search operation. uiOrder: 2 @@ -137,9 +115,9 @@ TASK_VECTOR_SEARCH: items: description: A dimension of the vector. example: 0.8167237 - format: number - format: array - format: array + type: number + type: array + type: array metadata: description: The metadata returned from the vector search operation. uiOrder: 3 @@ -147,16 +125,16 @@ TASK_VECTOR_SEARCH: required: [] items: title: Metadatum - format: object + type: object required: [] - format: array + type: array required: [] - format: object + type: object required: - status - result title: Output - format: object + type: object TASK_UPSERT: shortDescription: Insert a vector data into a collection input: @@ -164,32 +142,25 @@ TASK_UPSERT: properties: collection-name: description: The name of the collection to upsert the data into. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to upsert the data from. If empty then default partition will be used. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string data: description: The data. - acceptFormats: - - json - - object + type: object uiOrder: 2 title: Data required: [] - format: object required: - collection-name - data title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -197,11 +168,11 @@ TASK_UPSERT: description: Upsert status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_BATCH_UPSERT: shortDescription: Insert a batch of vector data into a collection input: @@ -209,37 +180,28 @@ TASK_BATCH_UPSERT: properties: collection-name: description: The name of the collection to upsert the data into. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to upsert the data from. If empty then default partition will be used. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string array-data: description: The data. - acceptFormats: - - array - - array - - array - - array + type: array uiOrder: 2 title: Array Data items: description: A datum. required: [] - format: object - format: array + type: object required: - collection-name - array-data title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -247,11 +209,11 @@ TASK_BATCH_UPSERT: description: Batch upsert status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DELETE: shortDescription: Delete vector data from a collection input: @@ -259,29 +221,23 @@ TASK_DELETE: properties: collection-name: description: The name of the collection to delete the data from. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to delete the data from. If empty then default partition will be used. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string filter: description: The properties filter to be applied to the data with milvus scalar filter, please refer to [Filtered-search](https://milvus.io/docs/single-vector-search.md#Filtered-search). uiOrder: 2 - acceptFormats: - - string + type: string title: Filter - format: string required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -289,11 +245,11 @@ TASK_DELETE: description: Delete status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_CREATE_COLLECTION: shortDescription: Create a collectio, please refer to [Create-Collection](https://milvus.io/docs/manage-collections.md#Create-Collection) input: @@ -301,46 +257,34 @@ TASK_CREATE_COLLECTION: properties: collection-name: description: The name of the collection to create. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string dimension: description: The dimension of the collection. - acceptFormats: - - integer + type: integer uiOrder: 1 title: Dimension - format: integer id-type: description: The type of the id. - acceptFormats: - - string + type: string uiOrder: 3 title: ID Type - format: string schema: description: The schema of the collection. - acceptFormats: - - json - - object + type: object uiOrder: 4 title: Schema required: [] - format: object auto-id: description: Whether to auto generate id. - acceptFormats: - - boolean + type: boolean uiOrder: 5 title: Auto ID default: false - format: boolean metric-type: description: The metric type of the collection. - acceptFormats: - - string + type: string uiOrder: 6 title: Metric Type enum: @@ -348,34 +292,27 @@ TASK_CREATE_COLLECTION: - IP - COSINE default: L2 - format: string index-params: description: The index parameters to be applied to the collection with milvus index parameters, please refer to [Create](https://milvus.io/api-reference/restful/v2.4.x/v2/Collection%20(v2)/Create.md). uiOrder: 7 - acceptFormats: - - array - - array + type: array title: Index Parameters required: [] items: description: Index parameter. required: [] - format: object - format: array + type: object params: description: The parameters to be applied to the collection with milvus parameters, please refer to [Parameters](https://milvus.io/docs/single-vector-search.md#Parameters). uiOrder: 8 - acceptFormats: - - json - - object + type: object title: Parameters required: [] - format: object required: - collection-name - dimension title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -383,11 +320,11 @@ TASK_CREATE_COLLECTION: description: Create collection status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DROP_COLLECTION: shortDescription: Drop a collection input: @@ -395,15 +332,13 @@ TASK_DROP_COLLECTION: properties: collection-name: description: The name of the collection to drop. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -411,11 +346,11 @@ TASK_DROP_COLLECTION: description: Drop collection status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_CREATE_PARTITION: shortDescription: Create a partition in a collection input: @@ -423,23 +358,19 @@ TASK_CREATE_PARTITION: properties: collection-name: description: The name of the collection to create the partition in. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to create. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string required: - collection-name - partition-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -447,11 +378,11 @@ TASK_CREATE_PARTITION: description: Create partition status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DROP_PARTITION: shortDescription: Drop a partition from a collection input: @@ -459,23 +390,19 @@ TASK_DROP_PARTITION: properties: collection-name: description: The name of the collection to drop the partition from. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to drop. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string required: - collection-name - partition-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -483,11 +410,11 @@ TASK_DROP_PARTITION: description: Drop partition status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_CREATE_INDEX: shortDescription: Create an index in a collection input: @@ -495,25 +422,20 @@ TASK_CREATE_INDEX: properties: collection-name: description: The name of the collection to create the index in. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string index-params: description: The index parameters to be applied to the collection with milvus index parameters, please refer to [Create](https://milvus.io/api-reference/restful/v2.4.x/v2/Index%20(v2)/Create.md). uiOrder: 7 - acceptFormats: - - json - - object + type: object title: Index Parameters required: [] - format: object required: - collection-name - index-params title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -521,11 +443,11 @@ TASK_CREATE_INDEX: description: Create index status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DROP_INDEX: shortDescription: Drop an index from a collection input: @@ -533,23 +455,19 @@ TASK_DROP_INDEX: properties: collection-name: description: The name of the collection to drop the index from. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string index-name: description: The name of the index to drop. - acceptFormats: - - string + type: string uiOrder: 1 title: Index Name - format: string required: - collection-name - index-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -557,8 +475,8 @@ TASK_DROP_INDEX: description: Drop index status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object diff --git a/pkg/component/data/mongodb/v0/README.mdx b/pkg/component/data/mongodb/v0/README.mdx index 81239ec8d..0eca7fd76 100644 --- a/pkg/component/data/mongodb/v0/README.mdx +++ b/pkg/component/data/mongodb/v0/README.mdx @@ -45,7 +45,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URI (required) | `uri` | string | Fill in your MongoDB URI. | @@ -63,7 +63,7 @@ Perform an insert operation
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INSERT` | | Database Name (required) | `database-name` | string | The name of the database in MongoDB. | @@ -79,7 +79,7 @@ Perform an insert operation
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Insert status. |
@@ -91,7 +91,7 @@ Perform an insert many operation
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INSERT_MANY` | | Database Name (required) | `database-name` | string | The name of the database in MongoDB. | @@ -107,7 +107,7 @@ Perform an insert many operation
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Insert many status. |
@@ -119,7 +119,7 @@ Perform a find operation
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_FIND` | | Database Name (required) | `database-name` | string | The name of the database in MongoDB. | @@ -137,7 +137,7 @@ Perform a find operation
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Result](#find-result) | `result` | object | Result of the find operation. | | Status | `status` | string | Find status. | @@ -150,7 +150,7 @@ Perform a find operation
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Metadata](#find-metadata) | `data` | array | The data returned from the find operation. | | [Documents](#find-documents) | `documents` | array | The documents returned from the find operation. | @@ -165,7 +165,7 @@ Perform an update operation
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE` | | Database Name (required) | `database-name` | string | The name of the database in MongoDB. | @@ -182,7 +182,7 @@ Perform an update operation
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Update status. |
@@ -194,7 +194,7 @@ Perform a delete operation
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE` | | Database Name (required) | `database-name` | string | The name of the database in MongoDB. | @@ -210,7 +210,7 @@ Perform a delete operation
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete status. |
@@ -222,7 +222,7 @@ Delete the collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DROP_COLLECTION` | | Database Name (required) | `database-name` | string | The name of the database in MongoDB. | @@ -236,7 +236,7 @@ Delete the collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete collection status. |
@@ -248,7 +248,7 @@ Delete the database
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DROP_DATABASE` | | Database Name (required) | `database-name` | string | The name of the database in MongoDB. | @@ -261,7 +261,7 @@ Delete the database
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete database status. |
@@ -273,7 +273,7 @@ Create a search index, only works for M10 or larger clusters
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_SEARCH_INDEX` | | Database Name (required) | `database-name` | string | The name of the database in MongoDB. | @@ -290,7 +290,7 @@ Create a search index, only works for M10 or larger clusters
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Create index status. |
@@ -302,7 +302,7 @@ Drop a search index, only works for M10 or larger clusters
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DROP_SEARCH_INDEX` | | Database Name (required) | `database-name` | string | The name of the database in MongoDB. | @@ -317,7 +317,7 @@ Drop a search index, only works for M10 or larger clusters
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete index status. |
@@ -329,7 +329,7 @@ Perform a vector search operation
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_VECTOR_SEARCH` | | Database Name (required) | `database-name` | string | The name of the database in MongoDB. | @@ -351,7 +351,7 @@ Perform a vector search operation
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Result](#vector-search-result) | `result` | object | Result of the vector search operation. | | Status | `status` | string | Vector search status. | @@ -364,7 +364,7 @@ Perform a vector search operation
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Documents](#vector-search-documents) | `documents` | array | The documents returned from the vector search operation. | | IDs | `ids` | array | The ids returned from the vector search operation. | diff --git a/pkg/component/data/mongodb/v0/config/setup.yaml b/pkg/component/data/mongodb/v0/config/setup.yaml index e94675d70..48310386e 100644 --- a/pkg/component/data/mongodb/v0/config/setup.yaml +++ b/pkg/component/data/mongodb/v0/config/setup.yaml @@ -2,13 +2,11 @@ additionalProperties: false properties: uri: description: Fill in your MongoDB URI. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: URI - format: string required: - uri title: MongoDB Connection -format: object +type: object diff --git a/pkg/component/data/mongodb/v0/config/tasks.yaml b/pkg/component/data/mongodb/v0/config/tasks.yaml index 10d48d99a..dc844c05c 100644 --- a/pkg/component/data/mongodb/v0/config/tasks.yaml +++ b/pkg/component/data/mongodb/v0/config/tasks.yaml @@ -5,40 +5,31 @@ TASK_INSERT: properties: database-name: description: The name of the database in MongoDB. - acceptFormats: - - string + type: string uiOrder: 0 title: Database Name - format: string collection-name: description: The name of the collection in MongoDB. - acceptFormats: - - string + type: string uiOrder: 1 title: Collection Name - format: string id: description: The ID of the document. - acceptFormats: - - string + type: string uiOrder: 2 title: ID - format: string data: description: The data to be inserted. - acceptFormats: - - json - - object + type: object uiOrder: 3 title: Data required: [] - format: object required: - database-name - collection-name - data title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -47,11 +38,11 @@ TASK_INSERT: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_INSERT_MANY: shortDescription: Perform an insert many operation input: @@ -59,52 +50,41 @@ TASK_INSERT_MANY: properties: database-name: description: The name of the database in MongoDB. - acceptFormats: - - string + type: string uiOrder: 0 title: Database Name - format: string collection-name: description: The name of the collection in MongoDB. - acceptFormats: - - string + type: string uiOrder: 1 title: Collection Name - format: string array-id: description: The array of id. - acceptFormats: - - array + type: array uiOrder: 2 items: description: An id of the document. example: 1 - format: string + type: string minItems: 1 title: Array ID - format: array array-data: description: The array data to be inserted. - acceptFormats: - - array - - array - - array - - array + type: array uiOrder: 3 title: Data items: description: The data to be inserted. title: Data required: [] - format: object + type: object minItems: 1 - format: array required: - database-name - collection-name - array-data title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -112,11 +92,11 @@ TASK_INSERT_MANY: description: Insert many status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_FIND: shortDescription: Perform a find operation input: @@ -124,61 +104,48 @@ TASK_FIND: properties: database-name: description: The name of the database in MongoDB. - acceptFormats: - - string + type: string uiOrder: 0 title: Database Name - format: string collection-name: description: The name of the collection in MongoDB. - acceptFormats: - - string + type: string uiOrder: 1 title: Collection Name - format: string id: description: The ID of the document. - acceptFormats: - - string + type: string uiOrder: 2 title: ID - format: string filter: description: The filter to find documents, please refer to [the documentations](https://www.mongodb.com/docs/manual/reference/operator/query/). If empty then all documents will be returned. - acceptFormats: - - json - - object + type: object shortDescription: The mongodb language query to filter the documents, empty for no filter uiOrder: 3 title: Filter required: [] - format: object limit: description: The number of documents to return. If empty then all documents will be returned. - acceptFormats: - - integer + type: integer shortDescription: Limit the documents, empty for all documents uiOrder: 4 title: Limit - format: integer fields: description: The fields to return in the documents. If empty then all fields will be returned. - acceptFormats: - - array + type: array shortDescription: Fields to be returned, empty for all fields uiOrder: 5 title: Fields items: title: Field - format: string + type: string minItems: 1 - format: array required: - database-name - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -187,7 +154,7 @@ TASK_FIND: required: [] uiOrder: 0 title: Status - format: string + type: string result: description: Result of the find operation. uiOrder: 0 @@ -201,8 +168,8 @@ TASK_FIND: items: description: An id of the document. example: c8faa-4b3b-4b3b-4b3b - format: string - format: array + type: string + type: array documents: description: The documents returned from the find operation. uiOrder: 1 @@ -210,9 +177,9 @@ TASK_FIND: title: Documents items: title: Document - format: object + type: object required: [] - format: array + type: array data: description: The data returned from the find operation. uiOrder: 2 @@ -220,16 +187,16 @@ TASK_FIND: required: [] items: title: Datum - format: object + type: object required: [] - format: array + type: array required: [] - format: object + type: object required: - status - result title: Output - format: object + type: object TASK_UPDATE: shortDescription: Perform an update operation input: @@ -237,51 +204,39 @@ TASK_UPDATE: properties: database-name: description: The name of the database in MongoDB. - acceptFormats: - - string + type: string uiOrder: 0 title: Database Name - format: string collection-name: description: The name of the collection in MongoDB. - acceptFormats: - - string + type: string uiOrder: 1 title: Collection Name - format: string id: description: The ID of the document. - acceptFormats: - - string + type: string uiOrder: 2 title: ID - format: string filter: description: The filter to update documents, please refer to [the documentations](https://www.mongodb.com/docs/manual/reference/operator/query/). If empty then all documents will be returned. - acceptFormats: - - json - - object + type: object shortDescription: The mongodb language query to filter the documents uiOrder: 3 title: Filter required: [] - format: object update-data: description: The updated data to be applied to the documents. - acceptFormats: - - json - - object + type: object uiOrder: 4 title: Update required: [] - format: object required: - database-name - collection-name - update-data title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -290,11 +245,11 @@ TASK_UPDATE: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DELETE: shortDescription: Perform a delete operation input: @@ -302,41 +257,32 @@ TASK_DELETE: properties: database-name: description: The name of the database in MongoDB. - acceptFormats: - - string + type: string uiOrder: 0 title: Database Name - format: string collection-name: description: The name of the collection in MongoDB. - acceptFormats: - - string + type: string uiOrder: 1 title: Collection Name - format: string id: description: The ID of the document. - acceptFormats: - - string + type: string uiOrder: 2 title: ID - format: string filter: description: The filter to delete documents, please refer to [the documentations](https://www.mongodb.com/docs/manual/reference/operator/query/). If empty then all documents will be returned. - acceptFormats: - - json - - object + type: object shortDescription: The mongodb language query to filter the documents uiOrder: 3 title: Filter required: [] - format: object required: - database-name - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -345,11 +291,11 @@ TASK_DELETE: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DROP_COLLECTION: shortDescription: Delete the collection input: @@ -357,23 +303,19 @@ TASK_DROP_COLLECTION: properties: database-name: description: The name of the database in MongoDB. - acceptFormats: - - string + type: string uiOrder: 0 title: Database Name - format: string collection-name: description: The name of the collection in MongoDB. - acceptFormats: - - string + type: string uiOrder: 1 title: Collection Name - format: string required: - database-name - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -382,11 +324,11 @@ TASK_DROP_COLLECTION: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DROP_DATABASE: shortDescription: Delete the database input: @@ -394,15 +336,13 @@ TASK_DROP_DATABASE: properties: database-name: description: The name of the database in MongoDB. - acceptFormats: - - string + type: string uiOrder: 0 title: Database Name - format: string required: - database-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -411,11 +351,11 @@ TASK_DROP_DATABASE: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_CREATE_SEARCH_INDEX: shortDescription: Create a search index, only works for M10 or larger clusters input: @@ -423,48 +363,37 @@ TASK_CREATE_SEARCH_INDEX: properties: database-name: description: The name of the database in MongoDB. - acceptFormats: - - string + type: string uiOrder: 0 title: Database Name - format: string collection-name: description: The name of the collection in MongoDB. - acceptFormats: - - string + type: string uiOrder: 1 title: Collection Name - format: string index-name: description: The name of the index to be created. - acceptFormats: - - string + type: string shortDescription: Index Name uiOrder: 2 title: Index Name - format: string index-type: description: The type of the index to be created. - acceptFormats: - - string + type: string shortDescription: Index Type uiOrder: 3 enum: - search - vectorSearch title: Index Type - format: string syntax: description: The syntax structure of the search index, please refer to the MongoDB documentation for more information. search [here](https://www.mongodb.com/docs/atlas/atlas-search/create-index/). vectorSearch [here](https://www.mongodb.com/docs/atlas/atlas-vector-search/vector-search-type/). - acceptFormats: - - json - - object + type: object shortDescription: Syntax Structure, please refer to the MongoDB documentation uiOrder: 4 title: Syntax required: [] - format: object required: - database-name - collection-name @@ -472,7 +401,7 @@ TASK_CREATE_SEARCH_INDEX: - index-name - syntax title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -481,11 +410,11 @@ TASK_CREATE_SEARCH_INDEX: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DROP_SEARCH_INDEX: shortDescription: Drop a search index, only works for M10 or larger clusters input: @@ -493,32 +422,26 @@ TASK_DROP_SEARCH_INDEX: properties: database-name: description: The name of the database in MongoDB. - acceptFormats: - - string + type: string uiOrder: 0 title: Database Name - format: string collection-name: description: The name of the collection in MongoDB. - acceptFormats: - - string + type: string uiOrder: 1 title: Collection Name - format: string index-name: description: The name of the index to be dropped. - acceptFormats: - - string + type: string shortDescription: Index Name uiOrder: 2 title: Index Name - format: string required: - database-name - collection-name - index-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -527,11 +450,11 @@ TASK_DROP_SEARCH_INDEX: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_VECTOR_SEARCH: shortDescription: Perform a vector search operation input: @@ -539,96 +462,74 @@ TASK_VECTOR_SEARCH: properties: database-name: description: The name of the database in MongoDB. - acceptFormats: - - string + type: string uiOrder: 0 title: Database Name - format: string collection-name: description: The name of the collection in MongoDB. - acceptFormats: - - string + type: string uiOrder: 1 title: Collection Name - format: string index-name: description: The name of the index to be used for vector search. - acceptFormats: - - string + type: string shortDescription: Index Name uiOrder: 2 title: Index Name - format: string query-vector: description: The query vector to be used for vector search. - acceptFormats: - - array - - array + type: array shortDescription: Query Vector uiOrder: 3 title: Query Vector items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 - format: array exact: description: The exact value for vector search. If true, then ENN search will be performed, otherwise ANN search will be performed. Default to false. - acceptFormats: - - boolean + type: boolean shortDescription: Exact Search, true for ENN search, false for ANN search uiOrder: 4 title: Exact default: false - format: boolean limit: description: Limit the documents to be returned. - acceptFormats: - - integer + type: integer shortDescription: Limit Documents uiOrder: 5 title: Limit - format: integer num-candidates: description: The number of candidates to the field to be used for vector search. Default to 3 times limit. - acceptFormats: - - integer + type: integer shortDescription: Number of Candidates, default to 3 times limit uiOrder: 6 title: Number of Candidates - format: integer path: description: The path to the field to be used for vector search. - acceptFormats: - - string + type: string shortDescription: Path, need to first create vectorSearch search index uiOrder: 7 title: Path - format: string filter: description: The filter to be used for vector search, need to first create filter vectorSearch search index, please refer to [the documentations](https://www.mongodb.com/docs/manual/reference/operator/query/). If empty then all documents will be returned to be used for vector search. - acceptFormats: - - json - - object + type: object shortDescription: The mongodb language query to filter the documents, empty for all documents uiOrder: 8 title: Filter required: [] - format: object fields: description: The fields to return in the documents. If empty then all fields will be returned. - acceptFormats: - - array + type: array shortDescription: Fields to be returned, empty for all fields uiOrder: 9 title: Fields items: title: Field - format: string + type: string minItems: 1 - format: array required: - database-name - collection-name @@ -637,7 +538,7 @@ TASK_VECTOR_SEARCH: - path - limit title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -646,7 +547,7 @@ TASK_VECTOR_SEARCH: required: [] uiOrder: 0 title: Status - format: string + type: string result: description: Result of the vector search operation. uiOrder: 0 @@ -660,8 +561,8 @@ TASK_VECTOR_SEARCH: items: description: An id of the document. example: c8faa-4b3b-4b3b-4b3b - format: string - format: array + type: string + type: array documents: description: The documents returned from the vector search operation. uiOrder: 1 @@ -669,9 +570,9 @@ TASK_VECTOR_SEARCH: title: Documents items: title: Document - format: object + type: object required: [] - format: array + type: array vectors: description: The vectors returned from the vector search operation. uiOrder: 2 @@ -683,9 +584,9 @@ TASK_VECTOR_SEARCH: items: description: A dimension of the vector. example: 0.8167237 - format: number - format: array - format: array + type: number + type: array + type: array metadata: description: The metadata returned from the vector search operation. uiOrder: 3 @@ -693,13 +594,13 @@ TASK_VECTOR_SEARCH: required: [] items: title: Metadatum - format: object + type: object required: [] - format: array + type: array required: [] - format: object + type: object required: - status - result title: Output - format: object + type: object diff --git a/pkg/component/data/pinecone/v0/README.mdx b/pkg/component/data/pinecone/v0/README.mdx index 0a4a2497b..96998b580 100644 --- a/pkg/component/data/pinecone/v0/README.mdx +++ b/pkg/component/data/pinecone/v0/README.mdx @@ -39,7 +39,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key (required) | `api-key` | string | Fill in your Pinecone AI API key. You can create an api key in Pinecone Console. | | Pinecone Index URL | `url` | string | Fill in your Pinecone index URL. It is in the form. | @@ -58,7 +58,7 @@ Retrieve the ids of the most similar items in a namespace, along with their simi
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_QUERY` | | ID | `id` | string | The unique ID of the vector to be used as a query vector. If present, the vector parameter will be ignored. | @@ -78,7 +78,7 @@ Retrieve the ids of the most similar items in a namespace, along with their simi
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Namespace | `namespace` | string | The namespace of the query. | | [Matches](#query-matches) | `matches` | array[object] | The matches returned for the query. | @@ -91,7 +91,7 @@ Retrieve the ids of the most similar items in a namespace, along with their simi
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | ID | `id` | string | The ID of the matched vector. | | Metadata | `metadata` | json | Metadata. | @@ -107,7 +107,7 @@ Writes vectors into a namespace. If a new value is upserted for an existing vect
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPSERT` | | ID (required) | `id` | string | This is the vector's unique id. | @@ -123,7 +123,7 @@ Writes vectors into a namespace. If a new value is upserted for an existing vect
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Upserted Count | `upserted-count` | integer | Number of records modified or added. |
@@ -135,7 +135,7 @@ Writes vectors into a namespace. If a new value is upserted for an existing vect
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_BATCH_UPSERT` | | [Vectors](#batch-upsert-vectors) (required) | `vectors` | array[object] | Array of vectors to upsert | @@ -152,7 +152,7 @@ Array of vectors to upsert
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | ID | `id` | string | The unique ID of the vector. | | Metadata | `metadata` | object | The vector metadata. This is a set of key-value pairs that can be used to store additional information about the vector. The values can have the following types: string, number, boolean, or array of strings. | @@ -164,7 +164,7 @@ Array of vectors to upsert
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Upserted Count | `upserted-count` | integer | Number of records modified or added. |
@@ -176,7 +176,7 @@ Rerank documents, such as text passages, according to their relevance to a query
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_RERANK` | | Query (required) | `query` | string | The query to rerank the documents. | @@ -191,7 +191,7 @@ Rerank documents, such as text passages, according to their relevance to a query
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Reranked Documents. | `documents` | array[string] | Reranked documents. | | Scores | `scores` | array[number] | The relevance score of the documents normalized between 0 and 1. | diff --git a/pkg/component/data/pinecone/v0/config/setup.yaml b/pkg/component/data/pinecone/v0/config/setup.yaml index 52c1aabf7..5e2bc1837 100644 --- a/pkg/component/data/pinecone/v0/config/setup.yaml +++ b/pkg/component/data/pinecone/v0/config/setup.yaml @@ -2,21 +2,17 @@ additionalProperties: false properties: api-key: description: Fill in your Pinecone AI API key. You can create an api key in Pinecone Console. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: API Key - format: string url: description: Fill in your Pinecone index URL. It is in the form. - acceptFormats: - - string + type: string instillSecret: false uiOrder: 1 title: Pinecone Index URL - format: string required: - api-key title: Pinecone Connection -format: object +type: object diff --git a/pkg/component/data/pinecone/v0/config/tasks.yaml b/pkg/component/data/pinecone/v0/config/tasks.yaml index 57df6f3bb..646c92c4e 100644 --- a/pkg/component/data/pinecone/v0/config/tasks.yaml +++ b/pkg/component/data/pinecone/v0/config/tasks.yaml @@ -5,78 +5,60 @@ TASK_QUERY: properties: id: description: The unique ID of the vector to be used as a query vector. If present, the vector parameter will be ignored. - acceptFormats: - - string + type: string shortDescription: Query by vector ID instead of by vector uiOrder: 0 title: ID - format: string vector: description: An array of dimensions for the query vector. - acceptFormats: - - array - - array + type: array uiOrder: 1 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Vector - format: array top-k: description: The number of results to return for each query. - acceptFormats: - - integer + type: integer uiOrder: 2 title: Top K - format: integer namespace: description: The namespace to query. - acceptFormats: - - string + type: string uiOrder: 3 title: Namespace - format: string filter: description: The filter to apply. You can use vector metadata to limit your search. See more details here. - acceptFormats: - - json + type: object shortDescription: The filter to apply on vector metadata uiOrder: 4 order: 1 required: [] title: Filter - format: object min-score: description: Exclude results whose score is below this value. - acceptFormats: - - number - - integer + type: number uiOrder: 5 title: Minimum Score - format: number include-metadata: default: false description: Indicates whether metadata is included in the response as well as the IDs. - acceptFormats: - - boolean + type: boolean uiOrder: 6 title: Include Metadata - format: boolean include-values: default: false description: Indicates whether vector values are included in the response. - acceptFormats: - - boolean + type: boolean uiOrder: 7 title: Include Values - format: boolean required: - top-k - vector title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -89,44 +71,44 @@ TASK_QUERY: description: The ID of the matched vector. uiOrder: 0 title: ID - format: string + type: string metadata: description: Metadata. uiOrder: 3 required: [] title: Metadata - format: json + type: json score: description: A measure of similarity between this vector and the query vector. The higher the score, the more similar they are. uiOrder: 1 title: Score - format: number + type: number values: description: Vector data values. uiOrder: 2 items: description: Each float value represents one dimension. title: Value - format: number + type: number title: Values - format: array + type: array required: - id - score title: Match - format: object + type: object title: Matches - format: array + type: array namespace: description: The namespace of the query. uiOrder: 0 title: Namespace - format: string + type: string required: - namespace - matches title: Output - format: object + type: object TASK_UPSERT: shortDescription: Writes vectors into a namespace. If a new value is upserted for an existing vector id, it will overwrite the previous value. description: Writes vectors into a namespace. If a new value is upserted for an existing vector id, it will overwrite the previous value. This task will @@ -136,46 +118,37 @@ TASK_UPSERT: properties: id: description: This is the vector's unique id. - acceptFormats: - - string + type: string uiOrder: 0 title: ID - format: string metadata: description: The vector metadata. - acceptFormats: - - json + type: object shortDescription: The vector metadata uiOrder: 3 order: 1 required: [] title: Metadata - format: object values: description: An array of dimensions for the vector to be saved. - acceptFormats: - - array - - array + type: array uiOrder: 1 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Values - format: array namespace: description: The namespace to query. - acceptFormats: - - string + type: string uiOrder: 2 title: Namespace - format: string required: - id - values title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -183,11 +156,11 @@ TASK_UPSERT: description: Number of records modified or added. uiOrder: 0 title: Upserted Count - format: integer + type: integer required: - upserted-count title: Output - format: object + type: object TASK_BATCH_UPSERT: shortDescription: Writes vectors into a namespace. If a new value is upserted for an existing vector ID, it will overwrite the previous value. input: @@ -201,51 +174,42 @@ TASK_BATCH_UPSERT: id: description: The unique ID of the vector. uiOrder: 0 - acceptFormats: - - string + type: string title: ID - format: string metadata: description: 'The vector metadata. This is a set of key-value pairs that can be used to store additional information about the vector. The values can have the following types: string, number, boolean, or array of strings.' uiOrder: 1 - acceptFormats: - - json + type: object shortDescription: The vector metadata required: [] title: Metadata - format: object values: description: An array of dimensions for the vector to be saved. uiOrder: 2 - acceptFormats: - - array - - array + type: array items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Values - format: array required: - id - values - format: object + type: object minItems: 1 title: Vectors - format: array + type: array namespace: description: The namespace to query. - acceptFormats: - - string + type: string uiOrder: 1 title: Namespace - format: string required: - vectors title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -253,11 +217,11 @@ TASK_BATCH_UPSERT: description: Number of records modified or added. uiOrder: 0 title: Upserted Count - format: integer + type: integer required: - upserted-count title: Output - format: object + type: object TASK_RERANK: shortDescription: Rerank documents, such as text passages, according to their relevance to a query. description: Rerank documents, such as text passages, according to their relevance to a query. The input is a list of documents and a query. The output @@ -267,32 +231,28 @@ TASK_RERANK: properties: query: description: The query to rerank the documents. - acceptFormats: - - string + type: string instullUIMultiline: false uiOrder: 0 title: Query - format: string documents: description: The documents to rerank. uiOrder: 1 items: - format: string + type: string minItems: 1 title: Documents - format: array + type: array top-n: description: The number of results to return sorted by relevance. Defaults to the number of inputs. - acceptFormats: - - integer + type: integer uiOrder: 2 title: Top N - format: integer required: - query - documents title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -300,20 +260,20 @@ TASK_RERANK: description: Reranked documents. items: title: Documents - format: string + type: string uiOrder: 0 title: Reranked documents. - format: array + type: array scores: description: The relevance score of the documents normalized between 0 and 1. items: title: Score - format: number + type: number uiOrder: 1 title: Scores - format: array + type: array required: - documents - scores title: Output - format: object + type: object diff --git a/pkg/component/data/qdrant/v0/README.mdx b/pkg/component/data/qdrant/v0/README.mdx index 512e5efce..762a754fb 100644 --- a/pkg/component/data/qdrant/v0/README.mdx +++ b/pkg/component/data/qdrant/v0/README.mdx @@ -41,7 +41,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key (required) | `api-key` | string | Fill in your Qdrant API key. Please refer to clusters in Qdrant data access control. | | Qdrant URL Endpoint (required) | `url` | string | Fill in your Qdrant URL endpoint. Please refer to clusters in Qdrant cluster details. | @@ -60,7 +60,7 @@ Perform a vector search on a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_VECTOR_SEARCH` | | Collection Name (required) | `collection-name` | string | The name of the collection to perform vector similarity search on. | @@ -79,7 +79,7 @@ Perform a vector search on a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Result](#vector-search-result) | `result` | object | Result of the vector search operation. | | Status | `status` | string | Vector search status. | @@ -92,7 +92,7 @@ Perform a vector search on a collection
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | IDs | `ids` | array | The ids returned from the vector search operation. | | [Metadata](#vector-search-metadata) | `metadata` | array | The metadata returned from the vector search operation. | @@ -108,7 +108,7 @@ Insert multiple vector points into a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_BATCH_UPSERT` | | Collection Name (required) | `collection-name` | string | The name of the collection to upsert the point into. | @@ -125,7 +125,7 @@ Insert multiple vector points into a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Batch upsert status. |
@@ -137,7 +137,7 @@ Upsert a vector point into a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPSERT` | | Collection Name (required) | `collection-name` | string | The name of the collection to upsert the point into. | @@ -154,7 +154,7 @@ Upsert a vector point into a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Upsert status. |
@@ -166,7 +166,7 @@ Delete vector points from a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE` | | Collection Name (required) | `collection-name` | string | The name of the collection to delete the object from. | @@ -182,7 +182,7 @@ Delete vector points from a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete status. |
@@ -194,7 +194,7 @@ Create a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_COLLECTION` | | Collection Name (required) | `collection-name` | string | The name of the collection to create. | @@ -208,7 +208,7 @@ Create a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Create collection status. |
@@ -220,7 +220,7 @@ Delete a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE_COLLECTION` | | Collection Name (required) | `collection-name` | string | The name of the collection to delete. | @@ -233,7 +233,7 @@ Delete a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete collection status. |
diff --git a/pkg/component/data/qdrant/v0/config/setup.yaml b/pkg/component/data/qdrant/v0/config/setup.yaml index 3d4092f95..819ca4390 100644 --- a/pkg/component/data/qdrant/v0/config/setup.yaml +++ b/pkg/component/data/qdrant/v0/config/setup.yaml @@ -2,22 +2,18 @@ additionalProperties: false properties: api-key: description: Fill in your Qdrant API key. Please refer to clusters in Qdrant data access control. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: API Key - format: string url: description: Fill in your Qdrant URL endpoint. Please refer to clusters in Qdrant cluster details. - acceptFormats: - - string + type: string instillSecret: false uiOrder: 1 title: Qdrant URL Endpoint - format: string required: - api-key - url title: Qdrant Connection -format: object +type: object diff --git a/pkg/component/data/qdrant/v0/config/tasks.yaml b/pkg/component/data/qdrant/v0/config/tasks.yaml index 404da5256..fb7896160 100644 --- a/pkg/component/data/qdrant/v0/config/tasks.yaml +++ b/pkg/component/data/qdrant/v0/config/tasks.yaml @@ -5,75 +5,58 @@ TASK_VECTOR_SEARCH: properties: collection-name: description: The name of the collection to perform vector similarity search on. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string vector: description: An array of dimensions for the vector query. - acceptFormats: - - array - - array + type: array uiOrder: 1 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Vector - format: array limit: description: The limit of points, empty for all points. - acceptFormats: - - integer + type: integer shortDescription: Limit Rows uiOrder: 2 title: Limit - format: integer payloads: description: The payloads to return in the points. If empty then all payloads will be returned. - acceptFormats: - - array + type: array shortDescription: Payloads to be returned, empty for all payloads uiOrder: 3 title: Payloads minItems: 1 items: title: Field - format: string - format: array + type: string filter: description: The properties filter to be applied to the data with Qdrant filter, please refer to [filter section](https://api.qdrant.tech/api-reference/search/points). - acceptFormats: - - json - - object + type: object uiOrder: 4 title: Filter required: [] - format: object params: description: The additional parameters to be passed to the search, please refer to [params section](https://api.qdrant.tech/api-reference/search/points). - acceptFormats: - - json - - object + type: object uiOrder: 5 title: Params required: [] - format: object min-score: description: The minimum score of the points to be returned. - acceptFormats: - - number + type: number uiOrder: 6 title: Min Score - format: number required: - collection-name - vector - limit title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -81,7 +64,7 @@ TASK_VECTOR_SEARCH: description: Vector search status. uiOrder: 0 title: Status - format: string + type: string result: description: Result of the vector search operation. uiOrder: 0 @@ -95,8 +78,8 @@ TASK_VECTOR_SEARCH: items: description: An id of the point. example: c8faa-4b3b-4b3b-4b3b - format: string - format: array + type: string + type: array points: description: The points returned from the vector search operation. uiOrder: 1 @@ -104,9 +87,9 @@ TASK_VECTOR_SEARCH: title: Points items: title: Point - format: object + type: object required: [] - format: array + type: array vectors: description: The vectors returned from the vector search operation. uiOrder: 2 @@ -118,9 +101,9 @@ TASK_VECTOR_SEARCH: items: description: A dimension of the vector. example: 0.8167237 - format: number - format: array - format: array + type: number + type: array + type: array metadata: description: The metadata returned from the vector search operation. uiOrder: 3 @@ -128,16 +111,16 @@ TASK_VECTOR_SEARCH: required: [] items: title: Metadatum - format: object + type: object required: [] - format: array + type: array required: [] - format: object + type: object required: - status - result title: Output - format: object + type: object TASK_BATCH_UPSERT: shortDescription: Insert multiple vector points into a collection input: @@ -145,30 +128,22 @@ TASK_BATCH_UPSERT: properties: collection-name: description: The name of the collection to upsert the point into. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string array-id: description: The array of id. - acceptFormats: - - array + type: array uiOrder: 1 items: description: An id of the point. example: 1 - format: string + type: string minItems: 1 title: Array ID - format: array array-metadata: description: The array of vector metadata payload. - acceptFormats: - - array - - array - - array - - array + type: array uiOrder: 2 minItems: 1 title: Array Metadata @@ -176,30 +151,23 @@ TASK_BATCH_UPSERT: description: The vector metadata payload. title: Metadatum required: [] - format: object - format: array + type: object array-vector: description: The array of vector values. - acceptFormats: - - array + type: array uiOrder: 3 items: description: An array of dimensions for the vector value. - acceptFormats: - - array - - array + type: array items: description: A dimension of the vector. example: 0.8167237 - format: number - format: array + type: number minItems: 1 title: Array Vector - format: array ordering: description: The ordering guarantees of the batch upsert. - acceptFormats: - - string + type: string default: weak uiOrder: 4 title: Ordering @@ -207,13 +175,12 @@ TASK_BATCH_UPSERT: - weak - medium - strong - format: string required: - collection-name - array-id - array-vector title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -221,11 +188,11 @@ TASK_BATCH_UPSERT: description: Batch upsert status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_UPSERT: shortDescription: Upsert a vector point into a collection input: @@ -233,44 +200,33 @@ TASK_UPSERT: properties: collection-name: description: The name of the collection to upsert the point into. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string id: description: The ID of the point. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string metadata: description: The vector metadata payload. - acceptFormats: - - json - - object + type: object uiOrder: 2 title: Metadata required: [] - format: object vector: description: An array of dimensions for the vector value. - acceptFormats: - - array - - array + type: array uiOrder: 3 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Vector - format: array ordering: description: The ordering guarantees of the batch upsert. - acceptFormats: - - string + type: string default: weak uiOrder: 4 title: Ordering @@ -278,13 +234,12 @@ TASK_UPSERT: - weak - medium - strong - format: string required: - collection-name - id - vector title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -292,11 +247,11 @@ TASK_UPSERT: description: Upsert status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DELETE: shortDescription: Delete vector points from a collection input: @@ -304,31 +259,23 @@ TASK_DELETE: properties: collection-name: description: The name of the collection to delete the object from. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string id: description: The ID of the point. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string filter: description: The properties filter to be applied to the data with Qdrant filter, please refer to [filter section](https://api.qdrant.tech/api-reference/points/delete-points). - acceptFormats: - - json - - object + type: object uiOrder: 2 title: Filter required: [] - format: object ordering: description: The ordering guarantees of the batch upsert. - acceptFormats: - - string + type: string default: weak uiOrder: 3 title: Ordering @@ -336,11 +283,10 @@ TASK_DELETE: - weak - medium - strong - format: string required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -348,11 +294,11 @@ TASK_DELETE: description: Delete status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_CREATE_COLLECTION: shortDescription: Create a collection input: @@ -360,25 +306,20 @@ TASK_CREATE_COLLECTION: properties: collection-name: description: The name of the collection to create. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string config: description: The configuration of the collection. Please refer to [here](https://api.qdrant.tech/api-reference/collections/create-collection). - acceptFormats: - - json - - object + type: object uiOrder: 1 title: Config required: [] - format: object required: - collection-name - config title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -386,11 +327,11 @@ TASK_CREATE_COLLECTION: description: Create collection status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DELETE_COLLECTION: shortDescription: Delete a collection input: @@ -398,15 +339,13 @@ TASK_DELETE_COLLECTION: properties: collection-name: description: The name of the collection to delete. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -414,8 +353,8 @@ TASK_DELETE_COLLECTION: description: Delete collection status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object diff --git a/pkg/component/data/redis/v0/README.mdx b/pkg/component/data/redis/v0/README.mdx index 5956d7811..9f01854d3 100644 --- a/pkg/component/data/redis/v0/README.mdx +++ b/pkg/component/data/redis/v0/README.mdx @@ -38,7 +38,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Host (required) | `host` | string | Redis host to connect to. | | Port (required) | `port` | integer | Port of Redis. | @@ -60,7 +60,7 @@ Retrieve chat history from Redis.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_RETRIEVE_CHAT_HISTORY` | | Session ID (required) | `session-id` | string | A unique identifier for the chat session. | @@ -75,7 +75,7 @@ Retrieve chat history from Redis.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Chat Message](#retrieve-chat-history-chat-message) | `messages` | array[object] | Messages. |
@@ -87,7 +87,7 @@ Retrieve chat history from Redis.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Content](#retrieve-chat-history-content) | `content` | array | The message content | | Metadata | `metadata` | json | The message metadata | @@ -98,7 +98,7 @@ Retrieve chat history from Redis.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Image URL](#retrieve-chat-history-image-url) | `image-url` | object | The image URL | | Text | `text` | string | The text content. | @@ -109,7 +109,7 @@ Retrieve chat history from Redis.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | URL | `url` | string | Either a URL of the image or the base64 encoded image data. |
@@ -122,7 +122,7 @@ Write chat message into Redis.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_WRITE_CHAT_MESSAGE` | | Session ID (required) | `session-id` | string | A unique identifier for the chat session. | @@ -138,7 +138,7 @@ Write chat message into Redis.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | boolean | The status of the write operation. |
@@ -150,7 +150,7 @@ Write multi-modal chat message into Redis.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_WRITE_MULTI_MODAL_CHAT_MESSAGE` | | Session ID (required) | `session-id` | string | A unique identifier for the chat session. | @@ -166,7 +166,7 @@ Write multi-modal chat message into Redis.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | boolean | The status of the write operation. |
diff --git a/pkg/component/data/redis/v0/config/setup.yaml b/pkg/component/data/redis/v0/config/setup.yaml index aa6d715b7..fdbfd91da 100644 --- a/pkg/component/data/redis/v0/config/setup.yaml +++ b/pkg/component/data/redis/v0/config/setup.yaml @@ -5,47 +5,37 @@ properties: description: Redis host to connect to. examples: - localhost,127.0.0.1 - acceptFormats: - - string + type: string instillSecret: false uiOrder: 0 title: Host - format: string password: description: Password associated with Redis. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 3 title: Password - format: string port: default: 6379 description: Port of Redis. - acceptFormats: - - integer + type: integer uiOrder: 1 maximum: 65536 minimum: 0 title: Port - format: integer ssl: default: false description: Indicates whether SSL encryption protocol will be used to connect to Redis. It is recommended to use SSL connection if possible. - acceptFormats: - - boolean + type: boolean uiOrder: 4 title: SSL Connection - format: boolean username: description: Username associated with Redis. - acceptFormats: - - string + type: string uiOrder: 2 title: Username - format: string required: - host - port title: Redis Connection -format: object +type: object diff --git a/pkg/component/data/redis/v0/config/tasks.yaml b/pkg/component/data/redis/v0/config/tasks.yaml index f4662fd9f..7a5411e21 100644 --- a/pkg/component/data/redis/v0/config/tasks.yaml +++ b/pkg/component/data/redis/v0/config/tasks.yaml @@ -6,32 +6,26 @@ TASK_RETRIEVE_CHAT_HISTORY: include-system-message: default: true description: Include system message in the retrieved conversation turns if exists. - acceptFormats: - - boolean + type: boolean uiOrder: 2 title: Include System Message If Exists - format: boolean latest-k: default: 5 description: The number of latest conversation turns to retrieve. A conversation turn typically includes one participant speaking or sending a message, and the other participant(s) responding to it. - acceptFormats: - - integer + type: integer uiOrder: 1 minimum: 1 title: Latest K - format: integer session-id: description: A unique identifier for the chat session. - acceptFormats: - - string + type: string uiOrder: 0 title: Session ID - format: string required: - session-id title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -42,7 +36,7 @@ TASK_RETRIEVE_CHAT_HISTORY: required: - messages title: Output - format: object + type: object TASK_WRITE_CHAT_MESSAGE: shortDescription: Write chat message into Redis. input: @@ -50,38 +44,32 @@ TASK_WRITE_CHAT_MESSAGE: properties: content: description: The message content. - acceptFormats: - - string + type: string uiOrder: 2 title: Content - format: string metadata: additionalProperties: true description: The message metadata. uiOrder: 3 required: [] title: Metadata - format: object + type: object role: description: The message role, i.e. 'system', 'user' or 'assistant'. - acceptFormats: - - string + type: string uiOrder: 1 title: Role - format: string session-id: description: A unique identifier for the chat session. - acceptFormats: - - string + type: string uiOrder: 0 title: Session ID - format: string required: - session-id - role - content title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -89,11 +77,11 @@ TASK_WRITE_CHAT_MESSAGE: description: The status of the write operation. uiOrder: 0 title: Status - format: boolean + type: boolean required: - status title: Output - format: object + type: object TASK_WRITE_MULTI_MODAL_CHAT_MESSAGE: shortDescription: Write multi-modal chat message into Redis. input: @@ -102,38 +90,32 @@ TASK_WRITE_MULTI_MODAL_CHAT_MESSAGE: content: $ref: schema.yaml#/$defs/instill-types/multi-modal-content description: The multi-modal message content. - acceptFormats: - - array + type: string uiOrder: 2 title: Content - format: string metadata: additionalProperties: true description: The message metadata. uiOrder: 3 required: [] title: Metadata - format: object + type: object role: description: The message role, i.e. 'system', 'user' or 'assistant'. - acceptFormats: - - string + type: string uiOrder: 1 title: Role - format: string session-id: description: A unique identifier for the chat session. - acceptFormats: - - string + type: string uiOrder: 0 title: Session ID - format: string required: - session-id - role - content title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -141,8 +123,8 @@ TASK_WRITE_MULTI_MODAL_CHAT_MESSAGE: description: The status of the write operation. uiOrder: 0 title: Status - format: boolean + type: boolean required: - status title: Output - format: object + type: object diff --git a/pkg/component/data/sql/v0/README.mdx b/pkg/component/data/sql/v0/README.mdx index 730137009..57084ee13 100644 --- a/pkg/component/data/sql/v0/README.mdx +++ b/pkg/component/data/sql/v0/README.mdx @@ -43,7 +43,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Engine (required) | `engine` | string | Choose the engine of your database.
Enum values
  • `MySQL`
  • `PostgreSQL`
  • `SQL Server`
  • `Oracle`
  • `MariaDB`
  • `Firebird`
| | Username (required) | `username` | string | Fill in your account username. | @@ -67,7 +67,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | SSL / TLS Type | `ssl-tls-type` | string | Must be `"NO TLS"` |
@@ -76,7 +76,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | CA Certificate | `ssl-tls-ca` | string | Base64 encoded CA certificate file. | | SSL / TLS Type | `ssl-tls-type` | string | Must be `"TLS"` | @@ -86,7 +86,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | CA Certificate | `ssl-tls-ca` | string | Base64 encoded CA certificate file. | | Client Certificate | `ssl-tls-cert` | string | Base64 encoded client certificate file. | @@ -104,7 +104,7 @@ Perform insert operation
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INSERT` | | Table Name (required) | `table-name` | string | The table name in the database to insert data into. | @@ -118,7 +118,7 @@ Perform insert operation
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Insert status. |
@@ -130,7 +130,7 @@ Perform insert operation with multiple rows
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INSERT_MANY` | | Table Name (required) | `table-name` | string | The table name in the database to insert data into. | @@ -144,7 +144,7 @@ Perform insert operation with multiple rows
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Insert many status. |
@@ -156,7 +156,7 @@ Perform update operation
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE` | | Table Name (required) | `table-name` | string | The table name in the database to update data into. | @@ -171,7 +171,7 @@ Perform update operation
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Update status. |
@@ -183,7 +183,7 @@ Perform select operation
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SELECT` | | Table Name (required) | `table-name` | string | The table name in the database to be selected. | @@ -199,7 +199,7 @@ Perform select operation
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Rows | `rows` | array[json] | The rows returned from the select operation. | | Status | `status` | string | Select status. | @@ -212,7 +212,7 @@ Perform delete operation
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE` | | Table Name (required) | `table-name` | string | The table name in the database to be deleted. | @@ -226,7 +226,7 @@ Perform delete operation
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete status. |
@@ -238,7 +238,7 @@ Create a table in the database
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_TABLE` | | Table Name (required) | `table-name` | string | The table name in the database to be created. | @@ -252,7 +252,7 @@ Create a table in the database
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Create table status. |
@@ -264,7 +264,7 @@ Drop a table in the database
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DROP_TABLE` | | Table Name (required) | `table-name` | string | The table name in the database to be dropped. | @@ -277,7 +277,7 @@ Drop a table in the database
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Drop table status. |
diff --git a/pkg/component/data/sql/v0/config/setup.yaml b/pkg/component/data/sql/v0/config/setup.yaml index d6332b282..d5d9cdb57 100644 --- a/pkg/component/data/sql/v0/config/setup.yaml +++ b/pkg/component/data/sql/v0/config/setup.yaml @@ -2,8 +2,7 @@ additionalProperties: false properties: engine: description: Choose the engine of your database. - acceptFormats: - - string + type: string uiOrder: 0 title: Engine enum: @@ -13,44 +12,33 @@ properties: - Oracle - MariaDB - Firebird - format: string username: description: Fill in your account username. - acceptFormats: - - string + type: string uiOrder: 1 title: Username - format: string password: description: Fill in your account password. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 2 title: Password - format: string database-name: description: Fill in the name of your database. - acceptFormats: - - string + type: string uiOrder: 3 title: Database Name - format: string host: description: Fill in the host of your database. - acceptFormats: - - string + type: string uiOrder: 4 title: Host - format: string port: description: Fill in the port of your database. default: 3306 - acceptFormats: - - number + type: number uiOrder: 5 title: Port - format: number ssl-tls: description: Enable SSL / TLS. uiOrder: 6 @@ -62,7 +50,7 @@ properties: uiOrder: 0 order: 0 title: SSL / TLS Type - format: string + type: string required: - ssl-tls-type title: No SSL / TLS @@ -73,16 +61,14 @@ properties: uiOrder: 0 order: 0 title: SSL / TLS Type - format: string + type: string ssl-tls-ca: description: Base64 encoded CA certificate file. shortDescription: Base64 encoded CA certificate file - acceptFormats: - - string + type: string uiOrder: 1 order: 1 title: CA Certificate - format: string required: - ssl-tls-type - ssl-tls-ca @@ -94,34 +80,28 @@ properties: uiOrder: 0 order: 0 title: SSL / TLS Type - format: string + type: string ssl-tls-ca: description: Base64 encoded CA certificate file. shortDescription: Base64 encoded CA certificate file - acceptFormats: - - string + type: string uiOrder: 1 order: 1 title: CA Certificate - format: string ssl-tls-cert: description: Base64 encoded client certificate file. shortDescription: Base64 encoded client certificate file - acceptFormats: - - string + type: string uiOrder: 2 order: 2 title: Client Certificate - format: string ssl-tls-key: description: Base64 encoded client key file. shortDescription: Base64 encoded client key file - acceptFormats: - - string + type: string uiOrder: 3 order: 3 title: Client Key - format: string required: - ssl-tls-type - ssl-tls-ca @@ -130,7 +110,7 @@ properties: title: mTLS order: 6 title: SSL / TLS - format: object + type: object required: - engine - username @@ -140,4 +120,4 @@ required: - port - ssl-tls title: SQL Connection -format: object +type: object diff --git a/pkg/component/data/sql/v0/config/tasks.yaml b/pkg/component/data/sql/v0/config/tasks.yaml index 19fed9357..5bec78696 100644 --- a/pkg/component/data/sql/v0/config/tasks.yaml +++ b/pkg/component/data/sql/v0/config/tasks.yaml @@ -5,29 +5,24 @@ TASK_INSERT: properties: table-name: description: The table name in the database to insert data into. - acceptFormats: - - string + type: string shortDescription: Database Table Name uiOrder: 0 title: Table Name - format: string data: description: The data to be inserted. - acceptFormats: - - json - - object + type: object uiOrder: 1 items: title: Object - format: json + type: json title: Data required: [] - format: object required: - data - table-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -36,11 +31,11 @@ TASK_INSERT: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_INSERT_MANY: shortDescription: Perform insert operation with multiple rows input: @@ -48,33 +43,26 @@ TASK_INSERT_MANY: properties: table-name: description: The table name in the database to insert data into. - acceptFormats: - - string + type: string shortDescription: Database Table Name uiOrder: 0 title: Table Name - format: string array-data: description: The array data to be inserted. - acceptFormats: - - array - - array - - array - - array + type: array uiOrder: 1 title: Data items: description: The data to be inserted. title: Data required: [] - format: object + type: object minItems: 1 - format: array required: - array-data - table-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -83,11 +71,11 @@ TASK_INSERT_MANY: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_UPDATE: shortDescription: Perform update operation input: @@ -95,38 +83,31 @@ TASK_UPDATE: properties: table-name: description: The table name in the database to update data into. - acceptFormats: - - string + type: string shortDescription: Database Table Name uiOrder: 0 title: Table Name - format: string filter: shortDescription: The filter to be applied to the data description: The filter to be applied to the data with SQL syntax, which starts with WHERE clause. uiOrder: 1 - acceptFormats: - - string + type: string title: Filter - format: string update-data: description: The new data to be updated to. - acceptFormats: - - json - - object + type: object uiOrder: 2 items: title: Object - format: json + type: json title: Update required: [] - format: object required: - filter - update-data - table-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -135,11 +116,11 @@ TASK_UPDATE: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_SELECT: shortDescription: Perform select operation input: @@ -147,44 +128,36 @@ TASK_SELECT: properties: table-name: description: The table name in the database to be selected. - acceptFormats: - - string + type: string shortDescription: Database Table Name uiOrder: 0 title: Table Name - format: string filter: shortDescription: The filter to be applied to the data. If empty, then all rows will be updated description: The filter to be applied to the data with SQL syntax, which starts with WHERE clause, empty for all rows. uiOrder: 1 - acceptFormats: - - string + type: string title: Filter - format: string limit: description: The limit of rows to be selected, empty for all rows. - acceptFormats: - - integer + type: integer shortDescription: Limit Rows uiOrder: 2 title: Limit - format: integer columns: description: The columns to return in the rows. If empty then all columns will be returned. - acceptFormats: - - array + type: array shortDescription: Columns to be returned, empty for all columns uiOrder: 3 title: Columns items: title: Column - format: string + type: string minItems: 1 - format: array required: - table-name title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -197,19 +170,19 @@ TASK_SELECT: items: title: Row required: [] - format: json - format: array + type: json + type: array status: description: Select status. required: [] uiOrder: 0 title: Status - format: string + type: string required: - status - rows title: Output - format: object + type: object TASK_DELETE: shortDescription: Perform delete operation input: @@ -217,25 +190,21 @@ TASK_DELETE: properties: table-name: description: The table name in the database to be deleted. - acceptFormats: - - string + type: string shortDescription: Database Table Name uiOrder: 0 title: Table Name - format: string filter: shortDescription: The filter to be applied to the data description: The filter to be applied to the data with SQL syntax, which starts with WHERE clause. uiOrder: 1 - acceptFormats: - - string + type: string title: Filter - format: string required: - filter - table-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -244,11 +213,11 @@ TASK_DELETE: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_CREATE_TABLE: shortDescription: Create a table in the database input: @@ -256,27 +225,22 @@ TASK_CREATE_TABLE: properties: table-name: description: The table name in the database to be created. - acceptFormats: - - string + type: string shortDescription: Database Table Name uiOrder: 0 title: Table Name - format: string columns-structure: description: 'The columns structure to be created in the table, json with value string, e.g {"name": "VARCHAR(255)", "age": "INT not null"}.' - acceptFormats: - - json - - object + type: object shortDescription: 'Columns Structure, e.g {"name": "VARCHAR(255)", "age": "INT not null"}' uiOrder: 1 title: Columns required: [] - format: object required: - table-name - columns-structure title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -285,11 +249,11 @@ TASK_CREATE_TABLE: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DROP_TABLE: shortDescription: Drop a table in the database input: @@ -297,16 +261,14 @@ TASK_DROP_TABLE: properties: table-name: description: The table name in the database to be dropped. - acceptFormats: - - string + type: string shortDescription: Database Table Name uiOrder: 0 title: Table Name - format: string required: - table-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -315,8 +277,8 @@ TASK_DROP_TABLE: required: [] uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object diff --git a/pkg/component/data/weaviate/v0/README.mdx b/pkg/component/data/weaviate/v0/README.mdx index 61567b755..5a2ef100b 100644 --- a/pkg/component/data/weaviate/v0/README.mdx +++ b/pkg/component/data/weaviate/v0/README.mdx @@ -41,7 +41,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key (required) | `api-key` | string | Fill in your Weaviate API key. Please refer to clusters in Weaviate Console. | | Weaviate URL Endpoint (required) | `url` | string | Fill in your Weaviate base URL without https:// or http://. Please refer to clusters in Weaviate Console. | @@ -60,7 +60,7 @@ Perform a vector search on a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_VECTOR_SEARCH` | | Collection Name (required) | `collection-name` | string | The name of the collection to perform vector search on. | @@ -78,7 +78,7 @@ Perform a vector search on a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Result](#vector-search-result) | `result` | object | Result of the vector search operation. | | Status | `status` | string | Upsert status. | @@ -91,7 +91,7 @@ Perform a vector search on a collection
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | IDs | `ids` | array | The ids returned from the vector search operation. | | [Metadata](#vector-search-metadata) | `metadata` | array | The metadata returned from the vector search operation. | @@ -107,7 +107,7 @@ Insert multiple vector objects into a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_BATCH_INSERT` | | Collection Name (required) | `collection-name` | string | The name of the collection to upsert the object into. | @@ -123,7 +123,7 @@ Insert multiple vector objects into a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Batch insert status. |
@@ -135,7 +135,7 @@ Insert a vector object into a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INSERT` | | Collection Name (required) | `collection-name` | string | The name of the collection to upsert the object into. | @@ -151,7 +151,7 @@ Insert a vector object into a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Upsert status. |
@@ -163,7 +163,7 @@ Update vector object in a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPDATE` | | Collection Name (required) | `collection-name` | string | The name of the collection to update the object in. | @@ -179,7 +179,7 @@ Update vector object in a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Update status. |
@@ -191,7 +191,7 @@ Delete vector objects from a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE` | | Collection Name (required) | `collection-name` | string | The name of the collection to delete the object from. | @@ -206,7 +206,7 @@ Delete vector objects from a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete status. |
@@ -218,7 +218,7 @@ Delete a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE_COLLECTION` | | Collection Name (required) | `collection-name` | string | The name of the collection to delete. | @@ -231,7 +231,7 @@ Delete a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete collection status. |
diff --git a/pkg/component/data/weaviate/v0/config/setup.yaml b/pkg/component/data/weaviate/v0/config/setup.yaml index 1f9914ee9..ff2184185 100644 --- a/pkg/component/data/weaviate/v0/config/setup.yaml +++ b/pkg/component/data/weaviate/v0/config/setup.yaml @@ -2,22 +2,18 @@ additionalProperties: false properties: api-key: description: Fill in your Weaviate API key. Please refer to clusters in Weaviate Console. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 0 title: API Key - format: string url: description: Fill in your Weaviate base URL without https:// or http://. Please refer to clusters in Weaviate Console. - acceptFormats: - - string + type: string instillSecret: false uiOrder: 1 title: Weaviate URL Endpoint - format: string required: - api-key - url title: Weaviate Connection -format: object +type: object diff --git a/pkg/component/data/weaviate/v0/config/tasks.yaml b/pkg/component/data/weaviate/v0/config/tasks.yaml index 8730fe72d..7c41c53e9 100644 --- a/pkg/component/data/weaviate/v0/config/tasks.yaml +++ b/pkg/component/data/weaviate/v0/config/tasks.yaml @@ -5,63 +5,49 @@ TASK_VECTOR_SEARCH: properties: collection-name: description: The name of the collection to perform vector search on. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string vector: description: An array of dimensions for the vector query, optional. If not provided, all objects will be returned. - acceptFormats: - - array - - array + type: array uiOrder: 1 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Vector - format: array limit: description: The limit of objects, empty for all objects. - acceptFormats: - - integer + type: integer uiOrder: 2 title: Limit - format: integer fields: description: The fields to return in the objects. If empty then all fields will be returned. - acceptFormats: - - array + type: array shortDescription: Fields to be returned, empty for all fields uiOrder: 3 title: Fields minItems: 1 items: title: Field - format: string - format: array + type: string filter: description: The properties filter to be applied to the data with GraphQL queries, which starts with WHERE field, please refer to [here](https://weaviate.io/developers/weaviate/search/filters). - acceptFormats: - - json - - object + type: object uiOrder: 4 title: Filter required: [] - format: object tenant: description: The tenant to perform the vector search on. - acceptFormats: - - string + type: string uiOrder: 5 title: Tenant - format: string required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -69,7 +55,7 @@ TASK_VECTOR_SEARCH: description: Upsert status. uiOrder: 0 title: Status - format: string + type: string result: description: Result of the vector search operation. uiOrder: 0 @@ -83,8 +69,8 @@ TASK_VECTOR_SEARCH: items: description: An id of the object. example: c8faa-4b3b-4b3b-4b3b - format: string - format: array + type: string + type: array objects: description: The objects returned from the vector search operation. uiOrder: 1 @@ -92,9 +78,9 @@ TASK_VECTOR_SEARCH: title: Objects items: title: Object - format: object + type: object required: [] - format: array + type: array vectors: description: The vectors returned from the vector search operation. uiOrder: 2 @@ -106,9 +92,9 @@ TASK_VECTOR_SEARCH: items: description: A dimension of the vector. example: 0.8167237 - format: number - format: array - format: array + type: number + type: array + type: array metadata: description: The metadata returned from the vector search operation. uiOrder: 3 @@ -116,16 +102,16 @@ TASK_VECTOR_SEARCH: required: [] items: title: Metadatum - format: object + type: object required: [] - format: array + type: array required: [] - format: object + type: object required: - status - result title: Output - format: object + type: object TASK_INSERT: shortDescription: Insert a vector object into a collection input: @@ -133,46 +119,36 @@ TASK_INSERT: properties: collection-name: description: The name of the collection to upsert the object into. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string id: description: The ID of the object. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string vector: description: An array of dimensions for the vector value. - acceptFormats: - - array - - array + type: array uiOrder: 2 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Vector - format: array metadata: description: The vector metadata properties. - acceptFormats: - - json - - object + type: object uiOrder: 3 title: Metadata required: [] - format: object required: - collection-name - vector - metadata title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -180,11 +156,11 @@ TASK_INSERT: description: Upsert status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_BATCH_INSERT: shortDescription: Insert multiple vector objects into a collection input: @@ -192,30 +168,22 @@ TASK_BATCH_INSERT: properties: collection-name: description: The name of the collection to upsert the object into. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string array-id: description: The array of id. - acceptFormats: - - array + type: array uiOrder: 1 items: description: An id of the object. example: 1 - format: string + type: string minItems: 1 title: Array ID - format: array array-metadata: description: The array of vector metadata properties. - acceptFormats: - - array - - array - - array - - array + type: array shortDescription: The vector metadata properties uiOrder: 2 minItems: 1 @@ -224,32 +192,26 @@ TASK_BATCH_INSERT: description: The vector metadata properties. title: Metadatum required: [] - format: object - format: array + type: object array-vector: description: The array of vector values. - acceptFormats: - - array + type: array uiOrder: 3 items: description: An array of dimensions for the vector value. - acceptFormats: - - array - - array + type: array items: description: A dimension of the vector. example: 0.8167237 - format: number - format: array + type: number minItems: 1 title: Array Vector - format: array required: - collection-name - array-metadata - array-vector title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -257,11 +219,11 @@ TASK_BATCH_INSERT: description: Batch insert status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DELETE: shortDescription: Delete vector objects from a collection input: @@ -269,31 +231,24 @@ TASK_DELETE: properties: collection-name: description: The name of the collection to delete the object from. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string id: description: The ID of the object. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string filter: description: The properties filter to be applied to the data with GraphQL queries, which starts with WHERE field, please refer to [here](https://weaviate.io/developers/weaviate/search/filters). - acceptFormats: - - json - - object + type: object uiOrder: 2 title: Filter required: [] - format: object required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -301,11 +256,11 @@ TASK_DELETE: description: Delete status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_UPDATE: shortDescription: Update vector object in a collection input: @@ -313,45 +268,35 @@ TASK_UPDATE: properties: collection-name: description: The name of the collection to update the object in. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string id: description: The ID of the object. - acceptFormats: - - string + type: string uiOrder: 1 title: ID - format: string update-vector: description: The updated vector value, optional. - acceptFormats: - - array - - array + type: array uiOrder: 2 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Update Vector - format: array update-metadata: description: The updated vector metadata properties, optional. - acceptFormats: - - json - - object + type: object uiOrder: 3 title: Update Metadata required: [] - format: object required: - collection-name - id title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -359,11 +304,11 @@ TASK_UPDATE: description: Update status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DELETE_COLLECTION: shortDescription: Delete a collection input: @@ -371,15 +316,13 @@ TASK_DELETE_COLLECTION: properties: collection-name: description: The name of the collection to delete. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -387,8 +330,8 @@ TASK_DELETE_COLLECTION: description: Delete collection status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object diff --git a/pkg/component/data/zilliz/v0/README.mdx b/pkg/component/data/zilliz/v0/README.mdx index 70d35823e..e47fadb06 100644 --- a/pkg/component/data/zilliz/v0/README.mdx +++ b/pkg/component/data/zilliz/v0/README.mdx @@ -43,7 +43,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Zilliz URL Endpoint (required) | `url` | string | Fill in your Zilliz public URL endpoint. | | Zilliz API Key (required) | `api-key` | string | Fill in your Zilliz API key. | @@ -62,7 +62,7 @@ Perform a vector search on a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_VECTOR_SEARCH` | | Collection Name (required) | `collection-name` | string | The name of the collection to perform vector search on. | @@ -84,7 +84,7 @@ Perform a vector search on a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Result](#vector-search-result) | `result` | object | Result of the vector search operation. | | Status | `status` | string | Vector search status. | @@ -97,7 +97,7 @@ Perform a vector search on a collection
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Data](#vector-search-data) | `data` | array | The points returned from the vector search operation. | | IDs | `ids` | array | The ids returned from the vector search operation. | @@ -113,7 +113,7 @@ Insert a vector data into a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UPSERT` | | Collection Name (required) | `collection-name` | string | The name of the collection to upsert the data into. | @@ -128,7 +128,7 @@ Insert a vector data into a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Upsert status. |
@@ -140,7 +140,7 @@ Insert a batch of vector data into a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_BATCH_UPSERT` | | Collection Name (required) | `collection-name` | string | The name of the collection to upsert the data into. | @@ -155,7 +155,7 @@ Insert a batch of vector data into a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Batch upsert status. |
@@ -167,7 +167,7 @@ Delete vector data from a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE` | | Collection Name (required) | `collection-name` | string | The name of the collection to delete the data from. | @@ -182,7 +182,7 @@ Delete vector data from a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Delete status. |
@@ -194,7 +194,7 @@ Create a collection, please refer to [create-collection-v2](https://docs.zilliz.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_COLLECTION` | | Collection Name (required) | `collection-name` | string | The name of the collection to create. | @@ -214,7 +214,7 @@ Create a collection, please refer to [create-collection-v2](https://docs.zilliz.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Create collection status. |
@@ -226,7 +226,7 @@ Drop a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DROP_COLLECTION` | | Collection Name (required) | `collection-name` | string | The name of the collection to drop. | @@ -239,7 +239,7 @@ Drop a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Drop collection status. |
@@ -251,7 +251,7 @@ Create a partition in a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CREATE_PARTITION` | | Collection Name (required) | `collection-name` | string | The name of the collection to create the partition in. | @@ -265,7 +265,7 @@ Create a partition in a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Create partition status. |
@@ -277,7 +277,7 @@ Drop a partition from a collection
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DROP_PARTITION` | | Collection Name (required) | `collection-name` | string | The name of the collection to drop the partition from. | @@ -291,7 +291,7 @@ Drop a partition from a collection
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status | `status` | string | Drop partition status. |
diff --git a/pkg/component/data/zilliz/v0/config/setup.yaml b/pkg/component/data/zilliz/v0/config/setup.yaml index 46054a14a..e00e25196 100644 --- a/pkg/component/data/zilliz/v0/config/setup.yaml +++ b/pkg/component/data/zilliz/v0/config/setup.yaml @@ -2,22 +2,18 @@ additionalProperties: false properties: url: description: Fill in your Zilliz public URL endpoint. - acceptFormats: - - string + type: string instillSecret: false uiOrder: 0 title: Zilliz URL Endpoint - format: string api-key: description: Fill in your Zilliz API key. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 1 title: Zilliz API Key - format: string required: - url - api-key title: Zilliz Connection -format: object +type: object diff --git a/pkg/component/data/zilliz/v0/config/tasks.yaml b/pkg/component/data/zilliz/v0/config/tasks.yaml index 6e3d3cf54..a1872abed 100644 --- a/pkg/component/data/zilliz/v0/config/tasks.yaml +++ b/pkg/component/data/zilliz/v0/config/tasks.yaml @@ -5,94 +5,72 @@ TASK_VECTOR_SEARCH: properties: collection-name: description: The name of the collection to perform vector search on. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to vector search the data from. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string vector: description: An array of dimensions for the vector search. - acceptFormats: - - array - - array + type: array uiOrder: 2 items: description: A dimension of the vector. example: 0.8167237 - format: number + type: number minItems: 1 title: Vector - format: array vector-field: description: The name of the field to perform vector search on. - acceptFormats: - - string + type: string uiOrder: 3 title: Vector Field - format: string limit: description: The limit of the data to return. - acceptFormats: - - integer + type: integer uiOrder: 4 title: Limit - format: integer fields: description: The fields to return in the data. If empty then all fields will be returned. - acceptFormats: - - array + type: array shortDescription: Fields to be returned, empty for all fields uiOrder: 4 title: Fields minItems: 1 items: title: Field - format: string - format: array + type: string filter: description: The properties filter to be applied to the data with zilliz scalar filter, please refer to [filtered-search](https://docs.zilliz.com/docs/single-vector-search?_highlight=filter/docs/single-vector-search#filtered-search). uiOrder: 5 - acceptFormats: - - string + type: string title: Filter - format: string offset: description: The offset of the data to return. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Offset - format: integer grouping-field: description: The name of the field to group the data by, please refer to [grouping-search](https://docs.zilliz.com/docs/release-notes-290?_highlight=grouping&_highlight=field/docs/release-notes-290#grouping-search). - acceptFormats: - - string + type: string uiOrder: 7 title: Grouping Field - format: string search-params: description: The search parameters to be applied to the data with zilliz search parameters, please refer to [search-parameters](https://docs.zilliz.com/docs/single-vector-search?_highlight=search&_highlight=params/docs/single-vector-search#search-parameters). uiOrder: 8 - acceptFormats: - - json - - object + type: object title: Search Parameters required: [] - format: object required: - collection-name - vector - vector-field - limit title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -100,7 +78,7 @@ TASK_VECTOR_SEARCH: description: Vector search status. uiOrder: 0 title: Status - format: string + type: string result: description: Result of the vector search operation. uiOrder: 0 @@ -114,8 +92,8 @@ TASK_VECTOR_SEARCH: items: description: An id of the point. example: c8faa-4b3b-4b3b-4b3b - format: string - format: array + type: string + type: array data: description: The points returned from the vector search operation. uiOrder: 1 @@ -123,9 +101,9 @@ TASK_VECTOR_SEARCH: title: Data items: title: Datum - format: object + type: object required: [] - format: array + type: array vectors: description: The vectors returned from the vector search operation. uiOrder: 2 @@ -137,9 +115,9 @@ TASK_VECTOR_SEARCH: items: description: A dimension of the vector. example: 0.8167237 - format: number - format: array - format: array + type: number + type: array + type: array metadata: description: The metadata returned from the vector search operation. uiOrder: 3 @@ -147,16 +125,16 @@ TASK_VECTOR_SEARCH: required: [] items: title: Metadatum - format: object + type: object required: [] - format: array + type: array required: [] - format: object + type: object required: - status - result title: Output - format: object + type: object TASK_UPSERT: shortDescription: Insert a vector data into a collection input: @@ -164,32 +142,25 @@ TASK_UPSERT: properties: collection-name: description: The name of the collection to upsert the data into. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to upsert the data from. If empty then default partition will be used. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string data: description: The data. - acceptFormats: - - json - - object + type: object uiOrder: 2 title: Data required: [] - format: object required: - collection-name - data title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -197,11 +168,11 @@ TASK_UPSERT: description: Upsert status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_BATCH_UPSERT: shortDescription: Insert a batch of vector data into a collection input: @@ -209,37 +180,28 @@ TASK_BATCH_UPSERT: properties: collection-name: description: The name of the collection to upsert the data into. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to upsert the data from. If empty then default partition will be used. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string array-data: description: The data. - acceptFormats: - - array - - array - - array - - array + type: array uiOrder: 2 title: Array Data items: description: A datum. required: [] - format: object - format: array + type: object required: - collection-name - array-data title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -247,11 +209,11 @@ TASK_BATCH_UPSERT: description: Batch upsert status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DELETE: shortDescription: Delete vector data from a collection input: @@ -259,29 +221,23 @@ TASK_DELETE: properties: collection-name: description: The name of the collection to delete the data from. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to delete the data from. If empty then default partition will be used. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string filter: description: The properties filter to be applied to the data with zilliz scalar filter, please refer to [filtered-search](https://docs.zilliz.com/docs/single-vector-search?_highlight=filter/docs/single-vector-search#filtered-search). uiOrder: 2 - acceptFormats: - - string + type: string title: Filter - format: string required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -289,11 +245,11 @@ TASK_DELETE: description: Delete status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_CREATE_COLLECTION: shortDescription: Create a collection, please refer to [create-collection-v2](https://docs.zilliz.com/reference/restful/create-collection-v2) input: @@ -301,46 +257,34 @@ TASK_CREATE_COLLECTION: properties: collection-name: description: The name of the collection to create. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string dimension: description: The dimension of the collection. - acceptFormats: - - integer + type: integer uiOrder: 1 title: Dimension - format: integer id-type: description: The type of the id. - acceptFormats: - - string + type: string uiOrder: 3 title: ID Type - format: string schema: description: The schema of the collection. - acceptFormats: - - json - - object + type: object uiOrder: 4 title: Schema required: [] - format: object auto-id: description: Whether to auto generate id. - acceptFormats: - - boolean + type: boolean uiOrder: 5 title: Auto ID default: false - format: boolean metric-type: description: The metric type of the collection. - acceptFormats: - - string + type: string uiOrder: 6 title: Metric Type enum: @@ -348,30 +292,23 @@ TASK_CREATE_COLLECTION: - IP - COSINE default: L2 - format: string index-params: description: The index parameters to be applied to the collection with zilliz index parameters, please refer to [index-parameter](https://zilliz.io/docs/single-vector-search.md#Index-parameters). uiOrder: 7 - acceptFormats: - - json - - object + type: object title: Index Parameters required: [] - format: object params: description: The parameters to be applied to the collection with zilliz parameters, please refer to [parameters](https://zilliz.io/docs/single-vector-search.md#Parameters). uiOrder: 8 - acceptFormats: - - json - - object + type: object title: Parameters required: [] - format: object required: - collection-name - dimension title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -379,11 +316,11 @@ TASK_CREATE_COLLECTION: description: Create collection status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DROP_COLLECTION: shortDescription: Drop a collection input: @@ -391,15 +328,13 @@ TASK_DROP_COLLECTION: properties: collection-name: description: The name of the collection to drop. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string required: - collection-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -407,11 +342,11 @@ TASK_DROP_COLLECTION: description: Drop collection status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_CREATE_PARTITION: shortDescription: Create a partition in a collection input: @@ -419,23 +354,19 @@ TASK_CREATE_PARTITION: properties: collection-name: description: The name of the collection to create the partition in. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to create. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string required: - collection-name - partition-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -443,11 +374,11 @@ TASK_CREATE_PARTITION: description: Create partition status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object TASK_DROP_PARTITION: shortDescription: Drop a partition from a collection input: @@ -455,23 +386,19 @@ TASK_DROP_PARTITION: properties: collection-name: description: The name of the collection to drop the partition from. - acceptFormats: - - string + type: string uiOrder: 0 title: Collection Name - format: string partition-name: description: The name of the partition to drop. - acceptFormats: - - string + type: string uiOrder: 1 title: Partition Name - format: string required: - collection-name - partition-name title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -479,8 +406,8 @@ TASK_DROP_PARTITION: description: Drop partition status. uiOrder: 0 title: Status - format: string + type: string required: - status title: Output - format: object + type: object diff --git a/pkg/component/generic/collection/v0/README.mdx b/pkg/component/generic/collection/v0/README.mdx index 588b1ee0e..bcb1a9dc8 100644 --- a/pkg/component/generic/collection/v0/README.mdx +++ b/pkg/component/generic/collection/v0/README.mdx @@ -42,7 +42,7 @@ Append values to create or extend an array, or add key-value pairs to an object.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_APPEND` | | Data (required) | `data` | any | The input data. If it's an array, the value will be appended. If it's an object, the key-value pairs from value will be added. If it's a primitive type (string, number, boolean), it will be converted to a single-element array before appending. | @@ -56,7 +56,7 @@ Append values to create or extend an array, or add key-value pairs to an object.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Data | `data` | any | The resulting data structure after the append operation. Will be either an array (if input was array or primitive) or an object (if input was object). Examples: [1,2,3], \{'name':'John', 'age':25\}, or ['hello','world']. |
@@ -68,7 +68,7 @@ Assign a value to a specific path in a data structure.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_ASSIGN` | | Data (required) | `data` | any | The input data structure to modify. Can be an array, object, or primitive value. | @@ -83,7 +83,7 @@ Assign a value to a specific path in a data structure.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Data | `data` | any | The resulting data structure after the assign operation. |
@@ -95,7 +95,7 @@ Concatenate multiple arrays or merge multiple objects into a single collection.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CONCAT` | | Data (required) | `data` | array[any] | An array of arrays or objects to be concatenated/merged. For arrays: [[1, 2], [3, 4]] becomes [1, 2, 3, 4]. For objects: [\{'a': 1\}, \{'b': 2\}] becomes \{'a': 1, 'b': 2\}. Later values override earlier ones for objects. | @@ -108,7 +108,7 @@ Concatenate multiple arrays or merge multiple objects into a single collection.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Data | `data` | any | The resulting array or object after concat operation. |
@@ -120,7 +120,7 @@ Find elements that exist in the first array or object but not in any of the othe
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DIFFERENCE` | | Data (required) | `data` | array[any] | An array of arrays or objects to find the difference. The first element is compared against all subsequent elements. For example, given arrays [[1, 2, 3], [2, 3, 4], [3, 4, 5]], the result will be [1]. For objects, given [\{'a': 1, 'b': 2\}, \{'b': 2, 'c': 3\}], the result will be \{'a': 1\}. | @@ -133,7 +133,7 @@ Find elements that exist in the first array or object but not in any of the othe
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Data | `data` | any | The resulting array or object after the difference operation. |
@@ -145,7 +145,7 @@ Find common elements that exist in all input arrays or objects.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_INTERSECTION` | | Data (required) | `data` | array[any] | An array of arrays or objects to find common elements. For arrays: given [[1, 2, 3], [2, 3, 4]], the result will be [2, 3]. For objects: given [\{'a': 1, 'b': 2\}, \{'b': 2, 'c': 3\}], the result will be \{'b': 2\}. | @@ -158,7 +158,7 @@ Find common elements that exist in all input arrays or objects.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Data | `data` | any | The resulting array or object after the intersection operation. |
@@ -170,7 +170,7 @@ Split arrays or objects into smaller chunks.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SPLIT` | | Data (required) | `data` | any | The source data to be split. Can be: 1) An array to split into groups 2) An object to split by property count (keys are sorted alphabetically for consistent ordering) | @@ -184,7 +184,7 @@ Split arrays or objects into smaller chunks.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Data | `data` | array[any] | The resulting array after splitting. For arrays: array of subarrays. For objects: array of smaller objects with alphabetically ordered keys |
@@ -196,7 +196,7 @@ Find elements that exist in exactly one of the input arrays or objects, but not
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SYMMETRIC_DIFFERENCE` | | Data (required) | `data` | array[any] | An array of arrays or objects to find symmetric difference. For arrays: given [[1, 2], [2, 3]], the result will be [1, 3]. For objects: given [\{'a': 1, 'b': 2\}, \{'b': 2, 'c': 3\}], the result will be \{'a': 1, 'c': 3\}. | @@ -209,7 +209,7 @@ Find elements that exist in exactly one of the input arrays or objects, but not
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Data | `data` | any | The resulting array or object after the symmetric difference operation. |
@@ -221,7 +221,7 @@ Find unique elements that exist in any of the input arrays or objects.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UNION` | | Data (required) | `data` | array[any] | An array of arrays or objects to find unique elements. For arrays: given [[1, 2], [2, 3]], the result will be [1, 2, 3]. For objects: given [\{'a': 1, 'b': 2\}, \{'b': 2, 'c': 3\}], the result will be \{'a': 1, 'b': 2, 'c': 3\}. | @@ -234,7 +234,7 @@ Find unique elements that exist in any of the input arrays or objects.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Data | `data` | any | The resulting array or object after the union operation. |
diff --git a/pkg/component/generic/collection/v0/config/tasks.yaml b/pkg/component/generic/collection/v0/config/tasks.yaml index 958468f9b..ffa4501c8 100644 --- a/pkg/component/generic/collection/v0/config/tasks.yaml +++ b/pkg/component/generic/collection/v0/config/tasks.yaml @@ -7,24 +7,20 @@ TASK_APPEND: data: description: The input data. If it's an array, the value will be appended. If it's an object, the key-value pairs from value will be added. If it's a primitive type (string, number, boolean), it will be converted to a single-element array before appending. - acceptFormats: - - '*' + type: '*' uiOrder: 0 title: Data - format: '*' value: description: 'The value to append. For arrays: the value will be appended as a new element. For objects: if value is an object, its key-value pairs will be added to the input object. For primitives: value will be appended to create/extend an array.' - acceptFormats: - - '*' + type: '*' uiOrder: 1 title: Value - format: '*' required: - data - value title: Input - format: object + type: object output: description: Output containing the modified data structure. uiOrder: 0 @@ -35,11 +31,11 @@ TASK_APPEND: uiOrder: 0 required: [] title: Data - format: '*' + type: '*' required: - data title: Output - format: object + type: object TASK_ASSIGN: shortDescription: Assign a value to a specific path in a data structure. input: @@ -48,32 +44,26 @@ TASK_ASSIGN: properties: data: description: The input data structure to modify. Can be an array, object, or primitive value. - acceptFormats: - - '*' + type: '*' uiOrder: 0 title: Data - format: '*' path: description: 'The path where to assign the value. Use dot notation for nested objects and [n] for array indices. Examples: ''users.[0].name'', ''.[0].key'', ''metadata.tags.[2]''.' - acceptFormats: - - string + type: string uiOrder: 1 title: Path - format: string value: description: The value to assign at the specified path. Can be any type (string, number, boolean, array, or object). - acceptFormats: - - '*' + type: '*' uiOrder: 2 title: Value - format: '*' required: - data - path - value title: Input - format: object + type: object output: description: Output containing the modified data structure. uiOrder: 0 @@ -82,11 +72,11 @@ TASK_ASSIGN: description: The resulting data structure after the assign operation. uiOrder: 0 title: Data - format: '*' + type: '*' required: - data title: Output - format: object + type: object TASK_CONCAT: shortDescription: Concatenate multiple arrays or merge multiple objects into a single collection. input: @@ -96,17 +86,15 @@ TASK_CONCAT: data: description: 'An array of arrays or objects to be concatenated/merged. For arrays: [[1, 2], [3, 4]] becomes [1, 2, 3, 4]. For objects: [{''a'': 1}, {''b'': 2}] becomes {''a'': 1, ''b'': 2}. Later values override earlier ones for objects.' - acceptFormats: - - array + type: array uiOrder: 0 items: - format: '*' + type: '*' title: Data - format: array required: - data title: Input - format: object + type: object output: description: Output containing the concatenated/merged result. uiOrder: 0 @@ -115,11 +103,11 @@ TASK_CONCAT: description: The resulting array or object after concat operation. uiOrder: 0 title: Data - format: '*' + type: '*' required: - data title: Output - format: object + type: object TASK_DIFFERENCE: shortDescription: Find elements that exist in the first array or object but not in any of the other arrays or objects. input: @@ -129,18 +117,16 @@ TASK_DIFFERENCE: description: 'An array of arrays or objects to find the difference. The first element is compared against all subsequent elements. For example, given arrays [[1, 2, 3], [2, 3, 4], [3, 4, 5]], the result will be [1]. For objects, given [{''a'': 1, ''b'': 2}, {''b'': 2, ''c'': 3}], the result will be {''a'': 1}.' - acceptFormats: - - array + type: array uiOrder: 0 items: - format: '*' + type: '*' required: [] title: Data - format: array required: - data title: Input - format: object + type: object output: description: Output containing the difference result. uiOrder: 0 @@ -149,11 +135,11 @@ TASK_DIFFERENCE: description: The resulting array or object after the difference operation. uiOrder: 0 title: Data - format: '*' + type: '*' required: - data title: Output - format: object + type: object TASK_INTERSECTION: shortDescription: Find common elements that exist in all input arrays or objects. input: @@ -163,17 +149,15 @@ TASK_INTERSECTION: data: description: 'An array of arrays or objects to find common elements. For arrays: given [[1, 2, 3], [2, 3, 4]], the result will be [2, 3]. For objects: given [{''a'': 1, ''b'': 2}, {''b'': 2, ''c'': 3}], the result will be {''b'': 2}.' - acceptFormats: - - array + type: array uiOrder: 0 items: - format: '*' + type: '*' title: Data - format: array required: - data title: Input - format: object + type: object output: description: Output containing the intersection result. uiOrder: 0 @@ -182,11 +166,11 @@ TASK_INTERSECTION: description: The resulting array or object after the intersection operation. uiOrder: 0 title: Data - format: '*' + type: '*' required: - data title: Output - format: object + type: object TASK_SPLIT: shortDescription: Split arrays or objects into smaller chunks. input: @@ -196,23 +180,19 @@ TASK_SPLIT: data: description: 'The source data to be split. Can be: 1) An array to split into groups 2) An object to split by property count (keys are sorted alphabetically for consistent ordering)' - acceptFormats: - - '*' + type: '*' uiOrder: 0 title: Data - format: '*' size: description: Number of elements per group uiOrder: 1 - acceptFormats: - - integer + type: integer title: Size - format: integer required: - data - size title: Input - format: object + type: object output: description: Output containing the split results. For objects, the properties in each chunk maintain alphabetical ordering of keys. uiOrder: 1 @@ -222,13 +202,13 @@ TASK_SPLIT: keys' uiOrder: 0 items: - format: '*' + type: '*' title: Data - format: array + type: array required: - data title: Output - format: object + type: object TASK_SYMMETRIC_DIFFERENCE: shortDescription: Find elements that exist in exactly one of the input arrays or objects, but not in multiple inputs. input: @@ -238,17 +218,15 @@ TASK_SYMMETRIC_DIFFERENCE: data: description: 'An array of arrays or objects to find symmetric difference. For arrays: given [[1, 2], [2, 3]], the result will be [1, 3]. For objects: given [{''a'': 1, ''b'': 2}, {''b'': 2, ''c'': 3}], the result will be {''a'': 1, ''c'': 3}.' - acceptFormats: - - array + type: array uiOrder: 0 items: - format: '*' + type: '*' title: Data - format: array required: - data title: Input - format: object + type: object output: description: Output containing the symmetric difference result. uiOrder: 0 @@ -257,11 +235,11 @@ TASK_SYMMETRIC_DIFFERENCE: description: The resulting array or object after the symmetric difference operation. uiOrder: 0 title: Data - format: '*' + type: '*' required: - data title: Output - format: object + type: object TASK_UNION: shortDescription: Find unique elements that exist in any of the input arrays or objects. input: @@ -271,17 +249,15 @@ TASK_UNION: data: description: 'An array of arrays or objects to find unique elements. For arrays: given [[1, 2], [2, 3]], the result will be [1, 2, 3]. For objects: given [{''a'': 1, ''b'': 2}, {''b'': 2, ''c'': 3}], the result will be {''a'': 1, ''b'': 2, ''c'': 3}.' - acceptFormats: - - array + type: array uiOrder: 0 items: - format: '*' + type: '*' title: Data - format: array required: - data title: Input - format: object + type: object output: description: Output containing the union result. uiOrder: 0 @@ -290,8 +266,8 @@ TASK_UNION: description: The resulting array or object after the union operation. uiOrder: 0 title: Data - format: '*' + type: '*' required: - data title: Output - format: object + type: object diff --git a/pkg/component/generic/http/v0/README.mdx b/pkg/component/generic/http/v0/README.mdx index 4e8126f45..67b69cdb3 100644 --- a/pkg/component/generic/http/v0/README.mdx +++ b/pkg/component/generic/http/v0/README.mdx @@ -43,7 +43,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Authentication](#authentication) (required) | `authentication` | object | Authentication method to use for the REST API. | @@ -61,7 +61,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Auth Type | `auth-type` | string | Must be `"NO_AUTH"` |
@@ -70,7 +70,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Auth Type | `auth-type` | string | Must be `"BASIC_AUTH"` | | Password | `password` | string | Password for Basic auth. | @@ -81,7 +81,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Auth Location | `auth-location` | string | Add the API key to the header or query params.
Enum values
  • `header`
  • `query`
| | Auth Type | `auth-type` | string | Must be `"API_KEY"` | @@ -93,7 +93,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Auth Type | `auth-type` | string | Must be `"BEARER_TOKEN"` | | Token | `token` | string | Bearer token. | @@ -109,7 +109,7 @@ Send a HTTP GET request.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_GET` | | Endpoint URL (required) | `endpoint-url` | string | The API endpoint url. | @@ -123,7 +123,7 @@ Send a HTTP GET request.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status Code | `status-code` | integer | The HTTP status code of the response. | | Body | `body` | any | The body of the response. | @@ -137,7 +137,7 @@ Send a HTTP POST request.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_POST` | | Endpoint URL (required) | `endpoint-url` | string | The API endpoint url. | @@ -152,7 +152,7 @@ Send a HTTP POST request.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status Code | `status-code` | integer | The HTTP status code of the response. | | Body | `body` | any | The body of the response. | @@ -166,7 +166,7 @@ Send a HTTP PATCH request.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_PATCH` | | Endpoint URL (required) | `endpoint-url` | string | The API endpoint url. | @@ -181,7 +181,7 @@ Send a HTTP PATCH request.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status Code | `status-code` | integer | The HTTP status code of the response. | | Body | `body` | any | The body of the response. | @@ -195,7 +195,7 @@ Send a HTTP PUT request.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_PUT` | | Endpoint URL (required) | `endpoint-url` | string | The API endpoint url. | @@ -210,7 +210,7 @@ Send a HTTP PUT request.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status Code | `status-code` | integer | The HTTP status code of the response. | | Body | `body` | any | The body of the response. | @@ -224,7 +224,7 @@ Send a HTTP DELETE request.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DELETE` | | Endpoint URL (required) | `endpoint-url` | string | The API endpoint url. | @@ -239,7 +239,7 @@ Send a HTTP DELETE request.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status Code | `status-code` | integer | The HTTP status code of the response. | | Body | `body` | any | The body of the response. | @@ -253,7 +253,7 @@ Send a HTTP HEAD request.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_HEAD` | | Endpoint URL (required) | `endpoint-url` | string | The API endpoint url. | @@ -267,7 +267,7 @@ Send a HTTP HEAD request.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status Code | `status-code` | integer | The HTTP status code of the response. | | Body | `body` | any | The body of the response. | @@ -281,7 +281,7 @@ Send a HTTP OPTIONS request.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_OPTIONS` | | Endpoint URL (required) | `endpoint-url` | string | The API endpoint url. | @@ -296,7 +296,7 @@ Send a HTTP OPTIONS request.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Status Code | `status-code` | integer | The HTTP status code of the response. | | Body | `body` | any | The body of the response. | diff --git a/pkg/component/generic/http/v0/config/setup.yaml b/pkg/component/generic/http/v0/config/setup.yaml index 534713e3f..b2fa2f956 100644 --- a/pkg/component/generic/http/v0/config/setup.yaml +++ b/pkg/component/generic/http/v0/config/setup.yaml @@ -11,7 +11,7 @@ properties: uiOrder: 0 order: 0 title: Auth Type - format: string + type: string required: - auth-type title: No Auth @@ -22,24 +22,20 @@ properties: uiOrder: 0 order: 0 title: Auth Type - format: string + type: string password: description: Password for Basic auth. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 2 order: 2 title: Password - format: string username: description: Username for Basic Auth. - acceptFormats: - - string + type: string uiOrder: 1 order: 1 title: Username - format: string required: - auth-type - username @@ -52,37 +48,31 @@ properties: enum: - header - query - acceptFormats: - - string + type: string uiOrder: 3 order: 3 title: Auth Location - format: string auth-type: const: API_KEY description: API key authentication. uiOrder: 0 order: 0 title: Auth Type - format: string + type: string key: default: X-API-Key description: Key name for API key authentication. - acceptFormats: - - string + type: string uiOrder: 1 order: 1 title: Key Name - format: string value: description: Key value for API key authentication. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 2 order: 2 title: Key Value - format: string required: - auth-type - key @@ -96,24 +86,22 @@ properties: uiOrder: 0 order: 0 title: Auth Type - format: string + type: string token: description: Bearer token. - acceptFormats: - - string + type: string instillSecret: true uiOrder: 1 order: 1 title: Token - format: string required: - auth-type - token title: Bearer Token order: 1 title: Authentication - format: object + type: object required: - authentication title: REST API Connection -format: object +type: object diff --git a/pkg/component/generic/http/v0/config/tasks.yaml b/pkg/component/generic/http/v0/config/tasks.yaml index d75e37040..769d5795a 100644 --- a/pkg/component/generic/http/v0/config/tasks.yaml +++ b/pkg/component/generic/http/v0/config/tasks.yaml @@ -4,8 +4,7 @@ $defs: properties: body: description: The request body. - acceptFormats: - - '*' + type: '*' shortDescription: The request body uiOrder: 1 order: 1 @@ -13,49 +12,41 @@ $defs: title: Body endpoint-url: description: The API endpoint url. - acceptFormats: - - string + type: string uiOrder: 0 title: Endpoint Url - format: string output-body-schema: description: The JSON schema of output body. - acceptFormats: - - string + type: string shortDescription: The JSON schema of output body uiOrder: 1 order: 2 required: [] title: Body - format: string required: - endpoint-url title: Input - format: object + type: object inputWithoutBody: uiOrder: 0 properties: endpoint-url: description: The API endpoint url. - acceptFormats: - - string + type: string uiOrder: 0 title: Endpoint Url - format: string output-body-schema: description: The request body. - acceptFormats: - - string + type: string shortDescription: The request body uiOrder: 1 order: 1 required: [] title: Body - format: string required: - endpoint-url title: Input Without Body - format: object + type: object output: description: The HTTP response from the API. uiOrder: 0 @@ -65,24 +56,24 @@ $defs: uiOrder: 1 required: [] title: Body - format: '*' + type: '*' header: description: The HTTP header of the response. uiOrder: 2 required: [] title: Header - format: json + type: json status-code: description: The HTTP status code of the response. uiOrder: 0 title: Status Code - format: integer + type: integer required: - status-code - body - header title: Output - format: object + type: object TASK_DELETE: shortDescription: Send a HTTP DELETE request. input: diff --git a/pkg/component/generic/scheduler/v0/config/events.yaml b/pkg/component/generic/scheduler/v0/config/events.yaml index e93e0b33a..e919f96e0 100644 --- a/pkg/component/generic/scheduler/v0/config/events.yaml +++ b/pkg/component/generic/scheduler/v0/config/events.yaml @@ -7,8 +7,8 @@ EVENT_CRON_JOB_TRIGGERED: properties: cron: pattern: ^[0-9*,-/]+\s+[0-9*,-/]+\s+[0-9*,-/]+\s+[0-9*,-/]+\s+[0-9*,-/]+$ - format: string - format: object + type: string + type: object messageSchema: $schema: http://json-schema.org/draft-07/schema required: @@ -16,9 +16,9 @@ EVENT_CRON_JOB_TRIGGERED: properties: triggered-at: description: The ISO 8601 timestamp when the cron job was triggered - format: string + type: string additionalProperties: false title: Cron job triggered event - format: object + type: object messageExamples: - triggered-at: '2024-01-01T00:00:00.000Z' diff --git a/pkg/component/operator/audio/v0/.compogen/bottom.mdx b/pkg/component/operator/audio/v0/.compogen/bottom.mdx index 88e8947e5..e107ef9bf 100644 --- a/pkg/component/operator/audio/v0/.compogen/bottom.mdx +++ b/pkg/component/operator/audio/v0/.compogen/bottom.mdx @@ -22,7 +22,7 @@ variable: audio: title: Audio to test description: Audio to test VAD and extraction - format: audio + type: audio output: samples: title: Output audio segments diff --git a/pkg/component/operator/audio/v0/README.mdx b/pkg/component/operator/audio/v0/README.mdx index 77c1b5a54..e80337932 100644 --- a/pkg/component/operator/audio/v0/README.mdx +++ b/pkg/component/operator/audio/v0/README.mdx @@ -36,7 +36,7 @@ Detect speech segments in audio data using Voice Activity Detection (VAD). This
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DETECT_ACTIVITY` | | Audio (required) | `audio` | string | Audio file to analyze for speech activity. | @@ -51,7 +51,7 @@ Detect speech segments in audio data using Voice Activity Detection (VAD). This
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Segments](#detect-activity-segments) | `segments` | array[object] | Array of time segments representing detected speech activity. Each segment contains start and end times in seconds. |
@@ -63,7 +63,7 @@ Detect speech segments in audio data using Voice Activity Detection (VAD). This
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | End Time | `end-time` | number | The number of seconds from the beginning of the audio file to the end of this segment. | | Start Time | `start-time` | number | The number of seconds from the beginning of the audio file to the start of this segment. | @@ -77,7 +77,7 @@ Segment audio data into pieces based on the provided time segments.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEGMENT` | | Audio (required) | `audio` | string | Audio data to segment. | @@ -94,7 +94,7 @@ A list of time segments of audio data.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | End Time | `end-time` | number | The number of seconds from the beginning of the audio file to the end of this segment. | | Start Time | `start-time` | number | The number of seconds from the beginning of the audio file to the start of this segment. | @@ -105,7 +105,7 @@ A list of time segments of audio data.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Audios | `audio-segments` | array[string] | A list of segmented audio data. |
@@ -136,7 +136,7 @@ variable: audio: title: Audio to test description: Audio to test VAD and extraction - format: audio + type: audio output: samples: title: Output audio segments diff --git a/pkg/component/operator/audio/v0/config/tasks.yaml b/pkg/component/operator/audio/v0/config/tasks.yaml index e7c1154ab..eea46e33a 100644 --- a/pkg/component/operator/audio/v0/config/tasks.yaml +++ b/pkg/component/operator/audio/v0/config/tasks.yaml @@ -5,18 +5,18 @@ $defs: title: Start Time description: The number of seconds from the beginning of the audio file to the start of this segment. uiOrder: 0 - format: number + type: number end-time: title: End Time description: The number of seconds from the beginning of the audio file to the end of this segment. uiOrder: 1 - format: number + type: number required: - start-time - end-time title: Segment description: A time segment of audio data, defined by its start and end times in seconds. - format: object + type: object TASK_DETECT_ACTIVITY: shortDescription: Detect speech segments in audio data using Voice Activity Detection (VAD). This task processes the input audio to 16kHz mono format, identifies periods of human speech, and outputs time segments for each detected speech activity. @@ -26,36 +26,27 @@ TASK_DETECT_ACTIVITY: properties: audio: description: Audio file to analyze for speech activity. - acceptFormats: - - audio/wav - - application/octet-stream + type: string uiOrder: 0 title: Audio - format: string min-silence-duration: description: Minimum duration of silence (in milliseconds) required to split speech segments. Longer values result in fewer, longer segments. - acceptFormats: - - integer - - number + type: integer uiOrder: 1 minimum: 0 title: Minimum Silence Duration default: 100 - format: integer speech-pad: description: Additional padding (in milliseconds) added to the start and end of each detected speech segment to prevent cutting off speech. - acceptFormats: - - integer - - number + type: integer uiOrder: 2 minimum: 0 title: Speech Pad default: 30 - format: integer required: - audio title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -66,11 +57,11 @@ TASK_DETECT_ACTIVITY: items: $ref: '#/$defs/segment' title: Segments - format: array + type: array required: - segments title: Output - format: object + type: object TASK_SEGMENT: shortDescription: Segment audio data into pieces based on the provided time segments. input: @@ -79,24 +70,21 @@ TASK_SEGMENT: properties: audio: description: Audio data to segment. - acceptFormats: - - audio/* - - application/octet-stream + type: string uiOrder: 0 title: Audio - format: string segments: description: A list of time segments of audio data. uiOrder: 1 items: $ref: '#/$defs/segment' title: Segments - format: array + type: array required: - audio - segments title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -105,10 +93,10 @@ TASK_SEGMENT: description: A list of segmented audio data. uiOrder: 0 items: - format: string + type: string title: Audios - format: array + type: array required: - audio-segments title: Output - format: object + type: object diff --git a/pkg/component/operator/base64/v0/README.mdx b/pkg/component/operator/base64/v0/README.mdx index 5f1b3725b..6cf97708f 100644 --- a/pkg/component/operator/base64/v0/README.mdx +++ b/pkg/component/operator/base64/v0/README.mdx @@ -36,7 +36,7 @@ Encode data into base64 string
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_ENCODE` | | Data (required) | `data` | string | Data to be encoded. | @@ -49,7 +49,7 @@ Encode data into base64 string
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Data | `data` | string | Data. |
@@ -61,7 +61,7 @@ Decode the base64 string.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DECODE` | | Data (required) | `data` | string | Base64 string to be decoded. | @@ -74,7 +74,7 @@ Decode the base64 string.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Data | `data` | string | Data. |
diff --git a/pkg/component/operator/base64/v0/config/tasks.yaml b/pkg/component/operator/base64/v0/config/tasks.yaml index eec356396..17156cef9 100644 --- a/pkg/component/operator/base64/v0/config/tasks.yaml +++ b/pkg/component/operator/base64/v0/config/tasks.yaml @@ -6,15 +6,13 @@ TASK_DECODE: properties: data: description: Base64 string to be decoded. - acceptFormats: - - string + type: string uiOrder: 0 title: Data - format: string required: - data title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -23,11 +21,11 @@ TASK_DECODE: description: Data. uiOrder: 0 title: Data - format: string + type: string required: - data title: Output - format: object + type: object TASK_ENCODE: shortDescription: Encode data into base64 string input: @@ -36,15 +34,13 @@ TASK_ENCODE: properties: data: description: Data to be encoded. - acceptFormats: - - string + type: string uiOrder: 0 title: Data - format: string required: - data title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -53,8 +49,8 @@ TASK_ENCODE: description: Data. uiOrder: 0 title: Data - format: string + type: string required: - data title: Output - format: object + type: object diff --git a/pkg/component/operator/document/v0/.compogen/bottom.mdx b/pkg/component/operator/document/v0/.compogen/bottom.mdx index 2aa41aae1..ac8b55dd9 100644 --- a/pkg/component/operator/document/v0/.compogen/bottom.mdx +++ b/pkg/component/operator/document/v0/.compogen/bottom.mdx @@ -46,10 +46,10 @@ component: variable: contract_pdf_file: title: Contract PDF file - format: "*/*" + type: "*/*" question: title: Question - format: string + type: string output: contract_question_answering: diff --git a/pkg/component/operator/document/v0/README.mdx b/pkg/component/operator/document/v0/README.mdx index 5d6c1249b..6f3fe2794 100644 --- a/pkg/component/operator/document/v0/README.mdx +++ b/pkg/component/operator/document/v0/README.mdx @@ -37,7 +37,7 @@ Convert document to text in Markdown format.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CONVERT_TO_MARKDOWN` | | Document (required) | `document` | string | Base64 encoded PDF/DOCX/DOC/PPTX/PPT/HTML/XLSX/XLS/CSV to be converted to text in Markdown format. | @@ -54,7 +54,7 @@ Convert document to text in Markdown format.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Body | `body` | string | Markdown text converted from the PDF document. | | Filename (optional) | `filename` | string | The name of the file. | @@ -71,7 +71,7 @@ Convert document to text.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CONVERT_TO_TEXT` | | Document (required) | `document` | string | Base64 encoded PDF/DOC/DOCX/XML/HTML/RTF/MD/PPTX/ODT/TIF/CSV/TXT/PNG document to be converted to plain text. | @@ -85,7 +85,7 @@ Convert document to text.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Body | `body` | string | Plain text converted from the document. | | Filename (optional) | `filename` | string | The name of the file. | @@ -101,7 +101,7 @@ Convert Document to images.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CONVERT_TO_IMAGES` | | PDF (required) | `document` | string | Base64 encoded PDF/DOCX/DOC/PPT/PPTX to be converted to images. | @@ -116,7 +116,7 @@ Convert Document to images.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Images | `images` | array[string] | Images converted from the document. | | Filenames (optional) | `filenames` | array[string] | The filenames of the images. The filenames will be appended with the page number. e.g. 'example-1.jpg'. | @@ -172,10 +172,10 @@ component: variable: contract_pdf_file: title: Contract PDF file - format: "*/*" + type: "*/*" question: title: Question - format: string + type: string output: contract_question_answering: diff --git a/pkg/component/operator/document/v0/config/tasks.yaml b/pkg/component/operator/document/v0/config/tasks.yaml index 2756b7749..cae8384c8 100644 --- a/pkg/component/operator/document/v0/config/tasks.yaml +++ b/pkg/component/operator/document/v0/config/tasks.yaml @@ -4,7 +4,7 @@ $defs: title: Resolution minimum: 72 default: 300 - format: number + type: number TASK_CONVERT_TO_MARKDOWN: shortDescription: Convert document to text in Markdown format. input: @@ -13,38 +13,34 @@ TASK_CONVERT_TO_MARKDOWN: properties: document: description: Base64 encoded PDF/DOCX/DOC/PPTX/PPT/HTML/XLSX/XLS/CSV to be converted to text in Markdown format. - acceptFormats: - - '*/*' + type: string uiOrder: 0 title: Document - format: string filename: description: The name of the file, please remember to add the file extension in the end of file name. e.g. 'example.pdf'. - acceptFormats: - - string + type: string uiOrder: 1 title: Filename - format: string display-image-tag: default: false description: Whether to display image tag in the markdown text. Default is 'false'. It is only applicable for convert-2024-08-28 converter. And, it is only applicable for the type of PPTX/PPT/DOCX/DOC/PDF. uiOrder: 2 title: Display Image Tag - format: boolean + type: boolean display-all-page-image: default: false description: Whether to respond the whole page as the images if we detect there could be images in the page. It will only support DOCX/DOC/PPTX/PPT/PDF. uiOrder: 3 title: Display All Page Image - format: boolean + type: boolean resolution: $ref: '#/$defs/resolution' uiOrder: 4 required: - document title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -53,42 +49,42 @@ TASK_CONVERT_TO_MARKDOWN: description: Markdown text converted from the PDF document. uiOrder: 0 title: Body - format: string + type: string filename: description: The name of the file. uiOrder: 1 title: Filename - format: string + type: string images: description: Images extracted from the document. uiOrder: 2 items: - format: string + type: string title: Images - format: array + type: array error: description: Error message if any during the conversion process. uiOrder: 3 title: Error - format: string + type: string all-page-images: description: The image contains all the pages in the document if we detect there could be images in the page. It will only support DOCX/DOC/PPTX/PPT/PDF. uiOrder: 4 items: - format: string + type: string title: All Page Images - format: array + type: array markdowns: description: Markdown text converted from the PDF document, separated by page. uiOrder: 5 items: - format: string + type: string title: Markdowns - format: array + type: array required: - body title: Output - format: object + type: object TASK_CONVERT_TO_TEXT: shortDescription: Convert document to text. input: @@ -97,22 +93,18 @@ TASK_CONVERT_TO_TEXT: properties: document: description: Base64 encoded PDF/DOC/DOCX/XML/HTML/RTF/MD/PPTX/ODT/TIF/CSV/TXT/PNG document to be converted to plain text. - acceptFormats: - - '*/*' + type: string uiOrder: 0 title: Document - format: string filename: description: The name of the file, please remember to add the file extension in the end of file name. e.g. 'example.pdf'. - acceptFormats: - - string + type: string uiOrder: 1 title: Filename - format: string required: - document title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -121,35 +113,35 @@ TASK_CONVERT_TO_TEXT: description: Plain text converted from the document. uiOrder: 0 title: Body - format: string + type: string error: description: Error message if any during the conversion process. uiOrder: 3 title: Error - format: string + type: string meta: description: Metadata extracted from the document. uiOrder: 1 required: [] title: Meta - format: json + type: json msecs: description: Time taken to convert the document. uiOrder: 2 title: Milliseconds - format: number + type: number filename: description: The name of the file. uiOrder: 1 title: Filename - format: string + type: string required: - body - meta - msecs - error title: Output - format: object + type: object TASK_CONVERT_TO_IMAGES: shortDescription: Convert Document to images. input: @@ -158,25 +150,21 @@ TASK_CONVERT_TO_IMAGES: properties: document: description: Base64 encoded PDF/DOCX/DOC/PPT/PPTX to be converted to images. - acceptFormats: - - '*/*' + type: string uiOrder: 0 title: PDF - format: string filename: description: The name of the file, please remember to add the file extension in the end of file name. e.g. 'example.pdf'. - acceptFormats: - - string + type: string uiOrder: 1 title: Filename - format: string resolution: $ref: '#/$defs/resolution' uiOrder: 4 required: - document title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -185,17 +173,17 @@ TASK_CONVERT_TO_IMAGES: description: Images converted from the document. uiOrder: 0 items: - format: string + type: string title: Images - format: array + type: array filenames: description: The filenames of the images. The filenames will be appended with the page number. e.g. 'example-1.jpg'. uiOrder: 1 items: - format: string + type: string title: Filenames - format: array + type: array required: - images title: Output - format: object + type: object diff --git a/pkg/component/operator/image/v0/README.mdx b/pkg/component/operator/image/v0/README.mdx index 3d836e427..62755361e 100644 --- a/pkg/component/operator/image/v0/README.mdx +++ b/pkg/component/operator/image/v0/README.mdx @@ -43,7 +43,7 @@ Concatenate images horizontally or vertically. All images must have the same wid
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CONCAT` | | Images (required) | `images` | array | Input images. | @@ -59,7 +59,7 @@ Concatenate images horizontally or vertically. All images must have the same wid
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Image | `image` | image/png | Output image. |
@@ -71,7 +71,7 @@ Crop image to the specified size.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CROP` | | Image (required) | `image` | string | Input image. | @@ -90,7 +90,7 @@ Crop image to the specified size.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Image | `image` | image/png | Output image. |
@@ -102,7 +102,7 @@ Resize image to the specified size.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_RESIZE` | | Image (required) | `image` | string | Input image. | @@ -118,7 +118,7 @@ Resize image to the specified size.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Image | `image` | image/png | Output image. |
@@ -130,7 +130,7 @@ Draw classification result on the image.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DRAW_CLASSIFICATION` | | Category (required) | `category` | string | The predicted category of the input. | @@ -146,7 +146,7 @@ Draw classification result on the image.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Image | `image` | image/png | Output image. |
@@ -158,7 +158,7 @@ Draw detection result on the image.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DRAW_DETECTION` | | Image (required) | `image` | string | Input image. | @@ -176,7 +176,7 @@ A list of detected objects.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Bounding box](#draw-detection-bounding-box) | `bounding-box` | object | The detected bounding box in (left, top, width, height) format. | | Category | `category` | string | The predicted category of the bounding box. | @@ -188,7 +188,7 @@ The detected bounding box in (left, top, width, height) format.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Height | `height` | number | Bounding box height value | | Left | `left` | number | Bounding box left x-axis value | @@ -201,7 +201,7 @@ The detected bounding box in (left, top, width, height) format.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Image | `image` | image/png | Output image. |
@@ -213,7 +213,7 @@ Draw keypoint result on the image.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DRAW_KEYPOINT` | | Image (required) | `image` | string | Input image. | @@ -231,7 +231,7 @@ A list of keypoint objects, a keypoint object includes all the pre-defined keypo
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Bounding Box](#draw-keypoint-bounding-box) | `bounding-box` | object | The detected bounding box in (left, top, width, height) format. | | [Keypoints](#draw-keypoint-keypoints) | `keypoints` | array | A keypoint group is composed of a list of pre-defined keypoints of a detected object. | @@ -243,7 +243,7 @@ A keypoint group is composed of a list of pre-defined keypoints of a detected ob
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Visibility Score | `v` | number | visibility score of the keypoint. | | X Coordinate | `x` | number | x coordinate of the keypoint. | @@ -255,7 +255,7 @@ The detected bounding box in (left, top, width, height) format.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Height | `height` | number | Bounding box height value | | Left | `left` | number | Bounding box left x-axis value | @@ -268,7 +268,7 @@ The detected bounding box in (left, top, width, height) format.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Image | `image` | image/png | Output image. |
@@ -280,7 +280,7 @@ Draw OCR result on the image.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DRAW_OCR` | | Image (required) | `image` | string | Input image. | @@ -298,7 +298,7 @@ A list of detected bounding boxes.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Bounding Box](#draw-ocr-bounding-box) | `bounding-box` | object | The detected bounding box in (left, top, width, height) format. | | Score | `score` | number | The confidence score of the predicted object. | @@ -310,7 +310,7 @@ The detected bounding box in (left, top, width, height) format.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Height | `height` | number | Bounding box height value | | Left | `left` | number | Bounding box left x-axis value | @@ -323,7 +323,7 @@ The detected bounding box in (left, top, width, height) format.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Image | `image` | image/png | Output image. |
@@ -335,7 +335,7 @@ Draw instance segmentation result on the image.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DRAW_INSTANCE_SEGMENTATION` | | Image (required) | `image` | string | Input image. | @@ -353,7 +353,7 @@ A list of detected instance bounding boxes.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Bounding Box](#draw-instance-segmentation-bounding-box) | `bounding-box` | object | The detected bounding box in (left, top, width, height) format. | | Category | `category` | string | The predicted category of the bounding box. | @@ -366,7 +366,7 @@ The detected bounding box in (left, top, width, height) format.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Height | `height` | number | Bounding box height value | | Left | `left` | number | Bounding box left x-axis value | @@ -379,7 +379,7 @@ The detected bounding box in (left, top, width, height) format.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Image | `image` | image/png | Output image. |
@@ -391,7 +391,7 @@ Draw semantic segmentation result on the image.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DRAW_SEMANTIC_SEGMENTATION` | | Image (required) | `image` | string | Input image. | @@ -408,7 +408,7 @@ A list of RLE binary masks.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Category | `category` | string | Category text string corresponding to each stuff mask. | | RLE | `rle` | string | Run Length Encoding (RLE) of each stuff mask within the image. | @@ -419,7 +419,7 @@ A list of RLE binary masks.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Image | `image` | image/png | Output image. |
diff --git a/pkg/component/operator/image/v0/config/schema.yaml b/pkg/component/operator/image/v0/config/schema.yaml index aed45096a..07e35c062 100644 --- a/pkg/component/operator/image/v0/config/schema.yaml +++ b/pkg/component/operator/image/v0/config/schema.yaml @@ -8,29 +8,29 @@ $defs: description: Bounding box height value uiOrder: 3 title: Height - format: number + type: number left: description: Bounding box left x-axis value uiOrder: 0 title: Left - format: number + type: number top: description: Bounding box top y-axis value uiOrder: 1 title: Top - format: number + type: number width: description: Bounding box width value uiOrder: 2 title: Width - format: number + type: number required: - left - top - width - height title: Bounding Box - format: object + type: object chat-messages: items: properties: @@ -45,18 +45,18 @@ $defs: uiOrder: 2 required: [] title: Metadata - format: json + type: json role: description: The message role, i.e. 'system', 'user' or 'assistant' uiOrder: 0 title: Role - format: string + type: string required: - role - content - format: object + type: object title: Chat Message - format: array + type: array classification: additionalProperties: false properties: @@ -64,16 +64,16 @@ $defs: description: The predicted category of the input. uiOrder: 0 title: Category - format: string + type: string score: description: The confidence score of the predicted category of the input. uiOrder: 1 title: Score - format: number + type: number required: - category - score - format: object + type: object detection: additionalProperties: false properties: @@ -91,29 +91,29 @@ $defs: description: The predicted category of the bounding box. uiOrder: 2 title: Category - format: string + type: string score: description: The confidence score of the predicted category of the bounding box. uiOrder: 3 title: Score - format: number + type: number required: - bounding-box - category - score title: Object - format: object + type: object title: Objects - format: array + type: array required: - objects - format: object + type: object embedding: items: title: Embedding - format: number + type: number title: Embedding - format: array + type: array instance-segmentation: additionalProperties: false properties: @@ -130,29 +130,29 @@ $defs: description: The predicted category of the bounding box. uiOrder: 2 title: Category - format: string + type: string rle: description: Run Length Encoding (RLE) of instance mask within the bounding box. uiOrder: 0 title: RLE - format: string + type: string score: description: The confidence score of the predicted instance object. uiOrder: 3 title: Score - format: number + type: number required: - rle - bounding-box - category - score title: Object - format: object + type: object title: Objects - format: array + type: array required: - objects - format: object + type: object keypoint: additionalProperties: false properties: @@ -175,41 +175,41 @@ $defs: description: visibility score of the keypoint. uiOrder: 2 title: Visibility Score - format: number + type: number x: description: x coordinate of the keypoint. uiOrder: 0 title: X Coordinate - format: number + type: number y: description: y coordinate of the keypoint. uiOrder: 1 title: Y Coordinate - format: number + type: number required: - x - y - v title: Keypoints - format: object + type: object title: Keypoints - format: array + type: array score: description: The confidence score of the predicted object. uiOrder: 1 title: Score - format: number + type: number required: - keypoints - score - bounding-box title: Object - format: object + type: object title: Objects - format: array + type: array required: - objects - format: object + type: object multi-modal-content: items: properties: @@ -219,18 +219,18 @@ $defs: description: Either a URL of the image or the base64 encoded image data. title: URL uiOrder: 0 - format: string + type: string required: - url title: Image URL description: The image URL uiOrder: 0 - format: object + type: object text: description: The text content. title: Text uiOrder: 1 - format: string + type: string type: description: The type of the content part. enum: @@ -238,11 +238,11 @@ $defs: - image-url title: Type uiOrder: 2 - format: string + type: string required: - type - format: object - format: array + type: object + type: array ocr: additionalProperties: false properties: @@ -259,23 +259,23 @@ $defs: description: The confidence score of the predicted object. uiOrder: 2 title: Score - format: number + type: number text: description: Text string recognised per bounding box. uiOrder: 1 title: Text - format: string + type: string required: - bounding-box - text - score title: Object - format: object + type: object title: Objects - format: array + type: array required: - objects - format: object + type: object semantic-segmentation: additionalProperties: false properties: @@ -288,19 +288,19 @@ $defs: description: Category text string corresponding to each stuff mask. uiOrder: 1 title: Category - format: string + type: string rle: description: Run Length Encoding (RLE) of each stuff mask within the image. uiOrder: 0 title: RLE - format: string + type: string required: - rle - category title: Object - format: object + type: object title: Stuffs - format: array + type: array required: - stuffs - format: object + type: object diff --git a/pkg/component/operator/image/v0/config/tasks.yaml b/pkg/component/operator/image/v0/config/tasks.yaml index 9c3ad4099..36db8e9bc 100644 --- a/pkg/component/operator/image/v0/config/tasks.yaml +++ b/pkg/component/operator/image/v0/config/tasks.yaml @@ -7,36 +7,28 @@ TASK_CONCAT: properties: images: description: Input images. - acceptFormats: - - array + type: array uiOrder: 0 title: Images - format: array grid-width: description: Grid width. If `grid-width` is provided, `grid-height` will be ignored. - acceptFormats: - - integer + type: integer uiOrder: 1 title: Grid Width - format: integer grid-height: description: Grid height. If `grid-height` is provided, `grid-width` will be ignored. - acceptFormats: - - integer + type: integer uiOrder: 2 title: Grid Height - format: integer padding: description: Padding between images. If `padding` is provided, it will be applied to all four sides of the image. - acceptFormats: - - integer + type: integer uiOrder: 3 title: Padding - format: integer required: - images title: Input - format: object + type: object output: description: Output concatenated image. uiOrder: 0 @@ -45,11 +37,11 @@ TASK_CONCAT: description: Output image. uiOrder: 0 title: Image - format: image/png + type: image/png required: - image title: Output - format: object + type: object TASK_CROP: shortDescription: Crop image to the specified size. input: @@ -58,59 +50,45 @@ TASK_CROP: properties: image: description: Input image. - acceptFormats: - - image/* + type: string uiOrder: 0 title: Image - format: string corner-radius: description: Radius from the corner of the image to crop the image. If `corner-radius` is provided, `circle-radius` will be ignored. If the `corner-radius` is larger than half of min(width, height), the min(width, height) will be applied to `corner-radius` . - acceptFormats: - - integer + type: integer uiOrder: 1 title: Corner Radius - format: integer circle-radius: description: Radius from the center of the circle to crop the image. If `circle-radius` is provided, `corner-radius` will be ignored. If the `circle-radius` is larger than half of min(width, height), the min(width, height) will be applied to `circle-radius`. - acceptFormats: - - integer + type: integer uiOrder: 2 title: Circle Radius - format: integer top-offset: description: Top offset of the crop. - acceptFormats: - - integer + type: integer uiOrder: 3 title: Top Offset - format: integer right-offset: description: Right offset of the crop. - acceptFormats: - - integer + type: integer uiOrder: 4 title: Right Offset - format: integer bottom-offset: description: Bottom offset of the crop. - acceptFormats: - - integer + type: integer uiOrder: 5 title: Bottom Offset - format: integer left-offset: description: Left offset of the crop. - acceptFormats: - - integer + type: integer uiOrder: 6 title: Left Offset - format: integer required: - image title: Input - format: object + type: object output: description: Output cropped image. uiOrder: 0 @@ -119,11 +97,11 @@ TASK_CROP: description: Output image. uiOrder: 0 title: Image - format: image/png + type: image/png required: - image title: Output - format: object + type: object TASK_RESIZE: shortDescription: Resize image to the specified size. input: @@ -132,36 +110,28 @@ TASK_RESIZE: properties: image: description: Input image. - acceptFormats: - - image/* + type: string uiOrder: 0 title: Image - format: string ratio: description: Resize ratio (e.g., 0.5 for half size, 2 for double size) to resize the image. If ratio is provided, width and height will be ignored. - acceptFormats: - - number + type: number uiOrder: 1 title: Ratio - format: number width: description: Width of the output image. - acceptFormats: - - integer + type: integer uiOrder: 2 title: Width - format: integer height: description: Height of the output image. - acceptFormats: - - integer + type: integer uiOrder: 3 title: Height - format: integer required: - image title: Input - format: object + type: object output: description: Output resized image. uiOrder: 0 @@ -170,11 +140,11 @@ TASK_RESIZE: description: Output image. uiOrder: 0 title: Image - format: image/png + type: image/png required: - image title: Output - format: object + type: object TASK_DRAW_CLASSIFICATION: shortDescription: Draw classification result on the image. input: @@ -183,33 +153,26 @@ TASK_DRAW_CLASSIFICATION: properties: category: $ref: schema.yaml#/$defs/instill-types/classification/properties/category - acceptFormats: - - string + type: string image: description: Input image. - acceptFormats: - - image/* + type: string uiOrder: 0 title: Image - format: string score: $ref: schema.yaml#/$defs/instill-types/classification/properties/score - acceptFormats: - - number - - integer + type: number show-score: description: Show model confidence score on each instance. - acceptFormats: - - boolean + type: boolean uiOrder: 0 title: Show Score - format: boolean required: - image - category - score title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -218,11 +181,11 @@ TASK_DRAW_CLASSIFICATION: description: Output image. uiOrder: 0 title: Image - format: image/png + type: image/png required: - image title: Output - format: object + type: object TASK_DRAW_DETECTION: shortDescription: Draw detection result on the image. input: @@ -231,27 +194,22 @@ TASK_DRAW_DETECTION: properties: image: description: Input image. - acceptFormats: - - image/* + type: string uiOrder: 0 title: Image - format: string objects: $ref: schema.yaml#/$defs/instill-types/detection/properties/objects - acceptFormats: - - array + type: array show-score: description: Show model confidence score on each instance. - acceptFormats: - - boolean + type: boolean uiOrder: 0 title: Show Score - format: boolean required: - image - objects title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -260,11 +218,11 @@ TASK_DRAW_DETECTION: description: Output image. uiOrder: 0 title: Image - format: image/png + type: image/png required: - image title: Output - format: object + type: object TASK_DRAW_KEYPOINT: shortDescription: Draw keypoint result on the image. input: @@ -273,27 +231,22 @@ TASK_DRAW_KEYPOINT: properties: image: description: Input image. - acceptFormats: - - image/* + type: string uiOrder: 0 title: Image - format: string objects: $ref: schema.yaml#/$defs/instill-types/keypoint/properties/objects - acceptFormats: - - array + type: array show-score: description: Show model confidence score on each instance. - acceptFormats: - - boolean + type: boolean uiOrder: 0 title: Show Score - format: boolean required: - image - objects title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -302,11 +255,11 @@ TASK_DRAW_KEYPOINT: description: Output image. uiOrder: 0 title: Image - format: image/png + type: image/png required: - image title: Output - format: object + type: object TASK_DRAW_SEMANTIC_SEGMENTATION: shortDescription: Draw semantic segmentation result on the image. input: @@ -315,20 +268,17 @@ TASK_DRAW_SEMANTIC_SEGMENTATION: properties: image: description: Input image. - acceptFormats: - - image/* + type: string uiOrder: 0 title: Image - format: string stuffs: $ref: schema.yaml#/$defs/instill-types/semantic-segmentation/properties/stuffs - acceptFormats: - - array + type: array required: - image - stuffs title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -337,11 +287,11 @@ TASK_DRAW_SEMANTIC_SEGMENTATION: description: Output image. uiOrder: 0 title: Image - format: image/png + type: image/png required: - image title: Output - format: object + type: object TASK_DRAW_INSTANCE_SEGMENTATION: shortDescription: Draw instance segmentation result on the image. input: @@ -350,27 +300,22 @@ TASK_DRAW_INSTANCE_SEGMENTATION: properties: image: description: Input image. - acceptFormats: - - image/* + type: string uiOrder: 0 title: Image - format: string objects: $ref: schema.yaml#/$defs/instill-types/instance-segmentation/properties/objects - acceptFormats: - - array + type: array show-score: description: Show model confidence score on each instance. - acceptFormats: - - boolean + type: boolean uiOrder: 0 title: Show Score - format: boolean required: - image - objects title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -379,11 +324,11 @@ TASK_DRAW_INSTANCE_SEGMENTATION: description: Output image. uiOrder: 0 title: Image - format: image/png + type: image/png required: - image title: Output - format: object + type: object TASK_DRAW_OCR: shortDescription: Draw OCR result on the image. input: @@ -392,27 +337,22 @@ TASK_DRAW_OCR: properties: image: description: Input image. - acceptFormats: - - image/* + type: string uiOrder: 0 title: Image - format: string objects: $ref: schema.yaml#/$defs/instill-types/ocr/properties/objects - acceptFormats: - - array + type: array show-score: description: Show model confidence score on each instance. - acceptFormats: - - boolean + type: boolean uiOrder: 0 title: Show Score - format: boolean required: - image - objects title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -421,8 +361,8 @@ TASK_DRAW_OCR: description: Output image. uiOrder: 0 title: Image - format: image/png + type: image/png required: - image title: Output - format: object + type: object diff --git a/pkg/component/operator/json/v0/.compogen/bottom.mdx b/pkg/component/operator/json/v0/.compogen/bottom.mdx index bbb74571c..c01107599 100644 --- a/pkg/component/operator/json/v0/.compogen/bottom.mdx +++ b/pkg/component/operator/json/v0/.compogen/bottom.mdx @@ -83,11 +83,11 @@ variable: job-description: title: job description description: The text of the job description. - format: string + type: string resume: title: resume description: The PDF file of the candidates resume - format: "*/*" + type: "*/*" output: output: title: output diff --git a/pkg/component/operator/json/v0/README.mdx b/pkg/component/operator/json/v0/README.mdx index da2b6211c..7a7d64481 100644 --- a/pkg/component/operator/json/v0/README.mdx +++ b/pkg/component/operator/json/v0/README.mdx @@ -38,10 +38,10 @@ Convert JSON to a string
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_MARSHAL` | -| JSON (required) | `json` | any | JSON entity to be marshaled. It can be any valid JSON datatype (e.g. number, string, hash, array). | +| JSON (required) | `json` | object | JSON entity to be marshaled. It can be any valid JSON datatype (e.g. number, string, hash, array). |
@@ -51,7 +51,7 @@ Convert JSON to a string
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | JSON String | `string` | string | String representation of the JSON input. |
@@ -63,7 +63,7 @@ Convert a string to JSON
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_UNMARSHAL` | | String (required) | `string` | string | JSON string to be unmarshaled. It can represent any valid JSON datatype (e.g. number, string, hash, array). | @@ -76,7 +76,7 @@ Convert a string to JSON
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | JSON | `json` | json | JSON entity extracted from the string input. |
@@ -88,10 +88,10 @@ Process JSON through a `jq` command
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_JQ` | -| JSON Value | `json-value` | any | JSON entity to be processed by the filter. It can be any valid JSON datatype (e.g. number, string, hash, array). | +| JSON Value | `json-value` | object | JSON entity to be processed by the filter. It can be any valid JSON datatype (e.g. number, string, hash, array). | | Filter (required) | `jq-filter` | string | Filter, in `jq` syntax, that will be applied to the JSON input. |
@@ -102,7 +102,7 @@ Process JSON through a `jq` command
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Results | `results` | array[json] | The `jq` command results. |
@@ -137,10 +137,10 @@ Rename fields in a JSON object with a conflict resolution strategy. If the new f
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_RENAME_FIELDS` | -| JSON (required) | `json` | any | JSON object to be edited. It can be any valid JSON datatype (e.g. number, string, hash, array). | +| JSON (required) | `json` | object | JSON object to be edited. It can be any valid JSON datatype (e.g. number, string, hash, array). | | [Fields](#rename-fields-fields) (required) | `fields` | array[object] | An array of objects specifying the fields to be renamed. | | Conflict Resolution | `conflict-resolution` | string | Defines how conflicts are handled when the new field already exists in the data. If the new field already exists, it will be overwritten by default. If the new field does not exist, it will be created. When set to 'error', the component will throw an error if the new field already exists. When set to 'skip', the new field will be skipped if it already exists.
Enum values
  • `overwrite`
  • `skip`
  • `error`
|
@@ -155,7 +155,7 @@ An array of objects specifying the fields to be renamed.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | From | `from` | string | The field in the original data that needs to be renamed. | | To | `to` | string | The new name for the field. | @@ -166,7 +166,7 @@ An array of objects specifying the fields to be renamed.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | JSON | `json` | json | JSON object with the renamed fields. |
@@ -258,11 +258,11 @@ variable: job-description: title: job description description: The text of the job description. - format: string + type: string resume: title: resume description: The PDF file of the candidates resume - format: "*/*" + type: "*/*" output: output: title: output diff --git a/pkg/component/operator/json/v0/config/tasks.yaml b/pkg/component/operator/json/v0/config/tasks.yaml index e934a7e65..7f19552d3 100644 --- a/pkg/component/operator/json/v0/config/tasks.yaml +++ b/pkg/component/operator/json/v0/config/tasks.yaml @@ -7,17 +7,14 @@ TASK_MARSHAL: json: description: JSON entity to be marshaled. It can be any valid JSON datatype (e.g. number, string, hash, array). shortDescription: JSON entity to be marshaled - acceptFormats: - - object - - json - - object + type: object uiOrder: 0 required: [] title: JSON required: - json title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -26,11 +23,11 @@ TASK_MARSHAL: description: String representation of the JSON input. uiOrder: 0 title: JSON string - format: string + type: string required: - string title: Output - format: object + type: object TASK_UNMARSHAL: shortDescription: Convert a string to JSON input: @@ -40,15 +37,13 @@ TASK_UNMARSHAL: string: description: JSON string to be unmarshaled. It can represent any valid JSON datatype (e.g. number, string, hash, array). shortDescription: JSON string to be unmarshaled - acceptFormats: - - string + type: string uiOrder: 0 title: String - format: string required: - string title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -58,11 +53,11 @@ TASK_UNMARSHAL: uiOrder: 0 required: [] title: JSON - format: json + type: json required: - json title: Output - format: object + type: object TASK_JQ: shortDescription: Process JSON through a `jq` command title: jq @@ -76,29 +71,22 @@ TASK_JQ: description: (DEPRECATED, use 'JSON value' instead) String with the JSON value to be processed. This field allows templated inputs, but the data might require preprocessing (marshalling). This field will be used in absence of 'JSON value' for backwards compatibility reasons. shortDescription: (DEPRECATED) JSON string to be processed - acceptFormats: - - string + type: string title: (DEPRECATED) JSON string - format: string json-value: uiOrder: 0 description: JSON entity to be processed by the filter. It can be any valid JSON datatype (e.g. number, string, hash, array). - acceptFormats: - - object - - object - - json + type: object title: JSON value jq-filter: uiOrder: 1 description: Filter, in `jq` syntax, that will be applied to the JSON input. - acceptFormats: - - string + type: string title: Filter - format: string required: - jq-filter title: Input - format: object + type: object output: description: Results of the `jq` command applied to the input JSON. uiOrder: 0 @@ -110,12 +98,12 @@ TASK_JQ: title: Results items: title: Result - format: json - format: array + type: json + type: array required: - results title: Output - format: object + type: object TASK_RENAME_FIELDS: shortDescription: Rename fields in a JSON object with a conflict resolution strategy. If the new field already exists, it will be overwritten by default. title: Rename Fields @@ -126,10 +114,7 @@ TASK_RENAME_FIELDS: json: description: JSON object to be edited. It can be any valid JSON datatype (e.g. number, string, hash, array). shortDescription: JSON object to be edited. - acceptFormats: - - object - - json - - object + type: object uiOrder: 0 required: [] title: JSON @@ -137,8 +122,7 @@ TASK_RENAME_FIELDS: description: An array of objects specifying the fields to be renamed. shortDescription: Array of fields to be renamed. uiOrder: 1 - acceptFormats: - - array + type: array items: description: Field to be renamed. shortDescription: Field to be renamed. @@ -146,26 +130,21 @@ TASK_RENAME_FIELDS: from: description: The field in the original data that needs to be renamed. shortDescription: Field to be renamed. - acceptFormats: - - string + type: string uiOrder: 0 title: From - format: string to: description: The new name for the field. shortDescription: New name for the field. - acceptFormats: - - string + type: string uiOrder: 1 title: To - format: string required: - from - to title: Field - format: object + type: object title: Fields - format: array conflict-resolution: description: Defines how conflicts are handled when the new field already exists in the data. If the new field already exists, it will be overwritten by default. If the new field does not exist, it will be created. When set to 'error', the component will throw an error if the new field already @@ -178,12 +157,12 @@ TASK_RENAME_FIELDS: - skip - error default: overwrite - format: string + type: string required: - json - fields title: Input - format: object + type: object output: description: Output. uiOrder: 1 @@ -193,8 +172,8 @@ TASK_RENAME_FIELDS: uiOrder: 0 required: [] title: JSON - format: json + type: json required: - json title: Output - format: object + type: object diff --git a/pkg/component/operator/text/v0/README.mdx b/pkg/component/operator/text/v0/README.mdx index d3d786832..b75e571fb 100644 --- a/pkg/component/operator/text/v0/README.mdx +++ b/pkg/component/operator/text/v0/README.mdx @@ -35,7 +35,7 @@ Chunk text with different strategies
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CHUNK_TEXT` | | Text (required) | `text` | string | Text to be chunked. | @@ -52,7 +52,7 @@ Chunking strategy.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Setting](#chunk-text-setting) | `setting` | object | Chunk Setting. |
@@ -71,7 +71,7 @@ Language models have a token limit. You should not exceed the token limit. When
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Allowed Special Tokens | `allowed-special` | array | A list of special tokens that are allowed within chunks. | | Chunk Method | `chunk-method` | string | Must be `"Token"` | @@ -87,7 +87,7 @@ This text splitter is the recommended one for generic text. It is parameterized
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Chunk Method | `chunk-method` | string | Must be `"Recursive"` | | Chunk Overlap | `chunk-overlap` | integer | Determines the number of tokens that overlap between consecutive chunks. | @@ -103,7 +103,7 @@ This text splitter is specially designed for Markdown format.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Chunk Method | `chunk-method` | string | Must be `"Markdown"` | | Chunk Overlap | `chunk-overlap` | integer | Determines the number of tokens that overlap between consecutive chunks. | @@ -115,7 +115,7 @@ This text splitter is specially designed for Markdown format.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Token Count | `token-count` | integer | Total count of tokens in the original input text. | | [Text Chunks](#chunk-text-text-chunks) | `text-chunks` | array[object] | Text chunks after splitting. | @@ -130,7 +130,7 @@ This text splitter is specially designed for Markdown format.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | End Position | `end-position` | integer | The ending position of the chunk in the original text. | | Start Position | `start-position` | integer | The starting position of the chunk in the original text. | diff --git a/pkg/component/operator/text/v0/config/tasks.yaml b/pkg/component/operator/text/v0/config/tasks.yaml index 58eb5936f..1542a5b92 100644 --- a/pkg/component/operator/text/v0/config/tasks.yaml +++ b/pkg/component/operator/text/v0/config/tasks.yaml @@ -1,29 +1,23 @@ $defs: text: description: Text to be chunked. - acceptFormats: - - string + type: string uiOrder: 0 title: Text - format: string chunk-size: default: 512 description: Specifies the maximum size of each chunk in terms of the number of tokens. - acceptFormats: - - integer + type: integer uiOrder: 1 minimum: 1 title: Chunk Size - format: integer chunk-overlap: default: 100 description: Determines the number of tokens that overlap between consecutive chunks. - acceptFormats: - - integer + type: integer uiOrder: 2 minimum: 1 title: Chunk Overlap - format: integer model-name: description: The name of the model used for tokenization. enum: @@ -59,11 +53,9 @@ $defs: - code-search-babbage-code-001 - code-search-ada-code-001 - gpt2 - acceptFormats: - - string + type: string uiOrder: 3 title: Model - format: string TASK_CHUNK_TEXT: shortDescription: Chunk text with different strategies input: @@ -90,7 +82,7 @@ TASK_CHUNK_TEXT: title: Chunk Method description: Chunking based on tokenization. uiOrder: 0 - format: string + type: string chunk-size: $ref: '#/$defs/chunk-size' chunk-overlap: @@ -100,37 +92,33 @@ TASK_CHUNK_TEXT: allowed-special: default: [] description: A list of special tokens that are allowed within chunks. - acceptFormats: - - array + type: array items: - format: string + type: string uiOrder: 4 title: Allowed Special Tokens - format: array disallowed-special: default: [] description: A list of special tokens that should not appear within chunks. - acceptFormats: - - array + type: array items: - format: string + type: string uiOrder: 5 title: Disallowed Special Tokens - format: array required: - chunk-method title: Token description: Language models have a token limit. You should not exceed the token limit. When you split your text into chunks it is therefore a good idea to count the number of tokens. There are many tokenizers. When you count tokens in your text you should use the same tokenizer as used in the language model. - format: object + type: object - properties: chunk-method: const: Recursive title: Chunk Method description: Chunking based on recursive splitting. uiOrder: 0 - format: string + type: string chunk-size: $ref: '#/$defs/chunk-size' chunk-overlap: @@ -140,20 +128,16 @@ TASK_CHUNK_TEXT: separators: default: [] description: A list of strings representing the separators used to split the text. - acceptFormats: - - array + type: array uiOrder: 3 items: - format: string + type: string title: Separators - format: array keep-separator: description: A flag indicating whether to keep the separator characters at the beginning or end of chunks. - acceptFormats: - - boolean + type: boolean uiOrder: 4 title: Keep Separator - format: boolean required: - chunk-method title: Recursive @@ -161,14 +145,14 @@ TASK_CHUNK_TEXT: on them in order until the chunks are small enough. The default list is ["\n\n", "\n", "", ""]. This has the effect of trying to keep all paragraphs (and then sentences, and then words) together as long as possible, as those would generically seem to be the strongest semantically related pieces of text. - format: object + type: object - properties: chunk-method: const: Markdown title: Chunk Method description: Chunking based on recursive splitting with markdown format. uiOrder: 0 - format: string + type: string chunk-size: $ref: '#/$defs/chunk-size' chunk-overlap: @@ -177,26 +161,24 @@ TASK_CHUNK_TEXT: $ref: '#/$defs/model-name' code-blocks: description: A flag indicating whether code blocks should be treated as a single unit. - acceptFormats: - - boolean + type: boolean uiOrder: 3 title: Code Blocks - format: boolean required: - chunk-method title: Markdown description: This text splitter is specially designed for Markdown format. - format: object - format: object + type: object + type: object title: Strategy required: - setting - format: object + type: object required: - text - strategy title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -205,7 +187,7 @@ TASK_CHUNK_TEXT: description: Total number of output text chunks. uiOrder: 2 title: Number of Text Chunks - format: integer + type: integer text-chunks: description: Text chunks after splitting. uiOrder: 1 @@ -217,44 +199,44 @@ TASK_CHUNK_TEXT: title: Text description: Text chunk after splitting. uiOrder: 0 - format: string + type: string start-position: title: Start Position description: The starting position of the chunk in the original text. uiOrder: 1 - format: integer + type: integer end-position: title: End Position description: The ending position of the chunk in the original text. uiOrder: 2 - format: integer + type: integer token-count: title: Token Count description: Count of tokens in a chunk. uiOrder: 3 - format: integer + type: integer required: - text - start-position - end-position - token-count - format: object + type: object title: Text Chunks - format: array + type: array token-count: description: Total count of tokens in the original input text. uiOrder: 0 title: Token Count - format: integer + type: integer chunks-token-count: description: Total count of tokens in the output text chunks. uiOrder: 3 title: Token Count Chunks - format: integer + type: integer required: - text-chunks - chunk-num - token-count - chunks-token-count title: Output - format: object + type: object diff --git a/pkg/component/operator/video/v0/README.mdx b/pkg/component/operator/video/v0/README.mdx index fe1f0c25c..32b51a960 100644 --- a/pkg/component/operator/video/v0/README.mdx +++ b/pkg/component/operator/video/v0/README.mdx @@ -39,7 +39,7 @@ Split a video into multiple shorter clips based on user-defined time segments. T
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SEGMENT` | | Video (required) | `video` | string | The source video file to be segmented. This video will be split into multiple clips based on the specified time segments. | @@ -56,7 +56,7 @@ An array of time segments defining the portions of the video to be extracted. Ea
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | End Time | `end-time` | number | The number of seconds from the beginning of the audio file to the end of this segment. | | Start Time | `start-time` | number | The number of seconds from the beginning of the audio file to the start of this segment. | @@ -67,7 +67,7 @@ An array of time segments defining the portions of the video to be extracted. Ea
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Videos | `video-segments` | array[string] | An array of video clips resulting from the segmentation process. Each element in this array corresponds to one of the input segments and contains the video data for that specific time range from the original video. |
@@ -79,7 +79,7 @@ Reduce video file size by adjusting frame rate, bitrate, and dimensions while ma
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SUBSAMPLE` | | Video (required) | `video` | string | The source video file to be subsampled. | @@ -97,7 +97,7 @@ Reduce video file size by adjusting frame rate, bitrate, and dimensions while ma
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Video | `video` | video/* | The subsampled video data, processed according to the specified input parameters. Maintains the content of the original video with potentially reduced file size due to changes in frame rate, bitrate, or dimensions. |
@@ -109,7 +109,7 @@ Extract the audio track from a video file, creating a standalone audio output. T
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_EXTRACT_AUDIO` | | Video (required) | `video` | string | The source video file from which the audio will be extracted. The video's visual content will be discarded, and only the audio track will be processed. | @@ -122,7 +122,7 @@ Extract the audio track from a video file, creating a standalone audio output. T
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Audio | `audio` | audio/* | The extracted audio data from the input video. This is a standalone audio file containing only the sound component of the original video, with all visual elements removed. The audio format may vary depending on the original video's audio codec and the extraction process. |
@@ -134,7 +134,7 @@ Extract image frames from a video at regular intervals or specified timestamps.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_EXTRACT_FRAMES` | | Video (required) | `video` | string | The source video file from which frames will be extracted. | @@ -149,7 +149,7 @@ Extract image frames from a video at regular intervals or specified timestamps.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Frames | `frames` | array[string] | Extracted video frames. |
@@ -161,11 +161,11 @@ Embed an audio to the existing video
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_EMBED_AUDIO` | -| Audio (required) | `audio` | any | Audio data to embed to video | -| Video (required) | `video` | any | Video input to be embedded with provided audio | +| Audio (required) | `audio` | audio | Audio data to embed to video | +| Video (required) | `video` | video | Video input to be embedded with provided audio |
@@ -175,7 +175,7 @@ Embed an audio to the existing video
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Video | `video` | video | Final video embedded with audio |
diff --git a/pkg/component/operator/video/v0/config/tasks.yaml b/pkg/component/operator/video/v0/config/tasks.yaml index 0002bae6f..616831218 100644 --- a/pkg/component/operator/video/v0/config/tasks.yaml +++ b/pkg/component/operator/video/v0/config/tasks.yaml @@ -6,18 +6,18 @@ $defs: title: Start Time description: The number of seconds from the beginning of the audio file to the start of this segment. uiOrder: 0 - format: number + type: number end-time: title: End Time description: The number of seconds from the beginning of the audio file to the end of this segment. uiOrder: 1 - format: number + type: number required: - start-time - end-time title: Segment description: A time segment of audio data, defined by its start and end times in seconds. - format: object + type: object TASK_SEGMENT: shortDescription: Split a video into multiple shorter clips based on user-defined time segments. This task takes a video input and an optional list of time ranges, then produces an array of video segments corresponding to those ranges. Each segment becomes a separate video clip, enabling precise extraction @@ -28,12 +28,9 @@ TASK_SEGMENT: properties: video: description: The source video file to be segmented. This video will be split into multiple clips based on the specified time segments. - acceptFormats: - - video/* - - application/octet-stream + type: string uiOrder: 0 title: Video - format: string segments: description: An array of time segments defining the portions of the video to be extracted. Each segment specifies a start and end time, and the task will create separate video clips for each of these segments. If not provided, the entire video will be treated as a single segment. @@ -41,11 +38,11 @@ TASK_SEGMENT: items: $ref: '#/$defs/segment' title: Segments - format: array + type: array required: - video title: Input - format: object + type: object output: description: Output. uiOrder: 0 @@ -55,13 +52,13 @@ TASK_SEGMENT: and contains the video data for that specific time range from the original video. uiOrder: 0 items: - format: string + type: string title: Videos - format: array + type: array required: - video-segments title: Output - format: object + type: object TASK_SUBSAMPLE: shortDescription: Reduce video file size by adjusting frame rate, bitrate, and dimensions while maintaining visual content. This task optimizes storage and bandwidth requirements with minimal quality loss. @@ -71,59 +68,43 @@ TASK_SUBSAMPLE: properties: video: description: The source video file to be subsampled. - acceptFormats: - - video/* - - application/octet-stream + type: string uiOrder: 0 title: Video - format: string video-bitrate: description: 'The target video bitrate for the subsampled video, in bits per second. Controls the output video''s data rate, affecting file size and quality. Must provide at least one of: video-bitrate, audio-bitrate, fps, width, or height.' - acceptFormats: - - number - - integer + type: number uiOrder: 2 title: Video Bitrate - format: number audio-bitrate: description: 'The target audio bitrate for the subsampled video, in bits per second. Controls the output video''s audio data rate, affecting file size and quality. Must provide at least one of: video-bitrate, audio-bitrate, fps, width, or height.' - acceptFormats: - - number - - integer + type: number uiOrder: 3 title: Audio Bitrate - format: number fps: description: 'The target frame rate for the subsampled video, in frames per second. Determines the number of frames in the output video. Must provide at least one of: video-bitrate, audio-bitrate, fps, width, or height.' - acceptFormats: - - number - - integer + type: number uiOrder: 1 title: FPS - format: number width: description: 'The width of the subsampled video, in pixels. Controls the output video''s horizontal resolution. If only width is provided, height is auto-calculated to maintain aspect ratio. Must provide at least one of: video-bitrate, audio-bitrate, fps, width, or height.' - acceptFormats: - - integer + type: integer uiOrder: 2 title: Width - format: integer height: description: 'The height of the subsampled video, in pixels. Controls the output video''s vertical resolution. If only height is provided, width is auto-calculated to maintain aspect ratio. Must provide at least one of: video-bitrate, audio-bitrate, fps, width, or height.' - acceptFormats: - - integer + type: integer uiOrder: 3 title: Height - format: integer required: - video title: Input - format: object + type: object output: description: Output. uiOrder: 1 @@ -133,11 +114,11 @@ TASK_SUBSAMPLE: potentially reduced file size due to changes in frame rate, bitrate, or dimensions. uiOrder: 0 title: Video - format: video/* + type: video/* required: - video title: Output - format: object + type: object TASK_EXTRACT_AUDIO: shortDescription: Extract the audio track from a video file, creating a standalone audio output. This task takes a video input and isolates its sound component, removing all visual elements. The resulting audio data is provided as a single output, suitable for further audio processing, analysis, or @@ -149,16 +130,13 @@ TASK_EXTRACT_AUDIO: video: description: The source video file from which the audio will be extracted. The video's visual content will be discarded, and only the audio track will be processed. - acceptFormats: - - video/* - - application/octet-stream + type: string uiOrder: 0 title: Video - format: string required: - video title: Input - format: object + type: object output: description: Output. uiOrder: 1 @@ -168,11 +146,11 @@ TASK_EXTRACT_AUDIO: video, with all visual elements removed. The audio format may vary depending on the original video's audio codec and the extraction process. uiOrder: 0 title: Audio - format: audio/* + type: audio/* required: - audio title: Output - format: object + type: object TASK_EMBED_AUDIO: shortDescription: Embed an audio to the existing video input: @@ -181,20 +159,14 @@ TASK_EMBED_AUDIO: properties: audio: description: Audio data to embed to video - acceptFormats: - - audio - - application/octet-stream + type: audio uiOrder: 0 title: Audio - type: string video: description: Video input to be embedded with provided audio - acceptFormats: - - video - - application/octet-stream + type: video uiOrder: 1 title: Video - type: string required: - video - audio @@ -206,10 +178,9 @@ TASK_EMBED_AUDIO: properties: video: description: Final video embedded with audio - format: video + type: video uiOrder: 0 title: Video - type: string required: - video title: Output @@ -224,31 +195,25 @@ TASK_EXTRACT_FRAMES: properties: video: description: The source video file from which frames will be extracted. - acceptFormats: - - video/* - - application/octet-stream + type: string uiOrder: 0 title: Video - format: string interval: description: The time interval between extracted frames, in seconds. If specified, frames will be extracted at regular intervals throughout the video. This parameter is mutually exclusive with `timestamps`. - acceptFormats: - - number - - integer + type: number uiOrder: 1 title: Interval - format: number timestamps: description: An array of specific timestamps (in seconds) at which to extract frames from the video. If provided, frames will be extracted only at these exact times. This parameter is mutually exclusive with `interval`. uiOrder: 2 title: Timestamps - format: array + type: array required: - video title: Input - format: object + type: object output: description: Output. uiOrder: 1 @@ -258,10 +223,10 @@ TASK_EXTRACT_FRAMES: uiOrder: 0 items: title: Frame - format: string + type: string title: Frames - format: array + type: array required: - frames title: Output - format: object + type: object diff --git a/pkg/component/operator/web/v0/.compogen/bottom.mdx b/pkg/component/operator/web/v0/.compogen/bottom.mdx index 7412d9a34..cbdaef47c 100644 --- a/pkg/component/operator/web/v0/.compogen/bottom.mdx +++ b/pkg/component/operator/web/v0/.compogen/bottom.mdx @@ -6,7 +6,7 @@ version: v1beta variable: url: title: URL - format: string + type: string component: crawler: diff --git a/pkg/component/operator/web/v0/README.mdx b/pkg/component/operator/web/v0/README.mdx index 9120cb799..8d77c7c2a 100644 --- a/pkg/component/operator/web/v0/README.mdx +++ b/pkg/component/operator/web/v0/README.mdx @@ -37,7 +37,7 @@ This task involves systematically navigating through a website, starting from a
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_CRAWL_SITE` | | URL (required) | `url` | string | The root URL to scrape. All links on this page will be scraped, and all links on those pages, and so on. | @@ -58,7 +58,7 @@ Filtering based on [regular expression](https://developer.mozilla.org/en-US/docs
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Exclude Pattern | `exclude-pattern` | string | When the URL is matched, the URL will not be crawled. | | Include Pattern | `include-pattern` | string | When the URL is matched, the URL will be crawled. | @@ -69,7 +69,7 @@ Filtering based on [regular expression](https://developer.mozilla.org/en-US/docs
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Pages](#crawl-site-pages) | `pages` | array[object] | The link and title of webpages crawled by the crawler. |
@@ -81,7 +81,7 @@ Filtering based on [regular expression](https://developer.mozilla.org/en-US/docs
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Link | `link` | string | The full URL to which the webpage link is pointing, e.g., http://www.example.com/foo/bar. | | Title | `title` | string | The title of a webpage link in plain text. | @@ -145,7 +145,7 @@ This task focuses on extracting specific data from targeted webpages by parsing
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SCRAPE_PAGES` | | URLs (required) | `urls` | array[string] | The URLs to scrape the webpage contents. | @@ -164,7 +164,7 @@ This task focuses on extracting specific data from targeted webpages by parsing
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Pages](#scrape-pages-pages) | `pages` | array[object] | A list of page objects that have been scraped. |
@@ -176,7 +176,7 @@ This task focuses on extracting specific data from targeted webpages by parsing
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Content | `content` | string | The scraped plain content without html tags of the webpage. | | HTML | `html` | string | The scraped html of the webpage. | @@ -189,7 +189,7 @@ This task focuses on extracting specific data from targeted webpages by parsing
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Description | `description` | string | The description of the webpage. | | Source URL | `source-url` | string | The source URL of the webpage. | @@ -243,7 +243,7 @@ This task extracts data directly from a website’s sitemap. A sitemap is typica
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_SCRAPE_SITEMAP` | | URL (required) | `url` | string | The URL of the sitemap to scrape. | @@ -256,7 +256,7 @@ This task extracts data directly from a website’s sitemap. A sitemap is typica
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | List | `list` | array[json] | The list of information in a sitemap. |
@@ -271,7 +271,7 @@ version: v1beta variable: url: title: URL - format: string + type: string component: crawler: diff --git a/pkg/component/operator/web/v0/config/tasks.yaml b/pkg/component/operator/web/v0/config/tasks.yaml index 5cfeb1b2c..3e801fe81 100644 --- a/pkg/component/operator/web/v0/config/tasks.yaml +++ b/pkg/component/operator/web/v0/config/tasks.yaml @@ -5,16 +5,16 @@ $defs: description: The full URL to which the webpage link is pointing, e.g., http://www.example.com/foo/bar. uiOrder: 0 title: Link - format: string + type: string title: description: The title of a webpage link in plain text. uiOrder: 1 title: Title - format: string + type: string required: - link title: Page Information - format: object + type: object TASK_CRAWL_SITE: shortDescription: This task involves systematically navigating through a website, starting from a designated page (typically the homepage), and following internal links to discover and retrieve page titles and URLs. The process is limited to 120 seconds and only collects links and titles from multiple @@ -25,53 +25,43 @@ TASK_CRAWL_SITE: properties: url: description: The root URL to scrape. All links on this page will be scraped, and all links on those pages, and so on. - acceptFormats: - - string + type: string uiOrder: 0 title: URL - format: string allowed-domains: description: A list of domains that are allowed to be scraped. If empty, all domains are allowed. - acceptFormats: - - array + type: array uiOrder: 1 items: - format: string + type: string title: Allowed Domains - format: array max-k: default: 10 description: Max-K sets a limit on the number of pages to fetch. If Max-K is set to 0, all available pages will be fetched within the time limit of 120 seconds. If Max-K is a positive number, the fetch will return up to that many pages, but no more. - acceptFormats: - - integer + type: integer uiOrder: 2 minimum: 0 title: Max Number of Pages - format: integer timeout: default: 1000 description: The time to wait for a page to load in milliseconds. Min 0, Max 60000. Please notice the timeout here is set for each page rather than the whole crawl task. - acceptFormats: - - integer + type: integer uiOrder: 3 minimum: 0 maximum: 60000 title: Timeout - format: integer max-depth: default: 0 description: Max Depth specifies how deep the crawler will navigate from the root URL. If max depth is set to 1, the crawler will only scrape the root URL and will not follow any links to other pages. If max depth is set to 0, the crawler will scrape all reachable pages until the total number of scraped pages reaches max-k. If both max-k and max depth are defined, the crawler will prioritize the max-k setting when determining how many pages to scrape. - acceptFormats: - - integer + type: integer uiOrder: 4 minimum: 0 title: Max Depth - format: integer filter: description: Filtering based on [regular expression](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_expressions). The URL will be crawled if it matches either include-pattern or not match exclude-pattern. When both include-pattern and exclude-pattern are empty, all @@ -82,25 +72,21 @@ TASK_CRAWL_SITE: properties: exclude-pattern: description: When the URL is matched, the URL will not be crawled. - acceptFormats: - - string + type: string uiOrder: 1 title: Exclude Pattern - format: string include-pattern: description: When the URL is matched, the URL will be crawled. - acceptFormats: - - string + type: string uiOrder: 2 title: Include Pattern - format: string required: [] - format: object + type: object required: - url - max-k title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -111,11 +97,11 @@ TASK_CRAWL_SITE: $ref: '#/$defs/page-info' title: Page title: Pages - format: array + type: array required: - pages title: Output - format: object + type: object TASK_SCRAPE_SITEMAP: shortDescription: This task extracts data directly from a website’s sitemap. A sitemap is typically an XML file that lists all URLs and other relevant metadata, providing a structured overview of the site’s pages. This method efficiently gathers key information from the sitemap without navigating through @@ -126,15 +112,13 @@ TASK_SCRAPE_SITEMAP: properties: url: description: The URL of the sitemap to scrape. - acceptFormats: - - string + type: string uiOrder: 0 title: URL - format: string required: - url title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -147,33 +131,33 @@ TASK_SCRAPE_SITEMAP: description: The URL of the webpage. title: URL uiOrder: 0 - format: string + type: string lastmod: description: The last modified time of the webpage with ISO 8601 format. title: Last Modified uiOrder: 1 - format: string + type: string changefreq: description: The change frequency of the webpage. title: Change Frequency uiOrder: 2 - format: string + type: string priority: description: The priority of the webpage. title: Priority uiOrder: 3 - format: number + type: number required: - loc - lastmod title: List - format: json + type: json title: List - format: array + type: array required: - list title: Output - format: object + type: object TASK_SCRAPE_PAGES: shortDescription: This task focuses on extracting specific data from targeted webpages by parsing its HTML structure. Unlike crawling, which navigates across multiple pages, scraping retrieves content only from the specified page. After scraping, the data can be further processed using a defined [jQuery](https://www.w3schools.com/jquery/jquery_syntax.asp) @@ -185,76 +169,62 @@ TASK_SCRAPE_PAGES: properties: urls: description: The URLs to scrape the webpage contents. - acceptFormats: - - array + type: array items: - format: string + type: string uiOrder: 0 title: URLs - format: array scrape-method: description: Defines the method used for web scraping. Available options include 'http' for standard HTTP-based scraping and 'chrome-simulator' for scraping through a simulated Chrome browser environment. - acceptFormats: - - string + type: string enum: - http - chrome-simulator uiOrder: 1 default: http title: Scrape Method - format: string include-html: description: Indicate whether to include the raw HTML of the webpage in the output. If you want to include the raw HTML, set this to true. - acceptFormats: - - boolean + type: boolean uiOrder: 2 title: Include HTML - format: boolean only-main-content: description: Only return the main content of the page by excluding the content of the tag of header, nav, footer. - acceptFormats: - - boolean + type: boolean uiOrder: 3 title: Only Main Content - format: boolean remove-tags: description: 'A list of tags, classes, and ids to remove from the output. You can use [jQuery](https://www.w3schools.com/jquery/jquery_syntax.asp) to remove data. If empty, no tags will be removed. Example: ''script, .ad, #footer''. Please check the [jQuery Syntax Examples](#jquery-syntax-examples).' - acceptFormats: - - array + type: array uiOrder: 4 items: - format: string + type: string title: Remove Tags - format: array only-include-tags: description: 'A list of tags, classes, and ids to include in the output. You can use [jQuery](https://www.w3schools.com/jquery/jquery_syntax.asp) to include data. If empty, all tags will be included. Example: ''script, .ad, #footer''. Please check the [jQuery Syntax Examples](#jquery-syntax-examples).' - acceptFormats: - - array + type: array uiOrder: 5 items: - format: string + type: string title: Only Include Tags - format: array timeout: default: 1000 description: This parameter specifies the time to wait for a page to load, measured in milliseconds. The minimum value is 0, and the maximum value is 60,000. Please note that if you set a short timeout, the page may not fully load. Conversely, setting a long timeout could significantly increase the time it takes for the task to complete. This timeout setting applies only to the Chrome simulator. - acceptFormats: - - integer + type: integer uiOrder: 6 minimum: 0 maximum: 60000 title: Timeout - format: integer required: - urls - scrape-method title: Input - format: object + type: object output: uiOrder: 0 properties: @@ -267,17 +237,17 @@ TASK_SCRAPE_PAGES: description: The scraped plain content without html tags of the webpage. uiOrder: 0 title: Content - format: string + type: string markdown: description: The scraped markdown of the webpage. uiOrder: 1 title: Markdown - format: string + type: string html: description: The scraped html of the webpage. uiOrder: 2 title: HTML - format: string + type: string metadata: description: The metadata of the webpage. uiOrder: 3 @@ -286,36 +256,36 @@ TASK_SCRAPE_PAGES: description: The title of the webpage. title: Title uiOrder: 0 - format: string + type: string description: description: The description of the webpage. title: Description uiOrder: 1 - format: string + type: string source-url: description: The source URL of the webpage. title: Source URL uiOrder: 2 - format: string + type: string required: - title - source-url title: Metadata - format: object + type: object links-on-page: description: The list of links on the webpage. uiOrder: 4 items: - format: string + type: string title: Links on Page - format: array + type: array required: - content - markdown - format: object + type: object title: Pages - format: array + type: array required: - pages title: Output - format: object + type: object diff --git a/pkg/component/resources/schemas/schema.yaml b/pkg/component/resources/schemas/schema.yaml index aed45096a..07e35c062 100644 --- a/pkg/component/resources/schemas/schema.yaml +++ b/pkg/component/resources/schemas/schema.yaml @@ -8,29 +8,29 @@ $defs: description: Bounding box height value uiOrder: 3 title: Height - format: number + type: number left: description: Bounding box left x-axis value uiOrder: 0 title: Left - format: number + type: number top: description: Bounding box top y-axis value uiOrder: 1 title: Top - format: number + type: number width: description: Bounding box width value uiOrder: 2 title: Width - format: number + type: number required: - left - top - width - height title: Bounding Box - format: object + type: object chat-messages: items: properties: @@ -45,18 +45,18 @@ $defs: uiOrder: 2 required: [] title: Metadata - format: json + type: json role: description: The message role, i.e. 'system', 'user' or 'assistant' uiOrder: 0 title: Role - format: string + type: string required: - role - content - format: object + type: object title: Chat Message - format: array + type: array classification: additionalProperties: false properties: @@ -64,16 +64,16 @@ $defs: description: The predicted category of the input. uiOrder: 0 title: Category - format: string + type: string score: description: The confidence score of the predicted category of the input. uiOrder: 1 title: Score - format: number + type: number required: - category - score - format: object + type: object detection: additionalProperties: false properties: @@ -91,29 +91,29 @@ $defs: description: The predicted category of the bounding box. uiOrder: 2 title: Category - format: string + type: string score: description: The confidence score of the predicted category of the bounding box. uiOrder: 3 title: Score - format: number + type: number required: - bounding-box - category - score title: Object - format: object + type: object title: Objects - format: array + type: array required: - objects - format: object + type: object embedding: items: title: Embedding - format: number + type: number title: Embedding - format: array + type: array instance-segmentation: additionalProperties: false properties: @@ -130,29 +130,29 @@ $defs: description: The predicted category of the bounding box. uiOrder: 2 title: Category - format: string + type: string rle: description: Run Length Encoding (RLE) of instance mask within the bounding box. uiOrder: 0 title: RLE - format: string + type: string score: description: The confidence score of the predicted instance object. uiOrder: 3 title: Score - format: number + type: number required: - rle - bounding-box - category - score title: Object - format: object + type: object title: Objects - format: array + type: array required: - objects - format: object + type: object keypoint: additionalProperties: false properties: @@ -175,41 +175,41 @@ $defs: description: visibility score of the keypoint. uiOrder: 2 title: Visibility Score - format: number + type: number x: description: x coordinate of the keypoint. uiOrder: 0 title: X Coordinate - format: number + type: number y: description: y coordinate of the keypoint. uiOrder: 1 title: Y Coordinate - format: number + type: number required: - x - y - v title: Keypoints - format: object + type: object title: Keypoints - format: array + type: array score: description: The confidence score of the predicted object. uiOrder: 1 title: Score - format: number + type: number required: - keypoints - score - bounding-box title: Object - format: object + type: object title: Objects - format: array + type: array required: - objects - format: object + type: object multi-modal-content: items: properties: @@ -219,18 +219,18 @@ $defs: description: Either a URL of the image or the base64 encoded image data. title: URL uiOrder: 0 - format: string + type: string required: - url title: Image URL description: The image URL uiOrder: 0 - format: object + type: object text: description: The text content. title: Text uiOrder: 1 - format: string + type: string type: description: The type of the content part. enum: @@ -238,11 +238,11 @@ $defs: - image-url title: Type uiOrder: 2 - format: string + type: string required: - type - format: object - format: array + type: object + type: array ocr: additionalProperties: false properties: @@ -259,23 +259,23 @@ $defs: description: The confidence score of the predicted object. uiOrder: 2 title: Score - format: number + type: number text: description: Text string recognised per bounding box. uiOrder: 1 title: Text - format: string + type: string required: - bounding-box - text - score title: Object - format: object + type: object title: Objects - format: array + type: array required: - objects - format: object + type: object semantic-segmentation: additionalProperties: false properties: @@ -288,19 +288,19 @@ $defs: description: Category text string corresponding to each stuff mask. uiOrder: 1 title: Category - format: string + type: string rle: description: Run Length Encoding (RLE) of each stuff mask within the image. uiOrder: 0 title: RLE - format: string + type: string required: - rle - category title: Object - format: object + type: object title: Stuffs - format: array + type: array required: - stuffs - format: object + type: object diff --git a/pkg/component/tools/compogen/cmd/testdata/readme-component1.txt b/pkg/component/tools/compogen/cmd/testdata/readme-component1.txt index cadc976a8..ca5f46918 100644 --- a/pkg/component/tools/compogen/cmd/testdata/readme-component1.txt +++ b/pkg/component/tools/compogen/cmd/testdata/readme-component1.txt @@ -33,12 +33,12 @@ properties: description: Specify which organization is used for the requests uiOrder: 1 title: Organization ID - format: string + type: string api-key: description: Fill in your Dummy API key uiOrder: 0 title: API Key - format: string + type: string authentication: description: Authentication method to use for the Dummy uiOrder: 0 @@ -50,7 +50,7 @@ properties: uiOrder: 0 order: 0 title: Auth Format - format: string + type: string required: - auth-type title: No Auth @@ -61,29 +61,27 @@ properties: uiOrder: 0 order: 0 title: Auth Format - format: string + type: string auth-way: description: ways for Auth 1 - acceptFormats: - - string + type: string enum: - header - query uiOrder: 1 order: 1 title: Auth Way - format: string required: - auth-type - auth-way title: Auth 1 order: 1 title: Authentication - format: object + type: object required: - api-key title: OpenAI Connection -format: object +type: object -- tasks.yaml -- TASK_DUMMY: @@ -94,7 +92,7 @@ TASK_DUMMY: description: Lorem ipsum dolor sit amet, consectetur adipiscing elit uiOrder: 0 title: Durna - format: string + type: string strategy: description: Chunking strategy uiOrder: 1 @@ -102,7 +100,7 @@ TASK_DUMMY: setting: description: Chunk Setting additionalProperties: true - format: object + type: object title: Chunk Setting uiOrder: 0 required: @@ -111,7 +109,7 @@ TASK_DUMMY: - properties: chunk-method: const: Token - format: string + type: string title: Chunk Method description: Chunking based on tokenization. uiOrder: 0 @@ -122,16 +120,16 @@ TASK_DUMMY: - gpt-3.5-turbo uiOrder: 1 title: Model - format: string + type: string title: Token required: - chunk-method - format: object + type: object description: Language models have a token limit. You should not exceed the token limit. When you split your text into chunks it is therefore a good idea to count the number of tokens. There are many tokenizers. When you count tokens in your text you should use the same tokenizer as used in the language model. - properties: chunk-method: const: Markdown - format: string + type: string title: Chunk Method description: Chunking based on recursive splitting with markdown format. uiOrder: 0 @@ -142,33 +140,33 @@ TASK_DUMMY: - gpt-3.5-turbo uiOrder: 1 title: Model - format: string + type: string title: Markdown required: - chunk-method - format: object + type: object description: This text splitter is specially designed for Markdown format. title: Strategy required: - setting - format: object + type: object dummy-string: description: '{{dummy_string}}' uiOrder: 0 title: Dummy String - format: string + type: string dummy-file: description: this is a file uiOrder: 0 title: Dummy File - format: '*' + type: '*' dummy-array: description: this is an array uiOrder: 0 title: Dummy Array - format: array + type: array items: - format: '*' + type: '*' required: - durna title: Input @@ -176,48 +174,47 @@ TASK_DUMMY: properties: orci: description: Orci sagittis eu volutpat odio facilisis mauris sit - format: string + type: string uiOrder: 0 title: Orci conversations: description: An array of conversations with thread messages uiOrder: 0 title: Conversations - format: array + type: array items: title: conversation details - format: object + type: object properties: message: description: message to start a conversation uiOrder: 0 title: Start Conversation Message - format: string + type: string start-date: description: when a conversation starts uiOrder: 1 title: Start Date - format: string + type: string last-date: description: Date of the last message uiOrder: 2 title: Last Date - format: string + type: string thread-reply-messages: description: replies in a conversation uiOrder: 0 title: Replied messages - format: array + type: array items: title: relied details - format: object + type: object properties: message: description: message to reply a conversation - instillFormat: string + type: string uiOrder: 3 title: Replied Message - format: string required: - message required: @@ -266,7 +263,7 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | API Key (required) | `api-key` | string | Fill in your Dummy API key | | [Authentication](#authentication) | `authentication` | object | Authentication method to use for the Dummy | @@ -287,7 +284,7 @@ This is some crucial information about setup: do it before execution.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Auth Format | `auth-type` | string | Must be `"NO_AUTH"` |
@@ -296,7 +293,7 @@ This is some crucial information about setup: do it before execution.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Auth Format | `auth-type` | string | Must be `"AUTH_1"` | | Auth Way | `auth-way` | string | ways for Auth 1
Enum values
  • `header`
  • `query`
| @@ -312,7 +309,7 @@ Perform a dummy task.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DUMMY` | | Dummy Array | `dummy-array` | array[any] | this is an array | @@ -332,7 +329,7 @@ Chunking strategy
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | [Chunk Setting](#dummy-chunk-setting) | `setting` | object | Chunk Setting |
@@ -351,7 +348,7 @@ Language models have a token limit. You should not exceed the token limit. When
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Chunk Method | `chunk-method` | string | Must be `"Token"` | | Model | `model-name` | string | The name of the model used for tokenization.
Enum values
  • `gpt-4`
  • `gpt-3.5-turbo`
| @@ -363,7 +360,7 @@ This text splitter is specially designed for Markdown format.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Chunk Method | `chunk-method` | string | Must be `"Markdown"` | | Model | `model-name` | string | The name of the model used for tokenization.
Enum values
  • `gpt-4`
  • `gpt-3.5-turbo`
| @@ -372,7 +369,7 @@ This text splitter is specially designed for Markdown format.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | [Conversations](#dummy-conversations) (optional) | `conversations` | array[object] | An array of conversations with thread messages | | Orci (optional) | `orci` | string | Orci sagittis eu volutpat odio facilisis mauris sit | @@ -385,7 +382,7 @@ This text splitter is specially designed for Markdown format.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Last Date | `last-date` | string | Date of the last message | | Start Conversation Message | `message` | string | message to start a conversation | @@ -397,7 +394,7 @@ This text splitter is specially designed for Markdown format.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Replied Message | `message` | string | message to reply a conversation |
diff --git a/pkg/component/tools/compogen/cmd/testdata/readme-component2.txt b/pkg/component/tools/compogen/cmd/testdata/readme-component2.txt index 556b6f87a..8e7e07c09 100644 --- a/pkg/component/tools/compogen/cmd/testdata/readme-component2.txt +++ b/pkg/component/tools/compogen/cmd/testdata/readme-component2.txt @@ -48,13 +48,13 @@ TASK_DUMMY: description: Lorem ipsum dolor sit amet, consectetur adipiscing elit uiOrder: 0 title: Durna - format: string + type: string parra: deprecated: true description: Shouldn't appear, it's deprecated uiOrder: 1 title: Parra - format: string + type: string required: - durna title: Input @@ -64,7 +64,7 @@ TASK_DUMMY: description: Orci sagittis eu volutpat odio facilisis mauris sit uiOrder: 0 title: Orci - format: string + type: string title: Output TASK_DUMMIER_THAN_DUMMY: @@ -76,7 +76,7 @@ TASK_DUMMIER_THAN_DUMMY: description: Cursus mattis molestie a iaculis at erat pellentesque adipiscing commodo uiOrder: 0 title: Cursus - format: string + type: string required: - cursus title: Input @@ -86,14 +86,14 @@ TASK_DUMMIER_THAN_DUMMY: description: Tellus elementum sagittis vitae et uiOrder: 0 title: Elementum - format: string + type: string errors: description: Error messages, if any, during the dummy process uiOrder: 3 title: Errors items: - format: string - format: array + type: string + type: array context: description: Free-form metadata uiOrder: 4 @@ -103,24 +103,24 @@ TASK_DUMMIER_THAN_DUMMY: description: 'This object should comply witht he format {"tortor": "something", "arcu": "something else"}' uiOrder: 1 title: Atem - format: object + type: object properties: tortor: description: Tincidunt tortor aliquam nulla uiOrder: 0 title: Tincidunt tortor - format: string + type: string arcu: description: Bibendum arcu vitae elementum curabitur vitae nunc sed velit uiOrder: 1 title: Arcu - format: string + type: string required: [] nullam_non: description: Id faucibus nisl tincidunt eget nullam non uiOrder: 2 title: Nullam non - format: number + type: number required: - elementum - atem @@ -185,7 +185,7 @@ Perform a dummy task.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DUMMY` | | Durna (required) | `durna` | string | Lorem ipsum dolor sit amet, consectetur adipiscing elit | @@ -198,7 +198,7 @@ Perform a dummy task.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Orci (optional) | `orci` | string | Orci sagittis eu volutpat odio facilisis mauris sit |
@@ -214,7 +214,7 @@ This task is dummier than `TASK_DUMMY`.
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `TASK_DUMMIER_THAN_DUMMY` | | Cursus (required) | `cursus` | string | Cursus mattis molestie a iaculis at erat pellentesque adipiscing commodo | @@ -227,7 +227,7 @@ This task is dummier than `TASK_DUMMY`.
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Elementum | `elementum` | string | Tellus elementum sagittis vitae et | | [Atem](#dummier-atem) | `atem` | object | This object should comply witht he format \{"tortor": "something", "arcu": "something else"\} | @@ -243,7 +243,7 @@ This task is dummier than `TASK_DUMMY`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | | Arcu | `arcu` | string | Bibendum arcu vitae elementum curabitur vitae nunc sed velit | | Tincidunt tortor | `tortor` | string | Tincidunt tortor aliquam nulla | diff --git a/pkg/component/tools/compogen/pkg/gen/readme.go b/pkg/component/tools/compogen/pkg/gen/readme.go index a500e5e0e..dd08dfdf7 100644 --- a/pkg/component/tools/compogen/pkg/gen/readme.go +++ b/pkg/component/tools/compogen/pkg/gen/readme.go @@ -348,18 +348,18 @@ func parseResourceProperties(o *objectSchema) []resourceProperty { prop.Title = titleCase(prop.Title) prop.replaceFormat() - // If format is array, extend the format with the element format. - switch prop.Format { + // If type is array, extend the type with the element type. + switch prop.Type { case "array": - if prop.Items.Format != "" { - if prop.Items.Format == "*" { - prop.Format = "array[any]" + if prop.Items.Type != "" { + if prop.Items.Type == "*" { + prop.Type = "array[any]" } else { - prop.Format += fmt.Sprintf("[%s]", prop.Items.Format) + prop.Type += fmt.Sprintf("[%s]", prop.Items.Type) } } case "": - prop.Format = "any" + prop.Type = "any" } prop.replaceDescription() @@ -403,15 +403,15 @@ func (rt *readmeTask) parseObjectProperties(properties map[string]property, isIn continue } - if op.Format != "object" && op.Format != "array[object]" && (op.Format != "array" || op.Items.Format != "object") { + if op.Type != "object" && op.Type != "array[object]" && (op.Type != "array" || op.Items.Type != "object") { continue } - if op.Format == "object" && op.Properties == nil { + if op.Type == "object" && op.Properties == nil { continue } - if op.Format == "array[object]" && op.Items.Properties == nil { + if op.Type == "array[object]" && op.Items.Properties == nil { continue } @@ -426,7 +426,7 @@ func (rt *readmeTask) parseObjectProperties(properties map[string]property, isIn op.replaceDescription() op.replaceFormat() - if op.Format == "object" { + if op.Type == "object" { if isInput { rt.InputObjects = append(rt.InputObjects, map[string]objectSchema{ @@ -445,7 +445,7 @@ func (rt *readmeTask) parseObjectProperties(properties map[string]property, isIn }) rt.parseObjectProperties(op.Properties, isInput) } - } else { // op.Format == "array[object]" || (op.Format == "array" || op.Items.Format == "object") + } else { // op.Type == "array[object]" || (op.Type == "array" || op.Items.Type == "object") props := op.Items.Properties for key := range props { @@ -520,12 +520,12 @@ func (rt *readmeTask) parseOneOfsProperties(properties map[string]property) { continue } - if op.Format != "object" && op.Format != "array" { + if op.Type != "object" && op.Type != "array" { continue } - if op.Format == "array" { - if op.Items.Format != "object" { + if op.Type == "array" { + if op.Items.Type != "object" { continue } @@ -614,20 +614,20 @@ func anchorSetupFromProperty(prop property) string { if isSemiStructuredObject(prop) { return prop.Title } - if prop.Format == "object" || - (prop.Format == "array" && prop.Items.Format == "object") || - (prop.Format == "array[object]") { + if prop.Type == "object" || + (prop.Type == "array" && prop.Items.Type == "object") || + (prop.Type == "array[object]") { return fmt.Sprintf("[%s](#%s)", prop.Title, blackfriday.SanitizedAnchorName(prop.Title)) } return prop.Title } func isSemiStructuredObject(p property) bool { - return p.Format == "object" && p.Properties == nil && p.OneOf == nil + return p.Type == "object" && p.Properties == nil && p.OneOf == nil } func arrayToBeSkipped(op property) bool { - return op.Format == "array" && op.Items.Format == "object" && op.Items.Properties == nil + return op.Type == "array" && op.Items.Type == "object" && op.Items.Properties == nil } func anchorTaskObject(p interface{}, task readmeTask) string { @@ -646,9 +646,9 @@ func anchorTaskWithProperty(prop property, taskName string) string { if isSemiStructuredObject(prop) { return prop.Title } - if prop.Format == "object" || - (prop.Format == "array" && prop.Items.Format == "object") || - (prop.Format == "array[object]") { + if prop.Type == "object" || + (prop.Type == "array" && prop.Items.Type == "object") || + (prop.Type == "array[object]") { return fmt.Sprintf("[%s](#%s-%s)", prop.Title, blackfriday.SanitizedAnchorName(taskName), blackfriday.SanitizedAnchorName(prop.Title)) } return prop.Title @@ -706,10 +706,10 @@ func (prop *property) replaceDescription() { } func (prop *property) replaceFormat() { - if prop.Format == "*" { - prop.Format = "any" + if prop.Type == "*" { + prop.Type = "any" } - if prop.Format == "array" && prop.Items.Format == "*" { - prop.Format = "array[any]" + if prop.Type == "array" && prop.Items.Type == "*" { + prop.Type = "array[any]" } } diff --git a/pkg/component/tools/compogen/pkg/gen/resources/templates/readme.mdx.tmpl b/pkg/component/tools/compogen/pkg/gen/resources/templates/readme.mdx.tmpl index 9fb9337cb..f1a81c1f0 100644 --- a/pkg/component/tools/compogen/pkg/gen/resources/templates/readme.mdx.tmpl +++ b/pkg/component/tools/compogen/pkg/gen/resources/templates/readme.mdx.tmpl @@ -41,10 +41,10 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | {{- range . }} -| {{ anchorSetup . }}{{ if .Required }} (required){{- end }} | `{{ .ID }}` | {{ .Format }} | {{ .Description }} {{ if .Enum }} {{ enumValues .Enum }} {{ end }} | +| {{ anchorSetup . }}{{ if .Required }} (required){{- end }} | `{{ .ID }}` | {{ .Type }} | {{ .Description }} {{ if .Enum }} {{ enumValues .Enum }} {{ end }} | {{- end }} {{- end }} @@ -66,10 +66,10 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | {{- range $propKey, $prop := $option.Properties }} -| {{ anchorSetup $prop }} | `{{ $propKey }}` | {{ $prop.Format }} | {{ if $prop.Const }} Must be `"{{ $prop.Const }}"` {{ else }} {{ $prop.Description }} {{- end }} {{ if .Enum }} {{ enumValues .Enum }} {{ end }} | +| {{ anchorSetup $prop }} | `{{ $propKey }}` | {{ $prop.Type }} | {{ if $prop.Const }} Must be `"{{ $prop.Const }}"` {{ else }} {{ $prop.Description }} {{- end }} {{ if .Enum }} {{ enumValues .Enum }} {{ end }} | {{- end }}
{{- end }} @@ -88,11 +88,11 @@ ${connection.}`. {{ if $task.Input }}
-| Input | Field ID | Format | Description | +| Input | Field ID | Type | Description | | :--- | :--- | :--- | :--- | | Task ID (required) | `task` | string | `{{ $task.ID }}` | {{- range $task.Input }} -| {{ anchorTaskObject . $task }}{{ if .Required }} (required){{ end }} | `{{ .ID }}` | {{ .Format }} | {{ .Description }} {{- if .Enum }} {{ enumValues .Enum }} {{ end }} | +| {{ anchorTaskObject . $task }}{{ if .Required }} (required){{ end }} | `{{ .ID }}` | {{ .Type }} | {{ .Description }} {{- if .Enum }} {{ enumValues .Enum }} {{ end }} | {{- end }}
{{- end }} @@ -110,10 +110,10 @@ ${connection.}`. {{ end }}
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | {{- range $propKey, $prop := $schema.Properties }} -| {{ anchorTaskObject $prop $task }} | `{{ $propKey }}` | {{ $prop.Format }} | {{ $prop.Description }} {{ if .Enum }} {{ enumValues .Enum }} {{ end }} | +| {{ anchorTaskObject $prop $task }} | `{{ $propKey }}` | {{ $prop.Type }} | {{ $prop.Description }} {{ if .Enum }} {{ enumValues .Enum }} {{ end }} | {{- end }}
{{- end }} @@ -139,10 +139,10 @@ ${connection.}`. {{ end }}
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | {{- range $propKey, $prop := $option.Properties }} -| {{ $prop.Title }} | `{{ $propKey }}` | {{ $prop.Format }} | {{ if $prop.Const }} Must be `"{{ $prop.Const }}"` {{ else }} {{ $prop.Description }} {{- end }} {{ if .Enum }} {{ enumValues .Enum }} {{ end }} | +| {{ $prop.Title }} | `{{ $propKey }}` | {{ $prop.Type }} | {{ if $prop.Const }} Must be `"{{ $prop.Const }}"` {{ else }} {{ $prop.Description }} {{- end }} {{ if .Enum }} {{ enumValues .Enum }} {{ end }} | {{- end }}
{{- end }} @@ -155,10 +155,10 @@ ${connection.}`. {{ if $task.Output -}}
-| Output | Field ID | Format | Description | +| Output | Field ID | Type | Description | | :--- | :--- | :--- | :--- | {{- range $task.Output }} -| {{ anchorTaskObject . $task }}{{ if not .Required }} (optional){{- end }} | `{{ .ID }}` | {{ .Format }} | {{ .Description }} | +| {{ anchorTaskObject . $task }}{{ if not .Required }} (optional){{- end }} | `{{ .ID }}` | {{ .Type }} | {{ .Description }} | {{- end }}
{{- end }} @@ -173,10 +173,10 @@ ${connection.}`.
-| Field | Field ID | Format | Note | +| Field | Field ID | Type | Note | | :--- | :--- | :--- | :--- | {{- range $propKey, $prop := $schema.Properties }} -| {{ anchorTaskObject $prop $task }} | `{{ $propKey }}` | {{ $prop.Format }} | {{ $prop.Description }} | +| {{ anchorTaskObject $prop $task }} | `{{ $propKey }}` | {{ $prop.Type }} | {{ $prop.Description }} | {{- end }}
{{- end }} diff --git a/pkg/component/tools/compogen/pkg/gen/schema.go b/pkg/component/tools/compogen/pkg/gen/schema.go index 1b9e9cf25..f9ea22ce3 100644 --- a/pkg/component/tools/compogen/pkg/gen/schema.go +++ b/pkg/component/tools/compogen/pkg/gen/schema.go @@ -9,11 +9,11 @@ type property struct { Title string `json:"title" validate:"required"` Order *int `json:"uiOrder" validate:"required"` - Format string `json:"format"` + Type string `json:"type"` - // If Format is array, Items defines the element format. + // If Type is array, Items defines the element format. Items struct { - Format string `json:"format"` + Type string `json:"type"` Properties map[string]property `json:"properties" validate:"omitempty,dive"` OneOf []objectSchema `json:"oneOf" validate:"dive"` } `json:"items"` diff --git a/pkg/component/tools/compogen/pkg/gen/schema_test.go b/pkg/component/tools/compogen/pkg/gen/schema_test.go index ffc8aacfa..d33cdc9f2 100644 --- a/pkg/component/tools/compogen/pkg/gen/schema_test.go +++ b/pkg/component/tools/compogen/pkg/gen/schema_test.go @@ -21,13 +21,13 @@ func TestObjectSchema_Validate(t *testing.T) { "stringval": { Description: "a string", Title: "String Value", - Format: "string", + Type: "string", Order: &zero, }, "intval": { Description: "an integer number", Title: "Integer value", - Format: "integer", + Type: "integer", Order: &one, }, }, @@ -58,7 +58,7 @@ func TestObjectSchema_Validate(t *testing.T) { modifier: func(rs *objectSchema) { rs.Properties["wrong"] = property{ Description: "foo", - Format: "zoot", + Type: "zoot", Order: &two, } }, @@ -68,9 +68,9 @@ func TestObjectSchema_Validate(t *testing.T) { name: "nok - no description", modifier: func(rs *objectSchema) { rs.Properties["wrong"] = property{ - Title: "bar", - Format: "zot", - Order: &two, + Title: "bar", + Type: "zot", + Order: &two, } }, wantErr: `^objectSchema\.Properties\[wrong\]\.Description: Description field is required$`, @@ -81,7 +81,7 @@ func TestObjectSchema_Validate(t *testing.T) { rs.Properties["wrong"] = property{ Description: "foo", Title: "bar", - Format: "zot", + Type: "zot", } }, wantErr: `^objectSchema\.Properties\[wrong\]\.Order: Order field is required$`,