Ship your custom AI agents on Blaxel in a few clicks.
main.py
/ main.ts
) available on a local endpoint.
Run the following command to serve the agent:
--hotreload
to get live changes.
main.py
/ main.ts
) callable on a global endpoint. When deploying to Blaxel, your workloads are served optimally to dramatically accelerate cold-start and latency while enforcing your deployment policies.
Run the following command to build and deploy a local agent on Blaxel:
bl deploy
), the new traffic routing depends on the --traffic
option. Without this option specified, Blaxel will automatically deploy the new revision with full traffic (100%) if the previous deployment was the latest revision. Otherwise, it will create the revision without deploying it (0% traffic).--directory
(-d
) option:
blaxel.toml
file at the root of your directory.
For more information on agent deployment settings, refer to the reference section down at the bottom of this guide.
bl deploy
), the new traffic routing depends on the --traffic
option. Without this option specified, Blaxel will automatically deploy the new revision with full traffic (100%) if the previous deployment was the latest revision. Otherwise, it will create the revision without deploying it (0% traffic).type
so Blaxel knows which kind of entity to deploy. Others are not mandatory but allow you to customize the deployment.
name
, workspace
, and type
fields are optional and serve as default values. Any bl command run in the folder will use these defaults rather than prompting you for input.agents
, functions
, and models
fields are also optional. They specify which resources to deploy with the agent. These resources are preloaded during build, eliminating runtime dependencies on the Blaxel control plane and dramatically improving performance.[env]
section defines environment variables that the agent can access via the SDK. Note that these are NOT secrets.[runtime]
section allows to override agent deployment parameters: timeout (in s) or memory (in MB) to allocate.[[triggers]]
and [triggers.configuration]
sections defines ways to send requests to the agent. You can create both synchronous and asynchronous trigger endpoints (respectively type = "http"
or type = "http-async"
). You can also make them either private (default) or public (authenticationType = "public"
).
A private synchronous HTTP endpoint is always created by default, even if you don’t define any trigger here.bl deploy
runs, it generates a YAML configuration manifest automatically and deploys it to Blaxel’s hosting infrastructure. You can also create custom manifest files in the .blaxel
folder and deploy them using the following command: