Sentence Similarity
sentence-transformers
Safetensors
gemma3_text
feature-extraction
dense
Generated from Trainer
dataset_size:43
loss:MultipleNegativesRankingLoss
embeddinggemma-tuning-lab
text-embeddings-inference
Instructions to use AlekseyCalvin/LyricalEmbeddingGemma_v1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use AlekseyCalvin/LyricalEmbeddingGemma_v1 with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("AlekseyCalvin/LyricalEmbeddingGemma_v1") sentences = [ "(Название:) ДО НОВОЙ ЗАРИ \n(Поэт:) Владимир Силлов \n\nДни \nПо жуткой нехоженой лестнице \nЗашагают быстрей. \nДеревья скоро разлистятся, \nНо станет ясней, \n\nВеснам, \nОбглоданным поэтами, \nПришел конец. \nИ солнцу с черными отметами \nКонец — венец. \n\nИ мы солнце и весны \nПотащим на рынок. \nПотащим чрез гвалты и давку \nИ бросим за тусклый полтинник \nК антиквару в лавку. \n\nВ душах оплеванных, \nНаглых и сильных, \nЕсть алтари. \nИ на них мы затеплим лампады к вечерне \nДо новой зари.", "(Title:) UNTIL IT DAWNS ANEW \n(Poet:) Vladimir SIllov \n\nDays \nWould walk an untrod morbid staircase \nAt accelerant pace. \nSoon trees splinter in leaflessness, \nAll the clearer it makes, \n\nSpringtimes \nThe poets still nibble on \nGet abruptly pulled down. \nWith the sun, a blotched face nothing beams upon, \nThey come down – are crowned. \n\nAnd this sun with springs \nTo market we’ll bring, \nHoist them over tussle and din, \nAnd for five faded roubles toss them \nTo some antiquarian. \n\nSouls spat on, slandered, \nInsolent, headstrong, \nAltars strew. \nOn them we'll light lamps for vesper nights, \nUntil it dawns anew.", "(Title:) BEFORE A FRESH DAWN \n(Poet:) Vladimir SIlloff \n\nDaytimes \nOn the eerie, untrodden stairs \nWill stomp faster. \nThe trees will soon blossom, \nBut it will become clearer, \n\nThat spring, \nGnawed away by poets, \nHas come to an end. \nAnd the sun with black marks \nIs the end — the crown. \n\nAnd we will lug the sun and spring \nTo the store. \nWe will lug them through the noise and crush \nAnd throw them for a dull fifty kopecks \nTo the antique dealer's shop. \n\nIn souls spat upon, \nArrogant and strong, \nThere rooms with altars. \nAnd on them we will light lamps for vespers \nUntil a new dawn.", "(Title:) THE WAYWARD STREETCAR (Stanzas 9-12) \n(Poet:) Nikolay Gumilev \n\nAnd in an alley with wooden-planked fencing, \nI see that house with three windows, gray lawns… \nStreetcar conductor, oh, why don't you stop here; \nHey, stop it now! Why, I have to get off! \n\nMasha, my darling, you lived and you sang here, \nWeaving a rug for the groom, for me; \nWhere is your voice now and where is your body? \nIt cannot be that you died, cannot be?! \n\nBut you were coughing, collapsed by the entrance, \nWhile, with a braid over-powdered and plumed, \nI went to get introduced to the Empress, \nSo that I never again met with you. \n\nI understand now: that all of our freedoms, \nOnly from there, are a light beating through; \nPeople and shades are amassed by the entrance \nInto a garden of planets, a zoo." ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4] - Notebooks
- Google Colab
- Kaggle
Welcome to the community
The community tab is the place to discuss and collaborate with the HF community!