Skip to content

Bug: summary model field always shows "unknown" in database #63

@GusBot69

Description

@GusBot69

Bug Description

The model column in the LCM database always shows "unknown" for all summaries, even though a specific model is configured and being used.

Expected Behavior

The model column should contain the actual model ID used for summarization (e.g., "minimax-portal/MiniMax-M2.1").

Actual Behavior

All 110 summaries in my database show model: "unknown":

sqlite> SELECT model, COUNT(*) FROM summaries GROUP BY model;
unknown|110

Root Cause Analysis

I traced the issue to src/summarize.ts lines 330-331:

if (typeof result.model === "string" && result.model.trim()) {
  parts.push(`resp_model=${result.model.trim()}`);
}

The model is extracted from the result and added to log parts, but it is never inserted into the database. The database schema shows model TEXT DEFAULT 'unknown', so it always falls back to the default.

Environment

  • OpenClaw: v2026.3.13
  • LCM: v0.3.0
  • Configured summaryModel: minimax-portal/MiniMax-M2.1
  • Configured summaryProvider: minimax-portal

Suggested Fix

Pass the model value to the database insert operation, or update the INSERT statement to include the model field.

Additional Context

The model IS being used correctly (summaries are generated), and it appears in logs as resp_model=..., but the database column remains unpopulated.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions