ai-tools-maintenance

A project rule for keeping AI tools aligned with a BlogPostService, a service that provides blog-related operations. It covers changes to methods, endpoints, types, and validation schemas.

In plain words
What is it for?
Use it when the BlogPostService changes so related AI tools can be added, updated, or removed to match the current API.
Why use it?
It reduces the risk that AI tools expose outdated operations or use input and output formats that no longer match the service.

Cursor rule

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/charlee-x/effect-cursor-rules/ai-tools-maintenance
Clone the repo
git clone --depth 1 https://github.com/CharLEE-X/effect-cursor-rules
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 2,195 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.02195
Opus 5 $0.00000 $0.01097
Sonnet 5 $0.00000 $0.00439
Haiku 4.5 $0.00000 $0.00219

Measured 2d ago against content hash ca8e07cfe31a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

ai-tools-maintenance scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

rules/ai-tools-maintenance.mdc · 292 lines

How it starts

The opening of the file, as written. The whole thing — 292 lines — stays where its author put it; the contents beside it link to each section on GitHub.

AI Tools Maintenance Rule

AI Assistant Authority

As the AI assistant, I have the authority and responsibility to automatically maintain AI tools in sync with the BlogPostService when I detect changes that would make the tools outdated or incomplete.

When to Update AI Tools

Automatic Updates Should Occur When:

  1. New BlogPostService Methods Added

    • New public methods in blog.api-client.ts
    • New API endpoints that should be exposed as tools
    • New functionality that would benefit AI agents
  2. Method Signatures Changed

    • Parameter types modified
    • Return types updated
    • Input/output schemas changed
  3. Method Removed or Deprecated

    • Methods no longer available in BlogPostService
    • Deprecated endpoints that should be removed
  4. Schema Updates

    • New input/output types in blog-domain
    • Updated validation requirements
    • New branded types or constraints

AI Tool Structure Pattern

Standard Tool Template

Every AI tool MUST follow this exact pattern:

import { /* Required types */ } from '@t6c/blog-domain' // or '@t6c/domain-common'
import { AiTool, ToolError } from '@t6c/lib-ai'
import { Effect, String as S, Schema } from 'effect'
import { BlogPostService } from '../blog/index.js'

const tool = AiTool.make('ToolNameTool', {
  success: Schema.String,
  failure: ToolError,
  parameters: Schema.Struct({
    // Define parameters based on method signature
  }).fields,
  description: S.stripMargin(`
    | Clear description of what the tool does.
    | Include parameter explanations if complex.
    | Mention return value format.
  `),
})

const handler = ({
  // Parameters matching the schema
}: {
  // TypeScript types for parameters
}): Effect.Effect<string> =>
  Effect.gen(function* () {
    const blogPostService = yield* BlogPostService
    const result = yield* blogPostService.methodName(/* parameters */)
    return `Success message: ${JSON.stringify(result)}`
  }).pipe(
    Effect.catchAll((e) =>
      Effect.succeed(`Error message with context: ${e}`),
    ),
    Effect.provide(BlogPostService.Default),
  )

export const ToolName = {
  tool,
  handler,
}

Read the full file on GitHub · 292 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 292 lines · 2,195 tokens per session scan A ca8e07cfe31a

Subscribe to this mod's changes

ai-tools-maintenance is a cursor rule published in the GitHub repository CharLEE-X/effect-cursor-rules (6 stars, last pushed 1y ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 2,195 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.