prithivida

24 models • 1 total models in database
Sort by:

parrot_paraphraser_on_T5

Parrot is a paraphrase based utterance augmentation framework purpose built to accelerate training NLU models. A paraphrase framework is more than just a paraphrasing model. For more details on th...

129,542
159

grammar_error_correcter_v1

This model is part of the Gramformer library please refer to https://github.com/PrithivirajDamodaran/Gramformer/

50,971
40

Splade_PP_en_v1

license:apache-2.0
16,197
29

parrot_adequacy_model

license:apache-2.0
7,473
7

parrot_fluency_model

license:apache-2.0
3,721
1

Splade PP En V2

Independent Implementation of SPLADE++ Model (`a.k.a splade-cocondenser and family`) for the Industry setting. -------------- This work stands on the shoulders of 2 robust researches: Naver's From Distillation to Hard Negative Sampling: Making Sparse Neural IR Models More Effective paper and Google's SparseEmbed. Props to both the teams for such a robust work. This is a 2nd iteration in this series. Try V1 here: prithivida/SpladePPenv1 1. What are Sparse Representations and Why learn one? Beginner ? expand this. Expert in Sparse & Dense representations ? feel free skip to next section 2, Lexical search with BOW based sparse vectors are strong baselines, but they famously suffer from vocabulary mismatch problem, as they can only do exact term matching. Here are the pros and cons: - ✅ Efficient and Cheap. - ✅ No need to fine-tune models. - ✅️ Interpretable. - ✅️ Exact Term Matches. - ❌ Vocabulary mismatch (Need to remember exact terms) Learned Neural / Dense retrievers (DPR, Sentence transformers, BGE models) with approximate nearest neighbors search has shown impressive results. Here are the pros and cons: - ✅ Search how humans innately think. - ✅ When finetuned beats sparse by long way. - ✅ Easily works with Multiple modals. - ❌ Suffers token amnesia (misses term matching), - ❌ Resource intensive (both index & retreival), - ❌ Famously hard to interpret. - ❌ Needs fine-tuning for OOD data. Getting pros of both searches made sense and that gave rise to interest in learning sparse representations for queries and documents with some interpretability. The sparse representations also double as implicit or explicit (latent, contextualized) expansion mechanisms for both query and documents. If you are new to query expansion learn more here from the master himself Daniel Tunkelang. The model learns to project it's learned dense representations over a MLM head to give a vocabulary distribution. Which is just to say the model can do automatic token expansion. (Image courtesy of pinecone) Skip to "HOW TO USE with POPULAR VECTORDBs and more" or continue for more details. 2. Motivation: SPLADE models are a fine balance between retrieval effectiveness (quality) and retrieval efficiency (latency and $), with that in mind we did very minor retrieval efficiency tweaks to make it more suitable for a industry setting. (Pure MLE folks should not conflate efficiency to model inference efficiency. Our main focus is on retrieval efficiency. Hereinafter efficiency is a short hand for retrieval efficiency unless explicitly qualified otherwise. Not that inference efficiency is not important, we will address that subsequently.) TL;DR of Our attempt & results 1. FLOPS tuning: Seperate Seq lens and Severely restrictive FLOPs schedule and token budget doc(128) & query(24) NOT 256 unlike Official SPLADE++. Inspired from SparseEmbed 3. Init Weights: Middle Trained bert-base-uncased with MLM Loss. Some corpus awarness like Official splade++ / ColBERT 4. Yet achieves competitive effectiveness of MRR@10 37.8 in ID data (& OOD 49.4) and a retrieval latency of - 48.81ms. (multi-threaded) all On Consumer grade-GPUs with only 5 negatives per query. 4. For Industry setting: Effectiveness on custom domains needs more than just Trading FLOPS for tiny gains and The Premise "SPLADE++ are not well suited to mono-cpu retrieval" does not hold. 5. Owing to query-time inference latency we still need 2 models one for query & doc, This is a Doc model and Query model will be released soon. Note: The paper refers to the best performing models as SPLADE++, hence for consistency we are reusing the same. 3. Why FLOPS is one of the key metrics for industry setting ? While ONLY a empirical analysis on large sample make sense here is a spot checking - a qualitatively example to give you an idea. Our models achieve par competitive effectiveness with ~4% and ~48%, lesser tokens comparable SPLADE++ models including SoTA. (We will show Quantitative results in the next section.) So, by design "how to beat SoTA MRR?" was never our goal, Instead "At what cost can we achieve an acceptable effectiveness i.e. MRR@10". Non-chalantly reducing lambda values (λQ,λD, see above table) will achieve a better MRR. But Lower lambda values = Higher FLOPS = More tokens = Poorer efficiency. This is NOT desirable for a Industry setting. naver/splade-cocondenser-ensembledistil (SoTA, ~4% more tokens + FLOPS = 1.85) naver/splade-v2-distil (~48% more tokens + FLOPS = 3.82) - Note 1: This specific passage was used as an example for ease of comparison Our models are token sparse and yet effective. It translates to faster retrieval (User experience) and smaller index size ($). Mean retrieval time on the standard MS-MARCO small dev set and Scaled total FLOPS loss are the respective metrics are below. This is why Google's SparseEmbed is interesting as they also achieve SPLADE quality retrieval effectiveness with much lower FLOPs. Compared to ColBERT, SPLADE and SparseEmbed match query and document terms with a linear complexity as ColBERT’s late interaction i.e. all query-document term pairs takes a quadratic complexity. The Challenge with SparseEmbed is it uses a hyperparameter called Top-k to restrict number of tokens used to learn contextual dense representations. Say 64 and 256 tokens for query and passage encoding. But it is unclear how well these hyperparameters are transferable to other domains or languages (where the notion of tokens changes a lot like our mother tongue Tamil which is Agglutinative in nature). Note: Why Anserini not PISA? Anserini is a production ready lucene based library. Common industry search deployments use Solr or elastic which are lucene based, hence the performance can be comparable. PISA latency is irrelevant for industry as it is a a research only system. The full [anserini evaluation log will be updated soon]() with encoding, indexing and querying details are here. - BEIR ZST OOD performance: Will be added to the end of page. Our model is different in few more aspects - Cocondenser Weights: Unlike the best Official SPLADE++ or SparseEmbed we do NOT initialse weights from Luyu/co-condenser models. Yet we achieve CoCondenser SPLADE level performance. More on this later. - Same size models: Official SPLADE++, SparseEmbed and Ours all finetune on the same size based model. Size of `bert-base-uncased`. 5. Roadmap and future directions for Industry Suitability. - Improve efficiency: This is a bottomless pit, Will continue to improve serving and retrieval efficiency. - Custom/Domain Finetuning: OOD Zeroshot performance of SPLADE models is great but unimportant in the industry setting as we need the ability to finetune on custom datasets or domains. Finetuning SPLADE on a new dataset is not cheap and needs labelling of queries and passages. So we will continue to see how we can enable economically finetuning our recipe on custom datasets without expensive labelling. - Multilingual SPLADE: Training cost of SPLADE i.e (GPU budget) directly proportional to Vocab size of the base model, So Mulitlingual SPLADE either using mbert or XLMR can be expensive as they have 120K and 250K vocab as opposed to 30K as in bert-base-uncased. We will continue to research to see how best we can extend our recipe to the multilingual world. To enable a light weight inference solution without heavy No Torch dependency we will also release a library - SPLADERunner Ofcourse if it doesnt matter you could always use these models with Huggingface transformers library. | VectorDB | Colab Link | |----------|------------| | Pinecone | [](https://colab.research.google.com/drive/1fB6LheD9wYG0G-nBHiz0z2juvljrsBum?usp=sharing) | | Qdrant | TBD | Integrating in your code ? How to use HF tokens in code Make these changes - Thanks to Nils Reimers for all the inputs. - Thanks to authors of the Anserini library. All limitations and biases of the BERT model applies to finetuning effort. Please cite if you use our models or libraries. Citation info below.

license:apache-2.0
734
29

Asimov-7B-v1

NaNK
license:mit
586
1

Asimov-7B-v2

NaNK
license:mit
584
0

informal_to_formal_styletransfer

160
8

miniReranker_arabic_v1

license:apache-2.0
160
4

all-MiniLM-L6-v2-gguf

license:apache-2.0
141
0

bge-base-en-v1.5-gguf

NaNK
license:mit
121
1

bert-for-patents-64d

license:apache-2.0
55
8

UAE-Large-V1-gguf

NaNK
license:mit
37
3

formal_to_informal_styletransfer

34
5

passive_to_active_styletransfer

23
5

active_to_passive_styletransfer

23
4

miniDense_arabic_v1

license:apache-2.0
16
7

miniDense_hindi_v1

license:cc-by-nc-nd-4.0
13
4

flashrank

license:cc-by-sa-4.0
10
5

miniDense_chinese_v1

license:cc-by-nc-nd-4.0
4
4

modern_colbert_base_en_v1

license:apache-2.0
3
4

ALT_CTRLSum

1
1

miniDense_telugu_v1

license:cc-by-nc-nd-4.0
0
2