Get context
get_contextRetrieve relevant memories and format a pre-rendered context block for any topic or project. Scope by tags, collections, and memory filters.
Instructions
Build a formatted context block for the current topic. Omit topic and collection to show the text collection picker (Memxus menu flow). Call list_collections when unsure of the exact slug. Partial collection names are resolved server-side. If the user's first message appears to be a coding task, technical question, or project-related request, call get_context with the detected topic BEFORE responding — do not wait for the user to ask. After this tool returns, show the user the pre-rendered block at the end of the tool result verbatim (user_facing_template). Do not repeat the raw context_block. Expand context: if count < total, recall/get_context with exclude_memory_ids + higher max_memories; if count === total, say no more memories without calling the server. Skills: use N → use_skill_in_chat, install N → install_skill, skip N → skip_skill.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tags | No | Optional tags. A tag like project:my-app also sets collection automatically. | |
| type | No | Memory category: general, preference, fact, instruction, or conversation. Omit to include all types. | |
| topic | No | Subject to build context for (e.g. "current project", "client meeting notes"). Omit with collection to show the collection picker. | |
| group_id | No | UUID of a shared group. Required with visibility=shared when group_name is not set. | |
| collection | No | Scope slug (e.g. project:memxus, personal:preferences). GitHub/Notion connector syncs use project:<slug> — one collection per project. Partial names work; call list_collections when unsure. | |
| group_name | No | Exact group name (case-insensitive). Alternative to group_id for shared memories. | |
| visibility | No | Optional. Defaults to user dashboard preference (private unless include_group_memories_in_context is on). | |
| max_memories | No | Max memories in context block. Omit for server default (10). Capped per your plan. | |
| include_skills | No | When showing the collection picker, set true if the user chose context + skills (default false). | |
| exclude_memory_ids | No | Memory IDs to exclude (for "Ampliar el contexto" follow-up calls). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | collection_picker when showing the collection selector; omitted for context results. | |
| count | Yes | Number of memories included. | |
| topic | No | Topic that was searched. | |
| total | No | Total eligible memories for ranking (before LIMIT). | |
| message | Yes | Human-readable output (same as content text). | |
| memories | No | Memories used to build the context block. | |
| truncated | No | True when memories were trimmed to the token budget. | |
| collections | No | Collections shown in picker mode. | |
| tokens_used | No | Estimated tokens in the context block. | |
| context_block | No | Formatted context block for injection into the conversation. | |
| impact_summary | No | ||
| impact_summary_text | No | Token reuse line for the AHORRO block when ENABLE_IMPACT_SUMMARY is on. |