Reputation audit: AI-score your own timeline, get a shareable card
Score your posts for professional, hostile, legal, and spam risk with one LLM call each, get a 0-100 reputation grade and a downloadable score card, then clean up whatever it flags.
Every account accumulates posts nobody re-reads: the venting reply from three years ago, the joke that reads differently out of context, the thread that doxxed a coworker's title by accident. Scrolling your own history to find those is slow and you miss most of them. This scores every post the same way a careful reviewer would, then rolls the verdicts into one number.
Three surfaces, one scoring engine
(src/ai/reputationScorer.js):
| Surface | File | Best when |
|---|---|---|
| Browser console | scripts/reputationAudit.js |
You want the shareable score card, or a one-click cleanup of what got flagged |
| CLI | xactions reputation <username> (src/cli/commands/reputation.js) |
You want to script it, run it in a cron, or pipe --json somewhere |
| API / SDK | POST /api/ai/reputation/score, or import { scorePosts } from 'xactions' |
You are building on top of it |
The rubric
Every post is scored 0 (no risk) to 100 (severe) on up to four dimensions, all in one LLM call:
| Dimension | Question the model is asked |
|---|---|
| 💼 Professional | Would this embarrass the author to an employer, client, or business partner? |
| ⚔️ Hostile | Is this a personal attack on someone named or identifiable in it? |
| ⚖️ Legal exposure | Defamation, doxxing, a threat, leaked confidential info, an unkeepable promise? |
| 🗑️ Low value | Low-effort spam or filler that adds nothing and flatters no one? |
A post's overall score is the maximum across its scored dimensions, not
the average: a post that is 95 on "hostile" and 0 everywhere else is still a
95, because averaging would wash out the one thing that actually matters
about it. Verdict: flagged at 70+, review at 40-69, clean below.
The account-level reputation score blends the average risk across every scanned post (60% weight) with the single worst post (40% weight), so one severe outlier still pulls the grade down even when the rest of the timeline is spotless. Grades: A+ (97+), A (90+), B (80+), C (65+), D (45+), F (below).
You can narrow to a subset of dimensions, or add your own custom question ("does this reveal my employer or home city?") scored alongside the built-ins.
Browser console (the shareable score card)
- Open your own profile:
x.com/YOUR_USERNAME, or/with_repliesto include your replies, usually the largest source of risk on an account. - DevTools (F12), Console tab.
- Paste
scripts/reputationAudit.js. A panel appears bottom-right with all four dimensions on. - Adjust the rubric or provider if you want, then click Scan.
- Read the score. Download card or Copy image to get the PNG. Optionally check posts in the flagged list and Clean up selected.
Alt+Shift+R starts a scan from anywhere on the page.
Scanning never touches anything
The scan is entirely read-only: it reads posts and sends their text to the
LLM provider you configured. Nothing on X changes until you explicitly check
posts in the flagged list and click Clean up selected, which has its own
dry run (on by default) and reuses the same DOM-verified delete logic as
scripts/searchSweep.js, including the confirmation
dialog before a real delete run.
The score card
Downloads as a 1200x675 PNG, X's own card aspect ratio, so it drops into a
post with no cropping. It shows the gauge, the score and grade, a bar per
dimension, and the verdict counts, plus the same "generated by" footer every
XActions export uses. Copy image puts it straight on the clipboard
(where the browser supports ClipboardItem) so you can paste it directly
into a new post's composer.
Caching
Every scored post is cached in localStorage for 14 days, keyed by post id
and the exact rubric used. Re-scanning after a cleanup, or the next day, only
scores posts that are new or that you changed the rubric for.
XReputationAudit.clearCache() forces a fresh scan of everything.
CLI
xactions reputation nichxbt
xactions reputation nichxbt --replies --limit 200
xactions reputation nichxbt --dimensions hostile,legal --custom-question "Does this reveal my employer?"
XAI_API_KEY=xai-... xactions reputation nichxbt --provider xai --json
Prints the score, a bar per dimension, and the worst posts with the reason
each was flagged. --json for scripting; the CLI does not render an image,
point people at the browser script for that. --reposts also scores posts
the account reposted from others (skipped by default).
API / SDK
import { scorePosts, summarizeReport } from 'xactions';
const scores = await scorePosts(posts, {
provider: 'xai',
apiKey: process.env.XAI_API_KEY,
dimensions: ['professional', 'legal'],
});
const report = summarizeReport(posts, scores);
console.log(report.reputationScore, report.grade);
POST /api/ai/reputation/score (x402-priced, reputation:score, $0.01 per
call, up to 200 posts) takes the same shape and returns { report, scores }.
GET /api/ai/reputation/dimensions lists the rubric with no payment
required. Both are documented in /openapi.json under the Reputation tag,
so an agent using x402scan or the Bazaar extension can discover and price the
call before making it.
Any LLM provider
xAI (Grok) works straight from the browser console: x.com's
Content-Security-Policy allows api.x.ai, so provider: 'xai' with a key
from console.x.ai needs nothing else installed.
OpenAI, Anthropic, OpenRouter, and Ollama need the
browser extension bridge from the console; the CLI and SDK
have no CSP to work around and take any of them directly.
Related
scripts/searchSweep.jsdeletes by search query instead of AI-judged risk.src/bulkDeleteTweets.jsdeletes by age, keyword, or engagement.docs/browser-scripts.mdis the full script catalog.- Skills Reference — the
reputation-auditskill an AI assistant reads to use this.