Live data from Hacker News

Which table format do LLMs understand best?

improvingagents.com

11–20 of 115 posts

Re: Which table format do LLMs understand best?

#12
post #10

I wonder how this compares to a more agentic approach where the LLM composes SQL queries to answer the questions, for example.

This was exactly my thought. Rather than feed the table directly to the LLM, build agents that extract the data and have the LLM act on the extracted data items. Then it’s a preference issue.

The author didn’t see much more than 60% accuracy which is not very useful for many (most?) real world tasks.

Re: Which table format do LLMs understand best?

#13

I am not an expert on the subject but i suggest that you can also save context space by using shorter XML element names (like f instead of function, c instead of class, etc.). Just add a legend at the top or bottom to explain what each abbreviation means, LLMs can figure out the mapping without issues. I use this approach when generating project structure maps with Tree-sitter. I did a quick comparison and didn't not…

if both f and function uses 1 token, are you really saving anything?

Re: Which table format do LLMs understand best?

#16
post #5

> where accuracy is paramount > accuracy: 60% Not to mention that the least poorly performing format is probably the stupidest way to encode tabular data, beating even XML. But I guess that’s the new normal because we’re trying to shoehorn conversational AI models to every use case rather than, say, training finetunes that are better at particular tasks. (Yes, of course you can’t train finetunes when the model is a p…

they used GPT-4.1 nano, results would be quite different with sonnet or gpt5.

Re: Which table format do LLMs understand best?

#18

This is an interesting theoretical exercise but please for the love of god don't actually use an LLM to search tabular data. This is a solved problem. Free software does this with 100% accuracy and insane efficiency.

This is a really eye-popping example. Because here we have input text that is fully structured perfectly unambiguous (it was carefully designed that way!) and yet the LLM can't get all the information out of it. Yet people are using these tools to summarize unstructured text, assuming the summary will capture the most salient points. Well how is the LLM supposed to be good for that task, if it can't even summarize the dang XML document? They keep telling me this thing is more expert than all the experts combined.

Re: Which table format do LLMs understand best?

#19
post #10

I wonder how this compares to a more agentic approach where the LLM composes SQL queries to answer the questions, for example.

Yeah I mean for many real world scale datasets you don’t want to blow the whole context window on a massive markdown file. Instead you can provide a tool that presents the data as a SQLite database. In my testing Claude code seems very capable of answering questions via SQLite queries or even `head` and `grep` on CSV files.
Post reply on HN