bge base en v1.5 course recommender v5

Providerdatasocietyco
Categorysentence-similarity
LicenseApache-2.0
Downloads3.7M
Stars0

Overview

The bge-base-en-v1.5-course-recommender-v5 is a specialized sentence-similarity model fine-tuned for educational content mapping. Built on the BGE (Baaiv General Embedding) architecture, it converts course descriptions and learner queries into dense vectors to facilitate high-precision semantic search. Unlike general-purpose embedding models, this version is optimized for the nuances of academic and professional training taxonomies, making it ideal for building course recommendation engines or automated curriculum mapping tools. It integrates seamlessly into any RAG (Retrieval-Augmented Generation) pipeline via standard embedding libraries, providing a lightweight yet performant alternative for developers needing domain-specific retrieval without the overhead of massive LLMs.

Highlights

  • Optimized for educational content and course semantic similarity
  • Apache-2.0 licensed for flexible commercial integration
  • High-efficiency dense vector embeddings for fast retrieval
  • Ideal for RAG pipelines and academic recommendation systems

Usage

Install
# Install Hugging Face transformers
pip install transformers torch
SDK Usage
# Load model with transformers
from transformers import AutoModel, AutoTokenizer

model = AutoModel.from_pretrained("datasocietyco/bge-base-en-v1.5-course-recommender-v5")
tokenizer = AutoTokenizer.from_pretrained("datasocietyco/bge-base-en-v1.5-course-recommender-v5")

Hugging Face Download

We recommend downloading the model via the Hugging Face CLI or Hub SDK.

Guidance:Before downloading, install huggingface_hub with:

Guidance
pip install -U huggingface_hub

CLI Download

Download the full repository

Download the full repository
huggingface-cli download datasocietyco/bge-base-en-v1.5-course-recommender-v5

Download a single file to a local folder (e.g. config.json into ./dir)

Download a single file to a local folder (e.g. config.json into ./dir)
huggingface-cli download datasocietyco/bge-base-en-v1.5-course-recommender-v5 config.json --local-dir ./dir

See the official docs for more CLI options

SDK Download

SDK Download
# 模型下载
from huggingface_hub import snapshot_download
model_dir = snapshot_download('datasocietyco/bge-base-en-v1.5-course-recommender-v5')

Git Download

Make sure git-lfs is installed first

Git Download
git lfs install
git clone https://huggingface.co/datasocietyco/bge-base-en-v1.5-course-recommender-v5

To skip LFS large-file downloads, use:

Skip LFS
GIT_LFS_SKIP_SMUDGE=1 git clone https://huggingface.co/datasocietyco/bge-base-en-v1.5-course-recommender-v5

Model files are hosted on the Hugging Face Hub — download directly via HF CLI / SDK / Git, not through this site.

PyTorch / Transformers Usage

Install Transformers

Install Transformers
pip install -U transformers torch

Load the model and run inference

Load the model and run inference
from transformers import AutoModelForCausalLM, AutoTokenizer

model = AutoModelForCausalLM.from_pretrained('datasocietyco/bge-base-en-v1.5-course-recommender-v5')
tokenizer = AutoTokenizer.from_pretrained('datasocietyco/bge-base-en-v1.5-course-recommender-v5')

Full Documentation

来源: HuggingFace

---
tags:

  • sentence-transformers

  • sentence-similarity

  • feature-extraction

  • generated_from_trainer

  • dataset_size:45

  • loss:MultipleNegativesRankingLoss

base_model: BAAI/bge-base-en-v1.5
pipeline_tag: sentence-similarity
library_name: sentence-transformers
---

SentenceTransformer based on BAAI/bge-base-en-v1.5

This is a sentence-transformers model finetuned from BAAI/bge-base-en-v1.5. 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
  • Maximum Sequence Length: 512 tokens
  • Output Dimensionality: 768 tokens
  • Similarity Function: Cosine Similarity
<!-- - Training Dataset: Unknown --> <!-- - Language: Unknown --> <!-- - License: Unknown -->

Model Sources

Full Model Architecture

code
SentenceTransformer(
  (0): Transformer({'max_seq_length': 512, 'do_lower_case': True}) with Transformer model: BertModel 
  (1): Pooling({'word_embedding_dimension': 768, 'pooling_mode_cls_token': True, 'pooling_mode_mean_tokens': False, '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:

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("datasocietyco/bge-base-en-v1.5-course-recommender-v5")

Run inference

sentences = [ 'The weather is lovely today.', "It's so sunny outside!", 'He drove to the stadium.', ] 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]

<!--

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.*
-->

<!--

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: 45 training samples
  • Columns: <code>anchor</code> and <code>positive</code>
  • Approximate statistics based on the first 45 samples:
| | anchor | positive | |:--------|:--------------------------------------------------------------------------------------|:--------------------------------------------------------------------------------------| | type | string | string | | details | <ul><li>min: 143 tokens</li><li>mean: 178.76 tokens</li><li>max: 258 tokens</li></ul> | <ul><li>min: 141 tokens</li><li>mean: 176.76 tokens</li><li>max: 256 tokens</li></ul> |
  • Samples:
| anchor | positive | |:-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Join our Telegram