Skip to main content
Glama
briantkatch

Paprika MCP Server

by briantkatch
user_preferences.py1.88 kB
"""User preferences prompt - loads user context from ~/.paprika-mcp/prompt.md.""" from pathlib import Path from typing import Any from mcp.types import GetPromptResult, PromptMessage, TextContent async def user_preferences_prompt(args: dict[str, Any]) -> GetPromptResult: """Load user preferences from ~/.paprika-mcp/prompt.md.""" prompt_path = Path.home() / ".paprika-mcp" / "prompt.md" if not prompt_path.exists(): return GetPromptResult( description="User preferences not configured", messages=[ PromptMessage( role="user", content=TextContent( type="text", text="No user preferences file found at ~/.paprika-mcp/prompt.md", ), ) ], ) try: content = prompt_path.read_text() return GetPromptResult( description="User preferences and context", messages=[ PromptMessage( role="user", content=TextContent(type="text", text=content) ) ], ) except Exception as e: return GetPromptResult( description="Error loading user preferences", messages=[ PromptMessage( role="user", content=TextContent( type="text", text=f"Error reading ~/.paprika-mcp/prompt.md: {str(e)}", ), ) ], ) # Prompt definition PROMPT_DEFINITION = { "name": "user_preferences", "description": ( "Load user preferences and high-level context from ~/.paprika-mcp/prompt.md. " "This can include dietary restrictions, favorite ingredients, or other helpful context." ), }

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/briantkatch/paprika-mcp'

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