TRU4Zero is a powerful framework for zero-shot table reasoning using Large Language Model (LLM) agents. It unifies multiple table reasoning tasks including table question answering, fact verification, and table-to-text generation into a single framework.
- Zero-Shot Learning: No label required!
- Unified Framework: Handles multiple table reasoning tasks
- LLM Agent Integration: Leverages powerful language models for reasoning
- Parallel Processing: Efficient batch processing with parallel inference
- Create and activate conda environment:
conda create -n tru4zero python=3.10
conda activate tru4zero
- Install dependencies:
cd tru4zero
pip install -r requirements.txt
python -m spacy download en-core-web-sm
cd tru4zero/feverous && python3 -m pip install -e .
You need to set your OpenAI API key in the .env
file. Additionally, as for our single agent and multi-agent settings, you can customize client
, MODEL
, REFLECTION_TURNS
, and TEMPERATURE
in tru4zero_module/config/tru4zero_global_config.py
.
The framework supports three main tasks:
- Table Question Answering
- Fact Verification
- Query-to-SQL Generation
For detailed usage instructions and examples, please refer to the README in each task's directory:
- WikiSQL: See wikisql/README.md
- TAT-QA: See tat-qa/README.md
- FEVEROUS: See feverous/README.md
- SEM-TAB-FACTS: See sem-tab-facts/README.md
If you use TRU4Zero in your research, please cite our work:
# Note that this is a toy version:
@article{tru4zero2024,
title={TRU4Zero: Unravel, Uncover, Unite! On Unified Zero-Shot Table Reasoning with LLM Agents},
author={Yiran Rex Ma},
year={2024}
}
For any questions or feedback, please feel free to open an issue or contact me at [email protected].