# 1. Ground an LLM Answer in Bharat Judgments & Statutes
> Combine hybrid case search with pre-extracted ratio decidendi, statutory lookup, and citator standing checks.
Source URL: /docs/recipes/ground-llm-bharat

**Problem:** An LLM drafting a legal research summary must anchor every proposition in real Bharat judgments and Central Act sections while confirming that none of the cited cases have been overruled.

| Step | Endpoint | Scope | Credits |
|---|---|---|---|
| 1. Hybrid case search + pre-extracted intelligence | `POST /api/v1/in/cases/search` | `corpus:read` | 2 |
| 2. Hybrid statute search | `POST /api/v1/in/statutes/search` | `corpus:read` | 2 |
| 3. Live citator standing check | `GET /api/v1/in/cases/{id}/citator` | `corpus:read` | 2 |

## Implementation [#implementation]

<Tabs items={["cURL","Python (vidhi)","TypeScript (@vidhi/sdk)","Go CLI (vidhi)"]}>
<Tab value="cURL">
```bash
# 1. Search judgments with pre-extracted ratio_decidendi
curl -sS -X POST https://api.vidhi.shamik.app/api/v1/in/cases/search \
  -H "Authorization: Bearer $VIDHI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "query": "unilateral appointment of sole arbitrator ineligible section 12(5)",
    "forum_type": "supreme_court",
    "include_intelligence": true,
    "limit": 3
  }'

# 2. Search matching Central Statute sections
curl -sS -X POST https://api.vidhi.shamik.app/api/v1/in/statutes/search \
  -H "Authorization: Bearer $VIDHI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"query": "ineligibility of arbitrator Seventh Schedule", "limit": 3}'

# 3. Verify later court treatment on the top case ID
curl -sS https://api.vidhi.shamik.app/api/v1/in/cases/40812/citator \
  -H "Authorization: Bearer $VIDHI_API_KEY"
```
</Tab>

<Tab value="Python (vidhi)">
```python
from vidhi import Vidhi

client = Vidhi()
cases = client.cases.search(
    query="unilateral appointment of sole arbitrator ineligible section 12(5)",
    forum_type="supreme_court",
    include_intelligence=True,
    limit=3,
)
statutes = client.statutes.search(
    query="ineligibility of arbitrator Seventh Schedule",
    limit=3,
)
top_case = cases.items[0]
citator = client.citations.citator(top_case.id)

print(top_case.id, top_case.ratio_decidendi)
print("Later treatment:", citator.later_court_treatment.status)
print("Statute hit:", statutes.items[0].act_code, statutes.items[0].section_number)
```
</Tab>

<Tab value="TypeScript (@vidhi/sdk)">
```ts
import { VidhiClient } from "@vidhi/sdk";

const client = new VidhiClient({ apiKey: process.env.VIDHI_API_KEY! });

const [cases, statutes] = await Promise.all([
  client.cases.search({
    query: "unilateral appointment of sole arbitrator ineligible section 12(5)",
    forum_type: "supreme_court",
    include_intelligence: true,
    limit: 3,
  }),
  client.statutes.search({
    query: "ineligibility of arbitrator Seventh Schedule",
    limit: 3,
  }),
]);

const topCase = cases.items[0];
const citator = await client.citations.citator(topCase.id);
console.log({
  caseId: topCase.id,
  ratio: topCase.ratio_decidendi,
  standing: citator.later_court_treatment.status,
  statute: statutes.items[0],
});
```
</Tab>

<Tab value="Go CLI (vidhi)">
```bash
vidhi search "unilateral appointment of sole arbitrator ineligible section 12(5)" \
  --forum-type supreme_court --intelligence --limit 3 --json
vidhi statute search "ineligibility of arbitrator Seventh Schedule" --limit 3 --json
vidhi case citator 40812 --json
```
</Tab>
</Tabs>

## Verified Response Excerpts [#verified-response-excerpts]

```json
{
  "items": [
    {
      "id": "40812",
      "title": "Perkins Eastman Architects DPC v. HSCC (India) Ltd.",
      "court_code": "SC",
      "court_name": "Supreme Court of India",
      "forum_type": "supreme_court",
      "year": 2019,
      "citation": "(2020) 20 SCC 760",
      "score": 0.9412,
      "ratio_decidendi": "A person having an interest in the outcome of the dispute is ineligible under Section 12(5) to unilaterally appoint a sole arbitrator.",
      "key_findings": ["Unilateral appointment by an interested party violates Section 12(5) read with Seventh Schedule."]
    }
  ],
  "next_cursor": "eyJzY29yZSI6MC45NDEyLCJpZCI6NDA4MTJ9",
  "has_more": true,
  "total": null,
  "total_is_exact": false
}
```