Skip to main content
Glama
MOmayr
by MOmayr

vector_execute

Embed text and write the resulting vector into a PostgreSQL vector or halfvec column. Supports inserting a new row or updating existing rows from literal text or a text column.

Instructions

Insert or update a vector/halfvec column by embedding text. insert: embed text (optional fields, optional persist via text_column). update: write only the vector. Source is text (single row: id, or where that matches one row) or text_column (embed each matched row, where/id, optional limit). Use execute for delete and non-vector columns.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNoupdate: single row
textNoLiteral to embed. Required for insert. For update, exactly one of text or text_column.
limitNoupdate + text_column: max rows (default 10, max 100)
tableYes
whereNoupdate: SQL WHERE fragment (no WHERE keyword)
fieldsNoinsert only: other column values
schemaNoDefault: public
id_columnNoDefault: id
operationYesinsert or update
text_columnNoinsert: also store `text` in this varchar. update: read this column per row and embed it.
embedding_columnYesvector or halfvec column to write

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.3

TDQS

A4/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full behavioral burden. It usefully discloses the single-row constraint for id/where and that update overwrites the vector column, but says nothing about reversibility, permission requirements, what happens when where matches multiple rows in insert mode, or the return shape. Adequate but leaves real operational risk undocumented.

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?

Front-loads the core action, then dispatches insert vs update in compact clauses. The telegraphic style is efficient but occasionally cryptic ('update: write only the vector'), trading readability for density.

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

Completeness3/5

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

With 11 parameters, no annotations, and no output schema, the description must cover behavior and results. It handles operation modes and source selection well, but omits the return/effect signal (rows affected) and error behavior, leaving gaps for a mutation tool of this complexity.

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

Parameters4/5

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

Schema coverage is 91%, so the baseline is 3, and the description adds genuine value beyond it by explaining parameter interactions: exactly one of text/text_column for update, and the id-vs-where single-row rule. It does not add much on `fields`, `schema`, or `id_column`, which remain schema-only.

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?

States a specific verb (insert/update) and resource (vector/halfvec column) and the mechanism (embedding text). It explicitly carves out the sibling boundary: 'Use execute for delete and non-vector columns', so an agent can distinguish it from execute and query without opening a schema.

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

Usage Guidelines4/5

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

Gives clear mode-selection guidance: insert requires `text` and optionally persists via `text_column`; update reads from `text` (single row via id or where) or `text_column` (per-row, with optional limit). It also names the alternative tool for out-of-scope operations. No explicit exclusions or prerequisites (permissions, row-count safety) beyond the tool routing.

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