cactus-compute/needle
Automation foundation model for tiny devices: 2-bit, 8-29 MB, tool calls, structured extraction and embeddings on phones, wearables, smart homes, robots, cars and microcontrollers.
Python★ 11,677+234 that day#11 on trendingB 70.2 health1.2% duplicated
B70.2/100
Duplication88
1.1% in python, bash, javascript, perlDead code68
4.5%Complexity58
43.5%Most complex files
- needle/model/architecture.py240 cx
- needle/__init__.py194 cx
- needle/model/finetune.py124 cx
- needle/model/export.py116 cx
- needle/playground/app.js82 cx
- needle/agent/tools.py75 cx
- needle/_worker.py59 cx
- needle/model/quantize.py59 cx
- tests/test_weights.py53 cx
- needle/cli.py51 cx
Dead code 4.52% unused · 13 findings
- needle/playground/app.jsunused-file
- needle/model/architecture.py:_parameter_pathunused-symbol
- needle/model/run.py:_step_statsunused-symbol
- needle/model/tokenizer.py:TOOLS_END_IDunused-export
- needle/model/tokenizer.py:TOOLS_START_IDunused-export
- needle/model/tokenizer.py:TOOL_CALL_END_IDunused-export
- needle/model/tokenizer.py:TOOL_CALL_START_IDunused-export
- needle/model/tokenizer.py:IM_END_IDunused-export
- needle/model/tokenizer.py:IM_START_IDunused-export
- needle/model/tokenizer.py:THINK_END_IDunused-export
66files
10,882lines
113,003tokens
12clones
131duplicated lines (1.2%)
1,426duplicated tokens (1.26%)
By format
| Format | Files | Lines | Clones | Duplicated lines | Duplication |
|---|---|---|---|---|---|
| python | 40 | 7,751 | 8 | 97 | 1.25% |
| markup | 6 | 654 | 3 | 28 | 4.28% |
| css | 1 | 513 | 1 | 6 | 1.17% |
| bash | 11 | 817 | 0 | 0 | 0% |
| javascript | 1 | 331 | 0 | 0 | 0% |
| txt | 1 | 226 | 0 | 0 | 0% |
| yaml | 2 | 174 | 0 | 0 | 0% |
| perl | 1 | 168 | 0 | 0 | 0% |
| markdown | 1 | 101 | 0 | 0 | 0% |
| text | 1 | 101 | 0 | 0 | 0% |
Largest clones
- 11 lines · 268 tokens markupassets/benchmarks.svg:231–241⇆assets/benchmarks.svg:284–294
- 10 lines · 237 tokens markupassets/benchmarks.svg:179–188⇆assets/benchmarks.svg:232–241
- 10 lines · 235 tokens markupassets/benchmarks.svg:126–135⇆assets/benchmarks.svg:179–188
- 16 lines · 86 tokens pythonneedle/environments/data_capture.py:117–132⇆needle/environments/kitchen_appliance.py:106–121
- 16 lines · 86 tokens pythonneedle/environments/data_capture.py:117–132⇆needle/environments/media_player.py:89–104
- 16 lines · 86 tokens pythonneedle/environments/data_capture.py:117–132⇆needle/environments/productivity.py:118–133
- 16 lines · 86 tokens pythonneedle/environments/data_capture.py:117–132⇆needle/environments/smart_home.py:124–139
- 16 lines · 86 tokens pythonneedle/environments/data_capture.py:117–132⇆needle/environments/wearable.py:96–111
- 8 lines · 76 tokens pythonneedle/__init__.py:111–118⇆needle/_worker.py:58–65
- 10 lines · 65 tokens pythontests/test_fetch.py:120–129⇆tests/test_fetch.py:142–151
Trending appearances
| Day | Rank | Stars | Files | Lines | Clones | Duplication | Health | Commit |
|---|---|---|---|---|---|---|---|---|
| Sep 20, 2026 | #11 | 11,677 (+234) | 66 | 10,882 | 12 | 1.2% | B 70.2 | fc5bae0 |
Want this for your own project? Install jscpd and run jscpd .