ThanhLe0125 / e5-math-ebd-01

huggingface.co
Total runs: 12
24-hour runs: 1
7-day runs: -2
30-day runs: -1
Model's Last Updated: July 11 2025
sentence-similarity

Introduction of e5-math-ebd-01

Model Details of e5-math-ebd-01

SentenceTransformer based on intfloat/multilingual-e5-base

This is a sentence-transformers model finetuned from intfloat/multilingual-e5-base . It maps sentences & paragraphs to a 768-dimensional dense vector space and can be used for semantic textual similarity, semantic search, paraphrase mining, text classification, clustering, and more.

Model Details
Model Description
  • Model Type: Sentence Transformer
  • Base model: intfloat/multilingual-e5-base
  • Maximum Sequence Length: 256 tokens
  • Output Dimensionality: 768 dimensions
  • Similarity Function: Cosine Similarity
Model Sources
Full Model Architecture
SentenceTransformer(
  (0): Transformer({'max_seq_length': 256, 'do_lower_case': False}) with Transformer model: XLMRobertaModel 
  (1): Pooling({'word_embedding_dimension': 768, 'pooling_mode_cls_token': False, 'pooling_mode_mean_tokens': True, 'pooling_mode_max_tokens': False, 'pooling_mode_mean_sqrt_len_tokens': False, 'pooling_mode_weightedmean_tokens': False, 'pooling_mode_lasttoken': False, 'include_prompt': True})
  (2): Normalize()
)
Usage
Direct Usage (Sentence Transformers)

First install the Sentence Transformers library:

pip install -U sentence-transformers

Then you can load this model and run inference.

from sentence_transformers import SentenceTransformer

# Download from the 🤗 Hub
model = SentenceTransformer("ThanhLe0125/e5-math-ebd-01")
# Run inference
sentences = [
    'query: Nếu u1 = 2 và q = 3, tìm u4.',
    'passage: # Cấp số nhân\n\n## Định nghĩa\n**Cấp số nhân** là dãy số $(u_n)$ mà kể từ số hạng thứ hai, mỗi số hạng đều bằng số hạng đứng trước nó nhân với một số không đổi $q \\neq 0$.\n\n$$u_{n+1} = u_n \\times q \\quad (\\forall n \\geq 1)$$\n\nSố $q$ được gọi là **công bội** của cấp số nhân.\n\n## Số hạng tổng quát\n$$u_n = u_1 \\times q^{n-1}$$\n\nHoặc với số hạng bất kỳ: $u_n = u_k \\times q^{n-k}$\n\n## Tính chất cơ bản\n1. **Tính chất đặc trưng:** $\\frac{u_{n+1}}{u_n} = q$ (hằng số, $u_n \\neq 0$)\n\n2. **Số hạng ở giữa:** $u_k^2 = u_{k-p} \\times u_{k+p}$ với $p > 0$\n\n3. **Ba số hạng liên tiếp:** $a, b, c$ tạo thành CSN ⇔ $b^2 = ac$ (với $a, c$ cùng dấu)\n\n## Ví dụ\n**Ví dụ 1:** Dãy số $3, 6, 12, 24, 48, ...$\n- Số hạng đầu: $u_1 = 3$\n- Công bội: $q = \\frac{6}{3} = 2$\n- Số hạng tổng quát: $u_n = 3 \\times 2^{n-1}$\n\n**Ví dụ 2:** Cho CSN có $u_2 = 6$ và $u_5 = 162$. Tìm $u_1$ và $q$.\n\n**Lời giải:**\n$u_5 = u_2 \\times q^3 \\Rightarrow 162 = 6 \\times q^3 \\Rightarrow q^3 = 27 \\Rightarrow q = 3$\n\n$u_1 = \\frac{u_2}{q} = \\frac{6}{3} = 2$\n\n## Ứng dụng thực tế\n- **Lãi suất kép:** Tiền lãi được cộng vào vốn gốc\n- **Tăng trưởng dân số:** Tăng theo tỷ lệ phần trăm hàng năm\n- **Phân rã phong xạ:** Giảm theo tỷ lệ cố định\n- **Lan truyền virus:** Số ca nhiễm tăng theo cấp số nhân',
    'passage: # Tổ hợp\n\n## Định nghĩa\n**Tổ hợp chập $k$ của $n$ phần tử** là cách chọn $k$ phần tử từ $n$ phần tử mà không quan tâm đến thứ tự.\n\n**Ký hiệu:** $C_n^k$ hoặc $\\binom{n}{k}$\n\n**Điều kiện:** $0 \\leq k \\leq n$\n\n## Công thức\n$$C_n^k = \\frac{A_n^k}{k!} = \\frac{n!}{k!(n-k)!}$$\n\n**Công thức Pascal:** $C_n^k = C_{n-1}^{k-1} + C_{n-1}^k$\n\n## Tính chất cơ bản\n1. $C_n^0 = C_n^n = 1$\n2. $C_n^k = C_n^{n-k}$\n3. $C_n^1 = n$\n4. $C_n^2 = \\frac{n(n-1)}{2}$\n\n## Ví dụ tính toán\n**Ví dụ 1:** Từ 10 học sinh, chọn 3 học sinh tham gia đội tuyển. Có bao nhiêu cách?\n\n**Lời giải:** $C_{10}^3 = \\frac{10!}{3! \\times 7!} = \\frac{10 \\times 9 \\times 8}{3 \\times 2 \\times 1} = 120$ cách.\n\n**Ví dụ 2:** Trong một lớp có 15 nam và 10 nữ. Chọn 5 người sao cho có đúng 3 nam và 2 nữ.\n\n**Lời giải:** \n- Chọn 3 nam từ 15 nam: $C_{15}^3 = 455$ cách\n- Chọn 2 nữ từ 10 nữ: $C_{10}^2 = 45$ cách\n- Tổng cộng: $455 \\times 45 = 20,475$ cách\n\n## Nhị thức Newton\n$$(a + b)^n = \\sum_{k=0}^{n} C_n^k a^{n-k} b^k$$\n\n**Ví dụ:** $(x + 2)^4 = C_4^0 x^4 + C_4^1 x^3 \\cdot 2 + C_4^2 x^2 \\cdot 2^2 + C_4^3 x \\cdot 2^3 + C_4^4 \\cdot 2^4$\n$= x^4 + 8x^3 + 24x^2 + 32x + 16$\n\n## Phân biệt chỉnh hợp và tổ hợp\n- **Chỉnh hợp:** Quan tâm thứ tự (Ví dụ: Chọn và xếp hạng)\n- **Tổ hợp:** Không quan tâm thứ tự (Ví dụ: Chọn thành viên nhóm)\n\n**Mối quan hệ:** $A_n^k = k! \\times C_n^k$',
]
embeddings = model.encode(sentences)
print(embeddings.shape)
# [3, 768]

# Get the similarity scores for the embeddings
similarities = model.similarity(embeddings, embeddings)
print(similarities.shape)
# [3, 3]
Evaluation
Metrics
Binary Classification
Metric Value
cosine_accuracy 0.955
cosine_accuracy_threshold 0.3744
cosine_f1 0.9302
cosine_f1_threshold 0.3454
cosine_precision 0.9677
cosine_recall 0.8955
cosine_ap 0.9841
cosine_mcc 0.8986
Training Details
Training Dataset
Unnamed Dataset
  • Size: 1,924 training samples
  • Columns: sentence_0 , sentence_1 , and sentence_2
  • Approximate statistics based on the first 1000 samples:
    sentence_0 sentence_1 sentence_2
    type string string string
    details
    • min: 10 tokens
    • mean: 24.51 tokens
    • max: 53 tokens
    • min: 228 tokens
    • mean: 254.59 tokens
    • max: 256 tokens
    • min: 228 tokens
    • mean: 254.66 tokens
    • max: 256 tokens
  • Samples:
    sentence_0 sentence_1 sentence_2
    query: Nếu biết tổng của 5 số hạng đầu và tổng của 10 số hạng đầu của một cấp số cộng, làm sao để tìm công sai? passage: # Tổng n số hạng đầu của cấp số cộng

    ## Công thức tổng
    Cho cấp số cộng $(u_n)$ với số hạng đầu $u_1$ và công sai $d$.

    Công thức 1: $S_n = \frac{n}{2}[2u_1 + (n-1)d]$

    Công thức 2: $S_n = \frac{n(u_1 + u_n)}{2}$

    Công thức 3: $S_n = nu_1 + \frac{n(n-1)}{2}d$

    ## Tính chất của tổng
    1. $S_n - S_{n-1} = u_n$ (với $n \geq 2$)

    2. Nếu $S_n = an^2 + bn$ thì dãy là CSC với:
    - $u_1 = a + b$
    - $d = 2a$

    ## Ví dụ tính toán
    Ví dụ 1: Tính tổng 15 số hạng đầu của CSC: $3, 7, 11, 15, ...$

    Lời giải:
    - $u_1 = 3$, $d = 4$
    - $S_{15} = \frac{15}{2}[2 \times 3 + (15-1) \times 4] = \frac{15}{2}[6 + 56] = 465$

    Ví dụ 2: Tìm $n$ biết tổng $n$ số hạng đầu của CSC có $u_1 = 2$, $d = 3$ là $S_n = 77$.

    Lời giải:
    $77 = \frac{n}{2}[2 \times 2 + (n-1) \times 3] = \frac{n(4 + 3n - 3)}{2} = \frac{n(3n + 1)}{2}$

    $154 = n(3n + 1) = 3n^2 + n$

    $3n^2 + n - 154 = 0$

    Giải được $n = 7$ (loại nghiệm âm)

    ## Bài toán thực tế
    Một công ty kế hoạch tăng lương cho nhân viên theo CSC...
    passage: # Bài toán tổ hợp - chỉnh hợp thực tế

    ## Dạng bài thường gặp
    1. Sắp xếp người ngồi
    2. Chọn đội tuyển, ủy ban
    3. Phân chia nhóm
    4. Xếp lịch, phân công
    5. Mật khẩu, biển số xe

    ## Ví dụ tổng hợp
    Ví dụ 1: Một bàn dài có 10 ghế. Có 6 nam và 4 nữ. Hỏi có bao nhiêu cách xếp sao cho:
    a) Các nữ ngồi cạnh nhau
    b) Nam và nữ ngồi xen kẽ

    Lời giải:
    a) Coi 4 nữ như 1 khối, ta có 7 đối tượng (6 nam + 1 khối nữ)
    - Xếp 7 đối tượng: $7!$ cách
    - Xếp 4 nữ trong khối: $4!$ cách
    - Tổng: $7! \times 4! = 120,960$ cách

    b) Vì có 6 nam và 4 nữ, xếp theo kiểu: N-Nam-N-Nam-...
    - Xếp 6 nam: $6!$ cách
    - Chọn 4 vị trí từ 7 vị trí giữa các nam: $C_7^4$ cách
    - Xếp 4 nữ vào 4 vị trí đã chọn: $4!$ cách
    - Tổng: $6! \times C_7^4 \times 4! = 1,209,600$ cách

    Ví dụ 2: Chia 12 học sinh thành 3 nhóm có 4 người mỗi nhóm.

    Lời giải:
    - Chọn 4 người cho nhóm 1: $C_{12}^4$
    - Chọn 4 người cho nhóm 2 từ 8 người còn lại: $C_8^4$
    - 4 người còn lại tự động vào nhóm 3...
    query: Công thức tính tổ hợp chập k của n phần tử là gì? passage: # Tổ hợp

    ## Định nghĩa
    Tổ hợp chập $k$ của $n$ phần tử là cách chọn $k$ phần tử từ $n$ phần tử mà không quan tâm đến thứ tự.

    Ký hiệu: $C_n^k$ hoặc $\binom{n}{k}$

    Điều kiện: $0 \leq k \leq n$

    ## Công thức
    $$C_n^k = \frac{A_n^k}{k!} = \frac{n!}{k!(n-k)!}$$

    Công thức Pascal: $C_n^k = C_{n-1}^{k-1} + C_{n-1}^k$

    ## Tính chất cơ bản
    1. $C_n^0 = C_n^n = 1$
    2. $C_n^k = C_n^{n-k}$
    3. $C_n^1 = n$
    4. $C_n^2 = \frac{n(n-1)}{2}$

    ## Ví dụ tính toán
    Ví dụ 1: Từ 10 học sinh, chọn 3 học sinh tham gia đội tuyển. Có bao nhiêu cách?

    Lời giải: $C_{10}^3 = \frac{10!}{3! \times 7!} = \frac{10 \times 9 \times 8}{3 \times 2 \times 1} = 120$ cách.

    Ví dụ 2: Trong một lớp có 15 nam và 10 nữ. Chọn 5 người sao cho có đúng 3 nam và 2 nữ.

    Lời giải:
    - Chọn 3 nam từ 15 nam: $C_{15}^3 = 455$ cách
    - Chọn 2 nữ từ 10 nữ: $C_{10}^2 = 45$ cách
    - Tổng cộng: $455 \times 45 = 20,475$ cách

    ## Nhị thức Newton
    $$(a + b)^n = \sum_{k=0}^{n} C_n^k a^{n-k} b^k$$

    Ví dụ: $(x + 2)...
    passage: # Công thức tọa độ cơ bản trong không gian

    ## Độ dài vectơ và khoảng cách
    Độ dài vectơ: $
    query: Ngoài tối ưu lợi nhuận, còn những dạng bài tối ưu kinh tế nào khác? passage: # Bài toán tối ưu kinh tế

    ## Các khái niệm cơ bản
    - Doanh thu: $R(x) = p \cdot x$ (giá × số lượng)
    - Chi phí: $C(x) = $ chi phí cố định + chi phí biến đổi
    - Lợi nhuận: $P(x) = R(x) - C(x)$

    ## Ví dụ: Tối ưu lợi nhuận
    Một công ty sản xuất $x$ sản phẩm/ngày với:
    - Chi phí: $C(x) = x^2 + 40x + 400$ (nghìn đồng)
    - Giá bán: 200 nghìn đồng/sản phẩm

    Tìm mức sản xuất để lợi nhuận tối đa.

    Lời giải:
    Doanh thu: $R(x) = 200x$
    Lợi nhuận: $P(x) = 200x - (x^2 + 40x + 400) = -x^2 + 160x - 400$

    $P'(x) = -2x + 160 = 0 \Rightarrow x = 80$
    $P''(x) = -2 < 0$ nên $x = 80$ cho cực đại.

    Lợi nhuận tối đa: $P(80) = -6400 + 12800 - 400 = 6000$ nghìn đồng.

    Kết luận: Sản xuất 80 sản phẩm/ngày để đạt lợi nhuận tối đa 6 triệu đồng.

    ## Dạng bài khác
    - Tối ưu giá bán khi có mối quan hệ giữa giá và lượng tiêu thụ
    - Tối ưu chi phí vận chuyển, sản xuất
    - Tối ưu thời gian với chi phí nhân công
    passage: # Tính toán tứ phân vị - Ví dụ thực hành

    ## Ví dụ với dữ liệu rời rạc
    Điểm thi của 10 học sinh: 5, 6, 7, 7, 8, 8, 8, 9, 9, 10

    Tìm vị trí:
    - $Q_1$: vị trí $\frac{10}{4} = 2.5$ → trung bình của số thứ 2 và 3
    - $Q_2$: vị trí $\frac{10}{2} = 5$ → trung bình của số thứ 5 và 6
    - $Q_3$: vị trí $\frac{3 \times 10}{4} = 7.5$ → trung bình của số thứ 7 và 8

    Kết quả:
    - $Q_1 = \frac{6 + 7}{2} = 6.5$
    - $Q_2 = \frac{8 + 8}{2} = 8$
    - $Q_3 = \frac{8 + 9}{2} = 8.5$
    - $IQR = 8.5 - 6.5 = 2$

    ## Ví dụ với dữ liệu ghép nhóm
    Cân nặng 100 học sinh:

  • Loss: MultipleNegativesRankingLoss with these parameters:
    {
        "scale": 20.0,
        "similarity_fct": "cos_sim"
    }
    
Training Hyperparameters
Non-Default Hyperparameters
  • eval_strategy : steps
  • per_device_train_batch_size : 4
  • per_device_eval_batch_size : 4
  • num_train_epochs : 20
  • multi_dataset_batch_sampler : round_robin
All Hyperparameters
Click to expand
  • overwrite_output_dir : False
  • do_predict : False
  • eval_strategy : steps
  • prediction_loss_only : True
  • per_device_train_batch_size : 4
  • per_device_eval_batch_size : 4
  • 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 : 20
  • 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 : False
  • 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 : {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
  • tp_size : 0
  • fsdp_transformer_layer_cls_to_wrap : None
  • accelerator_config : {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
  • deepspeed : None
  • label_smoothing_factor : 0.0
  • optim : adamw_torch
  • 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
  • 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
  • eval_use_gather_object : False
  • average_tokens_across_devices : False
  • prompts : None
  • batch_sampler : batch_sampler
  • multi_dataset_batch_sampler : round_robin
Training Logs
Epoch Step Training Loss ranking_evaluator_cosine_ap
0.8299 200 - 0.9696
1.0 241 - 0.9698
1.6598 400 - 0.9648
2.0 482 - 0.9776
2.0747 500 0.723 -
2.4896 600 - 0.9716
3.0 723 - 0.9716
3.3195 800 - 0.9753
4.0 964 - 0.9770
4.1494 1000 0.449 0.9773
4.9793 1200 - 0.9721
5.0 1205 - 0.9697
5.8091 1400 - 0.9756
6.0 1446 - 0.9805
6.2241 1500 0.3991 -
6.6390 1600 - 0.9756
7.0 1687 - 0.9767
7.4689 1800 - 0.9717
8.0 1928 - 0.9682
8.2988 2000 0.374 0.9748
9.0 2169 - 0.9771
9.1286 2200 - 0.9834
9.9585 2400 - 0.9769
10.0 2410 - 0.9767
10.3734 2500 0.3678 -
10.7884 2600 - 0.9797
11.0 2651 - 0.9799
11.6183 2800 - 0.9799
12.0 2892 - 0.9740
12.4481 3000 0.3711 0.9809
13.0 3133 - 0.9795
13.2780 3200 - 0.9825
14.0 3374 - 0.9841
Framework Versions
  • Python: 3.11.11
  • Sentence Transformers: 3.4.1
  • Transformers: 4.51.3
  • PyTorch: 2.6.0+cu124
  • Accelerate: 1.5.2
  • Datasets: 3.6.0
  • Tokenizers: 0.21.1
Citation
BibTeX
Sentence Transformers
@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
@misc{henderson2017efficient,
    title={Efficient Natural Language Response Suggestion for Smart Reply},
    author={Matthew Henderson and Rami Al-Rfou and Brian Strope and Yun-hsuan Sung and Laszlo Lukacs and Ruiqi Guo and Sanjiv Kumar and Balint Miklos and Ray Kurzweil},
    year={2017},
    eprint={1705.00652},
    archivePrefix={arXiv},
    primaryClass={cs.CL}
}

Runs of ThanhLe0125 e5-math-ebd-01 on huggingface.co

12
Total runs
1
24-hour runs
1
3-day runs
-2
7-day runs
-1
30-day runs

More Information About e5-math-ebd-01 huggingface.co Model

e5-math-ebd-01 huggingface.co

e5-math-ebd-01 huggingface.co is an AI model on huggingface.co that provides e5-math-ebd-01's model effect (), which can be used instantly with this ThanhLe0125 e5-math-ebd-01 model. huggingface.co supports a free trial of the e5-math-ebd-01 model, and also provides paid use of the e5-math-ebd-01. Support call e5-math-ebd-01 model through api, including Node.js, Python, http.

ThanhLe0125 e5-math-ebd-01 online free

e5-math-ebd-01 huggingface.co is an online trial and call api platform, which integrates e5-math-ebd-01's modeling effects, including api services, and provides a free online trial of e5-math-ebd-01, you can try e5-math-ebd-01 online for free by clicking the link below.

ThanhLe0125 e5-math-ebd-01 online free url in huggingface.co:

https://huggingface.co/ThanhLe0125/e5-math-ebd-01

e5-math-ebd-01 install

e5-math-ebd-01 is an open source model from GitHub that offers a free installation service, and any user can find e5-math-ebd-01 on GitHub to install. At the same time, huggingface.co provides the effect of e5-math-ebd-01 install, users can directly use e5-math-ebd-01 installed effect in huggingface.co for debugging and trial. It also supports api for free installation.

e5-math-ebd-01 install url in huggingface.co:

https://huggingface.co/ThanhLe0125/e5-math-ebd-01

Url of e5-math-ebd-01

e5-math-ebd-01 huggingface.co Url

Provider of e5-math-ebd-01 huggingface.co

ThanhLe0125
ORGANIZATIONS

Other API from ThanhLe0125

huggingface.co

Total runs: 3
Run Growth: 3
Growth Rate: 100.00%
Updated:December 20 2024
huggingface.co

Total runs: 0
Run Growth: 0
Growth Rate: 0.00%
Updated:December 27 2024
huggingface.co

Total runs: 0
Run Growth: -2
Growth Rate: 0.00%
Updated:December 19 2024