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

feat(core): add embeddings #2

Merged
merged 2 commits into from
Sep 11, 2024
Merged

feat(core): add embeddings #2

merged 2 commits into from
Sep 11, 2024

Conversation

PatrykWyzgowski
Copy link
Contributor

Adding classes responsible for text embedding and handling embedding errors.

@PatrykWyzgowski PatrykWyzgowski self-assigned this Sep 11, 2024
Copy link
Contributor

github-actions bot commented Sep 11, 2024

🧪 Test coverage: 92.92%

Code Coverage Summary

Filename                                                                                                  Stmts    Miss  Cover    Missing
------------------------------------------------------------------------------------------------------  -------  ------  -------  -----------------------
packages/ragnarok-common/src/ragnarok_common/__init__.py                                                      0       0  100.00%
packages/ragnarok-common/src/ragnarok_common/llms/__init__.py                                                 4       0  100.00%
packages/ragnarok-common/src/ragnarok_common/llms/base.py                                                    33       4  87.88%   33, 52, 88, 97
packages/ragnarok-common/src/ragnarok_common/llms/litellm.py                                                 25       4  84.00%   8-9, 54, 85
packages/ragnarok-common/src/ragnarok_common/llms/local.py                                                   24       9  62.50%   7, 39-44, 54, 67-68
packages/ragnarok-common/src/ragnarok_common/llms/types.py                                                    8       2  75.00%   24, 28
packages/ragnarok-common/src/ragnarok_common/llms/clients/__init__.py                                         4       0  100.00%
packages/ragnarok-common/src/ragnarok_common/llms/clients/base.py                                            23       0  100.00%
packages/ragnarok-common/src/ragnarok_common/llms/clients/exceptions.py                                      14       6  57.14%   7-8, 17, 26-27, 36
packages/ragnarok-common/src/ragnarok_common/llms/clients/litellm.py                                         50      10  80.00%   10-11, 70, 108, 122-127
packages/ragnarok-common/src/ragnarok_common/llms/clients/local.py                                           37      12  67.57%   8-10, 59-67, 89-100
packages/ragnarok-common/src/ragnarok_common/prompt/__init__.py                                               2       0  100.00%
packages/ragnarok-common/src/ragnarok_common/prompt/base.py                                                  18       0  100.00%
packages/ragnarok-common/src/ragnarok_common/prompt/parsers.py                                               34       0  100.00%
packages/ragnarok-common/src/ragnarok_common/prompt/prompt.py                                                96       2  97.92%   103, 107
packages/ragnarok-common/tests/__init__.py                                                                    0       0  100.00%
packages/ragnarok-common/tests/unit/__init__.py                                                               0       0  100.00%
packages/ragnarok-common/tests/unit/llms/__init__.py                                                          0       0  100.00%
packages/ragnarok-common/tests/unit/llms/test_litellm.py                                                     63       0  100.00%
packages/ragnarok-common/tests/unit/prompts/__init__.py                                                       0       0  100.00%
packages/ragnarok-common/tests/unit/prompts/test_parsers.py                                                  65       0  100.00%
packages/ragnarok-common/tests/unit/prompts/test_prompt.py                                                   81       0  100.00%
packages/ragnarok-dev-kit/src/ragnarok_dev_kit/__init__.py                                                    0       0  100.00%
packages/ragnarok-dev-kit/src/ragnarok_dev_kit/discovery/__init__.py                                          2       0  100.00%
packages/ragnarok-dev-kit/src/ragnarok_dev_kit/discovery/prompt_discovery.py                                 38       1  97.37%   62
packages/ragnarok-dev-kit/tests/unit/discovery/prompt_classes_for_tests.py                                   27       0  100.00%
packages/ragnarok-dev-kit/tests/unit/discovery/test_prompt_discovery.py                                      25       0  100.00%
packages/ragnarok-dev-kit/tests/unit/discovery/ragnarok_tests_pkg_with_prompts/__init__.py                    2       0  100.00%
packages/ragnarok-dev-kit/tests/unit/discovery/ragnarok_tests_pkg_with_prompts/prompts/__init__.py            3       0  100.00%
packages/ragnarok-dev-kit/tests/unit/discovery/ragnarok_tests_pkg_with_prompts/prompts/temp_prompt1.py       14       0  100.00%
packages/ragnarok-dev-kit/tests/unit/discovery/ragnarok_tests_pkg_with_prompts/prompts/temp_prompt2.py       14       0  100.00%
TOTAL                                                                                                       706      50  92.92%

Diff against main

Filename      Stmts    Miss  Cover
----------  -------  ------  --------
TOTAL             0       0  +100.00%

Results for commit: 69d90b5

Minimum allowed coverage is 60%

♻️ This comment has been updated with latest results

Copy link
Contributor

Trivy scanning results.

Copy link
Member

@mhordynski mhordynski left a comment

Choose a reason for hiding this comment

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

lgtm

@micpst micpst added feature New feature or request document search Changes to the document search package labels Sep 11, 2024
@PatrykWyzgowski PatrykWyzgowski merged commit 25d8249 into main Sep 11, 2024
3 checks passed
@micpst micpst deleted the pw/add_embeddings branch September 12, 2024 09:22
@micpst micpst added core Changes to the core package integrations Changes in vendor integration and removed document search Changes to the document search package labels Sep 13, 2024
@micpst micpst changed the title feat: add embeddings feat(core): add embeddings Sep 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Changes to the core package feature New feature or request integrations Changes in vendor integration
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants