Skip to content

feat: add deterministic route resolver - #85

Closed
JTInventory wants to merge 7 commits into
kunchenguid:mainfrom
JTInventory:fm/firstmate-route-resolver-pr1-0625
Closed

JTInventory wants to merge 7 commits into
kunchenguid:mainfrom
JTInventory:fm/firstmate-route-resolver-pr1-0625

Conversation

@JTInventory

Copy link
Copy Markdown

Summary

Firstmate can now resolve a task route without changing spawn behavior. The new read-only command classifies task text into cheap, standard, deep, or critical, reports the selected harness/model/effort/reason/override/risk flags, and refuses risky downgrades unless --captain-downgrade-ok is explicit.

The resolver fails closed for production/runtime, money, credential/auth, security, external side-effect, Git danger, and Firstmate core safety signals. Read-only scout work can still take a cheaper route when no high-risk or deep-planning signals are present.

Validation

  • bash -n bin/fm-route.sh tests/fm-route.test.sh
  • bash tests/fm-route.test.sh
  • git diff --check
  • bash -n bin/*.sh tests/*.sh
  • bash tests/fm-bootstrap.test.sh

Compound Engineering
Codex

@JTInventory

Copy link
Copy Markdown
Author

Closing because this work is maintained in the JTInventory fork. We are not expecting upstream review or merge for this branch.

@JTInventory JTInventory closed this Jul 1, 2026
fritznoff pushed a commit to fritznoff/starship that referenced this pull request Nov 2, 2026
* feat: add one-tap photo drop to the phone bridge

Let the captain send photos from a phone on the existing glance page while keeping every other route read-only and quarantining files in data/bridge-inbox/.

Co-authored-by: Cursor <cursoragent@cursor.com>

* no-mistakes(review): Ensure atomic inbox pair publication, captain

* no-mistakes(document): Clarify photo upload rate limiting

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
fritznoff pushed a commit to fritznoff/starship that referenced this pull request Nov 18, 2026
…akes (kunchenguid#85)

* fix(bin): name the queued event in a watcher recovery wake instead of a bare rearm-resurface

A recovery that finds a queued row now closes as 'check: queued wake: <row reason>',
so a row another producer appended, or one a handling successor queued while no
arm was attached to deliver its close, reaches the supervisor as that event. The
close stays check-kind, so it still routes to main. Only a recovery with nothing
usable queued (a genuine outage with work in flight) keeps 'check: rearm-resurface'.
fm_wake_queue_newest_reason in bin/fm-wake-lib.sh owns how a row is named.

* fix(bin): name the queued event in a watcher recovery wake instead of a bare rearm-resurface

A recovery that finds a queued row now closes as 'check: queued wake: <row reason>',
so a row another producer appended, or one a handling successor queued while no
arm was attached to deliver its close, reaches the supervisor as that event. The
close stays check-kind, so it still routes to main. Only a recovery with nothing
usable queued (a genuine outage with work in flight) keeps 'check: rearm-resurface'.
fm_wake_queue_newest_reason in bin/fm-wake-lib.sh owns how a row is named.

* fix(bin): do not wake main for a recovery when nothing queued is main's to see

A downtime recovery no longer wakes main when every queued row is held by a
live supervision-branch grant (the branch presents and acknowledges those), and
a fresh watcher no longer reopens an announced episode for rows main's drain
already presented to the turn handling it. A recovery wake names the newest row
main would be shown, preferring a real event over a bare heartbeat. Interrupted
handling republished as downtime, and a genuine outage, still resurface.
Tests assert the reasons literally instead of through the code under test.

* no-mistakes(review): skip presented rows on re-arm while same session holds

* no-mistakes(review): pair presented stamp with recorded session id

* no-mistakes(review): share one recovery-row filter for count and label

* no-mistakes(review): count an unreadable queue as one recovery row
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant