Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
SELVEDGE_DBNoPath to the SQLite database file. Overrides project and global defaults.
SELVEDGE_QUIETNoSet to '1' to suppress warnings about using global database fallback.
SELVEDGE_LOG_LEVELNoLogging level for the Selvedge server. One of DEBUG, INFO, WARNING, ERROR.WARNING

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
log_changeA

Record 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 a create on the new path with metadata.renamed_from set — so the entity's history follows it. Example:

log_change(
    entity_path="src/auth/session.py::login",   # new path
    change_type="rename",
    rename_from="src/auth.py::login",            # old path
    entity_type="function",
    reasoning="Split auth.py into an auth/ package; login moved.",
)

On validation failure (invalid change_type, missing entity_path, or rename_from set without change_type='rename') the result is {"status": "error", "error": "..."} with no event written.

diffA

Get 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.

blameA

Most 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. If no history exists for the entity, returns {"error": "..."} with protocol-level isError: false.

historyA

Filtered 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.

changesetA

All 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."

searchA

Full-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'.

prior_attemptsA

Prior 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 with three extra fields:

  • outcome — "reverted" (a later remove/delete on the same path) or "active" (no later removal seen).

  • confidence — "proximity_high" or "proximity_low".

  • outcome_reasoning — the reverting event's reasoning (WHY it was rejected), or "" while still active.

Outcome is inferred from add->remove proximity — v0.3.7 has no explicit reject/revert change types yet (those arrive in v0.3.11). Output is templated, deterministic, and makes no LLM call. This is a pull-only tool: it never writes and never pushes; you decide when to ask.

Conservative by design — min_confidence defaults to "proximity_high", so an empty list (nothing clearly tried-and-rejected) is the normal, preferred answer over a speculative false positive. Pass min_confidence="proximity_low" to widen recall.

stale_decisionsA

Decisions whose revisit_after has passed AND that are still in active use.

The date-based half of active memory (v0.3.8). Returns events with a revisit_after now in the past — but ONLY when the entity is still live, so an old-but-correct decision nobody touches never nags. The required active-use signal is one of: the entity was queried (blame / diff / prior_attempts) at or after the decision, or its changeset_id saw later activity. Pure age alone does NOT surface.

Each result is the change event plus four fields: revisit_due (UTC ISO), days_overdue (int, 0 on the due day), active_use_signals (list), and stale_reason (a one-line summary). Most-overdue first; filter by entity_path, project, or agent. Date-based only — expires_when evaluation lands in v0.3.11. Templated and deterministic; no LLM call.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/masondelan/selvedge'

If you have feedback or need assistance with the MCP directory API, please join our Discord server