nFactorial
Build distributed agents that spawn more distributed sub-agents.
nFactorial is a distributed task queue for building reliable multi-agent systems. It makes the following trivial to implement:
- Agent Reliability: Automatic retries, backoff strategies, and recovery of dropped tasks from crashed workers.
- In-flight Task Management: Cancel, steer, and monitor running tasks.
- Spawning Sub Agents: Having an agent spawn multiple sub agents and wait for their completion before continuing.
- Deferred Tools: Pause the agent while it waits for long running tools to complete externally or wait for user approval before continuing.
- Observability: Built-in metrics dashboard and comprehensive logging
Installation
pip install nfactorial
Quick Start
from factorial import Agent, Orchestrator, AgentWorkerConfig, gpt_41
def get_weather(location: str) -> str:
return f"The weather in {location} is sunny and 72°F"
agent = Agent(
instructions="You help users get weather information.",
model=gpt_41,
tools=[get_weather],
)
# Create orchestrator
orchestrator = Orchestrator(
redis_host="localhost",
redis_port=6379,
redis_db=0,
redis_max_connections=50,
)
orchestrator.register_runner(
agent=agent, agent_worker_config=AgentWorkerConfig(workers=1)
)
# Run the system
if __name__ == "__main__":
orchestrator.run()
Usage Examples:
IDE Coding Agent
/docs/examples/code_agent
Multi-Agent
/docs/examples/multi_agent
Deliberations.ai
Metadata
Release files for nfactorial 0.1.30
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 |
|---|---|---|---|---|
| nfactorial-0.1.30.tar.gz | 77.0 kB | Without provenance | Details for nfactorial-0.1.30.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| nfactorial-0.1.30-py3-none-any.whl | Python 3 | none | any | Details for nfactorial-0.1.30-py3-none-any.whl |
Total release size: 165.9 kB
Release files / nfactorial-0.1.30.tar.gz
| Download URL | nfactorial-0.1.30.tar.gz |
|---|---|
| Size | 77.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e5d94c0610ddde064443325db5afa4cdcae44371c7f6d7bbecc29d9f50348d0c
|
|
BLAKE2b-256 checksum How to use checksums |
4a09fe7156efefef8853cac6b4c546bf2c36d776e198949d312c725e1388d77c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.0
|
Release files / nfactorial-0.1.30-py3-none-any.whl
| Download URL | nfactorial-0.1.30-py3-none-any.whl |
|---|---|
| Size | 88.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5e46166d5c345e4e78b9fe04dd87821e306cc9eff1fd044d84be605a1c7e971d
|
|
BLAKE2b-256 checksum How to use checksums |
12cc14b12be98252157b8ee1610d7a89b99d52cd125032a8258807851f3798a1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.0
|
Security for nfactorial 0.1.30
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.