diff --git a/agents-api/agents_api/autogen/Agents.py b/agents-api/agents_api/autogen/Agents.py index a59cbeeaa..177e2a57f 100644 --- a/agents-api/agents_api/autogen/Agents.py +++ b/agents-api/agents_api/autogen/Agents.py @@ -57,7 +57,9 @@ class Agent(BaseModel): """ Default settings for all sessions created by this agent """ - default_system_template: str = '{%- if agent.name -%}\nYou are {{agent.name}}.{{" "}}\n{%- endif -%}\n\n{%- if agent.about -%}\nAbout you: {{agent.about}}.{{" "}}\n{%- endif -%}\n\n{%- if user -%}\nYou are talking to a user\n {%- if user.name -%}{{" "}} and their name is {{user.name}}\n {%- if user.about -%}. About the user: {{user.about}}.{%- else -%}.{%- endif -%}\n {%- endif -%}\n{%- endif -%}\n\n{{NEWLINE}}\n\n{%- if session.situation -%}\nSituation: {{session.situation}}\n{%- endif -%}\n\n{{NEWLINE+NEWLINE}}\n\n{%- if agent.instructions -%}\nInstructions:{{NEWLINE}}\n {%- if agent.instructions is string -%}\n {{agent.instructions}}{{NEWLINE}}\n {%- else -%}\n {%- for instruction in agent.instructions -%}\n - {{instruction}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{NEWLINE}}\n{%- endif -%}\n\n{%- if docs -%}\nRelevant documents:{{NEWLINE}}\n {%- for doc in docs -%}\n {{doc.title}}{{NEWLINE}}\n {%- if doc.content is string -%}\n {{doc.content}}{{NEWLINE}}\n {%- else -%}\n {%- for snippet in doc.content -%}\n {{snippet}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{"---"}}\n {%- endfor -%}\n{%- endif -%}' + default_system_template: str = ( + '{%- if agent.name -%}\nYou are {{agent.name}}.{{" "}}\n{%- endif -%}\n\n{%- if agent.about -%}\nAbout you: {{agent.about}}.{{" "}}\n{%- endif -%}\n\n{%- if user -%}\nYou are talking to a user\n {%- if user.name -%}{{" "}} and their name is {{user.name}}\n {%- if user.about -%}. About the user: {{user.about}}.{%- else -%}.{%- endif -%}\n {%- endif -%}\n{%- endif -%}\n\n{{NEWLINE}}\n\n{%- if session.situation -%}\nSituation: {{session.situation}}\n{%- endif -%}\n\n{{NEWLINE+NEWLINE}}\n\n{%- if agent.instructions -%}\nInstructions:{{NEWLINE}}\n {%- if agent.instructions is string -%}\n {{agent.instructions}}{{NEWLINE}}\n {%- else -%}\n {%- for instruction in agent.instructions -%}\n - {{instruction}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{NEWLINE}}\n{%- endif -%}\n\n{%- if docs -%}\nRelevant documents:{{NEWLINE}}\n {%- for doc in docs -%}\n {{doc.title}}{{NEWLINE}}\n {%- if doc.content is string -%}\n {{doc.content}}{{NEWLINE}}\n {%- else -%}\n {%- for snippet in doc.content -%}\n {{snippet}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{"---"}}\n {%- endfor -%}\n{%- endif -%}' + ) """ Default system template for all sessions created by this agent """ @@ -106,7 +108,9 @@ class CreateAgentRequest(BaseModel): """ Default settings for all sessions created by this agent """ - default_system_template: str = '{%- if agent.name -%}\nYou are {{agent.name}}.{{" "}}\n{%- endif -%}\n\n{%- if agent.about -%}\nAbout you: {{agent.about}}.{{" "}}\n{%- endif -%}\n\n{%- if user -%}\nYou are talking to a user\n {%- if user.name -%}{{" "}} and their name is {{user.name}}\n {%- if user.about -%}. About the user: {{user.about}}.{%- else -%}.{%- endif -%}\n {%- endif -%}\n{%- endif -%}\n\n{{NEWLINE}}\n\n{%- if session.situation -%}\nSituation: {{session.situation}}\n{%- endif -%}\n\n{{NEWLINE+NEWLINE}}\n\n{%- if agent.instructions -%}\nInstructions:{{NEWLINE}}\n {%- if agent.instructions is string -%}\n {{agent.instructions}}{{NEWLINE}}\n {%- else -%}\n {%- for instruction in agent.instructions -%}\n - {{instruction}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{NEWLINE}}\n{%- endif -%}\n\n{%- if docs -%}\nRelevant documents:{{NEWLINE}}\n {%- for doc in docs -%}\n {{doc.title}}{{NEWLINE}}\n {%- if doc.content is string -%}\n {{doc.content}}{{NEWLINE}}\n {%- else -%}\n {%- for snippet in doc.content -%}\n {{snippet}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{"---"}}\n {%- endfor -%}\n{%- endif -%}' + default_system_template: str = ( + '{%- if agent.name -%}\nYou are {{agent.name}}.{{" "}}\n{%- endif -%}\n\n{%- if agent.about -%}\nAbout you: {{agent.about}}.{{" "}}\n{%- endif -%}\n\n{%- if user -%}\nYou are talking to a user\n {%- if user.name -%}{{" "}} and their name is {{user.name}}\n {%- if user.about -%}. About the user: {{user.about}}.{%- else -%}.{%- endif -%}\n {%- endif -%}\n{%- endif -%}\n\n{{NEWLINE}}\n\n{%- if session.situation -%}\nSituation: {{session.situation}}\n{%- endif -%}\n\n{{NEWLINE+NEWLINE}}\n\n{%- if agent.instructions -%}\nInstructions:{{NEWLINE}}\n {%- if agent.instructions is string -%}\n {{agent.instructions}}{{NEWLINE}}\n {%- else -%}\n {%- for instruction in agent.instructions -%}\n - {{instruction}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{NEWLINE}}\n{%- endif -%}\n\n{%- if docs -%}\nRelevant documents:{{NEWLINE}}\n {%- for doc in docs -%}\n {{doc.title}}{{NEWLINE}}\n {%- if doc.content is string -%}\n {{doc.content}}{{NEWLINE}}\n {%- else -%}\n {%- for snippet in doc.content -%}\n {{snippet}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{"---"}}\n {%- endfor -%}\n{%- endif -%}' + ) """ Default system template for all sessions created by this agent """ @@ -152,7 +156,9 @@ class CreateOrUpdateAgentRequest(CreateAgentRequest): """ Default settings for all sessions created by this agent """ - default_system_template: str = '{%- if agent.name -%}\nYou are {{agent.name}}.{{" "}}\n{%- endif -%}\n\n{%- if agent.about -%}\nAbout you: {{agent.about}}.{{" "}}\n{%- endif -%}\n\n{%- if user -%}\nYou are talking to a user\n {%- if user.name -%}{{" "}} and their name is {{user.name}}\n {%- if user.about -%}. About the user: {{user.about}}.{%- else -%}.{%- endif -%}\n {%- endif -%}\n{%- endif -%}\n\n{{NEWLINE}}\n\n{%- if session.situation -%}\nSituation: {{session.situation}}\n{%- endif -%}\n\n{{NEWLINE+NEWLINE}}\n\n{%- if agent.instructions -%}\nInstructions:{{NEWLINE}}\n {%- if agent.instructions is string -%}\n {{agent.instructions}}{{NEWLINE}}\n {%- else -%}\n {%- for instruction in agent.instructions -%}\n - {{instruction}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{NEWLINE}}\n{%- endif -%}\n\n{%- if docs -%}\nRelevant documents:{{NEWLINE}}\n {%- for doc in docs -%}\n {{doc.title}}{{NEWLINE}}\n {%- if doc.content is string -%}\n {{doc.content}}{{NEWLINE}}\n {%- else -%}\n {%- for snippet in doc.content -%}\n {{snippet}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{"---"}}\n {%- endfor -%}\n{%- endif -%}' + default_system_template: str = ( + '{%- if agent.name -%}\nYou are {{agent.name}}.{{" "}}\n{%- endif -%}\n\n{%- if agent.about -%}\nAbout you: {{agent.about}}.{{" "}}\n{%- endif -%}\n\n{%- if user -%}\nYou are talking to a user\n {%- if user.name -%}{{" "}} and their name is {{user.name}}\n {%- if user.about -%}. About the user: {{user.about}}.{%- else -%}.{%- endif -%}\n {%- endif -%}\n{%- endif -%}\n\n{{NEWLINE}}\n\n{%- if session.situation -%}\nSituation: {{session.situation}}\n{%- endif -%}\n\n{{NEWLINE+NEWLINE}}\n\n{%- if agent.instructions -%}\nInstructions:{{NEWLINE}}\n {%- if agent.instructions is string -%}\n {{agent.instructions}}{{NEWLINE}}\n {%- else -%}\n {%- for instruction in agent.instructions -%}\n - {{instruction}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{NEWLINE}}\n{%- endif -%}\n\n{%- if docs -%}\nRelevant documents:{{NEWLINE}}\n {%- for doc in docs -%}\n {{doc.title}}{{NEWLINE}}\n {%- if doc.content is string -%}\n {{doc.content}}{{NEWLINE}}\n {%- else -%}\n {%- for snippet in doc.content -%}\n {{snippet}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{"---"}}\n {%- endfor -%}\n{%- endif -%}' + ) """ Default system template for all sessions created by this agent """ @@ -229,7 +235,9 @@ class PatchAgentRequest(BaseModel): """ Default settings for all sessions created by this agent """ - default_system_template: str = '{%- if agent.name -%}\nYou are {{agent.name}}.{{" "}}\n{%- endif -%}\n\n{%- if agent.about -%}\nAbout you: {{agent.about}}.{{" "}}\n{%- endif -%}\n\n{%- if user -%}\nYou are talking to a user\n {%- if user.name -%}{{" "}} and their name is {{user.name}}\n {%- if user.about -%}. About the user: {{user.about}}.{%- else -%}.{%- endif -%}\n {%- endif -%}\n{%- endif -%}\n\n{{NEWLINE}}\n\n{%- if session.situation -%}\nSituation: {{session.situation}}\n{%- endif -%}\n\n{{NEWLINE+NEWLINE}}\n\n{%- if agent.instructions -%}\nInstructions:{{NEWLINE}}\n {%- if agent.instructions is string -%}\n {{agent.instructions}}{{NEWLINE}}\n {%- else -%}\n {%- for instruction in agent.instructions -%}\n - {{instruction}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{NEWLINE}}\n{%- endif -%}\n\n{%- if docs -%}\nRelevant documents:{{NEWLINE}}\n {%- for doc in docs -%}\n {{doc.title}}{{NEWLINE}}\n {%- if doc.content is string -%}\n {{doc.content}}{{NEWLINE}}\n {%- else -%}\n {%- for snippet in doc.content -%}\n {{snippet}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{"---"}}\n {%- endfor -%}\n{%- endif -%}' + default_system_template: str = ( + '{%- if agent.name -%}\nYou are {{agent.name}}.{{" "}}\n{%- endif -%}\n\n{%- if agent.about -%}\nAbout you: {{agent.about}}.{{" "}}\n{%- endif -%}\n\n{%- if user -%}\nYou are talking to a user\n {%- if user.name -%}{{" "}} and their name is {{user.name}}\n {%- if user.about -%}. About the user: {{user.about}}.{%- else -%}.{%- endif -%}\n {%- endif -%}\n{%- endif -%}\n\n{{NEWLINE}}\n\n{%- if session.situation -%}\nSituation: {{session.situation}}\n{%- endif -%}\n\n{{NEWLINE+NEWLINE}}\n\n{%- if agent.instructions -%}\nInstructions:{{NEWLINE}}\n {%- if agent.instructions is string -%}\n {{agent.instructions}}{{NEWLINE}}\n {%- else -%}\n {%- for instruction in agent.instructions -%}\n - {{instruction}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{NEWLINE}}\n{%- endif -%}\n\n{%- if docs -%}\nRelevant documents:{{NEWLINE}}\n {%- for doc in docs -%}\n {{doc.title}}{{NEWLINE}}\n {%- if doc.content is string -%}\n {{doc.content}}{{NEWLINE}}\n {%- else -%}\n {%- for snippet in doc.content -%}\n {{snippet}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{"---"}}\n {%- endfor -%}\n{%- endif -%}' + ) """ Default system template for all sessions created by this agent """ @@ -278,7 +286,9 @@ class UpdateAgentRequest(BaseModel): """ Default settings for all sessions created by this agent """ - default_system_template: str = '{%- if agent.name -%}\nYou are {{agent.name}}.{{" "}}\n{%- endif -%}\n\n{%- if agent.about -%}\nAbout you: {{agent.about}}.{{" "}}\n{%- endif -%}\n\n{%- if user -%}\nYou are talking to a user\n {%- if user.name -%}{{" "}} and their name is {{user.name}}\n {%- if user.about -%}. About the user: {{user.about}}.{%- else -%}.{%- endif -%}\n {%- endif -%}\n{%- endif -%}\n\n{{NEWLINE}}\n\n{%- if session.situation -%}\nSituation: {{session.situation}}\n{%- endif -%}\n\n{{NEWLINE+NEWLINE}}\n\n{%- if agent.instructions -%}\nInstructions:{{NEWLINE}}\n {%- if agent.instructions is string -%}\n {{agent.instructions}}{{NEWLINE}}\n {%- else -%}\n {%- for instruction in agent.instructions -%}\n - {{instruction}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{NEWLINE}}\n{%- endif -%}\n\n{%- if docs -%}\nRelevant documents:{{NEWLINE}}\n {%- for doc in docs -%}\n {{doc.title}}{{NEWLINE}}\n {%- if doc.content is string -%}\n {{doc.content}}{{NEWLINE}}\n {%- else -%}\n {%- for snippet in doc.content -%}\n {{snippet}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{"---"}}\n {%- endfor -%}\n{%- endif -%}' + default_system_template: str = ( + '{%- if agent.name -%}\nYou are {{agent.name}}.{{" "}}\n{%- endif -%}\n\n{%- if agent.about -%}\nAbout you: {{agent.about}}.{{" "}}\n{%- endif -%}\n\n{%- if user -%}\nYou are talking to a user\n {%- if user.name -%}{{" "}} and their name is {{user.name}}\n {%- if user.about -%}. About the user: {{user.about}}.{%- else -%}.{%- endif -%}\n {%- endif -%}\n{%- endif -%}\n\n{{NEWLINE}}\n\n{%- if session.situation -%}\nSituation: {{session.situation}}\n{%- endif -%}\n\n{{NEWLINE+NEWLINE}}\n\n{%- if agent.instructions -%}\nInstructions:{{NEWLINE}}\n {%- if agent.instructions is string -%}\n {{agent.instructions}}{{NEWLINE}}\n {%- else -%}\n {%- for instruction in agent.instructions -%}\n - {{instruction}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{NEWLINE}}\n{%- endif -%}\n\n{%- if docs -%}\nRelevant documents:{{NEWLINE}}\n {%- for doc in docs -%}\n {{doc.title}}{{NEWLINE}}\n {%- if doc.content is string -%}\n {{doc.content}}{{NEWLINE}}\n {%- else -%}\n {%- for snippet in doc.content -%}\n {{snippet}}{{NEWLINE}}\n {%- endfor -%}\n {%- endif -%}\n {{"---"}}\n {%- endfor -%}\n{%- endif -%}' + ) """ Default system template for all sessions created by this agent """ diff --git a/agents-api/agents_api/autogen/Chat.py b/agents-api/agents_api/autogen/Chat.py index 3143e8a00..b097aeb9b 100644 --- a/agents-api/agents_api/autogen/Chat.py +++ b/agents-api/agents_api/autogen/Chat.py @@ -59,7 +59,9 @@ class BaseChatResponse(BaseModel): """ Background job IDs that may have been spawned from this interaction. """ - docs: Annotated[list[DocReference], Field(json_schema_extra={"readOnly": True})] = [] + docs: Annotated[list[DocReference], Field(json_schema_extra={"readOnly": True})] = ( + [] + ) """ Documents referenced for this request (for citation purposes). """ @@ -132,15 +134,21 @@ class CompletionUsage(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - completion_tokens: Annotated[int | None, Field(json_schema_extra={"readOnly": True})] = None + completion_tokens: Annotated[ + int | None, Field(json_schema_extra={"readOnly": True}) + ] = None """ Number of tokens in the generated completion """ - prompt_tokens: Annotated[int | None, Field(json_schema_extra={"readOnly": True})] = None + prompt_tokens: Annotated[ + int | None, Field(json_schema_extra={"readOnly": True}) + ] = None """ Number of tokens in the prompt """ - total_tokens: Annotated[int | None, Field(json_schema_extra={"readOnly": True})] = None + total_tokens: Annotated[int | None, Field(json_schema_extra={"readOnly": True})] = ( + None + ) """ Total number of tokens used in the request (prompt + completion) """ @@ -421,9 +429,9 @@ class MessageModel(BaseModel): """ Tool calls generated by the model. """ - created_at: Annotated[AwareDatetime | None, Field(json_schema_extra={"readOnly": True})] = ( - None - ) + created_at: Annotated[ + AwareDatetime | None, Field(json_schema_extra={"readOnly": True}) + ] = None """ When this resource was created as UTC date-time """ @@ -447,7 +455,9 @@ class RenderResponse(ChatInputData): model_config = ConfigDict( populate_by_name=True, ) - docs: Annotated[list[DocReference], Field(json_schema_extra={"readOnly": True})] = [] + docs: Annotated[list[DocReference], Field(json_schema_extra={"readOnly": True})] = ( + [] + ) """ Documents referenced for this request (for citation purposes). """ @@ -556,9 +566,9 @@ class ChatInput(ChatInputData): """ Modify the likelihood of specified tokens appearing in the completion """ - response_format: SimpleCompletionResponseFormat | SchemaCompletionResponseFormat | None = ( - None - ) + response_format: ( + SimpleCompletionResponseFormat | SchemaCompletionResponseFormat | None + ) = None """ Response format (set to `json_object` to restrict output to JSON) """ diff --git a/agents-api/agents_api/autogen/Docs.py b/agents-api/agents_api/autogen/Docs.py index 9e5507357..6e8609fed 100644 --- a/agents-api/agents_api/autogen/Docs.py +++ b/agents-api/agents_api/autogen/Docs.py @@ -97,13 +97,15 @@ class Doc(BaseModel): """ Language of the document """ - embedding_model: Annotated[str | None, Field(json_schema_extra={"readOnly": True})] = None + embedding_model: Annotated[ + str | None, Field(json_schema_extra={"readOnly": True}) + ] = None """ Embedding model used for the document """ - embedding_dimensions: Annotated[int | None, Field(json_schema_extra={"readOnly": True})] = ( - None - ) + embedding_dimensions: Annotated[ + int | None, Field(json_schema_extra={"readOnly": True}) + ] = None """ Dimensions of the embedding model """ diff --git a/agents-api/agents_api/autogen/Executions.py b/agents-api/agents_api/autogen/Executions.py index 6989af1dd..88053194b 100644 --- a/agents-api/agents_api/autogen/Executions.py +++ b/agents-api/agents_api/autogen/Executions.py @@ -190,7 +190,9 @@ class Transition(TransitionEvent): ) execution_id: Annotated[UUID, Field(json_schema_extra={"readOnly": True})] current: Annotated[TransitionTarget, Field(json_schema_extra={"readOnly": True})] - next: Annotated[TransitionTarget | None, Field(json_schema_extra={"readOnly": True})] + next: Annotated[ + TransitionTarget | None, Field(json_schema_extra={"readOnly": True}) + ] step_label: Annotated[ str | None, Field( diff --git a/agents-api/agents_api/autogen/Files.py b/agents-api/agents_api/autogen/Files.py index 5c1814699..aaebac9a6 100644 --- a/agents-api/agents_api/autogen/Files.py +++ b/agents-api/agents_api/autogen/Files.py @@ -31,7 +31,13 @@ class CreateFileRequest(BaseModel): """ Description of the file """ - mime_type: str | None = None + mime_type: Annotated[ + str | None, + Field( + max_length=120, + pattern="^(application|audio|font|example|image|message|model|multipart|text|video|x-(?:[0-9A-Za-z!#$%&'*+.^_`|~-]+))\\/([0-9A-Za-z!#$%&'*+.^_`|~-]+)$", + ), + ] = None """ MIME type of the file """ @@ -71,7 +77,13 @@ class File(BaseModel): """ Description of the file """ - mime_type: str | None = None + mime_type: Annotated[ + str | None, + Field( + max_length=120, + pattern="^(application|audio|font|example|image|message|model|multipart|text|video|x-(?:[0-9A-Za-z!#$%&'*+.^_`|~-]+))\\/([0-9A-Za-z!#$%&'*+.^_`|~-]+)$", + ), + ] = None """ MIME type of the file """ diff --git a/agents-api/agents_api/autogen/Responses.py b/agents-api/agents_api/autogen/Responses.py index f29dba192..ced6bfee8 100644 --- a/agents-api/agents_api/autogen/Responses.py +++ b/agents-api/agents_api/autogen/Responses.py @@ -93,7 +93,9 @@ class ComputerToolCall(BaseModel): """ An identifier used when responding to the tool call with output. """ - action: Click | DoubleClick | Drag | KeyPress | Move | Screenshot | Scroll | Type | Wait + action: ( + Click | DoubleClick | Drag | KeyPress | Move | Screenshot | Scroll | Type | Wait + ) """ The action to perform. """ @@ -226,7 +228,9 @@ class CreateResponse(BaseModel): reasoning: Reasoning | None = None text: Text | None = None tool_choice: Literal["auto", "none"] | ToolChoice | None = None - tools: list[FunctionTool | WebSearchTool | FileSearchTool | ComputerTool] | None = None + tools: list[FunctionTool | WebSearchTool | FileSearchTool | ComputerTool] | None = ( + None + ) truncation: Literal["disabled", "auto"] | None = None metadata: dict[str, Any] | None = None @@ -713,7 +717,9 @@ class Response(BaseModel): store: StrictBool = True temperature: float = 1 text: Text | None = None - tool_choice: ToolChoiceTypes | ToolChoiceFunction | Literal["auto", "none", "required"] + tool_choice: ( + ToolChoiceTypes | ToolChoiceFunction | Literal["auto", "none", "required"] + ) tools: list[FunctionTool | WebSearchTool | FileSearchTool | ComputerTool] top_p: float = 1 truncation: Literal["disabled", "auto"] @@ -922,7 +928,7 @@ class ToolChoiceTypes(BaseModel): Allowed values are: - `file_search` - - `web_search_preview` + - `web_search_preview` - `computer_use_preview` """ diff --git a/agents-api/agents_api/autogen/Sessions.py b/agents-api/agents_api/autogen/Sessions.py index 1937624db..f25ba7df5 100644 --- a/agents-api/agents_api/autogen/Sessions.py +++ b/agents-api/agents_api/autogen/Sessions.py @@ -47,6 +47,14 @@ class CreateSessionRequest(BaseModel): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal[ + "single_agent_no_user", + "single_agent_single_user", + "single_agent_multi_user", + "multi_agent_no_user", + "multi_agent_single_user", + "multi_agent_multi_user", + ] user: UUID | None = None """ User ID of user associated with this session @@ -89,7 +97,7 @@ class CreateSessionRequest(BaseModel): """ Whether to forward tool calls to the model """ - recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch | None = None + recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch = None """ Recall options for the session """ @@ -164,6 +172,17 @@ class PatchSessionRequest(BaseModel): model_config = ConfigDict( populate_by_name=True, ) + kind: ( + Literal[ + "single_agent_no_user", + "single_agent_single_user", + "single_agent_multi_user", + "multi_agent_no_user", + "multi_agent_single_user", + "multi_agent_multi_user", + ] + | None + ) = None situation: str | None = None """ Session situation @@ -197,7 +216,7 @@ class PatchSessionRequest(BaseModel): Whether to forward tool calls to the model """ recall_options: ( - VectorDocSearchUpdate | TextOnlyDocSearchUpdate | HybridDocSearchUpdate | None + VectorDocSearchUpdate | TextOnlyDocSearchUpdate | HybridDocSearchUpdate ) = None """ Recall options for the session @@ -209,6 +228,14 @@ class Session(BaseModel): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal[ + "single_agent_no_user", + "single_agent_single_user", + "single_agent_multi_user", + "multi_agent_no_user", + "multi_agent_single_user", + "multi_agent_multi_user", + ] situation: str | None = None """ Session situation @@ -245,7 +272,7 @@ class Session(BaseModel): """ Whether to forward tool calls to the model """ - recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch | None = None + recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch = None """ Recall options for the session """ @@ -259,16 +286,13 @@ class Session(BaseModel): """ When this resource was updated as UTC date-time """ - kind: str | None = None - """ - Discriminator property for Session. - """ class SingleAgentMultiUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["single_agent_multi_user"] = "single_agent_multi_user" agent: UUID users: Annotated[list[UUID], Field(min_length=2)] @@ -277,6 +301,7 @@ class SingleAgentNoUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["single_agent_no_user"] = "single_agent_no_user" agent: UUID @@ -284,6 +309,7 @@ class SingleAgentSingleUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["single_agent_single_user"] = "single_agent_single_user" agent: UUID user: UUID @@ -324,6 +350,14 @@ class UpdateSessionRequest(BaseModel): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal[ + "single_agent_no_user", + "single_agent_single_user", + "single_agent_multi_user", + "multi_agent_no_user", + "multi_agent_single_user", + "multi_agent_multi_user", + ] situation: str | None = None """ Session situation @@ -356,7 +390,7 @@ class UpdateSessionRequest(BaseModel): """ Whether to forward tool calls to the model """ - recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch | None = None + recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch = None """ Recall options for the session """ @@ -404,16 +438,14 @@ class CreateOrUpdateSessionRequest(CreateSessionRequest): populate_by_name=True, ) id: UUID - user: UUID | None = None - """ - User ID of user associated with this session - """ - users: list[UUID] | None = None - agent: UUID | None = None - """ - Agent ID of agent associated with this session - """ - agents: list[UUID] | None = None + kind: Literal[ + "single_agent_no_user", + "single_agent_single_user", + "single_agent_multi_user", + "multi_agent_no_user", + "multi_agent_single_user", + "multi_agent_multi_user", + ] situation: str | None = None """ Session situation @@ -446,7 +478,7 @@ class CreateOrUpdateSessionRequest(CreateSessionRequest): """ Whether to forward tool calls to the model """ - recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch | None = None + recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch = None """ Recall options for the session """ @@ -457,6 +489,7 @@ class MultiAgentMultiUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["multi_agent_multi_user"] = "multi_agent_multi_user" agents: Annotated[list[UUID], Field(min_length=2)] users: Annotated[list[UUID], Field(min_length=2)] @@ -465,6 +498,7 @@ class MultiAgentNoUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["multi_agent_no_user"] = "multi_agent_no_user" agents: Annotated[list[UUID], Field(min_length=2)] @@ -472,5 +506,6 @@ class MultiAgentSingleUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["multi_agent_single_user"] = "multi_agent_single_user" agents: Annotated[list[UUID], Field(min_length=2)] user: UUID diff --git a/agents-api/agents_api/autogen/Tasks.py b/agents-api/agents_api/autogen/Tasks.py index 19f7da507..dde103206 100644 --- a/agents-api/agents_api/autogen/Tasks.py +++ b/agents-api/agents_api/autogen/Tasks.py @@ -8,6 +8,7 @@ from pydantic import AwareDatetime, BaseModel, ConfigDict, Field, StrictBool +from .Common import JinjaTemplate from .Tools import ( ChosenBash20241022, ChosenComputer20241022, @@ -222,15 +223,15 @@ class Else(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["map_reduce"], Field(json_schema_extra={"readOnly": True})] = ( - "map_reduce" - ) + kind_: Annotated[ + Literal["map_reduce"], Field(json_schema_extra={"readOnly": True}) + ] = "map_reduce" """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -238,7 +239,15 @@ class Else(BaseModel): """ The variable to iterate over """ - map: EvaluateStep | ToolCallStep | PromptStep | GetStep | SetStep | LogStep | YieldStep + map: ( + EvaluateStep + | ToolCallStep + | PromptStep + | GetStep + | SetStep + | LogStep + | YieldStep + ) """ The steps to run for each iteration """ @@ -266,13 +275,13 @@ class ElseModel(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -312,13 +321,15 @@ class ErrorWorkflowStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["error"], Field(json_schema_extra={"readOnly": True})] = "error" + kind_: Annotated[Literal["error"], Field(json_schema_extra={"readOnly": True})] = ( + "error" + ) """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -332,15 +343,15 @@ class EvaluateStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["evaluate"], Field(json_schema_extra={"readOnly": True})] = ( - "evaluate" - ) + kind_: Annotated[ + Literal["evaluate"], Field(json_schema_extra={"readOnly": True}) + ] = "evaluate" """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -402,15 +413,15 @@ class ForeachStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["foreach"], Field(json_schema_extra={"readOnly": True})] = ( - "foreach" - ) + kind_: Annotated[ + Literal["foreach"], Field(json_schema_extra={"readOnly": True}) + ] = "foreach" """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -424,13 +435,13 @@ class ForeachStepUpdateItem(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -444,13 +455,15 @@ class GetStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["get"], Field(json_schema_extra={"readOnly": True})] = "get" + kind_: Annotated[Literal["get"], Field(json_schema_extra={"readOnly": True})] = ( + "get" + ) """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -464,15 +477,15 @@ class IfElseWorkflowStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["if_else"], Field(json_schema_extra={"readOnly": True})] = ( - "if_else" - ) + kind_: Annotated[ + Literal["if_else"], Field(json_schema_extra={"readOnly": True}) + ] = "if_else" """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -517,8 +530,7 @@ class IfElseWorkflowStep(BaseModel): | SwitchStep | ForeachStep | ParallelStep - | Else - | None, + | Else, Field(alias="else"), ] = None """ @@ -530,13 +542,13 @@ class IfElseWorkflowStepUpdateItem(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -581,8 +593,7 @@ class IfElseWorkflowStepUpdateItem(BaseModel): | SwitchStepUpdateItem | ForeachStepUpdateItem | ParallelStepUpdateItem - | ElseModel - | None, + | ElseModel, Field(alias="else"), ] = None """ @@ -612,13 +623,15 @@ class LogStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["log"], Field(json_schema_extra={"readOnly": True})] = "log" + kind_: Annotated[Literal["log"], Field(json_schema_extra={"readOnly": True})] = ( + "log" + ) """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -632,15 +645,15 @@ class Main(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["map_reduce"], Field(json_schema_extra={"readOnly": True})] = ( - "map_reduce" - ) + kind_: Annotated[ + Literal["map_reduce"], Field(json_schema_extra={"readOnly": True}) + ] = "map_reduce" """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -648,7 +661,15 @@ class Main(BaseModel): """ The variable to iterate over """ - map: EvaluateStep | ToolCallStep | PromptStep | GetStep | SetStep | LogStep | YieldStep + map: ( + EvaluateStep + | ToolCallStep + | PromptStep + | GetStep + | SetStep + | LogStep + | YieldStep + ) """ The steps to run for each iteration """ @@ -672,13 +693,13 @@ class MainModel(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -718,21 +739,27 @@ class ParallelStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["parallel"], Field(json_schema_extra={"readOnly": True})] = ( - "parallel" - ) + kind_: Annotated[ + Literal["parallel"], Field(json_schema_extra={"readOnly": True}) + ] = "parallel" """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ parallel: Annotated[ list[ - EvaluateStep | ToolCallStep | PromptStep | GetStep | SetStep | LogStep | YieldStep + EvaluateStep + | ToolCallStep + | PromptStep + | GetStep + | SetStep + | LogStep + | YieldStep ], Field(max_length=100), ] @@ -745,13 +772,13 @@ class ParallelStepUpdateItem(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -844,10 +871,7 @@ class PromptItem(BaseModel): The role of the message """ tool_call_id: str | None = None - content: Annotated[ - list[str] | list[Content | ContentModel | ContentModel1] | str | None, - Field(...), - ] + content: list[str] | list[Content | ContentModel | ContentModel1] | str """ The content parts of the message """ @@ -877,13 +901,15 @@ class PromptStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["prompt"], Field(json_schema_extra={"readOnly": True})] = "prompt" + kind_: Annotated[Literal["prompt"], Field(json_schema_extra={"readOnly": True})] = ( + "prompt" + ) """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -925,13 +951,13 @@ class PromptStepUpdateItem(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -973,13 +999,15 @@ class ReturnStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["return"], Field(json_schema_extra={"readOnly": True})] = "return" + kind_: Annotated[Literal["return"], Field(json_schema_extra={"readOnly": True})] = ( + "return" + ) """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -996,13 +1024,15 @@ class SetStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["set"], Field(json_schema_extra={"readOnly": True})] = "set" + kind_: Annotated[Literal["set"], Field(json_schema_extra={"readOnly": True})] = ( + "set" + ) """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -1038,13 +1068,15 @@ class SleepStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["sleep"], Field(json_schema_extra={"readOnly": True})] = "sleep" + kind_: Annotated[Literal["sleep"], Field(json_schema_extra={"readOnly": True})] = ( + "sleep" + ) """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -1070,13 +1102,15 @@ class SwitchStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["switch"], Field(json_schema_extra={"readOnly": True})] = "switch" + kind_: Annotated[Literal["switch"], Field(json_schema_extra={"readOnly": True})] = ( + "switch" + ) """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -1090,13 +1124,13 @@ class SwitchStepUpdateItem(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -1181,7 +1215,9 @@ class TaskTool(CreateToolRequest): model_config = ConfigDict( populate_by_name=True, ) - inherited: Annotated[StrictBool, Field(json_schema_extra={"readOnly": True})] = False + inherited: Annotated[StrictBool, Field(json_schema_extra={"readOnly": True})] = ( + False + ) """ Read-only: Whether the tool was inherited or not. Only applies within tasks. """ @@ -1195,15 +1231,15 @@ class Then(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["map_reduce"], Field(json_schema_extra={"readOnly": True})] = ( - "map_reduce" - ) + kind_: Annotated[ + Literal["map_reduce"], Field(json_schema_extra={"readOnly": True}) + ] = "map_reduce" """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -1211,7 +1247,15 @@ class Then(BaseModel): """ The variable to iterate over """ - map: EvaluateStep | ToolCallStep | PromptStep | GetStep | SetStep | LogStep | YieldStep + map: ( + EvaluateStep + | ToolCallStep + | PromptStep + | GetStep + | SetStep + | LogStep + | YieldStep + ) """ The steps to run for each iteration """ @@ -1239,13 +1283,13 @@ class ThenModel(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -1285,15 +1329,15 @@ class ToolCallStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["tool_call"], Field(json_schema_extra={"readOnly": True})] = ( - "tool_call" - ) + kind_: Annotated[ + Literal["tool_call"], Field(json_schema_extra={"readOnly": True}) + ] = "tool_call" """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -1429,15 +1473,15 @@ class WaitForInputStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["wait_for_input"], Field(json_schema_extra={"readOnly": True})] = ( - "wait_for_input" - ) + kind_: Annotated[ + Literal["wait_for_input"], Field(json_schema_extra={"readOnly": True}) + ] = "wait_for_input" """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -1451,13 +1495,15 @@ class YieldStep(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - kind_: Annotated[Literal["yield"], Field(json_schema_extra={"readOnly": True})] = "yield" + kind_: Annotated[Literal["yield"], Field(json_schema_extra={"readOnly": True})] = ( + "yield" + ) """ The kind of step """ - label: Annotated[str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$")] = ( - None - ) + label: Annotated[ + str | None, Field(max_length=120, pattern="^[^0-9]|^[0-9]+[^0-9].*$") + ] = None """ The label of this step for referencing it from other steps """ @@ -1467,7 +1513,8 @@ class YieldStep(BaseModel): VALIDATION: Should resolve to a defined subworkflow. """ arguments: ( - dict[str, list[str] | dict[str, str] | list[dict[str, str]] | str] | Literal["_"] + dict[str, list[str] | dict[str, str] | list[dict[str, str]] | str] + | Literal["_"] ) = "_" """ The input parameters for the subworkflow (defaults to last step output) diff --git a/agents-api/agents_api/autogen/Tools.py b/agents-api/agents_api/autogen/Tools.py index 78a86e492..059419216 100644 --- a/agents-api/agents_api/autogen/Tools.py +++ b/agents-api/agents_api/autogen/Tools.py @@ -12,6 +12,7 @@ BaseModel, ConfigDict, Field, + RootModel, StrictBool, ) @@ -394,50 +395,11 @@ class BaseIntegrationDef(BaseModel): """ -class BaseIntegrationDefUpdate(BaseModel): +class BaseIntegrationDefUpdate(BaseIntegrationDef): """ Integration definition """ - model_config = ConfigDict( - populate_by_name=True, - ) - provider: ( - Literal[ - "dummy", - "weather", - "wikipedia", - "spider", - "brave", - "browserbase", - "email", - "mailgun", - "remote_browser", - "llama_parse", - "ffmpeg", - "cloudinary", - "arxiv", - "unstructured", - "algolia", - ] - | None - ) = None - """ - The provider of the integration - """ - method: str | None = None - """ - The specific method of the integration to call - """ - setup: Any | None = None - """ - The setup parameters the integration accepts - """ - arguments: Any | None = None - """ - The arguments to pre-apply to the integration call - """ - class Bash20241022Def(BaseModel): model_config = ConfigDict( @@ -671,7 +633,9 @@ class BrowserbaseGetSessionLiveUrlsArguments(BrowserbaseGetSessionArguments): pass -class BrowserbaseGetSessionLiveUrlsArgumentsUpdate(BrowserbaseGetSessionArgumentsUpdate): +class BrowserbaseGetSessionLiveUrlsArgumentsUpdate( + BrowserbaseGetSessionArgumentsUpdate +): pass @@ -2076,9 +2040,9 @@ class SystemDefUpdate(BaseModel): model_config = ConfigDict( populate_by_name=True, ) - resource: Literal["agent", "user", "task", "execution", "doc", "session", "job"] | None = ( - None - ) + resource: ( + Literal["agent", "user", "task", "execution", "doc", "session", "job"] | None + ) = None """ Resource is the name of the resource to use """ @@ -2856,7 +2820,9 @@ class BrowserbaseCompleteSessionIntegrationDef(BaseBrowserbaseIntegrationDef): arguments: BrowserbaseCompleteSessionArguments | None = None -class BrowserbaseCompleteSessionIntegrationDefUpdate(BaseBrowserbaseIntegrationDefUpdate): +class BrowserbaseCompleteSessionIntegrationDefUpdate( + BaseBrowserbaseIntegrationDefUpdate +): """ browserbase complete session integration definition """ @@ -3006,7 +2972,9 @@ class BrowserbaseGetSessionLiveUrlsIntegrationDef(BaseBrowserbaseIntegrationDef) arguments: BrowserbaseGetSessionLiveUrlsArguments | None = None -class BrowserbaseGetSessionLiveUrlsIntegrationDefUpdate(BaseBrowserbaseIntegrationDefUpdate): +class BrowserbaseGetSessionLiveUrlsIntegrationDefUpdate( + BaseBrowserbaseIntegrationDefUpdate +): """ browserbase get session live urls integration definition """ diff --git a/integrations-service/integrations/autogen/Files.py b/integrations-service/integrations/autogen/Files.py index 5c1814699..aaebac9a6 100644 --- a/integrations-service/integrations/autogen/Files.py +++ b/integrations-service/integrations/autogen/Files.py @@ -31,7 +31,13 @@ class CreateFileRequest(BaseModel): """ Description of the file """ - mime_type: str | None = None + mime_type: Annotated[ + str | None, + Field( + max_length=120, + pattern="^(application|audio|font|example|image|message|model|multipart|text|video|x-(?:[0-9A-Za-z!#$%&'*+.^_`|~-]+))\\/([0-9A-Za-z!#$%&'*+.^_`|~-]+)$", + ), + ] = None """ MIME type of the file """ @@ -71,7 +77,13 @@ class File(BaseModel): """ Description of the file """ - mime_type: str | None = None + mime_type: Annotated[ + str | None, + Field( + max_length=120, + pattern="^(application|audio|font|example|image|message|model|multipart|text|video|x-(?:[0-9A-Za-z!#$%&'*+.^_`|~-]+))\\/([0-9A-Za-z!#$%&'*+.^_`|~-]+)$", + ), + ] = None """ MIME type of the file """ diff --git a/integrations-service/integrations/autogen/Sessions.py b/integrations-service/integrations/autogen/Sessions.py index 05a7925eb..160242db2 100644 --- a/integrations-service/integrations/autogen/Sessions.py +++ b/integrations-service/integrations/autogen/Sessions.py @@ -46,6 +46,14 @@ class CreateSessionRequest(BaseModel): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal[ + "single_agent_no_user", + "single_agent_single_user", + "single_agent_multi_user", + "multi_agent_no_user", + "multi_agent_single_user", + "multi_agent_multi_user", + ] user: UUID | None = None """ User ID of user associated with this session @@ -88,7 +96,7 @@ class CreateSessionRequest(BaseModel): """ Whether to forward tool calls to the model """ - recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch | None = None + recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch = None """ Recall options for the session """ @@ -163,6 +171,17 @@ class PatchSessionRequest(BaseModel): model_config = ConfigDict( populate_by_name=True, ) + kind: ( + Literal[ + "single_agent_no_user", + "single_agent_single_user", + "single_agent_multi_user", + "multi_agent_no_user", + "multi_agent_single_user", + "multi_agent_multi_user", + ] + | None + ) = None situation: str | None = None """ Session situation @@ -195,9 +214,9 @@ class PatchSessionRequest(BaseModel): """ Whether to forward tool calls to the model """ - recall_options: ( - VectorDocSearchUpdate | TextOnlyDocSearchUpdate | HybridDocSearchUpdate | None - ) = None + recall_options: VectorDocSearchUpdate | TextOnlyDocSearchUpdate | HybridDocSearchUpdate = ( + None + ) """ Recall options for the session """ @@ -208,6 +227,14 @@ class Session(BaseModel): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal[ + "single_agent_no_user", + "single_agent_single_user", + "single_agent_multi_user", + "multi_agent_no_user", + "multi_agent_single_user", + "multi_agent_multi_user", + ] situation: str | None = None """ Session situation @@ -244,7 +271,7 @@ class Session(BaseModel): """ Whether to forward tool calls to the model """ - recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch | None = None + recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch = None """ Recall options for the session """ @@ -258,16 +285,13 @@ class Session(BaseModel): """ When this resource was updated as UTC date-time """ - kind: str | None = None - """ - Discriminator property for Session. - """ class SingleAgentMultiUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["single_agent_multi_user"] = "single_agent_multi_user" agent: UUID users: Annotated[list[UUID], Field(min_length=2)] @@ -276,6 +300,7 @@ class SingleAgentNoUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["single_agent_no_user"] = "single_agent_no_user" agent: UUID @@ -283,6 +308,7 @@ class SingleAgentSingleUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["single_agent_single_user"] = "single_agent_single_user" agent: UUID user: UUID @@ -323,6 +349,14 @@ class UpdateSessionRequest(BaseModel): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal[ + "single_agent_no_user", + "single_agent_single_user", + "single_agent_multi_user", + "multi_agent_no_user", + "multi_agent_single_user", + "multi_agent_multi_user", + ] situation: str | None = None """ Session situation @@ -355,7 +389,7 @@ class UpdateSessionRequest(BaseModel): """ Whether to forward tool calls to the model """ - recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch | None = None + recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch = None """ Recall options for the session """ @@ -403,16 +437,14 @@ class CreateOrUpdateSessionRequest(CreateSessionRequest): populate_by_name=True, ) id: UUID - user: UUID | None = None - """ - User ID of user associated with this session - """ - users: list[UUID] | None = None - agent: UUID | None = None - """ - Agent ID of agent associated with this session - """ - agents: list[UUID] | None = None + kind: Literal[ + "single_agent_no_user", + "single_agent_single_user", + "single_agent_multi_user", + "multi_agent_no_user", + "multi_agent_single_user", + "multi_agent_multi_user", + ] situation: str | None = None """ Session situation @@ -445,7 +477,7 @@ class CreateOrUpdateSessionRequest(CreateSessionRequest): """ Whether to forward tool calls to the model """ - recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch | None = None + recall_options: VectorDocSearch | TextOnlyDocSearch | HybridDocSearch = None """ Recall options for the session """ @@ -456,6 +488,7 @@ class MultiAgentMultiUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["multi_agent_multi_user"] = "multi_agent_multi_user" agents: Annotated[list[UUID], Field(min_length=2)] users: Annotated[list[UUID], Field(min_length=2)] @@ -464,6 +497,7 @@ class MultiAgentNoUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["multi_agent_no_user"] = "multi_agent_no_user" agents: Annotated[list[UUID], Field(min_length=2)] @@ -471,5 +505,6 @@ class MultiAgentSingleUserSession(Session): model_config = ConfigDict( populate_by_name=True, ) + kind: Literal["multi_agent_single_user"] = "multi_agent_single_user" agents: Annotated[list[UUID], Field(min_length=2)] user: UUID diff --git a/integrations-service/integrations/autogen/Tasks.py b/integrations-service/integrations/autogen/Tasks.py index 6dee77a34..1a8de5b43 100644 --- a/integrations-service/integrations/autogen/Tasks.py +++ b/integrations-service/integrations/autogen/Tasks.py @@ -267,7 +267,7 @@ class ElseModel(BaseModel): """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -425,7 +425,7 @@ class ForeachStepUpdateItem(BaseModel): """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -512,8 +512,7 @@ class IfElseWorkflowStep(BaseModel): | SwitchStep | ForeachStep | ParallelStep - | Else - | None, + | Else, Field(alias="else"), ] = None """ @@ -531,7 +530,7 @@ class IfElseWorkflowStepUpdateItem(BaseModel): """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -576,8 +575,7 @@ class IfElseWorkflowStepUpdateItem(BaseModel): | SwitchStepUpdateItem | ForeachStepUpdateItem | ParallelStepUpdateItem - | ElseModel - | None, + | ElseModel, Field(alias="else"), ] = None """ @@ -673,7 +671,7 @@ class MainModel(BaseModel): """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -746,7 +744,7 @@ class ParallelStepUpdateItem(BaseModel): """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -839,10 +837,7 @@ class PromptItem(BaseModel): The role of the message """ tool_call_id: str | None = None - content: Annotated[ - list[str] | list[Content | ContentModel | ContentModel1] | str | None, - Field(...), - ] + content: list[str] | list[Content | ContentModel | ContentModel1] | str """ The content parts of the message """ @@ -926,7 +921,7 @@ class PromptStepUpdateItem(BaseModel): """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -1091,7 +1086,7 @@ class SwitchStepUpdateItem(BaseModel): """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ @@ -1240,7 +1235,7 @@ class ThenModel(BaseModel): """ The label of this step for referencing it from other steps """ - kind_: str | None = None + kind_: str """ Discriminator property for BaseWorkflowStep. """ diff --git a/integrations-service/integrations/autogen/Tools.py b/integrations-service/integrations/autogen/Tools.py index 5a872725a..8f7dd396b 100644 --- a/integrations-service/integrations/autogen/Tools.py +++ b/integrations-service/integrations/autogen/Tools.py @@ -394,49 +394,7 @@ class BaseIntegrationDef(BaseModel): """ -class BaseIntegrationDefUpdate(BaseModel): - """ - Integration definition - """ - - model_config = ConfigDict( - populate_by_name=True, - ) - provider: ( - Literal[ - "dummy", - "weather", - "wikipedia", - "spider", - "brave", - "browserbase", - "email", - "mailgun", - "remote_browser", - "llama_parse", - "ffmpeg", - "cloudinary", - "arxiv", - "unstructured", - "algolia", - ] - | None - ) = None - """ - The provider of the integration - """ - method: str | None = None - """ - The specific method of the integration to call - """ - setup: Any | None = None - """ - The setup parameters the integration accepts - """ - arguments: Any | None = None - """ - The arguments to pre-apply to the integration call - """ +BaseIntegrationDefUpdate = BaseIntegrationDef class Bash20241022Def(BaseModel): diff --git a/schemas/create_agent_request.json b/schemas/create_agent_request.json index fdf7713be..55f68ed42 100644 --- a/schemas/create_agent_request.json +++ b/schemas/create_agent_request.json @@ -86,6 +86,20 @@ "title": "Name", "type": "string" }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" + }, "updated_at": { "format": "date-time", "readOnly": true, @@ -459,6 +473,20 @@ ], "title": "Schema" }, + "secrets": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/SecretRef" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Secrets" + }, "timeout": { "anyOf": [ { @@ -622,6 +650,20 @@ ], "title": "Schema" }, + "secrets": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/SecretRefUpdate" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Secrets" + }, "timeout": { "anyOf": [ { @@ -3547,6 +3589,20 @@ "minLength": 1, "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "required": [ @@ -3691,6 +3747,20 @@ "pattern": "^[\\p{L}\\p{Nl}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]+[\\p{ID_Start}\\p{Mn}\\p{Mc}\\p{Nd}\\p{Pc}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]*$", "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "required": [ @@ -3773,6 +3843,20 @@ "minLength": 1, "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "required": [ @@ -3956,11 +4040,106 @@ "pattern": "^[\\p{L}\\p{Nl}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]+[\\p{ID_Start}\\p{Mn}\\p{Mc}\\p{Nd}\\p{Pc}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]*$", "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "title": "CreateOrUpdateUserRequest", "type": "object" }, + "CreateProjectRequest": { + "description": "Payload for creating a project", + "properties": { + "canonical_name": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Canonical Name" + }, + "metadata": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Metadata" + }, + "name": { + "maxLength": 255, + "minLength": 1, + "title": "Name", + "type": "string" + } + }, + "required": [ + "name" + ], + "title": "CreateProjectRequest", + "type": "object" + }, + "CreateSecretRequest": { + "properties": { + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "metadata": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Metadata" + }, + "name": { + "title": "Name", + "type": "string" + }, + "value": { + "title": "Value", + "type": "string" + } + }, + "required": [ + "name", + "value" + ], + "title": "CreateSecretRequest", + "type": "object" + }, "CreateSessionRequest": { "description": "Payload for creating a session", "properties": { @@ -4442,6 +4621,20 @@ "pattern": "^[\\p{L}\\p{Nl}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]+[\\p{ID_Start}\\p{Mn}\\p{Mc}\\p{Nd}\\p{Pc}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]*$", "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "title": "CreateUserRequest", @@ -5889,6 +6082,20 @@ "title": "Name", "type": "string" }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" + }, "size": { "minimum": 1.0, "readOnly": true, @@ -6869,6 +7076,22 @@ "title": "ListResponse[Execution]", "type": "object" }, + "ListResponse_Project_": { + "properties": { + "items": { + "items": { + "$ref": "#/$defs/Project" + }, + "title": "Items", + "type": "array" + } + }, + "required": [ + "items" + ], + "title": "ListResponse[Project]", + "type": "object" + }, "ListResponse_ResourceDeletedResponse_": { "properties": { "items": { @@ -8443,6 +8666,20 @@ } ], "title": "Name" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "title": "PatchAgentRequest", @@ -8756,11 +8993,87 @@ "pattern": "^[\\p{L}\\p{Nl}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]+[\\p{ID_Start}\\p{Mn}\\p{Mc}\\p{Nd}\\p{Pc}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]*$", "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "title": "PatchUserRequest", "type": "object" }, + "Project": { + "description": "Project model", + "properties": { + "canonical_name": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Canonical Name" + }, + "created_at": { + "format": "date-time", + "readOnly": true, + "title": "Created At", + "type": "string" + }, + "id": { + "format": "uuid", + "readOnly": true, + "title": "Id", + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Metadata" + }, + "name": { + "maxLength": 255, + "minLength": 1, + "title": "Name", + "type": "string" + }, + "updated_at": { + "format": "date-time", + "readOnly": true, + "title": "Updated At", + "type": "string" + } + }, + "required": [ + "id", + "created_at", + "updated_at", + "name" + ], + "title": "Project", + "type": "object" + }, "PromptItem-Input": { "properties": { "content": { @@ -9668,6 +9981,98 @@ "title": "SchemaCompletionResponseFormat", "type": "object" }, + "Secret": { + "description": "A secret that can be used in tasks and sessions", + "properties": { + "created_at": { + "format": "date-time", + "readOnly": true, + "title": "Created At", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "id": { + "format": "uuid", + "readOnly": true, + "title": "Id", + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Metadata" + }, + "name": { + "title": "Name", + "type": "string" + }, + "updated_at": { + "format": "date-time", + "readOnly": true, + "title": "Updated At", + "type": "string" + }, + "value": { + "title": "Value", + "type": "string" + } + }, + "required": [ + "id", + "created_at", + "updated_at", + "name", + "value" + ], + "title": "Secret", + "type": "object" + }, + "SecretRef": { + "properties": { + "name": { + "title": "Name", + "type": "string" + } + }, + "required": [ + "name" + ], + "title": "SecretRef", + "type": "object" + }, + "SecretRefUpdate": { + "properties": { + "name": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Name" + } + }, + "title": "SecretRefUpdate", + "type": "object" + }, "Session": { "properties": { "auto_run_tools": { @@ -12284,6 +12689,20 @@ "minLength": 1, "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "required": [ @@ -12292,6 +12711,46 @@ "title": "UpdateAgentRequest", "type": "object" }, + "UpdateSecretRequest": { + "properties": { + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "metadata": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Metadata" + }, + "name": { + "title": "Name", + "type": "string" + }, + "value": { + "title": "Value", + "type": "string" + } + }, + "required": [ + "name", + "value" + ], + "title": "UpdateSecretRequest", + "type": "object" + }, "UpdateSessionRequest": { "description": "Payload for updating a session", "properties": { @@ -12590,6 +13049,20 @@ "pattern": "^[\\p{L}\\p{Nl}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]+[\\p{ID_Start}\\p{Mn}\\p{Mc}\\p{Nd}\\p{Pc}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]*$", "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "title": "UpdateUserRequest", @@ -12632,6 +13105,20 @@ "title": "Name", "type": "string" }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" + }, "updated_at": { "format": "date-time", "readOnly": true, @@ -14016,6 +14503,20 @@ "minLength": 1, "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "required": [ diff --git a/schemas/create_task_request.json b/schemas/create_task_request.json index 05fe01152..afd397efe 100644 --- a/schemas/create_task_request.json +++ b/schemas/create_task_request.json @@ -86,6 +86,20 @@ "title": "Name", "type": "string" }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" + }, "updated_at": { "format": "date-time", "readOnly": true, @@ -459,6 +473,20 @@ ], "title": "Schema" }, + "secrets": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/SecretRef" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Secrets" + }, "timeout": { "anyOf": [ { @@ -622,6 +650,20 @@ ], "title": "Schema" }, + "secrets": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/SecretRefUpdate" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Secrets" + }, "timeout": { "anyOf": [ { @@ -3547,6 +3589,20 @@ "minLength": 1, "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "required": [ @@ -3691,6 +3747,20 @@ "pattern": "^[\\p{L}\\p{Nl}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]+[\\p{ID_Start}\\p{Mn}\\p{Mc}\\p{Nd}\\p{Pc}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]*$", "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "required": [ @@ -3773,6 +3843,20 @@ "minLength": 1, "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "required": [ @@ -3956,11 +4040,106 @@ "pattern": "^[\\p{L}\\p{Nl}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]+[\\p{ID_Start}\\p{Mn}\\p{Mc}\\p{Nd}\\p{Pc}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]*$", "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "title": "CreateOrUpdateUserRequest", "type": "object" }, + "CreateProjectRequest": { + "description": "Payload for creating a project", + "properties": { + "canonical_name": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Canonical Name" + }, + "metadata": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Metadata" + }, + "name": { + "maxLength": 255, + "minLength": 1, + "title": "Name", + "type": "string" + } + }, + "required": [ + "name" + ], + "title": "CreateProjectRequest", + "type": "object" + }, + "CreateSecretRequest": { + "properties": { + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "metadata": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Metadata" + }, + "name": { + "title": "Name", + "type": "string" + }, + "value": { + "title": "Value", + "type": "string" + } + }, + "required": [ + "name", + "value" + ], + "title": "CreateSecretRequest", + "type": "object" + }, "CreateSessionRequest": { "description": "Payload for creating a session", "properties": { @@ -4442,6 +4621,20 @@ "pattern": "^[\\p{L}\\p{Nl}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]+[\\p{ID_Start}\\p{Mn}\\p{Mc}\\p{Nd}\\p{Pc}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]*$", "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "title": "CreateUserRequest", @@ -5889,6 +6082,20 @@ "title": "Name", "type": "string" }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" + }, "size": { "minimum": 1.0, "readOnly": true, @@ -6869,6 +7076,22 @@ "title": "ListResponse[Execution]", "type": "object" }, + "ListResponse_Project_": { + "properties": { + "items": { + "items": { + "$ref": "#/$defs/Project" + }, + "title": "Items", + "type": "array" + } + }, + "required": [ + "items" + ], + "title": "ListResponse[Project]", + "type": "object" + }, "ListResponse_ResourceDeletedResponse_": { "properties": { "items": { @@ -8443,6 +8666,20 @@ } ], "title": "Name" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "title": "PatchAgentRequest", @@ -8756,11 +8993,87 @@ "pattern": "^[\\p{L}\\p{Nl}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]+[\\p{ID_Start}\\p{Mn}\\p{Mc}\\p{Nd}\\p{Pc}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]*$", "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "title": "PatchUserRequest", "type": "object" }, + "Project": { + "description": "Project model", + "properties": { + "canonical_name": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Canonical Name" + }, + "created_at": { + "format": "date-time", + "readOnly": true, + "title": "Created At", + "type": "string" + }, + "id": { + "format": "uuid", + "readOnly": true, + "title": "Id", + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Metadata" + }, + "name": { + "maxLength": 255, + "minLength": 1, + "title": "Name", + "type": "string" + }, + "updated_at": { + "format": "date-time", + "readOnly": true, + "title": "Updated At", + "type": "string" + } + }, + "required": [ + "id", + "created_at", + "updated_at", + "name" + ], + "title": "Project", + "type": "object" + }, "PromptItem-Input": { "properties": { "content": { @@ -9668,6 +9981,98 @@ "title": "SchemaCompletionResponseFormat", "type": "object" }, + "Secret": { + "description": "A secret that can be used in tasks and sessions", + "properties": { + "created_at": { + "format": "date-time", + "readOnly": true, + "title": "Created At", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "id": { + "format": "uuid", + "readOnly": true, + "title": "Id", + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Metadata" + }, + "name": { + "title": "Name", + "type": "string" + }, + "updated_at": { + "format": "date-time", + "readOnly": true, + "title": "Updated At", + "type": "string" + }, + "value": { + "title": "Value", + "type": "string" + } + }, + "required": [ + "id", + "created_at", + "updated_at", + "name", + "value" + ], + "title": "Secret", + "type": "object" + }, + "SecretRef": { + "properties": { + "name": { + "title": "Name", + "type": "string" + } + }, + "required": [ + "name" + ], + "title": "SecretRef", + "type": "object" + }, + "SecretRefUpdate": { + "properties": { + "name": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Name" + } + }, + "title": "SecretRefUpdate", + "type": "object" + }, "Session": { "properties": { "auto_run_tools": { @@ -12284,6 +12689,20 @@ "minLength": 1, "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "required": [ @@ -12292,6 +12711,46 @@ "title": "UpdateAgentRequest", "type": "object" }, + "UpdateSecretRequest": { + "properties": { + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "metadata": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Metadata" + }, + "name": { + "title": "Name", + "type": "string" + }, + "value": { + "title": "Value", + "type": "string" + } + }, + "required": [ + "name", + "value" + ], + "title": "UpdateSecretRequest", + "type": "object" + }, "UpdateSessionRequest": { "description": "Payload for updating a session", "properties": { @@ -12590,6 +13049,20 @@ "pattern": "^[\\p{L}\\p{Nl}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]+[\\p{ID_Start}\\p{Mn}\\p{Mc}\\p{Nd}\\p{Pc}\\p{Pattern_Syntax}\\p{Pattern_White_Space}]*$", "title": "Name", "type": "string" + }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" } }, "title": "UpdateUserRequest", @@ -12632,6 +13105,20 @@ "title": "Name", "type": "string" }, + "project": { + "anyOf": [ + { + "maxLength": 255, + "minLength": 1, + "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$", + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Project" + }, "updated_at": { "format": "date-time", "readOnly": true, diff --git a/typespec/MIGRATION_1.0.md b/typespec/MIGRATION_1.0.md new file mode 100644 index 000000000..9cc4b3cb8 --- /dev/null +++ b/typespec/MIGRATION_1.0.md @@ -0,0 +1,53 @@ +# TypeSpec 0.61.x to 1.1.0 Migration Summary + +## Changes Made + +### 1. Updated Dependencies +- Updated all `@typespec/*` packages from `0.61.x` to their latest stable versions: + - `@typespec/compiler`: `~1.1.0` + - `@typespec/http`: `~1.1.0` + - `@typespec/openapi`: `~1.1.0` + - `@typespec/openapi3`: `~1.1.0` + - `@typespec/events`: `~0.71.0` (preview) + - `@typespec/rest`: `~0.71.0` (preview) + - `@typespec/sse`: `~0.71.0` (preview) + - `@typespec/versioning`: `~0.71.0` (preview) + +### 2. Fixed Breaking Changes + +#### Visibility Decorators +- Changed from string-based visibility (`"read"`, `"create"`, `"update"`) to enum-based visibility +- Updated all `@visibility()` and `@withVisibility()` decorators to use `Lifecycle` enum members: + - `"read"` → `Lifecycle.Read` + - `"create"` → `Lifecycle.Create` + - `"update"` → `Lifecycle.Update` +- Removed `@visibility("none")` decorators as "none" is not a valid Lifecycle member + +#### Object Value Syntax +- Updated decorator arguments from model expressions to object values using `#{}` +- Changed `@service({...})` to `@service(#{...})` +- Changed `@info({...})` to `@info(#{...})` + +#### Service Decorator +- Removed `name` property from `@service` decorator (only `title` is supported in 1.0) + +#### Patch Operation +- Added `#{implicitOptionality: true}` to `@patch` decorators to maintain backward compatibility with the old implicit optional behavior + +### 3. Successfully Compiled +- TypeSpec now compiles without errors +- Generated OpenAPI 3.0 specification successfully +- All APIs remain compatible with existing implementations + +## Next Steps + +1. **Test Generated Code**: Run the full code generation pipeline to ensure Python models are generated correctly +2. **Verify API Compatibility**: Test that generated APIs maintain backward compatibility +3. **Update Documentation**: Update any documentation referencing TypeSpec version or syntax +4. **Monitor Deprecations**: Keep an eye on preview packages (`@typespec/events`, `@typespec/rest`, etc.) for future stable releases + +## Notes + +- The versioning system has changed from projection-based to mutator-based, but this doesn't affect our current usage +- Some packages (events, rest, sse, versioning) are still in preview (~0.71.0) while core packages are stable (1.1.0) +- The migration maintains full backward compatibility with the existing API structure \ No newline at end of file diff --git a/typespec/agents/models.tsp b/typespec/agents/models.tsp index 1f9f7a109..7a337dea9 100644 --- a/typespec/agents/models.tsp +++ b/typespec/agents/models.tsp @@ -45,7 +45,7 @@ model Agent { } /** Payload for updating a agent */ -@withVisibility("create", "update") +@withVisibility(Lifecycle.Create, Lifecycle.Update) model UpdateAgentRequest { ...Agent; } @@ -54,7 +54,7 @@ model UpdateAgentRequest { model PatchAgentRequest is UpdateAgentRequest {} /** Payload for creating a agent (and associated documents) */ -@withVisibility("create") +@withVisibility(Lifecycle.Create) model CreateAgentRequest { ...UpdateAgentRequest; } diff --git a/typespec/chat/models.tsp b/typespec/chat/models.tsp index 66fe4bcaf..0624c985e 100644 --- a/typespec/chat/models.tsp +++ b/typespec/chat/models.tsp @@ -35,7 +35,7 @@ enum FinishReason { /** Determines how the session accesses history and memories */ model MemoryAccessOptions { /** DISABLED: Whether this interaction should form new memories or not (will be enabled in a future release) */ - @visibility("read") // DISABLED + @visibility(Lifecycle.Read) // DISABLED remember: boolean = false; /** Whether previous memories and docs should be recalled or not */ @@ -144,15 +144,15 @@ model InputChatSettings extends InputDefaultChatSettings { /** Usage statistics for the completion request */ model CompletionUsage { /** Number of tokens in the generated completion */ - @visibility("read") + @visibility(Lifecycle.Read) completion_tokens?: uint32; /** Number of tokens in the prompt */ - @visibility("read") + @visibility(Lifecycle.Read) prompt_tokens?: uint32; /** Total number of tokens used in the request (prompt + completion) */ - @visibility("read") + @visibility(Lifecycle.Read) total_tokens?: uint32; } @@ -184,7 +184,7 @@ model BaseTokenLogProb { model TokenLogProb extends BaseTokenLogProb { /** The log probabilities of the tokens */ - @visibility("read") + @visibility(Lifecycle.Read) @minItems(1) top_logprobs: BaseTokenLogProb[]; } @@ -215,7 +215,7 @@ model SingleChatOutput extends BaseChatOutput { /** The output returned by the model. Note that, depending on the model provider, they might return more than one message. */ model MultipleChatOutput extends BaseChatOutput { - @visibility("read") + @visibility(Lifecycle.Read) @minItems(1) messages: ChatMLMessage[]; } @@ -233,11 +233,11 @@ model BaseChatResponse { usage?: CompletionUsage; /** Background job IDs that may have been spawned from this interaction. */ - @visibility("read") + @visibility(Lifecycle.Read) jobs: uuid[] = #[]; /** Documents referenced for this request (for citation purposes). */ - @visibility("read") + @visibility(Lifecycle.Read) docs: DocReference[] = #[]; ...HasCreatedAt; @@ -262,6 +262,6 @@ alias ChatResponse = ChunkChatResponse | MessageChatResponse; model RenderResponse extends ChatInputData { /** Documents referenced for this request (for citation purposes). */ - @visibility("read") + @visibility(Lifecycle.Read) docs: DocReference[] = #[]; } diff --git a/typespec/common/interfaces.tsp b/typespec/common/interfaces.tsp index dc37c7cc1..4f7db8bdc 100644 --- a/typespec/common/interfaces.tsp +++ b/typespec/common/interfaces.tsp @@ -83,7 +83,7 @@ interface PatchEndpoint< Type, DocString extends valueof string = "Patch resource by its id (merge changes with existing values)" > { - @patch + @patch(#{implicitOptionality: true}) @doc(DocString) patch( @path @@ -242,7 +242,7 @@ interface ChildPatchEndpoint< Type, DocString extends valueof string = "Patch a resource owned by the given parent using its id" > { - @patch + @patch(#{implicitOptionality: true}) @doc(DocString) patch( @path diff --git a/typespec/common/mixins.tsp b/typespec/common/mixins.tsp index 5d74cad1e..8e4c23844 100644 --- a/typespec/common/mixins.tsp +++ b/typespec/common/mixins.tsp @@ -1,6 +1,9 @@ +import "@typespec/http"; import "./scalars.tsp"; import "./types.tsp"; +using TypeSpec.Http; + namespace Common; // @@ -9,25 +12,25 @@ namespace Common; model HasCreatedAtOptional { /** When this resource was created as UTC date-time */ - @visibility("read") + @visibility(Lifecycle.Read) created_at?: utcDateTime; } model HasCreatedAt { /** When this resource was created as UTC date-time */ - @visibility("read") + @visibility(Lifecycle.Read) created_at: utcDateTime; } model HasUpdatedAt { /** When this resource was updated as UTC date-time */ - @visibility("read") + @visibility(Lifecycle.Read) updated_at: utcDateTime; } model HasDeletedAt { /** When this resource was deleted as UTC date-time */ - @visibility("read") + @visibility(Lifecycle.Read) deleted_at: utcDateTime; } @@ -37,12 +40,12 @@ model HasTimestamps { } model HasIdOptional { - @visibility("read") + @visibility(Lifecycle.Read) id?: uuid; } model HasId { - @visibility("read") + @visibility(Lifecycle.Read) @key id: uuid; } @@ -54,6 +57,6 @@ model HasMetadata { model HasJobs { /** IDs (if any) of jobs created as part of this request */ - @visibility("read") + @visibility(Lifecycle.Read) jobs: uuid[] = #[]; } \ No newline at end of file diff --git a/typespec/docs/models.tsp b/typespec/docs/models.tsp index 3aaa4f57e..70f21dc88 100644 --- a/typespec/docs/models.tsp +++ b/typespec/docs/models.tsp @@ -25,28 +25,28 @@ model Doc { content: string | string[]; /** Embeddings for the document */ - @visibility("read") + @visibility(Lifecycle.Read) embeddings: float32[] | float32[][] | null = null; - @visibility("read") + @visibility(Lifecycle.Read) /** Modality of the document */ modality?: string; - @visibility("read") + @visibility(Lifecycle.Read) /** Language of the document */ language?: string; - @visibility("read") + @visibility(Lifecycle.Read) /** Embedding model used for the document */ embedding_model?: string; - @visibility("read") + @visibility(Lifecycle.Read) /** Dimensions of the embedding model */ embedding_dimensions?: uint16; } /** Payload for creating a doc */ -@withVisibility("create") +@withVisibility(Lifecycle.Create) model CreateDocRequest { ...Doc; diff --git a/typespec/entries/models.tsp b/typespec/entries/models.tsp index 597d9b189..557a932a9 100644 --- a/typespec/entries/models.tsp +++ b/typespec/entries/models.tsp @@ -82,7 +82,7 @@ model ChatMLMessage { name?: string; /** Whether to continue this message or return a new one */ - @visibility("create") + @visibility(Lifecycle.Create) continue?: boolean; /** Tool calls generated by the model. */ @@ -92,7 +92,7 @@ model ChatMLMessage { ...HasIdOptional; } -@withVisibility("create") +@withVisibility(Lifecycle.Create) model InputChatMLMessage { ...ChatMLMessage; } diff --git a/typespec/executions/models.tsp b/typespec/executions/models.tsp index a867168c0..c18741806 100644 --- a/typespec/executions/models.tsp +++ b/typespec/executions/models.tsp @@ -40,11 +40,11 @@ alias ExecutionStatus = ( model Execution { /** The ID of the task that the execution is running */ - @visibility("read") + @visibility(Lifecycle.Read) task_id: Task.id; /** The status of the execution */ - @visibility("read") + @visibility(Lifecycle.Read) status: ExecutionStatus; /** The input to the execution */ @@ -85,7 +85,7 @@ model ExecutionStatusEvent { } /** Payload for creating an execution */ -@withVisibility("create") +@withVisibility(Lifecycle.Create) model CreateExecutionRequest { ...Execution; } @@ -147,26 +147,26 @@ model TransitionTarget { } model TransitionEvent { - @visibility("read") + @visibility(Lifecycle.Read) type: TransitionType; - @visibility("read") + @visibility(Lifecycle.Read) output: unknown; ...HasTimestamps; } model Transition extends TransitionEvent { - @visibility("read") + @visibility(Lifecycle.Read) execution_id: Execution.id; - @visibility("read") + @visibility(Lifecycle.Read) current: TransitionTarget; - @visibility("read") + @visibility(Lifecycle.Read) next: TransitionTarget | null; - @visibility("read") + @visibility(Lifecycle.Read) step_label?: stepLabel; ...HasId; diff --git a/typespec/files/models.tsp b/typespec/files/models.tsp index f3e978755..4310e5b26 100644 --- a/typespec/files/models.tsp +++ b/typespec/files/models.tsp @@ -28,17 +28,17 @@ model File { project?: canonicalName; /** Size of the file in bytes */ - @visibility("read") + @visibility(Lifecycle.Read) @minValue(1) size: uint64; /** Hash of the file */ - @visibility("read") + @visibility(Lifecycle.Read) hash: string; } /** Payload for creating a file */ -@withVisibility("create") +@withVisibility(Lifecycle.Create) model CreateFileRequest { ...File; } diff --git a/typespec/main.tsp b/typespec/main.tsp index ecbfb596d..7261805e8 100644 --- a/typespec/main.tsp +++ b/typespec/main.tsp @@ -29,19 +29,18 @@ using Versions; // /** Julep is a backend for creating stateful AI apps with background tasks and long-term memory easily. */ -@service({ - name: "julep-api", +@service(#{ title: "Julep API", }) @versioned(ApiVersions) -@info({ +@info(#{ termsOfService: "https://julep.ai/terms", - contact: { + contact: #{ name: "Julep AI", url: "https://julep.ai", email: "developers@julep.ai", }, - license: { + license: #{ name: "Apache 2.0", url: "https://www.apache.org/licenses/LICENSE-2.0.html", }, diff --git a/typespec/package-lock.json b/typespec/package-lock.json index 489de8fea..521ed2795 100644 --- a/typespec/package-lock.json +++ b/typespec/package-lock.json @@ -8,14 +8,40 @@ "name": "julep-typespec", "version": "0.4.0", "dependencies": { - "@typespec/compiler": "0.61.x", - "@typespec/events": "0.61.x", - "@typespec/http": "0.61.x", - "@typespec/openapi": "0.61.x", - "@typespec/openapi3": "0.61.x", - "@typespec/rest": "0.61.x", - "@typespec/sse": "0.61.x", - "@typespec/versioning": "0.61.x" + "@typespec/compiler": "~1.1.0", + "@typespec/events": "~0.71.0", + "@typespec/http": "~1.1.0", + "@typespec/openapi": "~1.1.0", + "@typespec/openapi3": "~1.1.0", + "@typespec/rest": "~0.71.0", + "@typespec/sse": "~0.71.0", + "@typespec/versioning": "~0.71.0" + } + }, + "node_modules/@apidevtools/json-schema-ref-parser": { + "version": "11.7.2", + "resolved": "https://registry.npmjs.org/@apidevtools/json-schema-ref-parser/-/json-schema-ref-parser-11.7.2.tgz", + "integrity": "sha512-4gY54eEGEstClvEkGnwVkTkrx0sqwemEFG5OSRRn3tD91XH0+Q8XIkYIfo7IwEWPpJZwILb9GUXeShtplRc/eA==", + "license": "MIT", + "dependencies": { + "@jsdevtools/ono": "^7.1.3", + "@types/json-schema": "^7.0.15", + "js-yaml": "^4.1.0" + }, + "engines": { + "node": ">= 16" + }, + "funding": { + "url": "https://github.com/sponsors/philsturgeon" + } + }, + "node_modules/@apidevtools/openapi-schemas": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@apidevtools/openapi-schemas/-/openapi-schemas-2.1.0.tgz", + "integrity": "sha512-Zc1AlqrJlX3SlpupFGpiLi2EbteyP7fXmUOGup6/DnkRgjP9bgMM/ag+n91rsv0U1Gpz0H3VILA/o3bW7Ua6BQ==", + "license": "MIT", + "engines": { + "node": ">=10" } }, "node_modules/@apidevtools/swagger-methods": { @@ -24,238 +50,416 @@ "integrity": "sha512-QAkD5kK2b1WfjDS/UQn/qQkbwF31uqRjPTrsCs5ZG9BQGAkjwvqGFjjPqAuzac/IYzpPtRzjCP1WrTuAIjMrXg==", "license": "MIT" }, + "node_modules/@apidevtools/swagger-parser": { + "version": "10.1.1", + "resolved": "https://registry.npmjs.org/@apidevtools/swagger-parser/-/swagger-parser-10.1.1.tgz", + "integrity": "sha512-u/kozRnsPO/x8QtKYJOqoGtC4kH6yg1lfYkB9Au0WhYB0FNLpyFusttQtvhlwjtG3rOwiRz4D8DnnXa8iEpIKA==", + "license": "MIT", + "dependencies": { + "@apidevtools/json-schema-ref-parser": "11.7.2", + "@apidevtools/openapi-schemas": "^2.1.0", + "@apidevtools/swagger-methods": "^3.0.2", + "@jsdevtools/ono": "^7.1.3", + "ajv": "^8.17.1", + "ajv-draft-04": "^1.0.0", + "call-me-maybe": "^1.0.2" + }, + "peerDependencies": { + "openapi-types": ">=7" + } + }, "node_modules/@babel/code-frame": { - "version": "7.26.2", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.26.2.tgz", - "integrity": "sha512-RJlIHRueQgwWitWgF8OdFYGZX328Ax5BCemNGlqHfplnRT9ESi8JkFlvaVYbS+UubVY6dpv87Fs2u5M29iNFVQ==", + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.27.1.tgz", + "integrity": "sha512-cjQ7ZlQ0Mv3b47hABuTevyTuYN4i+loJKGeV9flcCgIK37cCXRh+L1bd3iBHlynerhQ7BhCkn2BPbQUL+rGqFg==", "license": "MIT", "dependencies": { - "@babel/helper-validator-identifier": "^7.25.9", + "@babel/helper-validator-identifier": "^7.27.1", "js-tokens": "^4.0.0", - "picocolors": "^1.0.0" + "picocolors": "^1.1.1" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-validator-identifier": { - "version": "7.25.9", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.25.9.tgz", - "integrity": "sha512-Ed61U6XJc3CVRfkERJWDz4dJwKe7iLmmJsbOGu9wSloNSFttHV0I8g6UAgb7qnK5ly5bGLPd4oXZlxCdANBOWQ==", + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.27.1.tgz", + "integrity": "sha512-D2hP9eA+Sqx1kBZgzxZh0y1trbuU+JoDkiEwqhQ36nodYqJwyEIhPSdMNd7lOm/4io72luTPWH20Yda0xOuUow==", "license": "MIT", "engines": { "node": ">=6.9.0" } }, - "node_modules/@babel/highlight": { - "version": "7.25.9", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.25.9.tgz", - "integrity": "sha512-llL88JShoCsth8fF8R4SJnIn+WLvR6ccFxu1H3FlMhDontdcmZWf2HgIZ7AIqV3Xcck1idlohrN4EUBQz6klbw==", + "node_modules/@inquirer/checkbox": { + "version": "4.1.8", + "resolved": "https://registry.npmjs.org/@inquirer/checkbox/-/checkbox-4.1.8.tgz", + "integrity": "sha512-d/QAsnwuHX2OPolxvYcgSj7A9DO9H6gVOy2DvBTx+P2LH2iRTo/RSGV3iwCzW024nP9hw98KIuDmdyhZQj1UQg==", "license": "MIT", "dependencies": { - "@babel/helper-validator-identifier": "^7.25.9", - "chalk": "^2.4.2", - "js-tokens": "^4.0.0", - "picocolors": "^1.0.0" + "@inquirer/core": "^10.1.13", + "@inquirer/figures": "^1.0.12", + "@inquirer/type": "^3.0.7", + "ansi-escapes": "^4.3.2", + "yoctocolors-cjs": "^2.1.2" }, "engines": { - "node": ">=6.9.0" + "node": ">=18" + }, + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@babel/runtime": { - "version": "7.26.10", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.26.10.tgz", - "integrity": "sha512-2WJMeRQPHKSPemqk/awGrAiuFfzBmOIPXKizAsVhWH9YJqLZ0H+HS4c8loHGgW6utJ3E/ejXQUsiGaQy2NZ9Fw==", + "node_modules/@inquirer/confirm": { + "version": "5.1.12", + "resolved": "https://registry.npmjs.org/@inquirer/confirm/-/confirm-5.1.12.tgz", + "integrity": "sha512-dpq+ielV9/bqgXRUbNH//KsY6WEw9DrGPmipkpmgC1Y46cwuBTNx7PXFWTjc3MQ+urcc0QxoVHcMI0FW4Ok0hg==", "license": "MIT", "dependencies": { - "regenerator-runtime": "^0.14.0" + "@inquirer/core": "^10.1.13", + "@inquirer/type": "^3.0.7" }, "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@humanwhocodes/momoa": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@humanwhocodes/momoa/-/momoa-2.0.4.tgz", - "integrity": "sha512-RE815I4arJFtt+FVeU1Tgp9/Xvecacji8w/V6XtXsWWH/wz/eNkNbhb+ny/+PlVZjV0rxQpRSQKNKE3lcktHEA==", - "license": "Apache-2.0", - "engines": { - "node": ">=10.10.0" + "node": ">=18" + }, + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@jsdevtools/ono": { - "version": "7.1.3", - "resolved": "https://registry.npmjs.org/@jsdevtools/ono/-/ono-7.1.3.tgz", - "integrity": "sha512-4JQNk+3mVzK3xh2rqd6RB4J46qUR19azEHBneZyTZM+c456qOrbbM/5xcR8huNCCcbVt7+UmizG6GuUvPvKUYg==", - "license": "MIT" - }, - "node_modules/@nodelib/fs.scandir": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", - "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "node_modules/@inquirer/core": { + "version": "10.1.13", + "resolved": "https://registry.npmjs.org/@inquirer/core/-/core-10.1.13.tgz", + "integrity": "sha512-1viSxebkYN2nJULlzCxES6G9/stgHSepZ9LqqfdIGPHj5OHhiBUXVS0a6R0bEC2A+VL4D9w6QB66ebCr6HGllA==", "license": "MIT", "dependencies": { - "@nodelib/fs.stat": "2.0.5", - "run-parallel": "^1.1.9" + "@inquirer/figures": "^1.0.12", + "@inquirer/type": "^3.0.7", + "ansi-escapes": "^4.3.2", + "cli-width": "^4.1.0", + "mute-stream": "^2.0.0", + "signal-exit": "^4.1.0", + "wrap-ansi": "^6.2.0", + "yoctocolors-cjs": "^2.1.2" }, "engines": { - "node": ">= 8" + "node": ">=18" + }, + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@nodelib/fs.stat": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", - "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "node_modules/@inquirer/core/node_modules/wrap-ansi": { + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", + "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, "engines": { - "node": ">= 8" + "node": ">=8" } }, - "node_modules/@nodelib/fs.walk": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", - "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "node_modules/@inquirer/editor": { + "version": "4.2.13", + "resolved": "https://registry.npmjs.org/@inquirer/editor/-/editor-4.2.13.tgz", + "integrity": "sha512-WbicD9SUQt/K8O5Vyk9iC2ojq5RHoCLK6itpp2fHsWe44VxxcA9z3GTWlvjSTGmMQpZr+lbVmrxdHcumJoLbMA==", "license": "MIT", "dependencies": { - "@nodelib/fs.scandir": "2.1.5", - "fastq": "^1.6.0" + "@inquirer/core": "^10.1.13", + "@inquirer/type": "^3.0.7", + "external-editor": "^3.1.0" }, "engines": { - "node": ">= 8" + "node": ">=18" + }, + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@readme/better-ajv-errors": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/@readme/better-ajv-errors/-/better-ajv-errors-1.6.0.tgz", - "integrity": "sha512-9gO9rld84Jgu13kcbKRU+WHseNhaVt76wYMeRDGsUGYxwJtI3RmEJ9LY9dZCYQGI8eUZLuxb5qDja0nqklpFjQ==", - "license": "Apache-2.0", + "node_modules/@inquirer/expand": { + "version": "4.0.15", + "resolved": "https://registry.npmjs.org/@inquirer/expand/-/expand-4.0.15.tgz", + "integrity": "sha512-4Y+pbr/U9Qcvf+N/goHzPEXiHH8680lM3Dr3Y9h9FFw4gHS+zVpbj8LfbKWIb/jayIB4aSO4pWiBTrBYWkvi5A==", + "license": "MIT", "dependencies": { - "@babel/code-frame": "^7.16.0", - "@babel/runtime": "^7.21.0", - "@humanwhocodes/momoa": "^2.0.3", - "chalk": "^4.1.2", - "json-to-ast": "^2.0.3", - "jsonpointer": "^5.0.0", - "leven": "^3.1.0" + "@inquirer/core": "^10.1.13", + "@inquirer/type": "^3.0.7", + "yoctocolors-cjs": "^2.1.2" }, "engines": { - "node": ">=14" + "node": ">=18" }, "peerDependencies": { - "ajv": "4.11.8 - 8" + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@readme/better-ajv-errors/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@inquirer/figures": { + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/@inquirer/figures/-/figures-1.0.12.tgz", + "integrity": "sha512-MJttijd8rMFcKJC8NYmprWr6hD3r9Gd9qUC0XwPNwoEPWSMVJwA2MlXxF+nhZZNMY+HXsWa+o7KY2emWYIn0jQ==", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/@inquirer/input": { + "version": "4.1.12", + "resolved": "https://registry.npmjs.org/@inquirer/input/-/input-4.1.12.tgz", + "integrity": "sha512-xJ6PFZpDjC+tC1P8ImGprgcsrzQRsUh9aH3IZixm1lAZFK49UGHxM3ltFfuInN2kPYNfyoPRh+tU4ftsjPLKqQ==", "license": "MIT", "dependencies": { - "color-convert": "^2.0.1" + "@inquirer/core": "^10.1.13", + "@inquirer/type": "^3.0.7" }, "engines": { - "node": ">=8" + "node": ">=18" }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@readme/better-ajv-errors/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/@inquirer/number": { + "version": "3.0.15", + "resolved": "https://registry.npmjs.org/@inquirer/number/-/number-3.0.15.tgz", + "integrity": "sha512-xWg+iYfqdhRiM55MvqiTCleHzszpoigUpN5+t1OMcRkJrUrw7va3AzXaxvS+Ak7Gny0j2mFSTv2JJj8sMtbV2g==", "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@inquirer/core": "^10.1.13", + "@inquirer/type": "^3.0.7" }, "engines": { - "node": ">=10" + "node": ">=18" }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@readme/better-ajv-errors/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/@inquirer/password": { + "version": "4.0.15", + "resolved": "https://registry.npmjs.org/@inquirer/password/-/password-4.0.15.tgz", + "integrity": "sha512-75CT2p43DGEnfGTaqFpbDC2p2EEMrq0S+IRrf9iJvYreMy5mAWj087+mdKyLHapUEPLjN10mNvABpGbk8Wdraw==", "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@inquirer/core": "^10.1.13", + "@inquirer/type": "^3.0.7", + "ansi-escapes": "^4.3.2" }, "engines": { - "node": ">=7.0.0" + "node": ">=18" + }, + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@readme/better-ajv-errors/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT" - }, - "node_modules/@readme/better-ajv-errors/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/@inquirer/prompts": { + "version": "7.5.3", + "resolved": "https://registry.npmjs.org/@inquirer/prompts/-/prompts-7.5.3.tgz", + "integrity": "sha512-8YL0WiV7J86hVAxrh3fE5mDCzcTDe1670unmJRz6ArDgN+DBK1a0+rbnNWp4DUB5rPMwqD5ZP6YHl9KK1mbZRg==", "license": "MIT", + "dependencies": { + "@inquirer/checkbox": "^4.1.8", + "@inquirer/confirm": "^5.1.12", + "@inquirer/editor": "^4.2.13", + "@inquirer/expand": "^4.0.15", + "@inquirer/input": "^4.1.12", + "@inquirer/number": "^3.0.15", + "@inquirer/password": "^4.0.15", + "@inquirer/rawlist": "^4.1.3", + "@inquirer/search": "^3.0.15", + "@inquirer/select": "^4.2.3" + }, "engines": { - "node": ">=8" + "node": ">=18" + }, + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@readme/better-ajv-errors/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@inquirer/rawlist": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/@inquirer/rawlist/-/rawlist-4.1.3.tgz", + "integrity": "sha512-7XrV//6kwYumNDSsvJIPeAqa8+p7GJh7H5kRuxirct2cgOcSWwwNGoXDRgpNFbY/MG2vQ4ccIWCi8+IXXyFMZA==", "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "@inquirer/core": "^10.1.13", + "@inquirer/type": "^3.0.7", + "yoctocolors-cjs": "^2.1.2" }, "engines": { - "node": ">=8" + "node": ">=18" + }, + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@readme/json-schema-ref-parser": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@readme/json-schema-ref-parser/-/json-schema-ref-parser-1.2.0.tgz", - "integrity": "sha512-Bt3QVovFSua4QmHa65EHUmh2xS0XJ3rgTEUPH998f4OW4VVJke3BuS16f+kM0ZLOGdvIrzrPRqwihuv5BAjtrA==", + "node_modules/@inquirer/search": { + "version": "3.0.15", + "resolved": "https://registry.npmjs.org/@inquirer/search/-/search-3.0.15.tgz", + "integrity": "sha512-YBMwPxYBrADqyvP4nNItpwkBnGGglAvCLVW8u4pRmmvOsHUtCAUIMbUrLX5B3tFL1/WsLGdQ2HNzkqswMs5Uaw==", "license": "MIT", "dependencies": { - "@jsdevtools/ono": "^7.1.3", - "@types/json-schema": "^7.0.6", - "call-me-maybe": "^1.0.1", - "js-yaml": "^4.1.0" + "@inquirer/core": "^10.1.13", + "@inquirer/figures": "^1.0.12", + "@inquirer/type": "^3.0.7", + "yoctocolors-cjs": "^2.1.2" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@readme/openapi-parser": { - "version": "2.6.0", - "resolved": "https://registry.npmjs.org/@readme/openapi-parser/-/openapi-parser-2.6.0.tgz", - "integrity": "sha512-pyFJXezWj9WI1O+gdp95CoxfY+i+Uq3kKk4zXIFuRAZi9YnHpHOpjumWWr67wkmRTw19Hskh9spyY0Iyikf3fA==", + "node_modules/@inquirer/select": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/@inquirer/select/-/select-4.2.3.tgz", + "integrity": "sha512-OAGhXU0Cvh0PhLz9xTF/kx6g6x+sP+PcyTiLvCrewI99P3BBeexD+VbuwkNDvqGkk3y2h5ZiWLeRP7BFlhkUDg==", "license": "MIT", "dependencies": { - "@apidevtools/swagger-methods": "^3.0.2", - "@jsdevtools/ono": "^7.1.3", - "@readme/better-ajv-errors": "^1.6.0", - "@readme/json-schema-ref-parser": "^1.2.0", - "@readme/openapi-schemas": "^3.1.0", - "ajv": "^8.12.0", - "ajv-draft-04": "^1.0.0", - "call-me-maybe": "^1.0.1" + "@inquirer/core": "^10.1.13", + "@inquirer/figures": "^1.0.12", + "@inquirer/type": "^3.0.7", + "ansi-escapes": "^4.3.2", + "yoctocolors-cjs": "^2.1.2" }, "engines": { "node": ">=18" }, "peerDependencies": { - "openapi-types": ">=7" + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/@readme/openapi-schemas": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@readme/openapi-schemas/-/openapi-schemas-3.1.0.tgz", - "integrity": "sha512-9FC/6ho8uFa8fV50+FPy/ngWN53jaUu4GRXlAjcxIRrzhltJnpKkBG2Tp0IDraFJeWrOpk84RJ9EMEEYzaI1Bw==", + "node_modules/@inquirer/type": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/@inquirer/type/-/type-3.0.7.tgz", + "integrity": "sha512-PfunHQcjwnju84L+ycmcMKB/pTPIngjUJvfnRhKY6FKPuYXlM4aQCb/nIdTFR6BEhMjFvngzvng/vBAJMZpLSA==", "license": "MIT", "engines": { "node": ">=18" + }, + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } + } + }, + "node_modules/@isaacs/fs-minipass": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@isaacs/fs-minipass/-/fs-minipass-4.0.1.tgz", + "integrity": "sha512-wgm9Ehl2jpeqP3zw/7mo3kRHFp5MEDhqAdwy1fTGkHAwnkGOVsgpvQhL8B5n1qlb01jV3n/bI0ZfZp5lWA1k4w==", + "license": "ISC", + "dependencies": { + "minipass": "^7.0.4" + }, + "engines": { + "node": ">=18.0.0" + } + }, + "node_modules/@jsdevtools/ono": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/@jsdevtools/ono/-/ono-7.1.3.tgz", + "integrity": "sha512-4JQNk+3mVzK3xh2rqd6RB4J46qUR19azEHBneZyTZM+c456qOrbbM/5xcR8huNCCcbVt7+UmizG6GuUvPvKUYg==", + "license": "MIT" + }, + "node_modules/@nodelib/fs.scandir": { + "version": "2.1.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", + "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "license": "MIT", + "dependencies": { + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.stat": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", + "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "license": "MIT", + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.walk": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", + "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "license": "MIT", + "dependencies": { + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" + }, + "engines": { + "node": ">= 8" } }, "node_modules/@sindresorhus/merge-streams": { @@ -276,25 +480,40 @@ "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", "license": "MIT" }, + "node_modules/@typespec/asset-emitter": { + "version": "0.71.0", + "resolved": "https://registry.npmjs.org/@typespec/asset-emitter/-/asset-emitter-0.71.0.tgz", + "integrity": "sha512-wXDF2kbEPTJksv16mzcEyaz97PUxz1xH/Bl4OFSnvwE5xC1hkb0uKQ2nsunnu4yFzbz6Jmn7aoxM1WlYR5PzkA==", + "license": "MIT", + "engines": { + "node": ">=20.0.0" + }, + "peerDependencies": { + "@typespec/compiler": "^1.1.0" + } + }, "node_modules/@typespec/compiler": { - "version": "0.61.2", - "resolved": "https://registry.npmjs.org/@typespec/compiler/-/compiler-0.61.2.tgz", - "integrity": "sha512-6QxYJd09VWssd/BvY+8eBxTVv085s1UNK63FdPrgT2lgI+j8VMMcpNR9m5l1zWlgGDM7sniA/Or8VCdVA6jerg==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@typespec/compiler/-/compiler-1.1.0.tgz", + "integrity": "sha512-dtwosIqd2UUEEIVBR+oDiUtN4n1lP8/9GxQVno+wbkijQgKDj4Hg0Vaq6HG4BduF7RptDdtzkdGQCS9CgOIdRA==", "license": "MIT", "dependencies": { - "@babel/code-frame": "~7.24.7", + "@babel/code-frame": "~7.27.1", + "@inquirer/prompts": "^7.4.0", "ajv": "~8.17.1", "change-case": "~5.4.4", - "globby": "~14.0.2", + "env-paths": "^3.0.0", + "globby": "~14.1.0", + "is-unicode-supported": "^2.1.0", "mustache": "~4.2.0", - "picocolors": "~1.1.0", - "prettier": "~3.3.3", - "prompts": "~2.4.2", - "semver": "^7.6.3", - "temporal-polyfill": "^0.2.5", + "picocolors": "~1.1.1", + "prettier": "~3.5.3", + "semver": "^7.7.1", + "tar": "^7.4.3", + "temporal-polyfill": "^0.3.0", "vscode-languageserver": "~9.0.1", "vscode-languageserver-textdocument": "~1.0.12", - "yaml": "~2.5.1", + "yaml": "~2.7.0", "yargs": "~17.7.2" }, "bin": { @@ -302,45 +521,32 @@ "tsp-server": "cmd/tsp-server.js" }, "engines": { - "node": ">=18.0.0" - } - }, - "node_modules/@typespec/compiler/node_modules/@babel/code-frame": { - "version": "7.24.7", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.24.7.tgz", - "integrity": "sha512-BcYH1CVJBO9tvyIZ2jVeXgSIMvGZ2FDRvDdOIVQyuklNKSsx+eppDEBq/g47Ayw+RqNFE+URvOShmf+f/qwAlA==", - "license": "MIT", - "dependencies": { - "@babel/highlight": "^7.24.7", - "picocolors": "^1.0.0" - }, - "engines": { - "node": ">=6.9.0" + "node": ">=20.0.0" } }, "node_modules/@typespec/events": { - "version": "0.61.0", - "resolved": "https://registry.npmjs.org/@typespec/events/-/events-0.61.0.tgz", - "integrity": "sha512-XUXy36qGo7v1ZBEK5WTD3TGXc4xr9rbL5U5f7aCabad4YHTi6r/2GMOVjuRJOiCJoMvEVeL1pWkhDZkBPbdd3A==", + "version": "0.71.0", + "resolved": "https://registry.npmjs.org/@typespec/events/-/events-0.71.0.tgz", + "integrity": "sha512-dJeyqBGqTTSlFDVWpdqeMjDpEyRmenH3yDABK3T/30MrO94sdXigxmeBnPCcOaaqst6pV3anFuKwfAqEN3GnbA==", "license": "MIT", "engines": { - "node": ">=18.0.0" + "node": ">=20.0.0" }, "peerDependencies": { - "@typespec/compiler": "~0.61.0" + "@typespec/compiler": "^1.1.0" } }, "node_modules/@typespec/http": { - "version": "0.61.0", - "resolved": "https://registry.npmjs.org/@typespec/http/-/http-0.61.0.tgz", - "integrity": "sha512-7+AYHkzkc+p652GY9BcEbXY4OZa1fTr03MVmZeafvmbQbXfyzUU9eJld13M3v6NaUWqXWZ7nBNMISyKiXp/kSw==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@typespec/http/-/http-1.1.0.tgz", + "integrity": "sha512-1doVGmkv3N8l57fVuci4jGMZ61EZBlDzuNZO2b9o0+mexCOs/P96CIpFkaNVvTQgjpyFsW1DlXiUKAvUC9zQfg==", "license": "MIT", "engines": { - "node": ">=18.0.0" + "node": ">=20.0.0" }, "peerDependencies": { - "@typespec/compiler": "~0.61.0", - "@typespec/streams": "~0.61.0" + "@typespec/compiler": "^1.1.0", + "@typespec/streams": "^0.71.0" }, "peerDependenciesMeta": { "@typespec/streams": { @@ -349,91 +555,105 @@ } }, "node_modules/@typespec/openapi": { - "version": "0.61.0", - "resolved": "https://registry.npmjs.org/@typespec/openapi/-/openapi-0.61.0.tgz", - "integrity": "sha512-3AF319Ae4yGVOscsCLQeedXUJJcL/NdGOR2/e/nFiL/AOVdgLfIRnpR0Ad9Zj9XAESh1fq9XSu4Mi7N1k4V7rw==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@typespec/openapi/-/openapi-1.1.0.tgz", + "integrity": "sha512-HPvrpSS7eSVk3fEkWndcDTrAZssWRYv3FyDTqVqljildc7FAiXdo88+r5CCK8endmgIrES7uJdHLkcIGUZx1pg==", "license": "MIT", "engines": { - "node": ">=18.0.0" + "node": ">=20.0.0" }, "peerDependencies": { - "@typespec/compiler": "~0.61.0", - "@typespec/http": "~0.61.0" + "@typespec/compiler": "^1.1.0", + "@typespec/http": "^1.1.0" } }, "node_modules/@typespec/openapi3": { - "version": "0.61.0", - "resolved": "https://registry.npmjs.org/@typespec/openapi3/-/openapi3-0.61.0.tgz", - "integrity": "sha512-ALLsTkK1UiJBzvygV1Zk/yZaym+lOWroGeEUhQNXYShsq+/GLZkK0rl8sd76Gigq+TVXKMOEwUUvgfws/LMUJw==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@typespec/openapi3/-/openapi3-1.1.0.tgz", + "integrity": "sha512-+1Ue7+M/PkNX54H6SJAym5ONHzlW7s5ZnA4fCH5jwKvalvI94stMvefOpd8FAesJDVmXc3wZ0kiqYo5EuMTjOQ==", "license": "MIT", "dependencies": { - "@readme/openapi-parser": "~2.6.0", - "yaml": "~2.5.1" + "@apidevtools/swagger-parser": "~10.1.1", + "@typespec/asset-emitter": "^0.71.0", + "openapi-types": "~12.1.3", + "yaml": "~2.7.0" }, "bin": { "tsp-openapi3": "cmd/tsp-openapi3.js" }, "engines": { - "node": ">=18.0.0" + "node": ">=20.0.0" }, "peerDependencies": { - "@typespec/compiler": "~0.61.0", - "@typespec/http": "~0.61.0", - "@typespec/openapi": "~0.61.0", - "@typespec/versioning": "~0.61.0" + "@typespec/compiler": "^1.1.0", + "@typespec/http": "^1.1.0", + "@typespec/json-schema": "^1.1.0", + "@typespec/openapi": "^1.1.0", + "@typespec/versioning": "^0.71.0" + }, + "peerDependenciesMeta": { + "@typespec/json-schema": { + "optional": true + }, + "@typespec/versioning": { + "optional": true + }, + "@typespec/xml": { + "optional": true + } } }, "node_modules/@typespec/rest": { - "version": "0.61.0", - "resolved": "https://registry.npmjs.org/@typespec/rest/-/rest-0.61.0.tgz", - "integrity": "sha512-L9Oyor+l42p6S8GE+UvaZTi+dcu6WubGZKmaBRpX8mCZGsa69EgIK8DQoyxrfMcxAO4I5U0sfkzCKwCVFtRr9g==", + "version": "0.71.0", + "resolved": "https://registry.npmjs.org/@typespec/rest/-/rest-0.71.0.tgz", + "integrity": "sha512-5qX+nWO5Jx4P1iTTT2REgdCtHsTMjlv/gL90u8cO1ih3yHDtf18a41UL6jSYaVUIvIj6rlmrgopActf0FhhUcw==", "license": "MIT", "engines": { - "node": ">=18.0.0" + "node": ">=20.0.0" }, "peerDependencies": { - "@typespec/compiler": "~0.61.0", - "@typespec/http": "~0.61.0" + "@typespec/compiler": "^1.1.0", + "@typespec/http": "^1.1.0" } }, "node_modules/@typespec/sse": { - "version": "0.61.0", - "resolved": "https://registry.npmjs.org/@typespec/sse/-/sse-0.61.0.tgz", - "integrity": "sha512-q9wqMTqRDQkgID51o9lXWkrF9Ndn67sZznzGvKpCS6pG7eDc0cigkTWFmV2Agag9HzoP2MdFMlvU/sJKECPtfg==", + "version": "0.71.0", + "resolved": "https://registry.npmjs.org/@typespec/sse/-/sse-0.71.0.tgz", + "integrity": "sha512-4lAwDMj8h/50s6zp/8IX8CLW+H3P+od5O32Bb8+fyTabEo7+H3PbdBbIJGv9Sj7+l8+bZXsyfRXa+aJxR9o2ZA==", "license": "MIT", "engines": { - "node": ">=18.0.0" + "node": ">=20.0.0" }, "peerDependencies": { - "@typespec/compiler": "~0.61.0", - "@typespec/events": "~0.61.0", - "@typespec/http": "~0.61.0", - "@typespec/streams": "~0.61.0" + "@typespec/compiler": "^1.1.0", + "@typespec/events": "^0.71.0", + "@typespec/http": "^1.1.0", + "@typespec/streams": "^0.71.0" } }, "node_modules/@typespec/streams": { - "version": "0.61.0", - "resolved": "https://registry.npmjs.org/@typespec/streams/-/streams-0.61.0.tgz", - "integrity": "sha512-MEFwYmYVibuTwVwJ6UKa9kgM3AP5bn/MWIhB/dTgYicXEgbUk+o9RHqg7JsySFyL0PO9XoqQBFiJhWM758f+pQ==", + "version": "0.71.0", + "resolved": "https://registry.npmjs.org/@typespec/streams/-/streams-0.71.0.tgz", + "integrity": "sha512-ofyAcg8GnO6uTffGo00D6MMfRkqie4QtnUUSGNC1Bam2WG+wkeSG/huP0WNRT8GofzK1N0M6QqQwAW/vdq9ymQ==", "license": "MIT", "peer": true, "engines": { - "node": ">=18.0.0" + "node": ">=20.0.0" }, "peerDependencies": { - "@typespec/compiler": "~0.61.0" + "@typespec/compiler": "^1.1.0" } }, "node_modules/@typespec/versioning": { - "version": "0.61.0", - "resolved": "https://registry.npmjs.org/@typespec/versioning/-/versioning-0.61.0.tgz", - "integrity": "sha512-PIIug6eg3zc7E+BBHyNHHQD+OBq3FU465nhKrLEp35iVji/sYFuPc1ywnELDuwJVRWm6nvqNL1vtnc+4lEk+oA==", + "version": "0.71.0", + "resolved": "https://registry.npmjs.org/@typespec/versioning/-/versioning-0.71.0.tgz", + "integrity": "sha512-8qknFLOpZTVzQ+SveXg9G7WJV8P80yxLlj0nOc3ZLBKiPgM6FF7vGWHRNtnh7s3gSXvWyxopaJ9fZSLZSJmbww==", "license": "MIT", "engines": { - "node": ">=18.0.0" + "node": ">=20.0.0" }, "peerDependencies": { - "@typespec/compiler": "~0.61.0" + "@typespec/compiler": "^1.1.0" } }, "node_modules/ajv": { @@ -466,6 +686,21 @@ } } }, + "node_modules/ansi-escapes": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", + "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", + "license": "MIT", + "dependencies": { + "type-fest": "^0.21.3" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/ansi-regex": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", @@ -476,15 +711,18 @@ } }, "node_modules/ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "license": "MIT", "dependencies": { - "color-convert": "^1.9.0" + "color-convert": "^2.0.1" }, "engines": { - "node": ">=4" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, "node_modules/argparse": { @@ -511,26 +749,36 @@ "integrity": "sha512-HpX65o1Hnr9HH25ojC1YGs7HCQLq0GCOibSaWER0eNpgJ/Z1MZv2mTc7+xh6WOPxbRVcmgbv4hGU+uSQ/2xFZQ==", "license": "MIT" }, - "node_modules/chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "license": "MIT", - "dependencies": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - }, - "engines": { - "node": ">=4" - } - }, "node_modules/change-case": { "version": "5.4.4", "resolved": "https://registry.npmjs.org/change-case/-/change-case-5.4.4.tgz", "integrity": "sha512-HRQyTk2/YPEkt9TnUPbOpr64Uw3KOicFWPVBb+xiHvd6eBx/qPr9xqfBFDT8P2vWsvvz4jbEkfDe71W3VyNu2w==", "license": "MIT" }, + "node_modules/chardet": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz", + "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==", + "license": "MIT" + }, + "node_modules/chownr": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-3.0.0.tgz", + "integrity": "sha512-+IxzY9BZOQd/XuYPRmrvEVjF/nqj5kgT4kEq7VofrDoM1MxoRjEWkrCC3EtLi59TVawxTAn+orJwFQcrqEN1+g==", + "license": "BlueOak-1.0.0", + "engines": { + "node": ">=18" + } + }, + "node_modules/cli-width": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/cli-width/-/cli-width-4.1.0.tgz", + "integrity": "sha512-ouuZd4/dm2Sw5Gmqy6bGyNNNe1qt9RpmxveLSO7KcgsTnU7RXfsw+/bukWGo1abgBiMAic068rclZsO4IWmmxQ==", + "license": "ISC", + "engines": { + "node": ">= 12" + } + }, "node_modules/cliui": { "version": "8.0.1", "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", @@ -545,28 +793,22 @@ "node": ">=12" } }, - "node_modules/code-error-fragment": { - "version": "0.0.230", - "resolved": "https://registry.npmjs.org/code-error-fragment/-/code-error-fragment-0.0.230.tgz", - "integrity": "sha512-cadkfKp6932H8UkhzE/gcUqhRMNf8jHzkAN7+5Myabswaghu4xABTgPHDCjW+dBAJxj/SpkTYokpzDqY4pCzQw==", - "license": "MIT", - "engines": { - "node": ">= 4" - } - }, "node_modules/color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "license": "MIT", "dependencies": { - "color-name": "1.1.3" + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" } }, "node_modules/color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "license": "MIT" }, "node_modules/emoji-regex": { @@ -575,6 +817,18 @@ "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "license": "MIT" }, + "node_modules/env-paths": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-3.0.0.tgz", + "integrity": "sha512-dtJUTepzMW3Lm/NPxRf3wP4642UWhjL2sQxc+ym2YMj1m/H2zDNQOlezafzkHwn6sMstjHTwG6iQQsctDW/b1A==", + "license": "MIT", + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/escalade": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", @@ -584,13 +838,18 @@ "node": ">=6" } }, - "node_modules/escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "node_modules/external-editor": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz", + "integrity": "sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==", "license": "MIT", + "dependencies": { + "chardet": "^0.7.0", + "iconv-lite": "^0.4.24", + "tmp": "^0.0.33" + }, "engines": { - "node": ">=0.8.0" + "node": ">=4" } }, "node_modules/fast-deep-equal": { @@ -622,9 +881,9 @@ "license": "MIT" }, "node_modules/fastq": { - "version": "1.17.1", - "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.17.1.tgz", - "integrity": "sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==", + "version": "1.19.1", + "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.19.1.tgz", + "integrity": "sha512-GwLTyxkCXjXbxqIhTsMI2Nui8huMPtnxg7krajPJAjnEG/iiOS7i+zCtWGZR9G0NBKbXKh6X9m9UIsYX/N6vvQ==", "license": "ISC", "dependencies": { "reusify": "^1.0.4" @@ -664,17 +923,17 @@ } }, "node_modules/globby": { - "version": "14.0.2", - "resolved": "https://registry.npmjs.org/globby/-/globby-14.0.2.tgz", - "integrity": "sha512-s3Fq41ZVh7vbbe2PN3nrW7yC7U7MFVc5c98/iTl9c2GawNMKx/J648KQRW6WKkuU8GIbbh2IXfIRQjOZnXcTnw==", + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/globby/-/globby-14.1.0.tgz", + "integrity": "sha512-0Ia46fDOaT7k4og1PDW4YbodWWr3scS2vAr2lTbsplOt2WkKp0vQbkI9wKis/T5LV/dqPjO3bpS/z6GTJB82LA==", "license": "MIT", "dependencies": { "@sindresorhus/merge-streams": "^2.1.0", - "fast-glob": "^3.3.2", - "ignore": "^5.2.4", - "path-type": "^5.0.0", + "fast-glob": "^3.3.3", + "ignore": "^7.0.3", + "path-type": "^6.0.0", "slash": "^5.1.0", - "unicorn-magic": "^0.1.0" + "unicorn-magic": "^0.3.0" }, "engines": { "node": ">=18" @@ -683,25 +942,22 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/grapheme-splitter": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/grapheme-splitter/-/grapheme-splitter-1.0.4.tgz", - "integrity": "sha512-bzh50DW9kTPM00T8y4o8vQg89Di9oLJVLW/KaOGIXJWP/iqCN6WKYkbNOF04vFLJhwcpYUh9ydh/+5vpOqV4YQ==", - "license": "MIT" - }, - "node_modules/has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "node_modules/iconv-lite": { + "version": "0.4.24", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", + "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", "license": "MIT", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3" + }, "engines": { - "node": ">=4" + "node": ">=0.10.0" } }, "node_modules/ignore": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz", - "integrity": "sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==", + "version": "7.0.5", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.5.tgz", + "integrity": "sha512-Hs59xBNfUIunMFgWAbGX5cq6893IbWg4KnrjbYwX3tx0ztorVgTDA6B2sxf8ejHJ4wz8BqGUMYlnzNBer5NvGg==", "license": "MIT", "engines": { "node": ">= 4" @@ -746,6 +1002,18 @@ "node": ">=0.12.0" } }, + "node_modules/is-unicode-supported": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-2.1.0.tgz", + "integrity": "sha512-mE00Gnza5EEB3Ds0HfMyllZzbBrmLOX3vfWoj9A9PEnTfratQ/BcaJOuMhnkhjXvb2+FkY3VuHqtAGpTPmglFQ==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -770,46 +1038,6 @@ "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", "license": "MIT" }, - "node_modules/json-to-ast": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/json-to-ast/-/json-to-ast-2.1.0.tgz", - "integrity": "sha512-W9Lq347r8tA1DfMvAGn9QNcgYm4Wm7Yc+k8e6vezpMnRT+NHbtlxgNBXRVjXe9YM6eTn6+p/MKOlV/aABJcSnQ==", - "license": "MIT", - "dependencies": { - "code-error-fragment": "0.0.230", - "grapheme-splitter": "^1.0.4" - }, - "engines": { - "node": ">= 4" - } - }, - "node_modules/jsonpointer": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/jsonpointer/-/jsonpointer-5.0.1.tgz", - "integrity": "sha512-p/nXbhSEcu3pZRdkW1OfJhpsVtW1gd4Wa1fnQc9YLiTfAjn0312eMKimbdIQzuZl9aa9xUGaRlP9T/CJE/ditQ==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/kleur": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/kleur/-/kleur-3.0.3.tgz", - "integrity": "sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/leven": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", - "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, "node_modules/merge2": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", @@ -832,6 +1060,42 @@ "node": ">=8.6" } }, + "node_modules/minipass": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz", + "integrity": "sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==", + "license": "ISC", + "engines": { + "node": ">=16 || 14 >=14.17" + } + }, + "node_modules/minizlib": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-3.0.2.tgz", + "integrity": "sha512-oG62iEk+CYt5Xj2YqI5Xi9xWUeZhDI8jjQmC5oThVH5JGCTgIjr7ciJDzC7MBzYd//WvR1OTmP5Q38Q8ShQtVA==", + "license": "MIT", + "dependencies": { + "minipass": "^7.1.2" + }, + "engines": { + "node": ">= 18" + } + }, + "node_modules/mkdirp": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-3.0.1.tgz", + "integrity": "sha512-+NsyUUAZDmo6YVHzL/stxSu3t9YS1iljliy3BSDrXJ/dkn1KYdmtZODGGjLcc9XLgVVpH4KshHB8XmZgMhaBXg==", + "license": "MIT", + "bin": { + "mkdirp": "dist/cjs/src/bin.js" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, "node_modules/mustache": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/mustache/-/mustache-4.2.0.tgz", @@ -841,20 +1105,37 @@ "mustache": "bin/mustache" } }, + "node_modules/mute-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-2.0.0.tgz", + "integrity": "sha512-WWdIxpyjEn+FhQJQQv9aQAYlHoNVdzIzUySNV1gHUPDSdZJ3yZn7pAAbQcV7B56Mvu881q9FZV+0Vx2xC44VWA==", + "license": "ISC", + "engines": { + "node": "^18.17.0 || >=20.5.0" + } + }, "node_modules/openapi-types": { "version": "12.1.3", "resolved": "https://registry.npmjs.org/openapi-types/-/openapi-types-12.1.3.tgz", "integrity": "sha512-N4YtSYJqghVu4iek2ZUvcN/0aqH1kRDuNqzcycDxhOUpg7GdvLa2F3DgS6yBNhInhv2r/6I0Flkn7CqL8+nIcw==", + "license": "MIT" + }, + "node_modules/os-tmpdir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "integrity": "sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==", "license": "MIT", - "peer": true + "engines": { + "node": ">=0.10.0" + } }, "node_modules/path-type": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/path-type/-/path-type-5.0.0.tgz", - "integrity": "sha512-5HviZNaZcfqP95rwpv+1HDgUamezbqdSYTyzjTvwtJSnIH+3vnbmWsItli8OFEndS984VT55M3jduxZbX351gg==", + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/path-type/-/path-type-6.0.0.tgz", + "integrity": "sha512-Vj7sf++t5pBD637NSfkxpHSMfWaeig5+DKWLhcqIYx6mWQz5hdJTGDVMQiJcw1ZYkhs7AazKDGpRVji1LJCZUQ==", "license": "MIT", "engines": { - "node": ">=12" + "node": ">=18" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" @@ -879,9 +1160,9 @@ } }, "node_modules/prettier": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.3.3.tgz", - "integrity": "sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew==", + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.5.3.tgz", + "integrity": "sha512-QQtaxnoDJeAkDvDKWCLiwIXkTgRhwYDEQCghU9Z6q03iyek/rxRh/2lC3HB7P8sWT2xC/y5JDctPLBIGzHKbhw==", "license": "MIT", "bin": { "prettier": "bin/prettier.cjs" @@ -893,19 +1174,6 @@ "url": "https://github.com/prettier/prettier?sponsor=1" } }, - "node_modules/prompts": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/prompts/-/prompts-2.4.2.tgz", - "integrity": "sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==", - "license": "MIT", - "dependencies": { - "kleur": "^3.0.3", - "sisteransi": "^1.0.5" - }, - "engines": { - "node": ">= 6" - } - }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -926,12 +1194,6 @@ ], "license": "MIT" }, - "node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, "node_modules/require-directory": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", @@ -951,9 +1213,9 @@ } }, "node_modules/reusify": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", - "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.1.0.tgz", + "integrity": "sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==", "license": "MIT", "engines": { "iojs": ">=1.0.0", @@ -983,6 +1245,12 @@ "queue-microtask": "^1.2.2" } }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "license": "MIT" + }, "node_modules/semver": { "version": "7.7.2", "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.2.tgz", @@ -995,11 +1263,17 @@ "node": ">=10" } }, - "node_modules/sisteransi": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz", - "integrity": "sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==", - "license": "MIT" + "node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "license": "ISC", + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } }, "node_modules/slash": { "version": "5.1.0", @@ -1039,33 +1313,50 @@ "node": ">=8" } }, - "node_modules/supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "license": "MIT", + "node_modules/tar": { + "version": "7.4.3", + "resolved": "https://registry.npmjs.org/tar/-/tar-7.4.3.tgz", + "integrity": "sha512-5S7Va8hKfV7W5U6g3aYxXmlPoZVAwUMy9AOKyF2fVuZa2UD3qZjg578OrLRt8PcNN1PleVaL/5/yYATNL0ICUw==", + "license": "ISC", "dependencies": { - "has-flag": "^3.0.0" + "@isaacs/fs-minipass": "^4.0.0", + "chownr": "^3.0.0", + "minipass": "^7.1.2", + "minizlib": "^3.0.1", + "mkdirp": "^3.0.1", + "yallist": "^5.0.0" }, "engines": { - "node": ">=4" + "node": ">=18" } }, "node_modules/temporal-polyfill": { - "version": "0.2.5", - "resolved": "https://registry.npmjs.org/temporal-polyfill/-/temporal-polyfill-0.2.5.tgz", - "integrity": "sha512-ye47xp8Cb0nDguAhrrDS1JT1SzwEV9e26sSsrWzVu+yPZ7LzceEcH0i2gci9jWfOfSCCgM3Qv5nOYShVUUFUXA==", + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/temporal-polyfill/-/temporal-polyfill-0.3.0.tgz", + "integrity": "sha512-qNsTkX9K8hi+FHDfHmf22e/OGuXmfBm9RqNismxBrnSmZVJKegQ+HYYXT+R7Ha8F/YSm2Y34vmzD4cxMu2u95g==", "license": "MIT", "dependencies": { - "temporal-spec": "^0.2.4" + "temporal-spec": "0.3.0" } }, "node_modules/temporal-spec": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/temporal-spec/-/temporal-spec-0.2.4.tgz", - "integrity": "sha512-lDMFv4nKQrSjlkHKAlHVqKrBG4DyFfa9F74cmBZ3Iy3ed8yvWnlWSIdi4IKfSqwmazAohBNwiN64qGx4y5Q3IQ==", + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/temporal-spec/-/temporal-spec-0.3.0.tgz", + "integrity": "sha512-n+noVpIqz4hYgFSMOSiINNOUOMFtV5cZQNCmmszA6GiVFVRt3G7AqVyhXjhCSmowvQn+NsGn+jMDMKJYHd3bSQ==", "license": "ISC" }, + "node_modules/tmp": { + "version": "0.0.33", + "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", + "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", + "license": "MIT", + "dependencies": { + "os-tmpdir": "~1.0.2" + }, + "engines": { + "node": ">=0.6.0" + } + }, "node_modules/to-regex-range": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", @@ -1078,10 +1369,22 @@ "node": ">=8.0" } }, + "node_modules/type-fest": { + "version": "0.21.3", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", + "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/unicorn-magic": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/unicorn-magic/-/unicorn-magic-0.1.0.tgz", - "integrity": "sha512-lRfVq8fE8gz6QMBuDM6a+LO3IAzTi05H6gCVaUpir2E1Rwpo4ZUog45KpNXKC/Mn3Yb9UDuHumeFTo9iV/D9FQ==", + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/unicorn-magic/-/unicorn-magic-0.3.0.tgz", + "integrity": "sha512-+QBBXBCvifc56fsbuxZQ6Sic3wqqc3WWaqxs58gvJrcOuN83HGTCwz3oS5phzU9LthRNE9VrJCFCLUgHeeFnfA==", "license": "MIT", "engines": { "node": ">=18" @@ -1150,39 +1453,6 @@ "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/wrap-ansi/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "license": "MIT", - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/wrap-ansi/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/wrap-ansi/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT" - }, "node_modules/y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", @@ -1192,10 +1462,19 @@ "node": ">=10" } }, + "node_modules/yallist": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-5.0.0.tgz", + "integrity": "sha512-YgvUTfwqyc7UXVMrB+SImsVYSmTS8X/tSrtdNZMImM+n7+QTriRXyXim0mBrTXNeqzVF0KWGgHPeiyViFFrNDw==", + "license": "BlueOak-1.0.0", + "engines": { + "node": ">=18" + } + }, "node_modules/yaml": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.5.1.tgz", - "integrity": "sha512-bLQOjaX/ADgQ20isPJRvF0iRUHIxVhYvr53Of7wGcWlO2jvtUlH5m87DsmulFVxRpNLOnI4tB6p/oh8D7kpn9Q==", + "version": "2.7.1", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.7.1.tgz", + "integrity": "sha512-10ULxpnOCQXxJvBgxsn9ptjq6uviG/htZKk9veJGhlqn3w/DxQ631zFF+nlQXLwmImeS5amR2dl2U8sg6U9jsQ==", "license": "ISC", "bin": { "yaml": "bin.mjs" @@ -1230,6 +1509,18 @@ "engines": { "node": ">=12" } + }, + "node_modules/yoctocolors-cjs": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/yoctocolors-cjs/-/yoctocolors-cjs-2.1.2.tgz", + "integrity": "sha512-cYVsTjKl8b+FrnidjibDWskAv7UKOfcwaVZdp/it9n1s9fU3IkgDbhdIRKCW4JDsAlECJY0ytoVPT3sK6kideA==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } } } } diff --git a/typespec/package.json b/typespec/package.json index ef7c0962e..a6e8229e3 100644 --- a/typespec/package.json +++ b/typespec/package.json @@ -3,14 +3,14 @@ "version": "0.4.0", "type": "module", "dependencies": { - "@typespec/compiler": "0.61.x", - "@typespec/events": "0.61.x", - "@typespec/http": "0.61.x", - "@typespec/openapi": "0.61.x", - "@typespec/openapi3": "0.61.x", - "@typespec/rest": "0.61.x", - "@typespec/sse": "0.61.x", - "@typespec/versioning": "0.61.x" + "@typespec/compiler": "~1.1.0", + "@typespec/events": "~0.71.0", + "@typespec/http": "~1.1.0", + "@typespec/openapi": "~1.1.0", + "@typespec/openapi3": "~1.1.0", + "@typespec/rest": "~0.71.0", + "@typespec/sse": "~0.71.0", + "@typespec/versioning": "~0.71.0" }, "private": true } diff --git a/typespec/projects/models.tsp b/typespec/projects/models.tsp index d3ed9a7bb..bd04fb16b 100644 --- a/typespec/projects/models.tsp +++ b/typespec/projects/models.tsp @@ -27,7 +27,7 @@ model Project { } /** Payload for updating a project */ -@withVisibility("create", "update") +@withVisibility(Lifecycle.Create, Lifecycle.Update) model UpdateProjectRequest { ...Project; } @@ -36,7 +36,7 @@ model UpdateProjectRequest { model PatchProjectRequest is UpdateProjectRequest {} /** Payload for creating a project */ -@withVisibility("create") +@withVisibility(Lifecycle.Create) model CreateProjectRequest { ...UpdateProjectRequest; } diff --git a/typespec/secrets/models.tsp b/typespec/secrets/models.tsp index b559c50f7..d5f994f10 100644 --- a/typespec/secrets/models.tsp +++ b/typespec/secrets/models.tsp @@ -24,12 +24,12 @@ model Secret { value: string; } -@withVisibility("create", "update") +@withVisibility(Lifecycle.Create, Lifecycle.Update) model UpdateSecretRequest { ...Secret; } -@withVisibility("create") +@withVisibility(Lifecycle.Create) model CreateSecretRequest { ...UpdateSecretRequest; } diff --git a/typespec/sessions/models.tsp b/typespec/sessions/models.tsp index d1970ce56..58f80ba57 100644 --- a/typespec/sessions/models.tsp +++ b/typespec/sessions/models.tsp @@ -105,7 +105,6 @@ enum ContextOverflowType { @discriminator("kind") model Session { - @visibility("none") kind: ( | "single_agent_no_user" | "single_agent_single_user" @@ -116,17 +115,17 @@ model Session { ); /** User ID of user associated with this session */ - @visibility("create") + @visibility(Lifecycle.Create) user?: uuid; - @visibility("create") + @visibility(Lifecycle.Create) users?: uuid[]; /** Agent ID of agent associated with this session */ - @visibility("create") + @visibility(Lifecycle.Create) agent?: uuid; - @visibility("create") + @visibility(Lifecycle.Create) agents?: uuid[]; /** Session situation */ @@ -136,7 +135,7 @@ model Session { system_template?: string; /** Summary (null at the beginning) - generated automatically after every interaction */ - @visibility("read") + @visibility(Lifecycle.Read) summary: string | null = null; /** Render system and assistant message content as jinja templates */ @@ -166,7 +165,6 @@ model Session { } model SingleAgentNoUserSession extends Session { - @visibility("none") kind: "single_agent_no_user" = "single_agent_no_user"; user?: never; @@ -177,7 +175,6 @@ model SingleAgentNoUserSession extends Session { } model SingleAgentSingleUserSession extends Session { - @visibility("none") kind: "single_agent_single_user" = "single_agent_single_user"; users?: never; @@ -188,7 +185,6 @@ model SingleAgentSingleUserSession extends Session { } model SingleAgentMultiUserSession extends Session { - @visibility("none") kind: "single_agent_multi_user" = "single_agent_multi_user"; user?: never; @@ -201,7 +197,6 @@ model SingleAgentMultiUserSession extends Session { } model MultiAgentNoUserSession extends Session { - @visibility("none") kind: "multi_agent_no_user" = "multi_agent_no_user"; user?: never; @@ -213,7 +208,6 @@ model MultiAgentNoUserSession extends Session { } model MultiAgentSingleUserSession extends Session { - @visibility("none") kind: "multi_agent_single_user" = "multi_agent_single_user"; users?: never; @@ -225,7 +219,6 @@ model MultiAgentSingleUserSession extends Session { } model MultiAgentMultiUserSession extends Session { - @visibility("none") kind: "multi_agent_multi_user" = "multi_agent_multi_user"; user?: never; @@ -240,7 +233,7 @@ model MultiAgentMultiUserSession extends Session { /** Payload for updating a session */ -@withVisibility("update") +@withVisibility(Lifecycle.Update) model UpdateSessionRequest { ...Session; } @@ -249,12 +242,12 @@ model UpdateSessionRequest { model PatchSessionRequest is UpdateSessionRequest {} /** Payload for creating a session */ -@withVisibility("create") +@withVisibility(Lifecycle.Create) model CreateSessionRequest { ...Session; } -@withVisibility("create", "update") +@withVisibility(Lifecycle.Create, Lifecycle.Update) model CreateOrUpdateSessionRequest extends CreateSessionRequest { @path id: uuid; diff --git a/typespec/tasks/models.tsp b/typespec/tasks/models.tsp index ca6b72e00..35138f866 100644 --- a/typespec/tasks/models.tsp +++ b/typespec/tasks/models.tsp @@ -26,32 +26,32 @@ model Workflow { model TaskTool extends CreateToolRequest { /** Read-only: Whether the tool was inherited or not. Only applies within tasks. */ - @visibility("read") + @visibility(Lifecycle.Read) inherited?: boolean = false; } /** Reference to a tool by id */ model ToolRefById { - @visibility("read", "create") + @visibility(Lifecycle.Read, Lifecycle.Create) id?: string; } /** Reference to a tool by name */ model ToolRefByName { - @visibility("read", "create") + @visibility(Lifecycle.Read, Lifecycle.Create) name?: validPythonIdentifier; } /** Reference to a tool */ model ToolRef { - @visibility("read", "create") + @visibility(Lifecycle.Read, Lifecycle.Create) ref: ToolRefById | ToolRefByName; } /** Object describing a Task */ model Task { /** The name of the task. */ - @visibility("read", "create", "update") + @visibility(Lifecycle.Read, Lifecycle.Create, Lifecycle.Update) name: displayName; /** The canonical name of the task. */ @@ -80,7 +80,7 @@ model Task { } /** Payload for updating a task */ -@withVisibility("update") +@withVisibility(Lifecycle.Update) model UpdateTaskRequest { ...Task; } @@ -89,7 +89,7 @@ model UpdateTaskRequest { model PatchTaskRequest is UpdateTaskRequest; /** Payload for creating a task */ -@withVisibility("create") +@withVisibility(Lifecycle.Create) model CreateTaskRequest { ...Task; } diff --git a/typespec/tasks/steps.tsp b/typespec/tasks/steps.tsp index ac08a0f99..f0b9de444 100644 --- a/typespec/tasks/steps.tsp +++ b/typespec/tasks/steps.tsp @@ -39,7 +39,7 @@ alias NestedExpressionObject = NestedExpression | NestedExpression[]; @discriminator("kind_") model BaseWorkflowStep { /** The kind of step */ - @visibility("read") + @visibility(Lifecycle.Read) kind_: (typeof T); /** The label of this step for referencing it from other steps */ @@ -77,7 +77,7 @@ alias CreateWorkflowStep = WorkflowStep; //////////////////// model ToolCallStep extends BaseWorkflowStep<"tool_call"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "tool_call" = "tool_call"; ...ToolCallStepDef; @@ -92,7 +92,7 @@ model ToolCallStepDef { } model PromptStep extends BaseWorkflowStep<"prompt"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "prompt" = "prompt"; ...PromptStepDef; @@ -126,7 +126,7 @@ model PromptStepDef { } model EvaluateStep extends BaseWorkflowStep<"evaluate"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "evaluate" = "evaluate"; ...EvaluateStepDef; @@ -138,7 +138,7 @@ model EvaluateStepDef { } model WaitForInputStep extends BaseWorkflowStep<"wait_for_input"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "wait_for_input" = "wait_for_input"; ...WaitForInputStepDef; @@ -155,7 +155,7 @@ model WaitForInputStepDef { } model LogStep extends BaseWorkflowStep<"log"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "log" = "log"; ...LogStepDef; @@ -171,7 +171,7 @@ model LogStepDef { /////////////////////// model GetStep extends BaseWorkflowStep<"get"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "get" = "get"; ...GetStepDef; @@ -183,7 +183,7 @@ model GetStepDef { } model SetStep extends BaseWorkflowStep<"set"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "set" = "set"; ...SetStepDef; @@ -199,7 +199,7 @@ model SetStepDef { /////////////////////// model ParallelStep extends BaseWorkflowStep<"parallel"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "parallel" = "parallel"; ...ParallelStepDef; @@ -221,7 +221,7 @@ model ForeachDo { } model ForeachStep extends BaseWorkflowStep<"foreach"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "foreach" = "foreach"; ...ForeachStepDef; @@ -233,7 +233,7 @@ model ForeachStepDef { } model MapReduceStep> extends BaseWorkflowStep<"map_reduce"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "map_reduce" = "map_reduce"; /** The variable to iterate over */ @@ -261,7 +261,7 @@ model MapReduceStep> extends BaseWor ///////////////////////// model IfElseWorkflowStep extends BaseWorkflowStep<"if_else"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "if_else" = "if_else"; ...IfElseWorkflowStepDef; @@ -318,7 +318,7 @@ model CaseThen { } model SwitchStep extends BaseWorkflowStep<"switch"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "switch" = "switch"; ...SwitchStepDef; @@ -335,7 +335,7 @@ model SwitchStepDef { ////////////////////////// model YieldStep extends BaseWorkflowStep<"yield"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "yield" = "yield"; ...YieldStepDef; @@ -352,7 +352,7 @@ model YieldStepDef { } model ErrorWorkflowStep extends BaseWorkflowStep<"error"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "error" = "error"; ...ErrorWorkflowStepDef; @@ -386,7 +386,7 @@ model SleepFor { } model SleepStep extends BaseWorkflowStep<"sleep"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "sleep" = "sleep"; ...SleepStepDef; @@ -398,7 +398,7 @@ model SleepStepDef { } model ReturnStep extends BaseWorkflowStep<"return"> { - @visibility("read") + @visibility(Lifecycle.Read) kind_: "return" = "return"; ...ReturnStepDef; diff --git a/typespec/tools/models.tsp b/typespec/tools/models.tsp index 52a0332ee..609b8bae6 100644 --- a/typespec/tools/models.tsp +++ b/typespec/tools/models.tsp @@ -304,13 +304,13 @@ model ToolResponse { } /** Payload for creating a tool */ -@withVisibility("create") +@withVisibility(Lifecycle.Create) model CreateToolRequest { ...Tool; } /** Payload for updating a tool */ -@withVisibility("update") +@withVisibility(Lifecycle.Update) model UpdateToolRequest { ...Tool; } @@ -333,7 +333,7 @@ model BaseChosenToolCall { text_editor_20241022?: ChosenTextEditor20241022; bash_20241022?: ChosenBash20241022; - @visibility("read") + @visibility(Lifecycle.Read) id?: string; } diff --git a/typespec/tsp-output/@typespec/openapi3/openapi-1.0.0.yaml b/typespec/tsp-output/@typespec/openapi3/openapi-1.0.0.yaml index 38495da54..1ab200773 100644 --- a/typespec/tsp-output/@typespec/openapi3/openapi-1.0.0.yaml +++ b/typespec/tsp-output/@typespec/openapi3/openapi-1.0.0.yaml @@ -596,7 +596,7 @@ paths: '201': description: The request has succeeded and a new resource has been created as a result. content: - application/json: + text/plain: schema: type: string enum: @@ -628,7 +628,7 @@ paths: '200': description: The request has succeeded. content: - application/json: + text/plain: schema: type: string enum: @@ -659,7 +659,7 @@ paths: '200': description: The request has succeeded. content: - application/json: + text/plain: schema: type: string enum: @@ -3452,9 +3452,9 @@ components: type: integer format: uint16 minimum: 1 + description: Limit the number of results maximum: 1000 exclusiveMaximum: true - description: Limit the number of results Common.logit_bias: type: number format: float @@ -3673,9 +3673,9 @@ components: description: The documents that were found time: type: number + description: The time taken to search in seconds minimum: 0 exclusiveMinimum: true - description: The time taken to search in seconds Docs.EmbedQueryResponse: type: object required: @@ -3721,9 +3721,9 @@ components: mmr_strength: type: number minimum: 0 + description: MMR Strength (mmr_strength = 1 - mmr_lambda) maximum: 1 exclusiveMaximum: true - description: MMR Strength (mmr_strength = 1 - mmr_lambda) default: 0.5 trigram_similarity_threshold: type: number @@ -3821,9 +3821,9 @@ components: mmr_strength: type: number minimum: 0 + description: MMR Strength (mmr_strength = 1 - mmr_lambda) maximum: 1 exclusiveMaximum: true - description: MMR Strength (mmr_strength = 1 - mmr_lambda) default: 0.5 allOf: - $ref: '#/components/schemas/Docs.BaseDocSearchRequest' @@ -4419,7 +4419,8 @@ components: description: Description of the file default: '' mime_type: - oneOf: + type: string + allOf: - $ref: '#/components/schemas/Common.mimeType' nullable: true description: MIME type of the file @@ -4462,7 +4463,8 @@ components: description: Description of the file default: '' mime_type: - oneOf: + type: string + allOf: - $ref: '#/components/schemas/Common.mimeType' nullable: true description: MIME type of the file @@ -4670,7 +4672,7 @@ components: - type - button - x - - y + - 'y' properties: type: type: string @@ -4691,7 +4693,7 @@ components: type: integer format: int32 description: The x-coordinate where the click occurred. - y: + 'y': type: integer format: int32 description: The y-coordinate where the click occurred. @@ -4848,13 +4850,13 @@ components: type: object required: - x - - y + - 'y' properties: x: type: integer format: int32 description: The x-coordinate. - y: + 'y': type: integer format: int32 description: The y-coordinate. @@ -4894,7 +4896,7 @@ components: top_p: type: number default: 1 - n: + 'n': type: integer format: int32 stop: @@ -4967,7 +4969,7 @@ components: required: - type - x - - y + - 'y' properties: type: type: string @@ -4979,7 +4981,7 @@ components: type: integer format: int32 description: The x-coordinate where the double click occurred. - y: + 'y': type: integer format: int32 description: The y-coordinate where the double click occurred. @@ -5389,7 +5391,7 @@ components: required: - type - x - - y + - 'y' properties: type: type: string @@ -5401,7 +5403,7 @@ components: type: integer format: int32 description: The x-coordinate to move to. - y: + 'y': type: integer format: int32 description: The y-coordinate to move to. @@ -5734,7 +5736,7 @@ components: required: - type - x - - y + - 'y' - scroll_x - scroll_y properties: @@ -5748,7 +5750,7 @@ components: type: integer format: int32 description: The x-coordinate where the scroll occurred. - y: + 'y': type: integer format: int32 description: The y-coordinate where the scroll occurred. @@ -6125,6 +6127,7 @@ components: type: object required: - id + - kind - situation - render_templates - token_budget @@ -6134,22 +6137,15 @@ components: properties: id: $ref: '#/components/schemas/Common.uuid' - user: - allOf: - - $ref: '#/components/schemas/Common.uuid' - description: User ID of user associated with this session - users: - type: array - items: - $ref: '#/components/schemas/Common.uuid' - agent: - allOf: - - $ref: '#/components/schemas/Common.uuid' - description: Agent ID of agent associated with this session - agents: - type: array - items: - $ref: '#/components/schemas/Common.uuid' + kind: + type: string + enum: + - single_agent_no_user + - single_agent_single_user + - single_agent_multi_user + - multi_agent_no_user + - multi_agent_single_user + - multi_agent_multi_user situation: type: string nullable: true @@ -6169,7 +6165,7 @@ components: description: Threshold value for the adaptive context functionality default: null context_overflow: - oneOf: + allOf: - $ref: '#/components/schemas/Sessions.ContextOverflowType' nullable: true description: Action to start on context window overflow @@ -6189,10 +6185,18 @@ components: default: false recall_options: anyOf: - - $ref: '#/components/schemas/Sessions.VectorDocSearch' - - $ref: '#/components/schemas/Sessions.TextOnlyDocSearch' - - $ref: '#/components/schemas/Sessions.HybridDocSearch' - nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.VectorDocSearch' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.TextOnlyDocSearch' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.HybridDocSearch' + nullable: true description: Recall options for the session default: null metadata: @@ -6203,6 +6207,7 @@ components: Sessions.CreateSessionRequest: type: object required: + - kind - situation - render_templates - token_budget @@ -6210,6 +6215,15 @@ components: - auto_run_tools - forward_tool_calls properties: + kind: + type: string + enum: + - single_agent_no_user + - single_agent_single_user + - single_agent_multi_user + - multi_agent_no_user + - multi_agent_single_user + - multi_agent_multi_user user: allOf: - $ref: '#/components/schemas/Common.uuid' @@ -6245,7 +6259,7 @@ components: description: Threshold value for the adaptive context functionality default: null context_overflow: - oneOf: + allOf: - $ref: '#/components/schemas/Sessions.ContextOverflowType' nullable: true description: Action to start on context window overflow @@ -6265,10 +6279,18 @@ components: default: false recall_options: anyOf: - - $ref: '#/components/schemas/Sessions.VectorDocSearch' - - $ref: '#/components/schemas/Sessions.TextOnlyDocSearch' - - $ref: '#/components/schemas/Sessions.HybridDocSearch' - nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.VectorDocSearch' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.TextOnlyDocSearch' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.HybridDocSearch' + nullable: true description: Recall options for the session default: null metadata: @@ -6305,9 +6327,9 @@ components: mmr_strength: type: number minimum: 0 + description: MMR Strength (mmr_strength = 1 - mmr_lambda) maximum: 1 exclusiveMaximum: true - description: MMR Strength (mmr_strength = 1 - mmr_lambda) default: 0.5 trigram_similarity_threshold: type: number @@ -6347,9 +6369,9 @@ components: mmr_strength: type: number minimum: 0 + description: MMR Strength (mmr_strength = 1 - mmr_lambda) maximum: 1 exclusiveMaximum: true - description: MMR Strength (mmr_strength = 1 - mmr_lambda) default: 0.5 trigram_similarity_threshold: type: number @@ -6368,9 +6390,15 @@ components: Sessions.MultiAgentMultiUserSession: type: object required: + - kind - agents - users properties: + kind: + type: string + enum: + - multi_agent_multi_user + default: multi_agent_multi_user agents: type: array items: @@ -6386,8 +6414,14 @@ components: Sessions.MultiAgentNoUserSession: type: object required: + - kind - agents properties: + kind: + type: string + enum: + - multi_agent_no_user + default: multi_agent_no_user agents: type: array items: @@ -6398,9 +6432,15 @@ components: Sessions.MultiAgentSingleUserSession: type: object required: + - kind - agents - user properties: + kind: + type: string + enum: + - multi_agent_single_user + default: multi_agent_single_user agents: type: array items: @@ -6413,6 +6453,15 @@ components: Sessions.PatchSessionRequest: type: object properties: + kind: + type: string + enum: + - single_agent_no_user + - single_agent_single_user + - single_agent_multi_user + - multi_agent_no_user + - multi_agent_single_user + - multi_agent_multi_user situation: type: string nullable: true @@ -6432,7 +6481,7 @@ components: description: Threshold value for the adaptive context functionality default: null context_overflow: - oneOf: + allOf: - $ref: '#/components/schemas/Sessions.ContextOverflowType' nullable: true description: Action to start on context window overflow @@ -6452,10 +6501,18 @@ components: default: false recall_options: anyOf: - - $ref: '#/components/schemas/Sessions.VectorDocSearchUpdate' - - $ref: '#/components/schemas/Sessions.TextOnlyDocSearchUpdate' - - $ref: '#/components/schemas/Sessions.HybridDocSearchUpdate' - nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.VectorDocSearchUpdate' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.TextOnlyDocSearchUpdate' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.HybridDocSearchUpdate' + nullable: true description: Recall options for the session default: null metadata: @@ -6465,6 +6522,7 @@ components: Sessions.Session: type: object required: + - kind - situation - summary - render_templates @@ -6476,6 +6534,15 @@ components: - created_at - updated_at properties: + kind: + type: string + enum: + - single_agent_no_user + - single_agent_single_user + - single_agent_multi_user + - multi_agent_no_user + - multi_agent_single_user + - multi_agent_multi_user situation: type: string nullable: true @@ -6501,7 +6568,7 @@ components: description: Threshold value for the adaptive context functionality default: null context_overflow: - oneOf: + allOf: - $ref: '#/components/schemas/Sessions.ContextOverflowType' nullable: true description: Action to start on context window overflow @@ -6521,10 +6588,18 @@ components: default: false recall_options: anyOf: - - $ref: '#/components/schemas/Sessions.VectorDocSearch' - - $ref: '#/components/schemas/Sessions.TextOnlyDocSearch' - - $ref: '#/components/schemas/Sessions.HybridDocSearch' - nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.VectorDocSearch' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.TextOnlyDocSearch' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.HybridDocSearch' + nullable: true description: Recall options for the session default: null id: @@ -6544,9 +6619,6 @@ components: format: date-time description: When this resource was updated as UTC date-time readOnly: true - kind: - type: string - description: Discriminator property for Session. discriminator: propertyName: kind mapping: @@ -6559,9 +6631,15 @@ components: Sessions.SingleAgentMultiUserSession: type: object required: + - kind - agent - users properties: + kind: + type: string + enum: + - single_agent_multi_user + default: single_agent_multi_user agent: $ref: '#/components/schemas/Common.uuid' users: @@ -6574,8 +6652,14 @@ components: Sessions.SingleAgentNoUserSession: type: object required: + - kind - agent properties: + kind: + type: string + enum: + - single_agent_no_user + default: single_agent_no_user agent: $ref: '#/components/schemas/Common.uuid' allOf: @@ -6583,9 +6667,15 @@ components: Sessions.SingleAgentSingleUserSession: type: object required: + - kind - agent - user properties: + kind: + type: string + enum: + - single_agent_single_user + default: single_agent_single_user agent: $ref: '#/components/schemas/Common.uuid' user: @@ -6632,6 +6722,7 @@ components: Sessions.UpdateSessionRequest: type: object required: + - kind - situation - render_templates - token_budget @@ -6639,6 +6730,15 @@ components: - auto_run_tools - forward_tool_calls properties: + kind: + type: string + enum: + - single_agent_no_user + - single_agent_single_user + - single_agent_multi_user + - multi_agent_no_user + - multi_agent_single_user + - multi_agent_multi_user situation: type: string nullable: true @@ -6658,7 +6758,7 @@ components: description: Threshold value for the adaptive context functionality default: null context_overflow: - oneOf: + allOf: - $ref: '#/components/schemas/Sessions.ContextOverflowType' nullable: true description: Action to start on context window overflow @@ -6678,10 +6778,18 @@ components: default: false recall_options: anyOf: - - $ref: '#/components/schemas/Sessions.VectorDocSearch' - - $ref: '#/components/schemas/Sessions.TextOnlyDocSearch' - - $ref: '#/components/schemas/Sessions.HybridDocSearch' - nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.VectorDocSearch' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.TextOnlyDocSearch' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Sessions.HybridDocSearch' + nullable: true description: Recall options for the session default: null metadata: @@ -6709,9 +6817,9 @@ components: mmr_strength: type: number minimum: 0 + description: MMR Strength (mmr_strength = 1 - mmr_lambda) maximum: 1 exclusiveMaximum: true - description: MMR Strength (mmr_strength = 1 - mmr_lambda) default: 0.5 allOf: - $ref: '#/components/schemas/Sessions.BaseDocSearch' @@ -6733,9 +6841,9 @@ components: mmr_strength: type: number minimum: 0 + description: MMR Strength (mmr_strength = 1 - mmr_lambda) maximum: 1 exclusiveMaximum: true - description: MMR Strength (mmr_strength = 1 - mmr_lambda) default: 0.5 allOf: - $ref: '#/components/schemas/Sessions.BaseDocSearchUpdate' @@ -7155,6 +7263,8 @@ components: description: The steps to run for each iteration allOf: - type: object + required: + - kind_ properties: label: allOf: @@ -7296,21 +7406,66 @@ components: description: The steps to run if the condition is true else: anyOf: - - $ref: '#/components/schemas/Tasks.WaitForInputStep' - - $ref: '#/components/schemas/Tasks.EvaluateStep' - - $ref: '#/components/schemas/Tasks.ToolCallStep' - - $ref: '#/components/schemas/Tasks.PromptStep' - - $ref: '#/components/schemas/Tasks.GetStep' - - $ref: '#/components/schemas/Tasks.SetStep' - - $ref: '#/components/schemas/Tasks.LogStep' - - $ref: '#/components/schemas/Tasks.YieldStep' - - $ref: '#/components/schemas/Tasks.ReturnStep' - - $ref: '#/components/schemas/Tasks.SleepStep' - - $ref: '#/components/schemas/Tasks.ErrorWorkflowStep' - - $ref: '#/components/schemas/Tasks.IfElseWorkflowStep' - - $ref: '#/components/schemas/Tasks.SwitchStep' - - $ref: '#/components/schemas/Tasks.ForeachStep' - - $ref: '#/components/schemas/Tasks.ParallelStep' + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.WaitForInputStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.EvaluateStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.ToolCallStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.PromptStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.GetStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.SetStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.LogStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.YieldStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.ReturnStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.SleepStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.ErrorWorkflowStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.IfElseWorkflowStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.SwitchStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.ForeachStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.ParallelStep' + nullable: true - type: object required: - kind_ @@ -7370,7 +7525,7 @@ components: description: The label of this step for referencing it from other steps discriminator: propertyName: kind_ - nullable: true + nullable: true description: The steps to run if the condition is false default: null allOf: @@ -7456,6 +7611,8 @@ components: description: Whether to run the reduce expression in parallel and how many items to run in each batch allOf: - type: object + required: + - kind_ properties: label: allOf: @@ -7469,21 +7626,66 @@ components: description: The steps to run if the condition is true else: anyOf: - - $ref: '#/components/schemas/Tasks.WaitForInputStep' - - $ref: '#/components/schemas/Tasks.EvaluateStep' - - $ref: '#/components/schemas/Tasks.ToolCallStep' - - $ref: '#/components/schemas/Tasks.PromptStepUpdateItem' - - $ref: '#/components/schemas/Tasks.GetStep' - - $ref: '#/components/schemas/Tasks.SetStep' - - $ref: '#/components/schemas/Tasks.LogStep' - - $ref: '#/components/schemas/Tasks.YieldStep' - - $ref: '#/components/schemas/Tasks.ReturnStep' - - $ref: '#/components/schemas/Tasks.SleepStep' - - $ref: '#/components/schemas/Tasks.ErrorWorkflowStep' - - $ref: '#/components/schemas/Tasks.IfElseWorkflowStepUpdateItem' - - $ref: '#/components/schemas/Tasks.SwitchStepUpdateItem' - - $ref: '#/components/schemas/Tasks.ForeachStepUpdateItem' - - $ref: '#/components/schemas/Tasks.ParallelStepUpdateItem' + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.WaitForInputStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.EvaluateStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.ToolCallStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.PromptStepUpdateItem' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.GetStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.SetStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.LogStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.YieldStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.ReturnStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.SleepStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.ErrorWorkflowStep' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.IfElseWorkflowStepUpdateItem' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.SwitchStepUpdateItem' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.ForeachStepUpdateItem' + nullable: true + - type: object + allOf: + - $ref: '#/components/schemas/Tasks.ParallelStepUpdateItem' + nullable: true - type: object required: - over @@ -7521,6 +7723,8 @@ components: description: Whether to run the reduce expression in parallel and how many items to run in each batch allOf: - type: object + required: + - kind_ properties: label: allOf: @@ -7531,11 +7735,13 @@ components: description: Discriminator property for BaseWorkflowStep. discriminator: propertyName: kind_ - nullable: true + nullable: true description: The steps to run if the condition is false default: null allOf: - type: object + required: + - kind_ properties: label: allOf: @@ -7644,6 +7850,8 @@ components: description: The steps to run in parallel. Max concurrency will depend on the platform. allOf: - type: object + required: + - kind_ properties: label: allOf: @@ -7726,6 +7934,8 @@ components: description: Whether to run the reduce expression in parallel and how many items to run in each batch allOf: - type: object + required: + - kind_ properties: label: allOf: @@ -7813,6 +8023,8 @@ components: description: Whether to run the reduce expression in parallel and how many items to run in each batch allOf: - type: object + required: + - kind_ properties: label: allOf: @@ -7857,10 +8069,14 @@ components: type: string content: anyOf: - - $ref: '#/components/schemas/Common.JinjaTemplate' + - type: string + allOf: + - $ref: '#/components/schemas/Common.JinjaTemplate' + nullable: true - type: array items: $ref: '#/components/schemas/Common.JinjaTemplate' + nullable: true - type: array items: anyOf: @@ -7962,7 +8178,7 @@ components: data: $ref: '#/components/schemas/Common.JinjaTemplate' description: Anthropic image content part - nullable: true + nullable: true description: The content parts of the message name: type: string @@ -8067,10 +8283,14 @@ components: type: string content: anyOf: - - $ref: '#/components/schemas/Common.JinjaTemplate' + - type: string + allOf: + - $ref: '#/components/schemas/Common.JinjaTemplate' + nullable: true - type: array items: $ref: '#/components/schemas/Common.JinjaTemplate' + nullable: true - type: array items: anyOf: @@ -8172,7 +8392,7 @@ components: data: $ref: '#/components/schemas/Common.JinjaTemplate' description: Anthropic image content part - nullable: true + nullable: true description: The content parts of the message name: type: string @@ -8235,6 +8455,8 @@ components: default: false allOf: - type: object + required: + - kind_ properties: label: allOf: @@ -8450,6 +8672,8 @@ components: description: The cond tree allOf: - type: object + required: + - kind_ properties: label: allOf: @@ -9635,6 +9859,8 @@ components: description: Integration definition Tools.BaseIntegrationDefUpdate: type: object + required: + - provider properties: provider: type: string diff --git a/typespec/users/models.tsp b/typespec/users/models.tsp index ad22ade6e..a616855c9 100644 --- a/typespec/users/models.tsp +++ b/typespec/users/models.tsp @@ -28,7 +28,7 @@ model User { } /** Payload for updating a user */ -@withVisibility("create", "update") +@withVisibility(Lifecycle.Create, Lifecycle.Update) model UpdateUserRequest { ...User; }