get_rules_for_tool
Retrieves the organization's coding standards and best practices rules for a tool.
WHEN TO CALL: Before writing or modifying ANY code. You MUST call this after get_tools
and before implementing changes. Do NOT skip this step — without it you cannot report
compliance correctly.
tool_id: MUST be one of the tool_id values returned by get_tools(). Do NOT guess or invent.
Returns the ruleset with rule IDs. Each rule has an ID — you MUST use these exact IDs
in register_applied_actions. Never use "N/A" or invent rule IDs.
After completing your coding task, call register_applied_actions with rule_id values
taken ONLY from this response (verified_compliant, violations_fixed, violations_prevented).
get_tools
Provides the list of linting/coding tools for the project's tech stack.
WHEN TO CALL: At the START of any coding task (new feature, bug fix, refactor, file edit).
Also when the user asks to fix compliance, apply rules, or align with standards.
MANDATORY FLOW (do not skip steps):
1) get_tools first (this call)
2) get_rules_for_tool(tool_id) for EACH relevant tool_id from this response — NEVER skip this
3) Apply rules to your code, then call register_applied_actions
Returns tool_id, name, version, ruleset_ids. Use ONLY the exact tool_id values from this
response when calling get_rules_for_tool. Without get_rules_for_tool you cannot know the
actual rules or their IDs, and you cannot correctly call register_applied_actions.
register_applied_actions
Registers the actions you took to comply with the organization's rules.
WHEN TO CALL: After completing ANY coding task where you consulted rules via get_rules_for_tool.
CRITICAL — rule_id: Every item (verified_compliant, violations_fixed, violations_prevented)
MUST have rule_id set to an exact rule ID from the get_rules_for_tool response. NEVER use
"N/A", "unknown", or invent rule IDs. If you did not call get_rules_for_tool, you cannot
fill this correctly — call get_tools → get_rules_for_tool first, then report.
STRUCTURE: llm_name and llm_version identify the model; verified_compliant (file_path, rule_id,
comments); violations_fixed (file_path, rule_id, start_line, end_line, issue_description,
fix_applied); violations_prevented (file_path, rule_id, comments). Rule-related fields in English.