Skip to main content
Glama

get_recent_prompts

Retrieve recent user prompts from LLM sessions to review study history, analyze question types, and track learning progress for metacognitive reflection.

Instructions

최근 며칠간의 질문들을 조회합니다.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
daysNo조회할 일수 (기본값: 7)

Implementation Reference

  • The handler implementation for the `get_recent_prompts` tool in `src/server.ts`. It takes an optional `days` argument and returns a summary of prompts stored in the last N days.
      "get_recent_prompts",
      "최근 며칠간의 질문들을 조회합니다.",
      {
        days: z.number().optional().describe("조회할 일수 (기본값: 7)"),
      },
      async ({ days = 7 }) => {
        ensureDirectories();
        const results: { date: string; count: number }[] = [];
    
        for (let i = 0; i < days; i++) {
          const date = new Date();
          date.setDate(date.getDate() - i);
          const dateStr = date.toISOString().split("T")[0];
          const prompts = loadPrompts(dateStr);
          if (prompts.length > 0) {
            results.push({ date: dateStr, count: prompts.length });
          }
        }
    
        if (results.length === 0) {
          return {
            content: [{ type: "text", text: `최근 ${days}일간 저장된 질문이 없습니다.` }],
          };
        }
    
        const list = results
          .map((r) => `${r.date}: ${r.count}개 질문`)
          .join("\n");
    
        const total = results.reduce((sum, r) => sum + r.count, 0);
    
        return {
          content: [{ type: "text", text: `최근 ${days}일간 학습 기록\n\n${list}\n\n총 ${total}개 질문` }],
        };
      }
    );

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/YUJAEYUN/learnlog-mcp'

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