Skip to content
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

Bilingual document example #43

Merged
merged 4 commits into from
Oct 25, 2024

Conversation

David-OC17
Copy link
Contributor

PR corresponding to this issue Create an example notebook with alignment of a bilingual document #42 .

The PR includes a new example use of the TextToEmbeddingModelPipeline. The use case shows how one can determine which sentences correspond to each other in a document, in this case a group of sentences from the first chapter of the novel "The Metamorphosis".

Why ?

The point of this PR is to further extend the examples that the repo provides for new users, and make it easier to understand in its different applications.

How ?

The example uses Dynamic Time Warping (DTW) to determine the cosine distance, and thus the optimal alignment of the provided sentences.

@facebook-github-bot
Copy link

Hi @David-OC17!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks!

@David-OC17 David-OC17 changed the title Bilingual document Bilingual document example Oct 4, 2024
@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Oct 4, 2024
@facebook-github-bot
Copy link

Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks!

Copy link
Contributor

@avidale avidale left a comment

Choose a reason for hiding this comment

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

A nice progress, thank you for adding this!
I added a few comments on how we could make the notebook even more informative.

README.md Outdated Show resolved Hide resolved
examples/bilingual_document.ipynb Outdated Show resolved Hide resolved
examples/bilingual_document.ipynb Outdated Show resolved Hide resolved
examples/bilingual_document.ipynb Show resolved Hide resolved
examples/bilingual_document.ipynb Outdated Show resolved Hide resolved
examples/bilingual_document.ipynb Outdated Show resolved Hide resolved
examples/bilingual_document.ipynb Outdated Show resolved Hide resolved
examples/bilingual_document.ipynb Outdated Show resolved Hide resolved
examples/bilingual_document.ipynb Outdated Show resolved Hide resolved
examples/bilingual_document.ipynb Outdated Show resolved Hide resolved
David-OC17 added a commit to David-OC17/SONAR that referenced this pull request Oct 7, 2024
@David-OC17 David-OC17 requested a review from avidale October 9, 2024 16:18
Copy link
Contributor

@avidale avidale left a comment

Choose a reason for hiding this comment

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

Looks very good!
Maybe, we shouldn't commit the bilingual_book.html file, though.
Apart from that, the PR is ready to merge!

examples/bilingual_book.html Outdated Show resolved Hide resolved
@avidale
Copy link
Contributor

avidale commented Oct 24, 2024

Looks great!
I suggest we merge it now.
And looking forward to the next PR!

@David-OC17 David-OC17 closed this Oct 24, 2024
@David-OC17 David-OC17 reopened this Oct 24, 2024
@avidale avidale merged commit f17dffa into facebookresearch:main Oct 25, 2024
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants