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.
npx agentmods add commands/codebytemirza/linkedin-post-mcp/aggregatinggit clone --depth 1 https://github.com/codebytemirza/linkedin-post-mcpWhat 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 | $0.00000 | $0.01524 |
| Opus 5 | $0.00000 | $0.00762 |
| Sonnet 5 | $0.00000 | $0.00305 |
| Haiku 4.5 | $0.00000 | $0.00152 |
Grade A, and why
aggregating 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 yesterday.
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.
This is a copy
100% identical to aggregating — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.
How it starts
The opening of the file, as written. The whole thing — 235 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Aggregations
Overview
Run analytics over indexed data using metric and bucket aggregations. Compute statistics, group documents, build histograms, and perform faceted navigation. Aggregations can be nested for multi-level analysis.
Good For
- Computing averages, sums, min/max across documents
- Grouping documents by field values (category breakdown)
- Building price range facets for e-commerce
- Histogram distributions (price ranges, date ranges)
- Multi-level analytics (average price per category)
Examples
Metric Aggregations
import { Redis, s } from "@upstash/redis";
const redis = Redis.fromEnv();
const index = await redis.search.createIndex({
name: "orders",
prefix: "order:",
dataType: "json",
schema: s.object({
product: s.string(),
category: s.facet(),
price: s.number("F64"),
quantity: s.number("U64"),
date: s.date(),
}),
});
// Insert sample data
await redis.json.set("order:1", "$", {
product: "Laptop",
category: "electronics",
price: 999.99,
quantity: 1,
date: "2024-06-15",
});
await redis.json.set("order:2", "$", {
product: "Mouse",
category: "electronics",
price: 29.99,
quantity: 3,
date: "2024-06-16",
});
await redis.json.set("order:3", "$", {
product: "Desk",
category: "furniture",
price: 249.99,
quantity: 1,
date: "2024-07-01",
});
await index.waitIndexing();
// Average price
const result = await index.aggregate({
aggregations: {
avg_price: { $avg: { field: "price" } },
},
});
// result.avg_price -> number
// Multiple metrics at once
const stats = await index.aggregate({
aggregations: {
avg_price: { $avg: { field: "price" } },
total_revenue: { $sum: { field: "price" } },
cheapest: { $min: { field: "price" } },
most_expensive: { $max: { field: "price" } },
order_count: { $count: { field: "price" } },
},
});
// Combined statistics
const priceStats = await index.aggregate({
aggregations: {
price_stats: { $stats: { field: "price" } },
// Returns: { count, min, max, sum, avg }
},
});
// Extended statistics (includes variance and standard deviation)
const extended = await index.aggregate({
aggregations: {
price_extended: { $extendedStats: { field: "price" } },
// Returns: { count, min, max, sum, avg, sumOfSquares, variance, stdDeviation }
},
});
// Percentiles
const percentiles = await index.aggregate({
aggregations: {
price_percentiles: { $percentiles: { field: "price", percents: [25, 50, 75, 95] } },
},
});
// Count distinct values
const uniqueCategories = await index.aggregate({
aggregations: {
unique_cats: { $cardinality: { field: "category" } },
},
});
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.
- yesterday First seen · 235 lines · 0 tokens per session scan A 372b2c0acdea
aggregating is a command published in the GitHub repository codebytemirza/linkedin-post-mcp (0 stars, last pushed 20d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,524 tokens. A static security scan graded it A with 0 findings. It is 100% identical to aggregating, differing in 0 lines, and is treated as a copy.
Other commands, from other repositories
checklist
Generate a custom checklist for the current feature based on user requirements.
clarify
Identify underspecified areas in the current feature spec by asking up to 5 highly targeted clarification questions and encoding answers back into the spec.
specify
Create or update the feature specification from a natural language feature description.
analyze
Perform a non-destructive cross-artifact consistency and quality analysis across spec.md, plan.md, and tasks.md after task generation.
converge
Assess the current codebase against the feature's spec, plan, and tasks, then append any remaining unbuilt work as new tasks to tasks.md so implement can complete it.
implement
Execute the implementation plan by processing and executing all tasks defined in tasks.md.