by phimage
mcp-foundation-models is an MCP server that integrates with Apple's on-device Foundation Models framework. It provides secure and private text generation capabilities to MCP clients.
mcp-foundation-models is a Model Context Protocol (MCP) server that provides text generation capabilities by integrating with Apple's on-device Foundation Models framework. It allows MCP clients to securely and privately access Apple's language models for text generation.
To use mcp-foundation-models, you first need to build it from source. Clone the repository, navigate into the directory, and run swift build -c release
. The executable will be available at .build/release/mcp-foundation-models
.
Once built, you can integrate it with MCP clients like Claude Desktop. Edit the Claude configuration file ($HOME/Library/Application Support/Claude/claude_desktop_config.json
) and add the server's full path as an mcpServers
sub-object. For example:
{
"mcpServers": {
"foundation-models": {
"command": "/path/to/mcp-foundation-models/.build/release/mcp-foundation-models",
"args": []
}
}
}
Environment variables can be used for configuration:
SYSTEM_INSTRUCTIONS
: Set default system instructions for the AI assistant.DEBUG
: Enable debug logging (any non-empty value).Q: What are the requirements to run mcp-foundation-models? A: You need macOS 26.0 or later (macOS Tahoe), Xcode 26.0 or later, Swift 6.2 or later, and an Apple Silicon Mac for optimal performance with Foundation Models.
Q: Can I set default system instructions for the AI assistant?
A: Yes, you can set the SYSTEM_INSTRUCTIONS
environment variable to define default system instructions.
Q: How can I enable debug logging?
A: Set the DEBUG
environment variable to any non-empty value to enable debug logging.
A Model Context Protocol (MCP) server that provides text generation capabilities using Apple's Foundation Models framework. This server enables MCP clients to access Apple's on-device language models for secure, private text generation.
Clone the repository:
git clone <repository-url>
cd mcp-foundation-models
Build the project:
swift build -c release
The executable will be available at:
.build/release/mcp-foundation-models
Edit Claude configuration file '$HOME/Library/Application Support/Claude/claude_desktop_config.json'
Add this server full path as "mcpServers" sub object
{
"mcpServers": {
"foundation-models": {
"command": "/path/to/mcp-foundation-models/.build/release/mcp-foundation-models",
"args": [
]
}
The server supports configuration through environment variables:
SYSTEM_INSTRUCTIONS
: Set default system instructions for the AI assistantDEBUG
: Enable debug logging (any non-empty value)MIT
Reviews feature coming soon
Stay tuned for community discussions and feedback