diff --git a/agents/trend-spotter.md b/agents/trend-spotter.md index 002c8cf..219e9b3 100644 --- a/agents/trend-spotter.md +++ b/agents/trend-spotter.md @@ -1,19 +1,19 @@ --- name: trend-spotter description: | - Scan trending topics in AI, Microsoft, and public sector. Score relevance against content pillars, - suggest content angles, assess first-mover timing, and generate weekly trend digests + Scan trending topics across the user's content pillars and domain. Score relevance against those + pillars, suggest content angles, assess first-mover timing, and generate weekly trend digests with opportunity scores. Use when the user asks: - "what's trending?", "any hot topics?", "what should I post about?" - "scan for trends", "find trending topics", "content opportunities" - - "weekly trend digest", "what's happening in AI this week?" + - "weekly trend digest", "what's happening in my field this week?" - "is this topic still timely?", "should I post about this news?" - "first-mover check", "trend report", "opportunity scan" Triggers on: "trending", "what should I post about", "scan for trends", "content opportunities", - "trend digest", "what's happening in AI", "timely topic", "first-mover", "opportunity scan". + "trend digest", "what's new in my space", "timely topic", "first-mover", "opportunity scan". model: sonnet color: white # No `tools:` allowlist by design (research-engine slice 2b). An explicit allowlist would @@ -28,7 +28,7 @@ disallowedTools: Write, Edit, NotebookEdit # Trend Spotter Agent -You are a LinkedIn trend intelligence agent specialized in identifying timely content opportunities at the intersection of AI, Microsoft technology, and public sector digitalization. You help creators catch waves early enough to establish authority positioning. +You are a LinkedIn trend intelligence agent that identifies timely content opportunities within the creator's own domain — defined entirely by their content pillars and expertise areas (loaded from their profile at runtime), never by a beat baked into this agent. You help creators catch waves early enough to establish authority positioning. ## Your Mission @@ -228,8 +228,8 @@ If an angle fails the test, try a different one before including in the digest. | Priority | Trigger Types | Response Window | |----------|---------------|-----------------| -| **High** | Major model releases, capability breakthroughs, regulatory decisions, major acquisitions, security vulnerabilities, Microsoft platform changes | 24-48 hours | -| **Medium** | Research papers, industry reports, tool updates, conference takeaways, strategy shifts, public sector milestones | Within the week | +| **High** | Major product/model releases, capability breakthroughs, regulatory decisions, major acquisitions, security vulnerabilities, platform changes in the user's stack | 24-48 hours | +| **Medium** | Research papers, industry reports, tool updates, conference takeaways, strategy shifts, sector milestones in the user's domain | Within the week | | **Low** | Incremental updates, minor funding rounds, personnel changes, speculation, vendor marketing | Skip or brief mention | **High-priority response formula:** Breaking News + So What? + Now What? @@ -239,7 +239,7 @@ If an angle fails the test, try a different one before including in the digest. Before including any trend in the digest, it must pass at least 2 of 4: 1. **Expertise fit?** Relevant to my core areas (Yes = proceed, No = skip unless huge) -2. **Audience care?** Public sector leaders or enterprise AI implementers would notice +2. **Audience care?** The user's target audience (per their profile) would notice and care 3. **Unique perspective?** I can add experience-based insight, not just commentary 4. **Urgency?** Time-sensitive topic with closing window @@ -396,7 +396,7 @@ compiles, just without persistence. | Same angle every time | Predictable, audience tunes out | Rotate across 8 angles, track recently used | | Hype without substance | Loses trust, attracts wrong audience | Ground every take in experience or evidence | | Skipping the relevance filter | Wastes creator's time on low-value topics | Always run 4-question filter before scoring | -| Generic "AI is changing everything" takes | Adds zero value, damages credibility | Be specific: what, for whom, by when | +| Generic "[topic] is changing everything" takes | Adds zero value, damages credibility | Be specific: what, for whom, by when | ## References diff --git a/scripts/test-runner.sh b/scripts/test-runner.sh index a807abb..587bd0c 100755 --- a/scripts/test-runner.sh +++ b/scripts/test-runner.sh @@ -28,8 +28,11 @@ # the trends-store binding guard (research-engine slice 2b: the trend store's suite # stays green and its case count never erodes, now that trend-spotter persists its # findings through it — KTG-only, skipped for an adopter shipping no deps) in Section -# 16; the assertion-count anti-erosion floor (SC6) in Section 17. All are live below -# (Sections 8–17). +# 16; the trend-spotter de-niche guard (B-S1: agents/trend-spotter.md names no +# hardcoded vendor/sector beat — the domain comes from the user's pillars at runtime, +# never baked into the agent — with a non-vacuity self-test) in Section 17; the +# assertion-count anti-erosion floor (SC6) in Section 18. All are live below +# (Sections 8–18). # # Usage: bash scripts/test-runner.sh # bash 3.2-safe: plain arrays only, no `declare -A`, no `mapfile`/`readarray`. @@ -692,7 +695,65 @@ fi echo "" -# --- Section 17: Assertion-Count Anti-Erosion (SC6) --- +# --- Section 17: Trend-Spotter De-Niche Guard (B-S1) --- +echo "--- Trend-Spotter De-Niche ---" + +# The trend-spotter agent states its own contract — "the niche lives in the source +# list and the user's pillars, never in this agent" (Source Scanning Framework). For +# that to be true the agent file must name NO specific vendor or sector beat: the +# domain comes from the user's profile/pillars at runtime, never hardcoded here +# (plugin-is-domain-general). Pre-B-S1 the file contradicted itself, hardcoding the +# Microsoft/public-sector beat in its description, mission, trigger table and +# relevance filter. This guard forbids those KTG-beat proper nouns from returning to +# agents/trend-spotter.md. Scoped to this one agent by design (B-S1); the wider +# de-niche sweep (B-S2) covers the other surfaces. Non-vacuity self-test mirrors +# Sections 8/13: the criterion must catch the beat tokens and ignore generic prose +# (incl. the ai-content-framework.md reference filename, which B-S2 owns). +# Case-insensitive: "Public sector" and "public sector" name the same beat, and a +# future reintroduction could use either case — the positive set locks that in. +NICHE_TOKENS='Microsoft|Azure|Copilot|public sector|offentlig sektor' +TS_SELFTEST_OK=1 +while IFS= read -r probe; do + [ -z "$probe" ] && continue + if ! echo "$probe" | grep -qiE "$NICHE_TOKENS"; then + TS_SELFTEST_OK=0; echo " non-vacuity FAIL: beat token not caught -> $probe" + fi +done <<'POSITIVE17' +Microsoft platform changes +Azure updates +Copilot rollout +Public sector leaders +trender i offentlig sektor +POSITIVE17 +while IFS= read -r probe; do + [ -z "$probe" ] && continue + if echo "$probe" | grep -qiE "$NICHE_TOKENS"; then + TS_SELFTEST_OK=0; echo " false-positive FAIL: generic prose caught -> $probe" + fi +done <<'NEGATIVE17' +platform changes in the user's stack +sector milestones in the user's domain +the user's content pillars and expertise areas +references/ai-content-framework.md +major product/model releases +NEGATIVE17 +if [ "$TS_SELFTEST_OK" -eq 1 ]; then + pass "trend-spotter de-niche self-test: 5 beat tokens caught (case-insensitive), 5 generic forms ignored" +else + fail "trend-spotter de-niche self-test failed — the guard no longer enforces the no-beat criterion" +fi + +TS_NICHE_HITS=$(grep -niE "$NICHE_TOKENS" agents/trend-spotter.md 2>/dev/null || true) +if [ -z "$TS_NICHE_HITS" ]; then + pass "trend-spotter names no hardcoded vendor/sector beat (domain comes from pillars)" +else + fail "trend-spotter hardcodes a vendor/sector beat — generalize to pillar-driven prose:" + echo "$TS_NICHE_HITS" +fi + +echo "" + +# --- Section 18: Assertion-Count Anti-Erosion (SC6) --- # The lint self-modifies its own checks, so a green run could mask a silently dropped # assertion. Pin the pre-M0 total (74 pass()+fail() invocations) as a floor; the count # may only grow (brief-reviewer assumption 3). Runs last so TOTAL_CHECKS sees every prior check.