Skip to main content
Glama
saidsef

GitHub PR Issue Analyser

by saidsef

github_pr_issue_analyser_ui

Analyze GitHub pull requests and issues with an interactive UI. Gain insights on code changes, comments, and labels to simplify code reviews.

Instructions

Execute Prefab Python code in a sandbox and render the result.

The code runs in a Pyodide WASM sandbox with full Python support. Import everything you use. Use the components tool to look up available components and their import paths.

Always use PrefabApp as the outermost context manager — this enables streaming so the UI renders progressively as code is written:

from prefab_ui.components import Column, Heading, Text, Row, Badge
from prefab_ui.app import PrefabApp

with PrefabApp() as app:
    with Column(gap=4):
        Heading("Dashboard")
        with Row(gap=2):
            Text("Revenue: $1.2M")
            Badge("On Track", variant="success")

For interactive UIs, pass initial state as a dict and use .rx on stateful components for reactive bindings:

from prefab_ui.components import Column, Slider, Text
from prefab_ui.app import PrefabApp

with PrefabApp(state={"threshold": 50}) as app:
    with Column(gap=4):
        slider = Slider(value=50, min=0, max=100, name="threshold")
        Text(f"Threshold: {slider.rx}%")

slider.rx produces {{ threshold }}, a template expression that resolves against client-side state. Use Rx("key") directly, or apply pipe filters: Rx("balance").currency() produces {{ balance | currency }}.

Available pipes: upper, lower, currency, length, json, round(n), default(val), truncate(n).

Charts live in prefab_ui.components.charts:

from prefab_ui.components.charts import BarChart, ChartSeries

BarChart(
    data=[{"month": "Jan", "rev": 100}, {"month": "Feb", "rev": 200}],
    series=[ChartSeries(data_key="rev", label="Revenue")],
    x_axis="month",
)

Values passed via data are available as global variables in the code. Python features like loops, f-strings, and comprehensions all work.

Layout patterns:

  • Card sub-components (CardHeader, CardContent, CardFooter) have built-in padding. Don't add extra padding to them. For a simple card without sub-components, use Card(css_class="p-6").

  • Use Grid(columns=N, gap=4) for equal-width cards or panels. Grid handles sizing automatically — no flex classes needed. For unequal widths, pass a list: Grid(columns=[2, 1], gap=4) gives a 2:1 ratio.

  • Row is for inline elements (badges, icons + text, buttons). Prefer Grid when children should have equal or proportional widths. Row does not wrap by default.

  • Column and Row accept gap (Tailwind scale: 1-12), align (cross-axis), and justify (main-axis) as native props — prefer these over raw css_class for spacing.

  • Use css_class="overflow-hidden" on containers if chart or content edges should clip to the container boundary.

Args: code: Python code that builds a Prefab component tree. data: Values injected as variables in the sandbox namespace. sandbox: A Sandbox instance. If not provided, a new one is created on each call.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYes
dataNo
Behavior4/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 clearly explains that code runs in a Pyodide WASM sandbox, that imports are needed, that PrefabApp enables streaming, and that data is injected as variables. It also covers available pipes and chart components. Minor missing info: no mention of side effects or error handling, but overall very transparent.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness2/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is very long with multiple code blocks, detailed layout patterns, and a full documentation-style section. While detailed, it is not concise; a shorter description with pointers to external docs would suffice. The core purpose is front-loaded, but the rest is overly verbose for a tool description.

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

Completeness3/5

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

The description covers code syntax, imports, components, layout patterns, charts, and data injection. However, it lacks information on error handling, return value format, and limitations. Also, the tool name is not reconciled with the actual functionality. For a tool with no annotations and no output schema, this is moderately complete but has notable gaps.

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?

Only two parameters exist with zero schema description coverage. The description compensates fully: 'code' is explained as Python code building a Prefab component tree, and 'data' as values injected into the sandbox namespace. This adds essential meaning beyond type definitions.

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

Purpose2/5

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

The description states 'Execute Prefab Python code in a sandbox and render the result,' but the tool name 'github_pr_issue_analyser_ui' strongly suggests analysis of GitHub PRs and issues, which is not mentioned anywhere. This mismatch significantly undermines purpose clarity.

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 provides extensive details on how to write Prefab UI code, including layout patterns, imports, and examples. However, it does not explicitly state when to use this tool versus alternatives. The usage context is clear for creating UIs, but lacking comparative guidance.

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/saidsef/mcp-github-pr-issue-analyser'

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