Agent skill · software engineering · aradotso

x-algorithm-feed

x-algorithm-feed — an agent skill for coding agents.

Why this skill is useful

Adds a complete Rust implementation of a social media feed ranking algorithm with executable code and configuration examples.

What it needs

Requires cargo, docker, rust installed locally. About 5k tokens when loaded. Last updated 2026-07-09. 70 stars on the source repository.

What this skill does

bash git clone https://github.com/xai-org/x-algorithm.git cd x-algorithm cargo build --release bash cargo test cargo test --lib # unit tests only cargo test --integration # integration tests bash cargo run --release -- --config config/default.toml toml [server] host = "0.0.0.0" port = 8080 workers = 8 [ranking] maxcandidates = 1500 finalfeedsize = 150 diversityfactor = 0.3 recencyweight = 0.25 [scoring] modelpath = "./models/rankerv1.bin" engagementweight = 0.4 relevanceweight = 0.35 recencyweight = 0.25 [sources] socialgraphweight = 0.5 interestgraphweight = 0.3 trendingweight = 0.2 [filters] safesearch = true minqualityscore = 0.1 maxagehours = 48 bash export XALGOCONFIGPATH=/etc/x-algorithm/config.toml export XALGOMODELPATH=/models/rankerv1.bin export XALGOLOGLEVEL=info export XALGOMETRICSPORT=9090 export XALGOREDISURL=redis://localhost:6379 export XALGODBURL=postgres://user:pass@localhost/xalgo rust use xalgorithm::types::{Tweet, User, FeedRequest, FeedResponse, CandidateScore}; // Tweet candidate let tweet = Tweet { id: 1234567890, authorid: 987654321, text: "Hello world".tostring(), createdat: chrono::Utc::now(), engagement: EngagementStats { likes: 42, retweets: 10, replies: 5, views: 1000, }, ..Default::default() }; // Feed request let request = FeedRequest { userid: 111222333, cursor: None, count: 50, context: RequestContext { device: DeviceType::Mobile, language: "en".tostring(), }, }; rust use xalgorithm::{ pipeline::FeedPipeline, config::AlgorithmConfig, sources::{SocialGraphSource, InterestGraphSource, TrendingSource}, ranker::NeuralRanker, filters::{SafetyFilter, DiversityFilter}, }; #[tokio::main] async fn main() -> anyhow::Result<()> { let config = AlgorithmConfig::fromfile("config/default.toml")?; // Build the pipeline let pipeline = FeedPipeline::builder() .withsource(SocialGraphSource::new(&config)) .withsource(InterestGraphSource::new(&config)) .withsource(TrendingSource::new(&config)) .withranker(NeuralRanker::load(&config.scoring.modelpath)?) . …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills aradotso/x-algorithm-feed

View the source on GitHub

Browse the @skills marketplace