Inspiration

International trade shapes the prices we pay, the products available in stores, and the success of entire industries. Yet most people find trade policy abstract and confusing. Terms like tariffs, import restrictions, or trade balances often appear in headlines without much explanation, making it difficult to understand how those policies actually affect everyday life.

That gap between policy decisions and public understanding is what inspired MapleMargin. Instead of reading about tariffs in abstract terms, users can experiment with them directly. By adjusting tariff levels and selecting different countries or products, users can see how trade flows, industry performance, and prices might change. Our goal is to transform complex trade policy into something intuitive and explorable so that anyone, from students to business owners, can better understand how global trade decisions influence the Canadian economy.

What it does

MapleMargin is an interactive simulation platform that shows how tariffs affect Canadian trade and industries.

Users can choose a trading partner, select a category of goods, and apply a hypothetical tariff rate. Once those parameters are set, the platform calculates how that tariff might influence trade flows and economic outcomes. For example, if Canada places a tariff on imported electronics, the system estimates how imports from that country might decline, how domestic producers might gain market share, and how prices for consumers might change.

The platform then presents these changes through charts and dashboards. Instead of requiring users to interpret complicated economic data, MapleMargin shows the results in a way that is easy to understand: which industries benefit, which ones struggle, and how supply chains may shift toward other countries.

Essentially, MapleMargin acts as a sandbox for trade policy. Users can test scenarios, observe the potential consequences, and gain a clearer understanding of how tariffs influence economic relationships.

How we built it

MapleMargin combines real-world trade data with an interactive simulation engine. We sourced international trade data primarily from UN Comtrade datasets, along with supporting Canadian trade statistics and Harmonized System (HS) product classifications to organize thousands of goods into understandable industry sectors. These datasets allowed us to model how Canada trades with different countries across major product categories.

On the backend, we used Python, Pandas, and FastAPI to process the datasets and run the tariff simulation. The model estimates how tariffs affect import demand and then redistributes trade across alternative suppliers or domestic industries to simulate realistic supply-chain shifts.

For the frontend, we built an interactive dashboard using React, allowing users to explore scenarios and instantly visualize how tariffs might influence Canadian trade.

Challenges we ran into

One of the biggest challenges was finding and preparing the right data. The trade data we relied on was spread across hundreds of CSV files, often with inconsistent formats, naming conventions, and missing fields. Before we could even begin building the simulation, we had to filter out irrelevant information, standardize the structure of the datasets, and merge them into a format our system could process.

Another challenge was identifying reliable and relevant datasets in the first place. Trade statistics exist across many databases, and determining which sources were accurate and detailed enough for our simulation required significant research.

Finally, modeling tariffs themselves required simplifying a very complex economic system. We had to design a simulation that was realistic enough to demonstrate meaningful trade impacts, while still being fast and interactive for users exploring different scenarios.

Accomplishments that we're proud of

One of our biggest accomplishments was successfully transforming massive, complex trade datasets into an interactive simulation that anyone can use.

We processed hundreds of raw data files, extracted meaningful information, and built a system that can calculate how tariffs might affect trade flows. We turned this information into visual dashboards that make the relationships between tariffs, countries, and industries much easier to understand.

We are also proud that MapleMargin allows users to experiment with trade scenarios, making it both educational and practical. Users can explore how policy decisions might reshape supply chains or influence Canadian industries, giving them insights that are usually only accessible through advanced economic analysis.

Building a complete pipeline, from raw datasets to simulations to a responsive frontend, within the timeframe of a hackathon required strong collaboration and technical coordination across the team.

What we learned

This project taught us how complex and interconnected global trade truly is. A single policy change can ripple through multiple industries, affect international relationships, and influence prices for consumers.

From a technical perspective, we gained experience working with large-scale real-world datasets, cleaning inconsistent data, and designing systems that can transform raw information into interactive insights.

Perhaps most importantly, we learned how to communicate complex ideas clearly. Economic systems can be intimidating, but when presented through intuitive visuals and interactive tools, they become far easier to understand.

What's next for MapleMargin

While the current version of MapleMargin already demonstrates the concept, future versions could incorporate more granular product categories, allowing users to analyze specific goods rather than broad sectors. We also plan to add regional Canadian data, which would show how tariff changes might affect different provinces and local industries.

Another direction would be incorporating predictive modeling and machine learning. By analyzing historical trade patterns and policy changes, MapleMargin could eventually forecast potential economic impacts before tariffs are even implemented.

Our long-term vision is to create a platform that serves as a decision-support and educational tool for understanding trade policy. By making global trade more transparent and interactive, MapleMargin can help individuals, businesses, and policymakers better navigate the complex economic systems that shape our world.

Built With

Share this project:

Updates