Skip to main content
Glama

run_plate_solve

Plate solve an open image offline against Gaia DR3/SP to add the astrometric solution required by run_spfc, run_mgc, and run_spcc. Provide approximate position and scale or rely on image keywords.

Instructions

Plate solve an open image with ImageSolver against the local Gaia DR3/SP database (offline). Adds the astrometric solution needed by run_spfc, run_mgc and run_spcc. Needs an approximate position (ra_deg, dec_deg; within a fraction of the field is enough) and scale (pixel_scale in arcsec/px, or focal_length_mm + pixel_size_um) unless the image keywords already carry RA, DEC and FOCALLEN/XPIXSZ. If the seeded solve fails, it is retried with the scale seed multiplied by 0.5, 2, 1/3 and 3 in turn (scale_search false tries the seed only). The result gives the solved scale from the solution, the expected scale (the seed, or the one the keywords give) and their ratio, which is far from 1 for a master a stacker resampled or drizzled. Observation time is read from DATE-OBS/DATE, else today. The result also states whether distortion correction and recursive surface splines were on.

Input Schema

NameRequiredDescriptionDefault
ra_degNoApproximate center RA in degrees
dec_degNoApproximate center Dec in degrees
view_idYesView ID to plate solve
pixel_scaleNoApproximate pixel scale in arcsec/pixel
scale_searchNoRetry with wider scale seeds when the seeded solve fails (default true)
pixel_size_umNoPixel size in microns
observation_jdNoJulian date of the observation (only if no DATE-OBS/DATE keyword)
focal_length_mmNoFocal length in mm (use with pixel_size_um instead of pixel_scale)
recursive_splinesNoImageSolver's "Recursive surface splines" distortion option (ImageSolver 6.5.0, PixInsight 1.9.5): models distortion with all matched stars as local surface splines over a quadtree. Omitted, the option keeps the value ImageSolver has. An older ImageSolver fails the call.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv2.5.0
    • addedInput schema / properties / recursive_splines
      Added value: +{
      +  "description": "ImageSolver's \"Recursive surface splines\" distortion option (ImageSolver 6.5.0, PixInsight 1.9.5): models distortion with all matched stars as local surface splines over a quadtree. Omitted, the option keeps the value ImageSolver has. An older ImageSolver fails the call.",
      +  "type": "boolean"
      +}
  2. Changed1 schema field changedv2.4.1
    • addedInput schema / properties / scale_search
      Added value: +{
      +  "description": "Retry with wider scale seeds when the seeded solve fails (default true)",
      +  "type": "boolean"
      +}
  3. First observedv2.1.0

TDQS

A4.6/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does so richly: retry ladder (0.5, 2, 1/3, 3) and its disabling via scale_search=false, observation-time fallback to today, and exactly what the result reports (solved vs expected scale and ratio, distortion/spline state). This is behavior an agent cannot get from the schema or annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action and routing, then the seeding requirements and result contents. Dense but each clause carries operative information; some sentences are long, which slightly hurts scannability but not information density.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex, 9-parameter tool with no output schema and no annotations, the description covers prerequisites, fallbacks, retry behavior, and return contents. An agent has everything needed to call it correctly and interpret the outcome.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline 3, but the description genuinely adds semantics: the tolerance on ra/dec ('a fraction of the field is enough'), the pixel_scale vs focal_length_mm+pixel_size_um equivalence, the exact retry multipliers behind scale_search, and that observation_jd is only needed absent DATE-OBS/DATE.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource ('Plate solve an open image with ImageSolver') plus the engine and database ('local Gaia DR3/SP, offline'), which distinguishes it from siblings like verify_astrometry or copy_astrometric_solution. It also names the downstream tools that consume the result.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explains prerequisites (approximate ra_deg/dec_deg and scale, or keywords carrying RA/DEC/FOCALLEN/XPIXSZ) and downstream usage (needed by run_spfc, run_mgc, run_spcc). It does not explicitly state when *not* to use it or point to an alternative seeding path, so it stops short of a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.