Skip to main content

Squillify development is paused indefinitely. Read why, and discover what this experiment achieved. Read the story

MicroSkills Reference

Filter Rows

data.filter_rows

ProductionBounded custom (Class B)Deterministicstrictfastv1.0.0
No network

Overview

When you send tabular rows and a filter expression, we return only the rows that match — using a safe, compiled language (comparisons, AND/OR/NOT, string checks, in/not-in, null tests). No scripting, no user-supplied regex, no reflection. Do not use this for full SQL semantics or arbitrary code execution.

Row filtering by an LLM is slow and inconsistent. You get the same matches every time for the same rows and expression.

Reliability

STRICT and deterministic for identical rows, schema hints, nullPolicy, and expression. Validation errors (not retryable — fix input): INVALID_EXPRESSION (syntax or unsupported operator — rewrite the filter); LIMIT_EXCEEDED (expression nesting, string literal, or in-list too large — simplify); SIZE_LIMIT_EXCEEDED (filter string over 1,000,000 characters); row count over 100,000; nullPolicy error_on_null when a null is compared. When limit is reached, truncated is true.

Context footprint

Returns matched rows, matchedCount, scannedCount, truncated, and ok. A successful call costs 1 execution credit.

When to use it

When you already have row objects and a predicate expressible in the safe DSL.

When you need SQL joins, window functions, or arbitrary scripting.

Scope

Note
Keeps row objects that match a safe, compiled filter expression.

Non-goals

  • Does not execute code, SQL, or JavaScript
  • Does not sort or aggregate rows
  • Does not fetch data from files or URLs
  • Does not accept user-supplied regular expressions

Properties

IdempotentRetry safeStreaming supportedFile input supportedRequires external service

Capabilities

data-transformation

Cost & billing

Flat rate per invocation

MetercallsBillable onsuccessCost per call1 credit

File handling

Accepts file_refProduces file_refMax input976.6 KB

How we handle your data

Sensitive output possible
What this means

This skill may receive sensitive content and may return submitted, transformed, extracted, or reformatted content.

Squillify guarantees
  • Runs inside Squillify
  • This skill runs inside Squillify.
  • Payloads are not sent to an external service by this skill.
  • Squillify does not permanently store submitted payloads.
  • Telemetry records metadata only, not submitted content.
  • Submitted payloads are not used for training.
  • Submitted payloads are not reviewed by humans.
  • This skill does not target sensitive data.
  • The response may contain submitted or transformed content.
Your responsibility

Squillify does not determine whether submitted content is sensitive. Your application is responsible for deciding what data it is allowed to submit. Your application is responsible for securing the response.

Read the Microskill Data Handling Policy

Input schema

FieldTypeRequiredDescription
rowsarrayYesBounded array of 0 through 100000 input row objects keyed by column name, where missing keys count as null.
filterstringYesSafe compiled filter expression over column names.
schemaobjectNoPurpose-bound map from column name to a type hint; omit it to infer types from values.
nullPolicystringNoHow null comparisons behave; omit it for false_on_null.
caseSensitivebooleanNoWhether string comparison is case-sensitive; omit it for true.
limitintegerNoMaximum matched rows to return; omit it for 100000.

Output schema

FieldTypeRequiredDescription
okbooleanYesTrue when filtering completed successfully.
rowsarrayYesBounded array of 0 through 100000 result row objects keyed by column name after this skill transformed the table.
matchedCountintegerYesHow many rows are returned in rows.
scannedCountintegerYesHow many input rows were examined before any early stop.
truncatedbooleanYesWhether the limit stopped collection before every match was returned.

API contract

POST /v1/execute
curl
curl -sS -X POST "$BASE/v1/execute" -H "Authorization: Bearer $KEY" -H 'Content-Type: application/json' -d '{"skillKey":"data.filter_rows","input":{"rows":[{"id":1,"country":"BE","amount":150},{"id":2,"country":"FR","amount":200}],"filter":"country = \"BE\" AND amount >= 100"}}'
Integrations
TypeScript SDK
import { Squillify } from "@squillify/sdk";

const sq = new Squillify({ apiKey: process.env.SQUILLIFY_API_KEY });

const { output } = await sq.execute("data.filter_rows", {"filter":"country = \"BE\" AND amount >= 100","rows":[{"amount":150,"id":1,"country":"BE"},{"amount":200,"id":2,"country":"FR"}]});

Errors

CodeHTTPRetryableDescription
VALIDATION_ERROR400NoThe request payload failed schema validation.
UNAUTHORIZED401NoMissing or invalid API key.
SKILL_NOT_ACCESSIBLE403NoThe API key is not granted access to this skill.
SKILL_NOT_AVAILABLE_FOR_PLAN403NoThis skill is not included in your current plan.
PLAN_ELIGIBILITY_UNAVAILABLE503YesPlan eligibility could not be decided. Retry after backoff.
SKILL_NOT_FOUND404NoThe requested skill or version does not exist.
TENANT_RATE_LIMITED429YesRequest rate limit exceeded. Retry after backoff.
QUOTA_EXCEEDED429YesPlan quota exhausted. Retryable once the quota period resets.
EXECUTION_TIMEOUT504YesExecution exceeded the allowed time budget.

Other limits

LimitValue
Recommended inline bytes32 KiB

Limitations

  • Does not execute code, SQL, or JavaScript
  • Does not sort or aggregate rows
  • Does not fetch data from files or URLs
  • Does not accept user-supplied regular expressions
  • Full SQL join/group semantics
  • Fuzzy or regex-from-input matching
  • Filtering more than 100,000 rows in one call

How to call

POST /v1/execute (requires authentication)

Request bodyjson
{
  "skillKey": "data.filter_rows",
  "input": {
    "filter": "country = \"BE\" AND amount >= 100",
    "rows": [
      {
        "amount": 150,
        "id": 1,
        "country": "BE"
      },
      {
        "amount": 200,
        "id": 2,
        "country": "FR"
      }
    ]
  }
}

Examples

Belgian orders over 100

Inputjson
{
  "filter": "country = \"BE\" AND amount >= 100",
  "rows": [
    {
      "amount": 150,
      "id": 1,
      "country": "BE"
    },
    {
      "amount": 200,
      "id": 2,
      "country": "FR"
    }
  ]
}
Expected outputjson
{
  "ok": true,
  "matchedCount": 1,
  "scannedCount": 2,
  "truncated": false,
  "rows": [
    {
      "country": "BE",
      "id": 1,
      "amount": 150
    }
  ]
}

Open or pending status via in list

Inputjson
{
  "filter": "status in [\"open\", \"pending\"]",
  "rows": [
    {
      "status": "open",
      "id": 1
    },
    {
      "status": "closed",
      "id": 2
    }
  ]
}
Expected outputjson
{
  "ok": true,
  "matchedCount": 1,
  "scannedCount": 2,
  "truncated": false,
  "rows": [
    {
      "status": "open",
      "id": 1
    }
  ]
}
  • Filter API or CSV rows before export
  • Select rows before aggregation
  • Apply a deterministic WHERE-style predicate in an agent pipeline

Avoid for

  • Full SQL join/group semantics
  • Fuzzy or regex-from-input matching
  • Filtering more than 100,000 rows in one call

Composable with

Safety & privacy

  • Runs without calling any external service.
  • Your payloads are never stored permanently.
  • Telemetry captures metadata only — never your payload contents.
  • We never train models on your payloads.
  • No human reviews your payloads.

Tags

transformationfilterdata