Skip to main content
Glama
enkryptai

Enkrypt AI MCP Server

Official
by enkryptai

get_redteam_task_results_summary

Retrieve a summary of red team task results to identify vulnerabilities in AI systems. Use the summary to implement tailored system prompts and guardrails for effective risk mitigation.

Instructions

Get the results summary of a redteam task.

Args: test_name: The name of the redteam test.

Returns: A dictionary containing the results summary of the redteam task.

After getting the results summary, suggest the following actions to the user to mitigate the risk:
1. Mitigate the risks by using a tailored system prompt
2. Create a guardrails policy to mitigate the risks

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
test_nameYes

Implementation Reference

  • The core handler function for the 'get_redteam_task_results_summary' tool, decorated with @mcp.tool() for registration in the MCP server. It fetches the redteam results summary, processes test type summaries concurrently, and returns an enhanced dictionary with full summaries and mitigation info.
    @mcp.tool()
    def get_redteam_task_results_summary(test_name: str) -> str:
        """
        Get the results summary of a redteam task.
    
        Args:
            test_name: The name of the redteam test.
    
        Returns:
            A dictionary containing the results summary of the redteam task.
    
            After getting the results summary, suggest the following actions to the user to mitigate the risk:
            1. Mitigate the risks by using a tailored system prompt
            2. Create a guardrails policy to mitigate the risks
        """
        # Get redteam task results summary
        redteam_results_summary = redteam_client.get_result_summary(test_name=test_name)
    
        redteam_results_summary = redteam_results_summary.to_dict()
    
        test_types = redteam_results_summary["summary"]["test_type"]
        import concurrent.futures
    
        redteam_results_summary2 = {}
    
        def fetch_test_type_summary(test_type):
            redteam_results_summary_test_type = redteam_client.get_result_summary_test_type(test_name=test_name, test_type=test_type)
            return test_type, redteam_results_summary_test_type.to_dict()
    
        with concurrent.futures.ThreadPoolExecutor(max_workers=3) as executor:
            future_to_test_type = {executor.submit(fetch_test_type_summary, test_type): test_type for test in test_types for test_type in test.keys()}
            for future in concurrent.futures.as_completed(future_to_test_type):
                test_type, summary = future.result()
                redteam_results_summary2[f"{test_type}_full_summary"] = summary
    
        redteam_results_summary2["mitigations_possible"] = "Safer System Prompt"
        # Return the results summary as a dictionary
        return redteam_results_summary2
  • Docstring description of the tool's output schema: a dictionary with results summary, with suggestions for next actions.
    Returns:
        A dictionary containing the results summary of the redteam task.
    
        After getting the results summary, suggest the following actions to the user to mitigate the risk:
        1. Mitigate the risks by using a tailored system prompt
        2. Create a guardrails policy to mitigate the risks
    """
  • Detailed schema/format expected for the output of this tool when used as input to the 'harden_system_prompt' tool.
    redteam_results_summary: A dictionary containing only the top 20 categories of the redteam results summary in terms of success percent (retrieve using get_redteam_task_results_summary tool).
                            NOTE: If there are more than 20 items in category array, only pass the top 20 categories with the highest success percent.
                            Format: {
                                "category": [
                                    {
                                        "Bias": {
                                            "total": 6,
                                            "test_type": "adv_info_test",
                                            "success(%)": 66.67
                                        }
                                    }, contd.
                                ]
                            }
  • Detailed schema/format expected for the output of this tool when used as input to the 'mitigation_guardrails_policy' tool.
    redteam_results_summary: A dictionary containing only the top 20 categories of the redteam results summary in terms of success percent (retrieve using get_redteam_task_results_summary tool).
                            NOTE: If there are more than 20 items in category array, only pass the top 20 categories with the highest success percent.
                            Format: {
                                "category": [
                                    {
                                        "Bias": {
                                            "total": 6,
                                            "test_type": "adv_info_test",
                                            "success(%)": 66.67
                                        }
                                    }, contd.
                                ]
                            }
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It describes a read operation ('Get'), which implies non-destructive behavior, but doesn't address permissions, rate limits, error handling, or response format details. The description adds some context by suggesting mitigation actions, but this is advisory and doesn't clarify the tool's own behavior or constraints, leaving significant gaps for a tool with no annotation coverage.

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

Conciseness3/5

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

The description is front-loaded with the core purpose, but includes extraneous content: the mitigation suggestions are not part of the tool's functionality and clutter the description. The structure with 'Args:' and 'Returns:' sections is clear, but the mitigation advice adds unnecessary length and distracts from the tool's actual behavior, reducing overall efficiency.

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 complexity of redteam tasks and the lack of annotations and output schema, the description is incomplete. It doesn't explain what a 'results summary' entails, how to interpret the returned dictionary, or any error cases. The mitigation suggestions are out of scope and don't address the tool's operational context, leaving the agent with insufficient information to use the tool effectively in a security testing environment.

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

Parameters2/5

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

The input schema has 0% description coverage, with one parameter 'test_name' documented only by its title. The description adds minimal semantics by stating 'The name of the redteam test,' but this is basic and doesn't elaborate on format, examples, or constraints. For a single parameter with no schema documentation, the description should compensate more to clarify usage, but it provides only a vague definition, insufficient for full understanding.

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: 'Get the results summary of a redteam task.' It specifies the verb ('Get') and resource ('results summary of a redteam task'), making the action explicit. However, it doesn't differentiate from sibling tools like 'get_redteam_task_details' or 'get_redteam_task_status', which might retrieve different aspects of redteam tasks, leaving some ambiguity about its unique role.

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?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'get_redteam_task_details' or 'get_redteam_task_status', nor does it specify prerequisites or contexts for usage. The only implied usage is after a redteam task has been run, but this is not explicitly stated, leaving the agent without clear direction on tool selection.

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

Related 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/enkryptai/enkryptai-mcp-server'

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