1 view
superdesigndev/treg
OpenRouter for agent tools. Join community here: https://discord.gg/6mQYYfFMAn
Python★ 3,217+468 that day#10 on trending
C63.5/100
Duplication85
1.9% in python, javascript, vue, bash, typescript, perl, sqlDead code79
2.5%Complexity38
70.3% The score is jscpd's own --health model: markup, data and text left out, tests kept. The numbers below are the trending scan's.
1.48%duplicated code · 1,450 of 97,882 lines
84clones in code
410code files of 3,005 scanned
15%duplicated over all files · 3,974 clones
Most complex files
- src/treg/cli.py1966 cx
- src/treg/routers/web.py884 cx
- src/treg/web/enrich-arena/arena.js756 cx
- src/treg/application/call/resolve.py739 cx
- scripts/catalog_validate.py626 cx
- tests/test_catalog_api.py583 cx
- scripts/catalog_ingest.py567 cx
- src/treg/domain/catalog/store.py422 cx
- tests/test_routing.py422 cx
- src/treg/application/arena.py408 cx
Dead code 2.52% unused · 90 findings
- src/treg/web/enrich-arena/arena.jsunused-file
- src/treg/web/dashboard-legacy/assets/81e84d6e19e3b54f7b591d1ea45e99c8c7a4560a/tutorial.jsunused-file
- src/treg/web/tutorial.jsunused-file
- src/treg/web/media/astra/page.jsunused-file
- src/treg/web/media/landing/hero-particles.jsunused-file
- e2e_check.pyunused-file
- src/treg/web/media/landing/gateway-3d.jsunused-file
- src/treg/web/agent-setup.jsunused-file
- src/treg/web/dashboard-legacy/assets/81e84d6e19e3b54f7b591d1ea45e99c8c7a4560a/agent-setup.jsunused-file
- src/treg/web/media/landing/refinement.jsunused-file
The code number leaves out tests, fixtures, docs, examples, data files, styles, translations and vendored code, and 1 generated file: src/treg/alembic/versions/0001_baseline_current_schema.py.
Largest clones in the code
- 547 lines in 2 placesjavascript2,925 tokenssrc/treg/web/dashboard-legacy/assets/81e84d6e19e3b54f7b591d1ea45e99c8c7a4560a/tutorial.js:12–558src/treg/web/tutorial.js:12–558
12(function () { 13 const PERSONAS = { 14 tom: { label: "Tom · owner", cls: "tom" }, 15 bob: { label: "Bob · member→admin", cls: "bob" }, 16 alice: { label: "Alice · viewer", cls: "alice" }, 17 sys: { label: "setup", cls: "sys" }, 18 ops: { label: "platform operator", cls: "ops" }, 19 you: { label: "you · member", cls: "you" }, 20 sam: { label: "Sam · restricted member", cls: "sam" }, 21 };First 10 of 547 lines.
- 88 lines in 2 placesjavascript891 tokenssrc/treg/web/agent-setup.js:2–89src/treg/web/dashboard-legacy/assets/81e84d6e19e3b54f7b591d1ea45e99c8c7a4560a/agent-setup.js:2–89
2(function(global){ 3 const agents=[ 4 {id:'openclaw',name:'OpenClaw',icon:'openclaw-color'}, 5 {id:'grokbot',name:'Grok Bot',icon:'/logos/agents/grokbot.png',plugin:'https://x.ai/bot/plugin/55647425'}, 6 {id:'hermes',name:'Hermes Agent',icon:'hermesagent'}, 7 {id:'claudeai',name:'Claude.ai',icon:'claude-color'}, 8 {id:'claude-code',name:'Claude Code',icon:'claudecode-color'}, 9 {id:'codex',name:'Codex',icon:'codex-color'}, 10 ]; 11 const moreAgents=[First 10 of 88 lines.
- 78 lines in 2 placesjavascript602 tokenssrc/treg/web/dashboard-legacy/assets/81e84d6e19e3b54f7b591d1ea45e99c8c7a4560a/dashboard-tour/tour.js:4–81src/treg/web/tour/tour.js:4–81
4(function () { 5 window.TREG_TOUR = { 6 personas: { tom:"Tom · owner", bob:"Bob · member→admin", alice:"Alice · viewer", sys:"sign-in" }, 7 colors: ["--accent","--green","--amber","--teal","--red"], // one mat colour per Part, cycled 8 steps: [ 9 { part:"Sign in", who:"sys", img:"01-signin.webp", title:"Three ways in", 10 explain:"The sign-in screen offers three separate doors — pick <b>one</b>: <b>Continue with GitHub</b> (real OAuth), <b>Email me a sign-in code</b> (wo… 11 notice:"This tour uses the email-code door. In production the code is <b>emailed</b> to you (via Resend); the screenshots here were captured in dev mod… 12 { part:"Sign in", who:"sys", img:"02-email-code.webp", title:"The email code", 13 explain:"Type your email and click <b>Email me a sign-in code</b>. <b>Check your inbox</b> for the 6-digit code, paste it into the field, and <b>Sign i…First 10 of 78 lines.
7 more
- 12 lines in 2 placeshtml378 tokens
- 33 lines in 2 placespython254 tokens
- 34 lines in 2 placespython215 tokens
- 15 lines in 2 placespython173 tokens
- 8 lines in 4 placespython50 tokens
- 11 lines in 2 placespython135 tokens
- 12 lines in 2 placespython132 tokens
Largest clones over all files, tests and data included
- 375 lines in 3 placesmarkdowndocs and examples4,847 tokensdsh/skills/treg/SKILL.md:41–415plugin/skills/treg/SKILL.md:44–418plugins/minimax/skills/treg/SKILL.md:25–399
41a directory dsh also scans. Harmless, but redundant with this bundle. 42 43--- 44 45# treg — the tool catalog for your agent 46 47**Ask for the task, not the tool.** When a job needs external or live data — backlinks, keyword 48volume, a TikTok profile, a work email, competitor ad creative — search the catalog, read the price, 49call it. 50First 10 of 375 lines.
- 79 lines in 5 placesmarkupmarkup1,688 tokenssrc/treg/web/usecase-ads.html:208–286src/treg/web/usecase-company.html:212–290src/treg/web/usecase-enrichment.html:187–265src/treg/web/usecase-seo.html:227–305src/treg/web/usecase-social.html:200–278
208 <div class="ctas"><a class="candy" href="/app?ref=p4" data-ev="lp_cta_primary" data-page="p4">Start Free</a></div> 209 <div class="trust"><p>$1.00 of free credit once per new verified account. No credit card, no provider signup. treg.to is open source 210(AGPL).</p></div> 211</div></section> 212 213<footer> 214 <div class="foot-in"> 215 <a class="brand" href="/"><span class="glyph">▚</span> treg.to</a> 216 <span class="note">100% open source</span> 217 <span class="sp"></span>First 10 of 79 lines.
- 376 lines in 2 placesmarkdowndocs and examples4,882 tokens
43Either way, the rest of this page is the part that matters — **when** treg is the right move, and 44**how to choose** between providers. 45 46--- 47 48# treg — the tool catalog for your agent 49 50**Ask for the task, not the tool.** When a job needs external or live data — backlinks, keyword 51volume, a TikTok profile, a work email, competitor ad creative — search the catalog, read the price, 52call it.First 10 of 376 lines.
- 378 lines in 2 placesmarkdowndocs and examples4,882 tokens
- 12 lines in 64 placesyamldata files58 tokens
By format, code only
| Format | Files | Lines | Clones | Duplicated lines | Duplication |
|---|---|---|---|---|---|
| python | 233 | 83,103 | 76 | 699 | 0.84% |
| html | 40 | 1,897 | 5 | 38 | 2% |
| javascript | 67 | 7,157 | 3 | 713 | 9.96% |
| vue | 40 | 3,615 | 0 | 0 | 0% |
| bash | 17 | 1,295 | 0 | 0 | 0% |
| typescript | 6 | 330 | 0 | 0 | 0% |
| css | 5 | 198 | 0 | 0 | 0% |
| perl | 1 | 174 | 0 | 0 | 0% |
| sql | 1 | 113 | 0 | 0 | 0% |
By format, all files
| Format | Files | Lines | Clones | Duplicated lines | Duplication |
|---|---|---|---|---|---|
| yaml | 195 | 115,868 | 2,717 | 37,785 | 32.61% |
| json | 1,821 | 154,889 | 694 | 29,031 | 18.74% |
| python | 414 | 151,988 | 298 | 2,752 | 1.81% |
| markup | 161 | 20,933 | 178 | 2,151 | 10.28% |
| markdown | 137 | 36,543 | 63 | 2,604 | 7.13% |
| bash | 49 | 2,138 | 7 | 319 | 14.92% |
| html | 40 | 1,897 | 5 | 38 | 2% |
| javascript | 74 | 8,551 | 4 | 719 | 8.41% |
| css | 15 | 3,589 | 4 | 26 | 0.72% |
| text | 32 | 572 | 4 | 68 | 11.89% |
Trending appearances
| Day | Rank | Stars | Files | Lines | Clones | All files | Code | Health | Commit |
|---|---|---|---|---|---|---|---|---|---|
| Sep 25, 2026 | #10 | 3,217 (+468) | 3,005 | 503,120 | 3,974 | 15% | 1.48% | C 63.5 | 9d9d7f6 |
| Sep 24, 2026 | #9 | 2,816 (+506) | 2,983 | 497,052 | 3,954 | 15.14% | 1.52% | C 63.5 | 87a49eb |
| Sep 23, 2026 | #6 | 2,317 (+230) | 2,960 | 494,147 | 3,950 | 15.22% | 1.54% | C 63.9 | 95bdc8d |
Want this for your own project? Install jscpd and run jscpd ., or measure it the way the baselines were measured.