# ----------------------------------------------------------------------------
#
#  Welcome to Baml! To use this generated code, please run the following:
#
#  $ pip install baml
#
# ----------------------------------------------------------------------------

# This file was generated by BAML: please do not edit it. Instead, edit the
# BAML files and re-generate this code using: baml-cli generate
# baml-cli is available with the baml package.

import typing
import typing_extensions
from enum import Enum


from pydantic import BaseModel, ConfigDict


import baml_py

CheckT = typing_extensions.TypeVar('CheckT')
CheckName = typing_extensions.TypeVar('CheckName', bound=str)

class Check(BaseModel):
    name: str
    expression: str
    status: str
class Checked(BaseModel, typing.Generic[CheckT, CheckName]):
    value: CheckT
    checks: typing.Dict[CheckName, Check]

def get_checks(checks: typing.Dict[CheckName, Check]) -> typing.List[Check]:
    return list(checks.values())

def all_succeeded(checks: typing.Dict[CheckName, Check]) -> bool:
    return all(check.status == "succeeded" for check in get_checks(checks))
# #########################################################################
# Generated enums (0)
# #########################################################################

# #########################################################################
# Generated classes (8)
# #########################################################################

class CapabilityCandidate(BaseModel):
    name: str
    candidate_type: str
    relevance_score: float
    reasoning: str
    requires_api_key: bool

class CapabilityCategory(BaseModel):
    name: str
    server: str
    summary: str

class CapabilityMatchResult(BaseModel):
    candidates: typing.List["CapabilityCandidate"]
    recommendation: str

class CapabilitySummary(BaseModel):
    categories: typing.List["CapabilityCategory"]
    usage_hint: str

class ManifestCLI(BaseModel):
    name: str
    description: str
    keywords: typing.List[str]

class ManifestServer(BaseModel):
    name: str
    description: str
    keywords: typing.List[str]
    requires_api_key: bool
    env_var: typing.Optional[str] = None

class ManifestSummary(BaseModel):
    servers: typing.List["ManifestServer"]
    clis: typing.List["ManifestCLI"]

class ToolDescription(BaseModel):
    server_name: str
    tool_name: str
    description: str

# #########################################################################
# Generated type aliases (0)
# #########################################################################
