Skip to main content
Glama
Johnhyeon

StockLens

by Johnhyeon

get_flow_batch

Retrieve institutional and foreign net buying data for up to 30 stock codes in a single parallel request, enabling efficient comparison of investor flows across multiple stocks.

Instructions

수급벌크 — 여러 종목의 투자자 수급(기관·외국인 순매매)을 한 번에 병렬 조회.

개별 get_flow를 N번 부르는 것보다 훨씬 빠릅니다 (서버 내부 asyncio.gather). "이 종목들 외국인 매수 같이 들어왔나", "관심종목 수급 비교" 같은 질문에 사용.

Args: codes: 종목코드 리스트 (최대 30개) days: 종목당 조회 일수 (기본 5, 최대 20). 토큰 절감 위해 단일 도구보다 짧음

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codesYes
daysNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

The description discloses that the tool uses server-side parallel execution (asyncio.gather) and that the default days parameter is shorter than the single tool to save tokens. No annotations are provided, so the description carries the full burden; it covers key behavioral aspects without raising concerns.

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 reasonably concise, with a clear first paragraph for purpose and performance, and a second paragraph for parameters. The Korean title '수급벌크 —' could be trimmed, but overall the structure is efficient and front-loaded.

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?

Given that an output schema exists (reducing the need to explain return values), the description covers purpose, performance, parameters, and usage examples. It could mention error handling for exceeding the 30-code limit, but for a simple batch query tool, it is sufficiently 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?

With 0% schema description coverage, the description fully compensates by explaining that `codes` is a list of stock codes with a maximum of 30, and `days` defaults to 5 with a maximum of 20, also noting the token-saving rationale for the shorter default. This adds significant meaning beyond the schema's titles.

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 that the tool batch queries investor flow (institutional/foreign net trading) for multiple stocks in parallel. It explicitly differentiates from the sibling `get_flow` by highlighting performance benefits (using asyncio.gather internally).

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 provides concrete example questions where the tool should be used, such as comparing flow across stocks. It mentions that it is faster than calling `get_flow` N times, but does not explicitly state when to prefer the individual tool over this batch variant. However, the context is clear enough.

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/Johnhyeon/stocklens-mcp'

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