Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.
Python agentagentic-aiagentic-frameworkagentic-workflowaiautomationclaudedeepseekgenaigptllmlow-codemcpnextjsno-codeopenaipythonskillsworkflow
fix: clean unnecessary | None type annotations (#35557) (#36824)
Evan0fa43973b893
diff --git a/api/core/agent/base_agent_runner.py b/api/core/agent/base_agent_runner.pyindex 694d6331483..55a31563d69 100644--- a/api/core/agent/base_agent_runner.py+++ b/api/core/agent/base_agent_runner.py@@ -118,7 +118,7 @@ class BaseAgentRunner(AppRunner):features = model_schema.features if model_schema and model_schema.features else []self.stream_tool_call = ModelFeature.STREAM_TOOL_CALL in featuresself.files = application_generate_entity.files if ModelFeature.VISION in features else []- self.query: str | None = ""+ self.query: str = ""self._current_thoughts: list[PromptMessage] = []def _repack_app_generate_entity(diff --git a/api/core/app/entities/task_entities.py b/api/core/app/entities/task_entities.pyindex defec9f9461..803fdacf78d 100644--- a/api/core/app/entities/task_entities.py+++ b/api/core/app/entities/task_entities.py@@ -241,7 +241,7 @@ class WorkflowFinishStreamResponse(StreamResponse):created_by: Mapping[str, object] = Field(default_factory=dict)created_at: intfinished_at: int | None- exceptions_count: int | None = 0+ exceptions_count: int = 0files: Sequence[Mapping[str, Any]] | None = []event: StreamEvent = StreamEvent.WORKFLOW_FINISHEDdiff --git a/api/core/entities/provider_entities.py b/api/core/entities/provider_entities.pyindex ad9a1f4a02a..4c9cd858e13 100644--- a/api/core/entities/provider_entities.py+++ b/api/core/entities/provider_entities.py@@ -113,7 +113,7 @@ class CustomModelConfiguration(BaseModel):current_credential_id: str | None = Nonecurrent_credential_name: str | None = Noneavailable_model_credentials: list[CredentialConfiguration] = []- unadded_to_model_list: bool | None = False+ unadded_to_model_list: bool = False# pydantic configsmodel_config = ConfigDict(protected_namespaces=())@@ -209,7 +209,7 @@ class ProviderConfig(BasicProviderConfig):required: bool = Falsedefault: Union[int, str, float, bool] | None = Noneoptions: list[Option] | None = None- multiple: bool | None = False+ multiple: bool = Falselabel: I18nObject | None = Nonehelp: I18nObject | None = Noneurl: str | None = Nonediff --git a/api/core/plugin/entities/request.py b/api/core/plugin/entities/request.pyindex d47dac9eaf5..fecad81c032 100644--- a/api/core/plugin/entities/request.py+++ b/api/core/plugin/entities/request.py@@ -73,7 +73,7 @@ class RequestInvokeLLM(BaseRequestInvokeModel):prompt_messages: list[PromptMessage] = Field(default_factory=list)tools: list[PromptMessageTool] | None = Field(default_factory=list[PromptMessageTool])stop: list[str] | None = Field(default_factory=list[str])- stream: bool | None = False+ stream: bool = Falsemodel_config = ConfigDict(protected_namespaces=())diff --git a/api/core/trigger/entities/entities.py b/api/core/trigger/entities/entities.pyindex a922e881cdf..06a29bed111 100644--- a/api/core/trigger/entities/entities.py+++ b/api/core/trigger/entities/entities.py@@ -46,8 +46,8 @@ class EventParameter(BaseModel):)template: PluginParameterTemplate | None = Field(default=None, description="The template of the parameter")scope: str | None = None- required: bool | None = False- multiple: bool | None = Field(+ required: bool = False+ multiple: bool = Field(default=False,description="Whether the parameter is multiple select, only valid for select or dynamic-select type",)diff --git a/packages/contracts/generated/api/console/workspaces/types.gen.ts b/packages/contracts/generated/api/console/workspaces/types.gen.tsindex a404af0aa8a..59ee3242e75 100644--- a/packages/contracts/generated/api/console/workspaces/types.gen.ts+++ b/packages/contracts/generated/api/console/workspaces/types.gen.ts@@ -1238,7 +1238,7 @@ export type CustomModelConfiguration = {current_credential_name?: string | nullmodel: stringmodel_type: ModelType- unadded_to_model_list?: boolean | null+ unadded_to_model_list?: boolean}export type CredentialFormSchema = {diff --git a/packages/contracts/generated/api/console/workspaces/zod.gen.ts b/packages/contracts/generated/api/console/workspaces/zod.gen.tsindex 4e4627a4b3c..8c430ddec8b 100644--- a/packages/contracts/generated/api/console/workspaces/zod.gen.ts+++ b/packages/contracts/generated/api/console/workspaces/zod.gen.ts@@ -1531,7 +1531,7 @@ export const zCustomModelConfiguration = z.object({current_credential_name: z.string().nullish(),model: z.string(),model_type: zModelType,- unadded_to_model_list: z.boolean().nullish().default(false),+ unadded_to_model_list: z.boolean().optional().default(false),})/**