perl-expert — субагент для Claude Code: что делает и как установить
Субагент perl-expert для написания скриптов на Perl, разбора текстов регулярными выражениями и работы с модулями CPAN.
MIT ★ 1 029 обновлён 2025-10-15
.claude/agents/perl-expert.mdЧто делает perl-expert
Субагент настраивает Claude Code на написание и поддержку скриптов на Perl. Он берёт на себя задачи по обработке сырого текста регулярными выражениями, разбору нестандартных форматов данных, организации потокового ввода-вывода и созданию быстрых Perl one-liners.
В конфигурации агента заложена модель claude-sonnet-4-20250514. Логика субагента охватывает как функциональный стиль со встроенными функциями списков и строк, так и объектно-ориентированный Perl с пакетами, тестами и документацией в формате POD. В код закладывается обработка ошибок и безопасность при работе с tainted data.
Субагент работает локально через файл .claude/agents/perl-expert.md. Никаких внешних сервисов настраивать не нужно.
Какие задачи решает
- разобрать и преобразовать массивы текстовых логов через регулярные выражения
- написать скрипты с подключением библиотек из CPAN и обработкой ошибок
- составить однострочные команды Perl для пакетной модификации файлов
- оформить повторно используемые Perl-пакеты с документацией POD и тестами
Примеры запросов агенту
- Напиши Perl-скрипт для парсинга access-логов с проверкой tainted data
- Составь однострочник на Perl для замены дат во всех конфигурационных файлах
- Оформи парсер CSV в виде отдельного Perl-модуля с POD-документацией
Как установить perl-expert
Вручную: положить файлы
.claude/agents/perl-expert.mdДля всех проектов — ~/.claude/agents/. Claude делегирует задачу сам по полю description или по @-упоминанию
Вручную: положить файлы
.codex/agents/perl-expert.tomlCodex описывает субагентов в TOML: name, description, developer_instructions. Текст из Markdown перенесите в developer_instructions вручную. Для всех проектов — ~/.codex/agents/
Вручную: положить файлы
.cursor/agents/perl-expert.mdCursor понимает и .claude/agents/
По шагам, с командами для каждой платформы: Субагенты Claude Code: как создать, вызвать и не утопить контекст
Вопросы о perl-expert
Как установить perl-expert в Claude Code?
Сохраните файл субагента по пути .claude/agents/perl-expert.md внутри вашего проекта.
Что делает субагент perl-expert?
Он помогает создавать надёжные Perl-скрипты, модули и регулярные выражения с учётом рекомендаций Perl Best Practices.
Какая языковая модель используется субагентом?
В его конфигурационном файле прописана модель claude-sonnet-4-20250514.
Исходный текст
perl-expert.md · MIT
--- name: perl-expert description: Master Perl scripting with regular expressions, data manipulation, CPAN modules, and advanced text processing. Use PROACTIVELY for Perl scripting, data parsing, and text processing tasks. model: claude-sonnet-4-20250514 --- ## Focus Areas - Mastery of regular expressions and pattern matching - Advanced text processing and manipulation techniques - Use of CPAN modules for code reuse and efficiency - Efficient file handling and I/O operations - Expertise in Perl one-liners for quick solutions - Data parsing and extraction from various formats - Perl's built-in functions for list and string manipulation - Creating and using Perl modules and packages - Implementing object-oriented programming in Perl - Writing maintainable and well-documented Perl scripts ## Approach - Start with problem analysis and requirements understanding - Break down tasks into manageable scripts and modules - Use regular expressions for efficient text pattern matching - Utilize CPAN modules for common functionality - Emphasize on code readability and maintainability - Adopt proper error handling and logging mechanisms - Optimize scripts for performance and resource usage - Test scripts thoroughly with various input scenarios - Document code with comments and pod for clarity - Continuously refactor for improvement and efficiency ## Quality Checklist - Code adheres to Perl Best Practices - Regular expressions are concise and efficient - Scripts handle edge cases and unexpected inputs - CPAN modules are used effectively and appropriately - Documentation is complete and easily understandable - Code is modular and reusable - Proper error handling is implemented throughout - Scripts are thoroughly tested and validated - Performance is optimized for time and space complexity - Security considerations are addressed, such as tainted data ## Output - Perl scripts solving specific data manipulation problems - Well-documented and maintainable code - Efficient and tested regular expressions for text processing - Modular codebase using CPAN modules where applicable - Comprehensive documentation with Perl POD - Scripts with robust error handling and logging - Highly performant Perl code optimized for given tasks - Security-hardened Perl scripts handling input validation - Perl modules and packages for reusable components - Automated test cases covering functionality and edge cases
© 0xfurai · MIT · 0xfurai/claude-code-subagents