Wikifunctions

Wikifunctions

Allowing AI models to discover and execute functions from the WikiFunctions library.

0
Stars
1
Forks
0
Releases

Overview

This MCP server implements the Model Context Protocol to bridge AI models and tools with the WikiFunctions library. It exposes three core tools that enable discovery, interpretation, and execution of WikiFunctions functions: find_code, get_template, and run_template. The find_code tool searches WikiFunctions for a function and returns its source code for inspection. The get_template tool fetches a function's definition and builds a user-friendly JSON template that describes how to call it, including the function name, description, and required arguments with their types. The run_template tool executes a function call by taking a template and user-provided values, translating it into a valid WikiFunctions call object, and sending it to the wikifunctions_run API endpoint for execution, with the result parsed and returned. The server locates functions via the wikilambdasearch_functions endpoint and retrieves details with wikilambda_fetch (including argument definitions, implementations, and multilingual labels). It resolves type ZIDs to human-readable names (e.g., Z6 -> "String"). Quick Start demonstrates enabling the server in mcp.json and running it via npx. This server enables MCP-enabled AI models and tools to discover, template, and execute WikiFunctions functions programmatically.

Details

Owner
Fredibau
Language
JavaScript
License
Updated
2025-12-07

Features

find_code

Searches WikiFunctions for a function and returns its source code for inspection.

get_template

Fetches the function definition and builds a JSON template describing how to call it, including name, description, and required arguments with their types.

run_template

Executes a function call by transforming a provided template and values into a WikiFunctions call object, sending it to wikifunctions_run, and returning the result.

Audience

AI modelsdiscover and execute WikiFunctions functions via MCP
MCP clientsintegrate with MCP-compatible tools like Claude-Desktop or Cursor via mcp.json

Tags

WikiFunctionsMCPModel Context ProtocolAPIfunction discoverytemplate buildingfunction executionWikiFunctions API