Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(docs): correct the CreateImage task example #24

Merged
merged 1 commit into from
Mar 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/main/java/io/kestra/plugin/openai/ChatCompletion.java
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@
@Getter
@NoArgsConstructor
@Schema(
title = "Given a prompt, get a response from an LLM using the [OpenAI’s Chat Completions API](https://platform.openai.com/docs/api-reference/chat/create)",
description = "For more information, refer to the [Chat Completions API docs](https://platform.openai.com/docs/guides/gpt/chat-completions-api)"
title = "Given a prompt, get a response from an LLM using the [OpenAI’s Chat Completions API](https://platform.openai.com/docs/api-reference/chat/create).",
description = "For more information, refer to the [Chat Completions API docs](https://platform.openai.com/docs/guides/gpt/chat-completions-api)."
)
@Plugin(
examples = {
@Example(
title = "Based on a prompt input, generate a completion response and pass it to a downstream task",
title = "Based on a prompt input, generate a completion response and pass it to a downstream task.",
full = true,
code = {
"id: openAI",
Expand Down
8 changes: 3 additions & 5 deletions src/main/java/io/kestra/plugin/openai/CreateImage.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,13 @@
@Getter
@NoArgsConstructor
@Schema(
title = "Given a prompt, create an image",
description = "For more information, refer to the [OpenAI Image Generation API docs](https://platform.openai.com/docs/api-reference/images/create)"
title = "Given a prompt, create an image.",
description = "For more information, refer to the [OpenAI Image Generation API docs](https://platform.openai.com/docs/api-reference/images/create)."
)
@Plugin(
examples = {
@Example(
code = """
id: imageGeneration
type: io.kestra.plugin.openai.CreateImage
prompt: A funny cat in a black suit
apiKey: <your-api-key>
download: true
Expand Down Expand Up @@ -108,7 +106,7 @@ public CreateImage.Output run(RunContext runContext) throws Exception {
public static class Output implements io.kestra.core.models.tasks.Output {

@Schema(
title = "Generated images"
title = "Generated images."
)
private List<URI> images;
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/io/kestra/plugin/openai/OpenAiInterface.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

public interface OpenAiInterface {
@Schema(
title = "The OpenAI API key"
title = "The OpenAI API key."
)
@PluginProperty(dynamic = true)
@NotNull
Expand Down