Skip to main content
Glama

ppm_risk_mark_occurred

Mark a risk as occurred to update its status in the project risk register, confirming the risk event has happened.

Instructions

Mark a risk as occurred.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
risk_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The MCP tool handler function. Takes a risk_id, calls the Odoo action 'action_mark_occurred' on the ppm.risk model, then reads and returns the updated risk state fields.
    @mcp.tool()
    def ppm_risk_mark_occurred(risk_id: int) -> dict[str, Any]:
        """Mark a risk as occurred."""
        client().call_action("ppm.risk", "action_mark_occurred", [risk_id])
        return _read_state("ppm.risk", risk_id, _RISK_FIELDS)
  • Registration as an MCP tool via the @mcp.tool() decorator on line 240, making it available in the FastMCP server named 'qod-ppm'.
    @mcp.tool()
    def ppm_risk_mark_occurred(risk_id: int) -> dict[str, Any]:
  • Schema: list of fields read back from the risk record after the action, used by the handler to return the updated state.
    _RISK_FIELDS = [
        "name",
        "state",
        "risk_type",
        "probability",
        "impact",
        "risk_score",
        "risk_level",
        "project_id",
        "owner_id",
    ]
  • Helper function that reads and returns the specified fields of a record; used by the handler to return the updated risk after marking occurred.
    def _read_state(model: str, rec_id: int, fields: list[str]) -> dict[str, Any]:
        rows = client().read(model, [rec_id], fields)
        if not rows:
            raise ValueError(f"{model} id={rec_id} not found")
        return rows[0]
  • The OdooClient.call_action method used by the handler to invoke 'action_mark_occurred' on the ppm.risk model.
    def call_action(self, model: str, method: str, ids: list[int]) -> Any:
        """Invoke an `action_*` button method on the given record ids."""
        return self.execute_kw(model, method, [ids])
Behavior2/5

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

No annotations are provided, so the description must disclose behavior. It only states 'mark as occurred' without explaining side effects, persistence, permissions, or whether the action is reversible. This is insufficient for a state mutation tool.

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 a single sentence with no wasted words. However, it sacrifices detail for brevity, leaving significant gaps. It is concise but not optimally informative.

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

Completeness2/5

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

Given the presence of an output schema (unknown content), one parameter, and many sibling tools, the description fails to provide lifecycle context, return value hints, or differentiation. The agent lacks a complete understanding of when and how to invoke this tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% for the only parameter (risk_id), and the description adds no meaning beyond the schema. The agent gets no guidance on what risk_id represents or how to obtain it.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action 'mark a risk as occurred', identifying a specific verb and resource. It differentiates from sibling tools like ppm_risk_close or ppm_risk_reopen by focusing on the 'occurred' state transition.

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

Usage Guidelines2/5

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

No guidance on when to use this tool versus alternatives. With many risk-related siblings (e.g., close, reopen, start analysis), the description should specify the risk lifecycle stage or prerequisites.

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/wethti/qod-ppm-odoo-mcp'

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