Skip to main content
Glama

Get Longest Trip On Single Charge

get_longest_trip_on_single_charge

Identify the longest distance a Tesla has driven between two consecutive charges. Use it to analyze maximum range and efficiency for a specific vehicle.

Instructions

Find the longest distance driven between two consecutive charges.

Uses window functions on charging_processes to define charge windows, then sums drives within each window to find the record.

Returns JSON with: record_distance_km, start_time, end_time, start_battery_pct, arrival_battery_pct, battery_consumed_pct, efficiency_comment.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
car_idNoFilter by vehicle ID (default: TESLA_CAR_ID env or first car)

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.2/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 burden. It partially compensates by disclosing the computation (window functions on charging_processes) and the returned fields, but it does not say whether this is a read-only aggregate, what permissions/defaults apply, or how cost is measured across gaps.

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-loaded with the core result, followed by the method and the return fields. Slightly padded by the implementation detail about window functions, which is interesting but not necessary for invocation.

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?

An output schema exists, yet the description redundantly enumerates return fields rather than trusting the schema. Combined with clear purpose and full parameter coverage, an agent has enough to call it correctly; the missing piece is any note on read-only safety or empty-result behavior.

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

Parameters3/5

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

Schema description coverage is 100% and the single car_id parameter is fully documented in the schema, including its default resolution behavior. The description adds no parameter meaning beyond that, which matches the baseline for full schema coverage.

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

Purpose4/5

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

States a precise verb and resource with a differentiating constraint: the distance must be 'between two consecutive charges', which separates it from generic trip aggregations. However, it never names or contrasts with the sibling 'tesla_longest_trips', leaving that overlap ambiguous.

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?

There is no explicit when-to-use guidance, no prerequisites, and no reference to an alternative tool. Usage is only implied by the purpose sentence, which is thin given several overlapping sibling tools.

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