Skip to main content
Glama
sifter-ai

sifter-mcp

Official

run_extraction

Trigger extraction process for a document using a specific sift to convert unstructured content into structured, queryable data.

Instructions

Enqueue extraction for a document on a specific sift.

Args:
    document_id: The document identifier
    sift_id: The sift to extract with

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
document_idYes
sift_idYes

Implementation Reference

  • The core handler function for the run_extraction MCP tool. It gets a sift handle by ID and calls extract() on it with the given document_id to enqueue extraction.
    @mcp.tool()
    async def run_extraction(document_id: str, sift_id: str) -> dict:
        """Enqueue extraction for a document on a specific sift.
    
        Args:
            document_id: The document identifier
            sift_id: The sift to extract with
        """
        async with _get_client() as client:
            handle = await client.get_sift(sift_id)
            return await handle.extract(document_id)
  • The MCP server instance (FastMCP) that the @mcp.tool() decorator registers the run_extraction function with.
    mcp = FastMCP("sifter", streamable_http_path="/", stateless_http=True, transport_security=_transport_security)
  • The Zapier action definition for run_extraction, performing a POST to /api/sifts/{sift_id}/extract with the document_id.
    const actionRunExtraction = {
      key: "run_extraction",
      noun: "Extraction",
      display: {
        label: "Run Extraction",
        description: "Trigger extraction of a document against a sift.",
      },
      operation: {
        inputFields: [
          { key: "sift_id", label: "Sift", dynamic: "sift_choices.id.name", required: true },
          { key: "document_id", label: "Document ID", required: true },
        ],
        perform: async (z, bundle) => {
          const resp = await z.request({
            method: "POST",
            url: `${apiUrl(bundle)}/api/sifts/${bundle.inputData.sift_id}/extract`,
            headers: headers(bundle),
            body: { document_id: bundle.inputData.document_id },
          });
          return resp.data;
        },
        sample: { task_id: "sample-task-id", status: "queued" },
      },
    };
  • Registration of the run_extraction action in the Zapier app module exports under the 'actions' object.
    [actionRunExtraction.key]: actionRunExtraction,
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden but only states it 'enqueues' without explaining behavior like whether the operation is asynchronous, potential side effects, or required permissions. Critical behavioral context is missing.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is short and to the point, but it could be more concise by integrating parameter descriptions. It is front-loaded with the action, but the docstring format introduces redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema, no annotations, and only two parameters, the description fails to provide sufficient context for an agent to confidently use the tool. Missing details about return values, error states, or expected behavior limit completeness.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, and the description merely repeats parameter names ('document_id', 'sift_id') without adding definitions, formats, or examples. The agent gains no additional insight beyond the parameter titles.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Enqueue extraction') and the specific resources ('document on a specific sift'). It effectively distinguishes from sibling tools like 'get_extraction_status' which retrieves results rather than initiates them.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives, prerequisites, or conditions. The description does not mention scenarios where extraction should not be run or any required prior steps.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/sifter-ai/sifter'

If you have feedback or need assistance with the MCP directory API, please join our Discord server