-
Notifications
You must be signed in to change notification settings - Fork 72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support empty string for fields in text embedding processor #1041
Support empty string for fields in text embedding processor #1041
Conversation
Signed-off-by: Yizhe Liu <[email protected]>
Signed-off-by: Yizhe Liu <[email protected]>
Signed-off-by: Yizhe Liu <[email protected]>
cfe4a5d
to
edd268c
Compare
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.
LGTM, thanks!
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.
LGTM thanks. Congrats @yizheliu-amazon on the first PR in neural search repo.
Do not merge until changelog comment is addressed. |
…g processor Signed-off-by: Yizhe Liu <[email protected]>
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-2.x 2.x
# Navigate to the new working tree
cd .worktrees/backport-2.x
# Create a new branch
git switch --create backport/backport-1041-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 ee24b1c92b41e9f9f1625e1036f790555d7fba07
# Push it to GitHub
git push --set-upstream origin backport/backport-1041-to-2.x
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-2.x Then, create a pull request where the |
…ch-project#1041) * Allow empty string for field in field map Signed-off-by: Yizhe Liu <[email protected]> * Allow empty string when validation Signed-off-by: Yizhe Liu <[email protected]> * Add to change log Signed-off-by: Yizhe Liu <[email protected]> * Update CHANGELOG to: Support empty string for fields in text embedding processor Signed-off-by: Yizhe Liu <[email protected]> --------- Signed-off-by: Yizhe Liu <[email protected]>
…1046) * Allow empty string for field in field map * Allow empty string when validation * Add to change log * Update CHANGELOG to: Support empty string for fields in text embedding processor --------- Signed-off-by: Yizhe Liu <[email protected]>
Description
Allow empty string for field in field map.
The basic idea is to mark field with empty string as
null
, so that empty value for such field won't be taken into account.Related Issues
Resolves #774
What is the current experience
For current text_embedding processor, it does not allow empty field of fieldMap due to validation here
Given such fieldMap
if below document is being ingested, ingestion will fail
Result:
After the PR how will the experience look like
Given same fieldMap and request as above, with this PR, the result looks like below
What are the use cases of this fix
The use case we want to support is: we still allow document ingestion even if it has some fields in fieldMap with empty/null value
As mentioned in #774 , because not all document have valid values for field in fieldMap. Also,
Check List
--signoff
.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.