arXiv ScienceSearch

arXiv · 2608.04464

Trie-Constrained Token Prediction with Hierarchy-Aware Semantic Alignment for HS Code Prediction

Abstract

Harmonized System (HS) code prediction (HSP) from commodity text is essential to international trade, and its importance continues to grow in port logistics. For the purposes of such prediction, recently, large language models (LLMs) have been actively investigated, owing especially to their strong language-understanding capabilities. However, their high computational cost limits deployment in constrained environments such as container terminals. Small language models (SLMs) offer a practical alternative, but their smaller scale makes them prone to generating invalid HS codes and to overlooking the hierarchical semantics between commodity text and HS codes. To address these limitations, this study proposes TRIE-HSA, which combines trie-constrained token prediction with hierarchy-aware semantic alignment (HSA). This method constrains the SLM to predict only valid digits under the HS taxonomy and aligns commodity text representations with the hierarchical structure of HS codes. In extensive experiments on data collected from an operational container terminal, TRIE-HSA improved average HS6 accuracy by 49.96 %p over zero-shot inference and exceeded the strongest task-specific benchmark by 11.94 %p. These results demonstrate that accurate and structurally valid HSP is achievable with fewer than 10 billion parameters. Therefore, TRIE-HSA offers a practical basis for deployment of HSP in port logistics operations that cannot support largescale LLMs.

Explore related subjects

Keep this discovery

BibTeXRIS

Minseop Kim, Taekhyun Park, Kikun Park, Hyerim Bae. 2026-09-04. Trie-Constrained Token Prediction with Hierarchy-Aware Semantic Alignment for HS Code Prediction. https://arxiv.org/abs/2608.04464

Cite the original work for its findings. Save a collection to share your selection of sources.

Discover connections

Connections use source metadata and explicit phrase matches, not verified experimental comparisons.

KEEP EXPLORING

Related papers

Hemispherical Ray-Casting Analysis for Milling Configuration Classification and Machinability Assessment

Early-stage manufacturability assessment reduces design iterations and costly downstream changes. This paper presents a GPU-accelerated geometric analysis method that evaluates CNC machinability and setup requirements directly from CAD files. A multi-stage pipeline uses hemispherical ray-casting to quantify surface accessibility, followed by directional variability analysis to extract dominant machining axes. Threshold-based classification determines 3-axis versus multi-axis machining. For 3-axis parts, orthogonal ray-casting and reachability optimization compute the minimum setup count and explicitly flag inaccessible surfaces. Validation cases show computation times sufficiently short to support interactive CAD workflows, enabling quantitative manufacturability feedback during the design stage without requiring manufacturing expertise.

cs.CE

Intrinsic Finite Element Methods for Fluids on Riemannian Manifolds Compared with Surface FEM

We present an intrinsic finite element formulation for the incompressible Navier--Stokes equations on Riemannian manifolds. We derive the corresponding weak formulation and prove that the backward Euler discretisation is energy stable. The proposed framework is validated on several representative manifolds, with particular attention paid to the long-time behaviour of the flow and its convergence to steady-state solutions represented by Killing vector fields. Comprehensive comparisons are performed with the surface finite element method and a corresponding eigenvalue formulation for Killing vector fields. The numerical results demonstrate that the intrinsic formulation provides an accurate, computationally efficient, and geometrically transparent alternative to embedded surface finite element formulations, while naturally extending to higher-dimensional Riemannian manifolds.

cs.CE