CoolFace
Modelpublic

MinhPhuc0804/qwen3-embedding-docling-checkthat-task1-v1

sourceHugging Faceupdated 5mo agoView on Hugging Face
0likes68downloads
Model Card

SentenceTransformer based on Qwen/Qwen3-Embedding-0.6B

This is a sentence-transformers model finetuned from Qwen/Qwen3-Embedding-0.6B. It maps sentences & paragraphs to a 1024-dimensional dense vector space and can be used for retrieval.

Model Details

Model Description

  • Model Type: Sentence Transformer
  • Base model: Qwen/Qwen3-Embedding-0.6B <!-- at revision c54f2e6e80b2d7b7de06f51cec4959f6b3e03418 -->
  • Maximum Sequence Length: 256 tokens
  • Output Dimensionality: 1024 dimensions
  • Similarity Function: Cosine Similarity
  • Supported Modality: Text <!-- - Training Dataset: Unknown --> <!-- - Language: Unknown --> <!-- - License: Unknown -->

Model Sources

Full Model Architecture

SentenceTransformer(
  (0): Transformer({'transformer_task': 'feature-extraction', 'modality_config': {'text': {'method': 'forward', 'method_output_name': 'last_hidden_state'}}, 'module_output_name': 'token_embeddings', 'architecture': 'Qwen3Model'})
  (1): Pooling({'embedding_dimension': 1024, 'pooling_mode': 'lasttoken', 'include_prompt': True})
  (2): Normalize({})
)

Usage

Direct Usage (Sentence Transformers)

First install the Sentence Transformers library:

bash
pip install -U sentence-transformers

Then you can load this model and run inference.

python
from sentence_transformers import SentenceTransformer

# Download from the 🤗 Hub
model = SentenceTransformer("MinhPhuc0804/qwen3-embedding-docling-checkthat-task1-v1")
# Run inference
queries = [
    'query: Myocarditis-triggered Unexpected Demise following BNT162b2 mRNA COVID-19 Immunization in Korea: Case Study Concentrating on Tissue-level Findings Sangjoon Choi et al.',
]
documents = [
    'passage: title: Myocarditis-induced Sudden Death after BNT162b2 mRNA COVID-19 Vaccination in Korea: Case Report Focusing on Histopathological Findings\nabstract: We present autopsy findings of a 22-year-old man who developed chest pain 5 days after the first dose of the BNT162b2 mRNA vaccine and died 7 hours later. Histological examination of the heart revealed isolated atrial myocarditis, with neutrophil and histiocyte predominance. Immunohistochemical C4d staining revealed scattered single-cell necrosis of myocytes which was not accompanied by inflammatory infiltrates. Extensive contraction band necrosis was observed in the atria and ventricles. There was no evidence of microthrombosis or infection in the heart and other organs. The primary cause of death was determined to be myocarditis, causally-associated with the BNT162b2 vaccine.',
    'passage: atase (DUSP) expression in neurons in the disease process.\n\ntitle: Mitogen Activated Protein Kinase (MAPK) Activation, p53, and Autophagy Inhibition Characterize the Severe Acute Respiratory Syndrome Coronavirus 2 (SARS-CoV-2) Spike Protein Induced Neurotoxicity\nThe pathways induced by the spike protein via toll-like receptor activation induce both the upregulation of PrPC (the normal isoform of the prion protein, PrP) and the expression of β amyloid. Through the spike-protein-dependent elevation of p53 levels via β amyloid metabolism, increased PrPC expression can lead to PrP misfolding and impaired autophagy, generating prion disease. We conclude that, according to the age of the spike protein-exposed patient and the state of their cellular autophagy activity, excess sustained activity of p53 in neurons may be a catalytic factor in neurodegeneration. An autoimmune reaction via molecular mimicry likely also contributes to neurological symptoms. Overall results suggest that neurodegeneration is in part due to the intensity and duration of spike protein exposure, patient advanced age, cellular autophagy activity, and activation, function and regulation of p53.',
    'passage: more contacts (22.8%; 95% CI, 13.6%-33.5%).\n\ntitle: Household Transmission of SARS-CoV-2\n<h3>Conclusions and Relevance</h3> The findings of this study suggest that given that individuals with suspected or confirmed infections are being referred to isolate at home, households will continue to be a significant venue for transmission of SARS-CoV-2.',
]
query_embeddings = model.encode_query(queries)
document_embeddings = model.encode_document(documents)
print(query_embeddings.shape, document_embeddings.shape)
# [1, 1024] [3, 1024]

# Get the similarity scores for the embeddings
similarities = model.similarity(query_embeddings, document_embeddings)
print(similarities)
# tensor([[0.8458, 0.1361, 0.0091]])

<!--

Direct Usage (Transformers)

<details><summary>Click to see the direct usage in Transformers</summary>

</details> -->

<!--

Downstream Usage (Sentence Transformers)

You can finetune this model on your own dataset.

<details><summary>Click to expand</summary>

</details> -->

<!--

Out-of-Scope Use

List how the model may foreseeably be misused and address what users ought not to do with the model. -->

Evaluation

Metrics

Information Retrieval
MetricValue
cosine_accuracy@10.5595
cosine_accuracy@30.7668
cosine_accuracy@50.8234
cosine_accuracy@100.8712
cosine_precision@10.5595
cosine_precision@30.2556
cosine_precision@50.1647
cosine_precision@100.0871
cosine_recall@10.5595
cosine_recall@30.7668
cosine_recall@50.8234
cosine_recall@100.8712
cosine_ndcg@100.721
cosine_mrr@100.6723
cosine_map@1000.676

<!--

Bias, Risks and Limitations

What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model. -->

<!--

Recommendations

What are recommendations with respect to the foreseeable issues? For example, filtering explicit content. -->

Training Details

Training Dataset

Unnamed Dataset
  • Size: 17,319 training samples
  • Columns: <code>sentence0</code> and <code>sentence1</code>
  • Approximate statistics based on the first 1000 samples: | | sentence0 | sentence1 | |:--------|:------------------------------------------------------------------------------------|:-------------------------------------------------------------------------------------| | type | string | string | | details | <ul><li>min: 19 tokens</li><li>mean: 54.81 tokens</li><li>max: 123 tokens</li></ul> | <ul><li>min: 21 tokens</li><li>mean: 180.82 tokens</li><li>max: 256 tokens</li></ul> |
  • Samples: | sentence0 | sentence1 | |:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | <code>query: 10) Sure enough, a slew of reports in numerous nations showing a rise in infections in children in the fresh surge in 2021, probably because of #B117 variant.</code> | <code>passage: otherapy at Israel's Bar-Ilan University and member of the country's national covid-19 vaccine clinical trial advisory committee,<br><br>title: Covid-19: More young children are being infected in Israel and Italy, emerging data suggest<br>told The BMJ that his figures indicated that, since the emergence of the UK variant B1.1.7 in Israel in mid-December, the proportion of new daily cases accounted for by children aged under 10 had risen by nearly a quarter (23%).Cohen urged caution over schools reopening."Though I am convinced that education should be the first sector to open up because of its importance, it is my personal opinion that we should still reopen gradually .<br>. .until we understand better the infection pattern of this new variant," he said.He said that no evidence yet showed the new variant to be more dangerous to children, but he noted that in January Israel had opened its first special covid-19 intensive care unit for children, admitting four or five children.</code> | | <code>query: CDC: Monkeypox isn’t airborne. And CDC: Wear a snug mask. Me: snug mask might only imply aerosols. Which are in the air. If not, you could wear a face shield for just droplets. Research on fomites- reveals that #MonkeypoxIsAirborne</code> | <code>passage: " or ulcerated, to characteristically well-circumscribed and centrally umbilicated. Both patients had mild illness.<br><br>title: High-Contact Object and Surface Contamination in a Household of Persons with <i>Monkeypox Virus</i> Infection — Utah, June 2022<br>The time from symptom onset to resolution was approximately 30 days for patient A and approximately 22 days for patient B.</code> | | <code>query: The extra advantage of vaccination combined with Omicron infection for neutralizing antibodies versus infection alone: far reduced expected protection throughout all variants, Omicron itself included.</code> | <code>passage: title: Neutralization profile of Omicron variant convalescent individuals<br>abstract: Abstract Recently, the Omicron variant of the severe acute respiratory syndrome coronavirus 2 (SARS-CoV-2) has been described as immune escape variant. Here, we analyzed samples from BA.1 (Omicron) convalescent patients with different constellations of prior SARS-CoV-2 immunity regarding vaccination and previous infection with a non-Omicron variant and determined titers of neutralizing antibodies against different SARS-CoV-2 variants (D614G, Alpha, Beta, Delta, Gamma, Omicron). We found high neutralizing antibody titers against all variants for vaccinated individuals after BA.1 breakthrough infection or for individuals after infection with a pre-omicron variant followed by BA.1 infection. In contrast, samples from naive unvaccinated individuals after BA.1 infection mainly contained neutralizing antibodies against BA.1 but only occasionally against the other variants.</code> |
  • Loss: <code>MultipleNegativesRankingLoss</code> with these parameters:
json
  {
      "scale": 20.0,
      "similarity_fct": "cos_sim",
      "gather_across_devices": false,
      "directions": [
          "query_to_doc"
      ],
      "partition_mode": "joint",
      "hardness_mode": null,
      "hardness_strength": 0.0
  }

Training Hyperparameters

Non-Default Hyperparameters
  • per_device_train_batch_size: 32
  • per_device_eval_batch_size: 32
  • num_train_epochs: 10
  • fp16: True
  • multi_dataset_batch_sampler: round_robin
All Hyperparameters

<details><summary>Click to expand</summary>

  • overwrite_output_dir: False
  • do_predict: False
  • prediction_loss_only: True
  • per_device_train_batch_size: 32
  • per_device_eval_batch_size: 32
  • per_gpu_train_batch_size: None
  • per_gpu_eval_batch_size: None
  • gradient_accumulation_steps: 1
  • eval_accumulation_steps: None
  • torch_empty_cache_steps: None
  • learning_rate: 5e-05
  • weight_decay: 0.0
  • adam_beta1: 0.9
  • adam_beta2: 0.999
  • adam_epsilon: 1e-08
  • max_grad_norm: 1
  • num_train_epochs: 10
  • max_steps: -1
  • lr_scheduler_type: linear
  • lr_scheduler_kwargs: {}
  • warmup_ratio: 0.0
  • warmup_steps: 0
  • log_level: passive
  • log_level_replica: warning
  • log_on_each_node: True
  • logging_nan_inf_filter: True
  • save_safetensors: True
  • save_on_each_node: False
  • save_only_model: False
  • restore_callback_states_from_checkpoint: False
  • no_cuda: False
  • use_cpu: False
  • use_mps_device: False
  • seed: 42
  • data_seed: None
  • jit_mode_eval: False
  • use_ipex: False
  • bf16: False
  • fp16: True
  • fp16_opt_level: O1
  • half_precision_backend: auto
  • bf16_full_eval: False
  • fp16_full_eval: False
  • tf32: None
  • local_rank: 0
  • ddp_backend: None
  • tpu_num_cores: None
  • tpu_metrics_debug: False
  • debug: []
  • dataloader_drop_last: False
  • dataloader_num_workers: 0
  • dataloader_prefetch_factor: None
  • past_index: -1
  • disable_tqdm: False
  • remove_unused_columns: True
  • label_names: None
  • load_best_model_at_end: False
  • ignore_data_skip: False
  • fsdp: []
  • fsdp_min_num_params: 0
  • fsdp_config: {'minnumparams': 0, 'xla': False, 'xlafsdpv2': False, 'xlafsdpgrad_ckpt': False}
  • fsdp_transformer_layer_cls_to_wrap: None
  • accelerator_config: {'splitbatches': False, 'dispatchbatches': None, 'evenbatches': True, 'useseedablesampler': True, 'nonblocking': False, 'gradientaccumulationkwargs': None}
  • parallelism_config: None
  • deepspeed: None
  • label_smoothing_factor: 0.0
  • optim: adamwtorchfused
  • optim_args: None
  • adafactor: False
  • group_by_length: False
  • length_column_name: length
  • ddp_find_unused_parameters: None
  • ddp_bucket_cap_mb: None
  • ddp_broadcast_buffers: False
  • dataloader_pin_memory: True
  • dataloader_persistent_workers: False
  • skip_memory_metrics: True
  • use_legacy_prediction_loop: False
  • push_to_hub: False
  • resume_from_checkpoint: None
  • hub_model_id: None
  • hub_strategy: every_save
  • hub_private_repo: None
  • hub_always_push: False
  • hub_revision: None
  • gradient_checkpointing: False
  • gradient_checkpointing_kwargs: None
  • include_inputs_for_metrics: False
  • include_for_metrics: []
  • eval_do_concat_batches: True
  • fp16_backend: auto
  • push_to_hub_model_id: None
  • push_to_hub_organization: None
  • mp_parameters:
  • auto_find_batch_size: False
  • full_determinism: False
  • torchdynamo: None
  • ray_scope: last
  • ddp_timeout: 1800
  • torch_compile: False
  • torch_compile_backend: None
  • torch_compile_mode: None
  • include_tokens_per_second: False
  • include_num_input_tokens_seen: False
  • neftune_noise_alpha: None
  • optim_target_modules: None
  • batch_eval_metrics: False
  • eval_on_start: False
  • use_liger_kernel: False
  • liger_kernel_config: None
  • eval_use_gather_object: False
  • average_tokens_across_devices: False
  • prompts: None
  • batch_sampler: batch_sampler
  • multi_dataset_batch_sampler: round_robin
  • router_mapping: {}
  • learning_rate_mapping: {}

</details>

Training Logs

EpochStepTraining Loss10-percent-dev-split_cosine_ndcg@10
0.92255000.3566-
1.0542-0.7010
1.845010000.194-
2.01084-0.7106
2.767515000.0851-
3.01626-0.7200
3.690020000.0447-
4.02168-0.7184
4.612525000.0342-
5.02710-0.7151
5.535130000.0254-
6.03252-0.7113
6.457635000.0216-
7.03794-0.7171
7.380140000.0189-
8.04336-0.7221
8.302645000.0169-
9.04878-0.7179
9.225150000.0167-
10.05420-0.7210

Training Time

  • Training: 1.3 hours

Framework Versions

  • Python: 3.12.6
  • Sentence Transformers: 5.4.1
  • Transformers: 4.56.0
  • PyTorch: 2.8.0+cu129
  • Accelerate: 1.10.1
  • Datasets: 4.8.4
  • Tokenizers: 0.22.0

Citation

BibTeX

Sentence Transformers
bibtex
@inproceedings{reimers-2019-sentence-bert,
    title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
    author = "Reimers, Nils and Gurevych, Iryna",
    booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
    month = "11",
    year = "2019",
    publisher = "Association for Computational Linguistics",
    url = "https://arxiv.org/abs/1908.10084",
}
MultipleNegativesRankingLoss
bibtex
@misc{oord2019representationlearningcontrastivepredictive,
      title={Representation Learning with Contrastive Predictive Coding},
      author={Aaron van den Oord and Yazhe Li and Oriol Vinyals},
      year={2019},
      eprint={1807.03748},
      archivePrefix={arXiv},
      primaryClass={cs.LG},
      url={https://arxiv.org/abs/1807.03748},
}

<!--

Glossary

Clearly define terms in order to be accessible across audiences. -->

<!--

Model Card Authors

Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction. -->

<!--

Model Card Contact

Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors. -->