Metis — an advanced financial model for B2B imports and e-commerce
From the cost of a single shipment to a purchasing decision — with visibility into margins, inventory and the company’s future liquidity.
Metis is a digital twin of the financial and operational structure of an importing company running multichannel B2B and e-commerce sales. It connects purchasing, sales, warehouse, team and financing data to show not just how much the company sells, but what it actually earns, where it commits capital and what purchases it can afford.
The model accounts for the journey of goods from a foreign-currency invoice, through transport, customs duty and insurance, to storage and sale. It also includes wages, fleet, infrastructure and debt servicing allocated to locations. Every cost item has a data source and an allocation key — rather than disappearing into a single averaged overhead figure.
Portfolio · B2B Imports and E-Commerce
3 roles
Due diligence, liquidity planning and data for AI agents
SKU × warehouse × period
Shared keys connecting costs, inventory and financial results
4 purchasing currencies
EUR, USD, GBP and CNY converted to PLN
WAC
Recursive valuation of inventory and stock issues
Excel + Python + React
Calculations, data integration and dashboards

Metis supports three decision areas: inventory and customer portfolio due diligence, operational cash flow management and purchasing recommendations from Quantis agents. Management, finance and logistics work with the same data, even though they use it for different tasks.
Problem
Gross margin alone does not show whether a product is profitable
Purchase price and selling price are only the start of the calculation. In importing, results are affected by exchange rates for advance and balance payments, freight, customs duty, occupied warehouse space, packing methods, financing costs and the product’s share of operating costs. A single averaged markup can conceal an SKU that sells well but ties up a disproportionate amount of cash or space.
A similar gap exists in liquidity planning. A confirmed order, payroll schedule or contracted campaign means a future payment, even if no invoice has been issued yet. A report based solely on accounting documents reveals these commitments too late.
Metis connects both views: the profitability of a decision and its cash implications. A change in exchange rates, energy costs, team composition or an allocation key flows through the connected modules. This makes it possible to assess a decision’s impact on the product, warehouse and company before implementing it.
Without a shared model
Only partial visibility into costs and commitments
Averaged storage and shipping costs distort product profitability. The book value of inventory does not reveal its quality, and sales figures do not expose customer concentration risk.
Purchasing, investments and liquidity are analysed separately. The team manually gathers data before it can assess whether a recommended order fits the budget.
With Metis
A decision based on cost, risk and available capital
Product cost is derived from source data, its logistics profile and its allocated share of warehouse costs. Inventory and customer portfolio quality are analysed at SKU and customer level.
Known payments enter the cash flow plan before the invoice arrives. Quantis agents receive not only demand forecasts, but also margins, budgets, planned investments and financial constraints.
System architecture
One calculation model, many uses for the data
Excel — a transparent financial and operational model
The Metis calculation layer is a network of connected formulas based on shared keys: product ID, warehouse ID and accounting period. Inventory cost depends on the previous period, while warehouse cost depends on the assigned team and central allocation keys.
The client can trace results back to assumptions and sources. Changing an exchange rate, allocation percentage or team composition updates the related calculations, rather than requiring manual corrections to every report.
Python and the server application — integration and scaling
Python handles source data processing and integration logic. A dedicated server application automatically adjusts the model’s size and structure to the number of SKUs in the client’s catalogue.
Parameter updates, scenario recalculations and result exports are launched from Excel, while integration processes run in the background. Expanding the catalogue does not mean manually rebuilding the model.
Databases — results available beyond the spreadsheet
The architecture includes storing calculation results in a NoSQL database and distributing them further as budgets, scenarios and data for comparative analysis. Server integration also includes exporting recalculated data from Excel to MySQL and transferring JSON data.
This means the model does not end with the analyst’s file — its results can feed the company’s applications and operational processes.
React and notifications — access to results and update status
React dashboards make model results available to the teams using the data. Automated Discord notifications report completed actions, such as updates to packing thresholds, parameter changes or data transfers.
The team sees not just the numbers, but also information about completed updates.

Quantis, Echo and AI — separate responsibilities
Quantis provides sales history, demand forecasts and a predictive engine also used in due diligence. Its agents use Metis data, objectives and financial constraints. Echo receives the operational cash flow plan, supplemented with known payments before invoicing.
Language models support the interpretation of calculated results. An LLM does not replace financial calculations — it adds a narrative to the numbers calculated by Metis.
Modules and features
Due diligence — the quality of inventory and revenue, not just their value
Metis uses a predictive engine originally built within Quantis and developed further in FORECAST: Adaptive Demand Engine. The analysis goes beyond a single reporting period: it helps an investor, management team or auditor assess the company’s condition using historical data.
DD: Stock Health Scoring
Shows what proportion of inventory value carries elevated risk. Based on sales pattern classification, it assesses SKU turnover, the probability of becoming slow-moving or obsolete stock, and the concentration of value in risky items.
The result is a product-level risk distribution, not a single rating for the entire warehouse. Investors gain an additional basis for company valuation, while management can spot ageing categories earlier. The analysis uses the same engine as demand forecasting, without maintaining a separate ML model solely for inventory risk.
DD: Client Risk & Concentration Analysis
Separates high revenue from the quality and stability of the B2B customer portfolio. It combines payment timeliness history, the customer’s share of sales and order variability into a risk profile.
It shows the company’s dependence on its largest customers and the potential significance of losing a specific client. Management and prospective company buyers can assess revenue concentration using payment and sales data, rather than relying solely on salespeople’s opinions.
Quantis agents — purchasing aligned with profitability and liquidity
Metis does not generate purchasing recommendations directly. It provides Quantis agents with data, objectives, constraints, budgets and priorities. The digital twin covers not only the current state, but also future plans, commitments, CapEx and margin targets.
Financial context — not just “what to buy”, but also “when”
A good purchase must be profitable and financeable at the right time. Metis calculates the cost of delivering goods and the cost of selling them, taking into account when they enter the warehouse and are released to the customer, not just the order date.
The context provided to the agent includes:
- Logistics: sea, rail and road freight, fuel surcharges and delay risks.
- Imports: customs duty, taxes, port charges, customs clearance and agency services.
- Storage: cubic volume or pallets, picking and the opportunity cost of occupied space.
- Sales: payment gateway and marketplace fees, B2B insurance and assumed returns costs.
- Financing: exchange rates, interest and the cost of capital tied up in an SKU.
- Demand: seasonality, industry trends and market changes affecting turnover.
AGENTS: Replenishment Recommendation Agent
Prepares replenishment proposals based on actual product economics. It accounts for contribution margin, storage and ordering costs, planned cash flow, CapEx and inventory budgets.
The budget is a constraint, not an additional comment on the recommendation. Priorities defined in Metis help resolve competing needs — even in a catalogue of 6,000 SKUs. If the plan indicates a temporary liquidity shortfall, the agent can identify a later purchasing window rather than focusing solely on product availability.
Every proposal can be traced back to the source data, costs and forecasts that justify it.
Team workflow — approval and exception management
The logistics specialist and analyst receive a proposal to review, rather than having to reconstruct the entire purchasing calculation themselves. They can focus on availability, turnover and margins, and respond to exceptions: freight price spikes, supplier delays and market anomalies.
The Replenishment Recommendation Agent is the first agent powered by Metis. The rules layer is prepared for further applications, such as assessing supplier terms against historical prices and freight costs, or detecting cost variances before the monthly report.
Integrations and cash flow — commitments visible before invoicing
INTEGRATIONS: Echo Operational Cash Flow Source
The liquidity plan includes what the company has already agreed to, not just what it has booked. Metis provides Echo with the plan and source data on known, certain payments for which no invoice has yet been issued.
Echo uses them to supplement the operational cash flow picture. Finance uses the same planning data as the rest of the model, rather than maintaining a separate spreadsheet of future payments.
CASHFLOW: Pre-Invoice Commitment Tracker
Organises scattered payables and receivables on a single timeline. It uses confirmed STOCK purchase orders, WAREHOUSE wages and contributions, EFAR investment and financing schedules, and contracted TRAFFIC campaigns.
The module does not create a new value — it gathers existing commitments arising from orders, contracts and schedules, then passes them to Echo. The finance team does not need to collect this information again from every department before updating the liquidity plan.
STOCK — inventory cost and individual SKU profitability
STOCK: Purchase Order Costing
Import costs reflect the actual terms of each payment. Advance and balance payments are converted to PLN separately. The bank exchange rate takes precedence; if none is provided, the model uses the table for the payment month.
Transport has its own exchange rate matched to its payment date, not the date the goods were purchased. The same mechanism handles EUR, USD, GBP and CNY. Purchase value and quantity feed the WAC engine by product and period, without manually reconciling exchange rates for each shipment component.
STOCK: Currency Requirement & Hedging
Currency exposure is connected to margin, rather than analysed in isolation from the business. Planned orders and payment dates determine future requirements to purchase EUR, USD, GBP and CNY.
The model allows comparison of current, scenario and hedged exchange rates, showing how each affects purchase cost, landed cost and margins at product, warehouse and transaction level.
The module’s logic draws on Origami Effect’s experience in analysing flows for companies with a combined currency exchange value of PLN 2.5 billion. This experience includes financial models and a Business Intelligence system for an online currency exchange platform.
STOCK: Customs & NBP Rate
Customs duty becomes part of product cost, rather than a later manual adjustment. The calculation base includes the value of goods, transport and insurance, converted using a separate official NBP exchange rate specified in the model, independently of the payment’s transaction rate.
The duty rate comes from a central table by tariff ID and period. The result feeds Purchase Order Costing. If no rate is defined, the model assumes zero rather than interrupting the calculation — so the completeness of the table matters when interpreting costs correctly.
STOCK: Weighted Average Cost Engine
Margin uses an inventory cost that accounts for deliveries in the given period. The engine first combines the previous balance with current purchases and calculates a new weighted average cost, WAC, then uses it to value sales for that period.
The result becomes the basis for the following month, creating a recursive calculation. When stock is zero or negative, the model retains the last updated average as the base cost. This means selling out inventory does not interrupt calculation continuity or cause division by zero.
STOCK: New Product Fallback
A new product is not automatically assigned a zero cost. If there is neither stock from the previous period nor a current purchase, Metis retrieves the catalogue price from the product master and converts it to PLN using the appropriate exchange rate.
This is a fallback valuation basis for SKUs without history. It limits artificially inflated margins and the need for finance to fill in costs manually.
STOCK: Warehouse Cost Allocation by Volume
A product bears storage costs in proportion to the space it occupies. The location cost from WAREHOUSE: Cost Matrix Output is divided by the total volume of assigned products. The resulting cost per m³ is used for allocation to SKUs.
This links warehouse cost with product contribution margin. It reveals items with a good gross margin that occupy too much space relative to the financial result they generate.


FULFILLMENT — costs based on how products are actually sold
Product dimensions alone are not enough to assess handling costs. A small SKU may regularly appear in large, multi-item orders. Metis builds a historical packing and basket profile, treating one sales document as one pick & pack parcel.
This is descriptive analytics: aggregation of history and classification against thresholds, not a model predicting the future parcel mix. The demand forecast provides the volume, while the fulfilment profile describes how that volume is handled.
FULFILLMENT: Size & Weight Classification
Handling costs account for the entire order, not just the dimensions of a single unit. A product receives a size class based on its longest side and a weight class, optionally including volumetric weight.
The order containing all items in the parcel is classified separately. The final fulfilment class takes the more demanding of the size and weight ratings. Missing dimensions result in an undefined class, usually with a conservative, higher cost threshold. Thresholds can be adapted to the carrier’s price list without changing the model’s logic.
FULFILLMENT: Basket Context Profile
Shows the picking work generated by an SKU’s presence in an order. It distinguishes solo sales, two-item baskets, three-to-four-item baskets and baskets containing at least five products.
The average number of items accompanying the product becomes an operational parameter. Basket context remains independent of dimensions: many items do not necessarily mean a large parcel, but may mean more pick & pack work.
FULFILLMENT: Product Packing Profile Export
Provides a basis for allocating packing and shipping costs using the history of a given SKU. It combines percentage distributions of parcel sizes, weight classes and basket sizes. By default, it requires at least three orders to avoid building a mix from too small a sample.
The export covers the entire catalogue and available period. It can be combined with a volume forecast and carrier and packing rates set by the client.
A multi-item order feeds the profiles of all products it contains. These profiles support cost allocation and margin analysis per SKU — they should not be summed to a company-wide result without an appropriate adjustment.
FORECAST — forecasts matched to product behaviour
FORECAST: Adaptive Demand Engine
Seasonal, stable and newly introduced products do not have to be forecast using the same method. Metis retrieves sales history and demand forecasts from Quantis, whose engine has been extended with adaptive features.
Method selection accounts for seasonality, trend, variability and the length of the SKU’s history. The forecast sales quantity for a product and period feeds the WAC engine as the stock issue volume. Forecast fit therefore affects not only the purchasing plan, but also planned inventory valuation and financial results.
FORECAST: Pattern Classification
The forecasting method can change as the product evolves. The classification layer analyses historical sales time series and assigns the SKU to a pattern used by the Adaptive Demand Engine.
The fit is reviewed periodically as data arrives, rather than being fixed once and for all. This limits the risk of using an outdated method when a product leaves its introduction phase or its demand pattern changes.
TEAM — total employment cost and its impact on locations
TEAM: Employee Master Registry
One master register connects HR data with cost accounting. Each person has a row containing their identification, position, department, network or location, employment dates, engagement type, social insurance status and employer PPK contribution rate.
The register feeds wage allocation to divisions and warehouses. Employment and B2B contracts can be accounted for under different cost and tax rules without manual exceptions in reports.
TEAM: Remuneration Timeline
The cost of a historical month is based on the rate in effect at the time, not today’s pay. The module stores a base rate and up to two pay rises with effective dates.
It also accounts for currency, VAT for invoicing contractors, commission, bonuses and payment source. The data allows remuneration for a given period to be reconstructed and feeds historical cost allocation to warehouses.
TEAM: Total Employment Cost — Benefits Basket
Employment costs include more than gross salary. A person can be assigned equipment, an office workstation, SaaS, a sports membership, team-building, wellness and mental health support, training and certifications, parking, relocation, public transport, medical care, childcare support, D&O insurance and discretionary bonuses.
Each benefit is a separate item. The full cost of an employee, department or warehouse can be compared, and the financial impact of standardising a specific benefit can be calculated.
TEAM: Termination Cost Modeling
An employment change has a quantifiable cost before the decision is made. Metis estimates exposure based on remuneration, notice period and the planned end date of the engagement, if known.
It allows analysis of an individual or a group, for example when restructuring a department or closing a warehouse. Notice-period costs can be included in the financial plan in advance.
TEAM: Vehicle & Asset Assignment
Fleet costs can be traced to the person using the vehicle. An employee is linked to an asset through an EFAR ID.
The connection to the asset’s activity profile makes fuel, servicing and parts costs available not only at warehouse or division level, but also by user. It supports assessment of whether assigning a vehicle to a position is justified.
CONTROL — costs accrued at the right time
OpEx: Activation Window Gate
A change to a cost’s active period is entered in one place. Before calculation, modules check the start and end dates of the assigned activation gate in the OpEx register.
The mechanism handles time-limited campaigns, recurring costs and seasonal costs. Rescheduling a campaign or ending a contract does not require changing formulas in every module. If a cost appears in the wrong month, its activation window can be checked centrally.
TRAFFIC — traffic acquisition costs linked to the campaign plan
TRAFFIC: Prospecting Cost Engine
The new-traffic budget is based on volume and rates, not a single fixed amount. A campaign’s monthly cost is the number of visits multiplied by CPC. Both parameters have independent annual percentage adjustments.
Traffic growth and advertising rate inflation can be modelled for future years without manually rewriting every monthly table. No costs are accrued outside the campaign’s active dates.
TRAFFIC: Remarketing Pool Engine
Remarketing costs change with the audience base from previous months. The model sums traffic over the retention period, converted from days to months, applying the appropriate annual adjustment to each historical month.
It then accounts for the Match Rate — the share of the audience the platform can match — and a separate remarketing CPC with an annual adjustment. Campaigns can differ in retention and matching, and costs remain linked to the volume of earlier traffic.
WAREHOUSE — warehouse costs with traceable sources
WAREHOUSE: Allocation Keys
One register defines the share of common costs assigned to a location. For each warehouse, it specifies employee divisions, CapEx, OpEx and financial liability items, along with their allocation percentages.
The same division or item can serve several warehouses with different shares. All WAREHOUSE modules use the same keys, so changing the split updates the related calculations.
WAREHOUSE: Wages & Payroll Contributions Allocation
The warehouse receives its allocated share of total labour costs, not just salaries. The module builds an employee key from first name, surname and employment date, then links it to seven registers: remuneration, accident insurance, disability insurance, pension insurance, the Labour Fund, FGŚP and PPK.
Rates come from TEAM history. Employee costs are summed using matrix calculations at division level and multiplied by the division’s share allocated to the warehouse. A new hire or departure affects the location’s cost calculation without separately rewriting the report.
WAREHOUSE: CapEx Allocation
The warehouse sees its share of centrally accounted asset and investment costs. The module searches five EFAR sources: fuel, servicing, spare parts, energy and CapEx cash data, then multiplies the value found by the allocation key.
The logic assumes that a given item appears in exactly one register. The link to the asset makes it possible to assess the location’s fleet, equipment and infrastructure burden, rather than leaving these costs solely in the company’s aggregate pool.
WAREHOUSE: OpEx Allocation
A location’s ongoing costs can be analysed separately from shared charges. Data comes from one dedicated register. The model matches the item and month, then applies the allocation percentage.
A consistent mechanism simplifies cost reconciliation and allows assessment of which operating expenses relate to a given warehouse.
WAREHOUSE: Financial Liabilities Allocation
Financing costs are also visible at warehouse level. The module allocates shares of lease instalments and interest on centrally arranged investment loans.
It uses a dedicated register, item and month matching, and a percentage key. This makes it possible to separate the impact of the location’s ongoing operations from charges resulting from the company’s financing decisions.
WAREHOUSE: Cost Matrix Output
One matrix replaces the manual compilation of four cost groups. It combines Wages, CapEx, OpEx and Financial Liabilities in a structure containing: item or division, category, allocation percentage and monthly values.
This is a shared basis for location cost calculations and warehouse comparisons. It preserves the distinction between operating costs and allocated personnel, asset and financing charges. It also feeds the allocation of storage costs to SKUs by volume.
EFAR — asset costs and capital expenditure as separate information
EFAR: Asset Activity Profiles
It is clear which asset generates a cost, in which month and for what reason. Fleet vehicles, machinery and equipment have their own fuel or energy, servicing and spare parts profiles.
Costs are calculated at source before being allocated to a warehouse or division. They feed WAREHOUSE: CapEx Allocation and help identify assets with rising maintenance costs, supporting equipment repair or replacement decisions.
EFAR: CapEx Cash Data
The investment plan is kept separate from the ongoing cost of using assets. The module records cash flows related to asset purchases, instalments and down payments, separately from operating profiles.
The data is one of the sources for WAREHOUSE allocation and cash flow planning. It allows capital expenditure schedules to be analysed separately from operating profitability.
ECON — shared assumptions and scenarios for future changes
ECON: Currency & Rate Trends
Modules use a shared exchange-rate register rather than maintaining inconsistent tables. ECON stores monthly EUR/PLN, USD/PLN, GBP/PLN and CNY/PLN values.
STOCK and EFAR select the rate for the relevant event: payment, transport or asset purchase, preserving separate rules for transaction and customs exchange rates. Updates to central assumptions flow through to related calculations without manually changing every sheet.
ECON: Financial Cost Indices
The financing cost plan can reflect changing market conditions. The monthly register includes interest rates, benchmarks such as WIBOR, lending margins and lease terms.
The data feeds debt-servicing costs allocated to warehouses. A change in the current or forecast rate becomes visible in the model, rather than retaining one unchanged assumption throughout the year.
ECON: Fuel & Electricity Price Trends
Different locations retain their own energy consumption profiles. Monthly fuel and electricity prices feed EFAR asset costs and, at energy-intensive locations, WAREHOUSE operating costs as well.
A cold storage facility does not have to be calculated using the same averaged rate as a dry warehouse of similar size. Price changes can be translated into fleet and location costs according to their operational characteristics.
ECON: Forward-Looking Sensitivity
Management can see the effects of a change before it takes effect. ECON registers store current values as well as future exchange rates, interest rates and energy prices. Modules retrieve them by period, so a change affects the correct month of the plan.
Similarly, on the revenue side, the model includes current and planned selling prices in the FORECAST layer. Cost and revenue scenarios show the impact on product and warehouse contribution margins in one connected calculation.
Client benefits
What access to connected data changes
Profitability visible at product level
Purchase, import, warehouse space and fulfilment profile costs feed into SKU analysis. A good gross margin can be distinguished from profitability after accounting for the costs of handling the product.
Purchasing linked to available cash
Quantis agent recommendations account for the cash flow plan, investments and inventory budget. The decision answers not only what is missing, but also when the company can fund replenishment.
Earlier visibility into liquidity pressures
Confirmed orders, payroll schedules and contracted expenditure reach Echo before invoicing. Finance sees known commitments without waiting for the document cycle to finish.
Assessing company quality before an investment decision
SKU and customer portfolio risk analysis supplements inventory book value and revenue figures. It helps identify ageing product ranges, sales concentration and customer payment risk.
Comparable warehouse cost calculations
Shared allocation keys show each location’s share of team, asset, operating and financing costs. Management can compare warehouses on a consistent basis and analyse the consequences of changes to the network.
Scenarios based on one set of assumptions
A change in exchange rates, interest rates, energy prices or selling prices flows through the connected modules. The impact on the product and location is visible in the period affected by the decision.
Less manual data compilation
Central registers, server integration and result exports reduce the need to collect the same information repeatedly. The team can devote more attention to variances and decisions, and less to reconciling spreadsheets.
AI with financial context
Agents receive calculated costs, objectives, priorities and constraints. Recommendations can be linked to source data, while language models support interpretation rather than replacing financial calculations.
Connect purchasing decisions with financial results and liquidity
Origami Effect designs financial and operational models based on a company’s real data and processes — so that costs, margins and available capital support a single decision.
