Skip to main content
Glama

query_bitmap_memory_usage

Read-only

Retrieve bitmap memory usage percentiles (P50/P90/P99) and distinct users by device, process, and app state to diagnose memory pressure and correlate with LMK rates.

Instructions

Query bitmap memory usage percentiles: bitmapMemoryUsageP50/P90/P99 (bytes) plus distinctUsers. Also supports P75 and P95 via metrics, and the processName and appState dimensions (e.g. FOREGROUND) on top of the usual device dimensions. Pair with query_lmk_rate when investigating memory pressure. Daily aggregation only.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "start_date": "<start_date>",
      "end_date": "<end_date>"
    },
    "name": "query_bitmap_memory_usage"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMax rows to return (default: 50)
filterNoAIP-160 filter over dimensions, e.g. "versionCode = 415"
metricsNoMetrics to fetch (default: bitmapMemoryUsageP50, bitmapMemoryUsageP90, bitmapMemoryUsageP99, distinctUsers)
end_dateYesEnd date (inclusive) as YYYY-MM-DD, e.g. '2026-08-13'
dimensionsNoBreak the metrics down by these dimensions, e.g. ['versionCode','deviceModel']
start_dateYesStart date (inclusive) as YYYY-MM-DD, e.g. '2026-08-01'
package_nameNoApp package name, e.g. 'com.acme.app' (defaults to GOOGLE_PLAY_PACKAGE_NAME)
aggregation_periodNoAggregation granularity — this metric set only supports DAILY

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.4.0
    • removedInput schema / additionalProperties
      Removed value: -false
  2. Addedv0.3.0

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and openWorldHint=true, so the safety profile is covered. The description adds some behavioral context — output units are bytes, P75/P95 are reachable only via the metrics parameter, and aggregation is restricted to DAILY — but these largely restate schema constraints rather than disclosing anything new about rate limits, pagination, or result shape.

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?

Three tight sentences that lead with the core metric set and follow with extensions, pairing guidance, and the aggregation constraint. Some content (DAILY-only, default metric list) duplicates the schema, so it is slightly redundant but never padded.

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?

For an 8-parameter read-only query tool with no output schema, the description covers what is returned, the unit of measure, the extra dimensions, and the aggregation limitation. It leaves the filter syntax and limit behavior entirely to the schema, which already documents both adequately.

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 100%, so baseline would be 3, but the description genuinely adds meaning: it tells the agent that additional percentiles (P75, P95) are obtained through the metrics parameter and that processName/appState are available as extra dimensions beyond the default device set, including the FOREGROUND example for appState.

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?

The description names a specific verb and resource ('Query bitmap memory usage percentiles') and enumerates the exact metrics returned (bitmapMemoryUsageP50/P90/P99 plus distinctUsers), so the agent knows precisely what data this yields. It does not explicitly distinguish itself from the close sibling query_memory_usage, which keeps it short of a 5.

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 gives a concrete investigation context ('Pair with query_lmk_rate when investigating memory pressure') and a hard constraint ('Daily aggregation only'), which steers tool selection. It stops short of stating when NOT to use this tool or naming the general memory sibling as the alternative to prefer in other cases.

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