bug(mcp): mem_save_prompt files prompts under the home-directory project on Cursor
Maintainers usually reply within 1 day
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 55/100
Research direction
Reproduce with the five steps in the issue: run engram mcp --tools=agent, call mem_current_project with and without a directory, then mem_save_prompt with only content and see it filed under the home-directory project. Find where the MCP server resolves the current project (the project_source: dir_basename vs config logic) and where mem_save_prompt picks its project, likely sharing the same resolution code as mem_current_project. Done: a prompt saved with only content lands in the workspace project from .engram/config.json. Note the possible duplicate #2116 — check whether the root cause is already tracked there.
Written by the indexing model from the issue text.
Description
Existing Issue Search
- I searched existing issues and will add evidence to a canonical tracker when applicable.
📝 Observed Consequence
mem_save_prompt stores the prompt under a project named after the home directory ("alexis") instead of the open workspace project ("macrodeck-frontend").
🔄 Steps to Reproduce
- Configure the user-level MCP server as
engram mcp --tools=agent, with no--projectand noENGRAM_PROJECT. - Open a workspace whose
.engram/config.jsoncontains"project_name": "macrodeck-frontend". - Call
mem_current_projectwith no arguments. - Call
mem_current_projectwithdirectoryset to that workspace. - Call
mem_save_promptwith onlycontent.
✅ Expected Behavior
I expected engram to store the prompt under the workspace project, macrodeck-frontend.
❌ Actual Behavior
Instead, this happened:
mem_current_project with no arguments:
cwd: /home/alexis
project: alexis
project_source: dir_basename
mem_current_project with directory set to the workspace:
cwd: /home/alexis/project/macrodeck/macrodeck-frontend
project: macrodeck-frontend
project_source: config
mem_save_prompt accepts content only. A call with only that field files the prompt under project alexis.
Operating System
Windows (WSL)
Release Version (Report Context)
3.6.0
Agent / Client
Cursor
📋 Relevant Logs
engram version
engram 3.6.0
mem_save_prompt parameters: content (required). No directory or cwd.
project is ignored unless project_choice_reason is user_selected_after_ambiguous_project.
💡 Additional Context
The Engram database living in the home directory is expected. The project label on the prompt is wrong.
Same gap as #2116, reproduced here on Cursor. Please treat this as another occurrence if the root is the same.
Pinning --project on the user-level server is not a fix: that one process serves every workspace.
- Dominant language
- Go
- Stars
- 7.1k
- Forks
- 729
- Avg merge
- 10h 46m
- Merged PRs (30d)
- 268
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Gentleman-Programming/engram
-
status:needs-review
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
Gentleman-Programming/engram#2065 · 1 comment ·
Maintainers usually reply within 1 day
-
feat(cli): run engram serve in the background as a daemon PR #2229Possibly taken @carolitascl claimed this 1 day ago. Openstatus:needs-review type:feature
Difficulty 4/5 3-5 days Newbie friendliness 35/100
Gentleman-Programming/engram#2228 · 1 comment ·
Maintainers usually reply within 1 day
-
status:needs-review type:feature
Difficulty 4/5 3-5 days Newbie friendliness 22/100
Gentleman-Programming/engram#2203 · 1 comment ·
Maintainers usually reply within 1 day
-
feat(store): reduce isolated test fixture startup costPossibly taken @dnlrsls claimed this 4 days ago. Openstatus:approved type:feature
Gentleman-Programming/engram#2202 · 1 comment · 1 assignee ·
Maintainers usually reply within 1 day
-
status:needs-review type:question
Difficulty 5/5 Over a week Newbie friendliness 20/100
Gentleman-Programming/engram#2201 · 3 comments ·
Maintainers usually reply within 1 day
All issues in Gentleman-Programming/engram
Similar issues
-
[BUG] serviceenvupdater filter does not update KUBERNETES_SERVICE_HOST/PORT in init containersPossibly taken @RaphaelFakhri claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
openyurtio/openyurt#2845 ·
Maintainers usually reply within 7 days
-
enhancement good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
fix(scan): validate and normalize output format in validate-contractPossibly taken @WKr1shna claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
bug good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 70/100