Fast, secure network awakeness monitoring for SyftBox - ping members to see who's online and ready for interactive queries
Project description
Syft Awake 🚀
Fast, secure network awakeness monitoring for SyftBox - ping network members to see who's online and ready for interactive queries.
Quick Start
Installation
pip install syft-awake
Usage
import syft_awake as sa
# Ping a specific user
response = sa.ping_user("friend@example.com", "Are you free for a call?")
if response and response.status == sa.AwakeStatus.AWAKE:
print(f"{response.responder} is awake: {response.message}")
# Scan the entire network (auto-discovers users with syft-awake)
summary = sa.ping_network()
print(f"Network awakeness: {summary.awakeness_ratio:.1%}")
for user in summary.awake_users:
print(f"✅ {user} is awake")
What It Does
Auto-Installation: Simply importing the library automatically installs the SyftBox app to respond to pings.
Network Discovery: Automatically finds other SyftBox users who have syft-awake installed by scanning the local datasites directory.
Real-time Status: Get detailed availability info including status (awake/busy/sleeping), workload level, and capabilities.
API
Core Functions
ping_user(email, message="ping") - Ping a specific user
ping_network(user_emails=None) - Ping multiple users (auto-discovers if no list provided)
Status Types
AwakeStatus.AWAKE- Available for interactionAwakeStatus.BUSY- Available but occupiedAwakeStatus.SLEEPING- Not available
Use Cases
Team Collaboration
# Check if team is available before starting a meeting
team_emails = ["alice@company.com", "bob@company.com"]
summary = sa.ping_network(user_emails=team_emails)
if summary.awakeness_ratio > 0.5:
print("Enough people online for the meeting!")
Distributed Computing
# Find available compute nodes
summary = sa.ping_network()
light_workload_users = [
user for user in summary.awake_users
if sa.ping_user(user).workload == "light"
]
How It Works
- Server: Each user runs a small SyftBox app that responds to awakeness pings
- Client: Use this Python library to ping users and scan the network
- Security: Uses SyftBox's authenticated, file-based RPC system
- Discovery: Automatically finds users by scanning
/SyftBox/datasites/*/app_data/syft-awake
License
Apache 2.0
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file syft_awake-0.2.0.tar.gz.
File metadata
- Download URL: syft_awake-0.2.0.tar.gz
- Upload date:
- Size: 46.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.4.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6d0a3d9d9306fc92914de9736f69a12ee73cbc6973283496c87066bdc139eb7f
|
|
| MD5 |
27ac9199a7e8c3435afe069a3127dacc
|
|
| BLAKE2b-256 |
7ac673748d20812ab1de648d830c2077ae504776a3377e6e6fe7b9195a80e33a
|
File details
Details for the file syft_awake-0.2.0-py3-none-any.whl.
File metadata
- Download URL: syft_awake-0.2.0-py3-none-any.whl
- Upload date:
- Size: 14.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.4.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
06a2dfed2efa9f38d84cebf498707bfc6e12be765b2dfd39fdc09d40dc9c64e4
|
|
| MD5 |
1fddeff1ff73d01738525be36933d6a3
|
|
| BLAKE2b-256 |
65fff828cc5391e05bc36b9d071626e56d5bdce715c2c18168c799d4b91c6cdb
|