Skip to main content
Glama

update_schema_incremental

Update an entity type's schema by adding or removing fields or changing its identity rule. Creates and activates a new schema version for new data, with optional migration.

Instructions

Incrementally update a schema by adding fields (fields_to_add — minor version bump), removing fields (fields_to_remove — major version bump; observation data preserved, snapshot-excluded until re-added), or changing the identity rule (canonical_name_fields — major version bump). Creates a new schema version and activates it immediately, so all new data stored after this call uses the updated schema. Optionally migrates existing raw_fragments to observations for historical data backfill.

canonical_name_fields re-keys how the type derives canonical_name / identity. Rules are ordered precedence with fallback — the first rule whose fields are all present wins, e.g. [{composite:["linkedin_url"]},"email","name"] keys on linkedin_url, else email, else name. Reach for it when same-name-different-entity collisions appear (e.g. a bulk import collapses distinct people who share a name because identity resolves on name alone). The existing reducer_config is preserved automatically, so this is the safe way to re-key without a full register_schema re-supply. Applies to NEW writes only — it does not retroactively re-key existing entities, so it will not by itself merge existing duplicates. Omit to keep the current rule; pass [] to clear it (succeeds only if the schema also declares identity_opt_out). The response echoes the resolved canonical_name_fields; call describe_entity_type first to see the current rule before replacing it.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
user_idNoUser ID for user-specific schema (required if user_specific=true)
activateNoActivate schema immediately so it applies to new data (default: true). If false, schema is registered but not active.
entity_typeYesEntity type to update
fields_to_addNoFields to add to schema
user_specificNoCreate user-specific schema variant (default: false)
schema_versionNoNew schema version (auto-increments if not provided)
fields_to_removeNoField names to remove from schema (triggers major version bump). Observation data is preserved; fields can be restored by re-adding them later.
migrate_existingNoMigrate existing raw_fragments to observations for historical data backfill (default: false). Note: New data automatically uses updated schema after activation, migration is only for old data.
canonical_name_fieldsNoReplace the entity type's identity rule (how canonical_name / entity identity is derived). Triggers a major version bump. Each item is a single field name (string) or an all-required composite ({composite:[...]}). Rules are ORDERED PRECEDENCE WITH FALLBACK: the resolver uses the first rule whose fields are all present, not an unordered set. Example: [{"composite":["linkedin_url"]},"email","name"] keys on linkedin_url when present, else email, else name. Omit to keep the current rule. Passing [] clears the rule, but only succeeds when the schema also declares identity_opt_out; otherwise it is rejected (a schema must declare canonical_name_fields OR identity_opt_out). The existing reducer_config is preserved automatically — this is the safe way to re-key a type without reconstructing it. Applies to NEW writes only; it does NOT retroactively re-key existing entities (they keep their stored canonical_name until re-derived), so re-keying will not by itself merge existing duplicates. To see the current rule before replacing it, call describe_entity_type first; the update response also echoes the resolved canonical_name_fields.
Behavior5/5

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

With no annotations, the description carries the full burden and does so thoroughly: it discloses that activation is immediate, existing observation data is preserved and snapshot-excluded, migration is optional, existing reducer_config is preserved, re-keying does not retroactively merge duplicates, and passing [] clears only when identity_opt_out is declared. These are exactly the non-obvious behavioral traits an agent needs to know.

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 longer than average, but justified by the tool's complexity (9 parameters, nuanced identity rules). It front-loads the core purpose in the first paragraph and then detains on canonical_name_fields in a well-separated second paragraph. Every sentence carries information; the length is a function of necessary detail rather than padding.

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

Completeness5/5

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

Given no output schema and 9 parameters, the description is remarkably complete. It covers activation, migration, version-bump behavior, identity-rule semantics, edge cases (clearing rule, identity_opt_out), and the non-retroactive nature. It does not need to describe return values because no output schema is provided, but it does mention the response echoes canonical_name_fields.

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

Parameters5/5

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

Although the input schema already covers all parameters (100% coverage), the description adds significant operational meaning beyond the schema. For canonical_name_fields it explains ordered precedence with a concrete example ([{composite:['linkedin_url']},'email','name']), the collision scenario, and the 'safe way' framing. It also ties fields_to_add/remove to version bump semantics, which is not in the schema.

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 opens with 'Incrementally update a schema' and enumerates three distinct operations (adding fields, removing fields, changing identity rule), each with explicit version-bump consequences. This clearly distinguishes it from siblings like register_schema, and the text even contrasts it: 'safe way to re-key without a full register_schema re-supply.'

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?

It provides a concrete use case: 'Reach for it when same-name-different-entity collisions appear' and cautions that re-keying applies to new writes only. It names an alternative (register_schema) and instructs to call describe_entity_type first, but does not explicitly list exclusions (e.g., when a full re-registration is required).

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/markmhendrickson/neotoma'

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