explain_minestom_pattern
Get documentation-backed explanations of Minestom design patterns for bootstrap, instances, events, commands, schedulers, or threading to implement features correctly.
Instructions
Use this when you want a docs-backed explanation of how Minestom typically models bootstrap, instances, events, commands, schedulers, or thread ownership.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| goal | No | Optional goal or problem statement to tailor the pattern explanation. | |
| topic | Yes | The Minestom subsystem or design topic to explain. |
Implementation Reference
- src/minestom/knowledge.ts:42-74 (handler)The `explain_minestom_pattern` tool handler logic and definition.
export const explainMinestomPatternTool: TanStackServerTool = toolDefinition({ description: "Use this when you want a docs-backed explanation of how Minestom typically models bootstrap, instances, events, commands, schedulers, or thread ownership.", inputSchema: explainMinestomPatternInputSchema, name: "explain_minestom_pattern", outputSchema: explainMinestomPatternOutputSchema, }).server(async (args) => { const { goal, topic } = explainMinestomPatternInputSchema.parse(args); const topicEntry = getTopicEntry(topic); const keyApis = getApisForTopic(topic) .slice(0, 5) .map((api) => ({ javadocUrl: api.javadocUrl, packageName: api.packageName, symbol: api.symbol, })); const goalAdjustment = goal ? `For goal "${goal}", start with ${topicEntry.keyApiSymbols.slice(0, 2).join(" and ")} and keep the ${topic} ownership model explicit.` : undefined; return explainMinestomPatternOutputSchema.parse({ commonPitfalls: topicEntry.commonPitfalls, explanation: topicEntry.explanation, goalAdjustment, keyApis, lifecycleNotes: topicEntry.lifecycleNotes, officialLinks: topicEntry.officialLinks, summary: topicEntry.summary, title: topicEntry.title, topic, }); }); - src/minestom/knowledge.ts:12-22 (schema)Input schema for the `explain_minestom_pattern` tool.
const explainMinestomPatternInputSchema = z.object({ goal: z .string() .optional() .describe( "Optional goal or problem statement to tailor the pattern explanation.", ), topic: minestomTopicSchema.describe( "The Minestom subsystem or design topic to explain.", ), }); - src/minestom/knowledge.ts:24-40 (schema)Output schema for the `explain_minestom_pattern` tool.
const explainMinestomPatternOutputSchema = z.object({ commonPitfalls: z.array(z.string()), explanation: z.string(), goalAdjustment: z.string().optional(), keyApis: z.array( z.object({ javadocUrl: z.string().url(), packageName: z.string(), symbol: z.string(), }), ), lifecycleNotes: z.array(z.string()), officialLinks: z.array(officialLinkSchema), summary: z.string(), title: z.string(), topic: minestomTopicSchema, });