Skip to main content
Glama

kobold_transcribe

Convert audio files to text using Whisper speech recognition technology for transcription and analysis.

Instructions

Transcribe audio using Whisper

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
apiUrlNohttp://localhost:5001
audioYes
languageNo

Implementation Reference

  • Handler logic that dispatches kobold_transcribe by validating input with TranscribeSchema, forwarding POST request to KoboldAI /api/extra/transcribe endpoint, and returning the response.
    if (postEndpoints[name]) {
        const { endpoint, schema } = postEndpoints[name];
        const parsed = schema.safeParse(args);
        if (!parsed.success) {
            throw new Error(`Invalid arguments: ${parsed.error}`);
        }
    
        const result = await makeRequest(`${apiUrl}${endpoint}`, 'POST', requestData);
        return {
            content: [{ type: "text", text: JSON.stringify(result, null, 2) }],
            isError: false,
        };
    }
  • Zod schema defining input for kobold_transcribe tool: optional apiUrl (from BaseConfigSchema), required audio string, optional language.
    const TranscribeSchema = BaseConfigSchema.extend({
        audio: z.string(),
        language: z.string().optional(),
    });
  • src/index.ts:208-212 (registration)
    Registers kobold_transcribe tool in ListTools response with name, description, and inputSchema.
    {
        name: "kobold_transcribe",
        description: "Transcribe audio using Whisper",
        inputSchema: zodToJsonSchema(TranscribeSchema),
    },
  • src/index.ts:335-335 (registration)
    Maps kobold_transcribe tool name to its KoboldAI endpoint and schema for dispatch in CallTool handler.
    kobold_transcribe: { endpoint: '/api/extra/transcribe', schema: TranscribeSchema },
  • Helper function used by all POST tool handlers, including kobold_transcribe, to make HTTP requests to KoboldAI API.
    async function makeRequest(url: string, method = 'GET', body: Record<string, unknown> | null = null) {
        const options: RequestInit = {
            method,
            headers: body ? { 'Content-Type': 'application/json' } : undefined,
        };
        
        if (body && method !== 'GET') {
            options.body = JSON.stringify(body);
        }
    
        const response = await fetch(url, options);
        if (!response.ok) {
            throw new Error(`KoboldAI API error: ${response.statusText}`);
        }
        
        return response.json();
    }

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/PhialsBasement/KoboldCPP-MCP-Server'

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