Skip to content

[Bug] Memory extraction hallucinates local time as UTC time (UTC+8 offset) #2369

Description

@QS-one

Pre-submission checklist | 提交前检查

  • I have searched existing issues and this hasn't been mentioned before | 我已搜索现有问题,确认此问题尚未被提及
  • I have read the project documentation and confirmed this issue doesn't already exist | 我已阅读项目文档并确认此问题尚未存在
  • This issue is specific to MemOS and not a general software issue | 该问题是针对 MemOS 的,而不是一般软件问题

Bug Description | 问题描述

When extracting factual memories, the LLM incorrectly uses UTC time as the local time, resulting in an 8-hour offset. The creation timestamp (created_at) in the database is accurate to the local time, but the generated memory content (memory field) hallucinates the incorrect time.

Image

How to Reproduce | 如何重现

  1. Ensure MemOS Cloud plugin is installed and running in DSH Desktop.
  2. Set the local timezone to UTC+8 (Asia/Shanghai).
  3. Open a chat session and instruct the agent to perform an action or state a preference around 12:45 PM.
  4. Wait for the conversation to end and the memory extraction process to trigger.
  5. Open the MemOS Console -> Memory List -> Fact Memory to inspect the extracted content.
  6. Observe that the time mentioned in the content is 8 hours earlier than the actual local time.

Environment | 环境信息

  • Host: DSH (DeepSeek Harness) Desktop
  • DSH Desktop Version: 2.0.9
  • OS: Windows (Local Timezone: Asia/Shanghai, UTC+8)
  • Plugin: @memtensor/memos-cloud-dsh-plugin (v0.1.1)
  • Node.js Version: v24.15.0
  • Provider: Qwen3.6-35B-A3B
  • MemOS Backend: MemOS Cloud

Additional Context | 其他信息

I noticed that MemOS provides a TZ environment variable (defaulting to Asia/Shanghai), but it seems the memory extraction pipeline does not pass this timezone context to the LLM prompt.

The prompt template requires the LLM to "Convert relative time expressions into absolute dates using the message timestamp if possible." However, without an explicit timezone offset in the timestamp, the LLM defaults to raw UTC time and hallucinates phrases like "early morning".

Suggested Fix:
Please explicitly inject the timezone offset (e.g., +08:00) into the message timestamp in the extraction prompt, or add a rule instructing the LLM not to infer or hallucinate specific time periods if timezone data is missing.

Willingness to Implement | 实现意愿

  • I'm willing to implement this myself | 我愿意自己解决
  • I would like someone else to implement this | 我希望其他人来解决

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

area:pluginOpenClaw & Hermesstatus:needs-triageNeeds initial triage | 需要初步判断 & 问题复现

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions