Something went wrong. Try again.
notification manager for bsky noti.waow.tech
Something went wrong. Try again.
12345678910111213import {mkdir, writeFile} from 'node:fs/promises'import {discoveryCandidates} from '../src/discovery'import {sampleDiscoveryGraph} from '../src/discovery-client'
const did = process.argv[2]if (!did?.startsWith('did:')) throw new Error('Usage: bun scripts/discovery-sample.ts <your-account-did>')const result = await sampleDiscoveryGraph(did)const candidates = discoveryCandidates(result.sample, Date.now())await mkdir('data', {recursive: true})await writeFile('data/discovery-sample.json', JSON.stringify({...result, candidates}, null, 2))console.log(JSON.stringify({...result.measurement, failedSeeds: result.measurement.failedSeeds.length, candidateCount: candidates.length}))console.log('Saved unverified candidates and connection evidence to data/discovery-sample.json; no recommendations published.')