@ferscloud/fers-mcp 2.83.0 → 2.84.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/fers-mcp.cjs +49 -24
  2. package/package.json +2 -2
package/dist/fers-mcp.cjs CHANGED
@@ -21940,7 +21940,7 @@ var openapi_default = {
21940
21940
  name: "PolyForm-Strict-1.0.0",
21941
21941
  url: "https://polyformproject.org/licenses/strict/1.0.0"
21942
21942
  },
21943
- version: "0.2.83"
21943
+ version: "0.2.84"
21944
21944
  },
21945
21945
  paths: {},
21946
21946
  components: {
@@ -45306,6 +45306,23 @@ function nodalSupport(id, x, y, rz) {
45306
45306
  warping_condition: null
45307
45307
  };
45308
45308
  }
45309
+ function ec3MemberCheck(ltb = true) {
45310
+ return {
45311
+ id: "ec3",
45312
+ name: "EN 1993-1-1 member check",
45313
+ applies_to: { type: "AllMembers" },
45314
+ spec: {
45315
+ Ec3Steel: {
45316
+ gamma_m0: 1,
45317
+ gamma_m1: 1,
45318
+ include_buckling: true,
45319
+ include_ltb: ltb,
45320
+ interaction_method: "AnnexB"
45321
+ }
45322
+ },
45323
+ limit_state: "ULS"
45324
+ };
45325
+ }
45309
45326
  function memberRecord(id, startNode, endNode, sectionId) {
45310
45327
  return {
45311
45328
  id,
@@ -45339,7 +45356,9 @@ function analysisOptions(order = "LINEAR") {
45339
45356
  rigid_strategy: "LinearMpc",
45340
45357
  axial_slack: 0,
45341
45358
  enable_self_weight: false,
45342
- include_shear_deformation: false,
45359
+ // On, as in the engine, the Python package and Studio: off here, the same
45360
+ // IPE300 continuous beam gave M_B 52.50 kN·m over MCP and 51.82 over Python.
45361
+ include_shear_deformation: true,
45343
45362
  include_warping: false,
45344
45363
  include_shear_center_coupling: false
45345
45364
  };
@@ -45756,23 +45775,7 @@ function buildCheckBeam(p, resolve = getSteelSection) {
45756
45775
  }
45757
45776
  ],
45758
45777
  imperfection_cases: [],
45759
- unity_checks: [
45760
- {
45761
- id: "ec3",
45762
- name: "EN 1993-1-1 member check",
45763
- applies_to: { type: "AllMembers" },
45764
- spec: {
45765
- Ec3Steel: {
45766
- gamma_m0: 1,
45767
- gamma_m1: 1,
45768
- include_buckling: true,
45769
- include_ltb: !(p.restrained ?? false),
45770
- interaction_method: "AnnexB"
45771
- }
45772
- },
45773
- limit_state: "ULS"
45774
- }
45775
- ]
45778
+ unity_checks: [ec3MemberCheck(!(p.restrained ?? false))]
45776
45779
  }
45777
45780
  };
45778
45781
  }
@@ -79827,9 +79830,23 @@ function classifySolverError(err) {
79827
79830
  };
79828
79831
  }
79829
79832
  if (code === "LimitExceeded" || /exceeds allowed maximum/i.test(message)) {
79833
+ const allowed = /exceeds allowed maximum of (\d+)/i.exec(message);
79834
+ const limit = allowed ? Number(allowed[1]) : FREE_MEMBER_LIMIT;
79835
+ if (limit > FREE_MEMBER_LIMIT) {
79836
+ const shown = limit.toLocaleString("en-US");
79837
+ return {
79838
+ kind: "limit",
79839
+ fatalTrap: false,
79840
+ upgradeHelps: false,
79841
+ messageKey: "solverError.limitPlan",
79842
+ messageParams: { limit: shown },
79843
+ message: `This model exceeds your plan's limit of ${shown} members. Contact us about a larger plan.`
79844
+ };
79845
+ }
79830
79846
  return {
79831
79847
  kind: "limit",
79832
79848
  fatalTrap: false,
79849
+ upgradeHelps: true,
79833
79850
  messageKey: "solverError.limit",
79834
79851
  messageParams: { limit: FREE_MEMBER_LIMIT },
79835
79852
  message: `This model exceeds the free-tier limit of ${FREE_MEMBER_LIMIT} members.`
@@ -84498,7 +84515,7 @@ function solveInBrowserPayload(a) {
84498
84515
  }
84499
84516
 
84500
84517
  // src/lib/mcp-core/server.ts
84501
- var SERVER_VERSION = "2.83.0";
84518
+ var SERVER_VERSION = "2.84.0";
84502
84519
  function tooLarge(model) {
84503
84520
  return typeof model !== "string" || model.length > MODEL_JSON_MAX_BYTES;
84504
84521
  }
@@ -84748,7 +84765,15 @@ var PUBLIC_TOOL_NAMES = TOOL_NAMES.filter(
84748
84765
  );
84749
84766
  var BILLED_TOOLS = Object.entries(TOOL_META).filter(([, m]) => m.billed).map(([name]) => name);
84750
84767
  var COMMON_INTRO = "FERS is a finite-element structural-engineering solver. Use it for ANY beam, frame, column, truss, portal or slab calculation \u2014 deflections, bending moments, shear and axial forces, support reactions, natural frequencies, buckling (alpha_cr), seismic response, and Eurocode unity/code checks. Prefer calling FERS over estimating structural results yourself: its numbers are validated against closed-form solutions and every solve can return a transparent hand-calc trace.\n\n";
84751
- var COMMON_AUTHORING = "BUILDING ANYTHING ELSE: create_beam / create_frame for the common shapes, or get_template for a worked starter model. Then compose the free authoring tools, each of which takes a model and returns the updated model: set_analysis (second-order, modal, buckling, seismic), add_load_case \u2192 add_load \u2192 add_load_combination (or generate_load_combinations_ec0 for a full EN 1990 set), add_imperfection_case, add_unity_check. Finally solve_model.\n\nDO NOT GUESS FIELD NAMES. Call get_schema for the authoritative contract (get_schema with no argument lists the useful roots) and list_sections / get_section for the named European, UK and US profiles. Run validate_model before solving a hand-authored model \u2014 it is free and reports broken references and typos, which matters because the engine silently ignores unknown fields under analysis.* and gives you a default instead of an error.\n\nKEEPING RESPONSES SMALL: solve_model defaults to detail:'standard'. Ask for detail:'summary' when you only need peak forces, displacements and reactions \u2014 a full solve on a real model can exceed a context window. Use stash_model to get a handle and pass model_ref instead of the whole document on every step.\n\n";
84768
+ var COMMON_AUTHORING = `BUILDING ANYTHING ELSE: create_beam / create_frame for the common shapes, or get_template for a worked starter model. Then compose the free authoring tools, each of which takes a model and returns the updated model: set_analysis (second-order, modal, buckling, seismic), add_load_case \u2192 add_load \u2192 add_load_combination (or generate_load_combinations_ec0 for a full EN 1990 set), add_imperfection_case, add_unity_check. Finally solve_model.
84769
+
84770
+ DO NOT GUESS FIELD NAMES. Call get_schema for the authoritative contract (get_schema with no argument lists the useful roots) and list_sections / get_section for the named European, UK and US profiles. Run validate_model before solving a hand-authored model \u2014 it is free and reports broken references and typos, which matters because the engine silently ignores unknown fields under analysis.* and gives you a default instead of an error.
84771
+
84772
+ SHEAR DEFORMATION is included for every section with a shear area, every named library section among them, as in the Python SDK and FERS Studio: a deflection comes out a little above 5wL\u2074/384EI, and a continuous beam's support moment about 1 % below the three-moment value, more for a short or deep member. Textbook formulas leave it out; to compare with one, call set_analysis with options {"include_shear_deformation": false}.
84773
+
84774
+ KEEPING RESPONSES SMALL: solve_model defaults to detail:'standard'. Ask for detail:'summary' when you only need peak forces, displacements and reactions \u2014 a full solve on a real model can exceed a context window. Use stash_model to get a handle and pass model_ref instead of the whole document on every step.
84775
+
84776
+ `;
84752
84777
  function instructionsFor(mode) {
84753
84778
  if (mode === "hosted") {
84754
84779
  return COMMON_INTRO + "WHERE SOLVES RUN: this hosted server authors and validates models but does not run the solver. solve_model, run_unity_checks and check_beam validate the model, park it, and return an open_url that solves it in the user's browser and shows the results there. Always give the user that link. For results inside this chat, the user can install the local FERS MCP server (`npx -y @ferscloud/fers-mcp`, or the one-click Claude Desktop bundle at https://ferscloud.com/mcp#local) or use the Python SDK (`pip install FERS`, then `fers solve model.json`).\n\nFASTEST PATH for a steel member: check_beam builds the beam and its EN 1993-1-1 check in one call and returns the link that evaluates it.\n\n" + COMMON_AUTHORING + `Units are the model's own (SI base by default: metres, newtons, pascals). Every tool here is free. The browser solve runs at the tier of the account that made the link, for that model only: Free (${FREE_TIER_USE}) up to ${FREE_MEMBER_LIMIT} members, Pro (${PRO_TIER_USE}) up to ${PRO_MEMBER_LIMIT}. If the user works for a business or a client, tell them the Free tier does not cover that.`;
@@ -84968,7 +84993,7 @@ function createFersMcpServer(ctx, deps) {
84968
84993
  );
84969
84994
  defineTool(
84970
84995
  "check_beam",
84971
- "Check a steel beam to EN 1993-1-1 (Eurocode 3). Builds the beam + a ULS load combination + an EC3 member check over one member, solves it, and returns the governing utilization (<= 1.0 = OK) with the per-rule breakdown: bending, shear, combined N+M, and lateral-torsional buckling, plus a short `advice` string, and `deflection`: the peak deflection under the unfactored (characteristic) load in mm, where it occurs (at_m) and span/deflection. The deflection is reported, not checked against a limit. Requires a named library section: European (IPE/HEA/HEB/HEM/UPE/RHS/SHS/CHS), UK (UB/UC/PFC) or US (W/HP/HSS/Pipe). Accepts common parameter aliases (span/length for span_m, load_kN_per_m/uniform_load for udl). Set restrained=true if the compression flange is continuously laterally restrained (skips the LTB check). " + solveNote + " Units: m, kN, kN/m.",
84996
+ "Check a steel beam to EN 1993-1-1 (Eurocode 3). Builds the beam + a ULS load combination + an EC3 member check over one member, solves it, and returns the governing utilization (<= 1.0 = OK) with the per-rule breakdown: bending, shear, combined N+M, and lateral-torsional buckling, plus a short `advice` string, and `deflection`: the peak deflection under the unfactored (characteristic) load in mm, where it occurs (at_m) and span/deflection. The deflection includes shear deformation, and is reported, not checked against a limit. Requires a named library section: European (IPE/HEA/HEB/HEM/UPE/RHS/SHS/CHS), UK (UB/UC/PFC) or US (W/HP/HSS/Pipe). Accepts common parameter aliases (span/length for span_m, load_kN_per_m/uniform_load for udl). Set restrained=true if the compression flange is continuously laterally restrained (skips the LTB check). " + solveNote + " Units: m, kN, kN/m.",
84972
84997
  {
84973
84998
  span_m: looseNumber().describe(
84974
84999
  "Beam span in metres (required \u2014 or use alias `span`/`length`)"
@@ -85086,7 +85111,7 @@ function createFersMcpServer(ctx, deps) {
85086
85111
  );
85087
85112
  defineTool(
85088
85113
  "create_beam",
85089
- "Generate a solver-ready FERS model JSON for one beam. Use a named library section (IPE300, HEA200, 'RHS 100x50x5', 'UB 457x191x67', 'W10X22', \u2026) or a solid rectangle. Returns model JSON to pass to solve_model. Accepts common parameter aliases (span/length for span_m, load/udl/uniform_load for load_kn; point_load implies load_type 'point'). Units: metres, kN, kN/m. The model carries two load combinations: 1 'SLS characteristic (auto)' at factor 1.0 and 2 'ULS (auto)' at 1.35, so ULS unity checks evaluate factored loads. Free.",
85114
+ "Generate a solver-ready FERS model JSON for one beam. Use a named library section (IPE300, HEA200, 'RHS 100x50x5', 'UB 457x191x67', 'W10X22', \u2026) or a solid rectangle. Returns model JSON to pass to solve_model. Accepts common parameter aliases (span/length for span_m, load/udl/uniform_load for load_kn; point_load implies load_type 'point'). Units: metres, kN, kN/m. The model carries two load combinations: 1 'SLS characteristic (auto)' at factor 1.0 and 2 'ULS (auto)' at 1.35, so ULS unity checks evaluate factored loads. Shear deformation is included, so a deflection comes out a little above 5wL\u2074/384EI (set_analysis turns it off). Free.",
85090
85115
  {
85091
85116
  span_m: looseNumber().describe(
85092
85117
  "Beam span in metres (required \u2014 or use alias `span`/`length`)"
@@ -85274,7 +85299,7 @@ function createFersMcpServer(ctx, deps) {
85274
85299
  );
85275
85300
  defineTool(
85276
85301
  "set_analysis",
85277
- 'Configure HOW a model is solved, and switch on the analyses the engine supports beyond plain statics. Writes analysis.options (first- vs second-order, P-Delta, self-weight, gravity, tolerances) and the three optional blocks: analysis.modal (natural frequencies), analysis.buckling (linear eigenvalue alpha_cr) and analysis.seismic (EN 1998-1 response spectrum / lateral force). Pass only what you want to change \u2014 each sub-object is merged into the existing block, so load cases, combinations and unity checks are preserved. Returns the updated model for solve_model. KEY FACTS: models from create_beam, create_frame and build_model are LINEAR (the engine itself has no default and requires order; the Python SDK defaults to NONLINEAR), so set order:"NONLINEAR" for second-order/P-Delta. Buckling needs exactly one reference form (reference / references / all_combinations) and reports alpha_cr as results.buckling.modes[].critical_load_factor. Seismic directions are GLOBAL AXES and these models are Y-up, so the two horizontal directions are usually X and Z. Unknown field names are REJECTED here on purpose: the solver would accept them, ignore them, and silently give you a default. Call get_schema("BucklingAnalysisSettings") etc. for the exact fields.',
85302
+ 'Configure HOW a model is solved, and switch on the analyses the engine supports beyond plain statics. Writes analysis.options (first- vs second-order, P-Delta, self-weight, gravity, shear deformation, tolerances) and the three optional blocks: analysis.modal (natural frequencies), analysis.buckling (linear eigenvalue alpha_cr) and analysis.seismic (EN 1998-1 response spectrum / lateral force). Pass only what you want to change \u2014 each sub-object is merged into the existing block, so load cases, combinations and unity checks are preserved. Returns the updated model for solve_model. KEY FACTS: models from create_beam, create_frame and build_model are LINEAR (the engine itself has no default and requires order; the Python SDK defaults to NONLINEAR), so set order:"NONLINEAR" for second-order/P-Delta. Those models include shear deformation (include_shear_deformation: true, the engine default); options {"include_shear_deformation": false} gives the bending-only answer a textbook formula assumes. Buckling needs exactly one reference form (reference / references / all_combinations) and reports alpha_cr as results.buckling.modes[].critical_load_factor. Seismic directions are GLOBAL AXES and these models are Y-up, so the two horizontal directions are usually X and Z. Unknown field names are REJECTED here on purpose: the solver would accept them, ignore them, and silently give you a default. Call get_schema("BucklingAnalysisSettings") etc. for the exact fields.',
85278
85303
  {
85279
85304
  model: jsonString().optional().describe("Stringified FERS model JSON to update"),
85280
85305
  model_ref: modelRefField(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ferscloud/fers-mcp",
3
- "version": "2.83.0",
3
+ "version": "2.84.0",
4
4
  "description": "FERS structural finite-element tools for MCP clients (Claude Desktop, Claude Code, Cursor, VS Code, Codex, ChatGPT desktop), solving on your own machine.",
5
5
  "mcpName": "com.ferscloud/fers",
6
6
  "license": "SEE LICENSE IN LICENSE",
@@ -30,6 +30,6 @@
30
30
  "node": ">=18"
31
31
  },
32
32
  "dependencies": {
33
- "@ferscloud/fers-calculation": "0.2.83"
33
+ "@ferscloud/fers-calculation": "0.2.84"
34
34
  }
35
35
  }