Skip to main content
Glama

Contact Setup

contact_setup

Set up surface-to-surface contact between face pairs for CalculiX simulations and enable nonlinear solver behavior, with optional friction and penalty stiffness.

Instructions

Set up surface-to-surface contact between face pairs for a CalculiX solve and flip the solver to nonlinear — no new solver (promotes the CCX contact/nonlinear flags the FEM path already exposes). face_pairs is a list of {a:{handle, tag|face}, b:{handle, tag|face}} (master, slave) pairs; friction is the Coulomb coefficient (0 = frictionless); slope optionally sets the penalty contact stiffness; nonlinear (default True) sets the solver's GeometricalNonlinearity.

Run fem_run + fem_results after. Gate RELATIVE to a bonded reference on the same mesh: a bonded model is stiffer (less peak displacement) than frictional contact. Returns {contacts:[handles], n_pairs, friction, nonlinear}.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "analysis": "<analysis>",
      "face_pairs": "<face_pairs>"
    },
    "name": "contact_setup"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameNoContact
slopeNo
analysisYes
frictionNo
nonlinearNo
workspaceNoRun this call in this named workspace
face_pairsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.5.7
    • addedInput schema / properties / workspace
      Added value: +{
      +  "default": "",
      +  "description": "Run this call in this named workspace",
      +  "title": "Workspace",
      +  "type": "string"
      +}
  2. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations only say readOnlyHint=false, destructiveHint=false, openWorldHint=false; the description goes further by disclosing that the call mutates solver state (GeometricalNonlinearity), that no new solver object is created, and what the return payload looks like. It stops short of saying whether existing contact definitions are overwritten or whether the change is reversible.

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

Conciseness5/5

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

The operation and its solver side effect come first, parameter semantics follow, then the required follow-up calls and the return shape. Four dense sentences, no filler, and the parenthetical about not creating a new solver earns its place by preventing a wrong mental model.

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

Completeness4/5

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

With no output schema, the description supplies the return shape ({contacts, n_pairs, friction, nonlinear}) and the downstream run/results sequence, which is what an agent needs to close the loop. Only the `analysis` handle's provenance and any overwrite/reversibility semantics are missing.

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 only 14%, so the description carries the burden and largely does: it spells out the nested {a:{handle,tag|face}, b:{...}} master/slave structure, defines friction as the Coulomb coefficient with 0 = frictionless, and explains slope as penalty stiffness and nonlinear's default. The `analysis` and `name` parameters are never explained, and units for slope are unspecified.

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 and resource ('Set up surface-to-surface contact between face pairs') plus the solve target ('for a CalculiX solve'), and names the non-obvious side effect (flips the solver to nonlinear). It also distinguishes itself from adjacent FEM tools by clarifying it creates no new solver and only promotes existing CCX flags, so an agent can tell it apart from fem_add_constraint/fem_set_solver.

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?

Explicitly prescribes the follow-on workflow ('Run fem_run + fem_results after') and gives a validation rule ('Gate RELATIVE to a bonded reference on the same mesh'). It does not, however, state when to prefer this over the sibling fem_add_constraint or the analytical hertz_contact check, so alternatives are left implicit.

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

Deploy Server

Other Tools