Skip to content
Skill

Calculations toolkit

Guides an agent through building, debugging and managing LeanIX calculated fields

Calculations toolkit is an open-source agent skill for enterprise it. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

Scripts
JavaScript
Platforms
Claude Code, Codex, Cursor
GitHub stars
12
Last commit
License
Apache-2.0
Listing updated

Similar skills

About Calculations toolkit

This skill helps an agent work with LeanIX Calculations, which fill computed fields on fact sheets from their own data or from related fact sheets through relations. It covers creating new calculations, diagnosing failing ones, explaining what calculations can do, and reviewing or managing the calculations already in a workspace.

The workflow has the agent first discover the workspace data model through the LeanIX GraphQL schema, then validate field and relation names, write synchronous JavaScript with an exported main function, test-run the code against sample fact sheets, and only then create the calculation. It also gives guidance on common error patterns, such as async code, imports or wrong data access paths, and on reading execution logs to trace what a calculation wrote.

Using the skill requires the LeanIX MCP server with the calculations toolset enabled. Calculations are written in JavaScript and run inside LeanIX, not in the agent's environment.

When your agent uses it

Build, debug, and create LeanIX Calculations — populate computed fields from other fields and relations. Use when creating new calculations, debugging errors, understanding calculation capabilities, managing workspace calculations, or analyzing existing calculations. Covers target field types, field access patterns, relation data, templates, error patterns, and best practices.

From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.

What it can access

Install

This skill ships in the sap-leanix plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

/plugin marketplace add SAP/leanix-ai-plugins
/plugin install sap-leanix@leanix-ai-plugins

Or copy only this skill to ~/.claude/skills/calculations-toolkit:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/SAP/leanix-ai-plugins.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/calculations-toolkit &&
cp -R "$tmp/skills/calculations-toolkit" ~/.claude/skills/calculations-toolkit &&
rm -rf "$tmp"

For one project only, put the folder in .claude/skills/calculations-toolkit inside it instead.

Claude Code docs on skills

Copy the skill folder to ~/.agents/skills/calculations-toolkit to use it in every repository:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/SAP/leanix-ai-plugins.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/calculations-toolkit &&
cp -R "$tmp/skills/calculations-toolkit" ~/.agents/skills/calculations-toolkit &&
rm -rf "$tmp"

For one repository only, put the folder in .agents/skills/calculations-toolkit inside it instead.

Codex docs on skills

Copy the skill folder to ~/.cursor/skills/calculations-toolkit to use it in every project:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/SAP/leanix-ai-plugins.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/calculations-toolkit &&
cp -R "$tmp/skills/calculations-toolkit" ~/.cursor/skills/calculations-toolkit &&
rm -rf "$tmp"

For one project only, put the folder in .cursor/skills/calculations-toolkit inside it instead.

Cursor docs on skills

Run in a terminal (add --scope workspace to install it for the current workspace only):

gemini skills install https://github.com/SAP/leanix-ai-plugins.git --path skills/calculations-toolkit

Or copy the folder to ~/.gemini/skills/calculations-toolkit yourself.

Gemini CLI docs on skills

For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/calculations-toolkit:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/SAP/leanix-ai-plugins.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/calculations-toolkit &&
cp -R "$tmp/skills/calculations-toolkit" ~/.copilot/skills/calculations-toolkit &&
rm -rf "$tmp"

For one project only, put the folder in .github/skills/calculations-toolkit inside it instead.

VS Code docs on skills

Get the folder:

git clone --depth 1 https://github.com/SAP/leanix-ai-plugins.git

Then copy leanix-ai-plugins/skills/calculations-toolkit into your agent's skills folder as calculations-toolkit. Agents that support SKILL.md read one folder per skill.

The SKILL.md format

What it does

Workspace data model discovery
Looks up fact sheet types, fields, relations and enum values from the live GraphQL schema before writing any code.
Calculation code generation
Produces synchronous JavaScript templates for counting, summing, averaging, date differences and conditional logic.
Test run before creation
Runs candidate code against a sample fact sheet or relation to check the result before saving the calculation.
Error diagnosis
Checks code for disallowed patterns such as async, fetch and imports, and maps common error counts to likely causes.
Execution log review
Lists and inspects past calculation runs to see the code, input data and value written for a fact sheet.
Workspace calculation audit
Reviews existing calculations for missing owners, empty descriptions, errors and inactive status.

Good for

  • Create a calculation that counts how many applications relate to a business capability
  • Debug a calculation that shows a configuration error after a field was renamed
  • Calculate days until a contract end date and store it in a custom field
  • Audit all workspace calculations for errors and missing owners
  • Trace why a specific fact sheet shows an unexpected calculated value

Calculations toolkit FAQ

Does the skill need any setup?

It requires the LeanIX MCP server with the calculations toolset enabled. Authentication is handled by the MCP server through /mcp, not by the skill.

Can calculations make API calls or use imports?

No. The skill's guidance states that calculation code cannot use async, await, fetch or imports, and it must return a single value.

Are new calculations active immediately?

No. The skill creates them as inactive and asks whether to enable them afterwards, since source fields are only read once a calculation is enabled.

Which languages does the skill use?

The skill's bundled scripts are JavaScript, and the calculation code it writes is JavaScript that runs inside LeanIX.

How do I install Calculations toolkit in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/calculations-toolkit to use it in all your projects, or to .claude/skills/calculations-toolkit in one project. Or install the sap-leanix plugin, which includes it: /plugin marketplace add SAP/leanix-ai-plugins, then /plugin install sap-leanix@leanix-ai-plugins.

Does Calculations toolkit run scripts?

Yes. It runs JavaScript scripts. No network calls were found in its scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

Which AI agents can use Calculations toolkit?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

Where this comes from

  • Description: from the skill's own SKILL.md.

More from SAP/leanix-ai-plugins

  1. Lets your agent build, debug and deploy LeanIX automations via MCP

    • Open source
    • 12 GitHub stars
    • Developer tools
  2. Builds and edits LeanIX diagrams from fact sheets, relations and plain shapes

    • Open source
    • 12 GitHub stars
    • Enterprise it
  3. Lets an agent search and read LeanIX fact sheets through the LeanIX MCP server

    • Open source
    • 12 GitHub stars
    • Enterprise it