agentleFS
KevoyuanKevoyuan/AgentSCAD/skills/scad-library-threads/SKILL.md

scad-library-threads

Skill26 starsChanged 5 months agoMITView on GitHub

This skill should be used when generating OpenSCAD with threads.scad or threadlib, including metric threads, threaded holes, taps, bolts, nuts, screw connectors, bottle caps, pipe threads, and printable threaded mechanical interfaces.

The file

Show its rules and text

We split this skill into the rules it gives an agent

15 rules. About 0 are common, 12 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈12

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use thread libraries when the runtime prompt lists threads.scad or threadlib and the requested design needs working threaded interfaces.

    line 13
  2. Distinctive:

    Use only the exact library listed as available by the runtime prompt.

    line 29
  3. Distinctive:

    Use threads for caps, knobs, adapters, pipe fittings, screw-in mounts, and replaceable connectors.

    line 33
  4. Distinctive:

    Use internal thread/tap helpers to subtract threaded holes from printable bodies.

    line 34
  5. Distinctive:

    Use external thread/bolt helpers for male threaded connectors.

    line 35
  6. Distinctive:

    Add non-threaded lead-in chamfers and grip surfaces so parts are printable and usable.

    line 36
  7. Very specific:

    Use metric_thread() when threads.scad is available and metric diameter/pitch are known:

    line 40
  8. Very specific:

    Use bolt(), nut(), tap(), or thread() when threadlib is available:

    line 55
  9. Distinctive:

    Keep thread diameter, pitch/designator, turns/length, and clearance exposed.

    line 77
  10. Distinctive:

    Use coarse printable threads for FDM unless the user asks for fine threads.

    line 79
  11. Distinctive:

    Use chamfers/lead-ins and leave tolerance.

    line 80
  12. Distinctive:

    Avoid tiny functional threads below typical printer capability unless the request explicitly needs them.

    line 81
  13. Distinctive:

    Do not combine multiple thread libraries in one model.

    line 85
  14. Distinctive:

    Do not invent standard designators.

    line 86
  15. Distinctive:

    Do not copy thread library source into generated SCAD.

    line 87

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

SCAD Library Threads Skill

Use thread libraries when the runtime prompt lists threads.scad or threadlib and the requested design needs working threaded interfaces.

Imports

For classic threads.scad:

include <threads.scad>

For threadlib:

use <threadlib/threadlib.scad>

Use only the exact library listed as available by the runtime prompt.

Best Uses

  • Use threads for caps, knobs, adapters, pipe fittings, screw-in mounts, and replaceable connectors.
  • Use internal thread/tap helpers to subtract threaded holes from printable bodies.
  • Use external thread/bolt helpers for male threaded connectors.
  • Add non-threaded lead-in chamfers and grip surfaces so parts are printable and usable.

threads.scad Pattern

Use metric_thread() when threads.scad is available and metric diameter/pitch are known:

include <threads.scad>

/* [Thread] */
thread_diameter = 20; // min: 4 max: 80 step: 0.5
thread_pitch = 2;    // min: 0.5 max: 6 step: 0.1
thread_length = 12;  // min: 3 max: 60 step: 0.5

metric_thread(thread_diameter, thread_pitch, thread_length);

threadlib Pattern

Use bolt(), nut(), tap(), or thread() when threadlib is available:

use <threadlib/threadlib.scad>

/* [Thread] */
turns = 6;         // min: 2 max: 20 step: 1
outer_diameter = 18; // min: 6 max: 60 step: 0.5

module threaded_hole_block() {
  difference() {
    cube([outer_diameter*2, outer_diameter*2, turns*1.5], center=true);
    translate([0, 0, -turns])
      tap("M12", turns=turns);
  }
}

threaded_hole_block();

Quality Rules

  • Keep thread diameter, pitch/designator, turns/length, and clearance exposed.
  • Extend subtractive taps slightly beyond the body to avoid thin artifacts at entrances.
  • Use coarse printable threads for FDM unless the user asks for fine threads.
  • Use chamfers/lead-ins and leave tolerance; do not create exact zero-clearance mating parts.
  • Avoid tiny functional threads below typical printer capability unless the request explicitly needs them.

Avoid

  • Do not combine multiple thread libraries in one model.
  • Do not invent standard designators; if uncertain, expose diameter and pitch or use generic geometry.
  • Do not copy thread library source into generated SCAD.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.