Skip to main content
Glama

generate_presentation

Convert raw text or markdown into a presentation deck. Use notes, outlines, or summaries to create slides.

Instructions

Create a new presentation from raw text or markdown. Use this to turn notes, outlines, meeting summaries, or draft content into an Alai deck before polling get_generation_status.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
input_textYesThe source content to transform into slides.
titleNoPresentation title shown in the deck and exports.
theme_idNoTheme identifier from get_themes. Use this to control layout family.
vibe_idNoVisual style identifier from get_vibes. Use only after discovering valid IDs.
languageNoPresentation language, for example English or Spanish.
export_formatsNoFormats to generate when the deck is ready.
slide_rangeNoRequested slide count range such as 2-5.
include_ai_imagesNoWhether Alai should generate image content for slides.
num_creative_variantsNoHow many creative variants to generate per slide.
total_variants_per_slideNoTotal variant count to generate for each slide.
image_idsNoExisting uploaded image identifiers to reuse in the deck.

Implementation Reference

  • The handler function for generate_presentation that forwards the call to the remote Alai MCP endpoint via callRemoteTool.
      async (args) => {
        try {
          return await callRemoteTool("generate_presentation", args);
        } catch (error) {
          return normalizeError(error);
        }
      },
    );
  • Input schema for generate_presentation: requires input_text, and optionally accepts title, theme_id, vibe_id, language, export_formats, slide_range, include_ai_images, num_creative_variants, total_variants_per_slide, and image_ids.
    inputSchema: {
      input_text: z
        .string()
        .min(1)
        .describe("The source content to transform into slides."),
      ...basePresentationInput,
      slide_range: z
        .string()
        .optional()
        .describe("Requested slide count range such as 2-5."),
      include_ai_images: z
        .boolean()
        .optional()
        .describe("Whether Alai should generate image content for slides."),
      num_creative_variants: z
        .number()
        .int()
        .min(0)
        .max(2)
        .optional()
        .describe("How many creative variants to generate per slide."),
      total_variants_per_slide: z
        .number()
        .int()
        .min(1)
        .max(4)
        .optional()
        .describe("Total variant count to generate for each slide."),
      image_ids: z
        .array(z.string())
        .optional()
        .describe("Existing uploaded image identifiers to reuse in the deck."),
    },
  • src/index.js:115-161 (registration)
    Registration of the generate_presentation tool on the MCP server via server.registerTool.
    server.registerTool(
      "generate_presentation",
      {
        description:
          "Create a new presentation from raw text or markdown. Use this to turn notes, outlines, meeting summaries, or draft content into an Alai deck before polling get_generation_status.",
        inputSchema: {
          input_text: z
            .string()
            .min(1)
            .describe("The source content to transform into slides."),
          ...basePresentationInput,
          slide_range: z
            .string()
            .optional()
            .describe("Requested slide count range such as 2-5."),
          include_ai_images: z
            .boolean()
            .optional()
            .describe("Whether Alai should generate image content for slides."),
          num_creative_variants: z
            .number()
            .int()
            .min(0)
            .max(2)
            .optional()
            .describe("How many creative variants to generate per slide."),
          total_variants_per_slide: z
            .number()
            .int()
            .min(1)
            .max(4)
            .optional()
            .describe("Total variant count to generate for each slide."),
          image_ids: z
            .array(z.string())
            .optional()
            .describe("Existing uploaded image identifiers to reuse in the deck."),
        },
      },
      async (args) => {
        try {
          return await callRemoteTool("generate_presentation", args);
        } catch (error) {
          return normalizeError(error);
        }
      },
    );
  • Helper function callRemoteTool that creates an MCP client, connects to the remote Alai endpoint, and calls the specified tool with the provided arguments.
    async function callRemoteTool(name, args) {
      const client = new Client(
        { name: "alai-mcp-wrapper", version: "1.0.2" },
        { capabilities: {} },
      );
      const transport = new StreamableHTTPClientTransport(new URL(REMOTE_MCP_URL), {
        requestInit: {
          headers: createRemoteHeaders(),
        },
      });
    
      try {
        await client.connect(transport);
        return await client.callTool({
          name,
          arguments: args,
        });
      } finally {
        await transport.close().catch(() => {});
        await client.close().catch(() => {});
      }
    }
Behavior3/5

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

With no annotations, the description carries full burden. It correctly implies the tool is asynchronous (by mentioning polling), but does not disclose auth needs, side effects, or error behavior. The description is adequate but could be more explicit about the generation process.

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

Conciseness5/5

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

The description is two sentences, front-loaded with the action verb 'Create'. Every word serves a purpose with no redundancy. It is concise and easy to parse.

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?

Given the complexity (11 parameters, no output schema), the description is minimal. It correctly sets up the workflow with get_generation_status but omits return value description, error cases, or parameter relationships (e.g., theme_id vs vibe_id). The parameter schema partially compensates.

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

Parameters3/5

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

Schema description coverage is 100%, so baseline is 3. The tool description adds no additional parameter meaning beyond the schema. It mentions 'raw text or markdown' which aligns with input_text but doesn't augment the schema.

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

Purpose5/5

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

The description clearly states the tool creates a presentation from raw text or markdown, with explicit use cases (notes, outlines, meeting summaries). It distinguishes from siblings like create_slide (individual slides) and get_generation_status (polling), and even references the correct subsequent tool.

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

Usage Guidelines4/5

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

The description explains when to use the tool: to turn raw text into a deck before polling get_generation_status. It provides context for the workflow but does not explicitly exclude scenarios or mention alternatives like create_slide for single slides, though this is implied.

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/getalai/alai-mcp-server'

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