How to use Vinsuka/legora_model with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("Vinsuka/legora_model") sentences = [ "What is the duration of the period mentioned in the text?", ". The only excep Ɵon to the requirement that the plainƟff must be a lending i nsƟtuƟon in order to invoke the provisions of the Act is contained in SecƟon 25, in terms of which a person who inter alia knowingly draws a cheque which is subsequently dishonoured by the bank for want of funds is guilty of an offence under the Act, and proceedings can be insƟtuted against such person in the Magistrate’s", "? The 1st question of law is formulated on the basis that , the 1st Defendant is the licensee of the 2nd Defendant and therefore, the 1st Defendant cannot claim prescriptive title to the subject matter", ".50,000/ - (that is , a period of 36 months) but such “Facility” is subject to review on 30 /09/2000”, (that is, a period of about only 5 months from the date of P4)" ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4]
How to fix it?