Amana

Agentic commerce you can trust. AI understands shopping intent and merchant interfaces; deterministic software controls identity, authority, and money.

Type
AI commerce platform
Role
AI & full-stack engineering

Tech stack

  • Java 25
  • Spring Boot
  • PostgreSQL
  • Next.js
  • React
  • TypeScript
  • Tailwind CSS
  • Gemini
  • pgvector
  • Razorpay
  • JUnit 5
  • Testcontainers
  • Vercel
  • Supabase

AI can understand a shopping request or diagnose a merchant API, but neither ability makes its answer financially authoritative. Amana separates those responsibilities in a deterministic trust layer for agentic commerce.

The Merchant Agentization Agent turns merchant-approved interfaces into tested, evidence-backed capabilities. The Safe AI Buyer interprets multimodal intent, discovers eligible products, and prepares a transaction without giving the model independent authority over money.

Amana public product landing page
Two product experiences share one deterministic commerce control plane.

The backend is a Java 25 / Spring Boot 4.1.1 modular monolith. PostgreSQL is the system of record. Authority-critical rules stay inside explicit module and transaction boundaries rather than introducing unnecessary distributed-system failure modes.

Gemini handles interpretation, multilingual and visual understanding, interface reasoning, diagnosis, and bounded planning. The application owns readiness, identity, authoritative quotes, policy evidence, proposals, authorization, exact money, execution, payment truth, and refund accounting.

Amana system architecture
The system separates AI reasoning from deterministic execution and financial truth.

The frontend uses Next.js, React, TypeScript, Tailwind CSS, and Razorpay Blade. Retrieval combines PostgreSQL full-text search, pg_trgm, pgvector, and Gemini embeddings. The deployed stack uses Vercel, Render, and Supabase; P0 requires no Kafka, BullMQ, or Redis service.

Merchant catalogues and APIs differ in money units, inventory semantics, fulfilment behaviour, policies, authentication, and response shapes. Amana starts with merchant-approved structured sources, not arbitrary website crawling.

The agentization lifecycle moves through inspection, discovery, mapping, contract testing, observation, diagnosis, bounded repair, and retest. AI may propose a mapping or diagnose a failure. Only deterministic evidence reduction can mark a capability READY.

Merchant agentization proposing a money-unit repair and requesting approval
A money-semantics change is proposed for merchant approval, not silently applied.

The demo exposes a concrete mismatch: an API returns 2999 for a ₹2,999 product, while the canonical money contract expects 299900 minor units. A rupees-to-paise repair must create a new mapping version, receive merchant approval, pass deterministic contract tests, and satisfy the readiness reducer.

Merchant capability after retesting and deterministic readiness reduction
Capability publication follows evidence and retesting, rather than a model’s confidence.

The Buyer can interpret typed, spoken, visual, multilingual, and conversational requests. Its execution path is stricter: eligible READY merchants, grounded catalogue records, an authoritative quote, stock and serviceability evidence, an immutable proposal, explicit authorization, and the execution gate.

Safe AI Buyer proposal awaiting explicit user authorization
The buyer reviews and authorizes a specific transaction before execution.

A canonical proposal hash binds authorization to the exact transaction. If execution attempts a modified amount, product, variant, merchant, currency, or provider account, the authorization no longer binds. Safety-critical missing evidence fails closed.

Browser callbacks and provider webhooks are observations, not unquestioned financial truth. The backend binds and reduces Razorpay evidence, reconciles ambiguous outcomes, and models proposal, authorization, execution, order, payment, fulfilment, and refunds separately.

Stable identities, constraints, and transactional locking make retries and concurrent callers converge. Durable work after commit uses a PostgreSQL transactional outbox. An uncertain provider outcome moves toward reconciliation rather than an invented success.

ChoiceWhyCost
Deterministic authority around AI reasoningKeep readiness, exact money, and execution application-owned.More explicit contracts, state, and evidence handling.
A modular monolithKeep authority-critical invariants inside clear transaction boundaries.Modules share a deployment boundary.
Merchant-approved structured sourcesTest known interfaces and preserve merchant authority.Arbitrary merchant websites are not automatically supported.
Hash-bound proposals and explicit authorizationBind the buyer’s approval to one exact transaction.Current purchases need on-screen authorization.
Fail closed and reconcile unknown outcomesAvoid guessing about safety-critical or financial state.Ambiguity can delay execution or completion.
Synthetic merchants and Razorpay Test ModeProvide a reproducible reviewer-facing demonstration.The demo does not establish production transaction or revenue claims.

The verification suites measure distinct boundaries, so their results are kept separate. These figures come from the repository’s committed evidence and README.

SuiteResult
Deterministic safety cases250 / 250 passed · 0 hard safety violations
Guard-removal negative controls12 / 12 killed
Concurrency scenarios10 / 10 passed
Concurrent critical operations5 operations at N=8 and N=32
Backend verification297 tests · 0 failures · 2 skipped
Frontend verification145 / 145 passed

The intent and retrieval fixtures report 92.41% buyer intent field accuracy, 83.58% hybrid-v3 discovery Recall@5, and 76.12% valid-product Recall@5. Valid-product recall improved by 20.90 percentage points over hybrid-v2. Exact-identity precision and valid no-match accuracy were both 100% on those fixtures.

The safety harness covers proposal integrity, money integrity, callback truth, payment and refund idempotency, capability readiness, evidence, and policy enforcement. The core pnpm proof:verify path runs offline without Gemini, Razorpay, or deployment services.

Explore the committed proof artifacts ↗

The public demo includes Buyer, Merchant, Proof, Security, Failure Lab, Architecture, and Performance surfaces. It uses synthetic merchants and products, Razorpay Test Mode, and explicit on-screen authorization for current purchases.

The fastest reviewer path is a Buyer request for Auralink Buds under ₹3,000, followed by the merchant money-unit repair and retest. The proof and security surfaces expose the evidence behind the authority boundaries.

Unattended scheduled AutoBuy is not presented as complete. Native Buyer applications remain a future direction. The current system makes no production revenue, security certification, or compliance certification claim.

The backend uses Render’s free tier and can sleep after inactivity. If the live demo is unavailable, open its health endpoint ↗, wait for an UP response, then reload the product.

Can the AI execute a payment on its own?

No. AI interprets and plans; the deterministic execution gate requires an exact, authorized proposal and the necessary evidence. There is no direct AI-to-Razorpay authority path.

What makes a merchant capability READY?

Deterministic contract tests, observed evidence, and a readiness reducer. A model can propose mappings and diagnose failures, but it cannot declare readiness.

How does Amana handle concurrent checkout attempts?

Stable identities, PostgreSQL constraints, and transactional locking make attempts converge. The documented suite covers five critical operations at eight and thirty-two concurrent callers.

Are payments real in the public demo?

The public system uses Razorpay Test Mode and synthetic demo merchants and products. It does not claim production revenue or unattended scheduled purchasing.

Does a browser success callback prove a payment succeeded?

No. Callbacks and webhooks are evidence observations. The backend binds provider order and payment evidence and deterministically reduces payment state; ambiguous outcomes are reconciled.

Can the core safety proof run without hosted services?

Yes. pnpm proof:verify runs the deterministic core proof offline. Provider-backed evaluation is a separate command and should be interpreted separately.

Project details and measurements from the repository README ↗.Checked 23 October 2026

LET’S CONNECT

LET’S TALK ABOUTWHAT’S NEXT.

I’m open to contracts, internships, and remote engineering roles.

STRAIGHT TO MY INBOX