Skip to content

refactor(agent-runtime): own event facts#1033

Merged
limityan merged 1 commit into
GCWing:mainfrom
limityan:yanzhn/agent-runtime-event-facts-owner
Jun 2, 2026
Merged

refactor(agent-runtime): own event facts#1033
limityan merged 1 commit into
GCWing:mainfrom
limityan:yanzhn/agent-runtime-event-facts-owner

Conversation

@limityan
Copy link
Copy Markdown
Collaborator

@limityan limityan commented Jun 2, 2026

Scope

  • Move portable runtime event facts into bitfun-agent-runtime:
    • FinishReason wire labels
    • session-state event labels
    • turn-outcome event fact mapping used by agent-session reply policy
  • Keep bitfun-core as compatibility facade / concrete adapter only:
    • execution types re-export FinishReason
    • event types map concrete SessionState to portable facts before formatting
    • scheduler delegates turn-outcome fact mapping to bitfun-agent-runtime
  • Extend core boundary checks so these facts cannot drift back into core.
  • Update plan/completed docs and module AGENTS only; stable architecture/design docs are unchanged because the target design did not change.

Boundary / Behavior

  • No product command, UI, default feature, release/fast-build script, or product capability changes.
  • No scheduler lifecycle, event delivery, post-turn hook, session manager, or concrete prompt assembly migration in this PR.
  • No new dependency from bitfun-agent-runtime back to bitfun-core or concrete service crates.

Refs #970

Verification

  • pnpm run fmt:rs
  • cargo test -p bitfun-agent-runtime --test events_contracts -- --nocapture
  • cargo test -p bitfun-core cancelled_reply_is_skipped_only_when_suppressed -- --nocapture
  • node scripts/check-core-boundaries.mjs
  • pnpm run check:repo-hygiene

@limityan limityan merged commit 09bf6d1 into GCWing:main Jun 2, 2026
4 checks passed
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