Skip to content
Development
Skill

/sap-enhancement-advisor

Finds the safest extension point for a requested SAP behavior change and recommends which enhancement mechanism to use — so a project doesn't fail by modifying the wrong place (copying standard, editing a fragile exit, missing the right BAdI). Complements /sap-se19 (which

From plugin
sap-dev
10123 skills3 agents

Claude Code

$ npx -y skills add sapdev-ai/sap-dev --skill sap-enhancement-advisor --agent claude-code

SKILL.md

sap-enhancement-advisor.SKILL.md
name: sap-enhancement-advisor
description: |
  Finds the safest extension point for a requested SAP behavior change and
  recommends which enhancement mechanism to use — so a project doesn't fail by
  modifying the wrong place (copying standard, editing a fragile exit, missing the
  right BAdI). Complements /sap-se19 (which IMPLEMENTS a BAdI): this skill DECIDES.
  Three auto-detected modes: inspect one BAdI / enhancement spot (classify
  classic/new/migrated + list implementations); inspect one SMOD enhancement
  (components + the CMOD projects using it); or enumerate candidates for a program
  / tcode (enhancement spots, referenced BAdIs, user-exit includes). Scores
  candidates with a transparent heuristic (released enhancement interface > BAdI >
  exit > implicit; avoid standard modification), flags risks, and emits
  candidates.tsv + a recommended plan. The optional business-intent string is
  advisory only (the ranking is structural). Read-only; never modifies SAP.
  Prerequisites: SAP profile via /sap-login (RFC); SAP NCo 3.1 (32-bit) in GAC.
argument-hint: "BADI <name> | ENHANCEMENT <smod> | PROGRAM <p> | TCODE <t>  [\"<intent>\"]"

SAP Enhancement Advisor Skill

You find WHERE to implement an SAP behavior change and recommend the safest mechanism. You decide; /sap-se19 and /sap-cmod implement. You are read-only.

Task: $ARGUMENTS

This is the fourth delivery-assurance skill, built on the Phase-0 primitives and reusing the sap-se19 (BAdI) and sap-cmod (SMOD/CMOD) table knowledge.

---

Shared Resources

| File | Call | Purpose | |---|---|---| | `<SAP_DEV_CORE_SHARED_DIR>/rules/skill_operating_rules.md` | *(rule)* | Mandatory operating rules - read-only here | | `<SKILL_DIR>/references/sap_enhancement_advisor.ps1` | `-Token [-Intent] [-TypeHint] [-OutputDir]` | The advisor engine | | `<SAP_DEV_CORE_SHARED_DIR>/scripts/sap_object_resolver.ps1` | dot-sourced by the engine | Resolve program / tcode context | | `<SAP_DEV_CORE_SHARED_DIR>/scripts/sap_finding_lib.ps1` | dot-sourced by the engine | Risk findings | | `<SAP_DEV_CORE_SHARED_DIR>/scripts/sap_artifact_lib.ps1` | dot-sourced by the engine | Registers outputs for /sap-evidence-pack | | `/sap-se19`, `/sap-cmod`, `/sap-impact-analysis` | sub-skills | Implement the recommendation / assess impact |

---

Step 0 — Resolve Work Directory

powershell -NoProfile -ExecutionPolicy Bypass -Command ". '<SAP_DEV_CORE_SHARED_DIR>\scripts\sap_settings_lib.ps1'; . '<SAP_DEV_CORE_SHARED_DIR>\scripts\sap_connection_lib.ps1'; Write-Output ('WORK_DIR=' + (Get-SapWorkDir))"
cmd /c if not exist "{WORK_TEMP}" mkdir "{WORK_TEMP}"

Set `{RUN_TEMP}` = the per-run scratch dir (`Get-SapRunTemp` mints + creates `{work_dir}\temp\run_<id>`):

powershell -NoProfile -ExecutionPolicy Bypass -Command ". '<SAP_DEV_CORE_SHARED_DIR>\scripts\sap_connection_lib.ps1'; Write-Output ('RUN_TEMP=' + (Get-SapRunTemp))"

Per the CLAUDE.md "Two-bucket temp model" write this skill's `_run.json` log state under `{RUN_TEMP}`.

---

Step 0.5 — Start Logging

powershell -ExecutionPolicy Bypass -File "<SAP_DEV_CORE_SHARED_DIR>\scripts\sap_log_helper.ps1" -Action start -StateFile "{RUN_TEMP}\sap_enhancement_advisor_run.json" -Skill sap-enhancement-advisor -ParamsJson "{}"

---

Step 1 — Parse the Target + Intent

  • **`BADI <name>`** / a BAdI / enhancement-spot name -> inspect mode (classify +

list implementations).

  • **`ENHANCEMENT <smod>`** / **`SMOD <name>`** -> SMOD inspect mode (components +

CMOD projects).

  • **`PROGRAM <p>`** / **`TCODE <t>`** / bare name -> enumerate candidates for the

program.

  • A trailing quoted string is the **business intent** (e.g. `"validate PO item

before save"`) -> pass as `-Intent`. It is echoed in the report but does NOT change the ranking.

---

Step 2 — Run the Advisor Engine

Run via **32-bit PowerShell** (NCo 3.1 in `GAC_32`):

C:\Windows\SysWOW64\WindowsPowerShell\v1.0\powershell.exe -ExecutionPolicy Bypass -File "<SKILL_DIR>\references\sap_enhancement_advisor.ps1" -Token "TCODE ME21N" -Intent "validate PO item before save"

Append `-TypeHint`, `-OutputDir` as needed. Creds resolve from the pinned profile.

Engine output:

ADVISOR: context=<O:N> mode=<BADI|SMOD|PROGRAM> candidates=<n> recommended=<name> rectype=<ctype>
PARTIAL: could_not_check=<tables>      (only if some reads were denied)
REPORT_MD / CANDIDATES_TSV / IMPLEMENTATIONS_TSV / RISK_TSV / RISK_JSON: <path>

Exit: `0` ok - `1` context not found - `2` RFC failure.

---

Step 3 — Present the Recommendation

Read `ADVISOR:`, then `REPORT_MD`. Present:

1. **Recommended mechanism** and why (the transparent score + the facts: classic/new, released, existing implementations, filters). 2. **Candidate table** — all options with their scores, so the user can override. 3. **Existing implementations** — and whether to EXTEND one or CREATE a new one. **Always ask** before creating; **never auto-suffix-bump** a new name (e.g. `ZMM_PO_CHECK` vs `ZMM_PO_CHECK_002`) — that is the user's decision. 4. **Risk flags** — multiple active implementations (undefined order), migrated/obsolete BAdI (prefer the new one), or "no clean enhancement point" (standard-modification risk). 5. **Two mandatory caveats** (never omit):

  • The ranking is **structural/heuristic**, not semantic — verify the

recommended interface's method signature actually exposes the data the intent needs.

  • For PROGRAM mode, enumeration is **non-exhaustive** — implicit enhancements

and dynamically-called BAdIs are not listed; SE84/SE81 is the exhaustive tool. If a `PARTIAL:` line appeared, name the tables that could not be read.

---

Step 4 — Hand Off

  • **BAdI** recommended -> `/sap-se19 create ...` (or display an existing impl).
  • **SMOD exit** recommended -> `/sap-cmod ...` (assign + edit + activate project).
  • **User-exit include** -> `/sap-se38` to edit the customer include.
  • Then `/sap-
Read more
@sapdev-ai
Ships withsap-dev

SAP development automation skills for AI coding assistants. Windows-only — the skills drive SAP GUI for Windows via GUI Scripting (plus optional RFC via SAP NCo); there is no macOS/Linux path.

10123 skills3 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
10
Star history of sapdev-ai/sap-dev on GitHub, a chart by star-history.com

Other skills on sap-dev.

sap-activate-object

sap-activate-object

Activates an inactive SAP repository object via SAP GUI Scripting. Routes to the correct transaction by object type: SE38 for…

@sapdev-ai@sapdev-aiInstall Skill
sap-api-advisor

sap-api-advisor

Natural-language SAP API discovery over RFC (no GUI): turn a goal like "create a sales order" or "post a goods movement" into a…

@sapdev-ai@sapdev-aiInstall Skill
sap-atc

sap-atc

Runs the SAP ABAP Test Cockpit (ATC) end-to-end as a quality gate: builds an SCI Object Set scoped to the target object(s),…

@sapdev-ai@sapdev-aiInstall Skill
sap-call-bdc

sap-call-bdc

Executes BDC (Batch Data Communication) sessions in SAP via RFC. Reads SHDB recording files from the bdc/ folder, connects via…

@sapdev-ai@sapdev-aiInstall Skill
sap-change-package

sap-change-package

Changes the package (TADIR-DEVCLASS) assignment of an SAP repository object via the "Object Directory Entry" dialog (Goto >…

@sapdev-ai@sapdev-aiInstall Skill
sap-check-abap

sap-check-abap

Validates ABAP source (report / program / FM / class / include) before deployment — one skill, dimension-dispatched: naming…

@sapdev-ai@sapdev-aiInstall Skill

More skills from other plugins.

brainstorming
Auto-invoked

brainstorming

You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…

@obra@obraInstall Skill
ask-matt

ask-matt

Ask which skill or flow fits your situation. A router over the skills in this repo.

skills2w309k
@mattpocock@mattpocockInstall Skill
accessibility
Auto-invoked

accessibility

Design, implement, and audit accessible UI to WCAG 2.2 Level AA across Web, iOS, and Android — semantic ARIA roles and labels,…

ecc2w293k
@affaan-m@affaan-mInstall Skill
compiler-commit

compiler-commit

Use when you want to verify compiler changes and commit with the correct convention. Runs tests, lint, and format, then commits…

react5d252k
@facebook@facebookInstall Skill

Questions about sap-enhancement-advisor.

Which coding agents can use sap-enhancement-advisor?
sap-enhancement-advisor installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.