Sculpt is a parametric ergonomic keycap generator for CadQuery and CQ-Editor, built for multi-axis, concave keycap design on ergonomic keyboards. It gives direct control over key height, sweep, pitch, yaw, local face tilt, and thumb cluster geometry, while keeping the workflow simple and editable from a single Python file.
The script generates not only the keycaps themselves, but also integrated printable support geometry designed to preserve surface quality and make the models easier to manufacture.
Sculpt can export both STL files for printing and STEP files for further CAD editing.
- Fully parametric sculpted keycap generation
- Per-key control of pitch, yaw, face tilt, and height
- Dedicated thumb cluster tuning
- Cherry MX-compatible stem geometry
- Integrated printable support geometry
- STL and STEP export
- Works in CQ-Editor, OCP CAD Viewer, and CLI mode
- Python 3
- CadQuery
- jmwright-CQ-Editor or another CadQuery-compatible viewer
- OCP modules used by CadQuery
- Open
Sculpt_keycaps_v1.pyin CQ-Editor. - Edit the main parameters at the top of the file.
- Set:
MODE = "single" | "left" | "right" | "both"QUALITY = "draft" | "production"INCLUDE_FN_ROW = True | False
- Run the script.
- Export the result as STL or STEP.
python Sculpt_keycaps_v1.py --mode single --quality production --output test_keycap.step
python Sculpt_keycaps_v1.py --mode left --quality production --output left_hand.step
python Sculpt_keycaps_v1.py --mode both --quality draft --fn-row --output sculpt_full.stepYou can also override the quality preset manually:
python Sculpt_keycaps_v1.py --mode left --slices 20 --output left_hand.stepKC_BASE_WIDTHKC_FACE_WIDTHKC_BASE_RADIUSKC_FACE_RADIUSKC_CAVITY_SCALEKC_SUPPORT_TOP_THINKC_SUPPORT_ANGLEKC_SLICESKC_DIMPLE_INSETKC_DIMPLE_TRANSITION_FILLETKC_TOP_THICKNESS_MIN
These parameters define the outer keycap shape, cavity scale, support geometry, dimple behavior, and minimum shell thickness.
STEM_BASE_HEIGHTSTEM_BASE_SPACINGSTEM_KEY_WIDTHSTEM_BASE_LIFTSTEM_WING_BREADTHSTEM_WING_THICKNESS
These parameters control the Cherry MX stem geometry and fit.
LAYOUT_UNITLAYOUT_DIMPLE_DEPTHDEFAULT_FACE_TILTKEYCAP_BOOT_HEIGHTSTEM_BOOT_HEIGHTMAX_KEY_HEIGHTMIN_KEY_HEIGHTLAYOUT_COLUMNSLAYOUT_ROWS
These parameters control key spacing, dimple depth, boot/support height, overall sculpt range, and matrix dimensions.
THUMB_HEIGHTSTHUMB_SWEEPTHUMB_FACE_TILT
These parameters define the thumb cluster height, sweep angles, and local face tilt.
KEY_ANGLESKEY_FACE_TILTKEY_HEIGHT
These arrays control the sculpt of each individual key.
KEY_ANGLESsets per-key pitch and yawKEY_FACE_TILTadds local top-surface tiltKEY_HEIGHTdefines explicit key height values
Together, they provide full control over the final shape of the layout.
Sculpt can generate:
- a single test keycap
- the left-hand layout
- the right-hand layout
- both halves together
Export formats:
.stlfor 3D printing.stepfor CAD editing and downstream modeling workflows
Sculpt includes integrated support geometry intended to make printing easier while preserving the visible surfaces of the keycaps. This support strategy was developed specifically for SLA printing.
The generated models are designed to be placed on the print bed at a print-friendly angle. Final fit may still require small tolerance adjustments depending on your printer, material, slicer profile, and stem calibration.
This project was inspired in part by key-sweep by Sammy Hughes.
See LICENSE.



