Skip to main content
Glama

save_execution_alignment

Preview or apply an execution-plan alignment: validates roadmap phases, changes, and evidence, then requires explicit user confirmation before updating the career profile.

Instructions

预览或应用执行方案校准(用户确认是硬门禁)。

何时调用:完成 plan_execution_alignment 后,LLM 设计了执行版路线图与变更清单。

校验纪律(代码执行,LLM 不可绕过):

  • requirement_profile_id 必须存在,且与当前档案需求链路一致;

  • roadmap.phases 非空,每个 phase 有 name/goal,milestones/tasks 结构合法;

  • 每条 change 的 type 合法且 evidence_ids 非空——没有证据的变更不允许落库;

  • diff_summary 必填。

Args: alignment_json: 校准方案 JSON 字符串,Schema: { "requirement_profile_id": "rp_...", "strategy_summary": "执行版整体策略", "roadmap": { "strategy_summary": "与顶层一致", "phases": [ { "type": "learn/project/intern/research", "name": "阶段名", "goal": "阶段目标", "kpi": {"metric": "", "target": "", "evidence": ""}, "milestones": [ { "name": "里程碑", "done_criteria": "", "tasks": [{"name": "", "description": "", "priority": "high"}] } ] } ] }, "changes": [ { "type": "add_task/modify_task/remove_task/reorder_tasks/" "modify_phase/add_phase/remove_phase/reorder_phases", "phase_id": "", "task_id": "", "details": {"name": ""}, "reason": "", "evidence_ids": ["JD001"] } ], "diff_summary": "本次校准的差异摘要" } confirmed: 用户是否已确认应用。false 只保存预览 artifact,返回 diff 与 确认提示,不修改档案;true 才替换 profile.plan、维护 plan_history / adjustments / core_state 并刷新职业地图。

返回 JSON(字符串): - confirmed=false: status=needs_confirmation,含 baseline/proposed 概览、 changes、保留/移除任务清单与确认提示; - confirmed=true: status=ok,含应用摘要、execution_plan_id、map_path、 next_steps(get_next_tasks / generate_tasks)。

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": {
      "alignment_json": "<alignment_json>"
    },
    "name": "save_execution_alignment"
  }
}

Input Schema

NameRequiredDescriptionDefault
confirmedNo
alignment_jsonYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

A4.9/5.0
Behavior5/5

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

With no annotations supplied, the description carries the full burden and does so: it discloses that validation is code-enforced and cannot be bypassed by the LLM, lists the specific invariants (non-empty phases, legal change types, mandatory evidence_ids and diff_summary), and states exactly what false does (preview artifact only, no profile mutation) versus true (replaces profile.plan, maintains plan_history/adjustments/core_state, refreshes the career map).

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?

Well front-loaded: purpose and gating rule first, then trigger condition, then validation discipline, then argument schema, then return shapes. The inline JSON schema is long but unavoidable since the input schema declares alignment_json as an opaque string, so length is earned rather than padded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a two-mode mutation tool with a nested JSON payload, everything an agent needs is present: prerequisite, gating semantics, validation constraints, the exact payload shape, and both return states including status values and the next recommended tools (get_next_tasks / generate_tasks). An output schema exists, and the description still adds the confirmation-prompt and baseline/proposed detail.

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?

Schema coverage is 0% and the parameters are only typed as boolean/string, so the description must supply all meaning — and it does, defining confirmed's two behaviors and fully expanding the nested alignment_json structure (roadmap.phases, milestones, tasks, changes with enumerated type values, evidence_ids). This adds substantial semantics the schema alone could never convey.

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 opening line states a concrete verb and resource ('预览或应用执行方案校准') and immediately flags the hard confirmation gate. It also positions the tool relative to its predecessor ('完成 plan_execution_alignment 后'), so an agent can distinguish the design step from the persistence step without opening any schema.

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

Usage Guidelines5/5

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

The '何时调用' line gives an explicit trigger condition (after plan_execution_alignment, once a roadmap and change list exist). The confirmed=false/true split spells out two distinct operating modes and their consequences, which functions as when-to-use versus when-to-preview guidance.

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