Commit Graph
292 Commits
Author SHA1 Message Date
rocky d6b614b8be refactor(concurrency): isolate ProviderConfig to the main actor and drop unneeded @unchecked Sendable
- ProviderConfig is now @MainActor instead of @unchecked Sendable; AppL10n reads the persisted UI language key directly so off-main string lookups stay valid.
- EnglishLearningStore serializes its read-modify-write with a type-wide lock (several instances share one defaults key).
- URLSession-only transports, GatewayGrantKeychainStore and Keychain conform to Sendable without @unchecked. UserDefaults/DeviceCheck wrappers keep @unchecked because those SDK types are not Sendable.
2026-10-20 23:00:12 +02:00
rocky 9a4107cef8 chore(home): remove the DEBUG host bundle probe card
Host identification has been verified on device; the temporary Home test card is no longer needed. The extension-side probe stays in place.
2026-10-20 23:00:11 +02:00
rocky 3d54098524 chore(version): read framework and test bundle versions from project.yml 2026-10-20 20:39:49 +02:00
rocky fd07c6e39e fix(keyboard): close librime on every hide to avoid 0xdead10cc kills
Hiding the keyboard on the typing surface kept librime's LevelDB userdb
LOCK open in the App Group, so RunningBoard killed the suspended extension.
Finalize the runtime on every hide (and when schema selection fails);
viewWillAppear re-prepares Rime in about 30-50 ms.
2026-10-20 20:20:07 +02:00
rocky f463f78296 chore(version): set repository version to 2.1.5 (build 125) 2026-10-20 20:07:35 +02:00
rocky 9e19060a8a chore(account): note why the Mac target compiles InvitePoster.swift 2026-10-20 20:07:35 +02:00
rocky a4c6102f5c chore(previews): record English feature previews and add App Store creative asset scripts 2026-10-20 20:06:37 +02:00
rocky ad79c2ea13 chore(flow): expand host-return whitelist and add a DEBUG host bundle probe
- Rebuild the return-to-host whitelist from the CN/US top charts plus Apple
  system apps; drop the canOpenURL pre-check (LSApplicationQueriesSchemes
  is capped at 50) and let open() report failure.
- Never record an OSG bundle id as the host to return to.
- DEBUG only: probe the host bundle id through the keyboard arbiter
  callback and surface the log on a Home test card. Release builds keep
  the previous behaviour (no host identification).
2026-10-20 20:06:36 +02:00
rocky d540a58594 fix(account): defer operation-error dismissal until the alert update ends 2026-10-20 20:06:36 +02:00
rocky 03bfbbe08b feat(account): add QR invitation poster and 8-character invitation codes
- Invite opens an appearance-matched poster with the app icon, inviter name,
  QR code, and short code; tap for a full-brightness QR view; save (add-only
  Photos access), share, or copy the link. Mac shows the poster in a popover
  and can save it as PNG.
- Accounts get look-alike-free 8-character codes. "I have a code" accepts a
  code, link, or pasted message during the server-defined binding window.
- Permanently rejected redemptions show a specific message and drop the
  stored code instead of retrying on every sign-in.
2026-10-20 20:06:36 +02:00
rocky eaacc35cf7 feat(styles): learn the personal reply style incrementally
Regeneration merges the on-device learned evidence with dictation and reply
choices since the last generation instead of re-reading only the newest
~2,500 characters. It unlocks after 500 new characters, fades traits that
stop getting support, and fully relearns styles without saved evidence.
2026-10-20 20:05:35 +02:00
rocky f71f598ac7 fix(keyboard): stop showing the edit hint after every insertion 2026-10-20 20:05:29 +02:00
rocky 1ddbd28371 feat(keyboard): show dictation progress as a fill on the microphone capsule 2026-10-20 20:05:21 +02:00
rocky be56d2210c fix(asr): keep recordings when streaming recognition fails or stalls
- Keep recording after a streaming ASR error and retry the captured PCM
  through batch ASR before reporting a failure.
- Treat an expired ASR wait as a stall so batch fallback still runs.
- Prime the managed Volcengine stream on mic touch and adopt it only while
  fresh and open.
- Auto-scroll the live transcript to the newest recognized text.
2026-10-20 20:05:08 +02:00
rocky f7a031cc1d test(manifest): register PolishStylesL10nTests in the polish group 2026-10-20 20:04:55 +02:00
rocky 7ae9dbcde7 Merge remote-tracking branch 'origin/main'
# Conflicts:
#	docs/index.html
#	docs/sitemap.xml
2026-10-07 11:19:12 +08:00
rocky ec963e3a79 docs(site): add Search Console verification meta, GA4 gtag, and website analytics notice 2026-10-07 11:16:29 +08:00
Rocky d5cf818134 docs(pages): restyle homepage in the logo's acrylic material
- One acrylic material in three thicknesses (canvas, panel, keycap) with grain and sheen
- Unify buttons and chips as rounded rectangles on a 10/14/24/32 radius scale
- Restrain green to logo, status, progress and the default badge
- Regroup sections: four-act story with a new hold-to-ask-AI clip, smoked privacy panel
  absorbing account info, platform reliability chips, centered FAQ, acrylic download panel
2026-10-01 14:03:18 +08:00
Rocky a9bf57ccf7 docs(pages): use real iPhone bezel and on-device keyboard recordings
Replace the HTML-drawn phone and keyboard mockups with Apple's iPhone 17 Pro
bezel and simulator recordings of the real keyboard extension (zh/en, light/dark).
Halve the marquee type and drop the credits image from the account section.
2026-10-01 13:23:57 +08:00
Rocky f3f0da707a docs(pages): match keyboard mockups to the real assistant UI
- Rebuild the story phone keyboard from AIKeyboardView: logo, AI/中文/EN
  tabs, translation and clipboard chips, mic capsule states (dictation red,
  hold-for-AI teal, busy spinner, inserted check), delete/space circles,
  return capsule, and undo/edit after insertion
- Replace invented tone chips with the real three reply cards (ordinary,
  formal, relaxed & playful) using the in-app demo copy
- Show the real copy flow: Paste plus ranked skill capsules in the top bar,
  "Finding events…" and "Adding to Calendar…" status text
- Replace the outdated clipboard-skills video (retired circular chips) with
  a live replica of the current top-bar skill flow
- Rework the hero capsule around the real mic capsule states
- Align FAQ, JSON-LD, and llms.txt wording with the shipped UI
2026-10-01 09:42:33 +08:00
Rocky b61b348cac docs(pages): redesign homepage motion and target voice-keyboard SEO keywords
- Move all canonical, hreflang, Open Graph, sitemap, robots, and llms.txt
  URLs to the custom domain https://osg.osglab.com/
- Put category keywords (AI 语音输入法, 嘴替输入法, Agentic keyboard) in
  the title, description, H1, section eyebrows, FAQ, and JSON-LD
- Add a 1200x630 social card and large-image Twitter card
- Add a scroll-driven three-act story (dictation, reply in your voice,
  agentic action), a live voice capsule, split-text headings, number
  counters, parallax media reveals, pointer spotlight and tilt, and a
  circular theme transition
- Keep the page fully readable without JavaScript and under reduced motion
- Point legacy redirect pages at sections that exist
2026-10-01 08:51:20 +08:00
Rocky ec67ae2777 Create CNAME 2026-10-01 08:12:34 +08:00
Rocky ffd5aa9377 docs(pages): replace site logo with the latest official icon 2026-09-27 20:23:13 +08:00
Rocky 503ef0ebe8 docs: shift core messaging to AI voice keyboard, voice double, agentic skills
Lead with “Say it. It's typed. Speaks like you. Acts for you.” across the
README and product page: the personalization story (learned style,
three-tone replies) moves ahead of typing, clipboard skills are framed as
agentic actions, and typing becomes the fallback capability.
2026-09-27 19:41:26 +08:00
Rocky ec1712f023 docs(pages): use the official rendered app icon for the site logo
Replace the approximated flat render with the actual Icon Composer
export (transparent corners), and version the favicon URL since browsers
cache site icons aggressively.
2026-09-27 19:33:06 +08:00
Rocky 239e635e88 docs(pages): bust Pages asset cache with versioned CSS/JS URLs 2026-09-27 19:27:54 +08:00
Rocky 4912529c13 docs(pages): redesign home as dark product stage with real footage
- Render the new Icon Composer app icon for favicon, nav, and og:image
- Hero uses the three-device visual on a dark stage; hand-drawn mockups
  replaced with on-device videos and real UI cards
- Add 2.1 selling points: personal style, three-tone replies, monthly
  usage calendar, EventKit skills export, guided trials, credit rewards
- Restructure service paths with on-device as the primary trust card
- Self-hosted inline SVG icons; remove dead Three.js assets and logo.svg
- Bump page version references to 2.1.0 (Mac source at 2.2)
2026-09-27 19:26:00 +08:00
Rocky 8c16bf67d8 docs(readme): refresh feature narrative and add three-device banner 2026-09-27 19:25:55 +08:00
Rocky fcd66b24d9 fix(clipboard): enforce plain-text output shape for Speak as Me
The speak-as-me skill inherited the Reply contract's JSON variants and
occasionally echoed the personal-style XML tags into the output. The
prompt now demands one ready-to-send plain-text paragraph, forbids JSON,
code fences, Markdown, lists, preambles, and multiple variants, and marks
the style block as prompt-internal packaging. Length follows the user's
natural voice instead of the mechanical ±20% cap.
2026-09-27 19:25:53 +08:00
rocky a2abfc5e8c fix: keyboard stability, host-only analytics, and auto-reply dedupe
- record analytics/usage only in the host app; the extension no longer opens the
  SQLite queues, so hiding the keyboard cannot hold WAL locks (0xdead10cc)
- sync clipboard history writes across processes so deletes made on one side
  are not reverted by the other
- guard memory-relief reentrancy on controller and telemetry sides to break
  the recursive crash loop
- resolve credentials off the main thread and migrate legacy keys once per
  install, so Keychain reads cannot be caught in the suspend window
- gate Volcengine ASR ping completion to once (SIGTRAP on double resume)
- treat same-text captures as the same logical copy and dedupe auto actions
  by content fingerprint within 30s, stopping Universal Clipboard storms
- realign version line to 2.1.0 (build 110)
2026-09-25 12:14:29 +08:00
Cursor AgentandRocky c0848a00de merge: style captions follow in-app language
Co-authored-by: Rocky <hkgood@users.noreply.github.com>
2026-09-21 00:05:35 +00:00
Cursor AgentandRocky 5fe07443fe fix(styles): resolve style captions through in-app language
Style card descriptions were passed to Text as raw String keys, so they
never went through AppL10n. Resolve them (and the editor title) with the
in-app UI language override, matching the rest of the host app.

Co-authored-by: Rocky <hkgood@users.noreply.github.com>
2026-09-20 23:10:03 +00:00
rockyandClaude Opus 5 0023741455 feat(app): add crash visibility, memory relief, and clipboard reply work
Squashes the working tree that had accumulated on cloud-agent. Two
strands of work, kept in one commit at the maintainer's request.

Crash and stability (this session):

- Subscribe to MetricKit so crash, hang, CPU, and disk-write diagnostics
  are recorded on device. Keyboard-extension memory kills are the most
  likely way a user loses the keyboard mid-sentence and iOS does not
  classify them as crashes, so they never reach App Store Connect.
- Upload those reports to POST /v1/analytics/diagnostics from internal
  builds only (local Debug and TestFlight), reusing the analytics
  installation identifier and skipping entirely when analytics are off.
  App Store builds keep everything on device.
- Shed the Chinese engine, English lexicon, and in-flight pipeline work
  at the 40 MiB and 48 MiB budget thresholds instead of waiting for a
  system memory warning that jetsam often preempts.
- Install audio taps with the input node's live format through one
  shared adaptive resampler, so an audio-route change mid-recording no
  longer raises an uncatchable format-mismatch exception. Covers the
  dictation preview and the Mac recorder, which still used the pattern
  the Flow capture path had already moved away from.
- Harden the librime bridge: never pass a nil string across a nonnull
  boundary when a user dictionary holds malformed UTF-8, null-check the
  engine API vector, and distrust a candidate count without its array.
- Guard the expanded candidate grid against a list that shrinks while
  the collection view is still laying out against the previous count.
- Resolve localized text without the App Group so the screen shown when
  that container is missing renders its message instead of crashing on
  launch, which is the one situation it exists to handle.
- Gate CI on the App Group and Keychain wiring that the keyboard
  extension hard-depends on, with a self-test proving the check fails.

Clipboard, reply, and semantics (pre-existing working tree):

- Unify the reply center, refresh keyboard AI features, and add native
  event and reminder exporters.
- Expand clipboard semantic routing with authored corpora and a
  product-blind holdout, plus the scripts that build and validate them.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-18 17:31:29 -07:00
rockyandClaude Opus 5 628e983794 merge: bring local uncommitted work onto the cloud-agent branch
Merges the wip/local-snapshot-20260901 safety commit (94 uncommitted files:
in-flight Account/Mac/Tip work, clipboard-semantics improvements, and the
feature-preview recording tooling) into the newer cloud-agent line.

Conflict resolutions:
- docs/*: honour the branch's deliberate removal in eac44da; drop the now
  dangling docs/archive/README.md that only pointed at the deleted files.
- CHANGELOG: both sides describe separate [Unreleased] features; keep both.
- ClipboardSkillSemanticRanker: take the branch's reply routing, which retires
  ranking playfulReply/acceptInvitation/... as separate skills in favour of
  ordinary/formal/playful variants inside one reply action. Keep the local
  link/phone/CJK-density work, which is orthogonal and still referenced.
- OfficialSkillCatalogTests: keep the local "installed exactly once" assertion;
  it matches the test's own comment and does not hardcode the default set.
- ClipboardSkillSemanticRankerTests: keep both sides' disjoint test functions;
  retarget the two link/phone cases at the branch's row, which no longer
  surfaces the retired specialised reply skills.

Verified: xcodebuild build succeeds and the 77 ranker/catalog/analyzer tests
pass.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-01 12:34:23 -07:00
rockyandClaude Opus 5 5d51c5bf77 chore: snapshot uncommitted local work before rebasing onto cloud-agent
Safety commit so the 94 uncommitted files in the working tree (in-flight
Account/Mac/Tip work plus the feature-preview recording tooling) survive the
move onto cursor/cloud-agent-1787824905651-vxuwc.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-01 11:28:07 -07:00
Rocky 3033ca5b33 fix(polish): gate test-build style generation at 1,250 chars and cap export at 5,000
Remove the test-mode unlimited personal-style corpus bypass and replace it with a real 1,250-character minimum gate. Production stays at 2,500. Training-corpus export and the diagnostics view now use a 5,000-character upper bound so the user's full private history never leaves the device in a single export.

- Add PolishStyleLearningCorpusBuilder.testBuildEffectiveCharacterCount (1,250) and trainingExtractionMaximumCharacterCount (5,000); trainingWindow(from:maximumCharacterCount:) accepts a custom cap.
- PolishStylesView: drop bypassesStyleLearningCharacterGate in favor of styleLearningMinimumCharacterCount, unify the ready/remaining text, remove the obsolete polishStyles.learn.testBuildReady key.
- PolishStyleCorpusExportStore: pass the 5,000 cap to trainingWindow and expose trainingExtractionMaximumCharacterCount in the export schema.
- FlowDiagnosticsSettingsView: show the export-sized (5,000-cap) corpus so the diagnostics match what the export ZIP actually contains.
- Tests: rewrite the export cap test for 5,000, add below-cap coverage, add trainingWindow(maximumCharacterCount:) unit coverage, and convert the old UI test into a regression test for the 1,250 test-build minimum.
- L10n: drop the testBuildReady string in en + zh-Hans, update diagnostics.corpus.ready to mention 5,000.
- CHANGELOG: bilingual entry under [Unreleased].
2026-08-30 12:09:06 +08:00
Rocky eac44daaf4 chore: drop unused provider logos, dead code, placeholder screenshots, and zero-reference planning docs
Removes assets and docs that are zero-references in the codebase and the
GitHub Pages site (scanned with ripgrep across *.swift / *.md / *.html).

Removed assets (no Swift / NSImage / UIImage / Image callers):
- 19 provider logo imagesets in OSGKeyboard/Assets.xcassets/:
  anthropic, apple, ark, codingplanx, cometapi, custom, deepseek,
  gemini, groq, mimo, minimax, mistral, moonshot, openai, openrouter,
  qwen, siliconflow, xai, zhipu
- docs/assets/badges/appstore-{en,zh}.svg (README badges in use are
  ios-{en,zh}.svg and macos-{en,zh}.svg)

Removed dead code:
- OSGKeyboardShared/Models/ProviderLogo.swift (no callers; only maps
  provider ids to the now-deleted logo imagesets)

Removed placeholder screenshots:
- docs/screenshots/6.1/ and docs/screenshots/6.7/ (10 PNGs generated
  by scripts/generate_screenshot_placeholders.py; never replaced with
  real captures, no README/HTML/Swift references)

Removed zero-reference planning / audit md (no code, no README, no
CHANGELOG, no GitHub Pages HTML references):
- docs/ACCOUNT_MANAGED_GATEWAY_TESTING.md
- docs/APPSTORE_METADATA.md
- docs/STOREKIT_TESTING.md
- docs/TYPING_KEYBOARD_BASELINE.md
- docs/ios-pip-voice-session-plan.md
- docs/keyboard-accuracy-plan.md
- docs/keyboard-memory-budget.md
- docs/local-asr-architecture.md
- docs/mac-parity-audit-2026-08-23.md
- docs/personal-dictionary-icloud-kvs-checklist.md
- docs/screenshots/README.md (described the deleted placeholders)

Kept (still referenced):
- Brand marks: OSGBrandMark, OSGLogoWide, OSGStatusMark, osglogo
- docs/TESTING.md (referenced by README.md / README.en.md / CONTRIBUTING.md)
- docs/FLOW_BLUETOOTH_TESTING.md (referenced by docs/TESTING.md)
- docs/RELEASE_NOTES_1.8.0.md (referenced by CHANGELOG.md)
- docs/assets/{badges,whats-new,logo,app-icon,hero-devices} (GitHub Pages)
- AppStoreScreenshots/, marketing/ (App Store /策划素材, not in repo refs)

Updated .gitignore so the deleted md cannot be re-added locally and
pushed back by accident. Asset placeholders, dead code, and unused
badges are also covered by patterns under the same rationale.

No version bump: this is a pure cleanup (chore:) with no user-visible
behavior change.
2026-08-29 22:15:52 +08:00
Rocky 2392cc8ac7 chore(repo): ignore new generated v6 artifacts
- Add Generated/, CorpusRegistry, v6 boundary/blind evaluation
  corpora, and sealed blessing benchmark review queues to the
  generated-artifact ignore list so they stay out of the source
  tree after reruns.
2026-08-29 11:51:45 +08:00
Rocky d23a3275a8 docs(ai): record AI and clipboard semantics updates
- Document the smart reply center, clipboard semantic v6 specialization,
  personal style generation fix, and durable Apple account session
  work in both English and Simplified Chinese.
- Update clipboard semantics README and open-training sources to
  reflect the v6 boundary, blessing, and consensus-adjudication
  corpora that the new release-gate pipeline consumes.
2026-08-29 11:51:45 +08:00
Rocky aa37067f79 chore(semantics): add v6 release gate pipeline
- Add reproducible v6 boundary, blessing, and consensus-adjudication
  corpora, plus the tiny-transformer trainer and v6 release-gate
  evaluator that gate every candidate on the deployed baselines.
- Wire consensus-label merging, product-policy anchor evaluation, and
  sealed blessing benchmark review with their pytest coverage.
- Refresh open-training corpus generation, iterative retraining runner,
  and random-holdout evaluation so v6 candidates can be benchmarked
  end-to-end.
2026-08-29 11:51:42 +08:00
Rocky b275b6b0d9 test(ai): expand AI flow and clipboard semantic coverage
- Cover reply-variant decision paths, scene-detector abstention, and
  the merged reply center stance catalog.
- Lock in clipboard semantic analyzer thresholds, complaint-only
  suppression, and existing-skill routing.
- Add durable session, refresh, and managed-gateway reliability tests
  for the Apple account path.
- Verify personal-style prompt derivation, low-confidence ASR
  tendencies, and Polish style learning against real corpus evidence.
- Exercise the assistant keyboard and Polish styles UI flows in
  end-to-end UI tests.
2026-08-29 11:51:25 +08:00
Rocky 3c10d73d7f feat(ai): unify reply center and refresh keyboard AI features
- Merge invitation, task, blessing, clarification, and empathy actions
  into a single Reply flow, with three fixed, clearly labeled stance
  choices whenever user intent must not be guessed.
- Refine clipboard semantic routing with bilingual schedule,
  confirmation, and follow-up models, conservative language thresholds,
  and explicit-assignment guard for complaint-only text.
- Persist Apple account refresh state, harden session recovery, and
  surface durable account diagnostics across keyboard and app.
- Derive personal-style prompts through two-stage corpus evidence and
  apply real low-confidence ASR tendencies instead of neutral templates.
- Localize the new reply center, clipboard semantics, and personal-style
  surfaces in both English and Simplified Chinese.
2026-08-29 11:51:21 +08:00
Cursor AgentandRocky f91a8f2456 test(semantics): strengthen consensus split auditing
Co-authored-by: Rocky <hkgood@users.noreply.github.com>
2026-08-27 10:52:58 +00:00
Cursor AgentandRocky 1ad8cb1edf chore(semantics): trim generated research artifacts
Co-authored-by: Rocky <hkgood@users.noreply.github.com>
2026-08-27 10:24:15 +00:00
Cursor AgentandRocky de9cd332a5 docs(semantics): record iterative retraining study
Co-authored-by: Rocky <hkgood@users.noreply.github.com>
2026-08-27 10:23:44 +00:00
Cursor AgentandRocky 00b90d9d28 chore(semantics): add iterative retraining research pipeline
Co-authored-by: Rocky <hkgood@users.noreply.github.com>
2026-08-27 10:23:41 +00:00
Rocky 42e6252f01 Cursor: Apply local changes for cloud agent 2026-08-27 18:01:46 +08:00
Rocky 39002336c0 feat(app): add flow diagnostics and refine interface
CI / macOS (push) Has been cancelled
CI / iOS / Extension (push) Has been cancelled
CI / SwiftLint (push) Has been cancelled
CI / Validate manifests (push) Has been cancelled
Improve failure recovery visibility, strengthen account-session handling, and make the cross-platform interface more consistent.
2026-08-26 14:40:06 +08:00
Rocky 1ee032bdb9 fix(account): merge durable session refresh
CI / macOS (push) Has been cancelled
CI / iOS / Extension (push) Has been cancelled
CI / SwiftLint (push) Has been cancelled
CI / Validate manifests (push) Has been cancelled
Preserve refresh idempotency and Apple credential revocation handling alongside the consolidated app updates.
2026-08-25 16:44:51 +08:00
Rocky 309d743fd3 fix(account): harden session refresh recovery
Persist refresh operation identity across failures and validate revoked Apple credentials so clients recover without unsafe token rotation.
2026-08-25 16:43:47 +08:00