{
 "schema_version": 1,
 "generated": "2026-10-20",
 "id": "fengzhenfei-carrel--answer-contract-questions-with-citations",
 "repo": "FengZhenfei/carrel",
 "repo_url": "https://github.com/FengZhenfei/carrel",
 "repo_slug": "fengzhenfei-carrel",
 "title": "Answer contract questions with cited passages",
 "page_title": "How to answer contract questions with cited passages with Carrel",
 "summary": "Index a folder of contracts and let an agent pull the clauses it needs before it answers.",
 "who": "A legal, procurement, or operations person who needs quick answers about delivery, acceptance, or payment terms across many contract files.",
 "problem": "Finding the right clause across many PDFs and Word files is slow, and an agent without the files will invent terms.",
 "outcome": "The agent returns answers grounded in retrieved contract passages, with the source text available for review.",
 "steps": [
  "Run `./deploy.sh` from the cloned Carrel folder and wait for the first startup to finish downloading parser models.",
  "Copy the contract files into `runtime/mirror/<contracts-folder>/` and enable that folder in the console at http://127.0.0.1:9800.",
  "Check service health and task progress in the console before your first query.",
  "Run `curl -sS http://127.0.0.1:9810/search -H 'Content-Type: application/json' -d '{\"question\": \"What are the delivery and acceptance requirements?\", \"top_k\": 8}'` to test retrieval. (inferred, check the README)"
 ],
 "agent_prompt": "Use the Carrel search API in the FengZhenfei/carrel repo at http://127.0.0.1:9810/search to find the clauses about <contract term> across the enabled contract folder. Report each answer with the source passage it came from. Verify that every claim in the answer appears in a returned passage.",
 "agents": [
  "any"
 ],
 "difficulty": "Intermediate",
 "time": "90 minutes",
 "basis": "readme",
 "caveat": "Carrel does not state that its answers are legally reliable, so a person should check any clause before relying on it.",
 "category": "Research",
 "tags": [
  "Research"
 ],
 "lang": "python",
 "requirements": [
  "Linux, macOS with Docker Desktop, or Windows through WSL2 (native Windows is not supported)",
  "Python 3.12+ and Docker 25+ with Compose v2",
  "A text embedding endpoint and a vision-language endpoint, either local or hosted",
  "A chat model if you want knowledge graphs",
  "Optional: an NVIDIA GPU with NVIDIA Container Toolkit for the local model stack"
 ],
 "risk": "sensitive",
 "seen_in_the_wild": false,
 "mentioned_publicly": false,
 "risks": [
  {
   "tag": "credentials",
   "notice": "If you enable LAN access, set both KB_WEB_HOST and KB_WEB_TOKEN and set KB_SEARCH_TOKEN before using protected search endpoints remotely, since contracts are confidential."
  }
 ],
 "best": false,
 "score": 0.9,
 "evidence": [],
 "url": "https://dedupedai.com/use-cases/fengzhenfei-carrel/answer-contract-questions-with-citations/",
 "md": "https://dedupedai.com/use-cases/fengzhenfei-carrel/answer-contract-questions-with-citations/index.md",
 "disclaimer": "Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked \"Seen in the wild\", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email hello@dedupedai.com and we will look at it promptly.",
 "api": "https://dedupedai.com/api/v1/usecases/fengzhenfei-carrel--answer-contract-questions-with-citations.json",
 "api_version": "v1"
}
