Skip to main content
Glama

get_flow_matrix

Generate a host-pair communication matrix from a PCAP file, showing packet and byte totals per source-destination pair. Optionally apply a display filter and limit to top N pairs.

Instructions

Build a host-pair communication matrix showing traffic volume.

Extracts ip.src, ip.dst, and frame.len fields from packets, then aggregates by (src, dst) pair sorted by total bytes descending.

Args: file_path: Path to the PCAP file display_filter: Optional display filter (e.g. "not arp") top_n: Number of top host pairs to return (default: 20)

Returns: Ranked table of host pairs with packet count and byte totals

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
top_nNo
file_pathYes
display_filterNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It clearly explains the aggregation logic (group by src/dst, sort by total bytes descending) and identifies the specific fields used, giving the agent a good sense of what happens during execution, though it omits edge-case behavior like handling missing files or empty results.

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 clear sections for Args and Returns, and the prose is efficient. The first paragraph and second paragraph share some redundancy (both mention aggregation), but the extra detail about field extraction and sorting is valuable and not excessive.

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?

The description covers the tool's purpose, parameters, and return value, making it functionally complete for invocation. It lacks explicit usage guidelines versus sibling tools, which is a minor gap, but given the output schema exists and the description provides all necessary details, it is overall complete.

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?

The schema has 0% description coverage, but the description compensates fully by providing a dedicated Args section that explains each parameter with concrete details (e.g., file_path is a PCAP, display_filter example 'not arp', top_n default 20). This exceeds the schema's sparse structure and gives the agent complete parameter understanding.

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 clearly states it builds a host-pair communication matrix showing traffic volume, with specific details about extracting ip.src, ip.dst, and frame.len fields. This distinguishes it from sibling tools like get_packet_statistics or aggregate_flows by focusing on host-pair aggregation and byte totals.

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

Usage Guidelines3/5

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

The description implies usage for analyzing host-pair traffic volume but does not explicitly state when to use this tool over alternatives. No exclusions or comparative guidance are provided, leaving the agent to infer based on the tool's name and description.

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/ouonet/tshark-mcp'

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