cross-machine-coordination
Skill3.4k starsChanged 2 months agoMITView on GitHub
Design proposal, not implemented: git-based task queuing between squad machines. For competing watchers, use squad watch work claims (ADR-002).
- Commits and pushes
2 other projects use a version of this, 2 of them edited.
Adopted by
Most recently taken up by
- microsoft/github-vteam-industry-demosedited, first seen Oct 25, 2026
- github/gh-awedited, first seen May 27, 2026
Other versions2 projects use a version of this.
Word for word · 0
None found.
Edited · 2
- github/gh-aw★ 5.6k91% same
- microsoft/github-vteam-industry-demos★ 291% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository247 other files it gives its agents.
- .github/agents.mdAGENTS.md
- .github/copilot-instructions.mdCopilot instructions
- packages/squad-cli/templates/copilot-instructions.mdCopilot instructions
- packages/squad-sdk/templates/copilot-instructions.mdCopilot instructions
- .squad-templates/copilot-instructions.mdCopilot instructions
- .squad/templates/copilot-instructions.mdCopilot instructions
- templates/copilot-instructions.mdCopilot instructions
- action-skill-contractsSkill
- agent-collaborationSkill
- agent-conductSkill
- architectural-proposalsSkill
- architectural-reviewSkill
- archival-integritySkill
- ci-validation-gatesSkill
- client-compatibilitySkill
- cli-wiringSkill
- content-scopeSkill
- distributed-meshSkill
- documentation-maintenanceSkill
- github-multi-accountSkill
- git-workflowSkill
- history-hygieneSkill
- init-modeSkill
- model-selectionSkill
- pr-lifecycleSkill
- protected-filesSkill
- release-processSkill
- reskillSkill
- reviewer-protocolSkill
- secret-handlingSkill
- security-reviewSkill
- squad-conventionsSkill
- test-disciplineSkill
- windows-compatibilitySkill
- agentic-workflow-designerSkill
- gh-aw-reliabilitySkill
- iterative-retrievalSkill
- reflectSkill
- {skill-name}Skill
- agent-collaborationSkill
- agent-conductSkill
- architectural-proposalsSkill
- ci-validation-gatesSkill
- client-compatibilitySkill
- cli-wiringSkill
- coordinator-init-modeSkill
- coordinator-response-modeSkill
- coordinator-source-of-truthSkill
- cross-squad-communicationSkill
- cross-squadSkill
- distributed-meshSkill
- docs-standardsSkill
- e2e-template-testingSkill
- economy-modeSkill
- error-recoverySkill
- external-commsSkill
- fact-checkingSkill
- gh-auth-isolationSkill
- gh-aw-enlistmentSkill
- github-multi-accountSkill
- The first 60 shown.
The file
Show its rules and text
We split this skill into the rules it gives an agent
14 rules. About 0 are common, 10 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈10
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 13
Squad Integration: All agents
- Very specific: line 79
Write result to .squad/cross-machine/results/gpu-voice-clone-001.yaml
- Distinctive: line 80
Commit & push the result
- Distinctive: line 183
All tasks go through:
- Distinctive: line 188
No unexpected fields (reject)
- Distinctive: line 191
Only approved commands allowed
- Very specific: line 194
No inline shell operators (&&, |, >)
- Distinctive: line 208
All executions logged to git
- Distinctive: line 209
Commit signed with Ralph's key
- Distinctive: line 351
If a task fails (exit code != 0):
- Distinctive: line 360
If a task doesn't complete within timeout:
- Distinctive: line 369
If git push/pull fails:
- Distinctive: line 373
No tasks lost (stored in local repo)
- Very specific: line 409
Not implemented: squad watch does not include this pattern.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Skill: Cross-Machine Coordination Pattern
Skill ID: cross-machine-coordination
Owner: Ralph (Work Monitor)
Squad Integration: All agents
Status: Design proposal — NOT implemented
⚠️ Not implemented. No Squad release reads
.squad/cross-machine/, thecross_machineconfig block, orsquad:machine-{name}labels. Ralph andsquad watchdo not poll task files, run whitelisted commands, or write result files. Everything below describes a proposed design, not current behavior. Do not tell users it works, and do not create task files expecting another machine to pick them up.Use these instead:
- Several machines or pods running
squad watch --executeon one repository: enable work claims (squad watch --execute --claims git-ref, orwatch.claimsin.squad/config.json). Claims are Git-ref leases that make sure only one watcher works on each issue. See ADR-002 (docs/specification/adr-002-work-claims-and-external-queues.md) and the "Multi-Machine Watch with Work Claims" docs scenario (docs/src/content/docs/scenarios/multi-machine-watch.md).- Sending work to a machine with specific hardware: use capability routing with
needs:*issue labels and a machine capabilities file.
Overview
Enables squad agents running on different machines (laptop, DevBox, Azure VM) to securely share work, coordinate execution, and pass results without manual intervention.
Pattern: Git-based task queuing + GitHub Issues supplement
Usage
For Task Sources (Orchestrating Machine)
To assign work to DevBox:
# Create task file
cat > .squad/cross-machine/tasks/2026-03-14T1530Z-laptop-gpu-voice-clone.yaml << 'EOF'
id: gpu-voice-clone-001
source_machine: laptop-machine
target_machine: devbox
priority: high
created_at: 2026-03-14T15:30:00Z
task_type: gpu_workload
payload:
command: "python scripts/voice-clone.py --input voice.wav --output cloned.wav"
expected_duration_min: 15
resources:
gpu: true
memory_gb: 8
status: pending
EOF
# Commit & push
git add .squad/cross-machine/tasks/
git commit -m "Cross-machine task: GPU voice cloning [squad:machine-devbox]"
git push origin mainIn this proposal (not implemented), Ralph on DevBox would:
- Pull the task on next cycle (5-10 min)
- Validate schema & command whitelist
- Execute the GPU workload
- Write result to
.squad/cross-machine/results/gpu-voice-clone-001.yaml - Commit & push the result
For Task Executors (DevBox, Azure VMs)
In this proposal (not implemented), Ralph would watch .squad/cross-machine/tasks/ for work targeted at this machine. Ralph does not do this today.
On each cycle (5-10 min), as proposed:
# Pseudo-code (proposed Ralph implementation; does not exist)
1. git pull origin main
2. Load all .yaml files in .squad/cross-machine/tasks/
3. Filter for status=pending AND target_machine=HOSTNAME
4. For each task:
a. Validate schema (must have: id, source_machine, target_machine, payload)
b. Validate command against whitelist
c. Execute task (with timeout)
d. Write result to .squad/cross-machine/results/{id}.yaml
e. Commit & push resultFor Urgent/Ad-Hoc Tasks
Use GitHub Issues with squad:machine-{name} label:
# Create issue
gh issue create \
--title "GPU: Clone voice profile from sample.wav" \
--body "Execute voice cloning on DevBox. Input: /path/to/voice-input.wav" \
--label "squad:machine-devbox" \
--label "urgent"In this proposal (not implemented), Ralph on DevBox would:
- Detect issue with
squad:machine-devboxlabel - Parse task from issue body
- Execute task
- Comment with result
- Close issue
File Formats
Task File (YAML)
Location: .squad/cross-machine/tasks/{timestamp}-{machine}-{task-id}.yaml
Required Fields:
id: {task-id} # Unique identifier (alphanumeric + dash)
source_machine: {hostname} # Where task was created
target_machine: {hostname} # Where task will execute
priority: high|normal|low # Execution priority
created_at: 2026-03-14T15:30:00Z # ISO 8601 timestamp
task_type: gpu_workload|script|... # Category
payload:
command: "..." # Shell command to execute
expected_duration_min: 15 # Timeout (minutes)
resources:
gpu: true|false
memory_gb: 8
cpu_cores: 4
status: pending|executing|completed|failedOptional Fields:
description: "Human-readable task description"
timeout_override_min: 120 # Override default timeout
retry_count: 3 # Retry failed tasksResult File (YAML)
Location: .squad/cross-machine/results/{task-id}.yaml
id: {task-id} # Links back to task
target_machine: devbox # Executed on
completed_at: 2026-03-14T15:45:00Z # When it finished
status: completed|failed|timeout # Outcome
exit_code: 0 # Shell exit code
stdout: "..." # Captured output
stderr: "..." # Captured errors
duration_seconds: 900 # How long it took
artifacts:
- path: "/path/to/artifacts/..." # Location of results
type: audio|text|model|...
size_mb: 2.5Security Model
Validation Pipeline
All tasks go through:
- Schema Validation
- YAML structure matches spec
- Required fields present
- No unexpected fields (reject)
- Command Whitelist
- Only approved commands allowed
- Path validation (no
../../escapes) - Environment variable sanitization
- No inline shell operators (
&&,|,>)
- Resource Limits
- Timeout enforced (default: 60 min)
- Memory cap: 16GB (adjustable)
- CPU threads: 4 (adjustable)
- Disk write: 100GB (adjustable)
- Execution Isolation
- Runs as unprivileged user
- Temp directory cleaned after execution
- Network access: read-only (no outbound writes)
- Audit Trail
- All executions logged to git
- Commit signed with Ralph's key
- Result stored immutably
Threat Mitigations
| Threat | Mitigation |
| Malicious task injection | Branch protection + PR review before merge |
| Credential leakage | Pre-commit secret scan + environment scrubbing |
| Resource exhaustion | Timeout + memory limits |
| Code injection | Command whitelist + no shell evaluation |
| Result tampering | Git commit history is immutable |
Configuration
Proposed .squad/config.json block. No Squad release reads it:
{
"cross_machine": {
"enabled": true,
"poll_interval_seconds": 300,
"this_machine": "devbox",
"max_concurrent_tasks": 2,
"task_timeout_minutes": 60,
"command_whitelist": [
"python scripts/voice-clone.py",
"python scripts/data-process.py",
"bash scripts/cleanup.sh"
],
"result_ttl_days": 30
}
}Examples
Example 1: GPU Voice Cloning (Laptop → DevBox)
1. Laptop creates task:
# .squad/cross-machine/tasks/2026-03-14T1530Z-laptop-gpu-001.yaml
id: gpu-voice-clone-001
source_machine: laptop-machine
target_machine: devbox
priority: high
created_at: 2026-03-14T15:30:00Z
task_type: gpu_workload
payload:
command: "python scripts/voice-clone.py --input voice.wav --output cloned.wav"
expected_duration_min: 15
resources:
gpu: true
memory_gb: 8
status: pending2. Laptop commits & pushes:
git add .squad/cross-machine/tasks/
git commit -m "Task: GPU voice cloning [squad:machine-devbox]"
git push origin main3. DevBox Ralph (5 min later):
[Ralph Watch Cycle]
- Pulled origin/main
- Detected: gpu-voice-clone-001 (status: pending, target: devbox)
- Validation: ✅ Schema OK, command whitelisted
- Executing: python scripts/voice-clone.py ...
- [15 minutes of processing]
- Completed: exit code 0
- Writing result...
- Committing & pushing...4. Laptop Ralph (next cycle) sees result:
# .squad/cross-machine/results/gpu-voice-clone-001.yaml
id: gpu-voice-clone-001
target_machine: devbox
completed_at: 2026-03-14T15:45:00Z
status: completed
exit_code: 0
stdout: "Voice cloning completed. Output written to /tmp/cloned.wav"
stderr: ""
duration_seconds: 900
artifacts:
- path: "/path/to/artifacts/voice-clone-001/output.wav"
type: audio
size_mb: 2.5Example 2: Urgent Debug Request (Human → DevBox via Issue)
Create issue:
gh issue create \
--title "DevBox: Debug voice model failure" \
--body "Error: Model failed to load on last run. Please check /tmp/model.log and report findings." \
--label "squad:machine-devbox" \
--label "urgent"DevBox Ralph detects → executes → comments:
✅ Executed on devbox at 2026-03-14 15:47:00
Command: python scripts/debug-model.py
Result:
------
Model file: /tmp/model-v2.bin (OK)
Checksum: a1b2c3d4e5f6 (matches expected)
Memory available: 12 GB (sufficient)
ERROR FOUND: Config file permission issue
- File: ~/.config/voice/model.yaml
- Permissions: -rw------- (owner-only)
- Expected: -rw-r--r-- (world-readable for service)
FIX: Run: chmod 644 ~/.config/voice/model.yamlError Handling
Task Execution Failures
If a task fails (exit code != 0):
- Result written with
status: failed+ exit code - stderr captured in result
- Committed to git for audit
- Source machine can retry by re-pushing task with
status: pending
Stalled Tasks
If a task doesn't complete within timeout:
- Process killed
- Result written with
status: timeout - stderr: "Execution exceeded X minutes"
- Source can investigate or retry
Network Failures
If git push/pull fails:
- Ralph retries on next cycle
- Tasks queue locally until connectivity restored
- No tasks lost (stored in local repo)
Monitoring & Debugging
Check Task Queue
ls -la .squad/cross-machine/tasks/
cat .squad/cross-machine/tasks/*.yaml | grep -E "^(id|status|target_machine):"Check Results
ls -la .squad/cross-machine/results/
cat .squad/cross-machine/results/{task-id}.yamlView Execution History
git log --oneline .squad/cross-machine/ | head -20Monitor Ralph Cycles
tail -f .squad/log/ralph-watch.log | grep "cross-machine"Integration with Ralph Watch
Not implemented: squad watch does not include this pattern. The proposed watch loop was:
Proposed Ralph Watch Cycle (every 5-10 min):
1. Fetch GitHub issues with squad:machine-* labels
2. Poll .squad/cross-machine/tasks/
3. For each matching task:
- Validate
- Execute
- Write result
- Commit & push
4. Update status in issue (if applicable)
5. Sleep until next cycleUntil this is built, task files and squad:machine-* labels do nothing. To stop several watchers from picking the same issue, use work claims (--claims git-ref, ADR-002).
Migration from Manual Handoff
Before (today):
- Laptop → user manually copies file to Teams chat
- user pastes into target terminal
- user copies output back
- user pastes result manually
After (if this proposal is built):
- Laptop Ralph writes task file → git push
- DevBox Ralph auto-executes → git push result
- Laptop Ralph auto-reads result
- 0 human intervention needed
Future Enhancements
Potential expansions (Phase 2+):
- Task Priorities: Execution order based on priority field
- Serial Pipelines: Machine A → B → C task chains
- GPU Availability Polling: Query DevBox before submitting work
- Cost Tracking: Log resource usage per task
- Notification Webhooks: Alert on task completion
- Web Dashboard: Real-time task status visualization
Questions?
Refer to research report: research/active/cross-machine-agents/README.md
Contact: the research and documentation owner or Ralph (Work Monitor)
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

