About
## Wave 1 submission
Overview
We’re building RAGbits Exchange — a pay-per-chunk RAG marketplace on 0G. Publishers store datasets/embeddings in 0G Storage; buyers hit an /ask endpoint on 0G Compute that fetches only the needed slices. Each request is HTTP 402–gated (x402), and outputs plus source digests are anchored on 0G Chain.
What we completed this wave
Ideation & scope lock
Chose the “Data Slice Marketplace (pay-per-chunk RAG)” direction and named it RAGbits Exchange.
Defined the user flow: Publish → 402 challenge → pay → slice retrieval → RAG → on-chain proof → response.
Written proposal
Drafted a full proposal (problem, why 0G, x402 flow, MVP, risks, success criteria).
Specified key artifacts: Evidence/Slice IDs, dataset/version hashing, response digest (SHA-256) recorded on-chain.
MVP plan & goals
MVP: Upload tool → 0G Storage; GET /ask with citations + digest; minimal ProofRegistry contract; simple explorer.
Success criteria set: x402 required per request, citations to exact slices, digest anchored per answered query.
Technical design
Architecture diagram (Publishers / Buyers / RAG Service on 0G Compute / 0G Chain).
Endpoint contract: GET /ask (402 then paid retry with X-PAYMENT), POST /publish (register dataset metadata).
On-chain fields defined: {answerHash, datasetHash, sliceIds[], modelVersion}.
Assets for the pitch
Project logo and simplified logo variant.
Process infographic and technical architecture diagram.
Product tagline options for technical audiences.
Deck
Created a concise pitch deck covering the above.
URL: https://ragbits-exchange-pit-z0hx.bolt.host
Deliverables this wave
Proposal text (ready for README/submit).
Visual assets: logo, explainer panels, technical diagram.
Pitch deck (link above).
Next wave (planned)
Scaffold contracts (ProofRegistry) + storage indexer.
x402-gated /ask endpoint and minimal retriever.
Demo UI to run two queries and show the on-chain proof.
## Wave 2 submission
Updates in this Wave Deliverable: https://v0.app/chat/github-youtube-page-eGb4hB7jY8k Complete x402 RAG Marketplace Integration
Implemented HTTP 402–metered retrieval flow on top of 0G services Publishers can upload datasets/embeddings to 0G Storage with indexing for byte-range or vector search
Buyers and agents can query via /ask endpoint on 0G Compute Full lifecycle tested: publish → query → 402 challenge → payment → retrieval → inference → proof anchoring ProofRegistry contract live on 0G Chain anchoring SHA-256 digests of answers + citations
Marketplace Architecture
Unified backend flow across 0G Storage, Compute, and Chain
Retrieval augmented generation (RAG) executed only on required slices (byte ranges or vector hits)
Citations returned with answers; proofs written on-chain for auditability
Middleware enforces x402 “pay-per-request” model (no accounts, no keys)
Extensible design supports new payment rails, rerankers, or dataset discovery
Smart Contract & Payment Flow
ProofRegistry Contract anchors {answer, slice IDs, dataset/version} digests to 0G Chain
Buyers receive {answer, citations[], proofTx} with every query
x402 flow:
Server replies with HTTP 402 Payment Required
Client retries with X-PAYMENT header (e.g., USDC via facilitator)
Request executes only after valid payment is confirmed
Pure pay-per-query, no pre-funded accounts or subscriptions
Retrieval & Inference Jobs
Retrieval engine fetches only needed slices from 0G Storage
Reranker + small LLM run inference on 0G Compute with citations included
Result digests anchored on-chain for verification
Provenance-first design ensures users can audit what data produced the output
API Endpoints
Dataset Services
/api/publish → register dataset metadata
/api/storage/upload → upload datasets/embeddings
Query Services
/api/ask?query=... → buyer query endpoint 402 challenge on first request with payment requirements Retry with X-PAYMENT to execute query Proof Services /api/proof/:txHash → retrieve digest + metadata from 0G Chain /api/citations/:id → query slice references Users & Roles Publishers: Monetize datasets/embeddings on a pay-per-query basis Buyers/Agents: Pay only for needed context, receive answers + verifiable proofs MVP Scope (Hackathon Delivery) Dataset upload + indexing to 0G Storage /publish + /ask endpoints with x402 middleware ProofRegistry contract deployed on 0G Chain Web demo: query box, citations viewer, proof transaction explorer Technologies 0G Storage / 0G Compute / 0G Chain x402 HTTP middleware (pay-per-request) Solidity (ProofRegistry) TypeScript/Node.js (API + retriever) React (web demo UI) Stretch Goals Merkle/MPT proofs for slice inclusion Publisher-defined pricing tiers (per dataset, per KB) Cross-chain buyer support with 0G anchoring via relayer Multi-model RAG (reranker options) + dataset discovery page ✅ Core flow is functional — marketplace backend complete, currently testing x402 challenges, proof anchoring, and web demo integration.
## Wave 3 submission
Recap on what we're building:
RAGbits Exchange - a marketplace where people pay for specific chunks of data they need for AI queries, built on the 0G network. How it works:
Data providers upload their datasets to 0G Storage When someone needs information, they send a request to an API They pay a small fee for just the data chunks they need (not the whole dataset) The system finds the relevant information, answers their question, and records proof of the transaction on blockchain
Markdown technical document containing all covered for wave3 (smart contract addresses, integration link, demo etc): https://github.com/s29papi/Ragbit/blob/main/TECHNICAL-DOCS-WAVE3-README.md
Why:
Today, AI models and researchers often need access to large datasets, but most data is locked behind full downloads or paywalls. RAGbit makes data more accessible and efficient — letting users pay only for the specific chunks they need, while ensuring data owners get fairly compensated through on-chain proofs.
## Wave 4 submission
RAGbits Exchange - a marketplace where people pay for specific chunks of data they need for AI queries, built on the 0G network. How it works:
Data providers upload their datasets to 0G Storage When someone needs information, they send a request to an API They pay a small fee for just the data chunks they need (not the whole dataset) The system finds the relevant information, answers their question, and records proof of the transaction on blockchain
Markdown technical document containing all covered for wave3 (smart contract addresses, integration link, demo etc): https://github.com/s29papi/Ragbit/blob/main/TECHNICAL-DOCS-WAVE4-README.md
Why:
Today, AI models and researchers often need access to large datasets, but most data is locked behind full downloads or paywalls. RAGbit makes data more accessible and efficient — letting users pay only for the specific chunks they need, while ensuring data owners get fairly compensated through on-chain proofs.
Prizes
- Wave 1 grant · 54 USDT
From the public Akindo product page. Votes, swipes and the judge score are hackfeed's own.





