SDK library for building services for the IVCAP platform
Project description
ivcap-service: A python library for building services for the IVCAP platform
A python library containing various helper and environment functions to simplify developing services to be deployed on IVCAP.
Note: A template git repository using this library can be found on github ivcap-works/ivcap-python-ai-tool-template. You may clone that and start from there.
Describe the service
logging_init()
logger = getLogger("app")
service = Service(
name="Some service",
contact={
"name": "Mary Doe",
"email": "mary.doe@acme.au",
},
license_info={
"name": "MIT",
"url": "https://opensource.org/license/MIT",
},
)
class Request(BaseModel):
jschema: str = Field("urn:sd:schema:some_tool.request.1", alias="$schema")
...
class Result(BaseModel):
jschema: str = Field("urn:sd:schema:some_tool.1", alias="$schema")
...
def some_service(req: Request) -> Result:
"""
Here should go a quite extensive description of what the service can be
used for so that an agent can work out if this service is useful in
a specific context.
DO NOT ADD PARAMTER AND RETURN DECRIPTIONS -
DESCRIBE THEM IN THE `Request` MODEL
"""
...
return Result(...)
Start the Service
if __name__ == "__main__":
from ivcap_service import start_batch_service
some_service(service, consume_compute)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ivcap_service-0.5.8.tar.gz
(16.8 kB
view details)
Built Distribution
File details
Details for the file ivcap_service-0.5.8.tar.gz
.
File metadata
- Download URL: ivcap_service-0.5.8.tar.gz
- Upload date:
- Size: 16.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.2 CPython/3.10.10 Darwin/24.3.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
ad799fa7840b0d483a28ff373a1672adf32cf3f3ff355adde840f19e4ad2eba1
|
|
MD5 |
4479e1dec5ad4391912a811e64c76782
|
|
BLAKE2b-256 |
199489da7cecb651f1232fc4e2f53c8f0571c1d5d4ffed4c3bf5832fa4db280f
|
File details
Details for the file ivcap_service-0.5.8-py3-none-any.whl
.
File metadata
- Download URL: ivcap_service-0.5.8-py3-none-any.whl
- Upload date:
- Size: 23.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.2 CPython/3.10.10 Darwin/24.3.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
6902641cd5bdcf2edb3d6cc70bdb3a2c434c48f4f4112a5b5af3ca6a0c5d830a
|
|
MD5 |
6beded0923ae431979096eb4ef35651d
|
|
BLAKE2b-256 |
feaeace8e224a1896f3f48b872112299863e8ee804d38a55bbd8279b5ddc655f
|