Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
97 commits
Select commit Hold shift + click to select a range
a7ac7ad
ENG-1852: Hotfix, added fail-fast option (#488)
kadirpekel Apr 11, 2025
b0887bd
Fix: BUG-503 failed to update utility tool after get (#491)
ahmetgunduz Apr 16, 2025
89daf2f
Bug-503-fix Update (#493)
ahmetgunduz Apr 16, 2025
6bf7d00
ENG-1920: added sentry cred (#476)
xainaz Apr 16, 2025
9e2b03c
Read input variables correctly (#496)
thiago-aixplain Apr 17, 2025
409a893
Fix: file not deleted in test_sql_tool_with_csv test (#492)
ahmetgunduz Apr 17, 2025
3acfacd
ENG-2007: Fix agent and team agent parametrized functional test - Syn…
lucas-aixplain Apr 17, 2025
da7ec38
ENG-1789: Add multiple index backbones support (#443)
basitanees Apr 23, 2025
d360780
ENG-2049: rename air functions (#500)
thiago-aixplain Apr 24, 2025
24e88da
ENG 1924: aixplain sdk new test cases for agents using utility and pi…
OsujiCC Apr 24, 2025
044d8d8
add pydantic requirement (#502)
basitanees Apr 25, 2025
4efdbc8
ENG-1978: Adding instructions to teams (#485)
thiago-aixplain Apr 25, 2025
ab2fcc5
BUG-504: Merged paramMappings for the same link vectors (#499)
kadirpekel Apr 25, 2025
268cc1a
ENG-1836: Set name of tools on the SDK (#501)
thiago-aixplain Apr 28, 2025
9796d19
Eng 2051 Improvements on CI flow (#509)
kadirpekel Apr 30, 2025
f0837fc
Add a finetuned version of BGE model (#512)
Muhammad-Elmallah May 5, 2025
511bf5f
ENG-2055-Aixplain-SDK-Centralized-Error-Handling (#510)
ahmetgunduz May 6, 2025
0c4edf4
ENG-1862:Added status to Tools and deployment check for Agent and Tea…
ahmetgunduz May 6, 2025
0989c51
Merge branch 'test' into development
hadi-aix May 8, 2025
84baed8
Fix: BUG-543 SQL Tool upload db issue (#519)
ahmetgunduz May 9, 2025
de6a1c4
ENG-2028: model streaming (#506)
thiago-aixplain May 9, 2025
b909a54
BUG-542-Utility-Model-Update-Test-Failing-in-SDK (#515)
ahmetgunduz May 9, 2025
8aa3d31
ENG-2115 fixing agent tests (#522)
thiago-aixplain May 9, 2025
4f20c65
Merge branch 'test' into development
thiago-aixplain May 9, 2025
87d5791
ENG-1551 ai xplain sdk caching onboarded models pipelines and agents …
xainaz May 12, 2025
6f600d9
Bug 531: standardize asset names (#521)
OsujiCC May 14, 2025
85d0406
fixed asset issue (#526)
xainaz May 15, 2025
4d650c9
Make functional test more stable (#525)
thiago-aixplain May 15, 2025
91d6864
ENG-2100: Enable JSON schema as output format (#513)
thiago-aixplain May 19, 2025
cecd3a6
Added serialize function for save (#529)
xainaz May 20, 2025
6aa648f
Add Embedding Params to Model (#534)
basitanees May 20, 2025
ad4ddbf
Prod 1785 enable adding any embedding in ai r not just embedding mode…
Muhammad-Elmallah May 21, 2025
bb74b68
Changed cache default to false (#536)
xainaz May 22, 2025
e3f072d
Merge branch 'test' into development
thiago-aixplain May 22, 2025
b2a00e3
added filelock (#538)
xainaz May 23, 2025
239b56a
Add filelock to requirements (#540)
thiago-aixplain May 23, 2025
1f6b614
cache duration (#541)
xainaz May 23, 2025
14485e2
ErrorCode returns code in string (#542)
yunsukim86 May 26, 2025
59be7cc
ENG-2003 : Add LLM's to Agents as Object (#524)
ahmetgunduz May 27, 2025
cdaaa81
ENG-2105: persist sql data (#528)
thiago-aixplain May 27, 2025
77ff8d8
Custom inspector interface (#484)
yunsukim86 Jun 2, 2025
f6422db
Eng 2040 ai r 2 add splitting features to the sdk (#546)
Muhammad-Elmallah Jun 2, 2025
59e40d6
pipeline to_dict change + fixed circular imports pipeline functional …
xainaz Jun 2, 2025
c8aa11c
ENG-1962: composio (#547)
thiago-aixplain Jun 4, 2025
b7a929d
Add input target for inspectors (#548)
yunsukim86 Jun 6, 2025
6067f16
ENG-1900 Refined agent deletion error messages (#543)
kadirpekel Jun 10, 2025
c570a70
ENG-2271: Add code interpreter model ID (#550)
lucas-aixplain Jun 16, 2025
80ddb8a
Update enums.py (#552)
hadi-aix Jun 18, 2025
39be1d0
Update enums.py (#554)
hadi-aix Jun 18, 2025
c45b709
Merge branch 'test' into development
hadi-aix Jun 18, 2025
095f9b8
removed pipeline cache test (#556)
xainaz Jun 19, 2025
01a7f9e
Functional test fix of agent in use error (#560)
ahmetgunduz Jun 20, 2025
585444a
BUG-574 Fixed functionType type handling (#561)
kadirpekel Jun 20, 2025
1e84627
PROD-1833: Optional Instructions in Agents (#559)
ahmetgunduz Jun 24, 2025
ea51442
fixing the tests (#569)
Muhammad-Elmallah Jun 25, 2025
ba406e2
Introducing prompt benchmarking (#497)
shreyasXplain Jun 26, 2025
3d6dc91
ENG-2371 functional test for pipeline run_async (#570)
kadirpekel Jun 27, 2025
a96dd07
Add new methods to Air (#578)
basitanees Jul 8, 2025
ac8b5ac
Bumped model-interfaces to latest release (#221)
mikelam-us-aixplain Jul 8, 2025
7e59519
Re-implement the integration.py file (#581)
elsheikhams99 Jul 13, 2025
5b6bcaa
Improve readability - fix OAUTH methods bug (#583)
elsheikhams99 Jul 14, 2025
6ab5953
Eng 2400 add tests, fix composio bugs (#585)
elsheikhams99 Jul 15, 2025
c397aaa
Add MCP Connection (#587)
hadi-aix Jul 15, 2025
ba71caa
Fix integration tests in model_test.py (#590)
elsheikhams99 Jul 16, 2025
7ea5ec8
Eng 2327 integrate mcp server (#592)
hadi-aix Jul 17, 2025
926927c
Update utils.py
hadi-aix Jul 17, 2025
481b6cf
Update api_key.py (#596)
hadi-aix Jul 17, 2025
971f5ec
Eng 2407 update rate limiting to allow 0 values (#597)
hadi-aix Jul 17, 2025
bab0353
Eng 2407 update rate limiting to allow 0 values (#600)
hadi-aix Jul 17, 2025
46de340
fix BUG-591 (#589)
ahmetgunduz Jul 18, 2025
933cb55
ENG-2349: Added from dict and to dict methods (#567)
ahmetgunduz Jul 22, 2025
3ac8838
Update integration.py (#605)
hadi-aix Jul 28, 2025
7723a60
Add support for tool recreate (#606)
hadi-aix Jul 30, 2025
7a43ead
Eng 2441 add support for python script integration for on prem (#607)
hadi-aix Jul 30, 2025
85f063b
Eng 2327 integrate mcp server (#608)
hadi-aix Jul 31, 2025
da3d304
Update integration.py
hadi-aix Jul 31, 2025
caeee0c
fixing typos (#611)
ankit0305 Aug 4, 2025
77666f8
elaborating error for team deployment (#609)
xainaz Aug 4, 2025
62fcea6
Update function_type.py (#616)
hadi-aix Aug 6, 2025
31802be
BUG-600 add proper error handling and allow Text and LLM in the input…
elsheikhams99 Aug 6, 2025
7ed14c3
Eng 2444 output format modification (#615)
elsheikhams99 Aug 6, 2025
abddcba
fixed in creation of team agents, sent to payload (#618)
xainaz Aug 6, 2025
1558978
Update pyproject.toml (#619)
ahmetgunduz Aug 7, 2025
6a9fe15
Update __init__.py (#621)
ahmetgunduz Aug 9, 2025
a08a0e0
session id agent init changes (#603)
xainaz Aug 11, 2025
cfdc183
indentation fix (#622)
ahmetgunduz Aug 11, 2025
77aac73
changed all role to instructions (#602)
xainaz Aug 12, 2025
a968b28
Revert "changed all role to instructions (#602)" (#623)
ahmetgunduz Aug 12, 2025
ca4c7d3
changed all role to instructions (#624)
xainaz Aug 13, 2025
af40dc4
Update unit tests for team-agents and agents (#625)
elsheikhams99 Aug 13, 2025
1863db8
Add/improve docstrings according to Google style for all classes, fun…
elsheikhams99 Aug 13, 2025
72d6f3a
Update function_type.py (#626)
ahmetgunduz Aug 13, 2025
960b3af
fix slack mcp (#629)
ahmetgunduz Aug 14, 2025
3eda2e4
resolve conflict with test (#628)
ahmetgunduz Aug 14, 2025
5a316cd
resolve conflict with test (#630)
ahmetgunduz Aug 14, 2025
b06016e
Resolve conflict (#632)
ahmetgunduz Aug 15, 2025
9a03a39
Merge branch 'test' into mergetotest_20250815
hadi-aix Aug 15, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
54 changes: 44 additions & 10 deletions aixplain/base/parameters.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,33 @@

@dataclass
class Parameter:
"""A class representing a single parameter with its properties.

Attributes:
name (str): The name of the parameter.
required (bool): Whether the parameter is required or optional.
value (Optional[Any]): The value of the parameter. Defaults to None.
"""
name: str
required: bool
value: Optional[Any] = None


class BaseParameters:
"""A base class for managing a collection of parameters.

This class provides functionality to store, access, and manipulate parameters
in a structured way. Parameters can be accessed using attribute syntax or
dictionary-style access.

Attributes:
parameters (Dict[str, Parameter]): Dictionary storing Parameter objects.
"""
def __init__(self) -> None:
"""Initialize base parameters class"""
"""Initialize the BaseParameters class.

The initialization creates an empty dictionary to store parameters.
"""
self.parameters: Dict[str, Parameter] = {}

def get_parameter(self, name: str) -> Optional[Parameter]:
Expand All @@ -34,10 +53,14 @@ def to_dict(self) -> Dict[str, Dict[str, Any]]:
return {param.name: {"required": param.required, "value": param.value} for param in self.parameters.values()}

def to_list(self) -> List[str]:
"""Convert parameters back to list format.
"""Convert parameters to a list format.

This method creates a list of dictionaries containing the name and value
of each parameter that has a value set.

Returns:
List[str]: List representation of parameters
List[str]: A list of dictionaries, each containing 'name' and 'value'
keys for parameters that have values set.
"""
return [{"name": param.name, "value": param.value} for param in self.parameters.values() if param.value is not None]

Expand All @@ -59,11 +82,18 @@ def __str__(self) -> str:
return "\n".join(lines)

def __setattr__(self, name: str, value: Any) -> None:
"""Allow setting parameters using attribute syntax (e.g., params.text = "Hello").
"""Allow setting parameters using attribute syntax.

This special method enables setting parameter values using attribute syntax
(e.g., params.text = "Hello"). It only works for parameters that have been
previously defined.

Args:
name (str): Name of the parameter
value (Any): Value to set for the parameter
name (str): Name of the parameter to set.
value (Any): Value to assign to the parameter.

Raises:
AttributeError: If attempting to set a parameter that hasn't been defined.
"""
if name == "parameters": # Allow setting the parameters dict normally
super().__setattr__(name, value)
Expand All @@ -75,16 +105,20 @@ def __setattr__(self, name: str, value: Any) -> None:
raise AttributeError(f"Parameter '{name}' is not defined")

def __getattr__(self, name: str) -> Any:
"""Allow getting parameter values using attribute syntax (e.g., params.text).
"""Allow getting parameter values using attribute syntax.

This special method enables accessing parameter values using attribute syntax
(e.g., params.text). It only works for parameters that have been previously
defined.

Args:
name (str): Name of the parameter
name (str): Name of the parameter to access.

Returns:
Any: Value of the parameter
Any: The value of the requested parameter.

Raises:
AttributeError: If parameter is not defined
AttributeError: If attempting to access a parameter that hasn't been defined.
"""
if name in self.parameters:
return self.parameters[name].value
Expand Down
20 changes: 20 additions & 0 deletions aixplain/decorators/api_key_checker.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,26 @@


def check_api_key(method):
"""Decorator to verify that an API key is set before executing the method.

This decorator checks if either TEAM_API_KEY or AIXPLAIN_API_KEY is set in the
configuration. If neither key is set, it raises an exception.

Args:
method (callable): The method to be decorated.

Returns:
callable: The wrapped method that includes API key verification.

Raises:
Exception: If neither TEAM_API_KEY nor AIXPLAIN_API_KEY is set.

Example:
@check_api_key
def my_api_method():
# Method implementation
pass
"""
def wrapper(*args, **kwargs):
if config.TEAM_API_KEY == "" and config.AIXPLAIN_API_KEY == "":
raise Exception(
Expand Down
2 changes: 1 addition & 1 deletion aixplain/enums/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@
from .asset_status import AssetStatus
from .index_stores import IndexStores
from .function_type import FunctionType
from .code_interpeter import CodeInterpreterModel
from .code_interpreter import CodeInterpreterModel
26 changes: 26 additions & 0 deletions aixplain/enums/asset_status.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,32 @@


class AssetStatus(Text, Enum):
"""Enumeration of possible status values for an asset in the aiXplain system.

This enum defines all possible states that an asset can be in throughout its lifecycle,
from creation to deletion. Each enum value corresponds to a specific state in the
asset's lifecycle.

Attributes:
DRAFT (str): Initial state for a newly created asset.
HIDDEN (str): Asset is hidden from public view.
SCHEDULED (str): Asset is scheduled for processing.
ONBOARDING (str): Asset is in the process of being onboarded.
ONBOARDED (str): Asset has been successfully onboarded.
PENDING (str): Asset is waiting for processing.
FAILED (str): Asset processing has failed.
TRAINING (str): Asset is currently in training.
REJECTED (str): Asset has been rejected.
ENABLING (str): Asset is in the process of being enabled.
DELETING (str): Asset is in the process of being deleted.
DISABLED (str): Asset has been disabled.
DELETED (str): Asset has been deleted.
IN_PROGRESS (str): Asset is currently being processed.
COMPLETED (str): Asset has completed processing.
CANCELING (str): Asset operation is being canceled.
CANCELED (str): Asset operation has been canceled.
DEPRECATED_DRAFT (str): Draft state that has been deprecated.
"""
DRAFT = "draft"
HIDDEN = "hidden"
SCHEDULED = "scheduled"
Expand Down
23 changes: 23 additions & 0 deletions aixplain/enums/code_interpreter.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
from enum import Enum


class CodeInterpreterModel(str, Enum):
"""Enumeration of available Code Interpreter model identifiers.

This enum defines the unique identifiers for different code interpreter models
available in the system. Each value represents a specific model's ID that can
be used for code interpretation tasks.

Attributes:
PYTHON_AZURE (str): Model ID for the Python code interpreter running on Azure.
"""

PYTHON_AZURE = "67476fa16eb563d00060ad62"

def __str__(self) -> str:
"""Return the string representation of the model ID.

Returns:
str: The model ID value as a string.
"""
return self._value_
10 changes: 10 additions & 0 deletions aixplain/enums/data_split.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,16 @@


class DataSplit(Enum):
"""Enumeration of dataset split types.

This enum defines the standard dataset split types used for machine learning tasks,
including training, validation, and testing splits.

Attributes:
TRAIN (str): Training dataset split used for model training.
VALIDATION (str): Validation dataset split used for model tuning.
TEST (str): Test dataset split used for final model evaluation.
"""
TRAIN = "train"
VALIDATION = "validation"
TEST = "test"
22 changes: 21 additions & 1 deletion aixplain/enums/data_subtype.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,21 @@


class DataSubtype(Enum):
"""Enumeration of data subtypes for categorizing and organizing data.

This enum defines various subtypes that can be used to further categorize
data points within the system, particularly useful for demographic and
content-based categorization.

Attributes:
AGE (str): Age category subtype.
GENDER (str): Gender category subtype.
INTERVAL (str): Time interval subtype.
OTHER (str): Miscellaneous/other subtype.
RACE (str): Race/ethnicity category subtype.
SPLIT (str): Data split category subtype.
TOPIC (str): Content topic subtype.
"""
AGE = "age"
GENDER = "gender"
INTERVAL = "interval"
Expand All @@ -33,5 +48,10 @@ class DataSubtype(Enum):
SPLIT = "split"
TOPIC = "topic"

def __str__(self):
def __str__(self) -> str:
"""Return the string representation of the data subtype.

Returns:
str: The data subtype value as a string.
"""
return self._value_
25 changes: 24 additions & 1 deletion aixplain/enums/data_type.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,24 @@


class DataType(str, Enum):
"""Enumeration of supported data types in the aiXplain system.

This enum defines all the data types that can be processed by the system,
including various media types and basic data types.

Attributes:
AUDIO (str): Audio data type.
FLOAT (str): Floating-point number data type.
IMAGE (str): Image data type.
INTEGER (str): Integer number data type.
LABEL (str): Label/category data type.
TENSOR (str): Tensor/multi-dimensional array data type.
TEXT (str): Text data type.
VIDEO (str): Video data type.
EMBEDDING (str): Vector embedding data type.
NUMBER (str): Generic number data type.
BOOLEAN (str): Boolean data type.
"""
AUDIO = "audio"
FLOAT = "float"
IMAGE = "image"
Expand All @@ -37,5 +55,10 @@ class DataType(str, Enum):
NUMBER = "number"
BOOLEAN = "boolean"

def __str__(self):
def __str__(self) -> str:
"""Return the string representation of the data type.

Returns:
str: The data type value as a string.
"""
return self._value_
11 changes: 10 additions & 1 deletion aixplain/enums/database_source.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,16 @@


class DatabaseSourceType(Enum):
"""Enum for database source types"""
"""Enumeration of supported database source types.

This enum defines the different types of database sources that can be used
for data storage and retrieval in the system.

Attributes:
POSTGRESQL (str): PostgreSQL database source type.
SQLITE (str): SQLite database source type.
CSV (str): CSV file source type.
"""

POSTGRESQL = "postgresql"
SQLITE = "sqlite"
Expand Down
18 changes: 17 additions & 1 deletion aixplain/enums/embedding_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,26 @@


class EmbeddingModel(str, Enum):
"""Enumeration of available embedding models in the aiXplain system.

This enum defines the unique identifiers for different embedding models that can
be used to generate vector representations of data.

Attributes:
OPENAI_ADA002 (str): OpenAI's Ada-002 text embedding model ID.
JINA_CLIP_V2_MULTIMODAL (str): Jina CLIP v2 multimodal embedding model ID.
MULTILINGUAL_E5_LARGE (str): Multilingual E5 Large text embedding model ID.
BGE_M3 (str): BGE-M3 embedding model ID.
"""
OPENAI_ADA002 = "6734c55df127847059324d9e"
JINA_CLIP_V2_MULTIMODAL = "67c5f705d8f6a65d6f74d732"
MULTILINGUAL_E5_LARGE = "67efd0772a0a850afa045af3"
BGE_M3 = "67efd4f92a0a850afa045af7"

def __str__(self):
def __str__(self) -> str:
"""Return the string representation of the embedding model ID.

Returns:
str: The model ID value as a string.
"""
return self._value_
23 changes: 23 additions & 0 deletions aixplain/enums/file_type.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,29 @@


class FileType(Enum):
"""Enumeration of supported file types in the aiXplain system.

This enum defines the file extensions for various file formats that can be
processed by the system, including document, audio, image, and video formats.

Attributes:
CSV (str): Comma-separated values file (.csv).
JSON (str): JSON document file (.json).
TXT (str): Plain text file (.txt).
XML (str): XML document file (.xml).
FLAC (str): Free Lossless Audio Codec file (.flac).
MP3 (str): MP3 audio file (.mp3).
WAV (str): Waveform audio file (.wav).
JPEG (str): JPEG image file (.jpeg).
PNG (str): Portable Network Graphics file (.png).
JPG (str): JPEG image file (.jpg).
GIF (str): Graphics Interchange Format file (.gif).
WEBP (str): WebP image file (.webp).
AVI (str): Audio Video Interleave file (.avi).
MP4 (str): MPEG-4 video file (.mp4).
MOV (str): QuickTime movie file (.mov).
MPEG4 (str): MPEG-4 video file (.mpeg4).
"""
CSV = ".csv"
JSON = ".json"
TXT = ".txt"
Expand Down
Loading