Skip to main content
Glama
bellsanct
by bellsanct

view_battle_log

Display detailed combat logs from your dungeon exploration to analyze battles, track progress, and review encounter outcomes in the idle dungeon crawler game.

Instructions

探索中のダンジョンの詳細な戦闘ログを表示します。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
save_keyYesセーブキー

Implementation Reference

  • The actual implementation of the view_battle_log tool logic.
    export async function viewBattleLog(saveKey: string): Promise<string> {
      const data = await storage.load(saveKey);
      
      if (!data.player.name) {
        return "プレイヤーが見つかりません。";
      }
    
      if (!data.player.currentDungeon || data.player.currentDungeon.battleLog.length === 0) {
        return "表示できる戦闘ログがありません。";
      }
    
      const battleLog = data.player.currentDungeon.battleLog;
      
      let output = `=== 戦闘ログ ===\n\n`;
      
      for (const battle of battleLog) {
        const icon = battle.victory ? '✅' : '❌';
        output += `${icon} ${battle.floor}階: ${battle.enemyName}\n`;
        output += `  与ダメージ: ${battle.damageDealt} / 被ダメージ: ${battle.damageTaken}\n`;
        output += `  クリティカル: ${battle.criticalHits}回 / 回避: ${battle.dodges}回\n`;
    
        if (battle.herbUsed) {
          output += `  薬草使用: ✅ (HP回復)\n`;
        }
    
        if (battle.victory) {
          output += `  ゴールド: +${battle.goldEarned}\n`;
          if (battle.itemsDropped.length > 0) {
            output += `  ドロップ: ${battle.itemsDropped.map(i => i.name).join(', ')}\n`;
          }
        }
        output += '\n';
      }
    
      return output;
    }
  • src/index.ts:192-198 (registration)
    Registration of the 'view_battle_log' tool with its schema.
    name: 'view_battle_log',
    description: '探索中のダンジョンの詳細な戦闘ログを表示します。',
    inputSchema: {
      type: 'object',
      properties: {
        save_key: {
          type: 'string',
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries full burden. It states it displays battle logs but doesn't disclose behavioral traits like whether this is a read-only operation, if it requires specific game state (active dungeon), what format the logs are in, or if there are any limitations (e.g., only recent logs). The description is minimal and lacks operational context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence in Japanese, efficiently conveying the core purpose without waste. It's front-loaded with the main action and resource. However, it could be more structured if it included brief usage notes.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations, no output schema, and a simple input schema, the description is incomplete. It doesn't explain what the tool returns (e.g., log format, success/failure), any side effects, or dependencies on game state. For a tool with potential complexity in a gaming context, more detail is needed.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% with one parameter (save_key) documented in the schema. The description adds no additional meaning about parameters beyond what the schema provides (e.g., what save_key represents or how to obtain it). Baseline 3 is appropriate since the schema handles parameter documentation.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('表示します' - display/show) and the resource ('詳細な戦闘ログ' - detailed battle log) with context ('探索中のダンジョン' - dungeon being explored). It distinguishes from siblings like view_inventory or view_status by specifying battle logs, but doesn't explicitly contrast with check_progress or dungeon_info which might overlap.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives like check_progress or dungeon_info. The description implies it's for viewing battle logs during dungeon exploration, but doesn't specify prerequisites (e.g., must be in a dungeon) or exclusions (e.g., not for post-dungeon analysis).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/bellsanct/mcp-dungeon-game'

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