[Bug] Claude defaults to assertion from memory instead of verification from tools

Resolved 💬 11 comments Opened Mar 9, 2026 by VoxCore84 Closed May 24, 2026

Bug Description

Claude Code states facts about schemas, file contents, configurations, and system state from memory/inference rather than checking with available tools. When these assertions are wrong, the error propagates into generated code, SQL, or recommendations — and is reported with the same confidence as verified facts.

Concrete Examples

Example 1: Column count from memory

A prior session wrote a SQL INSERT for gameobject_template with 32 Data column values. The table actually has 35 (Data0-Data34). Claude counted from memory instead of running DESCRIBE gameobject_template. The 3-column mismatch wasn't caught until execution failed in a later session.

Example 2: Column existence assumption

Claude wrote a verification query referencing smart_scripts.VerifiedBuild. That column doesn't exist on this table. Instead of checking the schema first, Claude assumed the column existed because most other tables in the same database have it.

Example 3: Schema inference across databases

When writing cross-database queries (source DB → target DB), Claude inferred that matching table names have matching schemas. Several tables had extra columns in the target (creature.size, gameobject.visibility, npc_vendor.OverrideGoldCost). The import document accounted for these, but only because a human had previously run DESCRIBE on both sides.

The Pattern

Claude has strong priors about what "should" be true based on patterns in training data and conversation context. These priors are often correct, which reinforces the behavior. But when they're wrong, the failure is silent — there's no indication that a fact was inferred rather than verified.

The fix isn't "always run DESCRIBE" — it's "distinguish between 'I know this' and 'I checked this' in reasoning, and default to checking when the cost is low."

Impact

  • Generated code contains bugs that match "what Claude thinks the schema looks like" rather than what it actually is
  • Users can't tell from Claude's output whether a claim is verified or inferred
  • The cost of checking (one DESCRIBE query, ~100ms) is trivially low compared to the cost of debugging wrong SQL

Related

  • #32289 — Claude generates incorrect code and reports it as complete

Environment

  • Claude Code 2.1.71
  • Windows 11

View original on GitHub ↗

This issue has 11 comments on GitHub. Read the full discussion on GitHub ↗