Skip to main content

client for the arkitekt_next platform

Project description

arkitekt-next

codecov PyPI version Maintenance Maintainer PyPI pyversions PyPI status

streaming analysis for mikroscopy

Idea

arkitekt-next is the python client for the arkitekt_next platform. It allows you to utilize the full extent of the platform from your python code. To understand the idea behind arkitekt_next, you need to understand the idea behind the arkitekt_next platform. (More on this in the documentation)

Features

  • Host your python functions and make them to your team
  • Use functions from your team in your code
  • Interact with and store data in a secure and scalable way on the platform
  • Use the platform as a central storage for your data

Install

pip install arkitekt-next[all]

This installs all dependencies for the arkitekt_next platform, inlcuding the arkitekt_next CLI, which can be used to develop and create apps, containerize them and deploy t

arkitekt_next is relying heavily on asyncio patters and therfore supports python 3.8 and above. It also relies on the pydantic stack for serialization.

App

You can use the cli to create python based apps for the arkitekt_next platform, profiting from a battery of features like easy GUI creation based on type annotations, orchestration of real-time (in memoery) workflows, data hosting, easy packaging and distribution in docker containers, etc...

To get started create a directory and run

arkitekt-next init

Which will lead you throught an app creation process. Apps can simply registered functions, through the register decorator

from arkitekt_next import register

@register
def rpc_function(x: int, name: str) -> str
    """
    A rpc function that we can
    simple call from anywhere

    ""

And then connected to a local or remote server by running

Run example:

arkitekt-next run dev

For more details on how to create an app follow the tutorials on https://arkitekt.live.

Usage with complex Datastructures

ArkitektNext takes care of serialization and documentation of standard python datastructures

  • str
  • bool
  • int
  • float
  • Enum
  • Dict
  • List

To increase performance and reduce latency it is not possible to serialize complex python objects like numpy arrays into the messages. These are best transformed into immutable objects on a centrally accessible storage and then only the reference is passed.

ArkitektNext does not impose any rules on how you handle this storage (see mikro for ideas), it provides however a simple api.

class ComplexStructure:
    id: str # A reference for this structure on central storage

    async def shrink(self):
        return self.id

    @classmethod
    async def expand(cls, value):
        return cls.load_from_server(value)

by providing two functions:

  • shrink
  • expand

You can now use this Structure with simple typehints and arkitekt_next will automaticall shrink (serialize) and expand (deserialize) the structure on calling.

def complex_call(x: ComplexStrucuture) -> int:
    return x.max()

Check out the arkitekt_next documentation for usage of this libary

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

arkitekt_next-0.39.1.tar.gz (570.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

arkitekt_next-0.39.1-py3-none-any.whl (610.3 kB view details)

Uploaded Python 3

File details

Details for the file arkitekt_next-0.39.1.tar.gz.

File metadata

  • Download URL: arkitekt_next-0.39.1.tar.gz
  • Upload date:
  • Size: 570.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for arkitekt_next-0.39.1.tar.gz
Algorithm Hash digest
SHA256 8ef3706214cf3abd6f42e9360164f7797e29eedd818ae187fa0cef69153f111d
MD5 68408eac0047f17050154add539f5ca0
BLAKE2b-256 bbc3b597bff78372beb306826bbbc61400c49126c8b96cd2d804463cf94bad87

See more details on using hashes here.

File details

Details for the file arkitekt_next-0.39.1-py3-none-any.whl.

File metadata

  • Download URL: arkitekt_next-0.39.1-py3-none-any.whl
  • Upload date:
  • Size: 610.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for arkitekt_next-0.39.1-py3-none-any.whl
Algorithm Hash digest
SHA256 705a8c557b02c84216b83d9bfd9ddbc3919d3a6613ed827b6a75414d92d0a20b
MD5 7428c85eb743bf276a39601a313c97cc
BLAKE2b-256 4edeedd91727633583680075fca23de19724958f90c75f9f276a0e74432243c6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page