/plugadvpl:hotspots

Rank ADVPL/TLPP functions by callsite count using fan-in analysis.

Updated Aug 27, 2026
One-click install
npx skills add https://github.com/JoniPraia/plugadvpl --skill plugadvpl-hotspots
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: /plugadvpl:hotspots
Source: https://github.com/JoniPraia/plugadvpl/tree/main/skills/hotspots
Command: npx skills add https://github.com/JoniPraia/plugadvpl --skill plugadvpl-hotspots

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It helps you identify which ADVPL/TLPP functions are most frequently used (by counting callers) so refactors can be prioritized where they will impact the most code.

Core Features & Use Cases

  • Top-N hotspots by fan-IN: Ranks destination functions by total call count, along with how many files and unique callsites they appear in.
  • TOTVS native filtering: Default filters out embedded native catalog calls so results focus on refactor-relevant custom code, with an option to include natives for audit.
  • Type-scoped analysis: Limits ranking to specific call types such as user functions, methods, execauto, or execblock for more targeted impact analysis.

Quick Start

Run /plugadvpl:hotspots to get the top 20 most-called custom functions (refactor priority) for your project.

Frequently Asked Questions about /plugadvpl:hotspots

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I identify high-impact ADVPL functions to prioritize for refactoring?

ADVPL fan-in analysis ranks functions by their total call count to identify refactoring priorities. By counting how many callsites invoke each destination function, it highlights which user functions and class methods have the broadest architectural impact across your codebase.

Can I filter ADVPL call graph analysis to exclude native TOTVS routines?

Yes, you can filter ADVPL call graph analysis to exclude native TOTVS routines by default. This ensures results focus on custom code refactoring, with an option to include native catalog calls when you need a comprehensive architectural audit.

What is the best way to scope impact analysis for specific TLPP call types?

The best way to scope impact analysis for TLPP call types is to apply type-scoped filters. This limits the fan-in ranking to specific categories like user functions, methods, execauto, or execblock, providing targeted impact assessment for your architectural review.

How do I generate a top-N list of frequently called functions in an TLPP codebase?

You generate a top-N list of frequently called TLPP functions by running a fan-in impact ranking. This produces an ordered list of destination functions based on total call count, along with the number of unique callsites and files where they appear.

Does ADVPL impact analysis include class methods and user functions in the same ranking?

Yes, ADVPL impact analysis includes both class methods and user functions in the same ranking. The fan-in calculation aggregates callsites across all these call paths to deliver a unified refactoring priority list based on total invocations.

When should I not use fan-in analysis for ADVPL code quality metrics?

You should not use fan-in analysis for ADVPL code quality metrics when you need to assess outgoing dependencies rather than incoming calls. Fan-in strictly measures how often a function is called by others, not the complexity or breadth of what it calls.