Luxis

Government tenders for building-supply stores: which ones fit, at what price they are won and what paperwork is missing.

RoleDatabase, ingestion from the portal, AI for matching, pricing and reading tender documents, MCP server and deployOriginbuild 101 hackathon, on a team of three · top 10 out of 100+ teamsYear2026CodePublic on GitHub
Next.js 16TypeScriptPostgreSQLpgvectorDrizzleSupabaseVercel AI SDKZodMCPVercel
Top 10

Out of more than 100 teams that applied to build 101. From the idea to the deployed app in one day, with real data from the public procurement portal: none of the tenders, prices or AI answers were simulated.

Luxis reads the tenders on Uruguay’s public procurement portal and tells a building-supply store which ones it can sell to, with a confidence percentage and the reason. For each tender it reads the bidding documents, works out the price that item was won at before, and flags what paperwork is missing and whether it can be obtained before the deadline. Three of us built it at build 101, a one-day hackathon, and we finished in the top 10 out of more than 100 teams that applied. My part was the database, the data and the AI that decides, calculates and reads.

Sebastián Viglione presenting Luxis on the build 101 stage, next to his two teammates
Pitching Luxis at build 101, with my two teammates.

The Uruguayan State buys cement, steel, sand and metal sheets every week, yet small and mid-sized building-supply stores barely sell to it. It is not about price: it is about how much work it takes to find out and to bid.

The procurement portal searches poorly and sends no alerts. Each tender comes with bidding documents of 30 to 100 pages, sometimes spread over several files inside a ZIP or a RAR, that nobody at a store has time to read. And even after reading them, two questions stay open: at what price is it won, and what paperwork do they ask for.

The hackathon brief asked for a product where AI was indispensable. We added that it had to actually work by the end of the day.

What we had to work around.

One day

From idea to deploy in a single day, with three people working in parallel on the same repository. Each of us had our own folders, and the contracts between modules were written before the code.

A portal not built for integration

The data is open, but it arrives as XML in windows of a few days, with detail pages that have to be scraped and bidding documents in PDF, Word, Excel, ZIP and RAR.

Items in free text

“CHAPA GALV ACANALADA CAL24 1,08X3,05M” is a metal sheet a store sells, but no rule knows that. Without solving it there is no matching and no price history.

An AI that cannot make things up

A store owner is going to bid with the number we show. A made-up price, or a requirement the documents do not ask for, is worse than saying nothing.

AI for what is language; arithmetic for what is a number.

The fastest thing at a hackathon is to hand everything to a model and show whatever it answers. We did not: a price “estimated” by a model cannot be defended or reproduced.

We split the problem in two. What is language goes to the model: whether a tender fits this store and with how much confidence, and what an eighty-page document requires. What is a number gets calculated: the winning price comes from real awards, in PostgreSQL, and the missing paperwork comes from crossing the requirements with what the company has and the days left.

And everything the model returns goes through a schema. If it cannot find a date in the documents, it returns empty; not an invented date.

Why it is built this way.

The model does the matching, on a written scale

The model evaluates every open tender in the sector against the company profile, item by item, and returns a confidence percentage with the reason in one or two sentences. The scale is in the prompt (90 to 100: it sells all the main items and reaches the area; under 40: not for this company), so the number means the same thing everywhere.

Winning price from the awards

For each item it looks up awards of the same article over the last 24 months, in the same currency and unit. The suggested price sits below the middle price without going all the way to the cheapest, and it is shown with how many awards are behind it and who wins most often.

The same article, written differently

Descriptions are stored as vectors with pgvector, and two articles count as the same when their similarity is above 0.92. That way an item finds its awards even if the portal entered it in several different ways.

Outlier prices, out

An award at less than a third or more than three times the middle price is almost always a data entry error: another unit, another currency or a total instead of the unit price. It stays out of the suggested price and out of the chart.

The AI does not decide what paperwork is missing

The model extracts from the documents what paperwork is required. What is missing comes from crossing that with the company’s documents and a table of how long each one takes to obtain: if it can be done before the deadline it shows up as an opportunity, and if not there is a warning, but the tender is not discarded.

A fast model for bulk work, a strong one on demand

Reading every open set of documents and evaluating every tender runs on the cheap model. The expensive one is kept for when someone asks to re-read a document or asks it a question. Models are named in a single file and the provider is switched with one variable.

A read-only MCP server

The price database and the open tenders can be queried from Claude, ChatGPT or an in-house system without going through the app: four read-only tools over data that is already public.

What we ruled out along the way.

Deciding by keywords

Keywords work for the coarse sector filter, not for deciding whether a tender fits this company. A turnkey construction job mentions cement and is not a sale of materials.

Letting the model estimate the price

It cannot be defended or reproduced. The price and its explanation come from the awards; the model does not touch the numbers.

Converting currencies

Turning dollars into pesos adds one more assumption to every price. Statistics are grouped by currency and by unit.

Storing the tender files

The extracted text is stored and the original is linked on the portal. Less infrastructure to set up in a day and nothing to keep in sync.

From “what do you sell” to “bid on this one”.

  1. 01

    Getting to know the company

    The profile is built by uploading files or the store’s website, or through a chat or voice interview that asks only for what is missing.

  2. 02

    Tenders that fit

    A dashboard with the open tenders sorted by confidence, each with its summary and the reason.

  3. 03

    The documents, read

    What is being bought, how much, where it is delivered and when it closes, with the requirements, the key dates and the risky clauses.

  4. 04

    The price it is won at

    For each item: the range where half of the awards landed, the suggested price and who wins it most often.

  5. 05

    What paperwork is missing

    Each requirement against what the company already has, with how long the missing ones take and whether there is time before the deadline.

  6. 06

    The database, from your own AI

    Winning price for an article, pricing for a whole list, open tenders and the full record of a tender, over MCP.

There were three of us. I built the database and the schema, the ingestion from the portal, the matching, the winning price, the reading of the documents with the missing paperwork, the MCP server, the integration and the deploy. Sign-up, the company profile, the voice interview and the chat with the documents, plus a good part of the interface, the calendar and the notifications, are my two teammates’ work.

From the portal to a recommendation with a price.

01

Public procurement portal

XML reports in windows of days, detail pages and tender files.

02

Ingestion

Normalizes dates, currencies and text; unpacks ZIP and RAR and extracts the text from PDF, Word and Excel.

03

PostgreSQL + pgvector

Tenders, items, awards and bidders, with descriptions and document paragraphs stored as vectors.

04

AI with structured output

Matching and document reading against Zod schemas, at temperature 0.

05

Calculation

Winning price with percentiles in SQL; missing paperwork with rules and lead times.

06

App and MCP

Next.js on Vercel: dashboard, tender page, chat and calendar, plus the MCP server.

The routes that talk to the portal run in São Paulo: from the United States, the portal drops the connection. We found out on the first deploy.

What can be measured.

Top 10

out of more than 100 teams that applied to the hackathon, with the app deployed in one day on real data from the portal.

8 of 10

real opportunities found when evaluating the matching on 20 hand-labeled cases, with no false positives.

65,254

awards analyzed to calculate winning prices, with data since 2024 (as of December 2, 2026).

4

read-only tools on the MCP server, to query prices and tenders from another AI or from an in-house system.

How it was measured.

Matching evaluation
20 hand-labeled cases
At a confidence threshold of 40
Precision 1.00 · recall 0.80
At a confidence threshold of 60
Precision 1.00 · recall 0.50
Model outputs
Validated against Zod schemas
Winning price
SQL over awards, outliers removed

It is 20 cases: enough to choose a threshold and to see that it does not recommend just anything, not enough for a statistic. The cases and the result are in the repository.

Inside Luxis, with a sample store.

Luxis dashboard with tenders sorted by match
The dashboard: each tender with its match score, the reason in one sentence, what the store can sell, the paperwork status and the estimated amount. Sample company, real tenders.
Tender page in Luxis with the summary of the bidding documents
A tender page: whether it is worth it and why, whether the paperwork can be ready in time and the bidding documents summed up in a paragraph.
Historical winning price per article in Luxis
The price it is won at: the range where half of the winning bids landed, the suggested price, the latest award and who usually wins. Public procurement data.
Luxis MCP server queried from an assistant
The same database from another AI: a question, the call to the MCP server tool and the real answer from the database, with the guide to connect it.
  • With the clock running, writing the contracts between modules before the code is what let three people work in parallel without stepping on each other.
  • The hard part of public data is not getting it: it is that the same article is written in many ways and with data entry errors.
  • Measuring, even with 20 cases, changes the discussion: the threshold stopped being an opinion.
  • An AI product is easier to defend when you can say what the model does and what it does not.

Want to talk about this project?

The code is public. If you want to see how it is built, or you are thinking about something similar for your company, write to me.