尚未检测到更新。GitHub 发布版本后会显示在这里。
个人 GitHub 账号下公开仓库的所有者可以登录并验证所有权,自行管理介绍,无需管理员批准。
登录并生成验证文件,在 30 分钟内将其提交到此仓库的默认分支。其他分支或分叉仓库中的文件无效。然后在下方检查文件,即可无需管理员批准直接管理项目。请保留文件以维持管理权限。
如需登录,将前往登录页面。登录后请回到此处,再次点击所选的验证按钮。
在项目文件夹中运行 /nomorevibe verify,即可验证所有权并自行管理介绍。
一分钟完成验证BorderReady: book UK→EU pallet shipments in plain English and catch booking mistakes before they reach the border (Ops Hackathon, Case 2)
翻译准备中
正在加载完整 README。
查看完整 README ↗Book it right, before it reaches the border. Book a pallet shipment from the UK to Germany, France or the Netherlands, and catch mistakes before it leaves. Built for the Ops Hackathon, Case 2 (Shipment Booking & Error Checker).
Live demo: https://borderready-app.vercel.app (public, no login).
Code: https://github.com/lopamudrabareja-ctrl/borderready
All arithmetic and every pass/fail decision is deterministic TypeScript (lib/rules.ts, lib/carriers.ts). The LLM (Google Gemini) is used for only two things:
The booking is one state object. Checks, carrier choice and the chat reply are all recomputed from it on every change.
If Gemini is slow, out of quota or not configured, the chat falls back to a regex extractor ("basic mode") and still works for simple messages. Unclear R-06 items are then flagged "check manually", never silently passed. Calls time out after 15 s in total.
Needs Node.js 20.9 or newer.
npm install
cp .env.example .env.local # then paste your Gemini key into .env.local
npm run dev # http://localhost:3000
Without a key the app still works, with chat in basic mode.
| Name | Required | Notes |
|---|---|---|
GEMINI_API_KEY | for smart chat | Free key from Google AI Studio. Server-side only. |
GEMINI_MODEL | no | Defaults to gemini-3.5-flash-lite (about 1 s per call). gemini-3.8-flash timed out on the free tier in testing. |
This is a demo on Gemini's free tier, so prompts may be used by Google. Don't enter real customer data.
| Command | What it does |
|---|---|
npm test | Vitest: all rules, carriers, Excel parsing, chat flow, LLM wrapper (mocked), junk-data robustness |
npm run build | Production build |
npm run make-fixture | Regenerates fixtures/test_bookings.xlsx from the template |
npm run play-chat | Plays 5 scripted conversations against a running server and prints the booking after each turn |
After make-fixture, copy the file to public/samples/ so Load sample data uses it.
data/rate_card.json fixed carrier options
data/sample_template.xlsx judges' template
lib/rules.ts R-01..R-10, pure functions
lib/prohibited.ts R-06 keyword lists and negation handling
lib/carriers.ts feasibility filter, ranking, balanced score
lib/booking.ts booking state, applyPatch, missing fields, summary
lib/excel.ts SheetJS parser for the Bookings + Items sheets
lib/llm.ts Gemini wrapper: extractPatch, classifyProhibited, retry, timeouts
lib/fallback.ts basic-mode regex extractor
lib/chat.ts one chat turn: apply patch, recompute, build the reply
lib/guidance.ts next steps and scope note (based on GOV.UK export guidance)
app/api/chat/route.ts chat endpoint, rate limited per IP
app/api/classify/route.ts batched R-06 classification for uploads
components/ ResultView (shared by both tabs), ChatPanel, UploadPanel
fixtures/test_bookings.xlsx planted-error workbook
tests/ Vitest suites
Whether the HS code is the correct one (only that it has at least 6 digits), EORI numbers, VAT, licences for controlled goods, whether the buyer can import, proof of origin, export declarations, Incoterms or dangerous-goods paperwork. See GOV.UK: Export goods from the UK.