a2a-memory 0.12.56 → 0.12.57
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/adapters/anthropic.js +1 -1
- package/dist/chunking/chunker.js +1 -1
- package/dist/claude/sync.js +1 -1
- package/dist/cli/commands/add.js +1 -1
- package/dist/cli/commands/claude-sync.js +1 -1
- package/dist/cli/commands/cleanup.js +1 -1
- package/dist/cli/commands/config.js +1 -1
- package/dist/cli/commands/contextrank.js +1 -1
- package/dist/cli/commands/edit.js +1 -1
- package/dist/cli/commands/embed.js +1 -1
- package/dist/cli/commands/export.js +1 -1
- package/dist/cli/commands/extract.js +1 -1
- package/dist/cli/commands/health.js +1 -1
- package/dist/cli/commands/list.js +1 -1
- package/dist/cli/commands/migrate-chunks.js +1 -1
- package/dist/cli/commands/migrate-file-refs.js +1 -1
- package/dist/cli/commands/proficiency.js +1 -1
- package/dist/cli/commands/review.js +1 -1
- package/dist/cli/commands/rm.js +1 -1
- package/dist/cli/commands/search.js +1 -1
- package/dist/cli/commands/session-extract.js +1 -1
- package/dist/cli/commands/setup-wizard.js +1 -1
- package/dist/cli/commands/setup.js +1 -1
- package/dist/cli/commands/skill.js +1 -1
- package/dist/cli/commands/status.js +1 -1
- package/dist/cli/commands/sync.js +1 -1
- package/dist/cli/commands/team.js +1 -1
- package/dist/cli/commands/usage.js +1 -1
- package/dist/cli/index.js +1 -1
- package/dist/config/manager.js +1 -1
- package/dist/contextrank/ac-matcher.js +1 -1
- package/dist/contextrank/edge-builder.d.ts +50 -0
- package/dist/contextrank/edge-builder.js +1 -1
- package/dist/contextrank/rank-builder.js +1 -1
- package/dist/contextrank/signal-builder.js +1 -1
- package/dist/contextrank/since-store.js +1 -1
- package/dist/db/database.d.ts +64 -1
- package/dist/db/database.js +1 -1
- package/dist/db/usage-spool.js +1 -1
- package/dist/embedding/e5-provider.js +1 -1
- package/dist/embedding/index.js +1 -1
- package/dist/embedding/local-provider.js +1 -1
- package/dist/embedding/openai-provider.js +1 -1
- package/dist/embedding/quantization.js +1 -1
- package/dist/extraction/dedup-manager.js +1 -1
- package/dist/extraction/emotion-filter.js +1 -1
- package/dist/extraction/extractor.js +1 -1
- package/dist/extraction/file-reference.js +1 -1
- package/dist/extraction/filter.js +1 -1
- package/dist/extraction/scorer.js +1 -1
- package/dist/extraction/similarity.js +1 -1
- package/dist/hooks/client-factory.js +1 -1
- package/dist/hooks/post-tool-use.js +1 -1
- package/dist/hooks/pre-compact.js +1 -1
- package/dist/hooks/session-end.js +1 -1
- package/dist/hooks/session-start.js +1 -1
- package/dist/hooks/shared.js +1 -1
- package/dist/hooks/stop.js +1 -1
- package/dist/hooks/user-prompt-submit.js +1 -1
- package/dist/i18n/index.js +1 -1
- package/dist/i18n/messages.js +1 -1
- package/dist/index.js +1 -1
- package/dist/lifecycle/cleanup-scheduler.js +1 -1
- package/dist/lifecycle/cleanup.js +1 -1
- package/dist/lifecycle/consolidation.js +1 -1
- package/dist/lifecycle/contradiction.js +1 -1
- package/dist/lifecycle/embedding-backfill.js +1 -1
- package/dist/lifecycle/index.js +1 -1
- package/dist/lifecycle/injection-flush.js +1 -1
- package/dist/lifecycle/quality-scorer.js +1 -1
- package/dist/lifecycle/session-extract.js +1 -1
- package/dist/lifecycle/shadow-rebuild.js +1 -1
- package/dist/lifecycle/tiering.js +1 -1
- package/dist/llm/client.js +1 -1
- package/dist/llm/index.js +1 -1
- package/dist/proficiency/actr-engine.js +1 -1
- package/dist/proficiency/detection.js +1 -1
- package/dist/proficiency/index.js +1 -1
- package/dist/proficiency/tracker.js +1 -1
- package/dist/search/adaptive-router.js +1 -1
- package/dist/search/index.js +1 -1
- package/dist/search/injection-filter.js +1 -1
- package/dist/search/memoryrank-rerank.js +1 -1
- package/dist/search/ranker.js +1 -1
- package/dist/search/reranker.js +1 -1
- package/dist/session/parser.js +1 -1
- package/dist/skill/evaluator.js +1 -1
- package/dist/skill/index.js +1 -1
- package/dist/sync/client.js +1 -1
- package/dist/sync/encryption.js +1 -1
- package/dist/sync/index.js +1 -1
- package/dist/sync/queue.js +1 -1
- package/dist/sync/scheduler.js +1 -1
- package/dist/sync/synchronizer.js +1 -1
- package/dist/sync/team-synchronizer.js +1 -1
- package/dist/sync/vector-clock.js +1 -1
- package/dist/types/index.js +1 -1
- package/dist/utils/keychain.js +1 -1
- package/dist/utils/logger.js +1 -1
- package/dist/utils/test-isolation.js +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
function _0x1293ed(_0x21a9bc,_0x304a15){return _0x5452(_0x304a15-0x1da,_0x21a9bc);}(function(_0x44657b,_0x91617b){function _0x3834cd(_0x1d659f,_0x572c33){return _0x5452(_0x1d659f-0xe3,_0x572c33);}function _0x569bf9(_0xc90e9d,_0x4b0d16){return _0x5452(_0xc90e9d-0x120,_0x4b0d16);}const _0x509990=_0x44657b();while(!![]){try{const _0x186840=parseInt(_0x3834cd(0x282,0x260))/0x1*(-parseInt(_0x3834cd(0x27a,0x287))/0x2)+-parseInt(_0x569bf9(0x2b6,0x2a8))/0x3*(parseInt(_0x569bf9(0x2a1,0x285))/0x4)+-parseInt(_0x569bf9(0x282,0x25e))/0x5*(-parseInt(_0x569bf9(0x2a3,0x29f))/0x6)+parseInt(_0x3834cd(0x287,0x27d))/0x7+parseInt(_0x569bf9(0x28a,0x26b))/0x8*(parseInt(_0x3834cd(0x243,0x224))/0x9)+-parseInt(_0x569bf9(0x2a8,0x296))/0xa*(parseInt(_0x3834cd(0x244,0x233))/0xb)+-parseInt(_0x3834cd(0x250,0x256))/0xc*(parseInt(_0x569bf9(0x293,0x2b0))/0xd);if(_0x186840===_0x91617b)break;else _0x509990['push'](_0x509990['shift']());}catch(_0x497938){_0x509990['push'](_0x509990['shift']());}}}(_0x2201,0xe14b1));import{rankNorm,parseTs}from'./signal-builder.js';function _0x5452(_0x460480,_0x485eca){_0x460480=_0x460480-0x15d;const _0x22015a=_0x2201();let _0x54526e=_0x22015a[_0x460480];if(_0x5452['ekvBYu']===undefined){var _0x1aec8c=function(_0x1007e0){const _0x5b58dd='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x19e365='',_0x70b348='';for(let _0x29c197=0x0,_0x598ebb,_0x17c526,_0x33c9ff=0x0;_0x17c526=_0x1007e0['charAt'](_0x33c9ff++);~_0x17c526&&(_0x598ebb=_0x29c197%0x4?_0x598ebb*0x40+_0x17c526:_0x17c526,_0x29c197++%0x4)?_0x19e365+=String['fromCharCode'](0xff&_0x598ebb>>(-0x2*_0x29c197&0x6)):0x0){_0x17c526=_0x5b58dd['indexOf'](_0x17c526);}for(let _0x5cdacb=0x0,_0x1a42e4=_0x19e365['length'];_0x5cdacb<_0x1a42e4;_0x5cdacb++){_0x70b348+='%'+('00'+_0x19e365['charCodeAt'](_0x5cdacb)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x70b348);};_0x5452['ngIvKU']=_0x1aec8c,_0x5452['QmlXQq']={},_0x5452['ekvBYu']=!![];}const _0x5d490c=_0x22015a[0x0],_0x2d02ab=_0x460480+_0x5d490c,_0x2b094e=_0x5452['QmlXQq'][_0x2d02ab];return!_0x2b094e?(_0x54526e=_0x5452['ngIvKU'](_0x54526e),_0x5452['QmlXQq'][_0x2d02ab]=_0x54526e):_0x54526e=_0x2b094e,_0x54526e;}export const FUSE_WEIGHTS={'sim':0.35,'cooc':0.3,'ref':0.25,'temp':0.1};export const PPR_RESTART=0.15;function _0x2201(){const _0x451faf=['DxrsB3DZ','z2v0uMfUA0LUCa','CMTbBLi','Aw9U','DZHFzhvTCa','BgvHCM5PBMC','z2vUzxjPy19Wzq','C3jJ','BwfW','z2v0','DgLLCG','mJrtuKTyBeC','y2X1C3rLCL9Pza','mtu5nZHezuTnuuW','zxjYB3jFC29SDq','zhvTCf9Zy29Yzq','BMfSDhK','y29UDMvUDgLVBG','mJbIs05ZCLK','ywjZ','CMvM','DgvTCa','Dw5PCxvLBMvZCW','reLeqvrf','CxvHBgL0Ev9ZyW','y29VyW','DZDFzhvW','Bg9N','D2vPz2H0','z2v0rwrNzxm','DMfSDwvZ','DZLFz2vUzxjPyW','mJy0mJG4tLb2CfnM','mKvsANLzyG','DZvFywn0AxzHDa','C2XPy2u','BM93','DZfFC3rYDwn0','s0vfua','qvjdseLwrq','Devfsuy','nJyWotGXvMrtuxrN','DZrFDw5PCxvLBG','y2f0zwDVCNK','zM9YrwfJAa','Bwf4','nJuYmZm3n0XZELLMqG','C2v0','ChvZAa','C2LT','ywn0AxzHDgLVBG','zxnZ','zMLSDgvY','zMLSBa','nti1mJmWmxvorLbpwa','odqWndiYreLOre1O','mty0mev3swXpDa','B3jL','BgvUz3rO','DZnFy29Vy0XVyW','Dg9ju09tDhjPBG','BM93txm','BeHcr3u','C3bSAxq','ogzVEfj0vW','AgfZ','ywnJzxnZx2nVDq','nZqYodeYDw91BLzI','CMvSAwfIAwXPDa','revmrvrfx0nbtG','zhvWx3nJB3jL','y3jLyxrLzf9HDa','zgvJAxnPB24','mJzyyMjwvg8','zhn0','r1fxCfm'];_0x2201=function(){return _0x451faf;};return _0x2201();}export const PPR_EPSILON=1e-9;export const PPR_MAX_ITERS=0x64;export const MEMORYRANK_WEIGHTS={'w1_struct':0.3,'w2_refLocal':0.11,'w3_coocLocal':0.09,'w4_uniqueness':0.16,'w5_activation':0.14,'w6_reliability':0x0,'w7_dup':0.08,'w8_dump':0.06,'w9_generic':0.06};export const COLDSTART_TAU_DAYS=0x15;export const COLDSTART_THETA=0.5;export const TIER_PRIOR={'semantic':0x1,'episodic':0.8,'working':0.6};export const HARD_PROTECT_CATEGORIES=new Set([_0x58e17b(0x238,0x258),_0x1293ed(0x352,0x361),_0x58e17b(0x24a,0x22a)+'tion',_0x58e17b(0x241,0x23e)]);export const IMPORTANCE_PRIOR={'decision':0x1,'convention':0x1,'error_solution':0x1,'learning':0x1,'code_pattern':0.7,'project_knowledge':0.7,'context':0.5,'skill':0.5};export const OBSERVATION_WINDOW_DAYS=0x15;export const PRUNE_HIGH=0.7;export const PRUNE_MID=0.5;function _0x58e17b(_0x19312f,_0x25fbff){return _0x5452(_0x19312f-0xc6,_0x25fbff);}export function ppmiNormalize(_0x26aa0b){if(_0x26aa0b[_0x248164(-0x124,-0x121)]===0x0)return[];let _0x3de358=0x0;const _0x471f85=new Map();for(const _0x4d73c5 of _0x26aa0b){_0x3de358+=_0x4d73c5[_0x248164(-0x110,-0xf3)],_0x471f85[_0x248164(-0xe2,-0xe0)](_0x4d73c5['src'],(_0x471f85[_0x248164(-0x122,-0x106)](_0x4d73c5[_0x2855b0(0x6e,0x49)])??0x0)+_0x4d73c5['weight']);}function _0x248164(_0x348db5,_0x4d6424){return _0x1293ed(_0x348db5,_0x4d6424- -0x45f);}const _0x3bc714=new Array(_0x26aa0b[_0x248164(-0x13c,-0x121)]);let _0x38ebde=0x0;for(let _0x5e3ae0=0x0;_0x5e3ae0<_0x26aa0b[_0x248164(-0x132,-0x121)];_0x5e3ae0++){const _0xe03d44=_0x26aa0b[_0x5e3ae0],_0xd8c8a9=(_0x471f85[_0x248164(-0x11d,-0x106)](_0xe03d44['src'])??0x0)*(_0x471f85[_0x2855b0(0x50,0x4b)](_0xe03d44[_0x248164(-0x11f,-0x111)])??0x0),_0xceb9f7=_0xd8c8a9>0x0?Math['log'](_0xe03d44[_0x2855b0(0x4b,0x5e)]*_0x3de358/_0xd8c8a9):0x0,_0xe30c42=Math['max'](0x0,_0xceb9f7);_0x3bc714[_0x5e3ae0]=_0xe30c42;if(_0xe30c42>_0x38ebde)_0x38ebde=_0xe30c42;}if(_0x38ebde===0x0)return[];const _0xd85e1e=[];function _0x2855b0(_0x133283,_0x3572e7){return _0x1293ed(_0x133283,_0x3572e7- -0x30e);}for(let _0x5b9107=0x0;_0x5b9107<_0x26aa0b['length'];_0x5b9107++){if(_0x248164(-0xe2,-0xe7)===_0x2855b0(0x46,0x44)){const _0x5b26a2=_0x38590f[_0x26fefd],_0x5320c8=(_0x25c792[_0x248164(-0x104,-0x106)](_0x5b26a2[_0x2855b0(0x4c,0x49)])??0x0)*(_0x3389a7['get'](_0x5b26a2[_0x2855b0(0x59,0x40)])??0x0),_0x56c749=_0x5320c8>0x0?_0x503367[_0x2855b0(0x72,0x5d)](_0x5b26a2[_0x248164(-0xe7,-0xf3)]*_0x4a9592/_0x5320c8):0x0,_0x4e07fc=_0x5531cd['max'](0x0,_0x56c749);_0x41daef[_0xd73d97]=_0x4e07fc;if(_0x4e07fc>_0x4d9feb)_0x760f58=_0x4e07fc;}else{if(_0x3bc714[_0x5b9107]>0x0)_0xd85e1e[_0x2855b0(0x6f,0x72)]({'src':_0x26aa0b[_0x5b9107][_0x248164(-0x105,-0x108)],'dst':_0x26aa0b[_0x5b9107][_0x2855b0(0x5b,0x40)],'weight':_0x3bc714[_0x5b9107]/_0x38ebde});}}return _0xd85e1e;}export function computeRanks(_0x2d84d4,_0x30f170){const _0x3225a1=_0x30f170?.[_0x1502a6(0x1f,0x2)]??0x0,_0xe2c224=_0x30f170?.[_0x1502a6(0x1f,-0x2)]??Date[_0x1502a6(0x52,0x74)](),_0x154178=_0x30f170?.['restart']??PPR_RESTART,_0x2d2619=_0x2d84d4[_0x1502a6(0x2f,0x2d)+_0x54f07f(-0x1a8,-0x184)](),_0x4e52e6=_0x2d2619['length'],_0x4359f3=new Map();_0x2d2619[_0x1502a6(0x5a,0x62)]((_0x303f24,_0x488f45)=>_0x4359f3['set'](_0x303f24['id'],_0x488f45));const _0x2e8a7d=_0x5da867=>_0x4359f3[_0x54f07f(-0x1af,-0x18f)](_0x5da867[_0x54f07f(-0x161,-0x17d)])&&_0x4359f3[_0x54f07f(-0x179,-0x18f)](_0x5da867[_0x54f07f(-0x197,-0x186)]),_0x21f851=_0x2d84d4[_0x1502a6(0x4b,0x5b)](_0x1502a6(0x5f,0x59))[_0x54f07f(-0x178,-0x19c)](_0x2e8a7d),_0x20140a=new Map();for(const _0x2de7d9 of _0x21f851){const _0x192467=_0x2de7d9[_0x1502a6(0x35,0x41)]+'\x20'+_0x2de7d9[_0x54f07f(-0x19d,-0x186)],_0x1f1202=_0x2de7d9[_0x54f07f(-0x161,-0x186)]+'\x20'+_0x2de7d9[_0x1502a6(0x35,0x47)];if((_0x20140a['get'](_0x192467)??0x0)<_0x2de7d9[_0x1502a6(0x4a,0x54)])_0x20140a[_0x54f07f(-0x13f,-0x155)](_0x192467,_0x2de7d9[_0x54f07f(-0x150,-0x168)]);if((_0x20140a[_0x1502a6(0x37,0x29)](_0x1f1202)??0x0)<_0x2de7d9[_0x54f07f(-0x182,-0x168)])_0x20140a['set'](_0x1f1202,_0x2de7d9['weight']);}const _0x2ec5e8=ppmiNormalize(_0x2d84d4['getEdges']('cooc')[_0x54f07f(-0x1ac,-0x19c)](_0x2e8a7d)),_0x29628e=_0x2d84d4[_0x1502a6(0x4b,0x5a)](_0x54f07f(-0x149,-0x16f))[_0x1502a6(0x16,0x35)](_0x2e8a7d);let _0x384343=0x0;for(const _0x2200ac of _0x29628e)if(_0x2200ac[_0x1502a6(0x4a,0x39)]>_0x384343)_0x384343=_0x2200ac[_0x54f07f(-0x16f,-0x168)];const _0x439564=_0x2d84d4[_0x1502a6(0x4b,0x56)](_0x1502a6(0x42,0x54))['filter'](_0x2e8a7d),_0x38f556=new Map(),_0x14c111=(_0x17869a,_0x3b6e48,_0x42116b)=>{if(_0x42116b<=0x0)return;function _0x540551(_0x31b488,_0x329b31){return _0x1502a6(_0x329b31-0x2b9,_0x31b488);}function _0x4afdf4(_0x355978,_0x420a54){return _0x1502a6(_0x355978- -0xf8,_0x420a54);}const _0x3f926f=_0x4359f3['get'](_0x17869a),_0xc6a52=_0x4359f3[_0x4afdf4(-0xc1,-0x9e)](_0x3b6e48);if(_0x3f926f===_0xc6a52)return;let _0x1a5dcf=_0x38f556[_0x4afdf4(-0xc1,-0xa2)](_0x3f926f);!_0x1a5dcf&&(_0x1a5dcf=new Map(),_0x38f556[_0x4afdf4(-0x9b,-0xb7)](_0x3f926f,_0x1a5dcf)),_0x1a5dcf['set'](_0xc6a52,(_0x1a5dcf[_0x4afdf4(-0xc1,-0xd6)](_0xc6a52)??0x0)+_0x42116b);};for(const [_0x19c0d1,_0x3f6f58]of _0x20140a){if(_0x1502a6(0x2d,0xc)===_0x54f07f(-0x1ad,-0x192)){const _0x520504=(0x1-_0x5deb76)*(_0x20976b[_0x679f7]+_0x2d21ab*_0x2de5f1[_0x4fc7c3])+_0x56e33e*_0x582c22[_0x243658];_0x36d914+=_0x1b2b25[_0x1502a6(0x41,0x35)](_0x520504-_0x49c54f[_0x15fb50]),_0x484684[_0x4745ab]=_0x520504;}else{const [_0x4e5028,_0x2e6975]=_0x19c0d1[_0x1502a6(0x21,0x6)]('\x20');_0x14c111(_0x4e5028,_0x2e6975,FUSE_WEIGHTS[_0x1502a6(0x5f,0x6d)]*_0x3f6f58);}}for(const _0x483438 of _0x2ec5e8)_0x14c111(_0x483438['src'],_0x483438[_0x54f07f(-0x18b,-0x186)],FUSE_WEIGHTS[_0x54f07f(-0x18f,-0x16b)]*_0x483438[_0x54f07f(-0x16a,-0x168)]);for(const _0x1069a3 of _0x439564)_0x14c111(_0x1069a3[_0x1502a6(0x35,0x28)],_0x1069a3['dst'],FUSE_WEIGHTS[_0x1502a6(0x42,0x32)]*_0x1069a3['weight']);function _0x1502a6(_0x481d7a,_0x56acc3){return _0x1293ed(_0x56acc3,_0x481d7a- -0x322);}if(_0x384343>0x0){for(const _0x381970 of _0x29628e)_0x14c111(_0x381970[_0x54f07f(-0x19f,-0x17d)],_0x381970[_0x54f07f(-0x1a1,-0x186)],FUSE_WEIGHTS[_0x54f07f(-0x15c,-0x16f)]*(_0x381970['weight']/_0x384343));}let _0x289458=0x0;const _0x187672=[],_0x3613e6=[],_0x2ee215=[],_0x495aab=new Array(_0x4e52e6)['fill'](![]);for(const [_0x319045,_0x472d28]of _0x38f556){let _0x4b16a3=0x0;for(const _0x494eca of _0x472d28[_0x54f07f(-0x182,-0x166)]())_0x4b16a3+=_0x494eca;if(_0x4b16a3<=0x0)continue;_0x495aab[_0x319045]=!![];for(const [_0x531df1,_0x4269fc]of _0x472d28){_0x187672[_0x54f07f(-0x151,-0x154)](_0x319045),_0x3613e6[_0x54f07f(-0x179,-0x154)](_0x531df1),_0x2ee215[_0x54f07f(-0x170,-0x154)](_0x4269fc/_0x4b16a3),_0x289458++;}}const _0x250966=new Array(_0x4e52e6);let _0x4854a0=0x0;for(let _0x5d4f6=0x0;_0x5d4f6<_0x4e52e6;_0x5d4f6++){const _0x502e46=_0x2d2619[_0x5d4f6]['quality_sc'+'ore']??0.5,_0x5e39ed=TIER_PRIOR[_0x2d2619[_0x5d4f6][_0x1502a6(0x38,0x20)]]??0.6,_0x2d4db6=Math[_0x54f07f(-0x172,-0x157)](_0x502e46,0.000001)*_0x5e39ed;_0x250966[_0x5d4f6]=_0x2d4db6,_0x4854a0+=_0x2d4db6;}for(let _0x52c3b9=0x0;_0x52c3b9<_0x4e52e6;_0x52c3b9++)_0x250966[_0x52c3b9]/=_0x4854a0;let _0x3bcd4d=_0x250966[_0x1502a6(0x51,0x59)](),_0x2a8d1a=0x0,_0x111722=![];for(let _0x49ac7f=0x0;_0x49ac7f<PPR_MAX_ITERS;_0x49ac7f++){_0x2a8d1a=_0x49ac7f+0x1;const _0x2f22d4=new Array(_0x4e52e6)['fill'](0x0);let _0x3ab13b=0x0;for(let _0x10d0a9=0x0;_0x10d0a9<_0x4e52e6;_0x10d0a9++)if(!_0x495aab[_0x10d0a9])_0x3ab13b+=_0x3bcd4d[_0x10d0a9];for(let _0xc7751=0x0;_0xc7751<_0x187672[_0x1502a6(0x1c,0x34)];_0xc7751++)_0x2f22d4[_0x3613e6[_0xc7751]]+=_0x2ee215[_0xc7751]*_0x3bcd4d[_0x187672[_0xc7751]];let _0x101285=0x0;for(let _0x15d62e=0x0;_0x15d62e<_0x4e52e6;_0x15d62e++){const _0x5f43bd=(0x1-_0x154178)*(_0x2f22d4[_0x15d62e]+_0x3ab13b*_0x250966[_0x15d62e])+_0x154178*_0x250966[_0x15d62e];_0x101285+=Math[_0x1502a6(0x41,0x5e)](_0x5f43bd-_0x3bcd4d[_0x15d62e]),_0x2f22d4[_0x15d62e]=_0x5f43bd;}_0x3bcd4d=_0x2f22d4;if(_0x101285<PPR_EPSILON){_0x111722=!![];break;}}const _0x87f3ca=rankNorm(_0x3bcd4d),_0x591b12=new Array(_0x4e52e6)['fill'](0x0);for(const _0x274899 of _0x439564)_0x591b12[_0x4359f3[_0x54f07f(-0x19c,-0x17b)](_0x274899[_0x1502a6(0x2c,0x1a)])]+=_0x274899[_0x1502a6(0x4a,0x52)];const _0x4742e3=rankNorm(_0x591b12),_0x3befa5=new Array(_0x4e52e6)[_0x1502a6(0x17,0x20)](0x0);for(const _0x546362 of _0x2ec5e8)_0x3befa5[_0x4359f3[_0x54f07f(-0x155,-0x17b)](_0x546362[_0x1502a6(0x35,0x18)])]+=_0x546362[_0x54f07f(-0x153,-0x168)];const _0x1a61e8=rankNorm(_0x3befa5),_0x5938e6=(_0x461e61,_0x768f7f)=>_0x461e61??_0x768f7f,_0x2f39ac=MEMORYRANK_WEIGHTS,_0x587768=new Array(_0x4e52e6);for(let _0x2c9d32=0x0;_0x2c9d32<_0x4e52e6;_0x2c9d32++){const _0x3656f6=_0x2d2619[_0x2c9d32];_0x587768[_0x2c9d32]=_0x2f39ac[_0x54f07f(-0x13d,-0x15f)]*_0x87f3ca[_0x2c9d32]+_0x2f39ac['w2_refLoca'+'l']*_0x4742e3[_0x2c9d32]+_0x2f39ac[_0x1502a6(0x1d,0x39)+'al']*_0x1a61e8[_0x2c9d32]+_0x2f39ac[_0x54f07f(-0x15e,-0x15a)+_0x54f07f(-0x1b4,-0x19d)]*_0x5938e6(_0x3656f6[_0x54f07f(-0x15a,-0x16e)],0.5)+_0x2f39ac[_0x1502a6(0x50,0x37)+_0x54f07f(-0x17a,-0x181)]*_0x5938e6(_0x3656f6[_0x54f07f(-0x134,-0x152)],0.5)+_0x2f39ac['w6_reliabi'+'lity']*_0x5938e6(_0x3656f6[_0x1502a6(0x26,0x3e)+'y'],0x1)-_0x2f39ac[_0x54f07f(-0x165,-0x16a)]*_0x5938e6(_0x3656f6[_0x1502a6(0x28,0x32)],0x0)-_0x2f39ac[_0x54f07f(-0x162,-0x180)]*_0x5938e6(_0x3656f6['dump_score'],0.5)-_0x2f39ac[_0x1502a6(0x4d,0x67)]*_0x5938e6(_0x3656f6['generic_pe'+'nalty'],0.5);}const _0x5e970a=_0x2d2619['map'](_0x44b1f7=>{const _0xe616bb=parseTs(_0x44b1f7['created_at'])??_0xe2c224;return Math['max']((_0xe2c224-_0xe616bb)/0x5265c00,0x0);}),_0x1bb452=_0x5e970a[_0x54f07f(-0x157,-0x17c)](_0x2afa74=>Math['exp'](-_0x2afa74/COLDSTART_TAU_DAYS)),_0x15f395=_0x2d2619[_0x54f07f(-0x179,-0x17c)](_0x42be3f=>{function _0x58570e(_0x3c61d3,_0x517d35){return _0x54f07f(_0x3c61d3,_0x517d35-0x487);}const _0xed4f7f=parseTs(_0x42be3f['last_acces'+'sed_at'])??parseTs(_0x42be3f[_0x58570e(0x2f0,0x2fe)])??_0xe2c224;return Math['max']((_0xe2c224-_0xed4f7f)/0x5265c00,0x0);}),_0x3190dd=rankNorm(_0x15f395);function _0x54f07f(_0x30d906,_0x2200a8){return _0x1293ed(_0x30d906,_0x2200a8- -0x4d4);}const _0x4e5dde=new Array(_0x4e52e6),_0x3bf878=new Array(_0x4e52e6);for(let _0x7cc9f4=0x0;_0x7cc9f4<_0x4e52e6;_0x7cc9f4++){const _0x423194=_0x2d2619[_0x7cc9f4],_0x28ee34=_0x423194[_0x54f07f(-0x17f,-0x16c)+_0x1502a6(0x1b,-0xa)]??0.5,_0x39ec27=IMPORTANCE_PRIOR[_0x423194[_0x54f07f(-0x167,-0x159)]]??0.5;_0x4e5dde[_0x7cc9f4]=(_0x5938e6(_0x423194[_0x54f07f(-0x193,-0x16e)],0.5)+_0x4742e3[_0x7cc9f4]+_0x5938e6(_0x423194[_0x54f07f(-0x19a,-0x18c)+'y'],0x1)*_0x28ee34+_0x5938e6(_0x423194[_0x54f07f(-0x14b,-0x152)],0.5)+_0x39ec27+_0x1bb452[_0x7cc9f4])/0x6;const _0x320601=_0x3190dd[_0x7cc9f4]*(0x1-_0x5938e6(_0x423194['activation'],0.5)),_0x5d647f=_0x423194[_0x1502a6(0x24,0x43)+'nt']===0x0&&_0x5e970a[_0x7cc9f4]>OBSERVATION_WINDOW_DAYS?0x1:0x0;_0x3bf878[_0x7cc9f4]=(_0x5938e6(_0x423194[_0x54f07f(-0x19d,-0x18a)],0x0)+_0x5938e6(_0x423194[_0x54f07f(-0x16b,-0x175)],0.5)+_0x5938e6(_0x423194[_0x1502a6(0x34,0x15)+_0x54f07f(-0x15a,-0x174)],0.5)+_0x320601+_0x5d647f)/0x5;}const _0x31589d=rankNorm(_0x587768),_0x28cf54=rankNorm(_0x2d2619[_0x1502a6(0x36,0x48)](_0x1756d4=>_0x5938e6(_0x1756d4['uniqueness'],0.5))),_0x5f0619={'KEEP':0x0,'MERGE':0x0,'ARCHIVE':0x0,'DELETE_CANDIDATE':0x0},_0x70880b=new Array(_0x4e52e6);for(let _0x221816=0x0;_0x221816<_0x4e52e6;_0x221816++){const _0x258488=_0x2d2619[_0x221816],_0x1c0146=HARD_PROTECT_CATEGORIES[_0x1502a6(0x23,0xe)](_0x258488[_0x1502a6(0x59,0x68)]),_0x7f74e2=_0x591b12[_0x221816]>0x0,_0x348663=_0x1bb452[_0x221816]>=COLDSTART_THETA,_0x419a1c=_0x31589d[_0x221816]>=0.5,_0x49ccb7=_0x28cf54[_0x221816]>=0.5,_0x3e73b9=_0x258488[_0x1502a6(0x3a,0x4a)]!==null;let _0x1d13d2;if(_0x419a1c&&_0x49ccb7)_0x1d13d2=_0x54f07f(-0x143,-0x15e);else{if(_0x419a1c&&!_0x49ccb7)_0x1d13d2=_0x3e73b9?'MERGE':'KEEP';else{if(!_0x419a1c&&_0x49ccb7)_0x1d13d2=_0x1502a6(0x54,0x31);else{if(_0x3bf878[_0x221816]>=PRUNE_HIGH&&_0x3e73b9&&!_0x7f74e2&&!_0x348663&&!_0x1c0146)_0x1d13d2=_0x1502a6(0x27,0x3f)+_0x54f07f(-0x14e,-0x16d);else{if(_0x3bf878[_0x221816]>=PRUNE_MID)_0x1d13d2='ARCHIVE';else _0x1d13d2=_0x1502a6(0x54,0x4b);}}}}if(_0x1c0146&&(_0x1d13d2==='DELETE_CAN'+_0x54f07f(-0x14a,-0x16d)||_0x1d13d2==='MERGE'))_0x1d13d2=_0x1502a6(0x55,0x2f);if((_0x7f74e2||_0x348663)&&_0x1d13d2===_0x1502a6(0x27,0x15)+'DIDATE')_0x1d13d2=_0x1502a6(0x55,0x53);if(_0x348663&&(_0x1d13d2==='MERGE'||_0x1d13d2===_0x54f07f(-0x13d,-0x15d)))_0x1d13d2=_0x54f07f(-0x141,-0x15e);_0x70880b[_0x221816]=_0x1d13d2,_0x5f0619[_0x1d13d2]++;}const _0x2e871b=new Date(_0xe2c224)[_0x1502a6(0x1e,0xd)+'g']();return _0x2d84d4['updateRank'+'s'](_0x2d2619[_0x1502a6(0x36,0x38)]((_0x535fc8,_0x17ae4a)=>({'id':_0x535fc8['id'],'struct_rank':_0x87f3ca[_0x17ae4a],'memoryrank':_0x587768[_0x17ae4a],'retention_score':_0x4e5dde[_0x17ae4a],'prune_score':_0x3bf878[_0x17ae4a],'decision':_0x70880b[_0x17ae4a]})),_0x2e871b),{'nodes':_0x4e52e6,'fusedEdges':_0x289458,'iterations':_0x2a8d1a,'converged':_0x111722,'decisions':_0x5f0619,'elapsedMs':_0x3225a1?Date[_0x54f07f(-0x185,-0x160)]()-_0x3225a1:0x0};}
|
|
1
|
+
(function(_0x1a91c7,_0xfe5c08){function _0x828a61(_0x314e3d,_0x5f9388){return _0x4424(_0x314e3d-0x20b,_0x5f9388);}function _0x58753e(_0x2000cd,_0x135f26){return _0x4424(_0x2000cd- -0xd6,_0x135f26);}const _0x4da18b=_0x1a91c7();while(!![]){try{const _0x558d51=parseInt(_0x828a61(0x33f,0x35a))/0x1+parseInt(_0x828a61(0x33c,0x314))/0x2+parseInt(_0x828a61(0x31e,0x31d))/0x3*(parseInt(_0x828a61(0x321,0x302))/0x4)+parseInt(_0x828a61(0x330,0x344))/0x5*(parseInt(_0x828a61(0x327,0x331))/0x6)+parseInt(_0x58753e(0x81,0x70))/0x7*(parseInt(_0x58753e(0x48,0x28))/0x8)+parseInt(_0x828a61(0x31c,0x335))/0x9*(parseInt(_0x828a61(0x337,0x31c))/0xa)+-parseInt(_0x828a61(0x32b,0x32f))/0xb;if(_0x558d51===_0xfe5c08)break;else _0x4da18b['push'](_0x4da18b['shift']());}catch(_0x5c2a17){_0x4da18b['push'](_0x4da18b['shift']());}}}(_0x376a,0xd8f2c));import{rankNorm,parseTs}from'./signal-builder.js';export const FUSE_WEIGHTS={'sim':0.35,'cooc':0.3,'ref':0.25,'temp':0.1};export const PPR_RESTART=0.15;export const PPR_EPSILON=1e-9;export const PPR_MAX_ITERS=0x64;function _0x376a(){const _0x40d329=['DZfFC3rYDwn0','DZrFDw5PCxvLBG','C2XPy2u','ywnJzxnZx2nVDq','y3jLyxrLzf9HDa','DZzFCMvSAwfIAq','Bwf4','s0vfua','DZHFzhvTCa','revmrvrfx0nbtG','DgvTCa','Aw9U','z2v0','zhn0','z2vUzxjPy19Wzq','BM93txm','DZvFywn0AxzHDa','zMLSBa','C3bSAxq','DZjFCMvMtg9Jyq','AKXfDfG','y29VyW','BgvUz3rO','DxrsB3DZ','y29UDMvUDgLVBG','uMfeqMm','ode2ovjKDMnfra','ChvZAa','z2v0rwrNzxm','reLeqvrf','BMfSDhK','DZDFzhvW','BgfZDf9Hy2nLCW','CxvHBgL0Ev9ZyW','zMLSDgvY','nZq5odHxvgnZwvq','Dg9ju09tDhjPBG','mJu2mZvTtgD2A3G','BgvHCM5PBMC','DZLFz2vUzxjPyW','nZzrsuPPue0','zxjYB3jFC29SDq','C2LT','CMvZDgfYDa','BgL0Eq','DxbKyxrLuMfUAW','nta2nti2EwzguxvY','ufPZvxu','mZeXmMzHBhnlBa','zeHoywy','mJCYndKXmdfxwePct2O','yNnJAwG','y2f0zwDVCNK','zxHW','BwfW','ntvwtMroEfe','C2vKx2f0','ywjZ','z2v0uMfUA0LUCa','AgfZ','Axf6v1C','zhvWx3nJB3jL','mteWse9nwMn4','qvjdseLwrq','B3jL','DMfSDwvZ','BM93','mtGZmda3mgPrDLPHvW','ywn0AxzHDgLVBG','DgLLCG','ode0mtC1B2LbDfvr','Dw5PCxvLBMvZCW','C2v0','C3jJ','tuvsr0u','CMvM','CMvSAwfIAwXPDa','zhvTCf9Zy29Yzq','D2vPz2H0'];_0x376a=function(){return _0x40d329;};return _0x376a();}export const MEMORYRANK_WEIGHTS={'w1_struct':0.3,'w2_refLocal':0.11,'w3_coocLocal':0.09,'w4_uniqueness':0.16,'w5_activation':0.14,'w6_reliability':0x0,'w7_dup':0.08,'w8_dump':0.06,'w9_generic':0.06};export const COLDSTART_TAU_DAYS=0x15;export const COLDSTART_THETA=0.5;function _0x4f40c8(_0x49f2f9,_0x5ed84d){return _0x4424(_0x49f2f9- -0x3c3,_0x5ed84d);}export const TIER_PRIOR={'semantic':0x1,'episodic':0.8,'working':0.6};export const HARD_PROTECT_CATEGORIES=new Set(['decision',_0x32aec2(-0x23a,-0x216),_0x4f40c8(-0x2ac,-0x2c3)+'tion',_0x4f40c8(-0x2af,-0x2b8)]);function _0x32aec2(_0x3f7c11,_0x492af3){return _0x4424(_0x3f7c11- -0x38f,_0x492af3);}export const IMPORTANCE_PRIOR={'decision':0x1,'convention':0x1,'error_solution':0x1,'learning':0x1,'code_pattern':0.7,'project_knowledge':0.7,'context':0.5,'skill':0.5};export const OBSERVATION_WINDOW_DAYS=0x15;export const PRUNE_HIGH=0.7;function _0x4424(_0x565ee,_0x49067e){_0x565ee=_0x565ee-0x10d;const _0x376a87=_0x376a();let _0x442496=_0x376a87[_0x565ee];if(_0x4424['PjXWHU']===undefined){var _0x248de3=function(_0x34fdc3){const _0x5a77d0='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x16c796='',_0x1e4671='';for(let _0x10c931=0x0,_0x3520fa,_0x483a95,_0x5df9eb=0x0;_0x483a95=_0x34fdc3['charAt'](_0x5df9eb++);~_0x483a95&&(_0x3520fa=_0x10c931%0x4?_0x3520fa*0x40+_0x483a95:_0x483a95,_0x10c931++%0x4)?_0x16c796+=String['fromCharCode'](0xff&_0x3520fa>>(-0x2*_0x10c931&0x6)):0x0){_0x483a95=_0x5a77d0['indexOf'](_0x483a95);}for(let _0x351d7c=0x0,_0x604445=_0x16c796['length'];_0x351d7c<_0x604445;_0x351d7c++){_0x1e4671+='%'+('00'+_0x16c796['charCodeAt'](_0x351d7c)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x1e4671);};_0x4424['cAdrRz']=_0x248de3,_0x4424['GxsIij']={},_0x4424['PjXWHU']=!![];}const _0x589347=_0x376a87[0x0],_0x340085=_0x565ee+_0x589347,_0x5ef7c3=_0x4424['GxsIij'][_0x340085];return!_0x5ef7c3?(_0x442496=_0x4424['cAdrRz'](_0x442496),_0x4424['GxsIij'][_0x340085]=_0x442496):_0x442496=_0x5ef7c3,_0x442496;}export const PRUNE_MID=0.5;export function ppmiNormalize(_0x4ec6dd){if(_0x4ec6dd[_0x12fda5(0x0,-0x1d)]===0x0)return[];let _0x1e9f79=0x0;const _0x2707cf=new Map();for(const _0x357f8c of _0x4ec6dd){_0x1e9f79+=_0x357f8c[_0x12fda5(-0x17,-0x28)],_0x2707cf['set'](_0x357f8c[_0x12fda5(-0x1c,0x4)],(_0x2707cf[_0x1bb179(-0xd2,-0xee)](_0x357f8c[_0x12fda5(-0x1c,-0x11)])??0x0)+_0x357f8c[_0x1bb179(-0xdf,-0xe4)]);}const _0x1746b4=new Array(_0x4ec6dd['length']);function _0x12fda5(_0x63e571,_0x2f73ac){return _0x4f40c8(_0x63e571-0x270,_0x2f73ac);}function _0x1bb179(_0x2561e7,_0x23b252){return _0x4f40c8(_0x2561e7-0x1a8,_0x23b252);}let _0x49ffdf=0x0;for(let _0x13c8bb=0x0;_0x13c8bb<_0x4ec6dd[_0x12fda5(0x0,0x23)];_0x13c8bb++){const _0x2fffa5=_0x4ec6dd[_0x13c8bb],_0x3e99dd=(_0x2707cf[_0x12fda5(-0xa,-0x3)](_0x2fffa5[_0x12fda5(-0x1c,-0x25)])??0x0)*(_0x2707cf[_0x12fda5(-0xa,0x9)](_0x2fffa5[_0x1bb179(-0xd1,-0xba)])??0x0),_0x3f095f=_0x3e99dd>0x0?Math['log'](_0x2fffa5[_0x12fda5(-0x17,-0x6)]*_0x1e9f79/_0x3e99dd):0x0,_0x624fd6=Math[_0x1bb179(-0xd8,-0xce)](0x0,_0x3f095f);_0x1746b4[_0x13c8bb]=_0x624fd6;if(_0x624fd6>_0x49ffdf)_0x49ffdf=_0x624fd6;}if(_0x49ffdf===0x0)return[];const _0x280659=[];for(let _0x5cd791=0x0;_0x5cd791<_0x4ec6dd[_0x1bb179(-0xc8,-0xc1)];_0x5cd791++){if(_0x1746b4[_0x5cd791]>0x0)_0x280659[_0x1bb179(-0xc3,-0xd3)]({'src':_0x4ec6dd[_0x5cd791][_0x12fda5(-0x1c,-0x2f)],'dst':_0x4ec6dd[_0x5cd791][_0x1bb179(-0xd1,-0xca)],'weight':_0x1746b4[_0x5cd791]/_0x49ffdf});}return _0x280659;}export function computeRanks(_0x1d4757,_0x595b05){const _0x129911=_0x595b05?.[_0x494b9e(-0x22f,-0x20c)]??0x0,_0x56defa=_0x595b05?.[_0x494b9e(-0x1f9,-0x20c)]??Date['now'](),_0x59bdf2=_0x595b05?.[_0x494b9e(-0x239,-0x23f)]??PPR_RESTART,_0x1f2415=_0x1d4757[_0x491769(0x26a,0x27a)+_0x491769(0x2c9,0x2a6)](),_0x22e558=_0x1f2415[_0x494b9e(-0x1f0,-0x205)],_0x34708e=new Map();_0x1f2415['forEach']((_0x125250,_0x59bf5c)=>_0x34708e[_0x491769(0x280,0x288)](_0x125250['id'],_0x59bf5c));const _0x2e7a67=_0x2a0e30=>_0x34708e[_0x491769(0x272,0x27b)](_0x2a0e30['src'])&&_0x34708e[_0x491769(0x29d,0x27b)](_0x2a0e30[_0x491769(0x277,0x29c)]),_0x474dc2=_0x1d4757['getEdges']('sim')[_0x494b9e(-0x26c,-0x248)](_0x2e7a67),_0x4ef9cd=new Map();for(const _0x277567 of _0x474dc2){const _0x382b15=_0x277567[_0x491769(0x270,0x289)]+'\x20'+_0x277567[_0x494b9e(-0x229,-0x20e)],_0x1ca7a1=_0x277567[_0x491769(0x29f,0x29c)]+'\x20'+_0x277567[_0x491769(0x2a8,0x289)];if((_0x4ef9cd[_0x491769(0x2a2,0x29b)](_0x382b15)??0x0)<_0x277567[_0x494b9e(-0x200,-0x21c)])_0x4ef9cd[_0x491769(0x2a5,0x288)](_0x382b15,_0x277567[_0x494b9e(-0x213,-0x21c)]);if((_0x4ef9cd['get'](_0x1ca7a1)??0x0)<_0x277567[_0x491769(0x2ae,0x28e)])_0x4ef9cd[_0x491769(0x283,0x288)](_0x1ca7a1,_0x277567['weight']);}const _0x4f2a7e=ppmiNormalize(_0x1d4757[_0x491769(0x2b7,0x2ab)](_0x494b9e(-0x1f0,-0x206))['filter'](_0x2e7a67)),_0x551191=_0x1d4757[_0x494b9e(-0x21f,-0x1ff)](_0x491769(0x281,0x299))[_0x491769(0x258,0x262)](_0x2e7a67);let _0x458634=0x0;for(const _0x16c83c of _0x551191)if(_0x16c83c[_0x491769(0x27d,0x28e)]>_0x458634)_0x458634=_0x16c83c[_0x491769(0x270,0x28e)];const _0x2c792d=_0x1d4757[_0x494b9e(-0x223,-0x1ff)](_0x491769(0x2aa,0x28b))[_0x494b9e(-0x26a,-0x248)](_0x2e7a67),_0x2db573=new Map(),_0x252057=(_0x194c41,_0x37ef33,_0x1502c0)=>{function _0x4d3d81(_0x565d12,_0x2b6b3c){return _0x491769(_0x2b6b3c,_0x565d12- -0xbc);}if(_0x1502c0<=0x0)return;const _0x589f60=_0x34708e['get'](_0x194c41),_0x52525a=_0x34708e[_0xe2bcde(-0x1eb,-0x1e9)](_0x37ef33);if(_0x589f60===_0x52525a)return;let _0x40f5ac=_0x2db573[_0x4d3d81(0x1df,0x1eb)](_0x589f60);function _0xe2bcde(_0x505299,_0x21ace1){return _0x491769(_0x505299,_0x21ace1- -0x484);}!_0x40f5ac&&(_0x40f5ac=new Map(),_0x2db573[_0xe2bcde(-0x221,-0x1fc)](_0x589f60,_0x40f5ac)),_0x40f5ac[_0x4d3d81(0x1cc,0x1cf)](_0x52525a,(_0x40f5ac[_0xe2bcde(-0x1cc,-0x1e9)](_0x52525a)??0x0)+_0x1502c0);};for(const [_0x1e0849,_0x9d72ea]of _0x4ef9cd){if(_0x491769(0x287,0x2a3)!==_0x491769(0x267,0x27c)){const [_0xccedba,_0x1893f5]=_0x1e0849[_0x491769(0x289,0x2a1)]('\x20');_0x252057(_0xccedba,_0x1893f5,FUSE_WEIGHTS[_0x491769(0x291,0x26a)]*_0x9d72ea);}else{const _0x3fd9f1=_0x35a1d3[_0x494b9e(-0x212,-0x221)]+'\x20'+_0x3e1419['dst'],_0x21a97f=_0x60e26a['dst']+'\x20'+_0x4a496b[_0x494b9e(-0x241,-0x221)];if((_0x2437c['get'](_0x3fd9f1)??0x0)<_0x215c3f[_0x491769(0x298,0x28e)])_0x1a45be['set'](_0x3fd9f1,_0x5ca25e['weight']);if((_0x248e18['get'](_0x21a97f)??0x0)<_0x41e878['weight'])_0x4c4c31['set'](_0x21a97f,_0x470537[_0x494b9e(-0x23e,-0x21c)]);}}for(const _0x80118d of _0x4f2a7e)_0x252057(_0x80118d[_0x494b9e(-0x210,-0x221)],_0x80118d['dst'],FUSE_WEIGHTS[_0x494b9e(-0x218,-0x206)]*_0x80118d['weight']);for(const _0x293c84 of _0x2c792d)_0x252057(_0x293c84['src'],_0x293c84['dst'],FUSE_WEIGHTS[_0x491769(0x27a,0x28b)]*_0x293c84[_0x491769(0x26f,0x28e)]);if(_0x458634>0x0){for(const _0x275530 of _0x551191)_0x252057(_0x275530[_0x494b9e(-0x246,-0x221)],_0x275530[_0x491769(0x27f,0x29c)],FUSE_WEIGHTS[_0x491769(0x27b,0x299)]*(_0x275530[_0x494b9e(-0x200,-0x21c)]/_0x458634));}let _0x3a7fc8=0x0;function _0x491769(_0x5f2c1f,_0xd11ada){return _0x4f40c8(_0xd11ada-0x515,_0x5f2c1f);}const _0xa57629=[],_0x512b2b=[],_0x588852=[],_0x4bbd65=new Array(_0x22e558)['fill'](![]);for(const [_0x178631,_0x5c485a]of _0x2db573){let _0x27f208=0x0;for(const _0xd5d9d7 of _0x5c485a[_0x494b9e(-0x21d,-0x229)]())_0x27f208+=_0xd5d9d7;if(_0x27f208<=0x0)continue;_0x4bbd65[_0x178631]=!![];for(const [_0x40086c,_0xbf150e]of _0x5c485a){if(_0x494b9e(-0x238,-0x23b)===_0x491769(0x2ca,0x2a8)){const [_0x308496,_0x33d563]=_0x998387[_0x494b9e(-0x20c,-0x209)]('\x20');_0x40d869(_0x308496,_0x33d563,_0x3f6f72[_0x494b9e(-0x25e,-0x240)]*_0x494365);}else _0xa57629[_0x491769(0x289,0x2aa)](_0x178631),_0x512b2b[_0x491769(0x2b3,0x2aa)](_0x40086c),_0x588852[_0x491769(0x2a3,0x2aa)](_0xbf150e/_0x27f208),_0x3a7fc8++;}}const _0x5b81d0=new Array(_0x22e558);let _0x51fa28=0x0;for(let _0x5cf460=0x0;_0x5cf460<_0x22e558;_0x5cf460++){const _0x6d6b19=_0x1f2415[_0x5cf460][_0x494b9e(-0x244,-0x249)+'ore']??0.5,_0x2a4f45=TIER_PRIOR[_0x1f2415[_0x5cf460][_0x491769(0x29e,0x285)]]??0.6,_0xbb3028=Math['max'](_0x6d6b19,0.000001)*_0x2a4f45;_0x5b81d0[_0x5cf460]=_0xbb3028,_0x51fa28+=_0xbb3028;}for(let _0x1c29db=0x0;_0x1c29db<_0x22e558;_0x1c29db++)_0x5b81d0[_0x1c29db]/=_0x51fa28;let _0x336091=_0x5b81d0[_0x491769(0x2b2,0x291)](),_0xf0d18c=0x0,_0x52842b=![];for(let _0x38da92=0x0;_0x38da92<PPR_MAX_ITERS;_0x38da92++){_0xf0d18c=_0x38da92+0x1;const _0x2613e2=new Array(_0x22e558)[_0x491769(0x2a1,0x2a0)](0x0);let _0x5343f5=0x0;for(let _0x283927=0x0;_0x283927<_0x22e558;_0x283927++)if(!_0x4bbd65[_0x283927])_0x5343f5+=_0x336091[_0x283927];for(let _0x1a2cbd=0x0;_0x1a2cbd<_0xa57629[_0x494b9e(-0x1e4,-0x205)];_0x1a2cbd++)_0x2613e2[_0x512b2b[_0x1a2cbd]]+=_0x588852[_0x1a2cbd]*_0x336091[_0xa57629[_0x1a2cbd]];let _0x1bcfb7=0x0;for(let _0x1bd799=0x0;_0x1bd799<_0x22e558;_0x1bd799++){const _0x802742=(0x1-_0x59bdf2)*(_0x2613e2[_0x1bd799]+_0x5343f5*_0x5b81d0[_0x1bd799])+_0x59bdf2*_0x5b81d0[_0x1bd799];_0x1bcfb7+=Math[_0x491769(0x279,0x279)](_0x802742-_0x336091[_0x1bd799]),_0x2613e2[_0x1bd799]=_0x802742;}_0x336091=_0x2613e2;if(_0x1bcfb7<PPR_EPSILON){if(_0x494b9e(-0x21d,-0x237)===_0x494b9e(-0x25b,-0x239)){for(const _0x26298c of _0x36d98a)_0x486b35(_0x26298c[_0x494b9e(-0x217,-0x221)],_0x26298c[_0x494b9e(-0x222,-0x20e)],_0x1f04ec[_0x491769(0x295,0x299)]*(_0x26298c['weight']/_0x40722c));}else{_0x52842b=!![];break;}}}const _0x18b035=rankNorm(_0x336091),_0x28eade=new Array(_0x22e558)['fill'](0x0);for(const _0x4c4f20 of _0x2c792d)_0x28eade[_0x34708e[_0x494b9e(-0x232,-0x20f)](_0x4c4f20[_0x494b9e(-0x1f3,-0x20e)])]+=_0x4c4f20[_0x494b9e(-0x1f8,-0x21c)];const _0x4ffa19=rankNorm(_0x28eade),_0x53df5a=new Array(_0x22e558)[_0x494b9e(-0x1ec,-0x20a)](0x0);function _0x494b9e(_0x201755,_0x20c7c5){return _0x4f40c8(_0x20c7c5-0x6b,_0x201755);}for(const _0x4284cc of _0x4f2a7e)_0x53df5a[_0x34708e[_0x494b9e(-0x1e8,-0x20f)](_0x4284cc['src'])]+=_0x4284cc['weight'];const _0x3f2b92=rankNorm(_0x53df5a),_0x31d853=(_0x39f432,_0x35488f)=>_0x39f432??_0x35488f,_0x2f5118=MEMORYRANK_WEIGHTS,_0xfcd7f7=new Array(_0x22e558);for(let _0x44ee52=0x0;_0x44ee52<_0x22e558;_0x44ee52++){const _0x4744b1=_0x1f2415[_0x44ee52];_0xfcd7f7[_0x44ee52]=_0x2f5118[_0x491769(0x2b4,0x28f)]*_0x18b035[_0x44ee52]+_0x2f5118[_0x491769(0x2ae,0x2a2)+'l']*_0x4ffa19[_0x44ee52]+_0x2f5118['w3_coocLoc'+'al']*_0x3f2b92[_0x44ee52]+_0x2f5118[_0x494b9e(-0x230,-0x21a)+'ess']*_0x31d853(_0x4744b1['uniqueness'],0.5)+_0x2f5118[_0x494b9e(-0x1ed,-0x20b)+_0x494b9e(-0x21b,-0x210)]*_0x31d853(_0x4744b1['activation'],0.5)+_0x2f5118[_0x491769(0x2b6,0x294)+_0x494b9e(-0x257,-0x23e)]*_0x31d853(_0x4744b1[_0x491769(0x282,0x28c)+'y'],0x1)-_0x2f5118[_0x494b9e(-0x26d,-0x24b)]*_0x31d853(_0x4744b1[_0x494b9e(-0x20b,-0x22d)],0x0)-_0x2f5118[_0x494b9e(-0x23b,-0x213)]*_0x31d853(_0x4744b1['dump_score'],0.5)-_0x2f5118[_0x494b9e(-0x22e,-0x243)]*_0x31d853(_0x4744b1[_0x494b9e(-0x21f,-0x20d)+_0x491769(0x28b,0x2ad)],0.5);}const _0x5aa585=_0x1f2415[_0x491769(0x291,0x276)](_0x4640e5=>{function _0x516309(_0x357002,_0x340ce2){return _0x491769(_0x357002,_0x340ce2- -0xd);}const _0x3377ec=parseTs(_0x4640e5[_0x444826(-0x1b8,-0x1ba)])??_0x56defa;function _0x444826(_0x21fd52,_0x118aaf){return _0x491769(_0x118aaf,_0x21fd52- -0x44b);}return Math[_0x516309(0x277,0x288)]((_0x56defa-_0x3377ec)/0x5265c00,0x0);}),_0x1903bd=_0x5aa585[_0x494b9e(-0x213,-0x234)](_0x525545=>Math[_0x491769(0x25e,0x275)](-_0x525545/COLDSTART_TAU_DAYS)),_0x2e95ee=_0x1f2415[_0x494b9e(-0x253,-0x234)](_0x54329e=>{function _0x181802(_0x4e21b2,_0x29f333){return _0x491769(_0x29f333,_0x4e21b2-0x10e);}const _0x43c989=parseTs(_0x54329e[_0x40fc74(-0x156,-0x16b)+_0x181802(0x386,0x3ae)])??parseTs(_0x54329e['created_at'])??_0x56defa;function _0x40fc74(_0x2fcf45,_0x37a540){return _0x491769(_0x37a540,_0x2fcf45- -0x3b6);}return Math[_0x40fc74(-0x121,-0x134)]((_0x56defa-_0x43c989)/0x5265c00,0x0);}),_0x37b1bf=rankNorm(_0x2e95ee),_0x3fd53d=new Array(_0x22e558),_0x2ee1a7=new Array(_0x22e558);for(let _0x4825b5=0x0;_0x4825b5<_0x22e558;_0x4825b5++){const _0x11a83f=_0x1f2415[_0x4825b5],_0x314293=_0x11a83f[_0x494b9e(-0x259,-0x249)+_0x491769(0x2a2,0x280)]??0.5,_0x13c287=IMPORTANCE_PRIOR[_0x11a83f['category']]??0.5;_0x3fd53d[_0x4825b5]=(_0x31d853(_0x11a83f[_0x491769(0x2a7,0x287)],0.5)+_0x4ffa19[_0x4825b5]+_0x31d853(_0x11a83f[_0x494b9e(-0x229,-0x21e)+'y'],0x1)*_0x314293+_0x31d853(_0x11a83f[_0x494b9e(-0x22d,-0x226)],0.5)+_0x13c287+_0x1903bd[_0x4825b5])/0x6;const _0x191ede=_0x37b1bf[_0x4825b5]*(0x1-_0x31d853(_0x11a83f['activation'],0.5)),_0x112ee9=_0x11a83f[_0x491769(0x29a,0x292)+'nt']===0x0&&_0x5aa585[_0x4825b5]>OBSERVATION_WINDOW_DAYS?0x1:0x0;_0x2ee1a7[_0x4825b5]=(_0x31d853(_0x11a83f[_0x491769(0x25b,0x27d)],0x0)+_0x31d853(_0x11a83f[_0x491769(0x26a,0x28d)],0.5)+_0x31d853(_0x11a83f[_0x491769(0x2a4,0x29d)+_0x494b9e(-0x1ef,-0x1fd)],0.5)+_0x191ede+_0x112ee9)/0x5;}const _0x5bbf57=rankNorm(_0xfcd7f7),_0xb405c=rankNorm(_0x1f2415[_0x494b9e(-0x258,-0x234)](_0x50b371=>_0x31d853(_0x50b371[_0x491769(0x293,0x287)],0.5))),_0x4acd22={'KEEP':0x0,'MERGE':0x0,'ARCHIVE':0x0,'DELETE_CANDIDATE':0x0},_0x4dbadf=new Array(_0x22e558);for(let _0x4afaee=0x0;_0x4afaee<_0x22e558;_0x4afaee++){if('PdIWV'==='eMJnI')_0x10112b+=_0x11c39c[_0x494b9e(-0x243,-0x21c)],_0x2fa239[_0x491769(0x269,0x288)](_0x34ecae['src'],(_0x17031[_0x491769(0x2ab,0x29b)](_0x3fdb4a['src'])??0x0)+_0x17d371[_0x494b9e(-0x213,-0x21c)]);else{const _0x12e52a=_0x1f2415[_0x4afaee],_0x13414d=HARD_PROTECT_CATEGORIES[_0x494b9e(-0x216,-0x22f)](_0x12e52a[_0x494b9e(-0x211,-0x236)]),_0x461490=_0x28eade[_0x4afaee]>0x0,_0x85e4c2=_0x1903bd[_0x4afaee]>=COLDSTART_THETA,_0x1ab473=_0x5bbf57[_0x4afaee]>=0.5,_0xf4b93e=_0xb405c[_0x4afaee]>=0.5,_0x3065ac=_0x12e52a['cluster_id']!==null;let _0x4eed0f;if(_0x1ab473&&_0xf4b93e)_0x4eed0f='KEEP';else{if(_0x1ab473&&!_0xf4b93e)_0x4eed0f=_0x3065ac?_0x491769(0x29f,0x28a):_0x491769(0x2a6,0x296);else{if(!_0x1ab473&&_0xf4b93e)_0x4eed0f='KEEP';else{if(_0x2ee1a7[_0x4afaee]>=PRUNE_HIGH&&_0x3065ac&&!_0x461490&&!_0x85e4c2&&!_0x13414d)_0x4eed0f=_0x494b9e(-0x21a,-0x212)+_0x494b9e(-0x217,-0x1fe);else{if(_0x2ee1a7[_0x4afaee]>=PRUNE_MID)_0x4eed0f=_0x494b9e(-0x225,-0x22b);else _0x4eed0f='KEEP';}}}}if(_0x13414d&&(_0x4eed0f===_0x494b9e(-0x1fe,-0x212)+_0x491769(0x2ae,0x2ac)||_0x4eed0f===_0x491769(0x2a1,0x28a)))_0x4eed0f=_0x491769(0x287,0x27f);if((_0x461490||_0x85e4c2)&&_0x4eed0f==='DELETE_CAN'+_0x491769(0x298,0x2ac))_0x4eed0f=_0x491769(0x261,0x27f);if(_0x85e4c2&&(_0x4eed0f==='MERGE'||_0x4eed0f===_0x491769(0x292,0x27f)))_0x4eed0f=_0x491769(0x2be,0x296);_0x4dbadf[_0x4afaee]=_0x4eed0f,_0x4acd22[_0x4eed0f]++;}}const _0x4e5538=new Date(_0x56defa)[_0x491769(0x26a,0x264)+'g']();return _0x1d4757[_0x491769(0x28d,0x26d)+'s'](_0x1f2415[_0x494b9e(-0x258,-0x234)]((_0x599155,_0x2a2afb)=>({'id':_0x599155['id'],'struct_rank':_0x18b035[_0x2a2afb],'memoryrank':_0xfcd7f7[_0x2a2afb],'retention_score':_0x3fd53d[_0x2a2afb],'prune_score':_0x2ee1a7[_0x2a2afb],'decision':_0x4dbadf[_0x2a2afb]})),_0x4e5538),{'nodes':_0x22e558,'fusedEdges':_0x3a7fc8,'iterations':_0xf0d18c,'converged':_0x52842b,'decisions':_0x4acd22,'elapsedMs':_0x129911?Date[_0x491769(0x2a7,0x282)]()-_0x129911:0x0};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function _0x5907fd(_0x5363d4,_0x1758d1){return _0x4164(_0x1758d1-0x207,_0x5363d4);}(function(_0xe619c1,_0x573290){const _0x582504=_0xe619c1();function _0x3185e2(_0x3f764b,_0x53f938){return _0x4164(_0x3f764b- -0x399,_0x53f938);}function _0x5aece3(_0x107efb,_0x7eb7e1){return _0x4164(_0x7eb7e1-0xe2,_0x107efb);}while(!![]){try{const _0x566e24=parseInt(_0x5aece3(0x268,0x263))/0x1*(-parseInt(_0x5aece3(0x275,0x266))/0x2)+parseInt(_0x5aece3(0x285,0x27e))/0x3+parseInt(_0x3185e2(-0x224,-0x238))/0x4+-parseInt(_0x5aece3(0x24c,0x256))/0x5+-parseInt(_0x5aece3(0x267,0x278))/0x6*(parseInt(_0x5aece3(0x251,0x25a))/0x7)+parseInt(_0x5aece3(0x252,0x258))/0x8*(-parseInt(_0x3185e2(-0x214,-0x216))/0x9)+parseInt(_0x5aece3(0x26e,0x26e))/0xa;if(_0x566e24===_0x573290)break;else _0x582504['push'](_0x582504['shift']());}catch(_0x416382){_0x582504['push'](_0x582504['shift']());}}}(_0x4556,0xc464e));export const ACTR_DECAY=0.5;export const DUP_TAU=0.98;export function parseTs(_0x5a42fc){if(!_0x5a42fc)return null;const _0x1399bf=_0x5a42fc['includes']('T')?_0x5a42fc:_0x5a42fc[_0x278954(0x398,0x398)]('\x20','T')+'Z';function _0x2c8d48(_0x31f6c6,_0x3e36aa){return _0x4164(_0x3e36aa-0x2e,_0x31f6c6);}const _0x175bdd=Date[_0x2c8d48(0x1d4,0x1c0)](_0x1399bf);function _0x278954(_0x25a3bc,_0x3f34d8){return _0x4164(_0x25a3bc-0x201,_0x3f34d8);}return Number[_0x2c8d48(0x1a4,0x1b5)](_0x175bdd)?null:_0x175bdd;}function _0x4164(_0xb608f7,_0x3f8736){_0xb608f7=_0xb608f7-0x173;const _0x455647=_0x4556();let _0x41642f=_0x455647[_0xb608f7];if(_0x4164['PZAdKE']===undefined){var _0x16d7aa=function(_0x2e1650){const _0x529902='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x21258a='',_0x5afd17='';for(let _0x278720=0x0,_0x44e655,_0x186c24,_0x1ed8cf=0x0;_0x186c24=_0x2e1650['charAt'](_0x1ed8cf++);~_0x186c24&&(_0x44e655=_0x278720%0x4?_0x44e655*0x40+_0x186c24:_0x186c24,_0x278720++%0x4)?_0x21258a+=String['fromCharCode'](0xff&_0x44e655>>(-0x2*_0x278720&0x6)):0x0){_0x186c24=_0x529902['indexOf'](_0x186c24);}for(let _0x2f93d8=0x0,_0x3668ef=_0x21258a['length'];_0x2f93d8<_0x3668ef;_0x2f93d8++){_0x5afd17+='%'+('00'+_0x21258a['charCodeAt'](_0x2f93d8)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x5afd17);};_0x4164['Dwjyce']=_0x16d7aa,_0x4164['PzrhsC']={},_0x4164['PZAdKE']=!![];}const _0x255bc3=_0x455647[0x0],_0x3ae8ea=_0xb608f7+_0x255bc3,_0x567b5c=_0x4164['PzrhsC'][_0x3ae8ea];return!_0x567b5c?(_0x41642f=_0x4164['Dwjyce'](_0x41642f),_0x4164['PzrhsC'][_0x3ae8ea]=_0x41642f):_0x41642f=_0x567b5c,_0x41642f;}function _0x2f6f52(_0x315d9e,_0x49a065){return _0x4164(_0x49a065- -0x2aa,_0x315d9e);}export function rankNorm(_0x4a405e){const _0xfbfeea=_0x4a405e[_0x20afa4(-0xc2,-0xd7)];function _0x20afa4(_0x189257,_0x4cccb5){return _0x4164(_0x189257- -0x239,_0x4cccb5);}if(_0xfbfeea===0x0)return[];if(_0xfbfeea===0x1)return[0.5];const _0x95b1fd=_0x4a405e[_0x20afa4(-0xa0,-0xb4)]((_0x158156,_0x4357c2)=>({'v':_0x158156,'i':_0x4357c2}))['sort']((_0xb7a994,_0x55c6a3)=>_0xb7a994['v']-_0x55c6a3['v']),_0x17316e=new Array(_0xfbfeea);let _0x34ba91=0x0;function _0x23b5ad(_0x2908f3,_0x219354){return _0x4164(_0x219354- -0x99,_0x2908f3);}while(_0x34ba91<_0xfbfeea){let _0x195f67=_0x34ba91;while(_0x195f67+0x1<_0xfbfeea&&_0x95b1fd[_0x195f67+0x1]['v']===_0x95b1fd[_0x34ba91]['v'])_0x195f67++;const _0x33a197=(_0x34ba91+_0x195f67)/0x2,_0x2c7740=_0x33a197/(_0xfbfeea-0x1);for(let _0x1fe85b=_0x34ba91;_0x1fe85b<=_0x195f67;_0x1fe85b++)_0x17316e[_0x95b1fd[_0x1fe85b]['i']]=_0x2c7740;_0x34ba91=_0x195f67+0x1;}return _0x17316e;}function _0x4556(){const _0x1d2588=['D2vPz2H0','mJr2BuDIEhq','CMvWBgfJzq','y3jLyxrLzf9HDa','BwfW','AgfZ','Dw5PB24','mZaXode1m2XSB2nhuG','C3jJ','ywXZ','mZiWnZmWme9Xt29ysG','mJKZnJm1mK1MtePAua','mtaXnda4u0vpvMTn','BgvUz3rO','mtC1nJC5n3LouwTbBW','ChvZAa','zMLUza','BM93','Bwf4','Dg9ju09tDhjPBG','zfD3zKW','B3jL','zgvJyxK','mtiWmdG4ou9dELbfyG','BM93txm','DMfSDwvZ','mKz3wvLbta','mJDcyuPNwKq','z2v0','Axnoyu4','zhn0','Bg9N','BNb1DfjVD3m','BMD0Aa','mtK0odu1mJb3tLjVD0W','C2v0','zMLSDgvY','z2v0rwrNzxm','y29UDgvUDf9Szq','CMvKDwnL','CgfYC2u','CgfYzw50','zhvWvgf1'];_0x4556=function(){return _0x1d2588;};return _0x4556();}class UnionFind{[_0x2f6f52(-0x109,-0x117)]=new Map();['find'](_0x10b06b){const _0x43db20=this[_0xcc9858(0x477,0x466)][_0x5cd5c7(0x5f,0x68)](_0x10b06b);function _0xcc9858(_0x22889d,_0x5c4882){return _0x2f6f52(_0x5c4882,_0x22889d-0x58e);}if(_0x43db20===undefined||_0x43db20===_0x10b06b)return this['parent'][_0x5cd5c7(0x74,0x6f)](_0x10b06b,_0x10b06b),_0x10b06b;const _0x249354=this[_0x5cd5c7(0x6c,0x5c)](_0x43db20);this['parent'][_0xcc9858(0x471,0x47d)](_0x10b06b,_0x249354);function _0x5cd5c7(_0x278ddf,_0x2c7974){return _0x2f6f52(_0x278ddf,_0x2c7974-0x18c);}return _0x249354;}[_0x5907fd(0x39c,0x3a2)](_0x3ee6ca,_0x240528){function _0x5eb5f3(_0x1fdec9,_0x5d980d){return _0x2f6f52(_0x1fdec9,_0x5d980d-0x55f);}const _0x1f59e0=this['find'](_0x3ee6ca);function _0x57d41a(_0x6dfe32,_0x467dd5){return _0x2f6f52(_0x467dd5,_0x6dfe32-0x598);}const _0x3a9525=this[_0x5eb5f3(0x41a,0x42f)](_0x240528);if(_0x1f59e0!==_0x3a9525)this[_0x57d41a(0x481,0x470)][_0x57d41a(0x47b,0x474)](_0x1f59e0,_0x3a9525);}}export function computeSignals(_0x4c431d,_0x458761){const _0xa90081=_0x458761?.[_0x5d3f16(-0x14c,-0x139)]??0x0,_0x38384c=_0x458761?.[_0x5d3f16(-0x14c,-0x158)]??Date[_0x129121(0xbd,0xbf)]();function _0x129121(_0x87fb9f,_0x48d229){return _0x5907fd(_0x48d229,_0x87fb9f- -0x2c5);}const _0xed4de4=_0x458761?.[_0x5d3f16(-0x14e,-0x14b)]??ACTR_DECAY,_0x52f31d=_0x458761?.[_0x5d3f16(-0x13a,-0x137)]??DUP_TAU,_0x5b8247=_0x4c431d['getSignalI'+_0x129121(0xcc,0xd7)](),_0x12b2f5=_0x5b8247['length'],_0x35e4b4=_0x5b8247['map'](_0x207184=>_0x207184['id']),_0x2e38aa=new Set(_0x35e4b4);let _0x471672=0x0;const _0x29550c=_0x5b8247[_0x5d3f16(-0x135,-0x14b)](_0x431132=>{const _0x3831c1=parseTs(_0x431132[_0x33cd94(-0x75,-0x71)])??_0x38384c;function _0x33cd94(_0x43ea5d,_0x51ef6e){return _0x129121(_0x43ea5d- -0x14f,_0x51ef6e);}const _0x120f4a=Math[_0x33cd94(-0x91,-0xa1)]((_0x38384c-_0x3831c1)/0x5265c00,0x1/0x18);function _0x1662cc(_0x51f106,_0x73c352){return _0x129121(_0x51f106-0x39d,_0x73c352);}const _0x5f5944=Math[_0x1662cc(0x45b,0x448)](_0x431132['access_cou'+'nt'],0x0);if(_0x5f5944>0x0)_0x471672++;return Math[_0x1662cc(0x468,0x458)]((_0x5f5944+0x1)/(0x1-_0xed4de4))-_0xed4de4*Math[_0x33cd94(-0x84,-0x88)](_0x120f4a);}),_0x5aee7d=rankNorm(_0x29550c),_0x57670f=_0x4c431d[_0x5d3f16(-0x13f,-0x131)]('sim'),_0x4facc2=new Map(),_0x47d0e0=new Map(),_0x283eef=new UnionFind();for(const _0x4f80c9 of _0x57670f){if(!_0x2e38aa[_0x5d3f16(-0x134,-0x12d)](_0x4f80c9[_0x129121(0xdf,0xe1)])||!_0x2e38aa[_0x5d3f16(-0x134,-0x124)](_0x4f80c9[_0x129121(0xca,0xd4)]))continue;let _0x20c938=_0x4facc2['get'](_0x4f80c9['src']);!_0x20c938&&(_0x20c938=[],_0x4facc2[_0x129121(0xcf,0xc2)](_0x4f80c9[_0x129121(0xdf,0xef)],_0x20c938));_0x20c938[_0x129121(0xbb,0xd0)](_0x4f80c9[_0x129121(0xd7,0xec)]),_0x47d0e0[_0x5d3f16(-0x141,-0x143)](_0x4f80c9[_0x129121(0xca,0xdb)],(_0x47d0e0['get'](_0x4f80c9[_0x5d3f16(-0x146,-0x153)])??0x0)+0x1);if(_0x4f80c9['weight']>=_0x52f31d)_0x283eef[_0x129121(0xdd,0xdd)](_0x4f80c9['src'],_0x4f80c9[_0x129121(0xca,0xd1)]);}const _0x38f396=_0x35e4b4[_0x5d3f16(-0x135,-0x13d)](_0x3b3816=>{const _0x257271=_0x4facc2[_0x2be526(0x56b,0x568)](_0x3b3816);function _0x2be526(_0x604c52,_0x3d3c5e){return _0x5d3f16(_0x3d3c5e-0x6b0,_0x604c52);}if(!_0x257271||_0x257271[_0x2be526(0x567,0x559)]===0x0)return 0x1;const _0x3e47f1=_0x257271[_0x2be526(0x575,0x573)]((_0x1a46a6,_0xb1a294)=>_0x1a46a6+_0xb1a294,0x0)/_0x257271['length'];function _0x3158f6(_0x1e4939,_0x2f3762){return _0x5d3f16(_0x1e4939-0x17d,_0x2f3762);}return 0x1-_0x3e47f1;}),_0x3ae460=_0x35e4b4[_0x129121(0xdb,0xd2)](_0x29c412=>_0x47d0e0[_0x5d3f16(-0x148,-0x157)](_0x29c412)??0x0),_0x2deed7=rankNorm(_0x3ae460),_0x2fd759=new Map(),_0x33d8f7=new Map();for(const _0x461c64 of _0x35e4b4){const _0x54df65=_0x283eef[_0x129121(0xbc,0xbe)](_0x461c64);_0x2fd759['set'](_0x461c64,_0x54df65),_0x33d8f7[_0x129121(0xcf,0xdf)](_0x54df65,(_0x33d8f7[_0x129121(0xc8,0xc5)](_0x54df65)??0x0)+0x1);}const _0x3794f1=_0x35e4b4[_0x129121(0xdb,0xc9)](_0x358995=>(_0x33d8f7[_0x129121(0xc8,0xbe)](_0x2fd759[_0x5d3f16(-0x148,-0x14c)](_0x358995))??0x1)-0x1),_0x3280a4=rankNorm(_0x3794f1),_0x203bb1=_0x35e4b4[_0x129121(0xdb,0xef)](_0x1aac62=>{function _0x3456ec(_0x2ed4cc,_0x1e1bcf){return _0x129121(_0x1e1bcf-0x463,_0x2ed4cc);}function _0xb2d835(_0x3e7960,_0x5e75cd){return _0x129121(_0x3e7960-0x1b,_0x5e75cd);}if(_0xb2d835(0xdb,0xc7)===_0x3456ec(0x519,0x523)){const _0x26871d=_0x2fd759[_0x3456ec(0x529,0x52b)](_0x1aac62);return(_0x33d8f7['get'](_0x26871d)??0x1)>=0x2?_0x26871d:null;}else{const _0x5aa934=_0x236190[_0xb2d835(0xe3,0xf4)](_0x24ff2b);return(_0x4e2f88[_0x3456ec(0x53c,0x52b)](_0x5aa934)??0x1)>=0x2?_0x5aa934:null;}}),_0xf88345=rankNorm(_0x5b8247[_0x129121(0xdb,0xf0)](_0x5c44d4=>_0x5c44d4[_0x129121(0xd2,0xc9)+_0x5d3f16(-0x143,-0x12f)])),_0x3931cd=_0x35e4b4[_0x129121(0xdb,0xe4)]((_0x233291,_0x4d729a)=>{const _0x26eab7=_0xf88345[_0x4d729a],_0x46d37c=_0x5b8247[_0x4d729a]['quality_sc'+_0x230dbf(-0x73,-0x81)]??0.5;function _0x230dbf(_0x570211,_0x5bf8bf){return _0x5d3f16(_0x5bf8bf-0xce,_0x570211);}const _0x307335=(_0x46d37c+_0x38f396[_0x4d729a])/0x2;return 0.5*(0x1-_0x26eab7)+0.5*(0x1-_0x307335);});function _0x5d3f16(_0x52726d,_0x45ec25){return _0x5907fd(_0x45ec25,_0x52726d- -0x4d5);}const _0xe9f081=rankNorm(_0x3931cd),_0x41c9ce=[..._0x33d8f7[_0x129121(0xc5,0xb3)]()][_0x129121(0xd0,0xdb)](_0x3176f2=>_0x3176f2>=0x2)[_0x5d3f16(-0x157,-0x144)],_0x17aebf=new Date(_0x38384c)[_0x129121(0xbf,0xbc)+'g'](),_0x5721f0=_0x35e4b4['map']((_0x12b8e6,_0x361d1c)=>({'id':_0x12b8e6,'activation':_0x5aee7d[_0x361d1c],'uniqueness':_0x38f396[_0x361d1c],'generic_penalty':_0x2deed7[_0x361d1c],'dup_score':_0x3280a4[_0x361d1c],'dump_score':_0xe9f081[_0x361d1c],'reliability':0x1,'cluster_id':_0x203bb1[_0x361d1c]}));return _0x4c431d['updateSign'+_0x5d3f16(-0x15b,-0x148)](_0x5721f0,_0x17aebf),{'nodes':_0x12b2f5,'dupClusters':_0x41c9ce,'activationValid':_0x471672,'elapsedMs':_0xa90081?Date['now']()-_0xa90081:0x0};}
|
|
1
|
+
function _0x4082(_0x2bd115,_0x4d0660){_0x2bd115=_0x2bd115-0x13b;const _0x3ce996=_0x3ce9();let _0x408223=_0x3ce996[_0x2bd115];if(_0x4082['qlKNnD']===undefined){var _0x25aa87=function(_0x296e65){const _0x3e205a='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x3699be='',_0x110308='';for(let _0xa1e8d7=0x0,_0x10584a,_0x43635c,_0x3bd444=0x0;_0x43635c=_0x296e65['charAt'](_0x3bd444++);~_0x43635c&&(_0x10584a=_0xa1e8d7%0x4?_0x10584a*0x40+_0x43635c:_0x43635c,_0xa1e8d7++%0x4)?_0x3699be+=String['fromCharCode'](0xff&_0x10584a>>(-0x2*_0xa1e8d7&0x6)):0x0){_0x43635c=_0x3e205a['indexOf'](_0x43635c);}for(let _0x4b3429=0x0,_0x1d7e9a=_0x3699be['length'];_0x4b3429<_0x1d7e9a;_0x4b3429++){_0x110308+='%'+('00'+_0x3699be['charCodeAt'](_0x4b3429)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x110308);};_0x4082['jTmpxg']=_0x25aa87,_0x4082['LtxvYE']={},_0x4082['qlKNnD']=!![];}const _0x449e30=_0x3ce996[0x0],_0x16f01f=_0x2bd115+_0x449e30,_0x582577=_0x4082['LtxvYE'][_0x16f01f];return!_0x582577?(_0x408223=_0x4082['jTmpxg'](_0x408223),_0x4082['LtxvYE'][_0x16f01f]=_0x408223):_0x408223=_0x582577,_0x408223;}(function(_0xbdddbe,_0x2792ba){const _0x4741fd=_0xbdddbe();function _0x3947f0(_0x4b77af,_0x1f042a){return _0x4082(_0x1f042a- -0xfb,_0x4b77af);}function _0xae2d03(_0x593222,_0x27b4e5){return _0x4082(_0x593222- -0x62,_0x27b4e5);}while(!![]){try{const _0x4484e8=parseInt(_0x3947f0(0x46,0x47))/0x1*(-parseInt(_0xae2d03(0xfa,0x104))/0x2)+parseInt(_0x3947f0(0x40,0x41))/0x3+parseInt(_0x3947f0(0x5b,0x62))/0x4*(-parseInt(_0x3947f0(0x6b,0x64))/0x5)+-parseInt(_0x3947f0(0x51,0x4d))/0x6+-parseInt(_0x3947f0(0x56,0x59))/0x7+-parseInt(_0x3947f0(0x5c,0x5c))/0x8+parseInt(_0x3947f0(0x70,0x5b))/0x9*(parseInt(_0x3947f0(0x6c,0x5e))/0xa);if(_0x4484e8===_0x2792ba)break;else _0x4741fd['push'](_0x4741fd['shift']());}catch(_0x332f36){_0x4741fd['push'](_0x4741fd['shift']());}}}(_0x3ce9,0xcb4b3));function _0x2ff61e(_0xa565c1,_0x38fc6b){return _0x4082(_0xa565c1-0x63,_0x38fc6b);}export const ACTR_DECAY=0.5;function _0x3ea8b4(_0x5e5efe,_0x24523b){return _0x4082(_0x24523b-0x2f4,_0x5e5efe);}export const DUP_TAU=0.98;function _0x3ce9(){const _0x144e8e=['y3jLyxrLzf9HDa','zhvWvgf1','z2v0','z2v0u2LNBMfSsq','zMLUza','Dg9ju09tDhjPBG','mteWmtG3ndLAt0vQuLG','zhn0','nte1nZuZmwn4vMzwyq','odK2mZjQsMXYtM0','B3jL','nZbwturSuhq','y29UDgvUDf9Szq','ywnJzxnZx2nVDq','mJrnBeroALi','nJqXoda4rhj1CMXM','DxbKyxrLu2LNBG','mtvUzLLgCxu','Bwf4','ywXZ','BM93','D2vPz2H0','Axnoyu4','Bg9N','BNb1DfjVD3m','mZKZmJeXmNLcy0LkvG','C2LT','C3jJ','BgvUz3rO','zMLSDgvY','z2v0rwrNzxm','ota4mJjfCLbXEuO','CgfYzw50','AgfZ','BM93txm','BwfW','CgfYC2u','nZK5nZm3mfLmD3vXDW','C2v0','CMvKDwnL','DMfSDwvZ','Dw5PB24','CxvHBgL0Ev9ZyW'];_0x3ce9=function(){return _0x144e8e;};return _0x3ce9();}export function parseTs(_0x5a51f1){function _0x147bb7(_0x3bf8e7,_0x140630){return _0x4082(_0x3bf8e7- -0x2bd,_0x140630);}if(!_0x5a51f1)return null;function _0xcdaac2(_0x47ceec,_0x528a6a){return _0x4082(_0x47ceec- -0x131,_0x528a6a);}const _0x4eb825=_0x5a51f1['includes']('T')?_0x5a51f1:_0x5a51f1['replace']('\x20','T')+'Z',_0x5045bf=Date[_0x147bb7(-0x176,-0x16e)](_0x4eb825);return Number[_0xcdaac2(0x33,0x45)](_0x5045bf)?null:_0x5045bf;}export function rankNorm(_0x47be24){function _0x38be51(_0x584727,_0x3d7e83){return _0x4082(_0x3d7e83-0x2c6,_0x584727);}const _0x345d51=_0x47be24[_0x38be51(0x401,0x405)];if(_0x345d51===0x0)return[];if(_0x345d51===0x1)return[0.5];const _0x605894=_0x47be24[_0x26f00a(0x2df,0x2da)]((_0x41ffa6,_0x55666b)=>({'v':_0x41ffa6,'i':_0x55666b}))['sort']((_0x418952,_0x179e61)=>_0x418952['v']-_0x179e61['v']);function _0x26f00a(_0x1e91c9,_0x5a7c36){return _0x4082(_0x1e91c9-0x199,_0x5a7c36);}const _0x17b044=new Array(_0x345d51);let _0xcf9a9b=0x0;while(_0xcf9a9b<_0x345d51){let _0x1cc764=_0xcf9a9b;while(_0x1cc764+0x1<_0x345d51&&_0x605894[_0x1cc764+0x1]['v']===_0x605894[_0xcf9a9b]['v'])_0x1cc764++;const _0x475d54=(_0xcf9a9b+_0x1cc764)/0x2,_0x104279=_0x475d54/(_0x345d51-0x1);for(let _0x405017=_0xcf9a9b;_0x405017<=_0x1cc764;_0x405017++)_0x17b044[_0x605894[_0x405017]['i']]=_0x104279;_0xcf9a9b=_0x1cc764+0x1;}return _0x17b044;}class UnionFind{[_0x3ea8b4(0x43b,0x437)]=new Map();[_0x2ff61e(0x1b5,0x19f)](_0x4900fb){const _0x4921d3=this[_0x5d4b32(0x19c,0x1a2)]['get'](_0x4900fb);function _0x5d4b32(_0x3ce850,_0x47684a){return _0x3ea8b4(_0x3ce850,_0x47684a- -0x295);}if(_0x4921d3===undefined||_0x4921d3===_0x4900fb)return this[_0x4306d0(0x75,0x60)][_0x4306d0(0x7b,0x6a)](_0x4900fb,_0x4900fb),_0x4900fb;const _0x10151f=this[_0x4306d0(0x84,0x7e)](_0x4921d3);this[_0x4306d0(0x75,0x74)][_0x4306d0(0x7b,0x6e)](_0x4900fb,_0x10151f);function _0x4306d0(_0xb9b901,_0x122362){return _0x3ea8b4(_0x122362,_0xb9b901- -0x3c2);}return _0x10151f;}[_0x2ff61e(0x1af,0x1b2)](_0x5577fc,_0x5d1602){function _0x5ad36f(_0x5265ad,_0xc5e3fe){return _0x2ff61e(_0x5265ad- -0x210,_0xc5e3fe);}const _0x4fcccf=this['find'](_0x5577fc);function _0x154e42(_0x1bf9bb,_0x1e466d){return _0x2ff61e(_0x1e466d- -0x43d,_0x1bf9bb);}const _0x4855e1=this[_0x154e42(-0x27b,-0x288)](_0x5d1602);if(_0x4fcccf!==_0x4855e1)this[_0x154e42(-0x2a3,-0x297)][_0x154e42(-0x2a5,-0x291)](_0x4fcccf,_0x4855e1);}}export function computeSignals(_0x547021,_0x5f29f8){const _0x210111=_0x5f29f8?.['nowMs']??0x0,_0x1cc68e=_0x5f29f8?.[_0x3ad332(-0x22b,-0x21e)]??Date['now'](),_0x79292f=_0x5f29f8?.['decay']??ACTR_DECAY,_0x22ff61=_0x5f29f8?.[_0x3ad332(-0x221,-0x220)]??DUP_TAU,_0x3f6cb3=_0x547021[_0x9cf00a(-0x72,-0x86)+_0x9cf00a(-0xad,-0x9c)](),_0x2800f4=_0x3f6cb3['length'],_0x290079=_0x3f6cb3['map'](_0x6951a4=>_0x6951a4['id']),_0xe4d2ca=new Set(_0x290079);let _0x4852eb=0x0;const _0x4f5008=_0x3f6cb3['map'](_0x70369c=>{const _0x55ce40=parseTs(_0x70369c[_0x47b1ac(0xb,0x14)])??_0x1cc68e,_0x36dc5f=Math['max']((_0x1cc68e-_0x55ce40)/0x5265c00,0x1/0x18),_0x1a9ef6=Math[_0x47b1ac(0x1d,0x1e)](_0x70369c[_0x47b1ac(0x18,0x16)+'nt'],0x0);function _0x47b1ac(_0x166f66,_0x2489af){return _0x3ad332(_0x166f66-0x22d,_0x2489af);}function _0x42bf7c(_0x2ad0c8,_0x3f178c){return _0x3ad332(_0x3f178c-0x371,_0x2ad0c8);}if(_0x1a9ef6>0x0)_0x4852eb++;return Math[_0x47b1ac(0x22,0x10)]((_0x1a9ef6+0x1)/(0x1-_0x79292f))-_0x79292f*Math[_0x47b1ac(0x22,0x2f)](_0x36dc5f);}),_0x8686ee=rankNorm(_0x4f5008),_0x4a1731=_0x547021[_0x9cf00a(-0xa5,-0x96)](_0x9cf00a(-0x9f,-0x9a)),_0x462a5b=new Map(),_0x11149d=new Map(),_0x54c0d3=new UnionFind();for(const _0x58bfb7 of _0x4a1731){if(!_0xe4d2ca[_0x9cf00a(-0x81,-0x93)](_0x58bfb7[_0x9cf00a(-0x92,-0x99)])||!_0xe4d2ca[_0x9cf00a(-0x96,-0x93)](_0x58bfb7[_0x9cf00a(-0x75,-0x82)]))continue;let _0x18e99e=_0x462a5b[_0x3ad332(-0x220,-0x22d)](_0x58bfb7[_0x9cf00a(-0xac,-0x99)]);!_0x18e99e&&(_0x18e99e=[],_0x462a5b[_0x3ad332(-0x227,-0x22c)](_0x58bfb7[_0x9cf00a(-0x8f,-0x99)],_0x18e99e));_0x18e99e['push'](_0x58bfb7[_0x3ad332(-0x20d,-0x1fd)]),_0x11149d[_0x9cf00a(-0x96,-0x8e)](_0x58bfb7['dst'],(_0x11149d[_0x9cf00a(-0x7a,-0x87)](_0x58bfb7[_0x3ad332(-0x21b,-0x209)])??0x0)+0x1);if(_0x58bfb7[_0x9cf00a(-0x89,-0x74)]>=_0x22ff61)_0x54c0d3['union'](_0x58bfb7[_0x9cf00a(-0x87,-0x99)],_0x58bfb7[_0x3ad332(-0x21b,-0x225)]);}const _0x1ab3a5=_0x290079[_0x3ad332(-0x22a,-0x23b)](_0x20dfcd=>{function _0x1bc82f(_0x46cc5f,_0x1a0761){return _0x3ad332(_0x1a0761-0x553,_0x46cc5f);}function _0x87f3be(_0x4cab2a,_0x1f06a8){return _0x3ad332(_0x1f06a8-0x4cc,_0x4cab2a);}const _0x56f8cf=_0x462a5b[_0x1bc82f(0x32c,0x333)](_0x20dfcd);if(!_0x56f8cf||_0x56f8cf[_0x1bc82f(0x320,0x322)]===0x0)return 0x1;const _0x4f1fd5=_0x56f8cf[_0x1bc82f(0x341,0x32d)]((_0x29c9ab,_0x5c547f)=>_0x29c9ab+_0x5c547f,0x0)/_0x56f8cf[_0x87f3be(0x2a0,0x29b)];return 0x1-_0x4f1fd5;}),_0x403fcd=_0x290079[_0x3ad332(-0x22a,-0x217)](_0x1a24ba=>_0x11149d[_0x3ad332(-0x220,-0x20b)](_0x1a24ba)??0x0);function _0x9cf00a(_0x262fa0,_0x38567f){return _0x3ea8b4(_0x262fa0,_0x38567f- -0x4cb);}const _0x38bc54=rankNorm(_0x403fcd),_0x509b9f=new Map(),_0x33b2f4=new Map();for(const _0x196152 of _0x290079){const _0x5b077f=_0x54c0d3['find'](_0x196152);_0x509b9f[_0x9cf00a(-0x92,-0x8e)](_0x196152,_0x5b077f),_0x33b2f4[_0x9cf00a(-0x9a,-0x8e)](_0x5b077f,(_0x33b2f4[_0x9cf00a(-0x87,-0x87)](_0x5b077f)??0x0)+0x1);}const _0x20c927=_0x290079['map'](_0x1f5f26=>(_0x33b2f4['get'](_0x509b9f['get'](_0x1f5f26))??0x1)-0x1),_0x12c3ff=rankNorm(_0x20c927),_0x449905=_0x290079[_0x3ad332(-0x22a,-0x21c)](_0x2fc320=>{function _0x1de896(_0x46eabc,_0x366af6){return _0x3ad332(_0x366af6-0x4a5,_0x46eabc);}const _0x2b0d73=_0x509b9f[_0x34c128(0x69,0x58)](_0x2fc320);function _0x34c128(_0x274114,_0x4d4477){return _0x3ad332(_0x274114-0x289,_0x4d4477);}return(_0x33b2f4[_0x34c128(0x69,0x75)](_0x2b0d73)??0x1)>=0x2?_0x2b0d73:null;}),_0x93662a=rankNorm(_0x3f6cb3[_0x3ad332(-0x22a,-0x21c)](_0x49c930=>_0x49c930[_0x9cf00a(-0x6e,-0x7d)+'ngth'])),_0x5a1d1b=_0x290079[_0x3ad332(-0x22a,-0x238)]((_0x554ad8,_0x3b1176)=>{function _0xe3d294(_0x103a99,_0x36a3b2){return _0x9cf00a(_0x103a99,_0x36a3b2-0x39d);}const _0x3eafbb=_0x93662a[_0x3b1176],_0x51b00c=_0x3f6cb3[_0x3b1176][_0xe3d294(0x300,0x313)+_0x35a717(0x81,0x7d)]??0.5;function _0x35a717(_0x7a6dba,_0x38a766){return _0x9cf00a(_0x38a766,_0x7a6dba-0x100);}const _0x5b516e=(_0x51b00c+_0x1ab3a5[_0x3b1176])/0x2;return 0.5*(0x1-_0x3eafbb)+0.5*(0x1-_0x5b516e);}),_0x54dc63=rankNorm(_0x5a1d1b),_0x36ec3e=[..._0x33b2f4[_0x3ad332(-0x225,-0x215)]()][_0x3ad332(-0x230,-0x23b)](_0x33fa37=>_0x33fa37>=0x2)[_0x3ad332(-0x231,-0x21e)];function _0x3ad332(_0x12e9bf,_0x2ab2c6){return _0x3ea8b4(_0x2ab2c6,_0x12e9bf- -0x664);}const _0x27b7cf=new Date(_0x1cc68e)[_0x3ad332(-0x21d,-0x221)+'g'](),_0x53678e=_0x290079['map']((_0x5f5ae3,_0x359be9)=>({'id':_0x5f5ae3,'activation':_0x8686ee[_0x359be9],'uniqueness':_0x1ab3a5[_0x359be9],'generic_penalty':_0x38bc54[_0x359be9],'dup_score':_0x12c3ff[_0x359be9],'dump_score':_0x54dc63[_0x359be9],'reliability':0x1,'cluster_id':_0x449905[_0x359be9]}));return _0x547021[_0x9cf00a(-0x82,-0x79)+_0x3ad332(-0x20f,-0x224)](_0x53678e,_0x27b7cf),{'nodes':_0x2800f4,'dupClusters':_0x36ec3e,'activationValid':_0x4852eb,'elapsedMs':_0x210111?Date[_0x9cf00a(-0x76,-0x75)]()-_0x210111:0x0};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4a44e7,_0x5c847c){function _0x155766(_0x46a73b,_0x4cb866){return _0x4448(_0x46a73b- -0x3b9,_0x4cb866);}const _0x3db7d6=_0x4a44e7();function _0x583460(_0x1f34e1,_0x57ba42){return _0x4448(_0x1f34e1-0x7f,_0x57ba42);}while(!![]){try{const _0x5288f7=-parseInt(_0x583460(0xed,0xe9))/0x1+-parseInt(_0x583460(0xf6,0xf3))/0x2*(-parseInt(_0x583460(0xf8,0xf9))/0x3)+parseInt(_0x155766(-0x341,-0x347))/0x4*(-parseInt(_0x583460(0xef,0xe7))/0x5)+parseInt(_0x583460(0xf3,0xed))/0x6+-parseInt(_0x583460(0xf5,0xfd))/0x7*(parseInt(_0x583460(0xf2,0xfa))/0x8)+-parseInt(_0x155766(-0x344,-0x33b))/0x9+parseInt(_0x583460(0xeb,0xee))/0xa;if(_0x5288f7===_0x5c847c)break;else _0x3db7d6['push'](_0x3db7d6['shift']());}catch(_0x167dea){_0x3db7d6['push'](_0x3db7d6['shift']());}}}(_0x14b2,0x25b98));import{existsSync,readFileSync,unlinkSync,writeFileSync}from'node:fs';import{dirname,join,resolve}from'node:path';import{resolvePath}from'../db/database.js';export function sinceFilePath(_0xe746a4){function _0x278f78(_0x5bc080,_0x444076){return _0x4448(_0x5bc080-0x95,_0x444076);}function _0x266dd2(_0x261f9e,_0x484e4a){return _0x4448(_0x261f9e- -0xe6,_0x484e4a);}return join(dirname(resolve(resolvePath(_0xe746a4))),_0x278f78(0x100,0xfe)+_0x266dd2(-0x77,-0x7c));}function _0x14b2(){const _0x42fc62=['otbszKrrDg4','DxrMltG','C2XPy2u','mtK3mdu2sLzYrMTN','mZK5mde4A1fWzuPz','mtqYotqXnKrcCKfLvG','mZvYr3jtExq','mJm3mdi2rLzsy1rX','ndu1mZjjugDptvK','m2POAuzeqq','BM93','CMvWBgfJzq','lMnVBNrLEhrYyq','ndK4mJC2mg5pEe5HrG','DhjPBq','nde4otrMy2Xrz3K','BMSTC2LUy2u'];_0x14b2=function(){return _0x42fc62;};return _0x14b2();}export function nowStamp(_0x525056=Date[_0x316e17(-0x2a9,-0x2a9)]()){function _0x408ccc(_0x4548a3,_0x240648){return _0x316e17(_0x240648,_0x4548a3-0x401);}function _0x4cc275(_0x4a527e,_0x22a08c){return _0x316e17(_0x4a527e,_0x22a08c-0x14);}return new Date(_0x525056)['toISOStrin'+'g']()[_0x408ccc(0x159,0x15f)]('T','\x20')[_0x4cc275(-0x29b,-0x29d)](0x0,0x13);}export function readSince(_0x22d9ac){const _0x289ef0=sinceFilePath(_0x22d9ac);function _0x57b364(_0x3b7b34,_0x4d8e3e){return _0x316e17(_0x3b7b34,_0x4d8e3e-0x2a9);}if(!existsSync(_0x289ef0))return undefined;function _0xfef1ef(_0x1f636e,_0x5ebbbc){return _0x316e17(_0x1f636e,_0x5ebbbc-0x653);}try{if('OviOt'!=='OviOt'){const _0x2a4d6f=_0x95195c(_0x4359d8);if(_0x404b83(_0x2a4d6f))_0x5290c3(_0x2a4d6f);}else{const _0x26dda1=readFileSync(_0x289ef0,_0xfef1ef(0x3aa,0x3a1))[_0x57b364(-0xf,-0xd)]();return/^\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}$/['test'](_0x26dda1)?_0x26dda1:undefined;}}catch{return undefined;}}function _0x4448(_0x1b7fe7,_0x1f1737){_0x1b7fe7=_0x1b7fe7-0x6b;const _0x14b260=_0x14b2();let _0x4448bd=_0x14b260[_0x1b7fe7];if(_0x4448['hqDflK']===undefined){var _0x59cde7=function(_0xbd2a3f){const _0x3a64f6='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x44cdc='',_0x1e4a2f='';for(let _0x35be50=0x0,_0x3fdd8d,_0x5e78bf,_0x3f1c48=0x0;_0x5e78bf=_0xbd2a3f['charAt'](_0x3f1c48++);~_0x5e78bf&&(_0x3fdd8d=_0x35be50%0x4?_0x3fdd8d*0x40+_0x5e78bf:_0x5e78bf,_0x35be50++%0x4)?_0x44cdc+=String['fromCharCode'](0xff&_0x3fdd8d>>(-0x2*_0x35be50&0x6)):0x0){_0x5e78bf=_0x3a64f6['indexOf'](_0x5e78bf);}for(let _0x27209d=0x0,_0x27738e=_0x44cdc['length'];_0x27209d<_0x27738e;_0x27209d++){_0x1e4a2f+='%'+('00'+_0x44cdc['charCodeAt'](_0x27209d)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x1e4a2f);};_0x4448['WiUyAJ']=_0x59cde7,_0x4448['GeCgqw']={},_0x4448['hqDflK']=!![];}const _0x1bf8e1=_0x14b260[0x0],_0x50611a=_0x1b7fe7+_0x1bf8e1,_0x30be3d=_0x4448['GeCgqw'][_0x50611a];return!_0x30be3d?(_0x4448bd=_0x4448['WiUyAJ'](_0x4448bd),_0x4448['GeCgqw'][_0x50611a]=_0x4448bd):_0x4448bd=_0x30be3d,_0x4448bd;}export function writeSince(_0x46c9d0,_0x3123ce){function _0x2133eb(_0x521675,_0x22b1fc){return _0x316e17(_0x22b1fc,_0x521675-0xe1);}try{return writeFileSync(sinceFilePath(_0x46c9d0),_0x3123ce+'\x0a',_0x2133eb(-0x1d1,-0x1d4)),!![];}catch{return![];}}function _0x316e17(_0x418908,_0x3fc8fd){return _0x4448(_0x3fc8fd- -0x323,_0x418908);}export function clearSince(_0x57e2b0){try{const _0x343e61=sinceFilePath(_0x57e2b0);if(existsSync(_0x343e61))unlinkSync(_0x343e61);}catch{}}
|
package/dist/db/database.d.ts
CHANGED
|
@@ -306,6 +306,45 @@ export declare class MemoryDatabase {
|
|
|
306
306
|
dst: string;
|
|
307
307
|
weight: number;
|
|
308
308
|
}>): number;
|
|
309
|
+
/**
|
|
310
|
+
* `#221` (ADR-093 D2): **src 단위 부분 교체** — 증분 rebuild 전용.
|
|
311
|
+
*
|
|
312
|
+
* `replaceEdges` 는 `DELETE WHERE type = ?` 로 테이블을 통째로 비우고 다시 쓴다. 전건이면
|
|
313
|
+
* 옳지만 증분에서는 **바뀌지 않은 엣지까지 전량 재기록**한다 — [검증] 2026-09-14 운영 사본
|
|
314
|
+
* (n=35,290 · sim 812,994): 한 회차의 **실제로 바뀐 src 가 0** 인데 812,994행을 지우고 다시 썼고
|
|
315
|
+
* 그 쓰기가 sim 소요의 **70%**(6,729~7,246ms)였다.
|
|
316
|
+
*
|
|
317
|
+
* 🔴 **`srcs` 는 「교체 대상」이지 「방출 대상」이 아니다.** 여기 들어온 src 의 기존 엣지를
|
|
318
|
+
* 전부 지우고 `edges` 에 담긴 것만 다시 넣는다 — 즉 `srcs` 에 있는데 `edges` 에 없는 src 는
|
|
319
|
+
* **엣지가 사라진다**(의도된 동작. 삭제·임베딩 소거 노드의 정리가 이 경로다).
|
|
320
|
+
*
|
|
321
|
+
* 🔴 **왜 전체 DELETE 를 대체할 때 GC 를 함께 넘겨야 하나** — 전건의 `DELETE WHERE type=?` 는
|
|
322
|
+
* 부수적으로 **유일한 쓰레기 수거**였다. `clearSince` 호출 사이트가 `embed --reindex` 하나뿐이라
|
|
323
|
+
* (`cli/commands/embed.ts`) 정상 운영에서 rebuild 는 **영구히 증분**이고, 「언젠가 전건이 돌아
|
|
324
|
+
* 쓸어 준다」가 성립하지 않는다. 호출부(`buildSimEdges`)가 `staleSrc`(rows 에 없는 src)와
|
|
325
|
+
* `danglingDstSrc`(rows 에 없는 dst 를 가리키는 엣지의 src)를 `srcs` 에 포함시켜야 한다.
|
|
326
|
+
*
|
|
327
|
+
* 🔴 **`computed_at` 의 의미가 바뀐다** — 전건은 전 행이 같은 값(마지막 교체 시각)이지만
|
|
328
|
+
* 이후에는 **행마다 「그 엣지가 마지막으로 쓰인 시각」** 이다. [검증] 읽는 코드는 0건이라
|
|
329
|
+
* 기능 영향이 없고, 오히려 「이번 실행이 실제로 쓴 행」을 세는 **외부 오라클**이 된다
|
|
330
|
+
* (ADR-093 DoD 3 — 코드 카운터와 독립이라 순환이 아니다).
|
|
331
|
+
*
|
|
332
|
+
* @param srcs 교체 대상 src id. 중복은 무해하다(DELETE 가 멱등).
|
|
333
|
+
* @returns 실제로 INSERT 한 엣지 수
|
|
334
|
+
*/
|
|
335
|
+
replaceEdgesForSrcs(type: string, srcs: Iterable<string>, edges: Array<{
|
|
336
|
+
src: string;
|
|
337
|
+
dst: string;
|
|
338
|
+
weight: number;
|
|
339
|
+
}>): number;
|
|
340
|
+
/**
|
|
341
|
+
* `#221` (ADR-093 D2): 단일 type 의 엣지 수.
|
|
342
|
+
*
|
|
343
|
+
* 🔴 부분 교체(`replaceEdgesForSrcs`) 도입으로 「이번에 쓴 수」와 「DB 총량」이 갈라졌다.
|
|
344
|
+
* `SimBuildResult.edges` 는 **총량**이 계약이므로(운영 로그가 그 시계열을 읽는다) 증분 경로가
|
|
345
|
+
* 이 메서드로 총량을 다시 센다. `countEdgesByType` 은 전 type GROUP BY 라 이 자리에 과하다.
|
|
346
|
+
*/
|
|
347
|
+
countEdges(type: string): number;
|
|
309
348
|
/** type별 엣지 카운트 (shadow 관찰). */
|
|
310
349
|
countEdgesByType(): Array<{
|
|
311
350
|
type: string;
|
|
@@ -315,12 +354,36 @@ export declare class MemoryDatabase {
|
|
|
315
354
|
/**
|
|
316
355
|
* `#216` (ADR-092 D1): `since` 이후 **sim 이 바뀔 수 있는** 메모리 id.
|
|
317
356
|
*
|
|
318
|
-
*
|
|
357
|
+
* 세 채널의 합집합이다 — 하나라도 빠지면 **조용한 누락**이 된다:
|
|
319
358
|
* 1. **임베딩이 있는데 sim src 에 없는 노드** — 신규 임베딩(신규 메모리 · backfill)과
|
|
320
359
|
* **재임베딩**을 함께 잡는다. 재임베딩은 `saveEmbedding` 이 sim src 행을 지워
|
|
321
360
|
* **스스로 이 채널에 들어온다**(D1-a).
|
|
322
361
|
* 2. **삭제(tombstone)** — 삭제 노드는 `getAllEmbeddingRows` 에서 빠지지만 그 노드를
|
|
323
362
|
* dst 로 갖던 src 의 top-k 에 구멍이 남는다. 역방향 폐포에 쓰려면 id 가 필요하다.
|
|
363
|
+
* 3. **`embedding` 이 NULL 로 지워졌는데 아직 sim 에 dst 로 남아 있는 노드**
|
|
364
|
+
* (`#221` · `ADR-093` D0). 🔴 **이 채널이 없으면 증분이 전건과 등가가 아니다.**
|
|
365
|
+
*
|
|
366
|
+
* 🔴 **채널 3 이 없던 동안 무슨 일이 있었나** (`#216` 의 결함, `#221` 이 발견):
|
|
367
|
+
* `updateMemory` 는 content 가 바뀌면 `wipe_embedding_on_content_change` 로 embedding 을
|
|
368
|
+
* **NULL 로 지운다**(위 852줄 근처, `skill→skill` 만 예외). 그 노드는
|
|
369
|
+
* - 채널 1 이 `embedding IS NOT NULL` 로 **배제**하고
|
|
370
|
+
* - tombstone 이 아니라 채널 2 도 아니며
|
|
371
|
+
* - 폐포(`edge-builder.ts:240` `if (!delta.has(e.dst)) continue`)가 그것을 dst 로 갖던 src 도 **못 끌어온다**
|
|
372
|
+
*
|
|
373
|
+
* 그 src 는 warm-seed 만 받는데 `edge-builder.ts:251` 의 `di === undefined` 가 그 엣지를
|
|
374
|
+
* **버리므로** top-k 에 **빈자리**가 남는다 — 고아가 남는 게 아니라 **자리가 비는** 것이다.
|
|
375
|
+
* [검증] 재현(n=200 · 3건 wipe): 증분 **4,893** vs 전건 **4,925** — **32 엣지 / 31 src** 부족.
|
|
376
|
+
* 채널 3 을 넣으면 `equal: true`.
|
|
377
|
+
*
|
|
378
|
+
* 🔴 **왜 dst 만인가 (src 를 넣지 않는 이유)** — `embedding` NULL 노드가 **src** 인 엣지는
|
|
379
|
+
* 그 노드가 `getAllEmbeddingRows`(= `WHERE embedding IS NOT NULL`)에 없어 **애초에 재방출되지
|
|
380
|
+
* 않는다**. 전건은 `replaceEdges` 의 전체 DELETE 가, 증분 부분 교체는 `staleSrc` 가 지운다.
|
|
381
|
+
* **빈자리를 만드는 것은 dst 쪽뿐**이다.
|
|
382
|
+
*
|
|
383
|
+
* 🔴 **`memories` 전체에 `embedding IS NULL` 을 걸지 않는 이유** — 신규 메모리가 임베딩되기
|
|
384
|
+
* 전 구간까지 Δ 에 들어와 역방향 폐포로 증폭된다. **sim 에 dst 로 실재하는 것**만 잡는다.
|
|
385
|
+
*
|
|
386
|
+
* [검증] 비용(운영 DB, 2026-09-14): Δ **1,305 → 1,322 (+1.3%)**, 폐포로 끌려올 src **470**.
|
|
324
387
|
*
|
|
325
388
|
* 🔴 **`updated_at` 채널은 의도적으로 없다.** `saveEmbedding` 이 `updated_at` 을 안 바꾸므로
|
|
326
389
|
* 「`updated_at` 이 바뀐 것」은 **임베딩이 안 바뀐 것**이고 sim 에 영향이 없다. 그런데 그것을
|