Views
No views yet
query: <original_question> [SEP] <agent_query>.
Passages use the standard passage: prefix following E5.1from sentence_transformers import SentenceTransformer
2
3model = SentenceTransformer("liuwenhan/Agentic-R_e5")
4
5input_texts = [
6 # Query encoder input:
7 # original_question [SEP] current_query
8 "query: Who wrote The Old Man and the Sea? [SEP] Old Man and the Sea",
9
10 # Passages
11 "passage: The Old Man and the Sea is a short novel written by the American author Ernest Hemingway in 1951.",
12 "passage: Ernest Hemingway was an American novelist, short-story writer, and journalist, born in 1899."
13]
14
15embeddings = model.encode(
16 input_texts,
17 normalize_embeddings=True
18)original_question refers to the user’s initial question.agent_query refers to the intermediate query generated during the agent’s reasoning process.[SEP] to separate the two parts of the query.normalize_embeddings=True for cosine similarity–based retrieval.