0Pricing
MLOps Academy · Lekcja

Definiowanie widoków cech za pomocą Feast

Deklaruj encje i cechy w rejestrze

Definiowanie widoków cech za pomocą Feast to bezpłatna lekcja MLOps Academy na CoddyKit. To lekcja 2 z 4. Możesz przeczytać całą lekcję poniżej za darmo — a potem ćwiczyć ją interaktywnie w przeglądarce z wbudowanym edytorem kodu i tutorem AI dostępnym 24/7. To część ścieżki edukacyjnej MLOps Academy, a Twój postęp synchronizuje się między webem a aplikacją CoddyKit. Kurs MLOps Academy zawiera 4 lekcji w sumie.

Części tej lekcji nie zostały jeszcze przetłumaczone i są wyświetlane po angielsku.

The Building Blocks

In Feast you describe features with code: an Entity, a data source, and a Feature View. Get these three right and the rest follows. 🏗️

What an Entity Is

An Entity is the thing your features describe, like a driver or a customer. It is the key you will look features up by later.

driver = Entity(name="driver", join_keys=["driver_id"])

Point at Your Data

A data source tells Feast where the raw feature values live, such as a Parquet file or a warehouse table.

src = FileSource(path="driver_stats.parquet", timestamp_field="event_timestamp")

The Feature View

A FeatureView groups related features for one entity and links them to a source. It is the heart of a Feast definition.

Declaring Fields

Inside a Feature View, each Field names a feature and its data type, so Feast knows the schema it will serve.

Field(name="conv_rate", dtype=Float32)

Putting It Together

One Feature View ties the entity, schema, and source into a single object Feast can manage. 🔗

fv = FeatureView(name="driver_stats", entities=[driver], schema=[Field(name="conv_rate", dtype=Float32)], source=src)

The TTL Window

A Feature View's ttl sets how long a value stays valid. Past that window, Feast treats the feature as missing rather than stale.

ttl=timedelta(days=1)

The Timestamp Column

Every source needs an event timestamp column. It records when each value was true, which makes time-correct lookups possible.

The Feature Repo

Your definitions live in a feature repo folder with a feature_store.yaml config. Feast scans Python files there to find your objects.

Apply the Definitions

Running feast apply registers your entities and feature views into the registry. Nothing is live until you apply.

feast apply

The Registry

The registry is Feast's catalog of every entity and feature view. Teammates query it to discover what features already exist. 📒

Quick Check

Which object does a Feature View group features around?

Recap

You defined Feast objects: an Entity, a source, and a Feature View with fields and a ttl, then ran feast apply to register them. Next, you'll serve them online.

Często zadawane pytania

Czy lekcja „Definiowanie widoków cech za pomocą Feast” jest bezpłatna?

Tak — pełny tekst „Definiowanie widoków cech za pomocą Feast” jest dostępny za darmo tutaj w sieci. Aby ćwiczyć ją interaktywnie (wbudowany edytor kodu i tutor AI dostępny 24/7) i odblokować resztę kursu MLOps Academy, przejdź na CoddyKit PRO. Kurs MLOps Academy zawiera 4 lekcji w sumie.

Co nauczysz się w „Definiowanie widoków cech za pomocą Feast”?

Deklaruj encje i cechy w rejestrze Ćwiczysz MLOps Academy z praktycznym kodem, który uruchamiasz bezpośrednio w przeglądarce, a tutor AI dostępny 24/7 odpowiada na Twoje pytania podczas pracy nad lekcją.

Czy potrzebuję doświadczenia, aby zacząć MLOps Academy?

Nie wymagamy żadnego doświadczenia. MLOps Academy w CoddyKit jest strukturyzowany dla początkujących i zaawansowanych użytkowników, więc możesz zacząć tutaj lub od początku i uczyć się w swoim tempie. To lekcja 2 z 4.

Ile czasu zajmuje lekcja „Definiowanie widoków cech za pomocą Feast”?

Większość lekcji CoddyKit trwa około 5–10 minut. Każda lekcja to mały, interaktywny krok, dzięki czemu robisz systematyczne postępy i zawsze wracasz dokładnie do tego samego miejsca — na webie i w aplikacji.

Czy mogę pisać i uruchamiać kod w tej lekcji MLOps Academy?

Tak. Każda lekcja MLOps Academy zawiera wbudowany edytor kodu, więc piszesz i uruchamiasz prawdziwy kod bezpośrednio w przeglądarce i od razu otrzymujesz sprzężenie zwrotne od AI — bez konfiguracji na komputerze.

Wszystkie lekcje w tym kursie

  1. Dlaczego istnieją magazyny cech
  2. Definiowanie widoków cech za pomocą Feast
  3. Materializacja cech w magazynie online
  4. Pobieranie cech poprawnych w danym momencie
← Powrót do MLOps Academy