Skip to content

feat: implement per-scope Markov chain preflight prediction#3

Merged
aayank13 merged 5 commits into
enginefrom
engine-preflight
Jul 7, 2026
Merged

feat: implement per-scope Markov chain preflight prediction#3
aayank13 merged 5 commits into
enginefrom
engine-preflight

Conversation

@aayank13

Copy link
Copy Markdown
Collaborator
  • Refactor PreflightPredictor to track transitions between capabilities per application/session scope.
  • Introduce global fallback for scopes with insufficient data.
  • Add metrics for preflight effectiveness and expose them via API.
  • Implement SubscriptionRegistry for managing capability subscriptions with TTL.
  • Enhance Router to support memory and lifecycle reporting, and subscription management.
  • Add new EngineEvent variants for model eviction and preflight warming events.

- Refactor PreflightPredictor to track transitions between capabilities per application/session scope.
- Introduce global fallback for scopes with insufficient data.
- Add metrics for preflight effectiveness and expose them via API.
- Implement SubscriptionRegistry for managing capability subscriptions with TTL.
- Enhance Router to support memory and lifecycle reporting, and subscription management.
- Add new EngineEvent variants for model eviction and preflight warming events.
@aayank13
aayank13 requested review from BH3GEI and Copilot June 28, 2026 13:10

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@aayank13 aayank13 self-assigned this Jun 28, 2026
aayank13 added 2 commits July 7, 2026 02:04
- Introduced a new `stream` method in the `Provider` trait to allow providers to emit incremental text deltas during inference.
- Added `StreamChunk` enum to represent different types of events in a streaming inference response, including `Started`, `Text`, `Completed`, and `Error`.
- Implemented `invoke_stream` in the `DaemonClient` to handle streaming responses over SSE.
- Updated the HTTP server to include a new `/v1/invoke/stream` endpoint for streaming inference output.
- Enhanced the `Router` to support bearer token authentication for API routes.
- Added metrics endpoint for Prometheus scraping.
- Improved error handling and request correlation with `x-request-id` headers.
- Updated dependencies in `Cargo.toml` for `reqwest` and `tokio`.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 26 out of 28 changed files in this pull request and generated 6 comments.

Comment thread mofa-engine-sdk/src/server.rs
Comment thread mofa-engine-core/src/engine.rs Outdated
Comment thread mofa-engine-core/src/preflight.rs
Comment thread mofa-kernel/src/types.rs
Comment thread mofa-kernel/src/types.rs
Comment thread mofa-kernel/src/types.rs

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 26 out of 28 changed files in this pull request and generated 9 comments.

Comment thread mofa-kernel/src/types.rs
Comment thread mofa-kernel/src/types.rs
Comment thread mofa-kernel/src/types.rs
Comment thread mofa-kernel/src/types.rs
Comment thread mofa-engine-core/src/preflight.rs Outdated
Comment thread mofa-engine-core/src/router.rs
Comment thread mofa-engine-sdk/src/server.rs
Comment thread mofa-engine-core/src/backends/openai_compat.rs Outdated
Comment thread mofa-engine-core/src/backends/ollama.rs Outdated
@aayank13
aayank13 merged commit 308842b into engine Jul 7, 2026
1 check passed
@aayank13
aayank13 deleted the engine-preflight branch July 12, 2026 15:08
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.

2 participants