BX Agents
Describe an agent in folders and files; build it into a real ColdBox application.
BX Agents is a conventions-based AI agent framework for BoxLang,
built on ColdBox and
BX AI. You describe an agent
with files and folders - not a framework's API surface - and bxAgents build assembles a
real, runnable ColdBox application out of it.
Discovery, validation and code generation run once, not on every boot. What you run afterwards is a plain ColdBox app.
Agent.bx and instructions.md are the only required files. Every other convention folder
is optional and only shapes the output if it exists.
Drop an @AITool-annotated function into tools/, or a SKILL.md folder into skills/ -
both are discovered and wired for you.
subagents/ nests the exact same convention tree, so a team of specialists is just more
folders - built leaf-first.
Telegram, Slack, Discord, Email, WhatsApp, Teams, Twilio, GitHub and Signal, plus http,
cli and mock.
Ask for it in Agent.bx and the build produces a themeable, streaming chat front end with
session history.
Build one in four steps
install-bx-module bx-ai bx-agents
box install bx-ai,bx-agents
bxAgents new my-agent --model=openai/gpt-5
Then edit instructions.md and add whichever convention folders you need.
bxAgents build
Discovery, validation, manifest, code generation - into .build/app/.
bxAgents chat
# or serve it over HTTP:
bxAgents serve --port=8080
What build actually produces
Your convention tree, and the plain ColdBox application build turns it into.
your-agent/
βββ Agent.bx # name, model, description
βββ instructions.md # the system prompt
βββ tools/ # @AITool functions
βββ skills/ # SKILL.md capabilities
βββ subagents/ # nested agent trees
βββ models/ # named model configs
βββ gateways/ # HTTP/MCP/chat exposure
βββ schedules/ # a real ColdBox scheduler
βββ mcp/ # MCP servers you host
βββ interceptors/ # lifecycle hooks
βββ modules/ # module dependencies
.build/app/
βββ Application.bx
βββ config/
β βββ ColdBox.bx
β βββ WireBox.bx
β βββ Router.bx
β βββ Scheduler.bx
βββ agent/
β βββ GeneratedAgentFactory.bx
βββ tools/ skills/ mcp/
βββ handlers/ interceptors/
βββ index.bxm
Only Agent.bx is required. instructions.md is optional - set instructions directly
in the class, or drop the file in and let the build wire it in. Every other folder only
affects the generated output if it exists and has content in it - so you add
conventions as you actually need them.
Agent.bx extends BX AI's own AiAgent directly - the build instantiates your class
rather than rebuilding one from a config struct, so what you write is what runs, and an
IDE can introspect it like any other class. See Agent.bx.
Reach it from anywhere
Nine push-style gateways - Telegram, Slack, Discord, Email, WhatsApp Cloud, Teams, Twilio,
GitHub and Signal - coordinated by one session with queue / steer / interrupt policies.
Expose the agent over HTTP routes, or host local MCP servers from mcp/ so other clients
can call your tools.
Package a portable .bxa and deploy it with local, ssh, docker, digitalocean,
ftp or sftp - secrets stay environment variables, never build artifacts.
Where to go next
Install BoxLang, BX AI and BX Agents.
Scaffold, build and chat with your first agent.
One page per convention folder, start to finish.
Exactly what build does, in order.
Every verb and its flags.
Package a .bxa and ship it, safely.
Every convention folder also has a working, buildable sample under
examples/.
BX Agents is under active development. Known Limitations tracks
the honest gaps - what's tested against a real running app, what still only runs against
BX AI's "mock" provider, and one real upstream ColdBox quirk this project ran into and
worked around.
