> For the complete documentation index, see [llms.txt](https://docs.roboflow.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.roboflow.com/datasets/hi/manage/manage-datasets/dataset-search.md).

# डेटासेट खोजें

Roboflow में डेटासेट को बेहतर समझने के लिए टेक्स्ट-आधारित खोज क्वेरी और फ़िल्टर का उपयोग करें।

## के बारे में

Dataset search आपको फ़ाइल-नाम लुकअप, संरचित फ़िल्टर (tags, splits, classes, dimensions, annotation counts), बूलियन लॉजिक, और प्राकृतिक-भाषा semantic search का उपयोग करके पूरे प्रोजेक्ट में विशिष्ट images खोजने देता है। इसका उपयोग अपने डेटा का audit करने, गलत लेबल किए गए या missing annotations को सामने लाने, और review या export के लिए targeted subsets बनाने में करें। वही queries web app और search REST API दोनों में उपलब्ध हैं।

## वेब ऐप

आप Roboflow में image files को file name, search query, और queries तथा filters को मिलाकर specific images खोजने और अपने data को बेहतर समझने के लिए search कर सकते हैं।

* **एक निश्चित tag वाले split में images:**\
  `tag:factory split:train`\
  यह tag filter और split filter का उपयोग करता है
* **semantic search और class filter का उपयोग करके missing labels खोजें**:\
  `person -class:helmet`\
  यह semantic search और class filter पर inverted filter का उपयोग करता है
* **यदि किसी class वाली सभी images को एक निश्चित filter की आवश्यकता हो:**\
  `class:helmet AND NOT (tag:v1 OR tag:v2)`\
  यह class filter, boolean logic, और tag filters का उपयोग करता है
* **कम annotations वाली चौड़ी images खोजें:**\
  `min-width:1000 max-annotations:1`\
  यह minimum width filter और max annotation count filter का उपयोग करता है

की पूरी सूची देखें [search filters](#search-filters) , साथ ही नीचे दिए गए उदाहरण भी

{% hint style="info" %}
आप इन सभी search filters और queries को एक साथ जोड़ सकते हैं
{% endhint %}

### Semantic Search

आप images को उनका वर्णन करके search कर सकते हैं। ये queries आपकी search terms से सबसे अधिक संबंधित images को खोजेंगी और उन images को भी खोजने में मदद कर सकती हैं, जब objects अभी labeled न हों।

Semantic search तब होता है जब आप बिना किसी filter selector के एक text query दर्ज करते हैं (जैसे: `filename:`)

<figure><img src="https://2706998663-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNVfRxNsvCh4GOyqrjmzX%2Fuploads%2Fgit-blob-252e7735b8f04fdeb7b567c8a73c783ba42c7ba0%2Fimage%20(355).png?alt=media" alt=""><figcaption></figcaption></figure>

### File Name से Search करें

आप `filename:` filter या file name textbox का उपयोग करके file names search कर सकते हैं, जो आपके लिए query बनाएगा।

<figure><img src="https://2706998663-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNVfRxNsvCh4GOyqrjmzX%2Fuploads%2Fgit-blob-007ef7663b94243be3a88de95df3a6fe6345bf5f%2Fimage%20(354).png?alt=media" alt="" width="192"><figcaption></figcaption></figure>

### Dataset Split के अनुसार Search करें

dataset split (train, valid, test) के आधार पर images search करें

<figure><img src="https://2706998663-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNVfRxNsvCh4GOyqrjmzX%2Fuploads%2Fgit-blob-42804a6e68a1551a7f23c0fe1746da8231fb5b02%2Fimage%20(356).png?alt=media" alt="" width="257"><figcaption></figcaption></figure>

images को किसी अलग split में फिर से assign करने के लिए, उन्हें चुनें (या search से "Select all matching" चुनें) और bulk actions menu में "Change Dataset Split" पर क्लिक करें। बड़े selections background में process होते हैं।

### Upload Date के अनुसार Search करें

Roboflow पर पहली बार upload की गई date के आधार पर images filter करें, इसके लिए `date:` filter का उपयोग करें। Upload date immutable होती है और image edit, re-annotate, या splits के बीच move होने पर नहीं बदलती।

का उपयोग करें `date:YYYY-MM-DD` किसी exact day के लिए, या range search करने के लिए comparison operators को मिलाएँ:

`date>=2026-01-01 date<2026-02-01`

### Search Filters

यहाँ उपलब्ध filters हैं:

* `like-image:<IMAGE_ID>`: image content के आधार पर semantic search
* `tag` : user द्वारा दिए गए tags के आधार पर filter करें।
* `filename` : दिए गए file name से मेल खाने वाले file names के लिए search चलाता है। आंशिक match चलाने के लिए query की शुरुआत और अंत में \* का उपयोग करें।
* `split` : split (train, test, valid) के आधार पर filter करता है।
* `job:<JOB_ID>` : दिए गए job ID वाली images दिखाता है।
* `min-width:X` : X से अधिक width वाली images दिखाता है।
* `max-width:X` : X से कम width वाली images दिखाता है।
* `min-height:X` : X से अधिक height वाली images दिखाता है।
* `max-height:X` : X से कम height वाली images दिखाता है।
* `min-annotations:X` : निर्दिष्ट संख्या से अधिक annotations वाली images को filter करता है।
* `max-annotations:X` : निर्दिष्ट संख्या से कम annotations वाली images दिखाता है।
* `class:CLASS`: ऐसी images दिखाता है जिनमें दिए गए label के साथ कम से कम 1 annotation हो।
* `date:YYYY-MM-DD` : उस immutable date के आधार पर filter करता है जब image upload की गई थी। comparison operators को support करता है (जैसे: `date>=2026-01-01 date<2026-02-01`).

#### Boolean Logic

AND, OR, NOT, और parentheses का उपयोग करके कई filters को जोड़ें और जटिल queries बनाएँ।

`class:helmet AND NOT (tag:v1 OR tag:v2)`

#### Inverted Filters

filter से मेल खाने वाली images को exclude करने के लिए filter से पहले minus sign जोड़ें।

`class:helmet -class:vest`

#### Numeric Class Filters

किसी image में labeled items की संख्या के आधार पर filter करें।

`class:helmet=3 class:vest>=4`

### API

आप Roboflow पर अपने dataset और images को भी [Search API](#http-api).

## HTTP API

आप REST API का उपयोग करके Roboflow पर hosted images search कर सकते हैं। दो endpoints हैं: एक project-scoped `/:workspace/:project/search` endpoint, और एक workspace-wide `/:workspace/search/v1` endpoint जो [web app dataset search](#web-app).

### प्रोजेक्ट में Images Search करें

Roboflow पर hosted images search करने के लिए, निम्न API endpoint पर POST request भेजें:

```url
https://api.roboflow.com/:workspace/:project/search
```

API के लिए एक उदाहरण request यहाँ है:

```bash
curl -X POST "https://api.roboflow.com/my-workspace/my-project-name/search?api_key=$ROBOFLOW_API_KEY" \
-H 'Content-Type: application/json' \
--data \
'{
    "like_image": "image_id",
    "in_dataset": true,
    "limit": 125
}'
```

यह endpoint POST body में निम्न values स्वीकार करता है:

```json
{
     // दिए जाने पर, semantic similarity के अनुसार sort किए गए results देता है
     "like_image": string,
     
     // दिए जाने पर, semantic similarity के अनुसार sort किए गए results देता है
     "prompt": string,
     
     // default 0
     "offset": int,
     
     // default 50 (max: 250)
     "limit": int,
     
     // मौजूद होने पर, दिए गए tag वाली images को filter करता है
     "tag": string,
     
     // मौजूद होने पर, दिए गए class name वाली images को filter करता है
     "class_name": string,
     
     // true होने पर, URL से project में मौजूद images को filter करता है
     "in_dataset": boolean,
     
     // मौजूद होने पर, केवल उन images को लौटाता है जो किसी भी batch में हैं
     "batch": boolean,
     
     // मौजूद होने पर, केवल दिए गए batch में मौजूद images लौटाता है
     "batch_id": string,

     // मौजूद होने पर, केवल वे images लौटाता है जो किसी annotation job में हैं
     "annotation_job": boolean,

     // मौजूद होने पर, केवल दिए गए annotation job में मौजूद images लौटाता है
     "annotation_job_id": string,
     
     // लौटाने के लिए fields निर्दिष्ट करें, default ["id", "created"] है
     // विकल्प हैं ["id", "name", "annotations", "labels", "split", "tags", "owner", "url", "embedding", "created"]
     "fields": string[]
}
```

Search API निम्न संरचना के साथ एक response लौटाएगा। उपलब्ध values आपके द्वारा निर्दिष्ट अतिरिक्त `fields` पर निर्भर करेंगी:

```json
{
    "offset": 0,
    "total": 292,
    "results": [
        {
            "id": "image123",
            "name": "humpbackwhale.jpg",
            "owner": "owner123",
            "url": "https://source.roboflow.com/owner123/image123/original.jpg",
            "annotations": {
                "count": 5,
                "classes": {
                    "whale": 1,
                    "fish": 4
                }
            },
            "labels": [],
            "tags": [
                "cam_x13"
            ]
        }
        // ... आदि.
    ]
}
```

### Workspace के Across Images Search करें

Workspace Image Search API आपको अपने workspace के भीतर images सूचीबद्ध करने और search करने देता है।

इस API के साथ, आप filter, sort, और semantic searches कर सकते हैं, एक query string का उपयोग करके जो इसके समान है [Roboflow web application की image search feature](#web-app).

#### Endpoint

API पर request करने के लिए, एक `POST` request निम्न endpoint पर भेजें:

```
https://api.roboflow.com/{WORKSPACE}/search/v1?api_key=API_KEY
```

जहाँ `WORKSPACE` आपका Workspace ID है, और `API_KEY` आपकी API key है।

[अपना Workspace ID कैसे खोजें, जानें](https://docs.roboflow.com/reference/authentication/authentication/workspace-and-project-ids).

[अपनी API key कैसे खोजें, जानें।](https://docs.roboflow.com/reference/platform/rest-api/authenticate-with-the-rest-api)

#### Authentication

API तक पहुँचने के लिए, आपको request में अपनी API key शामिल करनी होगी। API key को query parameter के रूप में pass किया जाना चाहिए।

उदाहरण: `?api_key={YOUR_API_KEY}`

#### Request Format

**Headers**

* `Content-Type: application/json`

**Body Parameters**

* `query` **(required)**: फ़िल्टर, sort, या semantic search करने के लिए एक non-empty string। उदाहरण के लिए: `"nighttime project:{my-project-url}"` images को `my-project-url` project में filter करेगा और उन images के लिए semantic sort लागू करेगा जो मेल खाती हैं `nighttime`. यदि missing या empty हो तो 400 error लौटाता है।
* `pageSize`: प्रति page लौटाए जाने वाले results की संख्या (default: 50).
* `fields`: response में शामिल करने के लिए fields की सूची। संभावित values हैं `"tags"`, `"width"`, `"height"`, `"filename"`, `"aspectRatio"`, `"split"`, `"projects"`, `"annotations"`, `"labels"`, `"owner"`, `"url"`.

**उदाहरण Request**

```bash
curl --location 'https://api.roboflow.com/{WORKSPACE}/search/v1?api_key={API_KEY}' \
--header 'Content-Type: application/json' \
--data '{
    "query": "project:foo nightime",
    "pageSize": 10,
    "fields": ["tags", "width", "height", "filename", "aspectRatio", "split"]
}'

```

#### Response Format

response एक JSON object है जिसमें निम्न fields शामिल हैं:

* `results`: image objects की एक array।
* `total`: मिली हुई images की कुल संख्या।
* `continuationToken`: pagination के लिए एक token।

**Image Object Fields**

fields पर निर्भर करते हुए जो `fields` parameter में अनुरोध किए गए हैं:

* `id`: image का unique identifier।
* `projectData`: project URL द्वारा keyed object, जिसमें project-specific data शामिल है:
  * `split`: dataset split को इंगित करता है (जैसे, "test"). तब लौटाया जाता है जब `"split"` is in `fields`.
  * `inDataset`: Boolean जो बताता है कि image dataset में है या नहीं। तब लौटाया जाता है जब `"projects"` is in `fields`.
  * `annotations`: इस project में image के लिए annotation data, जिसमें शामिल है `annotationGroup`, `classes` , और `classCounts`. तब लौटाया जाता है जब `"annotations"` is in `fields`.
  * `labels`: इस project में image के लिए label data। तब लौटाया जाता है जब `"labels"` is in `fields`.
* `tags`: image से जुड़े tags की array।
* `width`: pixels में image की चौड़ाई।
* `height`: pixels में image की ऊँचाई।
* `filename`: image file का नाम।
* `aspectRatio`: image का aspect ratio।
* `owner`: image का owner identifier।
* `url`: मूल image file का direct URL।

**Pagination और `continuationToken`**

The `continuationToken` response में लौटाया गया token आपको search result से मेल खाने वाले pages के बीच scroll करने देता है। जब `continuationToken` को किसी subsequent request में शामिल किया जाता है, तो यह results का अगला set fetch करता है।

का उपयोग करने के लिए `continuationToken`, इसे अपनी अगली API call के request body में शामिल करें। इससे आपके मूल query के आधार पर results का अगला page प्राप्त होगा।

**Error Responses**

* `400` - तब लौटाया जाता है जब `query` missing या empty हो, या जब एक `project:` filter आपके workspace से संबंधित नहीं किसी project को संदर्भित करता हो।
* `500` - आंतरिक सर्वर त्रुटि।

**Project और Dataset Filters**

में उपलब्ध सभी filters के अतिरिक्त [app में dataset search](#web-app) , workspace-wide search भी `project` और `dataset` के लिए filters का समर्थन करता है। उदाहरण के लिए आप ऐसा query उपयोग कर सकते हैं जैसे `project:foo project:bar` उन सभी images को खोजने के लिए जो दोनों projects में हैं `foo` और `bar`.\
\
ऐसी query जैसे `dataset:foo`project में images लौटाएगी `foo` जिन्हें labeled किया गया है और project में dataset में जोड़ा गया है।

## Python SDK

`Project.search_all()` project की images में search results का एक paginated iterator लौटाता है। Search modes को मिलाया जा सकता है: class द्वारा सीमित text prompt, single batch तक सीमित existing-image similarity search, आदि।

```python
import roboflow

rf = roboflow.Roboflow(api_key="YOUR_API_KEY")
project = rf.workspace().project("my-detector")

records = []
for page in project.search_all(
    prompt="mug on a desk",
    class_name="mug",
    in_dataset=True,
    limit=100,
    fields=["id", "created", "name", "labels"],
):
    records.extend(page)

print(len(records))
```

### Parameters

* `prompt` (str, optional) - प्राकृतिक-भाषा search prompt (CLIP embeddings के माध्यम से semantic search)।
* `like_image` (str, optional) - text के बजाय visual similarity से search करने के लिए image id।
* `tag` (str, optional) - केवल इसी tag वाली images।
* `class_name` (str, optional) - केवल वे images जिनमें इस class में annotation है।
* `in_dataset` (bool, optional) - क्या results को project के dataset में मौजूद images तक सीमित करना है, batch / annotation-job staging areas को छोड़कर।
* `batch` (bool, optional) और `batch_id` (str, optional) - किसी specific upload batch तक सीमित करें।
* `annotation_job` (bool, kw-only) और `annotation_job_id` (str, kw-only) - किसी specific annotation job तक सीमित करें।
* `offset` (int, default `0`) - pagination offset।
* `limit` (int, default `100`) - page size।
* `fields` (list\[str], optional) - response size कम करने के लिए प्रति result केवल सूचीबद्ध fields माँगें।

`search_all()` यह एक जनरेटर है - प्रत्येक पुनरावृत्ति अधिकतम `limit` परिणाम, और offset को स्वतः आगे बढ़ाता है। एक बार के एकल-पृष्ठ कॉल के लिए, उपयोग करें `project.search(...)` उसी तर्कों के साथ।

### वर्कस्पेस-व्यापी खोज

वर्कस्पेस में हर परियोजना में खोजने के लिए, उपयोग करें `Workspace.search()` / `Workspace.search_all()`. परियोजना-वार विधियों के विपरीत, ये एक एकल RoboQL `query` स्ट्रिंग (उदाहरण के लिए `"class:forklift"`, `"tag:review"`, या सिमेंटिक CLIP खोज के लिए मुक्त पाठ) तथा वैकल्पिक `page_size` और `fields`. प्रत्येक उत्पन्न पृष्ठ परिणाम पंक्तियों की एक सूची है, और पंक्तियों में स्रोत परियोजना एक `projects` फ़ील्ड के अंतर्गत शामिल होती है।

```python
records = []
for page in rf.workspace().search_all(query="class:forklift"):
    records.extend(page)
```

### खोज परिणामों को डाउनलोड योग्य डेटासेट के रूप में निर्यात करें

`Workspace.search_export()` एक खोज चलाता है और परिणामों को डाउनलोड योग्य डेटासेट (COCO / YOLO / VOC आदि) के रूप में पैकेज करता है। देखें [डेटा निर्यात (REST)](/datasets/hi/versions/dataset-versions/exporting-data.md#http-api) अंतर्निहित एंडपॉइंट के लिए।

```python
path = rf.workspace().search_export(
    query="forklift",
    format="coco",
    location="./forklift-search",
)
print(path)
```

## CLI

आप अपने वर्कस्पेस में छवियों को खोजने के लिए उपयोग कर सकते हैं [RoboQL](/datasets/hi/manage/manage-datasets/dataset-search.md) और वैकल्पिक रूप से मिलते-जुलते परिणामों को डाउनलोड योग्य डेटासेट के रूप में निर्यात कर सकते हैं।

### खोज

```bash
roboflow search "<query>"
```

#### विकल्प

| ध्वज       | विवरण                                                   |
| ---------- | ------------------------------------------------------- |
| `--limit`  | लौटाए जाने वाले अधिकतम परिणाम (डिफ़ॉल्ट: 50)            |
| `--cursor` | पेजिनेशन के लिए निरंतरता टोकन                           |
| `--fields` | शामिल करने के लिए फ़ील्ड की अल्पविराम से अलग की गई सूची |

#### उदाहरण

एक विशिष्ट टैग वाली छवियों को खोजें:

```bash
roboflow search "tag:reviewed"
```

एक विशिष्ट वर्ग वाली छवियों को खोजें:

```bash
roboflow search "class:person" --limit 100
```

### खोज परिणाम निर्यात करें

जोड़ें `--export` मिलती-जुलती छवियों को डेटासेट के रूप में डाउनलोड करने के लिए:

```bash
roboflow search "<query>" --export -f <format> -l <location>
```

#### निर्यात विकल्प

| ध्वज                       | विवरण                                       |
| -------------------------- | ------------------------------------------- |
| `--export`                 | निर्यात मोड सक्षम करें                      |
| `-f`, `--format`           | एनोटेशन प्रारूप (डिफ़ॉल्ट: coco)            |
| `-l`, `--location`         | निर्यात को सहेजने के लिए स्थानीय निर्देशिका |
| `-d`, `--dataset`          | एक विशिष्ट परियोजना तक सीमित करें           |
| `-g`, `--annotation-group` | एक विशिष्ट एनोटेशन समूह तक सीमित करें       |
| `--name`                   | निर्यात के लिए वैकल्पिक नाम                 |
| `--no-extract`             | ज़िप फ़ाइल रखें, निष्कर्षण छोड़ें           |

#### उदाहरण

सभी समीक्षा की गई छवियों को COCO प्रारूप में निर्यात करें:

```bash
roboflow search "tag:reviewed" --export -f coco -l ./reviewed-export
```

एक विशिष्ट परियोजना से छवियों को YOLOv8 प्रारूप में निर्यात करें:

```bash
roboflow search "class:car" --export -d my-project -f yolov8 -l ./cars
```

### JSON आउटपुट

```bash
roboflow search "tag:reviewed" --json
```

```json
{
  "results": [...],
  "total": 42,
  "cursor": "next-page-token"
}
```

का उपयोग करें `cursor` पेजिनेशन के लिए मान:

```bash
roboflow search "tag:reviewed" --cursor "next-page-token" --json
```

## MCP सर्वर

अपने AI एजेंट को इससे जोड़ें [MCP सर्वर](https://docs.roboflow.com/agents/mcp-server) और यह इन टूल्स से छवियाँ खोज सकता है:

<table data-search="false"><thead><tr><th width="290">टूल</th><th>विवरण</th></tr></thead><tbody><tr><td><code>images_search</code></td><td>किसी परियोजना के अंदर छवियाँ खोजें।</td></tr><tr><td><code>images_workspace_search</code></td><td>RoboQL का उपयोग करके पूरे वर्कस्पेस में छवियाँ खोजें।</td></tr></tbody></table>
