Skip to main content
Glama
njoerd114

kubecon-eu-mcp

by njoerd114

detect_conflicts

Identify overlapping sessions in your KubeCon Europe schedule to resolve scheduling conflicts and optimize your conference experience.

Instructions

Detect scheduling conflicts among selected sessions.

Checks whether any of the provided sessions overlap in time, helping attendees resolve conflicts in their planned schedule.

Inspired by kubecon-event-scorer's conflict detection.

Args: session_uids: Comma-separated session UIDs to check for conflicts.

Returns: JSON with conflict pairs, overlap duration, and session details.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
session_uidsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The MCP tool handler for 'detect_conflicts' which parses inputs and calls the data_service logic.
    @mcp.tool()
    async def detect_conflicts(session_uids: str) -> str:
        """Detect scheduling conflicts among selected sessions.
    
        Checks whether any of the provided sessions overlap in time, helping
        attendees resolve conflicts in their planned schedule.
    
        Inspired by kubecon-event-scorer's conflict detection.
    
        Args:
            session_uids: Comma-separated session UIDs to check for conflicts.
    
        Returns:
            JSON with conflict pairs, overlap duration, and session details.
        """
        uids = [uid.strip() for uid in session_uids.split(",") if uid.strip()]
        if len(uids) < 2:
            return json.dumps(
                {"message": "Need at least 2 session UIDs to check for conflicts."}
            )
    
        conflicts = await data_service.detect_conflicts(uids)
    
        return json.dumps(
            {
                "sessions_checked": len(uids),
                "conflicts_found": len(conflicts),
                "conflicts": conflicts,
                "tip": "Use `search_sessions` to find alternative sessions on the same topic."
                if conflicts
                else "No conflicts — your schedule is clear!",
            },
            indent=2,
        )
  • The actual business logic implementation for 'detect_conflicts' inside the DataService class.
    async def detect_conflicts(self, session_uids: list[str]) -> list[dict]:
        """Detect scheduling conflicts among selected sessions.
    
        Inspired by kubecon-event-scorer's conflicts_with() method.
    
        Args:
            session_uids: List of session UIDs to check for conflicts.
    
        Returns:
            List of conflict pairs with details.
        """
        all_sessions = await self.get_sessions()
        colocated = await self.get_colocated_sessions()
        session_map = {s.uid: s for s in all_sessions + colocated}
    
        selected = [session_map[uid] for uid in session_uids if uid in session_map]
        conflicts: list[dict] = []
    
        for i, a in enumerate(selected):
            for b in selected[i + 1 :]:
                if a.day != b.day:
                    continue
                # Parse ISO times and check overlap
                try:
                    a_start = datetime.fromisoformat(a.start)
                    a_end = datetime.fromisoformat(a.end)
                    b_start = datetime.fromisoformat(b.start)
                    b_end = datetime.fromisoformat(b.end)
                except (ValueError, TypeError):
                    continue
    
                if a_start < b_end and b_start < a_end:
                    overlap_start = max(a_start, b_start)
                    overlap_end = min(a_end, b_end)
                    overlap_min = int(
                        (overlap_end - overlap_start).total_seconds() / 60
                    )
                    conflicts.append(
                        {
                            "session_a": {
                                "uid": a.uid,
                                "title": a.title,
                                "time": f"{a.start} - {a.end}",
                                "location": a.location,
                            },
                            "session_b": {
                                "uid": b.uid,
                                "title": b.title,
                                "time": f"{b.start} - {b.end}",
                                "location": b.location,
                            },
                            "overlap_minutes": overlap_min,
                        }
                    )
    
        return conflicts
Behavior3/5

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

With no annotations provided, the description carries the full burden. It describes the core behavior (detecting time overlaps) and mentions the return format (JSON with conflict pairs, overlap duration, session details). However, it lacks details on error handling, performance characteristics, or any side effects. The mention of being 'inspired by kubecon-event-scorer's conflict detection' adds some context but isn't specific about implementation.

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 well-structured with clear sections: purpose statement, usage context, inspiration note, Args, and Returns. Each sentence adds value. It could be slightly more concise by integrating the inspiration note into the purpose statement, but overall it's efficient and front-loaded with the core functionality.

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 1 parameter with low schema coverage, no annotations, and an output schema (implied by 'Returns' section), the description does a good job. It explains the parameter semantics, outlines the return structure, and provides enough context for basic usage. For a simple conflict detection tool, this is reasonably complete, though it could benefit from more behavioral details like error cases.

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

Parameters4/5

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

The input schema has 1 parameter with 0% description coverage. The description compensates by explaining 'session_uids: Comma-separated session UIDs to check for conflicts,' which clarifies the parameter's purpose and format beyond the schema's basic type information. This adds meaningful semantic context for the single required parameter.

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 tool's purpose: 'Detect scheduling conflicts among selected sessions' and 'Checks whether any of the provided sessions overlap in time.' It specifies the verb ('detect/check'), resource ('sessions'), and scope ('overlap in time'). However, it doesn't explicitly differentiate from sibling tools like 'get_schedule' or 'score_sessions' which might involve session analysis.

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

Usage Guidelines3/5

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

The description implies usage context: 'helping attendees resolve conflicts in their planned schedule' suggests it's for schedule planning. However, it doesn't provide explicit guidance on when to use this tool versus alternatives like 'get_schedule' (which might show schedules) or 'score_sessions' (which might evaluate sessions). No when-not-to-use or prerequisite information is included.

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/njoerd114/kubecon-eu-mcp'

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