From galeharness-cli
Execute iOS Swift/ObjC work with Morph-X blueprint, transform, audit, and memory fingerprinting to reduce template-code repetition risk.
npx claudepluginhub wangrenzhu-ola/galeharnesscodingcli --plugin galeharness-cliThis skill uses the workspace's default tool permissions.
Execute work with the normal shipping discipline, plus Morph-X safeguards for iOS Swift/ObjC output. This reduces template-code repetition risk; it does not guarantee App Review success and does not replace real product, UI, content, metadata, or feature differentiation.
Creates isolated Git worktrees for feature branches with prioritized directory selection, gitignore safety checks, auto project setup for Node/Python/Rust/Go, and baseline verification.
Executes implementation plans in current session by dispatching fresh subagents per independent task, with two-stage reviews: spec compliance then code quality.
Dispatches parallel agents to independently tackle 2+ tasks like separate test failures or subsystems without shared state or dependencies.
Execute work with the normal shipping discipline, plus Morph-X safeguards for iOS Swift/ObjC output. This reduces template-code repetition risk; it does not guarantee App Review success and does not replace real product, UI, content, metadata, or feature differentiation.
<input_document> #$ARGUMENTS </input_document>
Determine how to proceed from <input_document>.
Plan document: read it completely in Phase 1 and treat it as a decision artifact.
Bare prompt: scan likely files, nearby tests, and local conventions; classify scope:
| Complexity | Signals | Action |
|---|---|---|
| Trivial | 1-2 files, no behavioral change | Setup, apply directly, and run relevant tests if behavior changed |
| Small / Medium | Clear scope, under ~10 files | Build a task list, then execute |
| Large | Cross-cutting, architecture, auth/payments/migrations, 10+ files | Recommend planning/brainstorming; if proceeding, build tasks carefully |
Run:
gale-task log skill_started --skill gh:work-x --title "${ARGUMENTS:-work-x}" 2>/dev/null || true
If gale-task is unavailable, skip silently. This must never block execution.
Before choosing a blueprint, retrieve related implementation context and historical Morph-X fingerprints:
hkt-memory retrieve \
--query "<task summary, iOS components, Swift/ObjC files, prior blueprint or strategy tags>" \
--layer all --limit 10 --min-similarity 0.35 \
--vector-weight 0.7 --bm25-weight 0.3
Use results only as context: extract constraints, avoided patterns, and prior blueprint/strategy fingerprints. Do not copy historical code shape. If no results or any command error occurs, proceed silently without blocking.
Query related work sessions:
hkt-memory session-search \
--query "gh:work-x <task title or iOS feature summary>" \
--limit 5
Use returned sessions as supplementary context for blueprint selection. If unavailable, continue silently; session search is non-blocking.
Read Plan and Clarify when a plan/spec path was provided.
Setup Environment
Create Task List
Choose Execution Strategy
Before writing or changing Swift/ObjC code:
.morph-config.yaml from the target iOS project root if present. If missing, use in-memory defaults and record config_source: default.For each task:
After Swift/ObjC code is produced and before final summary:
Apply safe transformation when the CLI is available:
gale-harness morph --apply --config .morph-config.yaml --report .morph-report.json
The transform must be semantics-preserving. If the command, SwiftSyntax, or ObjC adapter is unavailable, skip the transform, record the reason, and continue to audit fallback.
Audit similarity:
gale-harness audit --similarity --config .morph-config.yaml --report .morph-audit.json
Include AST/structure fingerprint, token n-gram, statement Jaccard, and control-flow approximation results when available. Missing baselines or tools are non-blocking and should be reported as degraded signals.
Handle thresholds:
.morph-config.yaml configures a blocking threshold and the audit exceeds it, stop before finalizing code and ask the user how to proceed.Run focused compile/test verification appropriate to the changed iOS project when available. If no Xcode or Swift test target is runnable, state the gap.
After implementation and Morph-X audit, store a concise memory record:
hkt-memory store \
--content "<summary with repo-relative files, blueprint constraints, strategy fingerprint, audit status, degraded fallback notes>" \
--title "<work-x title>" \
--topic "work-x morph blueprint strategy fingerprint" \
--layer all
Store only summaries, tags, and fingerprints; do not store full source code. On error, note it as non-blocking and do not fail the workflow.
Return:
## Work-X Summary
**Completed**: [what changed]
**Blueprint**: [constraints and strategy fingerprint]
**Morph Apply**: [report path or degraded reason]
**Similarity Audit**: [report path, threshold result, blocking/warning decision]
**Tests**: [commands run and results]
**Compliance Boundary**: Reduces template-code repetition risk; does not guarantee App Review success.
Run gale-task log skill_completed 2>/dev/null || true. If unavailable, skip silently.