Skip to content

Fix use of Huggingface#1363

Draft
austin-aryn-ai wants to merge 1 commit intomainfrom
austin/ut-cleanup
Draft

Fix use of Huggingface#1363
austin-aryn-ai wants to merge 1 commit intomainfrom
austin/ut-cleanup

Conversation

@austin-aryn-ai
Copy link
Contributor

I used the pytest hook in this PR to find all unit tests that download a model from Huggingface:

test_infer
test_partition
test_partition_with_ocr_instance
test_table_extraction_order
test_detr_pdfminer_object_type
test_sentence_transformer[sentence-transformers/all-MiniLM-L6-v2-384-texts0]
test_sentence_transformer[sentence-transformers/all-MiniLM-L6-v2-384-texts1]
test_sentence_transformer[sentence-transformers/all-mpnet-base-v2-768-texts2]
test_sentence_transformer_embedding
test_sentence_transformer_batch_size
test_merge_elements
test_merge_elements_via_execute
test_docset_greedy
test_merge_elements
test_merge_elements_image_summarize
test_merge_elements_via_execute
test_docset_greedy
test_merge_empty_text_works
test_merge_elements
test_merge_elements_via_execute
test_docset_augmented
test_transformers_similarity_scorer
test_transformers_similarity_scorer_no_doc_structure
test_transformers_similarity_scorer_no_element_id
test_transformers_score_similarity
test_split_elements
test_via_execute
test_tf_with_bert_tokenizer
test_tf_with_bert_tokenizer_with_token_ids

I think some of these can be rewritten not to use a model from HF and some of them should be moved to /integration.

Comment on lines +36 to +41
@pytest.fixture(scope="function", autouse=True)
def check_huggingface_hub(request):
"""
Use this to find tests that download a model from Huggingface.
"""

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This hook won't be enabled in main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant