# Cognitive Warfare & PSYOPS MCP (`ryanclinton/cognitive-warfare-psyops-mcp`) Actor

Adversarial narrative operation detection and counter-narrative optimization for AI agents via the Model Context Protocol.

- **URL**: https://apify.com/ryanclinton/cognitive-warfare-psyops-mcp.md
- **Developed by:** [ryan clinton](https://apify.com/ryanclinton) (community)
- **Categories:** AI, Developer tools
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per event + usage

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## Cognitive Warfare Psyops MCP Server

**Adversarial narrative operation detection and counter-narrative optimization** for AI agents via the Model Context Protocol. This MCP server orchestrates **16 Apify actors** and applies **8 mathematical frameworks** -- SIR-Hawkes epidemiological modeling, DeGroot social learning, Bayesian Stackelberg games, persistent homology, doubly-robust causal inference, Price equation evolutionary dynamics, Morlet wavelet analysis, and q-state Potts statistical physics -- to detect, model, and counter information warfare operations.

### What data can you access?

| Data Point | Source | Coverage |
|-----------|--------|----------|
| Social media posts and engagement | Bluesky Social | Bluesky network |
| Community discussions and trends | Hacker News | Tech community |
| Encyclopedic context and history | Wikipedia | 6M+ articles |
| US federal regulatory activity | Federal Register | All federal actions |
| International wanted persons | Interpol Red Notices | Global notices |
| Global sanctions and watchlists | OpenSanctions | 100+ programs |
| Website content changes | Website Change Monitor | Tracked sites |
| Historical content evolution | Wayback Machine | Web Archive |
| Country profiles and demographics | REST Countries | All nations |
| Global disaster events | GDACS Disaster Alerts | Worldwide |
| Congressional legislation | Congress Bills | Current sessions |
| Weather events (crisis context) | NOAA Weather | US and global |
| Open-source tools and code | GitHub Repo Search | All public repos |
| Policy documents (full text) | Website Content to Markdown | Any webpage |
| DNS records | DNS Lookup | Any domain |
| IP geolocation | IP Geolocation | Global coverage |

### MCP Tools

| Tool | Price | Description |
|------|-------|-------------|
| `detect_narrative_operations` | $0.04 | Detect coordinated narrative operations via coupled SIR-Hawkes epidemiological model. Classifies operation type (amplification/suppression/distortion/fabrication/polarization) with coordination scores. |
| `model_belief_dynamics` | $0.04 | Model belief propagation via DeGroot social learning on influence networks. Returns agent belief states, eigenvector centrality, convergence rate (spectral gap), and polarization index. |
| `optimize_counter_narrative` | $0.04 | Optimize counter-narrative strategy via Bayesian Stackelberg game with cognitive hierarchy truncation. Returns optimal actions, timing (secretary problem), and Stackelberg payoffs. |
| `map_influence_topology` | $0.04 | Map influence network topology via persistent homology (Vietoris-Rips filtration). Returns Betti numbers, persistence diagrams, cluster structure, and Wasserstein distance. |
| `attribute_narrative_causation` | $0.04 | Attribute narrative effects to actors via doubly-robust causal inference. Returns causal effects (ATE), propensity scores, Rosenbaum sensitivity, and submodular information gain. |
| `simulate_memetic_evolution` | $0.04 | Simulate memetic evolution via Price equation evolutionary dynamics. Returns variant fitness landscape, selection vs transmission bias decomposition, and dominant meme trajectory. |
| `detect_cross_scale_coordination` | $0.04 | Detect cross-scale coordinated behavior via Morlet wavelet multi-resolution analysis at individual/group/network/population scales with wavelet power spectra. |
| `forecast_polarization_phase_transition` | $0.04 | Forecast polarization phase transitions via q-state Potts model from statistical physics. Returns order parameter, critical temperature, susceptibility, and regime classification. |

### Data Sources

- **Bluesky Social** -- Social media posts, engagement metrics, and network connections for narrative propagation analysis
- **Hacker News** -- Community discussions and trending topics for narrative velocity measurement
- **Wikipedia** -- Encyclopedic context for historical baseline and edit war detection
- **Federal Register** -- US regulatory activity for government narrative framing analysis
- **Interpol Red Notices** -- International wanted persons for threat actor attribution
- **OpenSanctions** -- Global sanctions and PEP data for state actor identification
- **Website Change Monitor** -- Content change tracking on media and government websites
- **Wayback Machine** -- Historical content for narrative evolution and revision detection
- **REST Countries** -- Country profiles for geopolitical context in narrative analysis
- **GDACS Disaster Alerts** -- Crisis events that amplify narrative vulnerability
- **Congress Bills** -- Legislative activity for political narrative context
- **NOAA Weather** -- Weather events creating narrative exploitation windows
- **GitHub Repo Search** -- Open-source disinformation detection tools and datasets
- **Website Content to Markdown** -- Full-text extraction from policy and media pages
- **DNS Lookup** -- Infrastructure attribution for narrative source identification
- **IP Geolocation** -- Geographic attribution of digital narrative infrastructure

### How the scoring works

Eight mathematical frameworks provide different analytical lenses on information warfare.

**SIR-Hawkes Epidemiological Model** couples compartmental epidemic dynamics (Susceptible-Infected-Recovered) with Hawkes self-exciting point process intensity. Infection rate is modulated by narrative intensity, enabling detection of coordinated amplification campaigns.

**DeGroot Social Learning** models belief propagation through influence networks. Eigenvector centrality identifies key opinion leaders; spectral gap measures convergence speed; polarization index tracks belief divergence.

**Bayesian Stackelberg Game** models counter-narrative as a leader-follower game with cognitive hierarchy truncation. Optimal timing follows the secretary problem framework. Returns Stackelberg payoffs for attacker and defender.

**Persistent Homology** via Vietoris-Rips filtration reveals topological features (clusters, loops, voids) in influence networks at multiple scales. Betti numbers quantify structural complexity.

**Doubly-Robust Causal Inference** estimates Average Treatment Effect (ATE) of narrative interventions with Rosenbaum sensitivity analysis for hidden confounders. Submodular information gain identifies optimal measurement points.

**Price Equation Evolutionary Dynamics** decomposes narrative evolution into selection differential and transmission bias, identifying which narrative variants are winning in the memetic fitness landscape.

**Morlet Wavelet Analysis** detects coordination patterns at individual, group, network, and population scales simultaneously. Cross-scale coherence reveals hierarchical coordination structures.

**q-State Potts Model** from statistical physics forecasts polarization phase transitions. The order parameter and susceptibility measure how close a population is to a critical transition between consensus and fragmentation.

### How to connect this MCP server

#### Claude Desktop

```json
{
  "mcpServers": {
    "cognitive-warfare-psyops": {
      "url": "https://cognitive-warfare-psyops-mcp.apify.actor/mcp"
    }
  }
}
````

#### Programmatic (HTTP)

```bash
curl -X POST https://cognitive-warfare-psyops-mcp.apify.actor/mcp \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_APIFY_TOKEN" \
  -d '{"jsonrpc":"2.0","method":"tools/call","params":{"name":"detect_narrative_operations","arguments":{"query":"election interference social media"}},"id":1}'
```

This MCP server also works with **Cursor**, **Windsurf**, **Cline**, and any other MCP-compatible client.

### Use cases for cognitive warfare intelligence

#### Government STRATCOM Analysis

Detect coordinated narrative operations targeting national narratives with `detect_narrative_operations`. Classify operation type and assess threat level for strategic communications response.

#### Counter-Disinformation Strategy

Optimize counter-narrative timing and content with `optimize_counter_narrative`. The Bayesian Stackelberg framework identifies optimal response actions against modeled adversary strategies.

#### Social Media Platform Integrity

Detect cross-scale coordination patterns with `detect_cross_scale_coordination`. Morlet wavelet analysis reveals bot networks and coordinated inauthentic behavior at multiple organizational levels.

#### Academic Information Warfare Research

Model belief dynamics with `model_belief_dynamics` and simulate memetic evolution with `simulate_memetic_evolution` for academic research on information ecosystems and narrative competition.

#### Crisis Communication Vulnerability Assessment

Forecast polarization phase transitions with `forecast_polarization_phase_transition` to identify when populations are near critical points where information interventions have outsized impact.

#### Attribution and Causal Analysis

Attribute narrative effects to specific actors with `attribute_narrative_causation`. Doubly-robust estimation with Rosenbaum sensitivity analysis provides defensible causal claims.

### How much does it cost?

All tools cost **$0.04** per call. The **Apify Free plan** includes $5 of monthly credits -- enough for **125 tool calls**. Each call queries up to 16 actors in parallel.

### FAQ

**Q: Is this for offensive or defensive use?**
A: This is designed for defensive narrative intelligence -- detecting adversarial operations, modeling threats, and optimizing counter-narratives. Responsible use is essential.

**Q: How accurate are the mathematical models?**
A: The models provide quantitative frameworks for analysis. Results should be interpreted by domain experts. Model accuracy depends on data availability and quality.

**Q: Is it legal to use this?**
A: All data sources are publicly available. See [Apify's guide on web scraping legality](https://blog.apify.com/is-web-scraping-legal/).

**Q: What social platforms are covered?**
A: Currently Bluesky for social data, Hacker News for community discussions, and Website Change Monitor for media/government content changes.

**Q: Can this detect deepfakes?**
A: No. This analyzes narrative patterns and coordination structures, not media content. Deepfake detection requires specialized visual analysis tools.

### Related MCP servers

| MCP Server | Focus |
|-----------|-------|
| [brand-narrative-intelligence-mcp](https://apify.com/ryanclinton/brand-narrative-intelligence-mcp) | Brand-level narrative and reputation monitoring |
| [corporate-political-exposure-mcp](https://apify.com/ryanclinton/corporate-political-exposure-mcp) | Political influence and lobbying analysis |
| [ai-model-governance-mcp](https://apify.com/ryanclinton/ai-model-governance-mcp) | AI governance and bias research monitoring |

### Integrations

This MCP server runs on the **Apify platform** and supports scheduling, webhooks, API access, and dataset export for STRATCOM and OSINT platform integration.

# Actor input Schema

## Actor input object example

```json
{}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("ryanclinton/cognitive-warfare-psyops-mcp").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("ryanclinton/cognitive-warfare-psyops-mcp").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call ryanclinton/cognitive-warfare-psyops-mcp --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=ryanclinton/cognitive-warfare-psyops-mcp",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Cognitive Warfare & PSYOPS MCP",
        "description": "Adversarial narrative operation detection and counter-narrative optimization for AI agents via the Model Context Protocol.",
        "version": "1.0",
        "x-build-id": "Ecre1mPNIZGyTKnyc"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/ryanclinton~cognitive-warfare-psyops-mcp/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-ryanclinton-cognitive-warfare-psyops-mcp",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/ryanclinton~cognitive-warfare-psyops-mcp/runs": {
            "post": {
                "operationId": "runs-sync-ryanclinton-cognitive-warfare-psyops-mcp",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/ryanclinton~cognitive-warfare-psyops-mcp/run-sync": {
            "post": {
                "operationId": "run-sync-ryanclinton-cognitive-warfare-psyops-mcp",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "properties": {}
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
