AgentPi is a signal-driven edge intelligence runtime designed for Raspberry Pi and similar edge devices. It converts real-world sensor signals into context-aware agent behaviors using a modular, event-driven architecture.
python -m venv .venv
source .venv/bin/activate
python -m pip install -U pip
python -m pip install -e .
python -m agentpi --duration 10Note: This repo contains a minimal demo pipeline that runs a mock signal adapter, processes signals into events, updates context, and activates a summarizer agent.
AgentPi follows a signal β observation β event β context β activation β agent pipeline.
- Signal ingestion (adapters)
- Observation creation (cognition)
- Event generation (cognition)
- Context update (context builder)
- Activation evaluation (activation engine)
- Agent responses (agents)
- Persistence (memory)
agentpi/β core Python packageadapters/β signal producers (hardware, mock, etc.)core/β runtime, event bus, orchestratorcognition/β perception, event detection, fusionmemory/β persistence (event logs, context snapshots)agents/β behavior implementations (summarizers, alerts)workflows/β higher-level orchestrationsschemas/β shared data models (Signal, Event, Context)config/β runtime configuration and defaults
tests/β automated unit tests
AgentPi supports configuration via:
- YAML file (passed via
--config) - Environment variables using the
AGENTPI_prefix - CLI override (e.g.,
--duration)
Example config file (agentpi.yml):
adapter: mock
poll_interval_seconds: 0.5
log_level: INFO
run_duration_seconds: 20Run with config:
python -m agentpi --config agentpi.ymlEnvironment variables override defaults:
export AGENTPI_POLL_INTERVAL_SECONDS=0.2
python -m agentpipython -m pytestFeel free to add new adapters, agents, workflows, and cognition rules. Keep modules small and preferring async patterns.
This project is released under the MIT License.