Centrality Analysis logo

Centrality Analysis

Community
MattArtzAnthro
centrality-analysis

Compute and compare degree, betweenness, PageRank, eigenvector, closeness, and eccentricity in the loaded Gephi graph. Use to identify hubs, bridges, authorities, and possible structural vulnerabilities without conflating different meanings of importance.

Overview

PublisherMattArtzAnthro
Repositorygephi-ai
Skill namecentrality-analysis
Stars
26
Forks
6
Bundled files
Instructions only
LicenseApache-2.0
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by MattArtzAnthro on GitHub. Read the source before you install it.

Installation

Install the Centrality Analysis AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/MattArtzAnthro/gephi-ai/tree/main/plugins/gephi-network-analysis/skills/centrality-analysis
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/MattArtzAnthro/gephi-ai.git /tmp/gephi-ai
mkdir -p .claude/skills
cp -r /tmp/gephi-ai/plugins/gephi-network-analysis/skills/centrality-analysis .claude/skills/centrality-analysis
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Centrality Analysis in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Centrality Analysis on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Centrality Analysis is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Centrality Analysis Workflow

Run comprehensive centrality analysis to identify the most important and influential nodes in the graph.

Follow the gephi skill's rules throughout; this workflow repeats only the ones it is most likely to break. Read ../gephi/references/statistics-guide.md before interpreting scores, and ../gephi/references/layout-guide.md before the layout step.

Tell the user what you are doing at each step. Narrate briefly before each tool call.

Rules this workflow must keep

  • Session start. Start with gephi_health_check. Then check which workspace is open (gephi_list_workspaces) and whether a filter is active (filter_active in replies): a filter from an earlier conversation stays on, and exports and checks then see only what it shows.
  • Ranking. To rank nodes on a metric, call gephi_query_nodes with sort_by set to the metric, columns set to the few columns you need, and limit about 10: nodes are ordered before paging, so the first page is the top of the whole graph. Without columns, every attribute of every node comes back and a long listing can overflow.
  • No scale-free label. Never call a heavy-tailed degree distribution "scale-free" or a "power law": those fits are near-indistinguishable from log-normal in practice and smuggle in a universal-law claim (Jacomy 2020; Broido and Clauset 2019). Describe hub dominance as a property of this network.
  • Eigenvector caveat. Gephi's eigenvector centrality can rank nodes differently from a standard calculation. Never rank on it alone: compare it with PageRank, and report a node as an authority only when the two agree.

Steps

  1. Session start: Call gephi_health_check. If it fails, tell the user to start Gephi and stop. Call gephi_list_workspaces and gephi_get_project_info for node and edge counts and graph type. If filter_active is true, say that the scores will describe only the visible nodes.

  2. Compute all centrality metrics:

    • Call gephi_compute_degree for degree (number of ties)
    • Call gephi_compute_betweenness for betweenness centrality (how often a node sits on the shortest path between others), closeness, and eccentricity
    • Call gephi_compute_pagerank for PageRank (importance passed on by important neighbours)
    • Call gephi_compute_eigenvector for eigenvector centrality (ties to well-tied nodes)
  3. Rank the top nodes with the ranking rule, one metric at a time:

    • gephi_query_nodes with column: "degree", a min cutoff, and limit: 20: top 10 by degree (hubs)
    • the same with column: "betweenesscentrality": top 10 by betweenness (bridges)
    • the same with column: "pageranks": top 10 by PageRank (importance)
    • the same with column: "eigencentrality", read only beside PageRank (see the eigenvector caveat)
    • Nodes that appear in several top-10 lists are the key actors.
  4. Visualize by betweenness: Call gephi_color_by_ranking with:

    • column: "betweenesscentrality"
    • Light blue to dark red gradient: r_min: 200, g_min: 220, b_min: 255, r_max: 180, g_max: 0, b_max: 0
  5. Size by PageRank: Call gephi_size_by_ranking with column "pageranks" and the default sizes (about one to ten on screen).

  6. Layout: Tell the user: "Running ForceAtlas 2 layout..." Call gephi_run_layout with algorithm "ForceAtlas 2" in two passes with sync: true: first 1500 iterations with properties {"linLogMode": false, "scalingRatio": 10, "strongGravityMode": true, "gravity": 0.01, "barnesHutOptimization": true}, then 3000 iterations with {"linLogMode": true, "scalingRatio": 0.5, "strongGravityMode": true, "gravity": 0.001, "barnesHutOptimization": true} (see the layout guide). Leave Dissuade Hubs off.

  7. Measure vulnerabilities: For the top two or three bridges, call gephi_whatif with [{"op": "remove_node", "id": "<id>"}], one node per call. It works on a scratch copy and never changes the real graph. Report the change in components and giant-component share for each. Also remove the next-ranked comparable node: the effect belongs to the bridge only if it clearly exceeds that comparison.

  8. Report: Present a ranked table of key nodes with their centrality scores. Highlight:

    • Hubs: High degree nodes
    • Bridges: High betweenness, low degree (connecting different communities)
    • Authorities: High PageRank, with eigenvector centrality agreeing
    • Vulnerabilities: Nodes whose removal fragments the network, with the gephi_whatif numbers from step 7

Frequently asked questions

What does the Centrality Analysis AI skill do?

Compute and compare degree, betweenness, PageRank, eigenvector, closeness, and eccentricity in the loaded Gephi graph. Use to identify hubs, bridges, authorities, and possible structural vulnerabilities without conflating different meanings of importance.

Why use Centrality Analysis on TypingMind?

Because you install it once and use it with any model. Centrality Analysis is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Centrality Analysis in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/MattArtzAnthro/gephi-ai/tree/main/plugins/gephi-network-analysis/skills/centrality-analysis. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Centrality Analysis?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Centrality Analysis?

As many as you like. As long as a model supports skills, you can use Centrality Analysis with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Centrality Analysis AI skill free?

Yes. It is published on GitHub by MattArtzAnthro under the Apache-2.0 license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇