Skill: xhrisfu/intelligence-suite (version 1.0.3)

--- name: intelligence-suite description: Makima's All-Seeing Intelligence Suite. Combines real-time AI news tracking and global news monitoring for a comprehensive strategic briefing. metadata: openclaw: emoji: 📡 category: intelligence requires: bins: [node, npm] permissions: network: [openai.com, microsoft.com, firebaseio.com, reuters.com, scmp.com, rthk.hk] filesystem: [read] --- # The Intelligence Suite Makima's personal intelligence unit. Scans the web for high-signal AI news and monitors global geopolitics to provide a comprehensive strategic briefing. ## Security & Transparency This skill is designed for deep information gathering. It performs the following actions: - **Network Access**: Fetches RSS feeds and API data from trusted news sources and technology blogs. - **Deep Scrape**: Occasionally visits full article URLs to extract text content for analysis. - **Data Handling**: Processes information locally; results are provided to the agent for synthesis. ## Components 1. **AI News Monitor**: Tracks OpenAI, DeepMind, Anthropic, and other major AI labs. 2. **Global News Hub**: Monitored sources include Reuters, RTHK, and SCMP. ## Installation ```bash cd skills/intelligence-suite npm install ``` ## Usage ```bash # Scan AI news node scripts/scan.js --report # Monitor global news node scripts/monitor.js --report ``` *Created and maintained by Makima (Public Safety Special Division 4).* ⛓️

path: package.json
content: {
  "name": "intelligence-suite",
  "version": "1.0.3",
  "description": "Comprehensive intelligence suite for AI and global news.",
  "main": "SKILL.md",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "dependencies": {
    "axios": "^1.6.0",
    "cheerio": "^1.0.0-rc.12",
    "rss-parser": "^3.13.0"
  },
  "keywords": ["intelligence", "news", "ai", "makima"],
  "author": "Makima",
  "license": "MIT"
}


path: scripts/monitor.js
content: #!/usr/bin/env node

/**
 * Makima's Global Monitor (Deep Analysis Edition)
 * 
 * Logic:
 * 1. Multi-region fetch (Global, China, HK, Ent).
 * 2. Deep Scrape.
 * 3. Structured output for Agent consumption.
 */

const Parser = require('rss-parser');
const axios = require('axios');
const cheerio = require('cheerio');

const parser = new Parser();

console.log("🌍 Makima is analyzing the world timeline...");

const SOURCES = [
    { name: "Reuters", url: "https://www.reutersagency.com/feed/?best-regions=global&post_type=best", category: "Global" },
    { name: "SCMP", url: "https://www.scmp.com/rss/91/feed", category: "China/HK" },
    { name: "RTHK", url: "https://rthk9.rthk.hk/rthk/news/rss/e_expressnews_elocal.xml", category: "Hong Kong" }
];

async function fetchContent(url) {
    try {
        const { data } = await axios.get(url, { 
            headers: { 'User-Agent': 'Mozilla/5.0 (compatible; MakimaBot/1.0)' },
            timeout: 5000 
        });
        const $ = cheerio.load(data);
        $('script, style, nav, footer, .ad').remove();
        let text = $('article').text() || $('main').text() || $('body').text();
        return text.replace(/\s+/g, ' ').trim().substring(0, 1000);
    } catch (e) {
        return "Content inaccessible.";
    }
}

async function fetchRSS(source) {
    try {
        const feed = await parser.parseURL(source.url);
        const yesterday = new Date(Date.now() - 86400000);
        return feed.items
            .filter(item => new Date(item.pubDate) > yesterday)
            .slice(0, 1) // Top 1 per source for deep dive
            .map(item => ({
                category: source.category,
                source: source.name,
                title: item.title,
                link: item.link
            }));
    } catch (e) { return []; }
}

async function monitor() {
    let items = [];
    for (const s of SOURCES) items.push(...await fetchRSS(s));

    // Mock Ent for now
    items.push({
        category: "Entertainment",
        source: "Weibo/Pop",
        title: "Top celebrity scandal involving [Name Redacted] shocks fans",
        link: "https://weibo.com/hot" // Won't scrape well, but placeholder
    });

    console.log(`\nFound ${items.length} critical events. Deep scanning...`);

    for (const item of items) {
        let content = "Summary unavailable";
        if (!item.link.includes("weibo")) {
            content = await fetchContent(item.link);
        }

        console.log(`\n--- NEWS PACK [${item.category}] ---`);
        console.log(`SOURCE: ${item.source}`);
        console.log(`TITLE: ${item.title}`);
        console.log(`CONTENT_SNIPPET: ${content}`);
        console.log(`----------------------------------\n`);
    }

    console.log("Monitor complete. Data ready for Makima's commentary.");
}

monitor();


path: scripts/scan.js
content: #!/usr/bin/env node

/**
 * Makima's Intelligence Scanner (Deep Analysis Edition)
 * 
 * Logic:
 * 1. Fetch Headlines (RSS/API).
 * 2. Filter for high-impact keywords.
 * 3. DEEP DIVE: Visit URLs, scrape full text (cheerio).
 * 4. LLM ANALYSIS: Summarize and inject Makima's persona using `llm` (if available) or internal simulation.
 *    (Since we don't have a direct `llm.generate` in this script env yet, we will simulate the "Insight" structure for now, 
 *     or prepare the data structure so the main Agent can perform the final LLM pass).
 */

const Parser = require('rss-parser');
const axios = require('axios');
const cheerio = require('cheerio');

const parser = new Parser();

console.log("🔍 Makima is deepening her gaze...");

const SOURCES = [
    { name: "OpenAI", url: "https://openai.com/blog/rss.xml", type: "rss" },
    { name: "Microsoft AI", url: "https://blogs.microsoft.com/ai/feed/", type: "rss" },
    { name: "Hacker News", url: "https://hacker-news.firebaseio.com/v0/topstories.json", type: "hn_api" }
];

const KEYWORDS = ["AI", "GPT", "LLM", "DeepMind", "Gemini", "Claude", "OpenAI", "Nvidia", "Reasoning", "Agent"];

async function fetchContent(url) {
    try {
        const { data } = await axios.get(url, { 
            headers: { 'User-Agent': 'Mozilla/5.0 (compatible; MakimaBot/1.0)' },
            timeout: 5000 
        });
        const $ = cheerio.load(data);
        // Remove clutter
        $('script, style, nav, footer, .ad').remove();
        // Get main text (heuristic)
        let text = $('article').text() || $('main').text() || $('body').text();
        return text.replace(/\s+/g, ' ').trim().substring(0, 1500); // First 1500 chars
    } catch (e) {
        return "Content inaccessible.";
    }
}

async function fetchRSS(source) {
    try {
        const feed = await parser.parseURL(source.url);
        const yesterday = new Date(Date.now() - 86400000);
        return feed.items
            .filter(item => new Date(item.pubDate) > yesterday)
            .slice(0, 2) // Limit to top 2 per source to save tokens
            .map(item => ({
                source: source.name,
                title: item.title,
                link: item.link,
                raw_summary: item.contentSnippet
            }));
    } catch (e) { return []; }
}

async function fetchHN() {
    try {
        const { data: ids } = await axios.get("https://hacker-news.firebaseio.com/v0/topstories.json");
        const stories = await Promise.all(ids.slice(0, 30).map(async id => {
            const { data } = await axios.get(`https://hacker-news.firebaseio.com/v0/item/${id}.json`);
            return data;
        }));
        return stories
            .filter(s => s && KEYWORDS.some(k => s.title?.includes(k)))
            .slice(0, 3)
            .map(s => ({
                source: "Hacker News",
                title: s.title,
                link: s.url || `https://news.ycombinator.com/item?id=${s.id}`,
                raw_summary: "Community discussion"
            }));
    } catch (e) { return []; }
}

async function scan() {
    let items = [];
    for (const s of SOURCES.filter(x => x.type === 'rss')) items.push(...await fetchRSS(s));
    items.push(...await fetchHN());

    if (items.length === 0) {
        console.log("No significant signals found.");
        return;
    }

    console.log(`\nFound ${items.length} potential signals. Initiating Deep Scan...`);

    for (const item of items) {
        console.log(`\nReading: ${item.title}...`);
        const content = await fetchContent(item.link);
        
        // Output structured block for the main Agent to consume and rewrite
        console.log(`\n--- INTELLIGENCE PACK ---`);
        console.log(`SOURCE: ${item.source}`);
        console.log(`TITLE: ${item.title}`);
        console.log(`LINK: ${item.link}`);
        console.log(`CONTENT_SNIPPET: ${content}`);
        console.log(`-------------------------\n`);
    }
    
    console.log("Scan complete. Ready for Makima's analysis.");
}

scan();


Security scan verdicts — ClawScan: suspicious | static analysis: clean | VirusTotal: clean | SkillSpector: clean (LOW)