alignment-doctor

alignment-doctor is an agent for Claude Code from jenkinsm13/metashape-mcp. It costs 75 tokens per session (2,359 once invoked), scanned A, original, MIT.

A troubleshooting agent for failed or inaccurate photo alignment in Agisoft Metashape, a program that builds 3D models from photographs. It investigates the cause of problems such as unaligned cameras, drift, or high reprojection error.

In plain words
What is it for?
Use it to diagnose low alignment rates, cameras in incorrect positions, coverage gaps, calibration problems, and high reprojection errors in Metashape projects.
Why use it?
It helps distinguish different alignment failures and identify likely causes, instead of merely reporting that the result is poor. It gathers alignment and sensor information before prescribing fixes.

Agent for Claude Code

Written for Claude Code: when-to-use in frontmatter.

Part of the metashape-mcp plugin — 12 skills, 8 agents, 2 hooks, 1 MCP server shipped together

Good fit Use it to diagnose low alignment rates, cameras in incorrect positions, coverage gaps, calibration problems, and high reprojection errors in Metashape projects.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/jenkinsm13/metashape-mcp/alignment-doctor
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/jenkinsm13/metashape-mcp

Made for: Claude Code.

Or install metashape-mcp, the plugin that ships this one along with the rest of its 12 skills, 8 agents, 2 hooks, 1 MCP server.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for alignment-doctor

README.md
[![agentmods](https://agentmods.dev/badge/agents/jenkinsm13/metashape-mcp/alignment-doctor/github.svg)](https://agentmods.dev/agents/jenkinsm13/metashape-mcp/alignment-doctor)
Your own site
<a href="https://agentmods.dev/agents/jenkinsm13/metashape-mcp/alignment-doctor"><img src="https://agentmods.dev/badge/agents/jenkinsm13/metashape-mcp/alignment-doctor/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for alignment-doctor

Your own site · 80×15
<a href="https://agentmods.dev/agents/jenkinsm13/metashape-mcp/alignment-doctor"><img src="https://agentmods.dev/badge/agents/jenkinsm13/metashape-mcp/alignment-doctor.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 75 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,359 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00075 $0.02359
Opus 5 $0.00037 $0.01179
Sonnet 5 $0.00015 $0.00472
Haiku 4.5 $0.00007 $0.00236

Measured 9d ago against content hash 1c093c2437d0, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

alignment-doctor scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/alignment-doctor.md · 184 lines

How it starts

The opening of the file, as written. The whole thing — 184 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Alignment Doctor

You are a diagnostic specialist for Metashape photo alignment problems. You investigate WHY alignment failed or produced bad results and prescribe specific, actionable fixes. You are NOT a QA checker (photogrammetry-qa handles that) -- you are called when something is already known to be wrong.

Diagnostic Protocol

When invoked, always gather data before diagnosing. Run these in order, stopping when you have enough information to diagnose:

Step 1: Triage -- What Kind of Problem?

Call get_alignment_stats() and list_sensors() to classify the problem:

Symptom Category
Alignment rate <50% Total failure -- sensor or matching problem
Alignment rate 50-85% Partial failure -- coverage gaps or difficult regions
Alignment rate >85% but cameras in wrong positions Geometric failure -- drift, split, or wrong connections
High reprojection error after optimization Calibration problem -- sensor model or lens mismatch

Step 2: Investigate by Category

Total Failure (<50% aligned)
  1. Check sensor configuration with list_sensors():

    • Fisheye lens not set as fisheye? This is the #1 cause. A fisheye on a standard lens model will fail catastrophically. Prescribe: set sensor type to fisheye.
    • Rolling shutter not enabled for video/electronic shutter? Causes matching failures on moving vehicles.
    • Multiple cameras sharing one sensor? If camera bodies differ, each needs its own sensor.
  2. Check image quality with analyze_images():

    • If >20% of images have quality <0.5, they are too blurry. Prescribe: disable cameras with quality <0.5.
  3. Check matching settings:

    • No reference preselection on a large corridor? Without it, Metashape tries to match every pair -- gets confused by repetitive road surfaces. Prescribe: reference_preselection=True.
    • Keypoint limit too low for fisheye? Default 40k is fine for rectilinear. Fisheye needs 60k+.
    • No guided matching on repetitive surfaces? Road asphalt is ambiguous. Prescribe: guided_matching=True.

Read the full file on GitHub · 184 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 184 lines · 75 tokens per session scan A 1c093c2437d0

Subscribe to this mod's changes

alignment-doctor is an agent published in the GitHub repository jenkinsm13/metashape-mcp (34 stars, last pushed 4mo ago), licensed MIT. It adds 75 tokens to every session and 2,359 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other agents, from other repositories

diagnose equipment root cause

Performs root cause analysis on process equipment using NeqSim's diagnostics framework — integrates multi-source reliability data (IOGP/SINTEF, CCPS, IEEE 493, Lees, OREDA), plant historian time-series, STID design conditions, and process simulation to produce ranked failure hypotheses with Bayesian confidence scoring.

equinor/neqsim · 71 tokens

equation-consistency-auditor

Audits equations, units, symbols, notation, and formula variants across a PaperLab book.

equinor/neqsim · 27 tokens

citizen-entomologist

Curiosity-driven insect guide that celebrates discovery, uses common names alongside scientific names, and channels observations into citizen science platforms like iNaturalist and BugGuide.

pjt222/agent-almanac · 36 tokens

debugger

Diagnoses data quality issues and analysis failures using scientific hypothesis-testing methodology. Invoked by orchestrator when errors occur during pipeline execution or when code-reviewer identifies complex issues requiring root-cause analysis.

brycewang-stanford/Auto-Empirical-Research-Skills · 42 tokens

debugger

Diagnose a repeated gate or slice-verify failure via bounded scientific-method hypothesis cycles, auto-invoked before the retry budget is spent.

Koroqe/claude-code-sdlc · 30 tokens

ma-aloha-consultant

Engage when the symptom is in the GENERATED helicity routines — ALOHA fails on a model's Lorentz structure (exotic/high-spin, custom lorentz.py), Source/DHELAS will not compile, or an amplitude value looks wrong; when you must READ or CALL exported ME routines — arg layout, ±IC(i) nsf/nsv signs; when the EMITTED…

MadGraphTeam/MadAgents · 212 tokens