Commit Graph
4 Commits
Author SHA1 Message Date
emilandClaude Opus 4.7 d484de8390 Bump default n_ctx 8192 → 32768
8K filled up after one month of activity (~200 MB state) and the next
`memwalk update` crashed with llama_decode returned 1 because new
tokens didn't fit. Nemotron 3 Nano 4B is trained for 1M context so
32K is well within model capacity and leaves headroom for several
more months of ingest before rotation matters.

Note: existing users need to delete current.memb after upgrading,
since state files are tied to the n_ctx they were created with.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-16 14:10:01 +03:00
emilandClaude Opus 4.7 9877edd610 Add MCP server: expose memwalk as tools for Claude Code / opencode / agents
New `memwalk mcp` subcommand starts a stdio MCP server exposing four
tools: ask, standup, status, update. The underlying memba Session is
loaded lazily on the first call that needs the model, then reused for
the lifetime of the process — first query ~2s, subsequent <500ms.

- memwalk/mcp_server.py — Server + tool list/dispatch using mcp SDK
- memwalk/cli.py        — `memwalk mcp` subcommand wires it up
- pyproject.toml        — mcp>=1.0.0 dependency
- README.md             — setup instructions for Claude Code and opencode

Verified locally: tools/list returns all 4, tools/call status returns
the expected JSON without loading the model.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-16 14:04:25 +03:00
emilandClaude Opus 4.7 564478710e Fix 'noted' contextual inertia in queries
Two changes to memwalk/ingest.py:

1. Ingest prompt now asks the model for a brief theme + standout
   projects summary instead of "Reply noted". The "X → noted"
   pattern was training the model in-context to reply "noted" to
   every follow-up regardless of question.

2. query() wraps the user question in a short framing prefix
   ("Drawing on the work activity I shared with you earlier,
   please answer this clearly and concretely: ...") which is
   enough to break the noted pattern even on pre-existing state
   files, so existing users don't need to rebuild to benefit.

Verified on the maintainer's state: vague greetings still
default to noted (degenerate case, CLI is for questions),
but real questions like "What did I work on this past month?"
and "What features did I ship in Randify.pro?" now produce
detailed accurate responses. Standup output now includes
real blockers extracted from commit messages.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-16 13:55:29 +03:00
emilandClaude Opus 4.7 b873144b69 Initial v0.1: memwalk CLI on top of memba
- Config in ~/.memwalk/config.toml (typer init writes it)
- Sources: git log walker + bash history parser with secret/noise filters
- Ingest orchestrator feeds events into a memba Session and saves
  ~/.memwalk/current.memb via the rewritten Session.chat() that preserves
  loaded state (raw eval+sample, no KV-cache reset)
- Daily snapshot rotation under ~/.memwalk/snapshots/
- CLI commands: init, update, ask, standup, status, prune

Validated on Nemotron-3-Nano-4B Q4_K_M end-to-end: ingest 304 events
(303 commits + 1 shell session) in 2.8s on GPU, recall in fresh process
returns accurate per-project summaries.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-16 13:40:46 +03:00