ai-api-client-sdk


Nameai-api-client-sdk JSON
Version 1.27.0 PyPI version JSON
download
home_pagehttps://www.sap.com/
SummaryAI API Client SDK
upload_time2023-05-15 15:45:46
maintainer
docs_urlNone
authorSAP SE
requires_python>=3.7
licenseSAP DEVELOPER LICENSE AGREEMENT
keywords sap ai core
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            
# SAP AI API Client SDK

The AI API client SDK is a Python-based SDK that enables you to access the AI API using Python methods and data structures. You can use the Client SDK to test AI API.

The client SDK can be used with any implementation of AI API. Because it is independent of the runtime implementation, it doesn't provide access to runtime-specific APIs. For example, maintaining object store secrets is specific to SAP AI Core and is therefore not included in the AI API client SDK. Check for SDK offerings for your runtime that let you access any runtime-specific APIs. For more information on SAP AI Core SDK see <https://pypi.org/project/ai-core-sdk/>.

For more information on the AI API specification, SAP AI Core and related topics, please refer to <https://help.sap.com/docs/AI_CORE?version=CLOUD>.

## Example Usage

```python
from ai_api_client_sdk.ai_api_v2_client import AIAPIV2Client

# Instantiate the client
client = AIAPIV2Client(base_url=AI_API_URL,
    auth_url=AUTH_URL,
    client_id=CLIENT_ID,
    client_secret=CLIENT_SECRET, resource_group=RESOURCE_GROUP)

# Make some queries, e.g.
scenarios = client.scenario.query()

for scenario in scenarios.resources:
    print(scenario.id)

# Find a deployable executables in scenario 1111
executables = client.executable.query(scenario_id="1111")
for executable in executables.resources:
    if executable.deployable == False:
        break
print(executable.id)

# Inspect the required parameters for the executable
for parameter in executable.parameters:
    print("Parameter:{}, Type: {}".format(parameter.name, parameter.type))

# Create a configuration
parameter_epochs = ParameterBinding(key="training-epochs", value="1")
myConfiguration = client.configuration.create(name="test", scenario_id="1111" executable_id="argo-mnist-0.2.1", parameter_bindings=[parameter_epochs])
```


            

Raw data

            {
    "_id": null,
    "home_page": "https://www.sap.com/",
    "name": "ai-api-client-sdk",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.7",
    "maintainer_email": "",
    "keywords": "SAP AI Core",
    "author": "SAP SE",
    "author_email": "",
    "download_url": "https://pypi.python.org/pypi/ai-api-client-sdk",
    "platform": "Windows",
    "description": "\n# SAP AI API Client SDK\n\nThe AI API client SDK is a Python-based SDK that enables you to access the AI API using Python methods and data structures. You can use the Client SDK to test AI API.\n\nThe client SDK can be used with any implementation of AI API. Because it is independent of the runtime implementation, it doesn't provide access to runtime-specific APIs. For example, maintaining object store secrets is specific to SAP AI Core and is therefore not included in the AI API client SDK. Check for SDK offerings for your runtime that let you access any runtime-specific APIs. For more information on SAP AI Core SDK see <https://pypi.org/project/ai-core-sdk/>.\n\nFor more information on the AI API specification, SAP AI Core and related topics, please refer to <https://help.sap.com/docs/AI_CORE?version=CLOUD>.\n\n## Example Usage\n\n```python\nfrom ai_api_client_sdk.ai_api_v2_client import AIAPIV2Client\n\n# Instantiate the client\nclient = AIAPIV2Client(base_url=AI_API_URL,\n    auth_url=AUTH_URL,\n    client_id=CLIENT_ID,\n    client_secret=CLIENT_SECRET, resource_group=RESOURCE_GROUP)\n\n# Make some queries, e.g.\nscenarios = client.scenario.query()\n\nfor scenario in scenarios.resources:\n    print(scenario.id)\n\n# Find a deployable executables in scenario 1111\nexecutables = client.executable.query(scenario_id=\"1111\")\nfor executable in executables.resources:\n    if executable.deployable == False:\n        break\nprint(executable.id)\n\n# Inspect the required parameters for the executable\nfor parameter in executable.parameters:\n    print(\"Parameter:{}, Type: {}\".format(parameter.name, parameter.type))\n\n# Create a configuration\nparameter_epochs = ParameterBinding(key=\"training-epochs\", value=\"1\")\nmyConfiguration = client.configuration.create(name=\"test\", scenario_id=\"1111\" executable_id=\"argo-mnist-0.2.1\", parameter_bindings=[parameter_epochs])\n```\n\n",
    "bugtrack_url": null,
    "license": "SAP DEVELOPER LICENSE AGREEMENT",
    "summary": "AI API Client SDK",
    "version": "1.27.0",
    "project_urls": {
        "Download": "https://pypi.python.org/pypi/ai-api-client-sdk",
        "Homepage": "https://www.sap.com/"
    },
    "split_keywords": [
        "sap",
        "ai",
        "core"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0bba5e27070429ccf25c7738dc1d827338964d8f76bf09a558149f4759ebe5f9",
                "md5": "6b9f4e25611f072724941afb848ccde7",
                "sha256": "a0b1cec4e91124f45af380123eaa5a9ca26a2cceab82ef34125a6a06f1684293"
            },
            "downloads": -1,
            "filename": "ai_api_client_sdk-1.27.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "6b9f4e25611f072724941afb848ccde7",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.7",
            "size": 234966,
            "upload_time": "2023-05-15T15:45:46",
            "upload_time_iso_8601": "2023-05-15T15:45:46.579473Z",
            "url": "https://files.pythonhosted.org/packages/0b/ba/5e27070429ccf25c7738dc1d827338964d8f76bf09a558149f4759ebe5f9/ai_api_client_sdk-1.27.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-05-15 15:45:46",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "ai-api-client-sdk"
}
        
Elapsed time: 0.06536s