Title: feat: Implemented Tiling Support for Time-Windowed Aggregations by ntkathole · Pull Request #5724 · feast-dev/feast · GitHub
Open Graph Title: feat: Implemented Tiling Support for Time-Windowed Aggregations by ntkathole · Pull Request #5724 · feast-dev/feast
X Title: feat: Implemented Tiling Support for Time-Windowed Aggregations by ntkathole · Pull Request #5724 · feast-dev/feast
Description: What this PR does / why we need it: This PR implements tiling for computing time-windowed aggregations efficiently by pre-aggregating data into small, time-bucketed units (tiles) that can be reused across multiple queries. Instead of scanning all raw events for each window, it: Pre-aggregates data into small time buckets (tiles) Computes windowed aggregations by subtracting tiles: window_at_T = tile_at_T - tile_at_(T-window_size) Stores intermediate representations (IRs) for holistic aggregations (avg, std, var) to enable correct merging Integrates tiling into Spark and Ray compute engines for StreamFeatureView Sawtooth Window Tiling Tile Generation: Events bucketed into hop-sized intervals (e.g., 1-minute tiles) Cumulative Aggregation: Each tile contains cumulative sum/count from start Window Computation: Windowed aggregation = tile_at_T - tile_at_(T-window_size) IR Handling: For holistic aggs, IRs subtracted separately, then final value recomputed Enable Tiling in StreamFeatureView sales_features = StreamFeatureView( name="sales_features", entities=[customer], source=kafka_source, aggregations=[ Aggregation( column="amount", function="avg", time_window=timedelta(minutes=5), ), Aggregation( column="amount", function="sum", time_window=timedelta(minutes=5), ), ], timestamp_field="event_timestamp", enable_tiling=True, # Enable tiling optimization tiling_hop_size=timedelta(minutes=1), # Generate tiles every 1 minute ) Architecture ┌─────────────────────────────────────────────────────────────┐ │ StreamFeatureView (enable_tiling=True) │ └────────────────────────┬────────────────────────────────────┘ │ ┌───────────────┴───────────────┐ │ │ ┌────▼────┐ ┌────▼────┐ │ Spark │ │ Ray │ │ Node │ │ Node │ └────┬────┘ └────┬────┘ │ │ │ Convert to pandas │ ▼ ▼ ┌─────────────────────────────────────────────────────────────┐ │ Tiling Logic. │ │ ┌──────────────────────────────────────────────────────┐ │ │ │ orchestrator.apply_sawtooth_window_tiling() │ │ │ │ - Group by entity + hop interval │ │ │ │ - Compute cumulative aggregations (tiles) │ │ │ │ - Output: Cumulative tiles at each hop │ │ │ └──────────────────────┬───────────────────────────────┘ │ │ │ │ │ ┌──────────────────────▼───────────────────────────────┐ │ │ │ tile_subtraction.convert_cumulative_to_windowed() │ │ │ │ - Subtract tiles: window = tile_T - tile_(T-W) │ │ │ │ - Recompute holistic aggs from IRs │ │ │ │ - Output: Windowed aggregations │ │ │ └──────────────────────┬───────────────────────────────┘ │ │ │ │ │ ┌──────────────────────▼───────────────────────────────┐ │ │ │ tile_subtraction.deduplicate_keep_latest() │ │ │ │ - Keep latest window per entity │ │ │ └──────────────────────────────────────────────────────┘ │ └─────────────────────────┬───────────────────────────────────┘ │ Convert back to engine format ▼ ┌───────────────┐ │ Online Store │ │ │ └───────────────┘
Open Graph Description: What this PR does / why we need it: This PR implements tiling for computing time-windowed aggregations efficiently by pre-aggregating data into small, time-bucketed units (tiles) that can be reused...
X Description: What this PR does / why we need it: This PR implements tiling for computing time-windowed aggregations efficiently by pre-aggregating data into small, time-bucketed units (tiles) that can be reused...
Opengraph URL: https://github.com/feast-dev/feast/pull/5724
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:049ecfe5-2783-dc7a-ef3b-bb2292bef832 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | C2D2:19A1E9:8E3121C:BDAC0DC:696E2123 |
| html-safe-nonce | e04aecaf2e20bd2b36dbbdc0857965a9bd845c8831b632a61e25094c9b4f78c4 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDMkQyOjE5QTFFOTo4RTMxMjFDOkJEQUMwREM6Njk2RTIxMjMiLCJ2aXNpdG9yX2lkIjoiNDI0NTk1MTQ0NzM1OTY5MzA5MSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | d2c56e2e2ad4066f75b82cba0b341e4b701234625ee8f85ff8b548501e16e807 |
| hovercard-subject-tag | pull_request:3014978473 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/feast-dev/feast/pull/5724/files |
| twitter:image | https://avatars.githubusercontent.com/u/16951913?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/16951913?s=400&v=4 |
| og:image:alt | What this PR does / why we need it: This PR implements tiling for computing time-windowed aggregations efficiently by pre-aggregating data into small, time-bucketed units (tiles) that can be reused... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 2fbe8cba5e260284c10af515699ff9bb2d6ace05ab6c2e2e585b71d93b2812c3 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/feast-dev/feast git https://github.com/feast-dev/feast.git |
| octolytics-dimension-user_id | 57027613 |
| octolytics-dimension-user_login | feast-dev |
| octolytics-dimension-repository_id | 161133770 |
| octolytics-dimension-repository_nwo | feast-dev/feast |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 161133770 |
| octolytics-dimension-repository_network_root_nwo | feast-dev/feast |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 7fb3bc5c995a876085291706b75cf9b08900c338 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width