Skip to main content
Glama

import_character_matrix

Import a character-matrix CSV to create a TreeData object for lineage reconstruction. The CSV must contain cell IDs and integer character states with sentinel values for missing and unmodified states.

Instructions

Import a character-matrix CSV into a new TreeData, ready for reconstruction.

The CSV must have cell ids in the first column and one column per character; integer states, with missing_state for dropout and unmodified_state for the uncut state. The matrix is stored in obsm[characters_key].

Args: csv_path: Absolute path to the character-matrix CSV. characters_key: obsm key to store the matrix under (default "characters"). missing_state: Sentinel for missing/dropout entries (default -1). unmodified_state: Sentinel for the uncut/unmodified state (default 0).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
csv_pathYes
missing_stateNo
characters_keyNocharacters
unmodified_stateNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
n_obsYesNumber of observations (cells/leaves).
treesNoKeys in tdata.obst.
layersNo
n_varsYesNumber of variables (e.g. genes).
sourceNoOrigin path or generator.
uns_keysNo
obsm_keysNo
dataset_idYes
obs_columnsNo
Behavior3/5

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

No annotations are provided, so the description must carry the behavioral disclosure burden. It mentions the matrix is stored in obsm[characters_key] and that the data is 'ready for reconstruction', but does not detail side effects (e.g., overwriting), error conditions, or performance characteristics. The description is moderately transparent but lacks depth for a tool with no annotations.

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 well-structured with a clear sentence for the main purpose, followed by a paragraph on CSV format requirements, and an Args section for parameters. It is focused and front-loaded. However, the Args section could be integrated into the schema to reduce redundancy, but given the lack of schema descriptions, it earns its place.

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

Completeness4/5

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

With an output schema present (not shown but context indicates true), the description need not explain return values. It covers input format, storage location, and sentinel meanings. It lacks explicit error handling or prerequisite checks, but overall provides sufficient context for an import tool.

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?

Schema coverage is 0%, so the description compensates fully by listing all four parameters with explanations: csv_path (absolute path), characters_key (obsm key with default), missing_state and unmodified_state (sentinels with defaults). This adds significant meaning beyond the schema's type and default values.

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 uses a specific verb ('import') and resource ('character-matrix CSV into a new TreeData'), clearly distinguishing it from sibling tools like simulate_characters or reconstruct_tree. It also states the purpose is 'ready for reconstruction', adding context.

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?

The description explains the required CSV format (cell ids, columns per character, integer states, sentinels) and the mapping to data storage (obsm[characters_key]). While it doesn't explicitly state when to use vs alternatives, the context implies this is for importing external data, contrasting with simulation or reconstruction tools.

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/colganwi/lineageverse-mcp'

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