### Setup import from .opt file Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/file-upload.md Use for importing a setup from a .opt file. The setupName and unit parameters are optional; if omitted, the values from the .opt file are used. The created setup is private. ```text request_file_upload(contentType: "application/octet-stream", category: "setup") → user uploads → poll get_upload_status until "complete" → setup_create_from_file(s3Url, setupName?, unit?) ``` -------------------------------- ### Install 3DOptix plugin in Codex Source: https://github.com/3doptix/skills/blob/main/README.md Adds the 3doptix/skills marketplace and installs the 3doptix plugin in Codex. Run these commands in a terminal. ```bash codex plugin marketplace add 3doptix/skills codex plugin add 3doptix@3doptix ``` -------------------------------- ### Session Start Checklist Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/SKILL.md A step-by-step checklist to be displayed at the beginning of every session to guide the optical design process. ```text [ ] Step 1 — Understand the System [ ] Step 2 — Propose Optical Layout [ ] Step 3 — Create Setup + Name + Widget Link [ ] Step 4 — Build Each Optical Element [ ] Step 5 — Place Light Source(s) [ ] Step 6 — Place Detector(s) [ ] Step 7 — Run Ray Tracing (with user approval) [ ] Step 8 — Present Results ``` -------------------------------- ### Example prompt: Build a 2-lens beam expander Source: https://github.com/3doptix/skills/blob/main/README.md A sample user prompt for the 3DOptix MCP server to build a 2-lens beam expander and run a spot diagram. ```text Build a 2-lens beam expander for a 5 mm 632 nm beam, 3× magnification, then run a spot diagram on the output. ``` -------------------------------- ### Example prompt: Import Zemax file Source: https://github.com/3doptix/skills/blob/main/README.md A sample user prompt for the 3DOptix MCP server to import a Zemax file and identify aberration locations. ```text Import my Zemax file into 3DOptix and tell me where the aberrations are worst. ``` -------------------------------- ### Install 3DOptix plugin in Claude Code Source: https://github.com/3doptix/skills/blob/main/README.md Adds the 3doptix/skills marketplace and installs the 3doptix plugin in Claude Code. Run these commands in a terminal. ```bash claude plugin marketplace add 3doptix/skills claude plugin install 3doptix@3doptix ``` -------------------------------- ### Session checklist for optimization workflow Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/optimization-workflow.md Display this checklist at the start of every optimization session and update it as you progress. It tracks phase transitions explicitly, from intake through baseline, iteration, and summary. ```text SESSION CHECKLIST — [Setup Name] [ ] Phase 0 — Intake: system type, FOMs, free variables, constraints [ ] Phase 1 — Baseline: layout read → collision map → analytical pre-check → simulate [ ] Phase N — Iterate: analytical verify → user approves → apply → simulate (repeat) [ ] Phase F — Summary: before/after comparison, widget URL, layout lock ``` -------------------------------- ### Fold Mirror Pose Example Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/SKILL.md Pose for a 45° fold mirror in the Z-X plane for a +Z to +X fold. ```text [x, 0, z, 0, -45, 0] ``` -------------------------------- ### Baseline results metrics table Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/optimization-workflow.md Example format for presenting analytical estimates, simulated results, targets, and status for system metrics. ```text Metric | Analytical Est. | Simulated | Target | Delta | Status ────────────────────────────────────────────────────────────────────────── Flux on detector | ~74% | 71% | ≥ 80% | −9% | FAIL RMS spot radius | ~35 µm | 38 µm | ≤ 15 µm | +23 µm | FAIL System length | 248 mm | — | ≤ 300 | — | PASS Min element gap | 4.2 mm | — | ≥ 2 mm | — | PASS ``` -------------------------------- ### Run validation script Source: https://github.com/3doptix/skills/blob/main/README.md Run 'node scripts/validate.js' to check skill frontmatter against the Agent Skills spec, confirm all four manifests agree on a version, and refuse to pass if '.mcp.json' grows a credential. No install step is needed. ```bash node scripts/validate.js ``` -------------------------------- ### Create a skill with required frontmatter Source: https://github.com/3doptix/skills/blob/main/README.md Create 'skills//SKILL.md' with this frontmatter. The 'name' must match the directory name, and the description should state when the skill should and should not trigger. ```markdown --- name: your-skill-name description: "When this skill should and should not trigger." --- ``` -------------------------------- ### Check plugin details before publishing Source: https://github.com/3doptix/skills/blob/main/README.md Run 'claude plugin details 3doptix' to confirm what a user will actually receive before publishing a change. ```bash claude plugin details 3doptix ``` -------------------------------- ### Repository layout Source: https://github.com/3doptix/skills/blob/main/README.md Shows the directory structure of the repository, including plugin manifests, MCP server config, skills, assets, and scripts. ```text .claude-plugin/ Claude Code plugin + marketplace manifests .codex-plugin/ Codex plugin manifest .agents/plugins/ Codex marketplace manifest .mcp.json The 3DOptix remote MCP server server.json MCP Registry entry skills/ Agent Skills — shared by every store assets/ Store icons (the spectral sphere from the 3DOptix mark) scripts/ validate.js, set-version.js — plain Node, no dependencies ``` -------------------------------- ### Optimization plan approval table Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/optimization-workflow.md Summarize all inputs in this table and do not proceed to Phase 1 until the user explicitly approves. If they change anything, regenerate and resubmit. ```text OPTIMIZATION PLAN — [Setup Name] System: [type] | Wavelength(s): [λ] Variable | Current | Min | Max | Step ───────────────────────────────────────────────── [component DOF] | [val] | [min] | [max] | [step] ───────────────────────────────────────────────── FOMs (ranked): [P1], [P2], ... Flux floor: [X]% | Min rays: [N] Collision floor: [X] mm Fixed parts: [list] Fixed pairs: [list] ───────────────────────────────────────────────── Approved? (yes / modify / cancel) ``` -------------------------------- ### Source Pose Configuration Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/SKILL.md Standard pose for a light source placed along the -Z axis, propagating in the +Z direction. ```text [0, 0, −d, 0, 0, 0] ``` -------------------------------- ### Release a new version Source: https://github.com/3doptix/skills/blob/main/README.md Cut a release by setting the version, validating, committing, tagging, and pushing. Never edit a manifest's version by hand; validate.js will fail. ```bash node scripts/set-version.js 1.1.0 # writes all four manifests node scripts/validate.js git commit -am "release: 1.1.0" && git tag v1.1.0 git push && git push --tags ``` -------------------------------- ### Ray file upload workflow Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/file-upload.md Use for uploading a ray file. After the upload completes, the s3Url is used when configuring a RAY_FILE light source. ```text request_file_upload(contentType: "application/octet-stream", category: "ray_file") → user uploads → poll get_upload_status until "complete" → use s3Url when configuring a RAY_FILE light source ``` -------------------------------- ### CAD/STEP upload workflow Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/file-upload.md Use for CAD/STEP file uploads. The flow returns a number_id that must be passed to setup_add_optomechanics. The resolution parameter accepts "LOW", "MEDIUM" (default), or "HIGH". The name should be taken from get_upload_status with the extension stripped. ```text request_file_upload(contentType: "application/step", category: "cad") → user uploads → poll get_upload_status until "complete" → cad_upload_and_process(s3Url, name, resolution?) # 30–120 s → setup_add_optomechanics(setupIdentifier, number_id) ``` -------------------------------- ### Lens geometry sub-routine: refractive index, radii, and EFL verification Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/custom-catalog-components.md Run these three steps in order before every 3doptix_lens_create. Step A computes the refractive index at the design wavelength (e.g., N-BK7 at 550 nm). Step B finds radii for the target EFL, returning radii for all valid subtypes. Step C verifies the EFL; it must match the target within 1% (0.1% for precision systems). ```text 3doptix_calculate_refractive_index( material: "N-BK7", wavelength: { value: 550, units: "nm" } ) → n ``` ```text 3doptix_find_spherical_radii_for_target_efl( refractive_index: n, efl: , system_units: "mm", central_thickness: T ← starting value: D / 20 (D = clear aperture diameter) ) → { r1, r2 } per lens subtype ``` ```text 3doptix_spherical_lens_maker_calculate_efl( refractive_index: n, r1: , r2: , central_thickness: T ) → efl ``` -------------------------------- ### Manufacturability check: sag and edge thickness Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/custom-catalog-components.md Manufacturability check to run before 3doptix_lens_create. Requires center thickness T ≥ 1 mm and edge thickness E ≥ 1 mm for biconvex lenses; for biconcave lenses the center thickness floor applies instead. If either fails, increase T by 1 mm and re-run the radii finder. ```text sag(R, D) = R - √(R² - (D/2)²) E = T - sag(R1, D) - sag(R2, D) [edge thickness, biconvex] Required: T ≥ 1 mm AND E ≥ 1 mm ``` -------------------------------- ### Analytical Performance Formulas Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/optimization-workflow.md A table of formulas used to estimate performance metrics for various optical scenarios during the verification phase. ```markdown | Scenario | Formula | |---------|---------| | Lens position change (imaging) | `1/f = 1/d_o + 1/d_i` | | Gaussian beam propagation | `w(z) = w₀ √(1 + (λz / πw₀²)²)` | | Collimating lens EFL | `f ≈ beam_radius / tan(θ_div)` | | Mirror tilt change | `r⃗_reflected = d⃗ − 2(d⃗·n̂)n̂` | | Flux through N surfaces | `T = Π(1 − loss_i)` — AR coating ~0.5%, uncoated ~3.5%, mirror 85–95% | | Rayleigh range | `z_R = π w₀² / λ` | ``` -------------------------------- ### Add 3DOptix MCP server directly Source: https://github.com/3doptix/skills/blob/main/README.md Adds the 3DOptix MCP server to Claude Code via HTTP transport. Use this if you only want the tools without the workflow guidance. ```bash claude mcp add --transport http 3doptix https://mcp.3doptix.com ``` -------------------------------- ### Optimization Summary Report Template Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/optimization-workflow.md A template for summarizing the results of an optimization run, including baseline, final, and target metrics, as well as a log of changes and simulation statistics. ```text OPTIMIZATION SUMMARY — [Setup Name] Metric | Baseline | Final | Target | Status ────────────────────────────────────────────── [FOM 1] | [val] | [val] | [val] | PASS/FAIL [FOM 2] | ... ────────────────────────────────────────────── Changes made: [Component] [DOF]: [old] → [new] (iteration N) ... Total iterations: X | Simulation runs: X | Blocked collisions: X Min element gap (final): X mm | All hard constraints: PASS / FAIL ``` -------------------------------- ### Full lens creation sequence Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/custom-catalog-components.md Full sequence for the lens geometry sub-routine. Steps 1-3 compute and verify the EFL, step 4 is the manufacturability check, and step 5 creates the lens. The materialId comes from 3doptix_material_search_by_name. ```text 1. 3doptix_calculate_refractive_index(material, wavelength) → n 2. 3doptix_find_spherical_radii_for_target_efl(n, efl, system_units, central_thickness) → r1, r2 3. 3doptix_spherical_lens_maker_calculate_efl(n, r1, r2, central_thickness) → verify EFL 4. Manufacturability check (sag + edge/center thickness) 5. 3doptix_lens_create(variant, r1, r2, central_thickness, materialId, diameter, ...) ← materialId = number_id from 3doptix_material_search_by_name (e.g. "n-bk7_schott") ``` -------------------------------- ### Gaussian Beam Parameter Formulas Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/SKILL.md Analytical formulas for calculating beam radius, Rayleigh range, and collimator effective focal length (EFL) before component placement. ```text Gaussian beam radius: w(z) = w0·√(1 + (λz / πw0²)²) Rayleigh range: z_R = πw0² / λ Collimator EFL: f = beam_radius_target / tan(θ_div) Beam at lens: verify w(z_lens) vs. CA rule (CA ≥ 1.5× beam diameter) ``` -------------------------------- ### Iteration Result Table Template Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/optimization-workflow.md The required format for reporting the final results of a simulation iteration. ```text Metric | Previous | Predicted | Simulated | Delta | Target | Status ``` -------------------------------- ### BFL and detector position formulas Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/custom-catalog-components.md Compute BFL analytically and set the detector position when the lens is centered at z = 0. Always report BFL and principal plane shift H = EFL - BFL to the user. ```text BFL = EFL·(1 - (n-1)·T / (n·R1)) ``` ```text z_detector = T/2 + BFL ← never place at EFL from lens center ``` -------------------------------- ### SESSION_RAY_TABLE Object Structure Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/ray-table.md The schema for the ray table object, containing metadata, surface-specific ray data, and detector statistics. ```javascript SESSION_RAY_TABLE = { setupName: string, simulationTimestamp: string, totalRays: number, wavelengths: number[], surfaces: [ { surfaceId: string, surfaceName: string, partLabel: string, hitCount: number, hitPositions: [[x,y,z], ...], directions: [[dx,dy,dz], ...], amplitudes: [a1, a2, ...], beamFootprint: {width, height}, positionRange: {x:[min,max], y:[min,max], z:[min,max]}, averageAmplitude: number, maxAmplitude: number, }, ... ], detector: { surfaceId: string, raysReachingDetector: number, collectionEfficiency: number, beamFootprint: {width, height}, } } ``` -------------------------------- ### Analytical Result Template Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/optimization-workflow.md The required format for presenting the proposed change and the results of the analytical verification checks. ```text Proposed: [Component] [DOF]: [old] → [new] Predicted metric: [current] → [estimate] (target: [X]) Collision map: all gaps PASS — OR — Collision map: ⚠️ gap [A→B] = X mm (floor: Y mm) ``` -------------------------------- ### Collision Check Formula Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/optimization-workflow.md Formula used to verify that the gap between two adjacent components is greater than the defined collision floor. ```text gap(A→B) = proposed_front_B_position − back_A_position ``` -------------------------------- ### Compute axial gap between optical elements Source: https://github.com/3doptix/skills/blob/main/skills/3doptix-workflow/references/optimization-workflow.md Formula used to calculate the gap between two adjacent optical elements A and B to detect potential collisions. ```text gap(A→B) = front_surface_B_z − back_surface_A_z ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.