{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/arxiv-2606-18986","title":"Beyond Tokenization: Direct Timestep Embedding and Contrastive Alignment for Time-Series Question Answering","arxiv_id":"2606.18986","date":"2026-06-17","proceeding":null,"authors":["Yafeng Wu","Huu Hiep Nguyen","Thin Nguyen","Hung Le"],"abstract":"Recent advances in large language models (LLMs) have given rise to time-series question answering (TSQA), which formulates time-series analysis as natural-language question answering. However, directly feeding raw numerical series into LLMs suffers from a tokenization bottleneck: Byte Pair Encoding fragments continuous values into unstable tokens whose embeddings lack meaningful metric structure, resulting in the loss of magnitude, scale, and trend information. Prior methods use patch-based encoders that split the series into fixed windows, locking in one granularity that breaks patterns and hides exact timesteps, through a separate module that rarely transfers across datasets with different lengths or sampling rates. To address this challenge, we propose CADE (Contrastive Alignment with Direct Embedding), a novel framework for TSQA built upon two key components: direct timestep embedding and semantic alignment. The proposed framework maps each timestep directly into the LLM embedding space through a point-wise linear encoder and MLP projector, preserving exact index-level access while eliminating the need for patching and padding. To further bridge the semantic gap between time-series and language representations, we introduce a novel one-directional supervised contrastive loss that aligns time-series embeddings with frozen class-name text anchors. Experimental results on the public Time-MQA benchmark demonstrate that our framework consistently improves performance across six TSQA tasks, outperforming both open-source and proprietary LLM baselines.","url_abs":"https://arxiv.org/abs/2606.18986","url_pdf":"https://arxiv.org/pdf/2606.18986","source":{"archive":null,"snapshot":"2025-07-28","note":"not in the Papers with Code archive (frozen at the snapshot)","row_kind":"graph","title_abstract_authors_date":"arXiv metadata, CC0 1.0 (https://info.arxiv.org/help/license)"},"code_links":[],"tasks":[],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":null,"mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2606.18986"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"mentioned_in_github":null,"is_official":null,"provenance":"deterministic:regex_extraction","mentioned_in_paper":null,"url":"https://github.com/YafengWu/CADE","reach":null}],"summary":{"ran_honours":1,"ran":7,"unverified":2},"by_repo_kind":{"found_in_text":{"samples":10,"ran":8,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":10,"samples":[{"code_sha256_prefix":"f6b944f50d3f15ae","entry":"count_parameters","repo":"YafengWu/CADE","repo_kind":"found_in_text","path":"ITFormer/qformer.py","file_url":"https://github.com/YafengWu/CADE/blob/HEAD/ITFormer/qformer.py","link_basis":"harvester_set","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"well_formed","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"f6b944f50d3f15ae"}},{"code_sha256_prefix":"1c7a5116161d0e14","entry":"formatting_func","repo":"YafengWu/CADE","repo_kind":"found_in_text","path":"Time-MQA/merge.py","file_url":"https://github.com/YafengWu/CADE/blob/HEAD/Time-MQA/merge.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"1c7a5116161d0e14"}},{"code_sha256_prefix":"fcae13cf1128376a","entry":"parse_list","repo":"YafengWu/CADE","repo_kind":"found_in_text","path":"CADE_wo_SupCon/merge.py","file_url":"https://github.com/YafengWu/CADE/blob/HEAD/CADE_wo_SupCon/merge.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"fcae13cf1128376a"}},{"code_sha256_prefix":"5e9af76aed1f8ea8","entry":"parse_qa_list","repo":"YafengWu/CADE","repo_kind":"found_in_text","path":"CADE_wo_SupCon/merge.py","file_url":"https://github.com/YafengWu/CADE/blob/HEAD/CADE_wo_SupCon/merge.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"5e9af76aed1f8ea8"}},{"code_sha256_prefix":"708025a71d27980d","entry":"parse_qa_list","repo":"YafengWu/CADE","repo_kind":"found_in_text","path":"deepseekv3.2.py","file_url":"https://github.com/YafengWu/CADE/blob/HEAD/deepseekv3.2.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"708025a71d27980d"}},{"code_sha256_prefix":"330018e1842bb50b","entry":"parse_qa_list","repo":"YafengWu/CADE","repo_kind":"found_in_text","path":"Frozen_random_linear/merge.py","file_url":"https://github.com/YafengWu/CADE/blob/HEAD/Frozen_random_linear/merge.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"330018e1842bb50b"}},{"code_sha256_prefix":"3d336e2377914a72","entry":"parse_stats","repo":"YafengWu/CADE","repo_kind":"found_in_text","path":"CADE_wo_SupCon/merge.py","file_url":"https://github.com/YafengWu/CADE/blob/HEAD/CADE_wo_SupCon/merge.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"3d336e2377914a72"}},{"code_sha256_prefix":"a326319a16758f3a","entry":"weight_tag","repo":"YafengWu/CADE","repo_kind":"found_in_text","path":"CADE/merge.py","file_url":"https://github.com/YafengWu/CADE/blob/HEAD/CADE/merge.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"a326319a16758f3a"}},{"code_sha256_prefix":"74e845a6129041fd","entry":"generate_answer","repo":"YafengWu/CADE","repo_kind":"found_in_text","path":"Time-MQA_Full_FT/merge.py","file_url":"https://github.com/YafengWu/CADE/blob/HEAD/Time-MQA_Full_FT/merge.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"74e845a6129041fd"}},{"code_sha256_prefix":"52ab1935fb9e168f","entry":"generate_from_embeds","repo":"YafengWu/CADE","repo_kind":"found_in_text","path":"CADE/merge.py","file_url":"https://github.com/YafengWu/CADE/blob/HEAD/CADE/merge.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"52ab1935fb9e168f"}}]},"arxiv_metadata":{"licence":"arXiv metadata, CC0 1.0 (https://info.arxiv.org/help/license)","fields":["title","abstract","authors","date"],"primary_category":"cs.CL","source":"arxiv_2026.jsonl"},"syntology_extracted_results":null}