### GET /tile/{article_id}/{tile_index}/{chunk_index} Source: https://pixelrag.ai/docs Fetch the screenshot for a specific tile using its article ID, tile index, and chunk index. ```APIDOC ## GET /tile/{article_id}/{tile_index}/{chunk_index} ### Description Fetch the screenshot for a specific tile. Pass the `article_id`, `tile_index`, and `chunk_index` obtained from a search result to get the tile's PNG image. ### Method GET ### Endpoint /tile/{article_id}/{tile_index}/{chunk_index} ### Parameters #### Path Parameters - **article_id** (integer) - Required - The ID of the article. - **tile_index** (integer) - Required - The index of the tile. - **chunk_index** (integer) - Required - The index of the chunk. ### Response #### Success Response (200) - **Image** (binary) - The PNG image data for the tile. ### Response Example (Returns a binary PNG image) ``` -------------------------------- ### GET /status Source: https://pixelrag.ai/docs Get the current status of the PixelRAG index, including configuration details. ```APIDOC ## GET /status ### Description Get the index status and configuration of the PixelRAG system. ### Method GET ### Endpoint /status ### Parameters None ### Response #### Success Response (200) (Details of the response body are not specified in the source, but it is expected to contain status and configuration information.) ``` -------------------------------- ### Fetch Specific Tile Screenshot Source: https://pixelrag.ai/docs Retrieve a tile's screenshot using its unique identifiers. This is the final step to get the visual content after a successful search. ```bash # Fetch a tile screenshot from the results curl https://pixelrag.ai/api/tile/698618/0/0 --output tile.png ``` -------------------------------- ### GET /health Source: https://pixelrag.ai/docs Perform a health check on the PixelRAG API. ```APIDOC ## GET /health ### Description Health check endpoint for the PixelRAG API. ### Method GET ### Endpoint /health ### Parameters None ### Response #### Success Response (200) (Typically returns a status indicating the API is healthy, e.g., 'OK' or a JSON object with a health status.) ``` -------------------------------- ### Text-Only Search for Tiles Source: https://pixelrag.ai/docs Initiate a search using only a text query to find relevant tiles. This is a fundamental step for agents to understand user intent. ```bash # Text-only search curl -X POST https://pixelrag.ai/api/search \ -H "Content-Type: application/json" \ -d '{"queries": [{"text": "When was the Eiffel Tower built?"}], "n_docs": 5}' ``` -------------------------------- ### Search for Tiles with Text Query Source: https://pixelrag.ai/docs Use this snippet to find tiles matching a natural-language question. Specify the number of documents to return. ```bash # 1 — search with a text query curl -X POST https://pixelrag.ai/api/search \ -H "Content-Type: application/json" \ -d '{"queries": [{"text": "How does photosynthesis work?"}], "n_docs": 5}' # → hits[0] = { "article_id": 5878188, "tile_index": 1, "chunk_index": 0, ... } ``` -------------------------------- ### POST /search Source: https://pixelrag.ai/docs Search for tiles matching a text query, an image, or a combination of both. Returns a list of matching tiles with their article, tile, and chunk indices. ```APIDOC ## POST /search ### Description Find matching tiles by sending a natural-language question or an image. Each hit comes back with `article_id`, `tile_index`, and `chunk_index`. ### Method POST ### Endpoint /search ### Parameters #### Request Body - **queries** (array) - Required - An array of query objects. Each object can contain: - **text** (string) - Optional - A natural-language query. - **image** (string) - Optional - A base64-encoded image. - **n_docs** (integer) - Optional - The number of documents to return. ### Request Example ```json { "queries": [ { "text": "How does photosynthesis work?" } ], "n_docs": 5 } ``` ### Response #### Success Response (200) - **hits** (array) - A list of matching tile objects, each containing: - **article_id** (integer) - The ID of the article. - **tile_index** (integer) - The index of the tile within the article. - **chunk_index** (integer) - The index of the chunk within the tile. #### Response Example ```json { "hits": [ { "article_id": 5878188, "tile_index": 1, "chunk_index": 0 } ] } ``` ``` -------------------------------- ### Fetch Tile Screenshot Source: https://pixelrag.ai/docs Retrieve the screenshot for a specific tile using the article ID, tile index, and chunk index obtained from a search result. The output is saved to a file named 'tile.png'. ```bash # 2 — fetch that hit's screenshot curl https://pixelrag.ai/api/tile/5878188/1/0 --output tile.png ``` -------------------------------- ### Search for Tiles with Image Query Source: https://pixelrag.ai/docs Find tiles that are visually similar to an input image. The image must be base64-encoded and sent inline within the JSON payload. ```bash # 3 — or search with an image: base64-encode any local file inline curl -X POST https://pixelrag.ai/api/search \ -H "Content-Type: application/json" \ -d "{\"queries\": [{\"image\": \"$(base64 < photo.jpg | tr -d '\n উপেক্ষা')\"}], \"n_docs\": 5}" ``` -------------------------------- ### Image-Only Search for Visual Similarity Source: https://pixelrag.ai/docs Conduct a search based solely on visual similarity to an input image. The image must be base64 encoded. ```bash # Image-only search (visual similarity) curl -X POST https://pixelrag.ai/api/search \ -H "Content-Type: application/json" \ -d "{\"queries\": [{\"image\": \"$(base64 < photo.jpg | tr -d '\n উপেক্ষা')\"}], \"n_docs\": 5}" ``` -------------------------------- ### Hybrid Search with Text and Image Source: https://pixelrag.ai/docs Perform a joint multimodal retrieval by combining both text and image queries in a single request. This is useful for queries like 'what is this X?'. ```bash # 4 — hybrid: combine text + image in one query (joint multimodal retrieval) curl -X POST https://pixelrag.ai/api/search \ -H "Content-Type: application/json" \ -d "{\"queries\": [{\"text\": \"impressionist oil painting\", \"image\": \"$(base64 < photo.jpg | tr -d '\n উপেক্ষা')\"}], \"n_docs\": 5}" ``` -------------------------------- ### Joint Image and Text Search Source: https://pixelrag.ai/docs Combine image and text queries for a more precise search, particularly effective for identifying specific objects or scenes described by text. ```bash # Joint image + text search (best for "what is this X?") curl -X POST https://pixelrag.ai/api/search \ -H "Content-Type: application/json" \ -d "{\"queries\": [{\"image\": \"$(base64 < photo.jpg | tr -d '\n উপেক্ষা')\", \"text\": \"landmark building\"}], \"n_docs\": 5}" ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.