Views
No views yet

1from transformers import AutoModel, AutoTokenizer
2
3model = AutoModel.from_pretrained("AnnaStudy/ReaKase-8B", torch_dtype="auto", device_map="auto")
4tokenizer = AutoTokenizer.from_pretrained("AnnaStudy/ReaKase-8B")
5
6case_txt = "The following contains key components of a legal case. Legal facts..."
7
8tokenized = tokenizer(case_txt, return_tensors='pt', padding=True, truncation=True, max_length=2048)
9outputs = model(**tokenized)
10case_embedding = outputs.last_hidden_state[:, -1]@article
{ReaKase-8B,
author = {Yanran Tang, Ruihong Qiu, Xue Li, Zi Huang},
title = {ReaKase-8B: Legal Case Retrieval via Knowledge and Reasoning Representations with LLMs},
journal = {CoRR},
volume = {abs/2510.26178},
year = {2025}
}