-
Notifications
You must be signed in to change notification settings - Fork 56
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: cmuhao <[email protected]>
- Loading branch information
Showing
10 changed files
with
3,785 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,4 +11,5 @@ terraform.tfstate.backup | |
.vscode/* | ||
**/derby.log | ||
**/metastore_db/* | ||
.env | ||
.env | ||
.idea |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
data/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
3.9 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
from feast import Entity | ||
|
||
item = Entity(name="item_id") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
project: feast_demo_local | ||
provider: local | ||
registry: | ||
registry_type: sql | ||
path: postgresql://@localhost:5432/feast | ||
online_store: | ||
type: postgres | ||
pgvector_enabled: true | ||
vector_len: 384 | ||
host: 127.0.0.1 | ||
port: 5432 | ||
database: feast | ||
user: "" | ||
password: "" | ||
|
||
|
||
offline_store: | ||
type: file | ||
entity_key_serialization_version: 2 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
from datetime import timedelta | ||
|
||
from feast import ( | ||
FeatureView, | ||
Field, FileSource, | ||
) | ||
from feast.data_format import ParquetFormat | ||
from feast.types import Float32, Array | ||
from entities import item | ||
|
||
|
||
parquet_file_path = "../data/city_wikipedia_summaries_with_embeddings.parquet" | ||
|
||
source = FileSource( | ||
file_format=ParquetFormat(), | ||
path=parquet_file_path, | ||
timestamp_field="event_timestamp", | ||
) | ||
|
||
city_embeddings_feature_view = FeatureView( | ||
name="city_embeddings", | ||
entities=[item], | ||
schema=[ | ||
Field(name="Embeddings", dtype=Array(Float32)), | ||
], | ||
source=source, | ||
ttl=timedelta(hours=2), | ||
) |
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters