Agent skill

Maintenance

by RussellSB in RussellSB/pytrendy

A skill your agent uses when making ANY code change to pytrendy, creating issues, or opening PRs.

MITAuto-check passedData & Analytics

Install Maintenance

skills CLI
$ npx skills add RussellSB/pytrendy --skill maintenance -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install RussellSB/pytrendy maintenance --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/RussellSB/pytrendy.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.opencode/skills/maintenance .claude/skills/maintenance && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
maintenance
GitHub stars
106
Token cost
~2.1k tokens
SKILL.md length
919 words
Files
1
Skills in repo
5
Repo updated
First seen
Licence
MIT

At a glance

A skill your agent uses when making ANY code change to pytrendy, creating issues, or opening PRs.

  • Works in 5 steps: process_signals(df, value_col,… → get_segments(df) — contiguous segment… → refine_segments(df, value_col, segments,… → …
  • Making ANY code change to pytrendy
  • SKILL.md covers Public API surface, Deprecation policy (the rule…, Code conventions and Pipeline (don't break the order), plus 6 more sections
  • Calls git and poetry

What it does

Maintenance is an agent skill from RussellSB/pytrendy. Use when making ANY code change to pytrendy, creating issues, or opening PRs. Covers commit format, PR title conventions, branch model, deprecation policy, API surface, diff conventions, remote session behaviour, and things you must not touch. Load this FIRST before any code work.

Its SKILL.md is about 2.1k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Data & Analytics. The repository describes itself as: Trend Detection in Python. Applicable for real-world industry use cases in time series. The licence is MIT.

When your agent uses it

  • Making ANY code change to pytrendy
  • Creating issues

Example prompts

  • “/maintenance”

Requirements

  • Python 3

Workflow steps

5 steps, taken from the first numbered list in SKILL.md.

  1. process_signals(df, value_col, method_params, debug) — Savitzky-Golay smoothing, flat/noise flags.
  2. get_segments(df) — contiguous segment extraction with min-length: Up/Down ≥3d, Flat/Noise ≥1d.
  3. refine_segments(df, value_col, segments, method_params) — boundary adjust, DTW gradual/abrupt classification, abrupt shaving, grouping…
  4. analyse_segments(df, value_col, segments) — metrics: total/percent change, duration, SNR, change rank.
  5. plot_pytrendy(df, value_col, segments) — only if plot=True.

What it can do on your machine

Read from SKILL.md and the folder at commit 0d6d5bb. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • git
    • poetry

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use git, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Maintenance loads about 2.1k tokens when it runs. Until then it costs about 73 tokens; SKILL.md has 919 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~73
When it runs · the whole SKILL.md, loaded when a task matches
~2.1k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from RussellSB/pytrendy at commit 0d6d5bb, republished under its MIT licence (© RussellSB). 919 words, ~2,118 tokens.

Download SKILL.mdSave it as .claude/skills/maintenance/SKILL.md (or your agent's skills folder).
name
maintenance
description
Use when making ANY code change to pytrendy, creating issues, or opening PRs. Covers commit format, PR title conventions, branch model, deprecation policy, API surface, diff conventions, remote session behaviour, and things you must not touch. Load this FIRST before any code work.

Maintenance & API evolution

CRITICAL: Before EVERY git commit, verify the message matches ^(feat|fix|docs|style|refactor|perf|test|build|ci|chore|revert)(\(.+\))?!?: .+. If not, rewrite it. No exceptions.

CRITICAL: Before EVERY PR title creation, verify the title matches the same pattern. lint-pr-title.yml enforces this in CI — PRs with non-conforming titles are blocked.

Public API surface

The public API is what pytrendy/__init__.py exports plus the detect_trends() signature:

python
from pytrendy import detect_trends, load_data, plot_pytrendy, dtw
  • detect_trends(df, date_col, value_col, plot=True, method_params=None, debug=False) → PyTrendyResults
  • load_data(name) — name ∈ {'series_synthetic', 'classes_signals'} (CSVs in pytrendy/io/data/)
  • plot_pytrendy(...) — annotated visualization
  • dtw — re-exported from pytrendy.simpledtw

PyTrendyResults (from pytrendy.io.results_pytrendy) is the return type: .print_summary(), filtering by direction/rank, tabular segment access.

Changing any of these is user-observable. Internal helpers in post_processing/, process_signals.py, simpledtw.py are not public API — restructure freely with refactor:.

Deprecation policy (the rule agents get wrong)

SituationCommit typeVersion bumpMechanism
Parameter still works but deprecated (soft)feat:minorwarnings.warn(..., DeprecationWarning) + keep accepting the old name
Parameter/behavior removed entirely (hard)feat!: or BREAKING CHANGE:majorRemove the old code path
Internal restructure, zero public API impactrefactor:noneNo warning needed

Deprecating a public param is feat:, NOT refactor: — even if the code change is a rename. Deprecation is a user-facing signal that triggers a minor bump and documents intent to remove in a future major. See docs/contributing.md "Deprecations" and .github/copilot-instructions.md (now migrated here).

Current live deprecation

detect_trends(..., method_params=...): is_abrupt_padded is deprecated (raises DeprecationWarning, see pytrendy/detect_trends.py:63). Use abrupt_padding instead.

Current method_params keys (the only ones honored)
python
method_params = {
    'abrupt_padding': 0,      # int: days to pad around abrupt transitions
    'avoid_noise': True,      # bool: skip noisy segments
}

Any other keys passed are silently dropped — detect_trends reconstructs the dict from these two defaults (pytrendy/detect_trends.py:72). Don't add a third key without also updating this allowlist and the docstring.

Code conventions

  • Docstrings: Google style (mkdocstrings is configured for it in mkdocs.yml). Required on public functions.
  • Type hints on all public function signatures.
  • No debug prints or commented-out code in committed code. Use debug=True in detect_trends for dev plots/prints — that's what it's for.
  • Keep diffs minimal: only touch lines directly relevant to the change. No stray reformatting, whitespace, blank-line, or indentation changes. These wreck reviews and cause merge conflicts. If something nearby is ugly, open a separate refactor: PR.
  • Follow existing patterns in the module you're editing — don't import a new library when the module already uses something equivalent.

Pipeline (don't break the order)

detect_trends() runs five stages in pytrendy/detect_trends.py:77:

  1. process_signals(df, value_col, method_params, debug) — Savitzky-Golay smoothing, flat/noise flags.
  2. get_segments(df) — contiguous segment extraction with min-length: Up/Down ≥3d, Flat/Noise ≥1d.
  3. refine_segments(df, value_col, segments, method_params) — boundary adjust, DTW gradual/abrupt classification, abrupt shaving, grouping, artifact cleanup.
  4. analyse_segments(df, value_col, segments) — metrics: total/percent change, duration, SNR, change rank.
  5. plot_pytrendy(df, value_col, segments) — only if plot=True.

Each stage's output is the next stage's input. See the pytrendy skill for the module map.

Segment schema (what tests assume)

Segment dicts have at minimum: direction ('Up'/'Down'/'Flat'/'Noise'), start, end. After analyse_segments, also: days, total_change, change_rank, trend_class ('gradual'/'abrupt'/NaN). Tests in tests/conftest.py assert on direction/start/end — changing the keys or values breaks the whole suite.

Branch model (enforced by CI)

  • PRs target develop, not main. check-base-branch.yml hard-fails otherwise. Only develop→main release PRs and automated docs/whats-new-* PRs bypass.
  • main = stable release branch. develop = prerelease (dev channel).
  • Branch off: git checkout -b my-feature origin/develop.

Commits & PR titles (Conventional Commits, enforced)

  • lint-pr-title.yml rejects titles not matching ^(feat|fix|docs|style|refactor|perf|test|build|ci|chore|revert)(\(.+\))?!?: .+.
  • semantic-release maps: feat→minor, fix→patch, !/BREAKING CHANGE:→major, others→no bump.
  • Deprecating a public API param = feat: (minor), not refactor: — see "Deprecation policy" section above.
  • chore vs fix: fix: triggers a patch release via semantic-release. Use chore: or ci: for maintenance-only changes that have zero user-facing code impact. Using fix: on non-bugfix work causes accidental auto-releases.
  • Imperative, lowercase, <72 chars, no trailing period.
Show full SKILL.md (336 more words)Show less

Don't touch these manually

  • pyproject.toml version — bumped by semantic-release via poetry version. Editing it by hand breaks releases.
  • CHANGELOG.md — generated by semantic-release on main.
  • docs/whats-new.md — generated by the agentic whats-new.yaml workflow (OpenCode CLI writes between <!-- WHATS_NEW_CONTENT_START/END --> sentinels). Don't edit by hand unless explicitly directed to fix/regenerate an entry — the workflow overwrites content between the sentinels on the next release.

Issues and PRs

When creating issues or PRs, follow the conventions in docs/contributing.md:

  • Issue titles use [Tag] Short description format: [Bug], [Docs], [Enhancement], [Feature], [CI], [Maintenance]
  • PR titles follow Conventional Commits: feat: ..., fix: ..., etc. (same as commit messages)
  • Link issues in PR descriptions with Closes #<number>
  • Labels apply appropriate labels: bug, documentation, enhancement, feature, test, maintenance, good first issue, priority

Remote session behaviour

Detecting CI environment: When PYTRENDY_CI=true is set, you are running in a GitHub Actions environment, not a local interactive session.

Environment constraints
  • Agent runs in a GitHub Actions runner, not the user's machine
  • Git identity, credentials, and write permissions are constrained by the runner
  • Cannot assume interactive capabilities — must act or fail, not ask for confirmation
Confirmation loop avoidance
  • When the user gives an explicit instruction (e.g. "create an issue", "fix this", "commit"), execute it directly
  • Safety assessment: Before executing, evaluate the action:
    • If safe and clearly scoped (e.g. "add a comment", "create a branch") → execute immediately
    • If the prompt clearly matches the action → execute immediately
    • If wildly out of scope or dangerous from a git perspective → do not execute, and explain why. Dangerous actions include:
      • Committing directly to main or develop
      • Force-pushing
      • Deleting branches
      • Any operation that could affect the release pipeline
Auth loop detection
  • If the same write operation fails with the same auth/permission error 3 or more times consecutively (same command, same error output), stop the session immediately
  • Post a final comment summarising: what was attempted, the exact error each time, and why it couldn't be completed
  • Do NOT retry blindly — repeated identical failures indicate a permission/scope issue, not a transient error
  • The user must fix the underlying permission before re-triggering

© RussellSB, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .opencode/skills/maintenance of RussellSB/pytrendy.

Open the folder on GitHubat commit 0d6d5bb

Compare with similar skills

Maintenance next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Maintenance compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Maintenance this skillRussellSB/pytrendy106—~2.1kAutomated safety check: PassMIT
AI Daily DigestvigorX777/ai-daily-digest1.6k—~1.3kAutomated safety check: PassNone
Documd Visualsmarkdown-viewer/skills3.4k—~3.3kAutomated safety check: PassCC-BY-4.0
Retentioneering Contributingretentioneering/retentioneering-tools925—~1.8kAutomated safety check: PassApache-2.0
Agentic Kaggle WorkflowFrankS-IntelLab/agentic-kaggle-skill188—~4kAutomated safety check: PassMIT
Billing Reviewpolarsource/polar10k—~2.3kAutomated safety check: PassMIT

Similar skills

  • AI Daily Digest

    vigorX777/ai-daily-digest

    Fetches RSS feeds from 90 top Hacker News blogs (curated by Karpathy), uses AI to score and filter articles, and generates a daily digest in Markdown with Chinese-translated titles, category…

    1.6k GitHub stars~1.3k tokensUpdated 7 mo ago
    Data & AnalyticsAuto-check passed
  • Documd Visuals

    markdown-viewer/skills

    Create text-driven visuals in Markdown: charts, diagrams, cards, architecture and page layouts.

    3.4k GitHub stars~3.3k tokensUpdated 3 days ago
    Data & AnalyticsAuto-check passed
  • Retentioneering Contributing

    retentioneering/retentioneering-tools

    Help the user turn their Retentioneering ideas, friction reports, bug findings, or feature needs into high-quality upstream contributions: from capturing and validating the idea, through minimal…

    925 GitHub stars~1.8k tokensUpdated 2 days ago
    Data & AnalyticsAuto-check passed
  • Agentic Kaggle Workflow

    FrankS-IntelLab/agentic-kaggle-skill

    Takes a Kaggle competition from rules and validation design through baselines, ensembling and notebook architecture to a scored submission.

    188 GitHub stars~4k tokensUpdated 3 mo ago
    Data & AnalyticsAuto-check passed
  • Billing Review

    polarsource/polar

    Review a diff that touches Polar's billing domain — subscriptions, cycles and crons, orders, billing entries, meters and usage, discounts, checkout, payments and dunning, refunds, disputes, payouts…

    10k GitHub stars~2.3k tokensUpdated today
    Data & AnalyticsAuto-check passed
  • Fast Dash

    dkedar7/fast_dash

    Build a Fast Dash web app from a Python function. An agent skill from dkedar7/fast_dash.

    129 GitHub stars~1.9k tokensUpdated 4 days ago
    Data & AnalyticsAuto-check passed

More from RussellSB/pytrendy

  • Debug

    RussellSB/pytrendy

    A skill your agent uses when debugging a pytrendy bug, reproducing a regression, or inspecting intermediate pipeline stage output.

    106 GitHub stars~1.9k tokensUpdated yesterday
    Auto-check passed
  • PR Plots

    RussellSB/pytrendy

    A skill your agent uses when preparing a fix or feature PR for review and adding before/after plot evidence to the PR body.

    106 GitHub stars~1.2k tokensUpdated yesterday
    Auto-check passed
  • Pytrendy

    RussellSB/pytrendy

    A skill your agent uses when working on pytrendy code, tests, or data.

    106 GitHub stars~2.5k tokensUpdated yesterday
    Auto-check passed
  • Cicd

    RussellSB/pytrendy

    A skill your agent uses when touching .github/workflows/, release config (.releaserc), mkdocs.yml, docs deploy, or the whats-new generator.

    106 GitHub stars~1.6k tokensUpdated yesterday
    Auto-check passed

Questions about Maintenance

What does Maintenance do?

A skill your agent uses when making ANY code change to pytrendy, creating issues, or opening PRs. Maintenance is an agent skill from RussellSB/pytrendy. Use when making ANY code change to pytrendy, creating issues, or opening PRs.

When should I use Maintenance?

Maintenance fits situations like: making ANY code change to pytrendy; creating issues.

How do I install Maintenance in Claude Code?

Run `npx skills add RussellSB/pytrendy --skill maintenance -a claude-code`. Or copy the skill folder (.opencode/skills/maintenance in RussellSB/pytrendy) into .claude/skills/maintenance in your project. Claude Code loads it when a task matches its description.

How do I install Maintenance in Codex?

Run `npx skills add RussellSB/pytrendy --skill maintenance -a codex`. Or copy the skill folder (.opencode/skills/maintenance in RussellSB/pytrendy) into .agents/skills/maintenance in your project. Codex loads it when a task matches its description.

Can I use Maintenance in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add RussellSB/pytrendy --skill maintenance -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/maintenance, .gemini/skills/maintenance, .github/skills/maintenance and .opencode/skills/maintenance in your project.

What does Maintenance need to run?

Going by SKILL.md and its folder, Maintenance needs the command-line tools its instructions call (git and poetry). Our summary lists: Python 3.

Does Maintenance access the network?

SKILL.md contains no URLs. Its commands use git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Maintenance safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Maintenance use?

Maintenance is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Maintenance use?

About 2.1k tokens (SKILL.md is roughly 8.5k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Maintenance?

Skills that share tags, products or a category with Maintenance: AI Daily Digest (vigorX777/ai-daily-digest, 1.6k stars), Documd Visuals (markdown-viewer/skills, 3.4k stars), Retentioneering Contributing (retentioneering/retentioneering-tools, 925 stars) and Agentic Kaggle Workflow (FrankS-IntelLab/agentic-kaggle-skill, 188 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Maintenance?

RussellSB (a GitHub user) maintains it in RussellSB/pytrendy, which has 106 GitHub stars. The repository holds 5 skills in this directory. The repository was last updated on October 8, 2026.

Source: RussellSB/pytrendy on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.