code-guardian
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| CODE_GUARDIAN_LLM_KEY | No | Optional bearer token for the LLM endpoint. | |
| CODE_GUARDIAN_LLM_URL | No | An Ollama `/api/chat` URL or any OpenAI-compatible `/v1/chat/completions` URL, detected by path (a bare host means Ollama, a `.../v1` base means OpenAI-compatible). Only needed for the `explain` tool. | |
| CODE_GUARDIAN_LLM_MODEL | No | The model to use for the plain-English explanation, e.g. qwen3:8b. Only needed for the `explain` tool. | |
| CODE_GUARDIAN_LLM_TIMEOUT | No | Optional timeout in seconds for the LLM request (default 60). |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| scanA | Is it safe to run, will it work, does it have what it needs? Safe, Works and Complete scores (0-100, higher is better), Overall and an A-F grade, every finding with file:line, the egress inventory and orphan-code hygiene. Deterministic; parses only, never runs the code. |
| orphansB | Functions, classes and modules nothing reachable from the project's entry points uses: dead, test-only or uncertain (dynamic dispatch). Judged against the goal contract when there is one. |
| explainA | Runs scan, then asks the local model at CODE_GUARDIAN_LLM_URL for a plain-English summary. Sends the findings only (no source). The score never changes; without a model it returns a note. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 3 tools
scan and orphans overlap since scan already reports 'orphan-code hygiene' while orphans drills into the same dead-code data, and explain is a wrapper that reruns scan. The descriptions do clarify the distinctions (drill-down vs. narrative), but boundaries are not fully crisp.
All three names are single lowercase words with a consistent style (scan, orphans, explain), which is readable and predictable. There is minor inconsistency in word class (two verbs vs. one noun) and no verb_noun pattern, but the convention is uniform enough.
Three tools is slightly thin but each earns its place: a primary scan, a focused drill-down, and an LLM summary mode. The surface fits the narrow, well-defined purpose of static safety scanning without redundancy.
For a parse-only safety/completeness scanner, the set covers the core workflow (assess safety, inspect dead code, get a plain-English explanation) with graceful degradation when no model is available. Minor gaps exist around configuration/dependency analysis, but core needs are met.