Update README.md
Browse files
README.md
CHANGED
|
@@ -1,3 +1,45 @@
|
|
| 1 |
-
---
|
| 2 |
-
license: cc-by-nc-4.0
|
| 3 |
-
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: cc-by-nc-4.0
|
| 3 |
+
---
|
| 4 |
+
|
| 5 |
+
|
| 6 |
+
# CPRetriever-Prob
|
| 7 |
+
|
| 8 |
+
**CPRetriever-Prob** is a sentence embedding model trained for competitive programming problem retrieval.
|
| 9 |
+
|
| 10 |
+
This model can be directly used via the `sentence-transformers` library.
|
| 11 |
+
|
| 12 |
+
Visit https://cpret.online/ to try out **CPRet** in action for competitive programming problem retrieval — powered by the **CPRetriever-Prob** model.
|
| 13 |
+
|
| 14 |
+
## 🔧 Usage
|
| 15 |
+
|
| 16 |
+
```python
|
| 17 |
+
from sentence_transformers import SentenceTransformer
|
| 18 |
+
|
| 19 |
+
model = SentenceTransformer("coldchair16/CPRetriever-Prob-Qwen3-4B-2510")
|
| 20 |
+
embeddings = model.encode([
|
| 21 |
+
"Given a sequence of n numbers, answer m range mex queries.",
|
| 22 |
+
"求一个长度为 n 的数列的区间 mex。"
|
| 23 |
+
])
|
| 24 |
+
```
|
| 25 |
+
|
| 26 |
+
## 💡 Applications
|
| 27 |
+
|
| 28 |
+
This model powers the retrieval demo in [CPRet](https://github.com/coldchair/CPRet), supporting several practical use cases:
|
| 29 |
+
|
| 30 |
+
* It can assist in **duplicate problem detection** by retrieving potentially similar problems — final identification still requires manual verification.
|
| 31 |
+
* It also supports **similar problem retrieval** to help broaden your problem-solving perspective.
|
| 32 |
+
* You can input either a **full problem description** or a **simplified version**, and the system will return the most relevant existing problems.
|
| 33 |
+
|
| 34 |
+
## 📚 Training and Evaluation
|
| 35 |
+
|
| 36 |
+
For training pipeline, evaluation benchmark, and retrieval demo, please refer to the full codebase:
|
| 37 |
+
👉 [CPRet on GitHub](https://github.com/coldchair/CPRet?tab=readme-ov-file)
|
| 38 |
+
|
| 39 |
+
## 📦 Model Card
|
| 40 |
+
|
| 41 |
+
* Architecture: `Qwen/Qwen3-Embedding-4B` (encoder backbone)
|
| 42 |
+
* Tasks: Contrastive pretraining + task-specific fine-tuning on programming problem pairs
|
| 43 |
+
* Format: Compatible with `sentence-transformers`
|
| 44 |
+
|
| 45 |
+
|