Views
No views yet
| Question | Example Answer |
|---|---|
| According to the table, what is the last title produced? | Specific Title |
| What is the difference in a specific comparative metric? | Numerical Difference |
| Which entity had the most significant impact in a given context? | Identified Entity |
| What were the first and last entries in a specific column? | Comparative Entries |
1from transformers import TessarTokenizer, BartForConditionalGeneration
2import pandas as pd
3
4# Load Tessar model and tokenizer
5tokenizer = TessarTokenizer.from_pretrained("SVECTOR-CORPORATION/Tessar-largest")
6model = BartForConditionalGeneration.from_pretrained("SVECTOR-CORPORATION/Tessar-largest")
7
8# Prepare sample table data
9data = {
10 "year": [1896, 1900, 1904, 2004, 2008, 2012],
11 "city": ["athens", "paris", "st. louis", "athens", "beijing", "london"]
12}
13table = pd.DataFrame.from_dict(data)
14
15# Ask a specific query
16query = "In which year did beijing host the Olympic Games?"
17encoding = tokenizer(table=table, query=query, return_tensors="pt")
18
19# Generate answer
20outputs = model.generate(**encoding)
21
22# Decode and print result
23print(tokenizer.batch_decode(outputs, skip_special_tokens=True))
24# Expected output: [' 2008.0']1@inproceedings{svector2025tessar,
2 title={{Tessar}: Advanced Neural Table Reasoning},
3 author={{SVECTOR Team}},
4 year={2025},
5 institution={SVECTOR Research}
6}