INNER CODE UNIT · Python

get_gcal_system_prompt

existence-master/Sentient · src/server/mcp_hub/gcal/main.py:39

def get_gcal_system_prompt() -> str:
    """Provides the system prompt for the GCal agent."""
    return prompts.gcal_agent_system_prompt

# --- Helper for Tool Execution ---
async def _execute_tool(ctx: Context, action_name: str, **kwargs) -> Dict[str, Any]:
    """Helper to handle auth and execution for all tools using Composio."""
    tool_name = inspect.stack()[1].function
    logger.info(f"Executing tool: {tool_name} with parameters: {kwargs}")
    try:
        user_id = auth.get_user_id_from_context(ctx)
        connection_id = await auth.get_composio_connection_id(user_id, "gcalendar")

        # NEW: Fetch user info including privacy filters
        user_info = await auth.get_user_info(user_id)
        privacy_filters = user_info.get("privacy_filters", {})
        keyword_filters = privacy_filters.get("keywords", [])
        email_filters = [email.lower() for email in privacy_filters.get("emails", [])]

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…