KubeAI Application Nucleus for edge (KAN) API defines a common object model that describes the full stack of intelligent Edge solutions, from AI models to solutions to devices and sensors. Because these objects are defined as standard Kubernetes custom resources, you can use popular Kubernetes tools like kubectl to manipulate these objects.
- AI model (
model.ai.symphony) - AI skill (
skill.ai.symphony) - Device (
device.fabric.symphony) - Target (
target.fabric.symphony) - Solution (
solution.solution.symphony) - Instance (
instance.solution.symphony)
The KAN portal experience aims to provide a streamlined experience of creating and managing intelligent Edge solutions leveraging cameras. Hence, we’ve hidden some KAN API concepts and renamed a few objects to make the UX more intuitive for target scenarios. The following table summarizes how portal concepts are mapped to API concepts:
| API Object | Portal Concept |
|---|---|
device.fabric.symphony |
Camera |
instance.solution.symphony |
Deployment |
model.ai.symphony |
AI Model |
skill.ai.symphony |
AI Skill |
solution.solution.symphony |
There are no solutions surfaced on portal. Essentially, a portal operates on a single, system-maintained solution object on behalf of the user. |
target.fabric.symphony |
Compute device |
Depending on your focus, you can start with the AI workflow, the device workflow, or the solution workflow as described below. At the end, you can create Instance objects which represent running deployments of your intelligent Edge solution.
- Create your AI model using tools of your choice.
- Once you have the AI model file, register your AI model with KAN as a
Modelobject. - Then define AI
Skillobjects that define processing pipelines. A processing pipeline reads data from a data source, applies one or more AI models (and other transformations), and sends inference results to designated outputs.
- Register your computational devices with KAN as
Targetobjects. You can also specify desired runtime components, such as a KAN agent, in your target definition. - Manually register your non-computational devices, such as sensors and actuators, as
Deviceobjects. You can also leverage projects like Akri to auto-discover devices.
- Define your intelligent solution as a
Solutionobject, which consists of a number ofComponentelements. A component is usually a container, and it may refer to AISkillobjects in its properties. - Define a
Instanceobject that maps aSolutionto one or multipleTargetobjects. Once the instance object is created, KAN ensures the impacted targets are updated according to the desired solution state and target state.
Note
The current version of KAN portal doesn't explicitly expose the Solution object. Behind the scenes, you always work with a single Solution object that is automatically managed. However, you can use KAN API to examine and update the object.
Assume that you are creating an intelligent edge solution that uses a website to show number of cars passing an intersection each hour. The following workflow describes how to create and deploy such a solution using KAN API.
-
Create or select a car detection model. KAN comes with a model zoo, which contains a car detection model you can use.
-
Register the model as a KAN
Modelobject. -
Define a KAN
Skillobject that defines a pipeline that:- Takes input from a camera;
- Sends frames to the car detection model;
- Collects inference results and sends detection events to an output (such as IoT Hub or an HTTP endpoint).
-
Define a KAN
Solutionobject that will create a Docker containerComponentthat takes theSkillas input and drives the inference process.Since KAN provides some containers out-of-the-box, you don't have to create these containers yousrelf.
-
Create your website container and add it as a
Componentof yourSolution. -
Define a
Targetthat represents a computer to which you want to deploy your solution. -
Define
Deviceobjects for cameras you want to use. TheseDeviceobjects are associated with yourTargetobject through labeling. -
Create a
Instanceobject that deploys yourSolutionto yourTarget.
Visit the KAN API Quickstart to try out the tutorials.
- For more information about KAN configuration, visit KAN Project: Setup guide.