stigmergy-autogen
Replace AutoGen's LLM-based speaker selection with deterministic pressure signals. Stop paying for an LLM call every time you need to pick who speaks next. Tasks, priorities, and dependencies drive selection instead.
AutoGen's default selection burns an LLM call per turn to decide who speaks. At 100+ turns that's real money and latency for a routing decision. Stigmergy makes the same decision in sub-millisecond time using pressure signals, and the cost doesn't change at 10,000 turns.
One-line integration with AutoGen v0.7+ SelectorGroupChat.
Install
pip install stigmergy-autogen
Usage
from autogen_agentchat.agents import AssistantAgent
from autogen_agentchat.teams import SelectorGroupChat
from stigmergy_autogen import StigmergySpeakerSelector
# Create AutoGen agents
researcher = AssistantAgent("researcher", model_client=model_client)
analyst = AssistantAgent("analyst", model_client=model_client)
writer = AssistantAgent("writer", model_client=model_client)
# Create stigmergy selector with tasks and dependencies
selector = StigmergySpeakerSelector(wake_threshold=0.4)
selector.register_task("research", agent_name="researcher", priority=0.8)
selector.register_task("analyze", agent_name="analyst", priority=0.6, deps=["research"])
selector.register_task("write", agent_name="writer", priority=0.5, deps=["analyze"])
# Use as SelectorGroupChat selector_func
team = SelectorGroupChat(
participants=[researcher, analyst, writer],
model_client=model_client,
selector_func=selector.select_speaker,
)
result = await team.run(task="Begin research on AI trends")
How It Works
The StigmergySpeakerSelector replaces AutoGen's default speaker selection:
- Each registered task deposits a pressure signal targeted at its agent
- On each turn, signals decay and the selector picks the agent with highest pressure
- Task dependencies are enforced — an agent won't be selected until its deps complete
- Completion signals propagate pressure to downstream agents
License
MIT
Metadata
Release files for stigmergy-autogen 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| stigmergy_autogen-0.2.0.tar.gz | 4.7 kB | Without provenance | Details for stigmergy_autogen-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| stigmergy_autogen-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for stigmergy_autogen-0.2.0-py3-none-any.whl |
Total release size: 9.7 kB
Release files / stigmergy_autogen-0.2.0.tar.gz
| Download URL | stigmergy_autogen-0.2.0.tar.gz |
|---|---|
| Size | 4.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
579380057dfe1633ba287d49f7e46a7b713d5cf0893b4aa03f19810e276de2a4
|
|
BLAKE2b-256 checksum How to use checksums |
bc9c3b05f9836026f70f512eb6912c9cb60196085e54c6f8ce83471dab9d1136
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.14
|
Release files / stigmergy_autogen-0.2.0-py3-none-any.whl
| Download URL | stigmergy_autogen-0.2.0-py3-none-any.whl |
|---|---|
| Size | 5.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2d25803eb2459383d97c95d7554d0e578926e4e8a2ab31d6272f46d5979bfdd0
|
|
BLAKE2b-256 checksum How to use checksums |
84bcdabce4a0bc22efa7a15d8348d84c36907473a07d9a102f180e12914b38d8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.14
|
Security for stigmergy-autogen 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.