Skip to content

Conversation

@ntkathole
Copy link
Member

What this PR does / why we need it:

Add example template for Ray.

# feast init -t ray
Ray template initialized with sample data:
  - Driver stats: /feast-projects/sacred_rodent/feature_repo/data/driver_stats.parquet
  - Customer profiles: /feast-projects/sacred_rodent/feature_repo/data/customer_daily_profile.parquet
  - Ray storage will be created at: /feast-projects/sacred_rodent/feature_repo/data/ray_storage

To get started:
  1. cd sacred_rodent/feature_repo
  2. feast apply
  3. python test_workflow.py

Creating a new Feast repository in /feast-projects/sacred_rodent.
# python test_workflow.py
============================================================
🚀 Ray Offline Store & Compute Engine Demo
============================================================

1. Initializing Feast with Ray configuration...
   ✓ Offline store: ray
   ✓ Compute engine: ray.engine

2. Creating entity DataFrame for historical feature retrieval...
   ✓ Created entity DataFrame with 3 rows
   ✓ Time range: 2025-08-15 12:00:00 to 2025-08-17 12:00:00

3. Retrieving historical features with Ray compute engine...
   (This demonstrates distributed point-in-time joins)
   ✓ Retrieved 3 historical feature rows
   ✓ Features: ['driver_id', 'customer_id', 'event_timestamp', 'conv_rate', 'acc_rate', 'avg_daily_trips', 'current_balance', 'avg_passenger_count', 'lifetime_trip_count']

   Sample historical features:
 driver_id  customer_id           event_timestamp  conv_rate  acc_rate  avg_daily_trips  current_balance  avg_passenger_count  lifetime_trip_count
      1001         2001 2025-08-16 12:00:00+00:00   0.253998  0.016639               76       738.030300             1.841441                  387
      1002         2002 2025-08-17 00:00:00+00:00   0.734615  0.839181               79        83.531244             2.651579                  342
      1003         2003 2025-08-17 06:00:00+00:00   0.768238  0.294502              968        39.029157             3.438895                  215

4. Testing on-demand feature transformations...
   ✓ Retrieved 1 rows with on-demand transformations

   Sample with on-demand features:
 driver_id  conv_rate  acc_rate  conv_rate_plus_acc_rate
      1001   0.253998  0.016639                 0.270637

5. Materializing features to online store...
   Attempting materialization up to 2025-08-17 12:00:00
Materializing 2 feature views to 2025-08-17 12:00:00+00:00 into the sqlite online store.

driver_hourly_stats from 2025-08-10 06:31:21+00:00 to 2025-08-17 12:00:00+00:00:
customer_daily_profile from 2025-08-10 06:31:26+00:00 to 2025-08-17 12:00:00+00:00:
   ✓ Ray compute engine materialization successful!

6. Testing online feature serving...
   ✓ Retrieved 2 online feature rows

   Sample online features:
 driver_id  customer_id  conv_rate  acc_rate  current_balance
      1001         2001   0.542408  0.615162        55.650719
      1002         2002   0.326722  0.137612       440.106567

============================================================
🎉 Ray Demo Complete!
============================================================
If you want to explore Feast with your existing ray cluster, you can configure ray_address to feature_store.yaml:
    offline_store:
      ray_address: "127.0.0.1:10001"
    batch_engine:
      ray_address: "127.0.0.1:10001"

Signed-off-by: ntkathole <nikhilkathole2683@gmail.com>
@ntkathole ntkathole self-assigned this Aug 17, 2025
@ntkathole ntkathole requested a review from a team as a code owner August 17, 2025 06:35
Copy link
Collaborator

@shuchu shuchu left a comment

Choose a reason for hiding this comment

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

lgtm

Copy link
Member

@franciscojavierarceo franciscojavierarceo left a comment

Choose a reason for hiding this comment

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

This is fine but it doesn't really do a good job of highlighting the usefulness of Ray.

@ntkathole
Copy link
Member Author

This is fine but it doesn't really do a good job of highlighting the usefulness of Ray.

yeah, I plan to extend this later

@franciscojavierarceo franciscojavierarceo merged commit a66d890 into feast-dev:master Aug 19, 2025
21 checks passed
franciscojavierarceo pushed a commit that referenced this pull request Aug 30, 2025
# [0.53.0](v0.52.0...v0.53.0) (2025-08-30)

### Bug Fixes

* Consistency in allow_cache and savedDatasets api ([#5572](#5572)) ([7e8b914](7e8b914))
* **docs:** Use absolute image URLs in README ([7188fc9](7188fc9))

### Features

* Added ray example template ([#5570](#5570)) ([a66d890](a66d890))
* Allow hyphen in repo name ([#5562](#5562)) ([4436673](4436673))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants