# Copyright 2024 Soul Machines Ltd

# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at

#     http://www.apache.org/licenses/LICENSE-2.0

# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# generated by datamodel-codegen:
#   filename:  api_async.yml
#   timestamp: 2024-04-02T22:17:10+00:00

from __future__ import annotations

from typing import Any, Dict, List, Optional

from pydantic import BaseModel

from . import common


class SessionStartMessage(BaseModel):
    projectId: str
    sessionId: str
    config: Dict[str, Any]
    deploymentEnvironment: Optional[common.DeploymentEnvironment] = None


class SessionEndMessage(BaseModel):
    projectId: str
    sessionId: str
    deploymentEnvironment: Optional[common.DeploymentEnvironment] = None


class UserConversationMessage(BaseModel):
    projectId: Optional[str] = None
    sessionId: Optional[str] = None
    config: Optional[Dict[str, Any]] = None
    text: str
    variables: Optional[Dict[str, Any]] = None
    memory: Optional[List[common.Memory]] = None
    deploymentEnvironment: Optional[common.DeploymentEnvironment] = None


class SkillConversationMessage(BaseModel):
    text: str
    variables: Optional[Dict[str, Any]] = None
    intent: Optional[common.Intent] = None
    memory: Optional[List[common.Memory]] = None
