thalysjuvenal
- 19 skills
- 0 followers
- 7 hours ago last updated
- ▌ Tdn Lookup · thalysjuvenal bundleUse as the escalation strategy when local ADVPL/TLPP reference material lacks an answer -- a tiered approach (local cache first, then TDN Confluence REST API via WebFetch, then Playwright against the API, then WebSearch, then visual site search) for looking up native functions, entry points, unknown errors, or business processes on TDN (tdn.totvs.com). Also triggers on Portuguese phrasing like "buscar documentacao no TDN", "nao encontrei na referencia local", "pesquisar funcao no TDN", "documentacao oficial TOTVS", or "erro desconhecido nao listado".
- ▌ Embedded SQL · thalysjuvenal bundleUse when the user needs to write, review, or migrate SQL queries in ADVPL/TLPP using BeginSQL/EndSQL blocks and macro expressions (%table%, %xfilial%, %notDel%, %exp%, %Order%) instead of raw TCQuery string concatenation -- covering INNER/LEFT JOIN patterns, aggregations (SUM/COUNT/GROUP BY/HAVING), subqueries, column type declarations, DML via TCSqlExec, and SQL-injection prevention. Also triggers on Portuguese phrasing like "consulta SQL", "query embutida", "migrar TCQuery para BeginSQL", "escrever SELECT com filial e notDel", or "montar JOIN em ADVPL".
- ▌ Query Builder · thalysjuvenal bundleUse when the user needs to build, choose the pattern for, or optimize a SQL query against Protheus ERP tables -- covering Workarea (DbSelectArea/DbSeek) vs Embedded SQL vs TCSqlExec pattern choice, mandatory D_E_L_E_T_/xFilial filters, SIX index-aligned WHERE ordering, FWPreparedStatement parameterization to prevent SQL injection, and cross-database (PostgreSQL/MSSQL/Oracle) portability. Also triggers on Portuguese phrasing like "consulta SQL", "montar query", "otimizar consulta", "qual indice usar", "escolher entre DbSeek ou SQL", or "prevenir SQL injection no Protheus".
- ▌ Probat Testing · thalysjuvenal bundleUse when the user needs to write or run unit, functional, or integration tests for TLPP code using ProBat (tlppCore's native testing engine) -- covering @TestFixture, @Test, @Setup/@TearDown, @OneTimeSetUp/@OneTimeTearDown, @Skip, @ErrorLog annotations, the full assertion library (assertEquals, assertTrue, assertVector, assertJson, assertIsRegExFull, etc.), SKIPASSERT, and TDD/CI workflows. Also triggers on Portuguese phrasing like "testes unitarios", "criar teste ProBat", "testar rotina TLPP", "cobertura de testes", or requests to add @Test methods to a TLPP class.
- ▌ Advpl Debugging · thalysjuvenal bundleUse when the user asks to debug, diagnose, or fix an ADVPL/TLPP error on TOTVS Protheus -- compilation errors (syntax, missing includes, undeclared variables), runtime failures (NIL access, type mismatch, array bounds), performance issues (slow queries, memory leaks), database locks (RecLock timeouts, deadlocks), or AppServer log/crash analysis. Also triggers on Portuguese phrasing like "erro de compilacao", "erro em tempo de execucao", "travou o lock", "RecLock nao libera", "performance lenta", "analisar log do appserver", or a pasted stack trace / error message from Protheus.
- ▌ Code Explanation · thalysjuvenal bundleUse when the user asks to explain what a piece of ADVPL/TLPP code does in plain language, adapting the explanation depth for a junior developer (line-by-line), a senior developer (business logic, design decisions, risks), or a functional consultant (no technical terms) -- e.g. understanding legacy code, filling in missing documentation, or assessing the impact of a customization. Also triggers on Portuguese phrasing like "explicar fonte", "explicar codigo", "o que essa rotina faz", "explicar para o consultor funcional", or requests for a --level junior/senior/funcional explanation.
- ▌ Sx Configuration · thalysjuvenal bundleUse when the user needs to generate or validate Protheus data dictionary configuration scripts -- covering SX2 (table headers), SX3 (fields), SIX (indexes), SXG (field groups), SXA (form folders/tabs), SX1 (report questions), SX5 (generic tables), SXB (F3 lookup queries), and SX7 (triggers). Also triggers on Portuguese phrasing like "criar campo customizado", "cadastrar tabela customizada", "dicionario de dados", "criar indice SIX", "gatilho de campo", "tabela generica SX5", "consulta F3", or field-prefix names like ZA1/ZZ1.
- ▌ Advpl Code Review · thalysjuvenal bundleUse when the user asks to review, audit, or check the quality of ADVPL/TLPP code for TOTVS Protheus before merge or deploy -- covering best practices (RecLock/MsUnlock pairing, variable scope, area management, error handling), performance bottlenecks, security vulnerabilities (SQL injection, credential exposure), and modernization opportunities (TLPP migration readiness). Also triggers on Portuguese phrasing like "revisar codigo", "revisar fonte", "auditar rotina", "checar boas praticas", "code review advpl", or requests to apply the official TOTVS SonarQube ruleset (CA/BG/CS codes).
- ▌ Advpl Refactoring · thalysjuvenal bundleUse when the user asks to refactor, clean up, or restructure existing ADVPL/TLPP code on TOTVS Protheus without changing its behavior -- extracting long functions (>100 lines), simplifying deeply nested conditionals, removing dead code, improving variable naming (Hungarian notation), eliminating duplicated logic, or reducing functions with too many parameters. Also triggers on Portuguese phrasing like "refatorar rotina", "melhorar esse fonte", "extrair funcao", "remover codigo morto", "simplificar condicional", "reduzir complexidade", or "God function" complaints.
- ▌ Protheus Business · thalysjuvenal bundleUse when the user needs to understand a TOTVS Protheus ERP business process, module workflow, or cross-module integration -- covering Compras (COM), Estoque (EST), Faturamento (FAT), Financeiro (FIN), Contabilidade (CTB), Fiscal (FIS), PCP, and Manutencao de Ativos (MNT), including their main routines (e.g. MATA110, MATA460), tables/fields, and business rules. Also triggers on Portuguese phrasing like "processo de negocio", "modulo de compras/estoque/faturamento/financeiro/fiscal/contabilidade/pcp/manutencao", "como funciona o ciclo de compras", or questions about integration between modules.
- ▌ Changelog Patterns · thalysjuvenal bundleUse when the user asks to generate a changelog, release notes, or delivery notes from ADVPL/TLPP code changes on TOTVS Protheus -- analyzing diffs or a list of changed files, classifying each change (NEW/FIX/CHANGE/REMOVE/REFACTOR), assessing business impact (ALTO/MEDIO/BAIXO), and detecting affected tables. Also triggers on Portuguese phrasing like "gerar changelog", "notas de versao", "documentar entrega", "o que mudou nessa versao", or requests to audit code changes for compliance.
- ▌ Protheus Reference · thalysjuvenal bundleUse when the user needs to look up a TOTVS Protheus native function's syntax/parameters/return value, the SX data dictionary structure (SX1-SX9, SIX), REST API endpoint patterns (FWRest, WsRestFul), MV_* system parameter behavior, SX3 field validation, or whether a function is restricted/internal-only. Also triggers on Portuguese phrasing like "funcao nativa", "dicionario de dados", "parametro MV_", "campo SX3", "API REST protheus", "essa funcao e restrita".
- ▌ Smartx Development · thalysjuvenal bundleUse when the user wants to build, migrate, or troubleshoot a Smart X routine -- TOTVS's metadata-driven UI framework that generates modern PO-UI screens from a data dictionary Object/Model/Interface/Launcher chain. Covers the model.tlpp/interface.tlpp/launcher artifacts, ADVPL function integration via pageActions/tableActions/onChange, converting a legacy MVC browse to Smart X, and common troubleshooting. Also triggers on Portuguese phrasing like "tela Smart X", "gerar tela por metadados", "migrar MVC para Smart X", "criar Modelo e Interface Smart X", "launcher Smart X", or names like FINA050SM/MATA110SX.
- ▌ Advpl Code Generation · thalysjuvenal bundleUse when the user asks to generate, create, or scaffold ADVPL/TLPP code for TOTVS Protheus -- User Functions, Static Functions, TLPP classes, MVC (Model/View/Controller), REST APIs, SOAP web services, entry points (pontos de entrada), TReport/FWMsPrinter reports, jobs, or workflows. Also triggers on Portuguese phrasing like "gerar codigo", "criar rotina", "criar fonte", "novo ponto de entrada", "criar classe tlpp", "gerar api rest", "criar mvc", or routine name patterns like FATA001/MATA010. Covers naming conventions, Hungarian notation, namespace rules, identifier length limits, and mandatory User Function/error-handling structure.
- ▌ Advpr Test Automation · thalysjuvenal bundleUse when the user wants to write, run, or troubleshoot automated regression tests for Protheus routines with ADVPR (Advanced Protheus Robot) -- covering FWTestHelper API, TestSuite/GPS de Testes setup, headless execution via FwExecSuite, and per-pattern scripting (MVC, ExecAuto/MSExecAuto, reports, processing routines, webservices, SmartLink, Smart View, single-message/TOTVS Message) plus routine preparation (screen bypass) and best practices. Also triggers on Portuguese phrasing like "teste automatizado", "robo de testes", "automacao de testes Protheus", "rodar suite de testes", "FWMyTestRunner", "GPS de testes", or "preparar rotina para teste automatico". The referenced files are written in Brazilian Portuguese.
- ▌ Smartview Development · thalysjuvenal bundleUse when the user wants to create, migrate, publish, or troubleshoot a TOTVS Smart View custom business object (Integrated Provider) -- the TLPP class carrying the @totvsFrameworkTReportsIntegratedProvider annotation with getSchema/getData, its parameters with lookup and combo endpoints, the callTReports menu source, and the .trp resource publication cycle. Also covers converting legacy TReport, FWMSPrinter, TMSPrinter and FWMSExcel reports into Smart View data views. Triggers on Portuguese phrasing like "objeto de negocio Smart View", "relatorio no Smart View", "migrar relatorio para Smart View", "visao de dados", "IntegratedProvider", "callTReports", "arquivo .trp", "combo de parametro Smart View". This is Smart View (TReports analytics), NOT Smart X (metadata-driven PO-UI screens) -- for Smart X screens use the smartx-development skill instead.
- ▌ Documentation Patterns · thalysjuvenal bundleUse when the user wants to generate technical documentation for ADVPL/TLPP code on TOTVS Protheus -- Protheus.doc header blocks (@type, @param, @return, @author, @since, @history), complete routine documentation (tables read/written, MV_* parameters, entry points, execution flow, dependencies), or REST API endpoint documentation (path/query parameters, request/response JSON, status codes). Also triggers on Portuguese phrasing like "documentar rotina", "gerar cabecalho Protheus.doc", "documentar endpoint", "documentar API REST", or requests to add documentation to legacy/undocumented code.
- ▌ Advpl To Tlpp Migration · thalysjuvenal bundleUse when the user asks to migrate, convert, compatibilize, or modernize legacy ADVPL procedural code to TLPP object-oriented classes on TOTVS Protheus -- turning User Functions/Static Functions into namespaced classes with methods and data properties, replacing Private/Public scoping, and preserving backward-compatible wrappers for existing callers. Also triggers on Portuguese phrasing like "migrar para tlpp", "compatibilizar fonte", "converter prw para tlpp", "transformar em classe", "modernizar rotina", or requests naming a `custom.<agrupador>.<servico>` / `totvs.protheus.<segmento>.<agrupador>` namespace.
- ▌ Protheus Locks Deadlocks · thalysjuvenal bundleUse when the user needs to understand, diagnose, or prevent Protheus record locks and deadlocks -- covering RecLock/MsUnlock/SoftLock/LockByName semantics, BeginTran/EndTran transaction scoping, lock leak and deadlock diagnostics (TopMemoStatus, MonitorActiveLocks, DBAccess monitor, SQL Server/PostgreSQL/Oracle lock queries), and prevention patterns (BEGIN SEQUENCE/RECOVER, lock ordering). Also triggers on Portuguese phrasing like "registro travado", "trava de registro", "deadlock", "erro de lock", "travamento no Protheus", "quem esta travando o registro", or "RecLock nao libera".