Selvedge
Persistent decision memory for AI agents: rationale, rejected approaches, and entity history.
Connector by masondelan · GitHub account verified by the MCP Registry
Chalk Labs
Need help deploying Selvedge?
Chalk Labs sets up agents like this inside real teams: connected to your tools, tested on your data, with a human in the loop where it matters.
Install
Works with Claude Code, Codex, VS Code, Cursor, Windsurf, Claude Desktop. Read the repository before you give any tool access to your data.
npx agentmarket install connector/masondelan-selvedge
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: agent-memory
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this server can do and what it asks for, from its tool list, install config and code. Checked Oct 25, 2026.
- Tools
- 8 read · 4 write · 0 delete · 2 not yet classified
- Secrets
- None asked for
- Install scripts
- None found
- Runs as
- Python package
Tools by what they do 14
Read from the source code; the running server may list different tools.
Read 8 · Look things up without changing anything.
blamechangesetdiffhistoryread_decisionsread_fileread_projectsearch
Write 4 · Create, change, send or run things.
apply_choicelog_changerun_checkswrite_file
Not yet classified 2 · We could not tell from the name and description.
prior_attemptsstale_decisions
Secrets and settings it asks for
Other settings (environment variables or headers).
SELVEDGE_DB
Network hosts it talks to 8
agent-trace.dev· found in codeapi.github.com· found in codedocs.astral.sh· found in codegithub.com· found in codeglama.ai· found in codepipx.pypa.io· found in codeselvedge.sh· found in codetelemetry.selvedge.sh· found in code
Files it touches
~/.claude/dev/null- Your home directory (~)
~/.config/something/file.md~/.cursor~/.cursor/mcp.json~/.selvedge~/.selvedge/config.toml~/.selvedge/selvedge.db~/.selvedge/telemetry.json- Any path the agent passes to its tools
Tools (14)
Read from the source code; the running server may differ. Descriptions are the server’s own words; hidden characters are shown as [U+…].
apply_choiceWrite one allowed value to this fixture's configuration and explain why.
blameBlame an entityMost recent change to an entity — what changed, when, who, why. Like `git blame` but for semantic entities (DB columns, functions, env vars, dependencies) and AI agents. Also carries the derived decision state: `status` (`active` / `reverted` / `reopened`) and `superseded_by` (id of a later supersede overriding this change, or ""). If no history exists for the entity, returns `{"error": "..."}` with protocol-level `isError: false`.
changesetGet a changesetAll events that share a `changeset_id`, oldest first. Use to reconstruct the full scope of a feature or task across multiple entities. If the changeset has no events, returns `[{"error": "..."}]` so the caller can distinguish "unknown changeset" from "empty history."
diffDiff an entity's historyGet change history for a codebase entity, newest first. Supports prefix matching — e.g. 'users' returns all events for the users table and any users.* column. Each event carries a derived `superseded_by` id ("" when nothing overrode it), so the tried → reverted → re-opened trail reads straight off the history.
historyBrowse historyFiltered change history across all entities, newest first. Combine `since`, `entity_path`, `project`, and `changeset_id` to scope the result. On unparseable `since` input the response is `[{"error": "..."}]` so the caller sees the problem.
log_changeLog a code changeRecord a change to a codebase entity. Call this immediately after making any meaningful change. The event is written to the local SQLite store and returned with its assigned id and timestamp. If the reasoning fails the quality validator (empty, too short, or a generic placeholder), or the entity_path doesn't match the usual shape for its entity_type, the result includes a `warnings` array — the event is still stored. Renames: pass the new path in `entity_path`, set `change_type="rename"`, and pass the old path in `rename_from`. Selvedge then writes two events — a `rename` on the old path and…
prior_attemptsPrior attempts on an entityPrior change attempts on an entity, each with an inferred outcome. Call this BEFORE editing an entity. If the same change was tried before and reverted, you get the prior `reasoning` and `change_type` plus an inferred `outcome` — so you can change your plan instead of repeating a rejected approach. Each result is a change event plus the trail fields: `outcome` ("reverted" — a later removal on the path; "reopened" — closed but a later supersede re-opened it; "rejected" — a standalone `reject` event that closed no earlier attempt, surfaced as its own row whose reasoning IS the record; "active"…
read_decisionsRead the project's maintained decision file, if one exists.
read_fileRead an exact project filename; no filesystem traversal or host access.
read_projectRead the current task, permitted Python subset and available project files.
run_checksExecute the public checks against the written solution, at most twice.
searchSearch eventsFull-text search across entity paths, diffs, reasoning, and agents. Useful for questions like 'what changes were made for the billing feature?', 'which columns were added by cursor?', or 'show everything related to authentication'.
stale_decisionsStale decisions due for revisitDecisions due for a revisit — expired, past their date, or with a triggered stale condition. Three deterministic rules. Expiry-based (`flag="expired"`): events whose `expires_when` condition fired, evaluated from local state only — `date:` against now, `entity:PATH:changes` against the event log, `library:NAME>=VERSION` against installed dist metadata; the pattern kind that fired is in `expired_pattern`. A `library:` condition whose dependency isn't locally observable surfaces as `flag="manual_review"` instead of a guess; `manual:LABEL` never auto-fires. Date-based (`flag="revisit_due"`): eve…
write_fileWrite solution.py only (at most two writes, at most 16,000 characters).
Signals
- Stars
- 25
- Forks
- 1
- Open issues
- 2
- Contributors
- 3
- Weekly downloads
- 144
- Last commit
- Oct 24, 2026 (7 days ago)
- Last release
- Oct 16, 2026 (15 days ago)
- Last package publish
- Oct 16, 2026 (15 days ago)
From GitHub (fetched Oct 24, 2026) and the package registry.
Details
- Registry name
io.github.masondelan/selvedge- Version
- 0.3.17
- Auth
- No auth
- Packages
- pypi selvedge
- License
- MIT
- Repository
- github.com/masondelan/selvedge
- Website
- selvedge.sh
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
Done for you
Rather not set it up yourself?
Chalk Labs scopes, builds and runs agents for your team: the task audit, the eval harness, the integrations and the weekly ops report. Fixed scope, priced before we start.
See how we build AI agents →Read the case studies
Chalk Labs is a two-founder AI and growth studio. We build AI agents, CRMs and MVPs for Web3 and AI companies, and have shipped 50+ product and token launches.
- launches shipped
- 50+
- launches shipped
- media placements
- 500+
- media placements
- founders on every account
- 2
- founders on every account
Press we've placed: Forbes · CoinDesk · Decrypt · Cointelegraph · The Block
Rahil Jain, Co-founder, Chalk Labs. Ex-Goldman Sachs engineer. You talk to the person who builds it.
Get Selvedge running in your business
Tell us what you want to automate. A founder replies within one working day with a plan, not a pitch deck.
Cite this page
Selvedge MCP server. Agent Mart. https://agentmart.dev/connectors/masondelan-selvedge (last updated 2026-10-24)