[{"data":1,"prerenderedAt":885},["ShallowReactive",2],{"docs-page-en-\u002Fmemos_cloud\u002Fintroduction\u002Ftime_awareness":3,"surround-en-\u002Fmemos_cloud\u002Fintroduction\u002Ftime_awareness":872},{"id":4,"title":5,"avatar":6,"banner":6,"body":7,"category":6,"desc":865,"description":13,"extension":866,"links":6,"meta":867,"navigation":6,"path":868,"seo":869,"stem":870,"__hash__":871},"docs\u002Fen\u002Fmemos_cloud\u002Fintroduction\u002Ftime_awareness.md","Time Awareness",null,{"type":8,"value":9,"toc":849},"minimark",[10,14,17,22,27,41,43,47,57,59,63,73,75,79,473,475,479,482,746,802,804,808,819,821,825,845],[11,12,13],"p",{},"We treat memories as objects that evolve over time, not as static text. A user's preferences, state, and facts may change; one-time events also need to keep when they happened. With time awareness, MemOS can decide when to use the latest current understanding and when to trace back to historical versions.",[15,16],"br",{},[18,19,21],"h2",{"id":20},"_1-what-problems-it-solves","1. What Problems It Solves",[23,24,26],"h3",{"id":25},"new-and-old-information-conflicts","New and old information conflicts",[28,29,30,34],"ul",{},[31,32,33],"li",{},"The user first says \"I like apples\", and later says \"I don't like apples anymore\".",[31,35,36,40],{},[37,38,39],"strong",{},"How MemOS handles it",": MemOS automatically detects the change. During retrieval, it returns only the currently valid understanding: \"does not like apples\". Historical versions are not deleted and can still be traced when needed.",[15,42],{},[23,44,46],{"id":45},"now-and-before-should-return-different-answers","\"Now\" and \"before\" should return different answers",[28,48,49,52],{},[31,50,51],{},"The user used to live in Beijing, then moved to Shanghai.",[31,53,54,56],{},[37,55,39],{},": MemOS understands time clues in the question. When the user asks \"Where do I live now?\", it retrieves Shanghai. When the user asks \"Where did I live before?\", it retrieves Beijing.",[15,58],{},[23,60,62],{"id":61},"events-should-not-be-forcibly-merged","Events should not be forcibly merged",[28,64,65,68],{},[31,66,67],{},"The user traveled to Xi'an during last year's National Day holiday and to Hangzhou during this year's May Day holiday.",[31,69,70,72],{},[37,71,39],{},": MemOS keeps the complete information for each event instead of merging everything into \"the user likes travel\". When the user asks \"Where did I travel recently?\", it can prioritize Hangzhou.",[15,74],{},[18,76,78],{"id":77},"_2-processing-flow","2. Processing Flow",[80,81,83,92,98,291,295,298,312,316,330,343],"steps",{"level":82},"3",[23,84,86,87,91],{"id":85},"at-write-time-use-chat_time-to-anchor-historical-time","At write time: use ",[88,89,90],"code",{},"chat_time"," to anchor historical time",[11,93,94,95,97],{},"Real-time conversations usually do not require a timestamp. MemOS uses the message ingestion time. If you import historical data, pass ",[88,96,90],{}," so memories are anchored to when the event actually happened.",[99,100,105],"pre",{"className":101,"code":102,"language":103,"meta":104,"style":104},"language-json shiki shiki-themes material-theme-lighter github-light-high-contrast github-dark-default","{\n  \"user_id\": \"memos_user_123\",\n  \"messages\": [\n    { \"role\": \"user\", \"content\": \"I like spicy food.\", \"chat_time\": \"2025-09-12 08:00:00\" },\n    { \"role\": \"user\", \"content\": \"I can't eat very oily or spicy food now, and I prefer something lighter.\", \"chat_time\": \"2025-09-25 12:00:00\" }\n  ]\n}\n","json","",[88,106,107,116,146,161,223,279,285],{"__ignoreMap":104},[108,109,112],"span",{"class":110,"line":111},"line",1,[108,113,115],{"class":114},"suWxN","{\n",[108,117,119,123,127,130,133,137,141,143],{"class":110,"line":118},2,[108,120,122],{"class":121},"sfJrv","  \"",[108,124,126],{"class":125},"skH7o","user_id",[108,128,129],{"class":121},"\"",[108,131,132],{"class":114},":",[108,134,136],{"class":135},"sjUum"," \"",[108,138,140],{"class":139},"sp1uZ","memos_user_123",[108,142,129],{"class":135},[108,144,145],{"class":114},",\n",[108,147,149,151,154,156,158],{"class":110,"line":148},3,[108,150,122],{"class":121},[108,152,153],{"class":125},"messages",[108,155,129],{"class":121},[108,157,132],{"class":114},[108,159,160],{"class":114}," [\n",[108,162,164,167,169,173,175,177,179,182,184,187,189,192,194,196,198,201,203,205,207,209,211,213,215,218,220],{"class":110,"line":163},4,[108,165,166],{"class":114},"    {",[108,168,136],{"class":121},[108,170,172],{"class":171},"smon8","role",[108,174,129],{"class":121},[108,176,132],{"class":114},[108,178,136],{"class":135},[108,180,181],{"class":139},"user",[108,183,129],{"class":135},[108,185,186],{"class":114},",",[108,188,136],{"class":121},[108,190,191],{"class":171},"content",[108,193,129],{"class":121},[108,195,132],{"class":114},[108,197,136],{"class":135},[108,199,200],{"class":139},"I like spicy food.",[108,202,129],{"class":135},[108,204,186],{"class":114},[108,206,136],{"class":121},[108,208,90],{"class":171},[108,210,129],{"class":121},[108,212,132],{"class":114},[108,214,136],{"class":135},[108,216,217],{"class":139},"2025-09-12 08:00:00",[108,219,129],{"class":135},[108,221,222],{"class":114}," },\n",[108,224,226,228,230,232,234,236,238,240,242,244,246,248,250,252,254,257,259,261,263,265,267,269,271,274,276],{"class":110,"line":225},5,[108,227,166],{"class":114},[108,229,136],{"class":121},[108,231,172],{"class":171},[108,233,129],{"class":121},[108,235,132],{"class":114},[108,237,136],{"class":135},[108,239,181],{"class":139},[108,241,129],{"class":135},[108,243,186],{"class":114},[108,245,136],{"class":121},[108,247,191],{"class":171},[108,249,129],{"class":121},[108,251,132],{"class":114},[108,253,136],{"class":135},[108,255,256],{"class":139},"I can't eat very oily or spicy food now, and I prefer something lighter.",[108,258,129],{"class":135},[108,260,186],{"class":114},[108,262,136],{"class":121},[108,264,90],{"class":171},[108,266,129],{"class":121},[108,268,132],{"class":114},[108,270,136],{"class":135},[108,272,273],{"class":139},"2025-09-25 12:00:00",[108,275,129],{"class":135},[108,277,278],{"class":114}," }\n",[108,280,282],{"class":110,"line":281},6,[108,283,284],{"class":114},"  ]\n",[108,286,288],{"class":110,"line":287},7,[108,289,290],{"class":114},"}\n",[23,292,294],{"id":293},"time-handling-for-two-kinds-of-memories","Time handling for two kinds of memories",[11,296,297],{},"MemOS handles memories differently:",[28,299,300,306],{},[31,301,302,305],{},[37,303,304],{},"States that may change",", such as where the user lives, what they like, or their current stage goal, keep different time versions. This lets retrieval use the current version while still allowing historical recall.",[31,307,308,311],{},[37,309,310],{},"One-time events",", such as where the user went or what they did, keep the details of each event. This lets retrieval return complete event information.",[23,313,315],{"id":314},"at-search-time-understand-the-time-target-in-the-question","At search time: understand the time target in the question",[28,317,318,324],{},[31,319,320,323],{},[37,321,322],{},"No explicit time target",": retrieve normally and prefer currently valid memories.",[31,325,326,329],{},[37,327,328],{},"With time clues",": understand the time target and select the corresponding version or event.",[11,331,332,333,338,339,342],{},"If you already know the time range, you can also combine ",[334,335,337],"a",{"href":336},"\u002Fmemos_cloud\u002Ffeatures\u002Ffilters","Memory Filters"," with ",[88,340,341],{},"create_time"," to narrow candidate memories:",[99,344,346],{"className":101,"code":345,"language":103,"meta":104,"style":104},"{\n  \"user_id\": \"memos_user_123\",\n  \"query\": \"Summarize my reading-related records in December 2025\",\n  \"filter\": {\n    \"and\": [\n      { \"create_time\": { \"gte\": \"2025-12-01\" } }\n    ]\n  }\n}\n",[88,347,348,352,370,390,404,418,457,462,468],{"__ignoreMap":104},[108,349,350],{"class":110,"line":111},[108,351,115],{"class":114},[108,353,354,356,358,360,362,364,366,368],{"class":110,"line":118},[108,355,122],{"class":121},[108,357,126],{"class":125},[108,359,129],{"class":121},[108,361,132],{"class":114},[108,363,136],{"class":135},[108,365,140],{"class":139},[108,367,129],{"class":135},[108,369,145],{"class":114},[108,371,372,374,377,379,381,383,386,388],{"class":110,"line":148},[108,373,122],{"class":121},[108,375,376],{"class":125},"query",[108,378,129],{"class":121},[108,380,132],{"class":114},[108,382,136],{"class":135},[108,384,385],{"class":139},"Summarize my reading-related records in December 2025",[108,387,129],{"class":135},[108,389,145],{"class":114},[108,391,392,394,397,399,401],{"class":110,"line":163},[108,393,122],{"class":121},[108,395,396],{"class":125},"filter",[108,398,129],{"class":121},[108,400,132],{"class":114},[108,402,403],{"class":114}," {\n",[108,405,406,409,412,414,416],{"class":110,"line":225},[108,407,408],{"class":121},"    \"",[108,410,411],{"class":171},"and",[108,413,129],{"class":121},[108,415,132],{"class":114},[108,417,160],{"class":114},[108,419,420,423,425,428,430,432,435,437,441,443,445,447,450,452,455],{"class":110,"line":281},[108,421,422],{"class":114},"      {",[108,424,136],{"class":121},[108,426,341],{"class":427},"s_fzf",[108,429,129],{"class":121},[108,431,132],{"class":114},[108,433,434],{"class":114}," {",[108,436,136],{"class":121},[108,438,440],{"class":439},"sw4Oa","gte",[108,442,129],{"class":121},[108,444,132],{"class":114},[108,446,136],{"class":135},[108,448,449],{"class":139},"2025-12-01",[108,451,129],{"class":135},[108,453,454],{"class":114}," }",[108,456,278],{"class":114},[108,458,459],{"class":110,"line":287},[108,460,461],{"class":114},"    ]\n",[108,463,465],{"class":110,"line":464},8,[108,466,467],{"class":114},"  }\n",[108,469,471],{"class":110,"line":470},9,[108,472,290],{"class":114},[15,474],{},[18,476,478],{"id":477},"_3-example","3. Example",[11,480,481],{},"Try writing a set of events with time information:",[99,483,485],{"className":101,"code":484,"language":103,"meta":104,"style":104},"{\n  \"user_id\": \"test_user\",\n  \"messages\": [\n    { \"role\": \"user\", \"content\": \"I live in Beijing.\", \"chat_time\": \"2025-01-10 10:00:00\" },\n    { \"role\": \"user\", \"content\": \"I moved to Shanghai.\", \"chat_time\": \"2025-06-01 10:00:00\" },\n    { \"role\": \"user\", \"content\": \"I traveled to Xi'an during last year's National Day holiday.\", \"chat_time\": \"2025-10-08 10:00:00\" },\n    { \"role\": \"user\", \"content\": \"I traveled to Hangzhou during this year's May Day holiday.\", \"chat_time\": \"2026-05-02 10:00:00\" }\n  ]\n}\n",[88,486,487,491,510,522,576,630,684,738,742],{"__ignoreMap":104},[108,488,489],{"class":110,"line":111},[108,490,115],{"class":114},[108,492,493,495,497,499,501,503,506,508],{"class":110,"line":118},[108,494,122],{"class":121},[108,496,126],{"class":125},[108,498,129],{"class":121},[108,500,132],{"class":114},[108,502,136],{"class":135},[108,504,505],{"class":139},"test_user",[108,507,129],{"class":135},[108,509,145],{"class":114},[108,511,512,514,516,518,520],{"class":110,"line":148},[108,513,122],{"class":121},[108,515,153],{"class":125},[108,517,129],{"class":121},[108,519,132],{"class":114},[108,521,160],{"class":114},[108,523,524,526,528,530,532,534,536,538,540,542,544,546,548,550,552,555,557,559,561,563,565,567,569,572,574],{"class":110,"line":163},[108,525,166],{"class":114},[108,527,136],{"class":121},[108,529,172],{"class":171},[108,531,129],{"class":121},[108,533,132],{"class":114},[108,535,136],{"class":135},[108,537,181],{"class":139},[108,539,129],{"class":135},[108,541,186],{"class":114},[108,543,136],{"class":121},[108,545,191],{"class":171},[108,547,129],{"class":121},[108,549,132],{"class":114},[108,551,136],{"class":135},[108,553,554],{"class":139},"I live in Beijing.",[108,556,129],{"class":135},[108,558,186],{"class":114},[108,560,136],{"class":121},[108,562,90],{"class":171},[108,564,129],{"class":121},[108,566,132],{"class":114},[108,568,136],{"class":135},[108,570,571],{"class":139},"2025-01-10 10:00:00",[108,573,129],{"class":135},[108,575,222],{"class":114},[108,577,578,580,582,584,586,588,590,592,594,596,598,600,602,604,606,609,611,613,615,617,619,621,623,626,628],{"class":110,"line":225},[108,579,166],{"class":114},[108,581,136],{"class":121},[108,583,172],{"class":171},[108,585,129],{"class":121},[108,587,132],{"class":114},[108,589,136],{"class":135},[108,591,181],{"class":139},[108,593,129],{"class":135},[108,595,186],{"class":114},[108,597,136],{"class":121},[108,599,191],{"class":171},[108,601,129],{"class":121},[108,603,132],{"class":114},[108,605,136],{"class":135},[108,607,608],{"class":139},"I moved to Shanghai.",[108,610,129],{"class":135},[108,612,186],{"class":114},[108,614,136],{"class":121},[108,616,90],{"class":171},[108,618,129],{"class":121},[108,620,132],{"class":114},[108,622,136],{"class":135},[108,624,625],{"class":139},"2025-06-01 10:00:00",[108,627,129],{"class":135},[108,629,222],{"class":114},[108,631,632,634,636,638,640,642,644,646,648,650,652,654,656,658,660,663,665,667,669,671,673,675,677,680,682],{"class":110,"line":281},[108,633,166],{"class":114},[108,635,136],{"class":121},[108,637,172],{"class":171},[108,639,129],{"class":121},[108,641,132],{"class":114},[108,643,136],{"class":135},[108,645,181],{"class":139},[108,647,129],{"class":135},[108,649,186],{"class":114},[108,651,136],{"class":121},[108,653,191],{"class":171},[108,655,129],{"class":121},[108,657,132],{"class":114},[108,659,136],{"class":135},[108,661,662],{"class":139},"I traveled to Xi'an during last year's National Day holiday.",[108,664,129],{"class":135},[108,666,186],{"class":114},[108,668,136],{"class":121},[108,670,90],{"class":171},[108,672,129],{"class":121},[108,674,132],{"class":114},[108,676,136],{"class":135},[108,678,679],{"class":139},"2025-10-08 10:00:00",[108,681,129],{"class":135},[108,683,222],{"class":114},[108,685,686,688,690,692,694,696,698,700,702,704,706,708,710,712,714,717,719,721,723,725,727,729,731,734,736],{"class":110,"line":287},[108,687,166],{"class":114},[108,689,136],{"class":121},[108,691,172],{"class":171},[108,693,129],{"class":121},[108,695,132],{"class":114},[108,697,136],{"class":135},[108,699,181],{"class":139},[108,701,129],{"class":135},[108,703,186],{"class":114},[108,705,136],{"class":121},[108,707,191],{"class":171},[108,709,129],{"class":121},[108,711,132],{"class":114},[108,713,136],{"class":135},[108,715,716],{"class":139},"I traveled to Hangzhou during this year's May Day holiday.",[108,718,129],{"class":135},[108,720,186],{"class":114},[108,722,136],{"class":121},[108,724,90],{"class":171},[108,726,129],{"class":121},[108,728,132],{"class":114},[108,730,136],{"class":135},[108,732,733],{"class":139},"2026-05-02 10:00:00",[108,735,129],{"class":135},[108,737,278],{"class":114},[108,739,740],{"class":110,"line":464},[108,741,284],{"class":114},[108,743,744],{"class":110,"line":470},[108,745,290],{"class":114},[747,748,749,765],"table",{},[750,751,752],"thead",{},[753,754,755,759,762],"tr",{},[756,757,758],"th",{},"Type",[756,760,761],{},"Search query",[756,763,764],{},"Expected result",[766,767,768,780,791],"tbody",{},[753,769,770,774,777],{},[771,772,773],"td",{},"Current state",[771,775,776],{},"\"Where do I live now?\"",[771,778,779],{},"Shanghai, using the latest state",[753,781,782,785,788],{},[771,783,784],{},"Historical state",[771,786,787],{},"\"Where did I live before?\"",[771,789,790],{},"Beijing, tracing back to the historical version",[753,792,793,796,799],{},[771,794,795],{},"Up to now",[771,797,798],{},"\"Where have I traveled?\"",[771,800,801],{},"Xi'an and Hangzhou, with Hangzhou ranked first",[15,803],{},[18,805,807],{"id":806},"_4-usage-suggestions","4. Usage Suggestions",[28,809,810,816],{},[31,811,812,813,815],{},"Pass accurate ",[88,814,90],{}," when importing historical data; otherwise, old events may be treated as if they just happened.",[31,817,818],{},"For current-state information, let users naturally express updates. MemOS will update the current understanding automatically.",[15,820],{},[18,822,824],{"id":823},"_5-next-steps","5. Next Steps",[826,827,828,837],"card-group",{},[829,830,834],"card",{"icon":831,"title":832,"to":833},"i-ri-message-3-line","Add Message","\u002Fmemos_cloud\u002Fmem_operations\u002Fadd_message",[11,835,836],{},"Write historical messages with timestamps",[829,838,842],{"icon":839,"title":840,"to":841},"i-ri-search-2-line","Search Memory","\u002Fmemos_cloud\u002Fmem_operations\u002Fsearch_memory",[11,843,844],{},"Search and verify time-related memories",[846,847,848],"style",{},"html pre.shiki code .suWxN, html code.shiki .suWxN{--shiki-light:#39ADB5;--shiki-default:#0E1116;--shiki-dark:#E6EDF3}html pre.shiki code .sfJrv, html code.shiki .sfJrv{--shiki-light:#39ADB5;--shiki-default:#024C1A;--shiki-dark:#7EE787}html pre.shiki code .skH7o, html code.shiki .skH7o{--shiki-light:#9C3EDA;--shiki-default:#024C1A;--shiki-dark:#7EE787}html pre.shiki code .sjUum, html code.shiki .sjUum{--shiki-light:#39ADB5;--shiki-default:#032563;--shiki-dark:#A5D6FF}html pre.shiki code .sp1uZ, html code.shiki .sp1uZ{--shiki-light:#91B859;--shiki-default:#032563;--shiki-dark:#A5D6FF}html pre.shiki code .smon8, html code.shiki .smon8{--shiki-light:#E2931D;--shiki-default:#024C1A;--shiki-dark:#7EE787}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .s_fzf, html code.shiki .s_fzf{--shiki-light:#F76D47;--shiki-default:#024C1A;--shiki-dark:#7EE787}html pre.shiki code .sw4Oa, html code.shiki .sw4Oa{--shiki-light:#E53935;--shiki-default:#024C1A;--shiki-dark:#7EE787}",{"title":104,"searchDepth":118,"depth":118,"links":850},[851,856,862,863,864],{"id":20,"depth":118,"text":21,"children":852},[853,854,855],{"id":25,"depth":148,"text":26},{"id":45,"depth":148,"text":46},{"id":61,"depth":148,"text":62},{"id":77,"depth":118,"text":78,"children":857},[858,860,861],{"id":85,"depth":148,"text":859},"At write time: use chat_time to anchor historical time",{"id":293,"depth":148,"text":294},{"id":314,"depth":148,"text":315},{"id":477,"depth":118,"text":478},{"id":806,"depth":118,"text":807},{"id":823,"depth":118,"text":824},"How memories update over time, keep history, and understand \"now\" and \"before\" during retrieval.","md",{},"\u002Fen\u002Fmemos_cloud\u002Fintroduction\u002Ftime_awareness",{"title":5,"description":13},"en\u002Fmemos_cloud\u002Fintroduction\u002Ftime_awareness","mkZ4xRoUS_Lrmb9mlYgNGk9qOApX-H3FGG0fawIf1gs",[873,881],{"title":874,"path":875,"stem":876,"icon":877,"framework":6,"module":6,"class":878,"target":-1,"active":879,"defaultOpen":879,"children":-1,"description":880},"Multi-user \u002F Multi-Agent Isolation","\u002Fmemos_cloud\u002Fintroduction\u002Fisolation_filters","memos_cloud\u002Fintroduction\u002Fisolation_filters","i-ri-filter-3-line",[],false,"Understand how MemOS Cloud separates users, Agents, conversations, and shared knowledge.",{"title":832,"path":833,"stem":882,"icon":831,"framework":6,"module":6,"class":883,"target":-1,"active":879,"defaultOpen":879,"children":-1,"description":884},"memos_cloud\u002Fmem_operations\u002Fadd_message",[],"MemOS automatically processes multimodal content such as text, files, and images into retrievable personal memories.",1779709046208]