Skip to main content
Glama

save_gap_analysis

Saves completed gap-analysis JSON after an analysis task finishes, storing match scores, skill gaps, resume fixes, and action plans for later career planning.

Instructions

保存差距分析结果。

何时调用:在 analyze_gaps 返回分析任务,LLM 完成分析后调用此工具保存结果。

Args: gap_json: 差距分析的 JSON 字符串

Schema(与 sop/resume_screening.yaml 的 output_schema 一致——以该 YAML 为唯一权威): { "match_score": 65, // 匹配度评分(0-100) "match_level": "partial_match", "start_level": "小厂", // 起点层级:大厂/中厂/小厂/暂不可入(路线图使用) "strengths": [ // 优势(对象数组) { "area": "前端开发", // 领域 "description": "1年经验", // 描述 "resume_highlight": "...", // 可选:简历怎么写 "interview_talk": "..." // 可选:面试怎么讲 } ], "resume_red_flags": [ // 简历负面信号(可选但强烈建议提供) { "signal": "代码主要 AI 生成", // 负面信号 "risk": "现场手撕代码站不住", // 风险说明 "evidence_fix": "补 2 个完整手写项目" // 补证据动作 } ], "resume_optimization": { // 简历过筛维度 "ats_keywords": ["Python", "Agent"], "missing_keywords": ["RAG"], "highlight_projects": [ {"project": "...", "how_to_package": "...", "quantified_result": "..."} ], "resume_tips": ["..."], "missing_experiences": [ {"experience": "...", "how_to_create": "..."} ] }, "interview_preparation": { // 面试通过维度 "must_prepare": [ {"topic": "...", "type": "八股|项目|场景", "priority": "high", "estimated_time": "...", "prepare_advice": "..."} ], "project_deep_dive": [ {"project": "...", "likely_questions": ["..."], "key_points": ["..."], "star_story": "S:... T:... A:... R:..."} ], "system_design_topics": [{"topic": "...", "framework": "..."}], "behavioral_questions": [{"question": "...", "story_template": "..."}], "study_plan": {"unit_1": ["..."], "unit_2": ["..."]} // 学习单元(不排时间,不用 week) }, "skill_gaps": [ // 技能差距(对象数组) { "skill": "TypeScript", "priority": "high", // high/medium/low "current_level": "无", "required_level": "熟练", // 注意:字段名是 required_level "is_hidden": false, // 可选:true 表示 JD 未写但实际考核 "how_to_improve": "...", "source": "BOSS直聘 JD" // 数据来源,必填 } ], "priority_actions": [ // 优先行动项(对象数组) {"action": "学习 TypeScript 基础", "timeline": "...", "impact": "...", "difficulty": "..."} ], "market_context": "..." // 市场背景(来自真实抓取数据汇总) }

硬校验:skill_gaps 非空时每项必须带非空 skill 与 source(来源真实), 缺失返回 INVALID_PARAM 且不写入档案;空 skill_gaps 允许保存。

内容建议(不阻断保存):skill_gaps 为空、red_flags 字段不完整、 AI 作者身份未在 red_flags 提及、未知字段——都会作为 advisories 返回并持久化, 由 LLM 与用户决定是否补充。

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": {
      "gap_json": "<gap_json>"
    },
    "name": "save_gap_analysis"
  }
}

Input Schema

NameRequiredDescriptionDefault
gap_jsonYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does so well: it discloses the hard validation rule (skill_gaps entries must have non-empty skill and source, otherwise INVALID_PARAM and nothing is written to the profile), that empty skill_gaps is allowed, and that softer issues return advisories that are persisted without blocking the save. Remaining gaps are overwrite/idempotency semantics and permission or state prerequisites, which it never addresses.

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?

It is front-loaded with a one-line purpose and a when-to-call line before any payload detail, which is good structure for a long definition. The embedded JSON contract is dense but each field carries a downstream constraint the agent must satisfy, so the length is largely earned; the inline comments and repeated emphasis on '不阻断保存' are the only mildly redundant parts.

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 a single-parameter tool whose parameter is a complex structured payload, a full field-level contract plus validation and advisory behavior is close to complete, and the output schema means return values need no explanation. The one real hole is state semantics — it never says whether saving replaces prior gap analysis, nor what happens if no analysis was ever produced — and it defers ultimate authority to an external YAML the agent may not have, though it does reproduce that schema inline.

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 covers 0% — it only declares gap_json as an untyped string. The description compensates completely by spelling out the entire JSON contract: every field, which are required vs. optional, enum-like values (high/medium/low, 大厂/中厂/小厂), the explicit note that the field name is required_level, and that study_plan uses unit_1/unit_2 rather than weeks. This is far more meaning than the input schema provides.

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 first line states a specific verb+resource (保存差距分析结果 / save gap-analysis result), and the '何时调用' line anchors it to a precise point in the workflow: after analyze_gaps returns an analysis task and the LLM finishes reasoning. That distinguishes it unambiguously from the sibling that produces the analysis rather than persisting it.

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 an explicit trigger condition (call after analyze_gaps returns and the LLM completes analysis), which is a clear when-to-use instruction. It stops short of naming when NOT to call — e.g. whether re-calling overwrites a previous save, or whether it is valid to call without a prior analyze_gaps run — so no exclusion criteria are present.

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