Browse documentation

Start here

OverviewGetting startedThe mental model

Use the runtime

Run the simulatorPi Agent and workspaceInstall and manage AppsESP32-P4 reference targetESP32-S3 supported target

Build Apps

App developer guideBuild your first AppApp source and packageData and migrationsActions and ToolsView and interactionNetworking and native servicesApp resourcesSchedulesPackage and updateTesting and debugging

Understand the runtime

Runtime flowGuests and lifecycleLayers and ownershipHarness boundary

Security

Trust and capabilitiesData isolationLifecycle and recovery

Reference

App manifestPocketPi APIView APICLI referenceLimits and compatibility

Examples

Exa App walkthroughRobinhood App walkthrough

Project

Current boundariesValidation status

Layers and ownership

The architecture is easiest to maintain when product policy stays in editable App/System source and mechanisms that require trust, bounds or hardware authority stay native.

Runtime composition

PocketPi product runtime
├── resident Harness + System App
├── App model, routing, schedules, lifecycle and recovery
├── installable ordinary Apps
├── PocketJS / QuickJS execution and UI
└── native host capabilities
    └── target platform: hardware + drivers + OS/RTOS services

PocketPi is the product-level runtime across these pieces. It is not defined by the lower scheduler/kernel layer; the target host uses that layer to implement storage, networking, clocks, threads, drivers and display/touch.

Layer responsibilities

LayerOwnsDoes not own
Agent Harnessmodel/tool loop, messages, turn state and Tool callingdevice credentials, App schema or rendering
PocketPiresident System lifecycle, App catalog/routing, schedules, install/update/uninstall and ownership rulesgeneric UI layout implementation or domain product logic
PocketJSGuest/module contracts, retained UI, layout, text and DrawList generationwhich App is installed, which Tool belongs to it or which App is foreground
Ordinary Appdomain Tools, Actions, schema, provider mapping, resources and Viewglobal workspace, raw secrets or hardware drivers
Native hosthardware, storage enforcement, credentials, TLS/transport, limits and rendering adapterRobinhood/Exa semantics or View policy

Mechanism versus policy examples

Mechanism stays nativePolicy stays in source
credential storage and header applicationwhich credential id/endpoint an App declares
one SQLite owner and read/write enforcementtables, queries, normalization and retention
Tool route lookup and Action deadlineTool description, JSON Schema and Action behavior
touch coordinates and PocketJS DrawList renderinglayout, screens, content and interaction events
scheduler clock and durable cursorwhich App Action runs and with what args

Changes and delivery boundary

ChangeDelivery
native host, PocketJS platform, AppSupervisor or System FrameworkFirmware build and flash
Pi Agent Root View or resident Harness bundleFirmware build and flash today
ordinary App manifest, schema, Actions, resources or ViewPackage and install/update .pocketapp
ordinary App DataAction transaction; no release delivery

Repository map

apps/                       System App and ordinary App source
system/                     shared Framework, net SDK and View SDK
crates/pocket-pi-agentos/   AppSupervisor and App contracts
crates/pocket-pi-embedded/  embedded resident Harness bridge
crates/pocket-pi-tools/     native workspace/device/schedule Tools
crates/pocket-pi-protocols/ model/provider codecs
hosts/esp32-sim/            macOS product-contract simulator
firmware/esp32-common/      shared ESP-IDF AgentOS host mechanisms
firmware/esp32-p4/          reference physical host
firmware/esp32-s3/          Waveshare ESP32-S3-Touch-LCD-4.3 host
tools/                      build, provision and App ingress CLIs

Canonical implementation design: docs/agentos-architecture.md.