Albus AgentOS - Event-driven AI agent runtime
Project description
AlbusOS
AlbusOS is an event-driven AI agent runtime.
Core Abstractions
Agent → Skills → Pathways → Nodes
Pack → Pathways → Nodes (deployment bundles)
- Agent: Persistent AI entity with identity, memory, skills, and goals
- Skill: Pathway wrapped as an agent capability
- Pack: Deployable unit with pathways, triggers, and tool requirements
- Pathway: Execution graph (nodes + connections)
- Node: Atomic compute unit (LLM, Tool, Transform, AgentLoop, etc.)
- Trigger: Event source that invokes a pathway (webhook, timer, MCP)
Quickstart (local dev)
Prereqs
Install
uv sync
cp env.example .env
Edit .env or use the defaults:
- Local-first (default): Just run Ollama with
qwen2.5:7bandllama3.1:8b - Cloud fallback: Set
OPENAI_API_KEYfor vision/speech capabilities
The system is local-first by default—no cloud API keys required for basic operation.
Run the server
uv run albus server --debug
Verify:
curl http://127.0.0.1:8080/api/v1/health
Launch terminal Studio
uv run albus studio --thread-id demo
Building Agents
Agents are persistent AI entities with identity, memory, and skills. Skills wrap pathways as capabilities.
from pathway_engine.domain.agent.builder import agent_builder
from pathway_engine.domain.agent.skill import skill_builder
from agents.registry import agent
from packs.research.pathways import build_deep_analysis_pathway
# Wrap a pathway as a skill
research_skill = (
skill_builder()
.id("deep_research")
.name("Deep Research")
.description("In-depth research using web search and synthesis")
.pathway(build_deep_analysis_pathway)
.input("query", "string - the research topic")
.output("response", "string - synthesized findings")
.build()
)
# Create the agent
@agent
def RESEARCH_ASSISTANT():
return (
agent_builder()
.id("research_assistant")
.name("Research Assistant")
.persona("You are a thorough research assistant who cites sources.")
.goal("Find accurate information")
.goal("Synthesize findings clearly")
.skill(research_skill)
.tool("web.*")
.tool("memory.*")
.as_reasoning_agent()
.max_steps(15)
.build()
)
Running an Agent Turn
curl -X POST http://localhost:8080/api/v1/agents/research_assistant/turn \
-H "Content-Type: application/json" \
-d '{
"message": "Research quantum computing developments in 2024",
"thread_id": "conv_123"
}'
See src/agents/README.md for full documentation.
Building Packs
Packs are deployable bundles of pathways and triggers.
from pathway_engine import pack_builder, Pack, Pathway, LLMNode
from packs.registry import deployable
@deployable
def MY_PACK():
"""Define and register a pack."""
return (
pack_builder()
.id("my_pack")
.name("My Pack")
.version("1.0.0")
.trigger(
id="on_request",
source="webhook",
pathway="my_pack.respond.v1",
)
.pathway("my_pack.respond.v1", build_respond_pathway)
.build()
)
def build_respond_pathway() -> Pathway:
"""Build the main pathway."""
return Pathway(
id="my_pack.respond.v1",
nodes={
"respond": LLMNode(
id="respond",
prompt="You are helpful. Respond to: {{message}}",
model="auto",
),
},
)
Deploying Packs and Agents
Configure in albus.yaml:
packs: ["*"] # Deploy all registered packs
agents: ["*"] # Deploy all registered agents
Or deploy at runtime:
# Deploy packs
curl -X POST http://localhost:8080/api/v1/packs/deploy \
-H "Content-Type: application/json" \
-d '{"pack_ids": ["research"]}'
# Deploy agents
curl -X POST http://localhost:8080/api/v1/agents/deploy \
-H "Content-Type: application/json" \
-d '{"agent_ids": ["research_assistant"]}'
Model Routing (Local-First)
AlbusOS automatically routes tasks to the best model:
| Task | Default Model | Provider |
|---|---|---|
| Tool calling | qwen2.5:7b |
Ollama |
| Code generation | qwen2.5-coder:7b |
Ollama |
| Reasoning | llama3.1:8b |
Ollama |
| Vision | gpt-4o |
OpenAI (fallback) |
Configure via albus.yaml:
models:
default_profile: local
routing:
tool_calling: qwen2.5:7b
code: qwen2.5-coder:7b
reasoning: llama3.1:8b
API Surface
The server is versioned under /api/v1:
Core Endpoints
GET /api/v1/health- Health checkGET /api/v1/help- Detailed endpoint helpGET /api/v1/tools- List available toolsGET /api/v1/docs- Swagger UI
Agent API
GET /api/v1/agents- List available agentsGET /api/v1/agents/deployed- List deployed agentsPOST /api/v1/agents/deploy- Deploy agentsGET /api/v1/agents/{id}- Get agent detailsPOST /api/v1/agents/{id}/turn- Run an agent turn
Pack API
GET /api/v1/packs- List available packsGET /api/v1/packs/deployed- List deployed packsPOST /api/v1/packs/deploy- Deploy packs
Pathway API
GET /api/v1/pathways- List pathwaysPOST /api/v1/pathways- Create pathwayPOST /api/v1/pathways/{id}/run- Run a pathwayGET /api/v1/pathways/{id}/export- Export pathway
Real-time
GET /api/v1/ws- WebSocket (events + JSON-RPC)POST /api/v1/webhooks/{topic}- Trigger webhook event
Model Config
GET /api/v1/config/models- View routing configPATCH /api/v1/config/models- Update routing
Code Execution + Sandboxing
AlbusOS supports sandboxed Python execution:
- Tool:
code.execute(stdlib tool) - Isolation: Docker (default) or local (dev-only)
Configure via env vars:
AGENT_STDLIB_CODE_SANDBOX_MODE:docker(default) orlocalAGENT_STDLIB_CODE_SANDBOX_DOCKER_IMAGE: default image
Architecture
shared_types (bottom)
↑
pathway_engine (runtime kernel + agent domain)
↑
stdlib (tools + LLM routing)
↑
persistence (storage)
↑
packs (deployable pathway bundles)
↑
agents (persistent AI entities)
↑
albus (top — product runtime + transports)
See docs/ARCHITECTURE.md for details.
Available Agents
| Agent | Description | Skills |
|---|---|---|
research_assistant |
Thorough research with source citation | deep_research, quick_search |
Available Packs
| Pack | Description | Pathways |
|---|---|---|
quickstart |
Minimal demo | 1 |
research |
Web search + analysis | 2 |
viz |
Diagram generation | 1 |
dataanalysis |
ML-powered analysis | 6 |
timesheet |
Timesheet extraction | 1 |
ontology |
Ontology extraction | 1 |
Contributing
docs/DEVELOPMENT.mddocs/ARCHITECTURE.mdsrc/agents/README.mdsrc/packs/README.mdCONTRIBUTING.md
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file albusos-0.4.0.tar.gz.
File metadata
- Download URL: albusos-0.4.0.tar.gz
- Upload date:
- Size: 327.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
95b38c06cb34dd727e7ed67ef0300c591348bb5f7f5e6cfc7130890e22a676c9
|
|
| MD5 |
3f27ab8583673c65f13b94228e9492d2
|
|
| BLAKE2b-256 |
d8f4c6451022a17a2f818ce66fc0497545281820d6a6406668f73ad9b6cdad8b
|
Provenance
The following attestation bundles were made for albusos-0.4.0.tar.gz:
Publisher:
deploy.yml on albusOS/AlbusOS
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
albusos-0.4.0.tar.gz -
Subject digest:
95b38c06cb34dd727e7ed67ef0300c591348bb5f7f5e6cfc7130890e22a676c9 - Sigstore transparency entry: 869231425
- Sigstore integration time:
-
Permalink:
albusOS/AlbusOS@adcd971c12a65f37d95bd858bb6aafabf2bb37e7 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/albusOS
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
deploy.yml@adcd971c12a65f37d95bd858bb6aafabf2bb37e7 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file albusos-0.4.0-py3-none-any.whl.
File metadata
- Download URL: albusos-0.4.0-py3-none-any.whl
- Upload date:
- Size: 446.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
99b069b39141471cb6aade31fae18ea53bce7edde95238d64f2e8879e13c6782
|
|
| MD5 |
c8e11765d4adb2e416d559ad5e760cfd
|
|
| BLAKE2b-256 |
d8ba97b6023008f120a061075c4d81442458de25d06183fa5d59cac5f2de20af
|
Provenance
The following attestation bundles were made for albusos-0.4.0-py3-none-any.whl:
Publisher:
deploy.yml on albusOS/AlbusOS
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
albusos-0.4.0-py3-none-any.whl -
Subject digest:
99b069b39141471cb6aade31fae18ea53bce7edde95238d64f2e8879e13c6782 - Sigstore transparency entry: 869231427
- Sigstore integration time:
-
Permalink:
albusOS/AlbusOS@adcd971c12a65f37d95bd858bb6aafabf2bb37e7 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/albusOS
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
deploy.yml@adcd971c12a65f37d95bd858bb6aafabf2bb37e7 -
Trigger Event:
workflow_dispatch
-
Statement type: