Case study
ScopeCheck — AI Scope-Creep Checker
AI SaaS that tells freelancers whether a client request is covered by the signed contract. Upload the SOW, paste the request, and get a suggestion with exact, page-cited quotes, plus RAG over proposals, emails, and meeting notes. Change orders, client replies, and a PDF decision log close the loop.
What I built
Scope creep costs freelancers and agencies real money: "can you also add a login?" arrives weeks after the contract is signed, and someone has to dig through a PDF to check whether it was agreed.
ScopeCheck turns that into a one-click check. You import the signed statement of work (PDF, Word, or a public link; files are read in the browser and never uploaded). When a client asks for something, ScopeCheck compares it with the contract and suggests Included, Extra work, or Needs clarification, quoting the exact clause and its page. The AI only suggests; you record the decision.
Real projects have more than one document, so ScopeCheck also takes proposals, email threads, and meeting notes. The contract is always sent to the model in full, because it is binding. Supporting documents are context: small sets are sent in full, and larger ones (up to 10 documents of 200,000 characters each) go through RAG. They are split into page-aware sections and searched with Postgres full-text and pgvector semantic search, merged with reciprocal rank fusion. Every quote the model returns must match its cited source word for word, or the whole answer is rejected.
When a request is extra work, it becomes a change order with hours and price. Once the client accepts, it is appended to the contract as a new version, and older AI checks are flagged as outdated. ScopeCheck drafts a client-ready reply from your decision, checked so it cannot invent prices or dates, and produces a decision log you can save as PDF for invoices or disputes.
Role
Solo builder: product, UX, full-stack development, AI/RAG, and deployment
Key features delivered
- One-click AI scope check with exact, page-cited quotes; a person makes every final decision
- Multi-document RAG: page-aware chunking plus hybrid search (Postgres full-text + pgvector, RRF), with the contract always kept in full context
- Quote verification: every quote is checked word for word against the exact source it cites; unsupported answers are rejected
- Scope import from PDF, Word, or public links (Google Docs supported), with SSRF-safe server fetching
- Change orders that version the contract, plus AI client replies that cannot invent numbers
- Printable decision log (PDF) with quotes, change orders, and full scope history
Impact
- Live in production at scopecheck.hamzaabubakar.dev
- 0 unverified quotes shown: answers with any quote that is not in its source are rejected
- Handles contracts up to 60,000 characters and up to 10 supporting documents of 200,000 characters each per project
- Daily AI allowance per user (10 checks by default) to keep costs predictable
- Tested with unit, API, browser (Playwright), and retrieval-eval suites
Stack
- Next.Js
- PostgreSQL
- OpenAI
- Vercel
- Typescript
Challenges
- Keeping AI answers trustworthy. Models paraphrase, so "quotes" can be invented. Every quote is now checked against the exact source it cites, and a definitive answer needs at least one quote from the contract itself.
- RAG without missing the clause that matters. Searching a contract in chunks can miss an exclusion. The contract is always sent in full; retrieval is used only for supporting documents, and only when they are too large to send in full.
- Mixing keyword and semantic search. Full-text and vector scores are on different scales, so they are merged with reciprocal rank fusion instead of a tuned weight. If embeddings are unavailable, keyword search still works.
- Fetching user-supplied links safely. Link import blocks private and internal addresses, re-checks every redirect, and caps size and time, so it cannot be abused to reach internal services (SSRF).
- Keeping history correct. Accepting a change order updates the contract and records a new version in one locked transaction, and earlier AI checks are flagged as outdated.
Screenshots
Product highlights
A few focused screens that show the core flow and UI polish.




