GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — feat: Making feast vector store with open ai search api compatible by patelchaitany · Pull Request #6121 · feast-dev/feast

Conversation

@patelchaitany

@patelchaitany patelchaitany commented Mar 17, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

What this PR does / why we need it:

This PR making the feast vector store api with open ai search api compatible so.

This are the changes are made.

  1. New OpenAI-compatible endpoint
  • Added POST /v1/vector_stores/{vector_store_id}/search that matches the OpenAI vector store search API
  • vector_store_id just maps to a feature view name
  • Takes a query string, embeds it via LiteLLM, calls retrieve_online_documents_v2, and returns results in OpenAI's vector_store.search_results.page format
  • LiteLLM embedding config goes in feature_store.yaml under a new embedding_model section (model, api_key, api_base, api_version, dimensions
  1. Metadata filtering
  • New filter_models.py with two Pydantic models: ComparisonFilter (eq, ne, gt, gte, lt, lte, in, nin) and CompoundFilter (and/or, nestable)
  • Threaded filters through the entire retrieval stack down to each online store
  • Each store translates filters into its native query language:
    • Elasticsearch: Query DSL clauses (term, range, terms, bool)
    • Milvus: boolean expressions like field == 'value'
    • Postgres: parameterized SQL subqueries with entity_key IN (SELECT ...)
    • SQLite: same approach as Postgres, SQLite syntax
  1. Numeric storage fix
  • Without this change, all values are stored as text, so '9' > '100' is true in filters
  • New enable_openai_compatible_store config flag on every store backend
  • When enabled, adds a value_num column that stores int, float, double, and bool values natively alongside the existing `value_text
  1. Bug fixes picked up along the way
  • SQLite BM25 search was reading raw value instead of value_text
  • SQLite's query param renamed to embedding since that's what it actually is
  • Added input escaping for Milvus query strings
  1. Tests
  • 160 lines of unit tests for filter models (valid/invalid operators, value types, nested compounds)
  • ~320 lines of integration tests covering filtered vector search, filtered text search, OpenAI response shape, and error cases (no embedding config, nonexistent feature view, empty results)

Which issue(s) this PR fixes:

#5615

Misc


Open with Devin

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@ntkathole ntkathole changed the title feat: making feast vector store with open ai search api compatible feat: Making feast vector store with open ai search api compatible Mar 17, 2026
@patelchaitany
patelchaitany force-pushed the enh/openai-compatibel-store-api branch 4 times, most recently from e45f167 to c8392a9 Compare March 23, 2026 11:17
@patelchaitany patelchaitany changed the title feat: Making feast vector store with open ai search api compatible feat: Making feast vector store with open ai search api compatible Mar 23, 2026
@patelchaitany
patelchaitany force-pushed the enh/openai-compatibel-store-api branch 5 times, most recently from 7e8adfb to 3f541ad Compare March 24, 2026 11:29
@patelchaitany
patelchaitany marked this pull request as ready for review March 24, 2026 11:29
@patelchaitany
patelchaitany requested review from a team as code owners March 24, 2026 11:29
@patelchaitany
patelchaitany requested review from haoxu0, nquinn408 and redhatHameed and removed request for a team March 24, 2026 11:29
devin-ai-integration[bot]

This comment was marked as resolved.

Sign in to view

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

devin-ai-integration[bot]

This comment was marked as resolved.

Sign in to view

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@patelchaitany
patelchaitany force-pushed the enh/openai-compatibel-store-api branch from cd692b9 to 086bed5 Compare March 30, 2026 12:05
devin-ai-integration[bot]

This comment was marked as resolved.

Sign in to view

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@patelchaitany
patelchaitany force-pushed the enh/openai-compatibel-store-api branch from 086bed5 to 9778002 Compare March 30, 2026 12:51
devin-ai-integration[bot]

This comment was marked as resolved.

Sign in to view

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@patelchaitany
patelchaitany force-pushed the enh/openai-compatibel-store-api branch 2 times, most recently from 68c843c to e29e557 Compare March 31, 2026 07:05
devin-ai-integration[bot]

This comment was marked as resolved.

Sign in to view

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@patelchaitany
patelchaitany force-pushed the enh/openai-compatibel-store-api branch 2 times, most recently from f0552c7 to dafe9fd Compare March 31, 2026 09:26
devin-ai-integration[bot]

This comment was marked as resolved.

Sign in to view

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

franciscojavierarceo
franciscojavierarceo reviewed Jun 1, 2026
View reviewed changes
Comment thread infra/website/docs/blog/feast-openai-compatible-api.md Outdated

If you've tried to connect an AI agent to Feast's vector search, you've probably hit this wall: the agent needs to search your feature store, but Feast expects a raw embedding vector. The agent doesn't have one. It has a question in English.

Until now, the workaround was ugly. You'd call an embedding provider (OpenAI, Ollama, whatever) to turn the text into a float array, then pass that array to Feast's `retrieve-online-documents` endpoint. Every client had to know both APIs, carry both sets of credentials, and run glue code whose only job was bridging the gap.

@franciscojavierarceo franciscojavierarceo Jun 1, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

we should deprecate the retrieve-online-documents API and rename it as search API to highlight the more generic primitive we want to support, which will offer a lot more long term flexibility.

CC @ntkathole

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

@patelchaitany patelchaitany Jun 2, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Okay I have added the new endpoint /search and deprecated the retrieve-online-documents as it is still available for the backward compatibility.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
franciscojavierarceo
franciscojavierarceo reviewed Jun 1, 2026
View reviewed changes
Comment thread infra/website/docs/blog/feast-openai-compatible-api.md Outdated

When Feast receives this request, it:

1. Embeds the query server-side using the model configured in `feature_store.yaml` (via [LiteLLM](https://docs.litellm.ai/), which supports OpenAI, Ollama, Azure, Cohere, HuggingFace, and 100+ other providers).

@franciscojavierarceo franciscojavierarceo Jun 1, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

yeah this seems acceptable if it's opt-in but we should also support sentence transformers.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@patelchaitany

patelchaitany commented Jun 3, 2026

Copy link
Copy Markdown
Contributor Author

@franciscojavierarceo, I have created an RFC as you requested Docs

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@patelchaitany

patelchaitany commented Jun 16, 2026

Copy link
Copy Markdown
Contributor Author

@franciscojavierarceo, let me know if you need any more changes, or if this is good to go.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@patelchaitany patelchaitany mentioned this pull request Jun 19, 2026
feat: Add ScyllaDB online store with vector search #6508
Merged
franciscojavierarceo
franciscojavierarceo requested changes Jun 22, 2026
View reviewed changes

@franciscojavierarceo franciscojavierarceo left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Thanks for pushing this through. I think we need another pass before merge. The main blockers are that the new OpenAI-compatible endpoint bypasses the existing online-read permission path, exposes Feast distances as OpenAI scores, and accepts OpenAI-shaped request fields that are not actually applied. I also left one existing remote-store mutation issue because it still reproduces on this head.

CI note: the latest unit-test-python (3.12, macos-14) check is still failing with two 120s CLI/apply timeouts, so this is not green yet.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread sdk/python/feast/feature_server.py Outdated
"/v1/vector_stores/{vector_store_id}/search"
):
try:
result = await store.retrieve_online_documents_openai(

@franciscojavierarceo franciscojavierarceo Jun 22, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

i think there's a bug here: this new endpoint bypasses _get_features, so auth-enabled servers never run the existing READ_ONLINE check for the target feature view. /search goes through _get_features() before retrieval, but this path calls store.retrieve_online_documents_openai(...) directly. Can we resolve the feature view, assert AuthzedAction.READ_ONLINE, and add an auth regression test for this endpoint?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@patelchaitany patelchaitany Jun 22, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Okay I will add those test as well as the authentication checks for this newly added api endpoints

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@patelchaitany patelchaitany Jun 22, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Auth regression test is out of scope for this PR, will address in a follow-up

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread sdk/python/feast/feature_store.py Outdated
for key, values in response_dict.items():
val = values[i] if i < len(values) else None
if key == "distance":
score = float(val) if val is not None else 0.0

@franciscojavierarceo franciscojavierarceo Jun 22, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

i think this is returning the wrong OpenAI semantics. distance is lower-is-better for the default pgvector L2 path, but the OpenAI response field is score, which clients treat as higher-is-better relevance and use with score_threshold. We should either normalize per metric before putting it in score, or avoid claiming OpenAI score semantics here.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@patelchaitany patelchaitany Jun 23, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Added _distance_to_score(distance, metric) in utils.py and applied it at the store level in Postgres, SQLite, and Milvus. Elasticsearch and Qdrant already return higher-is-better scores, so no changes needed there

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread sdk/python/feast/feature_server.py
query=request.query,
max_num_results=request.max_num_results or 10,
filters=request.filters,
ranking_options=(

@franciscojavierarceo franciscojavierarceo Jun 22, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

This accepts and forwards ranking_options, including score_threshold, but retrieve_online_documents_openai() never applies it. That makes clients think thresholding is enforced when it is silently ignored. Can we either implement score_threshold now or reject unsupported ranking_options/rewrite_query with a 4xx until they are wired?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
Comment thread sdk/python/feast/infra/online_stores/remote.py
if requested_features is None:
requested_features = []
if "distance" not in requested_features:
requested_features.append("distance")

@franciscojavierarceo franciscojavierarceo Jun 22, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

This still mutates the caller-owned requested_features list. When this is called through FeatureStore._retrieve_from_online_store_v2, Feast later builds features_to_request = requested_features + ["distance"], so distance can appear twice in the response metadata. Please copy before appending, or keep synthetic fields owned by one layer only.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
Comment thread sdk/python/feast/feature_store.py Outdated
if features_to_retrieve:
feature_names = features_to_retrieve
else:
feature_names = [f.name for f in feature_view.features]

@franciscojavierarceo franciscojavierarceo Jun 22, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

By default this requests every feature from the feature view, which includes the embedding/vector field itself. The response conversion below then copies every non-entity, non-distance field into attributes, so OpenAI-compatible search responses can include the raw embedding vector as metadata. Can we exclude vector fields by default and only return scalar metadata/content fields unless explicitly requested?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@patelchaitany patelchaitany Jun 22, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Sure, I remove the vector field from the feature_names

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread docs/reference/alpha-vector-database.md Outdated
}
```

String equality filters work on all backends. Numeric and boolean filters require `enable_openai_compatible_store: true` in the online store config.

@franciscojavierarceo franciscojavierarceo Jun 22, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

This doc says string equality filters work on all backends without the new store flag, but the Postgres and SQLite implementations reject any filter when enable_openai_compatible_store is false. Either the runtime should allow text-only filters on existing schemas, or the docs should say all filtering requires the flag for those backends.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
github-advanced-security[bot]
github-advanced-security Bot found potential problems Jun 23, 2026
View reviewed changes
Comment thread sdk/python/feast/feature_server.py
Comment on lines +596 to +601
content={
"error": {
"message": str(e),
"type": "invalid_request_error",
}
},
franciscojavierarceo
franciscojavierarceo reviewed Jul 3, 2026
View reviewed changes
Comment thread infra/website/docs/blog/feast-openai-compatible-api.md Outdated

Until now, the workaround was ugly. You'd call an embedding provider (OpenAI, Ollama, whatever) to turn the text into a float array, then pass that array to Feast's vector search endpoint (`POST /search`, formerly `retrieve-online-documents`). Every client had to know both APIs, carry both sets of credentials, and run glue code whose only job was bridging the gap.

Feast now has a new endpoint: `POST /v1/vector_stores/{feature_view}/search`. It follows the [OpenAI Vector Store Search API](https://platform.openai.com/docs/api-reference/vector-stores-search) format. You send text, Feast handles the embedding internally, and you get results back in the same JSON shape that OpenAI returns. No float arrays, no extra SDK.

@franciscojavierarceo franciscojavierarceo Jul 3, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

but this isn't openai compatible.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@patelchaitany patelchaitany Jul 3, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

I initially went with feature view names for simplicity from implementation and user perspective but you're right it should follow the OpenAI vs_{hash} format for proper compatibility.

it is an easy addition, plan is to hash the project:feature_view_name and cache it at server startup time and it refresh at every registry TTL, Will also add GET /v1/vector_stores so user can discover the vs_ IDs for their feature views

working on it

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@patelchaitany patelchaitany Jul 6, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Now added this endpoint Give it another look when you get time

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
franciscojavierarceo
franciscojavierarceo reviewed Jul 3, 2026
View reviewed changes
Comment thread infra/website/docs/blog/feast-openai-compatible-api.md Outdated
import requests

result = requests.post(
"http://feast-server:6566/v1/vector_stores/product_catalog/search",

@franciscojavierarceo franciscojavierarceo Jul 3, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

the product_catalog is not vector store compatible. it should be some vs_{hash} identifier.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
franciscojavierarceo
franciscojavierarceo requested changes Jul 3, 2026
View reviewed changes

@franciscojavierarceo franciscojavierarceo left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Thanks for the update. CI is green now and some of the earlier concerns are fixed, but I still don't think this is ready to merge. The main blocker is that the OpenAI score fix is currently changing the existing Feast distance contract for native /search / retrieve_online_documents_v2 callers. I also left notes on the remaining OpenAI-compat/doc mismatches.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread sdk/python/feast/infra/online_stores/postgres_online_store/postgres.py Outdated
] != float("inf"):
dist_val = ValueProto()
dist_val.double_val = entity_data["vector_distance"]
dist_val.double_val = _distance_to_score(

@franciscojavierarceo franciscojavierarceo Jul 3, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

i think this fix landed in the wrong layer. retrieve_online_documents_v2() and /search still expose this synthetic field as distance, but Postgres now stores a higher-is-better OpenAI score in it. That changes the native Feast contract for non-OpenAI callers, and the same pattern appears in SQLite/Milvus. Can we keep the stores returning raw distances and convert to OpenAI score only in retrieve_online_documents_openai()?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
Comment thread sdk/python/feast/feature_store.py Outdated
unsupported.append("ranking_options.score_threshold")
if ranking_options.get("ranker") is not None:
unsupported.append("ranking_options.ranker")
if rewrite_query is not None:

@franciscojavierarceo franciscojavierarceo Jul 3, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

this rejects rewrite_query: false, even though that is the no-op/default shape an OpenAI-compatible client can send. OGX keeps this field for API compatibility and ignores false at the store layer. Can we only reject rewrite_query=True until query rewriting is implemented?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
Comment thread docs/reference/alpha-vector-database.md Outdated
| `query` | `string` or `list[string]` | (required) | Plain text search query. Lists are joined with spaces before embedding. |
| `max_num_results` | `int` | `10` | Maximum number of results to return. |
| `filters` | `object` | `null` | OpenAI-style filters (see below). |
| `ranking_options` | `object` | `null` | Accepted but not yet applied. |

@franciscojavierarceo franciscojavierarceo Jul 3, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

the docs now say ranking_options and rewrite_query are accepted but not applied, but the implementation raises 422 when score_threshold, ranker, or any rewrite_query value is present. Can we make the docs match the actual behavior, or wire the supported no-op/default cases?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
franciscojavierarceo
franciscojavierarceo reviewed Jul 6, 2026
View reviewed changes
Comment thread docs/reference/alpha-vector-database.md Outdated

```yaml
embedding_model:
provider: litellm # default; can be omitted

@franciscojavierarceo franciscojavierarceo Jul 6, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

i'm a little worried about requiring litellm for embeddings, why wouldn't we embed within feast? in fact, i think this is a good usage of this. even though it's not as efficient as using a GPU, it's good enough.

CC @ntkathole

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@patelchaitany patelchaitany Jul 6, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

We want to support wide range of the embedding model and using litellm for embedding looks feasible option to me but in feast we support the sentence-transformers for doing it entirely in the feast.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@franciscojavierarceo franciscojavierarceo Jul 6, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

yeah so then let's not add litellm to scope

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
franciscojavierarceo
franciscojavierarceo reviewed Jul 6, 2026
View reviewed changes
Comment thread infra/website/docs/blog/feast-openai-compatible-api.md Outdated
@@ -0,0 +1,382 @@
---
title: "Making Feast Speak OpenAI: Vector Search Without the Glue Code"

@franciscojavierarceo franciscojavierarceo Jul 6, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Suggested change
title: "Making Feast Speak OpenAI: Vector Search Without the Glue Code"
title: "Using Feast's OpenAI Compatible Search API"

are we limiting this only to vector search? or are we supporting hybrid as well?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@patelchaitany patelchaitany Jul 6, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Currently we are doing only the vector search

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
franciscojavierarceo
franciscojavierarceo approved these changes Jul 8, 2026
View reviewed changes

@franciscojavierarceo franciscojavierarceo left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

we can address this in a follow up PR but right now the diagram includes LiteLLM still but we took that out, so we should remove that from the diagram but let's get this merged.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany reacted with hooray emoji
All reactions
  • 🎉 1 reaction
@franciscojavierarceo

franciscojavierarceo commented Jul 8, 2026

Copy link
Copy Markdown
Member

@patelchaitany can you also document this feature as an alpha API in the docs?

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@patelchaitany

patelchaitany commented Jul 13, 2026

Copy link
Copy Markdown
Contributor Author

@franciscojavierarceo, I had question regarding adding the /search endpoint should we Include the retrieve_online_documents_openai() under that as well or should it remain only accessible through this endpoint
/v1/vector_stores/{vector_store_id}/search

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@franciscojavierarceo

franciscojavierarceo commented Jul 13, 2026

Copy link
Copy Markdown
Member

@franciscojavierarceo, I had question regarding adding the /search endpoint should we Include the retrieve_online_documents_openai() under that as well or should it remain only accessible through this endpoint

We should just call it search() or search_online_store() or openai_search().

I like search() as the public API that's non-OpenAI and then we could have a search() method and openai_search(). method.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@patelchaitany

patelchaitany commented Jul 13, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor Author

@franciscojavierarceo, I had question regarding adding the /search endpoint should we Include the retrieve_online_documents_openai() under that as well or should it remain only accessible through this endpoint

We should just call it search() or search_online_store() or openai_search().

I like search() as the public API that's non-OpenAI and then we could have a search() method and openai_search(). method.

Thanks @franciscojavierarceo ,so it's a change for the name, but there is not any public method for search() in the Python SDK yet (search is available as an API endpoint). If renaming the method / introducing something like search could cost more changes, so I could rename retrieve_online_documents_openai to openai_search as that is introduced in this change. But about the search API, I could simply wrap it in a wrapper, but couldn't change it completely as it might be a big change.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@franciscojavierarceo

franciscojavierarceo commented Jul 13, 2026

Copy link
Copy Markdown
Member

yeah just rename to openai_search sounds good to me

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

jyejare
jyejare reviewed Jul 13, 2026
View reviewed changes

@jyejare jyejare left a comment

Copy link
Copy Markdown
Collaborator

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

This PR adds OpenAI-compatible vector store search endpoints to Feast, enabling text-based search with server-side embedding. The implementation is comprehensive with good documentation and multi-backend support. However, there are several security concerns around input validation and potential injection attacks that need to be addressed before merging.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread sdk/python/feast/infra/online_stores/milvus_online_store/milvus.py
Comment on lines +119 to +123
"""Escape a string for safe use inside a Milvus single-quoted literal.

Backslashes must be escaped first; otherwise a trailing backslash in the
input would combine with the escaped quote to break out of the literal.
"""

@jyejare jyejare Jul 13, 2026

Copy link
Copy Markdown
Collaborator

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

[Critical] SQL Injection vulnerability in Milvus string escaping

The Milvus string escaping function only escapes backslashes and single quotes, but doesn't handle other potential injection vectors. Milvus boolean expressions could be vulnerable to injection if field names or other components aren't properly validated.

Suggested:

Suggested change
"""Escape a string for safe use inside a Milvus single-quoted literal.
Backslashes must be escaped first; otherwise a trailing backslash in the
input would combine with the escaped quote to break out of the literal.
"""
def _milvus_escape_string(s: str) -> str:
"""Escape a string for safe use inside a Milvus single-quoted literal."""
# More comprehensive escaping for Milvus
return s.replace("\\", "\\\\").replace("'", "\\'")
.replace('"', '\\"').replace('\n', '\\n').replace('\r', '\\r')

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@codecov-commenter

codecov-commenter commented Jul 20, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

❌ Patch coverage is 34.59336% with 571 lines in your changes missing coverage. Please review.
✅ Project coverage is 45.74%. Comparing base (294efad) to head (c1cc000).

Files with missing lines Patch % Lines
...ra/online_stores/postgres_online_store/postgres.py 10.07% 125 Missing ⚠️
...stores/elasticsearch_online_store/elasticsearch.py 0.00% 100 Missing ⚠️
sdk/python/feast/infra/online_stores/sqlite.py 36.69% 78 Missing and 10 partials ⚠️
sdk/python/feast/feature_store.py 13.51% 63 Missing and 1 partial ⚠️
.../infra/online_stores/milvus_online_store/milvus.py 36.36% 53 Missing and 10 partials ⚠️
sdk/python/feast/feature_server.py 51.47% 33 Missing ⚠️
...nfra/online_stores/mongodb_online_store/mongodb.py 24.24% 25 Missing ⚠️
sdk/python/feast/embedder.py 38.88% 22 Missing ⚠️
sdk/python/feast/infra/online_stores/remote.py 38.88% 16 Missing and 6 partials ⚠️
sdk/python/feast/filter_models.py 66.66% 13 Missing ⚠️
... and 5 more
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #6121      +/-   ##
==========================================
- Coverage   45.94%   45.74%   -0.21%     
==========================================
  Files         412      414       +2     
  Lines       48864    49668     +804     
  Branches     6913     7078     +165     
==========================================
+ Hits        22452    22722     +270     
- Misses      24859    25366     +507     
- Partials     1553     1580      +27     
Flag Coverage Δ
go-feature-server 30.58% <ø> (ø)
python-unit 47.00% <34.59%> (-0.24%) ⬇️
Files with missing lines Coverage Δ
sdk/python/feast/__init__.py 97.05% <100.00%> (+0.08%) ⬆️
...k/python/feast/infra/online_stores/online_store.py 70.38% <100.00%> (+0.10%) ⬆️
sdk/python/feast/infra/passthrough_provider.py 61.22% <100.00%> (+0.19%) ⬆️
sdk/python/feast/infra/provider.py 92.30% <100.00%> (+0.08%) ⬆️
sdk/python/feast/repo_config.py 77.77% <100.00%> (+0.39%) ⬆️
sdk/python/feast/vector_store_utils.py 100.00% <100.00%> (ø)
...on/feast/api/registry/rest/rest_registry_server.py 77.21% <71.42%> (-0.57%) ⬇️
sdk/python/feast/infra/online_stores/helpers.py 95.91% <81.81%> (-4.09%) ⬇️
...ra/online_stores/scylladb_online_store/scylladb.py 0.00% <0.00%> (ø)
sdk/python/feast/infra/mcp_servers/mcp_server.py 85.50% <87.09%> (+0.89%) ⬆️
... and 11 more

... and 1 file with indirect coverage changes


Continue to review full report in Codecov by Harness.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 294efad...c1cc000. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

patelchaitany added 8 commits July 21, 2026 14:34
@patelchaitany
Phase 1: Added basic open ai competible search api in the vector store
357b888
Signed-off-by: Chaitany patel <[email protected]>
@patelchaitany
Added test for testing the new OpenAI api
2859abe
Signed-off-by: Chaitany patel <[email protected]>
@patelchaitany
fix: patch fastapi_mcp circular recursion that blocks MCP endpoint re…
4c0d230
…gistration

fastapi_mcp 0.4.0 resolve_schema_references() has no cycle detection.
Feast's OpenAPI schema contains self-referential protobuf types
(Value -> Struct -> Value) which trigger a RecursionError.  The error
is silently caught, so the /mcp route never gets registered and CI
gets a 404.
Add _resolve_schema_references_safe() that tracks a seen-refs set to
break circular  chains, and monkey-patch it into fastapi_mcp
before FastApiMCP processes the schema.  Non-circular schemas produce
identical output to the original.

Signed-off-by: Chaitany patel <[email protected]>
@patelchaitany
docs: Update filtering requirements for Postgres and SQLite backends …
ec4ccce
…in alpha-vector-database.md; enhance error handling in feature_server.py for invalid requests; clarify unsupported parameters in feature_store.py; ensure requested_features is a list in remote.py

Signed-off-by: Chaitany patel <[email protected]>
Signed-off-by: Chaitany Patel <[email protected]>
@patelchaitany
- Accept rewrite_query=false as a no-op; only reject
fcaebbd
  true
  - Document score conversion formulas and distance
  metrics in
    alpha-vector-database.md
  - Add Sentence Transformers as a supported embedding
  provider
  - Fix embedding_model config example in docstring

Signed-off-by: Chaitany Patel <[email protected]>
@patelchaitany
- Add GET /v1/vector_stores and GET
7465fc3
  /v1/vector_stores/{id} endpoints
    with RBAC enforcement (DESCRIBE permission)
  - Introduce VectorStoreRegistry cache that derives
  vs_{sha256} IDs from
    project + feature view name, refreshed on registry
  TTL cycle
  - Replace raw feature view names with stable vs_
  identifiers in search
    responses (file_id, filename fields)
  - Update docs, blog post, and integration tests for
  new ID scheme
  - Add unit tests for VectorStoreRegistry, ID
  generation, and object building

Signed-off-by: Chaitany Patel <[email protected]>
@patelchaitany
Remove LiteLLM embedding provider, default to Sentence Transformers
7629ab5
Signed-off-by: Chaitany Patel <[email protected]>
@patelchaitany
Updatethe Docs, documented OpenAI search API as Alpha
c1cc000
Signed-off-by: Chaitany Patel <[email protected]>
@patelchaitany

patelchaitany commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

@franciscojavierarceo let me know if any changes are required.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

franciscojavierarceo
franciscojavierarceo approved these changes Jul 22, 2026
View reviewed changes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@devin-ai-integration devin-ai-integration[bot] devin-ai-integration[bot] left review comments
@franciscojavierarceo franciscojavierarceo franciscojavierarceo approved these changes
@haoxu0 haoxu0 Awaiting requested review from haoxu0 haoxu0 is a code owner automatically assigned from feast-dev/maintainers
@redhatHameed redhatHameed Awaiting requested review from redhatHameed redhatHameed is a code owner automatically assigned from feast-dev/maintainers
@nquinn408 nquinn408 Awaiting requested review from nquinn408 nquinn408 is a code owner automatically assigned from feast-dev/maintainers
@ntkathole ntkathole Awaiting requested review from ntkathole
@jyejare jyejare Awaiting requested review from jyejare
+1 more reviewer
@github-advanced-security github-advanced-security[bot] github-advanced-security[bot] left review comments
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

ok-to-test

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

6 participants

@patelchaitany @ntkathole @franciscojavierarceo @codecov-commenter @jyejare @github-advanced-security
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.