As someone who’s worked in HTS classification since 2017, the question of whether AI can handle this intricate process has been at the forefront of my mind for some time. HTS (Harmonized Tariff Schedule) classification is critical in global trade, ensuring that goods are categorized correctly for customs duties, taxes, and international trade compliance. It involves analyzing products down to the tiniest detail, applying complex rules and regulations to determine their proper classification. But could artificial intelligence, with its rapid advancements, manage such a detailed and nuanced task? This article explores my journey of discovery, experimentation, and ongoing development to answer that very question.
Why Is HTS Classification So Complicated for AI?
HTS classification is inherently complex because it’s not just about matching product names to codes. It requires deep knowledge of General Rules of Interpretation (GRIs), national and international trade policies, and an understanding of intricate product specifications. Every product has specific attributes, and classifying them correctly involves interpreting these attributes in the context of legal trade rules. AI, as powerful as it is, faces challenges in dealing with this level of detailed interpretation and context.
AI can process large amounts of data, but the complications lie in its ability to understand the reasoning behind those classifications, especially when a single product can have multiple possible categories. Furthermore, legal frameworks are dynamic, with frequent updates and country-specific variations. Training AI to navigate this intricate web of information is no small feat.
Behind the Story: My Journey
My journey into AI and HTS classification began unexpectedly. I had been working as an HS classifier since 2017, and during the COVID-19 pandemic, like many, I found myself with extra free time while working from home. This time allowed me to explore a curiosity that had been growing—robotics and automation. As someone who had studied Bengali literature in my academic life, this was new territory for me. I wasn’t a tech guy by any stretch, but the pandemic gave me the space to dive in.
By December 2020, I had completed a course on Robotic Process Automation (RPA) using UiPath, and I was hooked. The more I learned, the more I wanted to explore. I attempted to learn Python and machine learning, but I quickly realized how complicated and technical these fields were. Despite my best efforts, I couldn’t make much progress.
Then, in mid-2021, I was introduced to OpenAI’s beta version. This technology opened my eyes to the possibilities of using AI to assist with HTS classification. I started to explore how AI might handle the classification of commodities, using the tools available to me. However, my lack of deep technical expertise in Python and machine learning held me back, and by July 2022, after leaving my job at Avalara, I paused the project.
November 2022 brought the release of ChatGPT 1.0, and I was back at it. I started using multiple AI tools to understand how they worked, initially for text generation, image creation, and even video generation—since content creation had become a hobby. During this time, I also began considering how AI could be fine-tuned to classify commodities. The potential was there, but the financial investment was substantial. My estimates suggested that developing an AI tool for HTS classification would cost close to $2 million.
Despite creating a proposal and presenting it on LinkedIn, I struggled to secure funding. Investors and CEOs contacted me, but without a working prototype, the project was seen as too risky. This was a low point for me, and once again, I paused the R&D process.
By December 2023, I faced a personal setback—I lost my job and remained unemployed for the next seven months. Fortunately, thanks to severance pay from STTAS and UPS, I had enough financial cushion to survive. During this downtime, I threw myself back into research and development, finally making progress. I’m now working towards building a functional prototype, though it still requires around $30,000 in additional funding to reach completion.
Why I Chose Chapter 82 for Testing
Honestly, I can’t fully explain why I chose Chapter 82 of the HTS for my initial testing. For those unfamiliar, Chapter 82 deals with tools, cutlery, and certain base metal articles. Something about its structure and variety of products drew me in, and I decided to focus my AI model training on this chapter. In hindsight, it was a good choice because it provided a broad range of products to challenge the AI.
Technology and Data I Used to Train the AI
Building an AI model capable of handling HTS classification was a technical journey far beyond my original expertise. I relied heavily on resources like GitHub, YouTube, and Stack Overflow to scrape together the Python and JavaScript code I needed. I used AWS as my server, and I pulled data from 17 different types of databases. These databases included PDFs, CSVs, text files, and even image files, all necessary to teach the AI how to interpret and classify various products.
It wasn’t easy. Training the AI with the basic concepts of Chapter 82 and the GRIs took a lot of trial and error. But eventually, the model started to respond to user instructions in a way that made sense. It wasn’t perfect, but it was working.
How It Works Now
The AI is now trained to understand the basic classification rules for Chapter 82. It can follow user instructions and respond with the appropriate HTS codes based on the data it has been given. I’ve attached a file below to provide more context on how the system operates, but in short, the AI is capable of recognizing commodities based on images, descriptions, names, or URLs.
What Will the Prototype Be Like?
The prototype I’m building will focus on classifying products under Chapter 82 for imports into the USA. Users will be able to provide input in several ways: by uploading an image of the commodity, providing a product description, entering the commodity name, or even sharing a product URL. The AI will then analyze this information and classify the product accordingly. The goal is to develop a tool that can scale to classify all commodities for all countries, making it invaluable for e-commerce platforms, which often struggle with correct HTS classification.
What I Want to Build
My ultimate vision is to create an AI tool that can classify HTS codes for any commodity, in any country, with multiple input types (e.g., API, product titles, CSV lists, or text/PDF files). The primary focus will be on supporting e-commerce businesses, particularly smaller companies that don’t have dedicated classification teams. This tool could significantly streamline the supply chain process by automating an otherwise manual and labor-intensive task.
Revenue Generation Potential
To give a concrete example of the potential revenue this tool could generate, let’s look at Amazon Global’s daily sales. Amazon handles around 66,000 orders per hour, or 1.58 million orders per day. If the AI tool could classify just 10% of these orders, it would process 158,400 commodities daily. Based on the industry standard, Amazon typically pays $0.35 per HS code. This means the AI tool could earn approximately $55,000 per day just from classifying Amazon’s orders alone. The possibilities are endless.
MOTO: Made in India
There is currently no trade compliance tool made in India, at least not as far as I know. By God’s grace, this AI-based HTS classification tool could be the first of its kind, created right here in India. It will not only support the growing e-commerce industry but also provide small business owners with a cost-effective solution for managing trade compliance.
Conclusion
AI has the potential to revolutionize the way HTS classification is handled, but it’s not a simple task. The road to developing such a tool is filled with technical challenges, financial hurdles, and personal sacrifices. Despite the setbacks I’ve faced, I remain committed to this project. With continued research, development, and hopefully, some financial backing, I believe we can bring this idea to life and create a tool that will benefit the entire global trade ecosystem. Let’s hope for the best!