Skip to main content

Mailbox Agents

CI Coverage License Python

PyPI benethos-mailbox-agents Container benethos-mailbox-agents

Sponsor PayPal

Small agents that work on a mailbox continuously. Each one looks at mail as it arrives or leaves, decides one narrow question about it and takes one reversible action: a keyword, or a move to a folder. The first ones sort invoices, track sent mail that still waits for a reply, recognise project inquiries and file the mail of listed senders into folders.

Status: alpha. Built, and run on a test account of invented mail. On a real mailbox only an early version of invoices ran, in the stage shadow, and changed nothing. Names, settings and the state file may still change from one version to the next. The design is written down in docs/CONCEPT.md, and no agent acts on a real mailbox yet. Do not point it at a mailbox you care about.

How it works

The mailbox service hands the change feed and a message to Mailbox Agents and takes a keyword or a move back. Each agent takes a message through four steps: trigger, selection, decision and effect. For a decision it asks a model once through an OpenAI-compatible gateway, without tools. The mailbox service stands on the mail accounts, the gateway on local or hosted model backends.
  • Mail is reached only through the REST API of the mailbox service, with its Python client benethos-mailbox-client. An agent works only against a version of the service it was tested against, today 0.8 from 0.8.0 and 0.9 from 0.9.0, and refuses any other. Which release works with which release of the service: docs/COMPATIBILITY.md.
  • A language model is reached only through an OpenAI-compatible gateway, with one call per message, a JSON schema for the answer and no tools.
  • Everything else is deterministic code: which messages an agent looks at, what a rule says, whether a quote from the model is really in the mail, and which action follows.
  • Every agent runs in a process of its own, with its own credentials and its own SQLite state file. The state file holds ids and decisions, never the text of a mail.
  • A new agent starts in the stage shadow, where it only records what it would do. The stages keyword and full follow after it was measured against labelled mail.

Install

The package is benethos-mailbox-agents on PyPI, for Python 3.11 or newer:

uvx benethos-mailbox-agents --version

In operation each agent runs as a container of the image ghcr.io/benethos-hub/benethos-mailbox-agents. containers/production holds the compose file and says how to set it up. Every setting is listed in docs/concept/configuration.md.

Development

Needs uv and a clone of the repository.

uv sync
uv run benethos-mailbox-agents --version
uv run pytest -q

The suite is offline. The live checks run against a mail server and a mailbox service of their own with invented mail, see containers/live.

Licence

MIT, see LICENSE.

Metadata

Release files for benethos-mailbox-agents 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for benethos-mailbox-agents 0.2.0
File Size Uploaded Provenance Actions
benethos_mailbox_agents-0.2.0.tar.gz 4.3 MB Without provenance Details for benethos_mailbox_agents-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for benethos-mailbox-agents 0.2.0
File Interpreter ABI Platform Actions
benethos_mailbox_agents-0.2.0-py3-none-any.whl Python 3 none any Details for benethos_mailbox_agents-0.2.0-py3-none-any.whl

Total release size: 4.4 MB

Release files / benethos_mailbox_agents-0.2.0.tar.gz

Download URL benethos_mailbox_agents-0.2.0.tar.gz
Size 4.3 MB
Tags Source
SHA-256 checksum
How to use checksums
8897ff519b0bde37b21dcead669e7c4a59e6acf0c4f018263e390358ebde14c7
BLAKE2b-256 checksum
How to use checksums
0a905af0eb7d224d7edb595a53cbc19a95420385ab9deb8489570528db0958ef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.9 {"installer":{"name":"uv","version":"0.13.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / benethos_mailbox_agents-0.2.0-py3-none-any.whl

Download URL benethos_mailbox_agents-0.2.0-py3-none-any.whl
Size 142.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b35b05655143ed4954ecd21baa369d91828a527c90790f7edaca57aac31aa27c
BLAKE2b-256 checksum
How to use checksums
5d0cbce3af08f340b9af924f49fcef799a5d25b71e2313e58811dc284bb28039
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.9 {"installer":{"name":"uv","version":"0.13.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for benethos-mailbox-agents 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page