Files
rune/docs/resource-authority.md

1.1 KiB

Resource Authority

Third orchestration plan (after foundation + cognitive strata): the resource authority layer, per design section S8.

Components (src/rune/orchestration/)

  • resources.py — ResourceState + Registry (unknown != zero)
  • eligibility.py — deterministic EligibilityFilter (removes, never ranks)
  • router.py — advisory router (FixedRouter, CostBiasRouter)
  • scheduler.py — ResourceScheduler (single authority: lease + bounded fallback)
  • broker.py — ResourceBroker + ElasticBudget (subagent inheritance)
  • authority.py — build_resources() composition

Contracts

  • Unknown health is NEVER usable; a request with no eligible candidate is structured unavailability (None), never a silent wrong pick.
  • Eligibility is deterministic; routing is advisory; the scheduler owns the final lease and records a bounded fallback chain.
  • Subagents inherit an ElasticBudget from the parent assignment and cannot bypass locality/provider/depth/concurrency/cost.

Run

PYTHONPATH=src:. python3 -m pytest tests/ -k orchestration --ignore=tests/test_message_widgets.py -q
PYTHONPATH=src:. python3 src/rune/canary_resource_authority.py