Skip to main content
Glama

report_execution

Posts verification results (pass/fail/flaky/skipped) per node to update confidence scores, transforming static priors into ground-truth-based estimates.

Instructions

Closes the verification feedback loop. External executors (any MCP-compatible coding agent, CI runner, or human) post back verification results — pass / fail / flaky / skipped — keyed to nodeId + tier + directive. Veris persists these in local SQLite state, applies them to confidence math (14-day half-life decay, flaky = half-credit), and uses them on subsequent runs to raise or lower confidence per node. Without this call, confidence is a static prior; with it, confidence reflects ground truth. Call once per batch of executed targets, not per-target — payload accepts an array.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
executionsYes

Implementation Reference

  • The handleReportExecution method is the core handler for the 'report_execution' tool. It accepts an array of execution results (each with nodeId, tier, result, and optional workflowId/directive/detail/durationMs), persists them via VerisState.recordExecution(), and returns the count of recorded executions along with the run ID.
    private handleReportExecution(args: any) {
        const executions = args.executions || [];
        if (!this.lastRunId) this.lastRunId = this.state.newRunId();
        const now = new Date().toISOString();
        for (const e of executions) {
            this.state.recordExecution({
                runId: this.lastRunId,
                nodeId: e.nodeId,
                workflowId: e.workflowId ?? null,
                tier: e.tier,
                directive: e.directive ?? '',
                result: e.result,
                detail: e.detail,
                durationMs: e.durationMs,
                executedAt: now
            });
        }
        return this.text({ recorded: executions.length, runId: this.lastRunId });
    }
  • The tool definition for 'report_execution' including inputSchema. It defines the 'executions' array parameter where each item has nodeId, workflowId, tier, directive, result (enum: pass/fail/skipped/flaky), detail, and durationMs. The description explains it closes the verification feedback loop by persisting verification results into SQLite state.
    { name: "report_execution",
      description: "Closes the verification feedback loop. External executors (any MCP-compatible coding agent, CI runner, or human) post back verification results — pass / fail / flaky / skipped — keyed to nodeId + tier + directive. Veris persists these in local SQLite state, applies them to confidence math (14-day half-life decay, flaky = half-credit), and uses them on subsequent runs to raise or lower confidence per node. Without this call, confidence is a static prior; with it, confidence reflects ground truth. Call once per batch of executed targets, not per-target — payload accepts an array.",
      inputSchema: {
          type: "object",
          properties: {
              executions: {
                  type: "array",
                  items: {
                      type: "object",
                      properties: {
                          nodeId: { type: "string" },
                          workflowId: { type: "string" },
                          tier: { type: "string" },
                          directive: { type: "string" },
                          result: { type: "string", enum: ["pass", "fail", "skipped", "flaky"] },
                          detail: { type: "string" },
                          durationMs: { type: "number" }
                      },
                      required: ["nodeId", "tier", "result"]
                  }
              }
          },
          required: ["executions"]
      } },
  • The registration in the CallToolRequestSchema handler. When the tool name is 'report_execution', it dispatches to handleReportExecution(args).
    this.server.setRequestHandler(CallToolRequestSchema, async (request) => {
        const args = (request.params.arguments || {}) as any;
        switch (request.params.name) {
            case "analyze_repository": return this.handleAnalyzeRepository();
            case "export_behavioral_graph": return this.handleExportGraph();
            case "analyze_pr_behavior": return this.handleAnalyzePr(args);
            case "generate_verification_plan": return this.handleGeneratePlan();
            case "identify_unverified_behaviors": return this.handleIdentifyUnverified(args);
            case "list_workflows": return this.handleListWorkflows();
            case "analyze_workflow": return this.handleAnalyzeWorkflow(args);
            case "detect_drift": return this.handleDetectDrift();
            case "generate_adversarial_probes": return this.handleGenerateProbes();
            case "allocate_budget": return this.handleAllocateBudget(args);
            case "what_if_revert": return this.handleWhatIfRevert(args);
            case "report_execution": return this.handleReportExecution(args);
            case "confidence_history": return this.handleConfidenceHistory(args);
            case "node_history": return this.handleNodeHistory(args);
            case "export_onboarding": return this.handleExportOnboarding();
            case "cross_repo_snapshot": return this.handleCrossRepoSnapshot();
            case "register_repo": return this.handleRegisterRepo(args);
            default: throw new Error(`Unknown tool: ${request.params.name}`);
        }
    });
  • The recordExecution method on VerisState persists a single ExecutionRecord into the local SQLite 'executions' table. This is the persistence helper called by handleReportExecution.
    public recordExecution(rec: ExecutionRecord): void {
        if (!this.db) return;
        const payload = {
            ...rec,
            detail: rec.detail ?? null,
            durationMs: rec.durationMs ?? null,
            executedAt: rec.executedAt ?? new Date().toISOString(),
            workflowId: rec.workflowId ?? null
        };
        this.db.prepare(`
            INSERT OR REPLACE INTO executions
            (run_id, node_id, workflow_id, tier, directive, result, detail, duration_ms, executed_at)
            VALUES (@runId, @nodeId, @workflowId, @tier, @directive, @result, @detail, @durationMs, @executedAt)
        `).run(payload);
    }
  • The ExecutionRecord interface defines the shape of execution data that the report_execution handler produces and recordExecution consumes.
    export interface ExecutionRecord {
        runId: string;
        nodeId: string;
        workflowId: string | null;
        tier: string;
        directive: string;
        result: 'pass' | 'fail' | 'skipped' | 'flaky';
        detail?: string;
        durationMs?: number;
        executedAt?: string;
    }
Behavior5/5

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

Despite no annotations, the description fully discloses key behaviors: results persist in SQLite, affect confidence math with 14-day half-life decay and flaky=half-credit, and are used on subsequent runs. It also notes the payload accepts an array for batching. This goes well beyond a simple action statement.

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?

The description is longer but each sentence adds value: purpose, usage pattern, behavioral impact, and batch recommendation. It is front-loaded with the core action. Could be slightly tighter but not wasteful.

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

Completeness3/5

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

No output schema is provided, and the description does not mention return value or error handling. While the purpose and behavior are clear, an agent would benefit from knowing what the response contains. Given the tool's complexity, this is a moderate gap.

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

Parameters3/5

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

Schema coverage is 0%, so description must compensate. It mentions parameters are 'keyed to nodeId + tier + directive', adding context to the grouping. It also lists 'pass / fail / flaky / skipped' for result enum, but does not detail fields like detail or durationMs. Partial compensation but not fully comprehensive.

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?

The description clearly states the tool closes the verification feedback loop by posting results. It specifies the verb 'post', the resource 'verification results', and the context of external executors. It distinguishes from siblings like 'generate_verification_plan' or 'analyze_workflow' by focusing on result reporting.

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?

The description provides explicit guidance: 'Call once per batch of executed targets, not per-target'. It explains the necessity of this call for confidence tracking and implies it is for external executors. However, it does not explicitly state when not to use or name alternatives.

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

Install Server

Other Tools

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/vighriday/Veris'

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