Skip to main content
Glama

challenge

Analyze statements critically to uncover assumptions and encourage deeper thinking. Promotes structured reasoning by evaluating prompts for logical consistency and potential biases.

Instructions

Challenge a statement or assumption with critical thinking

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
promptYesThe user's message or statement to analyze critically. When manually invoked with 'challenge', exclude that prefix - just pass the actual content. For automatic invocations, pass the user's complete message unchanged.

Implementation Reference

  • The main execution logic for the 'challenge' tool. It wraps the input prompt with critical thinking instructions and returns structured JSON data that instructs the AI to critically reassess the statement instead of reflexively agreeing.
    async handleChallenge(params: z.infer<typeof ChallengeSchema>) { // Challenge tool doesn't use AI - it just wraps the prompt in critical thinking instructions const wrappedPrompt = this.wrapPromptForChallenge(params.prompt); const responseData = { status: "challenge_created", original_statement: params.prompt, challenge_prompt: wrappedPrompt, instructions: ( "Present the challenge_prompt to yourself and follow its instructions. " + "Reassess the statement carefully and critically before responding. " + "If, after reflection, you find reasons to disagree or qualify it, explain your reasoning. " + "Likewise, if you find reasons to agree, articulate them clearly and justify your agreement." ), }; return { content: [ { type: "text", text: JSON.stringify(responseData, null, 2), }, ], }; }
  • src/server.ts:335-342 (registration)
    Registers the 'challenge' tool with the MCP server, linking to the aiHandlers.handleChallenge execution function.
    server.registerTool("challenge", { title: "Challenge", description: "Challenge a statement or assumption with critical thinking", inputSchema: ChallengeSchema.shape, }, async (args) => { const aiHandlers = await getHandlers(); return await aiHandlers.handleChallenge(args); });
  • Zod schema defining the input for the 'challenge' tool: a single 'prompt' string field.
    const ChallengeSchema = z.object({ prompt: z.string().describe("The user's message or statement to analyze critically. When manually invoked with 'challenge', exclude that prefix - just pass the actual content. For automatic invocations, pass the user's complete message unchanged."), });
  • Helper function that formats the user's prompt into a critical reassessment template used by the handler.
    private wrapPromptForChallenge(prompt: string): string { return ( `CRITICAL REASSESSMENT – Do not automatically agree:\n\n` + `"${prompt}"\n\n` + `Carefully evaluate the statement above. Is it accurate, complete, and well-reasoned? ` + `Investigate if needed before replying, and stay focused. If you identify flaws, gaps, or misleading ` + `points, explain them clearly. Likewise, if you find the reasoning sound, explain why it holds up. ` + `Respond with thoughtful analysis—stay to the point and avoid reflexive agreement.` ); }
  • src/server.ts:682-699 (registration)
    Registers the prompt template for the 'challenge' tool, providing a user-friendly way to invoke it.
    server.registerPrompt("challenge", { title: "Challenge Statement", description: "Challenge a statement or assumption with critical thinking", argsSchema: { prompt: z.string().optional(), provider: z.string().optional(), model: z.string().optional(), sessionId: z.string().optional(), }, }, (args) => ({ messages: [{ role: "user", content: { type: "text", text: `Challenge this statement with critical thinking and provide alternative perspectives: ${args.prompt || 'Please provide a statement or assumption to analyze critically.'}` } }] }));

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/RealMikeChong/ultra-mcp'

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