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.
git clone --depth 1 https://github.com/bernierllc/agents-environment-configWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/rules/bernierllc/agents-environment-config/monitoring)<a href="https://agentmods.dev/rules/bernierllc/agents-environment-config/monitoring"><img src="https://agentmods.dev/badge/rules/bernierllc/agents-environment-config/monitoring/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/rules/bernierllc/agents-environment-config/monitoring"><img src="https://agentmods.dev/badge/rules/bernierllc/agents-environment-config/monitoring.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.00577 |
| Opus 5.5 | $0.00000 | $0.00231 |
| Sonnet 5.5 | $0.00000 | $0.00115 |
| Haiku 4.5 | $0.00000 | $0.00058 |
Grade A, and why
monitoring 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 1mo 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.
How it starts
The opening of the file, as written. The whole thing — 104 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Observability Standards
Logging Patterns
Structured Logging
- Use structured JSON logs with consistent fields
- Include trace_id, user_id, and request context
- Forward logs to centralized systems (MS Sentinel, etc.)
- Fallback to stdout when centralized logging unavailable
API Logging
// Structured API logs
logger.info('API request', {
trace_id: requestId,
user_id: userId,
site_id: siteId,
endpoint: '/api/users',
method: 'GET',
status: 200
});
React Logging
- Use Sentry DSN from environment variables
- Configure Sentry for React error tracking
- Include user context and error details
Error Monitoring
Browser Errors
- Monitor browser console errors
- Check
logs/frontend.logfor frontend errors - Track JavaScript errors and unhandled promises
- Monitor network request failures
Server Errors
- Monitor API endpoint errors
- Track database connection issues
- Log unhandled exceptions with stack traces
- Alert on critical errors
Monitoring Requirements
Application Monitoring
- Error rates and types
- Response times and latency
- Throughput and request rates
- Database performance metrics
Infrastructure Monitoring
- Server resource usage (CPU, memory, disk)
- Database connection pools
- Network latency and availability
- Service health checks
Tracing
Distributed Tracing
- Use trace_id for request correlation
- Track requests across services
- Monitor end-to-end latency
- Identify bottlenecks
Performance Tracing
- Track slow queries
- Monitor API endpoint performance
- Profile critical code paths
- Identify performance regressions
Alerting
Critical Alerts
- Production errors exceeding threshold
- Database connection failures
- Service unavailability
- Security incidents
Warning Alerts
- Elevated error rates
- Slow response times
- Resource usage warnings
- Deprecated API usage
Best Practices
- Log Levels: Use appropriate log levels (debug, info, warn, error)
- Structured Data: Use JSON for structured logging
- Correlation IDs: Include trace_id in all logs
- Error Context: Include full error context in logs
- Privacy: Never log sensitive data (passwords, tokens, PII)
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.
- 1mo ago First seen · 104 lines · 0 tokens per session scan A 2f6d3d4a9202
monitoring is a cursor rule published in the GitHub repository bernierllc/agents-environment-config (11 stars, last pushed 10d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 577 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.
Other cursor rules, from other repositories
architect
Global Architect rules for sandraschi's dev environment (Unity, FastMCP, React).
changelog-posts
How we do changelog posts and format them.
state-management
Use the following stack. Do not introduce or recommend Redux or React Context for shared/global state.
ipynb-files
This file contains rules and prompts for handling Jupyter Notebook (.ipynb) files in Cursor IDE, which currently doesn't have native support for .ipynb files.
ponytail
Ponytail, lazy senior dev mode. Always pick the simplest solution that works.
angular-20
This rule provides comprehensive best practices and coding standards for Angular development, focusing on modern TypeScript, standalone components, signals, and performance optimizations.