Skip to content
YA

Challenges

Beyond the happy path

Real problems from the projects — how they were found, approached and solved. Each story names its source document.

01AI integrationWakeel

A lead should exist only if the customer said yes

  1. 1

    Problem

    The AI employee collects a customer's name and phone to create a sales lead. Left to the model, a lead could be created from a misread 'yes', a half-finished conversation — or twice, when a background job retries.

  2. 2

    Investigation

    Three distinct failure modes: the model deciding consent, details changing between collection and confirmation, and at-least-once job delivery creating duplicates.

  3. 3

    Approach

    Move every consequential decision out of the model. Validate fields in code, read them back with a fixed template in the agent's dialect, store a draft on the conversation, and classify the next message deterministically.

  4. 4

    Solution

    Guards classify the reply as yes / no / unclear. Only yes runs create_lead — without the model deciding. The draft id becomes the lead id, so a retried job finds the lead already exists. The model still writes the summary; code decides whether there is anything to summarise.

Lessons learnedLet the model write; let code decide anything with consequences. Idempotency keys are cheaper than apologies.

Source: Wakeel · docs/ARCHITECTURE.md §2

02Performance optimizationCodePort

Choosing a renderer with a benchmark, not an opinion

  1. 1

    Problem

    An isometric city with rain, lightning, night lighting and ~300 entities had to hold 60 fps on a mid-range phone, within an 8 ms render budget. The usual advice says SurfaceView for games, Compose for UI.

  2. 2

    Investigation

    Two hosts were built around the same renderer and the same deterministic world, so the comparison isolated the host. Each ran 4 scenarios × 3 cold runs on a Snapdragon 6 Gen 1, measuring CPU per frame, vsync jank, GPU time and memory.

  3. 3

    Approach

    Bake every static object once at start-up into hardware-bitmap atlas pages; per frame, only depth-sorted blits, additive emissives and batched lines — with zero allocations, verified by a JVM test.

  4. 4

    Solution

    Compose Canvas won on every axis: CPU p95 2.5–2.7 ms under stress vs 9.3–9.9 ms, jank 0.17–0.34% vs 1.2–1.5%, no missed vsync. The decision and its tables live in ADR 0001.

Lessons learnedBuild the cheap version of both options and measure on a real device. Conventional wisdom is a hypothesis.

Source: CodePort · docs/adr/0001-renderer.md

03Complex debuggingKaff

The gesture worked in the lab and failed on a real phone

  1. 1

    Problem

    On an OPPO Reno13 F (Android 16), holding an open palm to accept a file often did nothing — while the Accept button always worked.

  2. 2

    Investigation

    Three independent causes: the camera only started when the offer arrived (a 1–1.5 s cold start inside a 5 s window); ColorOS silently expired 'this time only' camera grants; and a palm-facing check rejected hands arriving at an angle.

  3. 3

    Approach

    Treat the gesture as a convenience trigger, not a security check — the pairing code protects the transfer — and remove every source of latency before the user raises a hand.

  4. 4

    Solution

    The receiver warms the camera as soon as a sender pairs; the armed window grew to 7 s; the camera stage requests its own permission; the palm-facing check is off by default; and live hints say what the camera sees.

Lessons learnedField-test on the phones your users own. OEM skins change the rules that emulators follow.

Source: Kaff · docs/DECISIONS.md — Field testing round 1

04Multilingual UISUBZERO

When Arabic letters were cut off at the bottom

  1. 1

    Problem

    In the Arabic UI, the final م of 'التقويم' (calendar) and other descenders were clipped in headings.

  2. 2

    Investigation

    Inter carries no Arabic glyphs, so Arabic falls back to the system Arabic face — whose taller descenders overflowed Inter's tighter line box and negative tracking.

  3. 3

    Approach

    Make the type scale script-aware instead of patching individual screens.

  4. 4

    Solution

    Under Arabic, headings step down one size, every line gets at least 1.5× leading, and negative tracking is dropped. Arabic plurals carry all six CLDR categories, and the assistant normalizes diacritics and Arabic-Indic digits before matching.

Lessons learnedRTL support is not a mirror. Typography, plurals and input normalization are part of it.

Source: SUBZERO · README — Localization

05Machine learning evaluationDoS Detection & Response

A 0.999 model meets an attack it has never seen

  1. 1

    Problem

    The intrusion detector scored F1 0.9989 on held-out Wednesday traffic. The real question was what happens on Friday's DDoS, which it never trained on.

  2. 2

    Investigation

    Per-flow recall dropped to 0.633; XGBoost, slightly better on Wednesday, collapsed to 0.113. Error analysis showed misses were flows where the server returned no payload — genuinely ambiguous — and that the model was uncertain on them.

  3. 3

    Approach

    Choose the model on generalisation, not on the leaderboard number, and design the response layer around the model's uncertainty.

  4. 4

    Solution

    Random Forest became the main model. A separate ALERT band (0.50 ≤ p < 0.90) rate-limits uncertain sources, and three strikes ban an IP with generated firewall rules — so the response still stopped 92.3% of DDoS flows and banned all 30 attacker IPs, with no innocent host banned. (The dataset has no IPs; source addresses are simulated to exercise the policy.)

Lessons learnedPublish the number you might fail on. Systems, not single predictions, are what defend networks.

Source: DoS Detection · README §5–6

06Voice & real-time systemsNOVA

Letting people interrupt a speaking assistant

  1. 1

    Problem

    Natural conversation means cutting in. But Android's recognizer is endpointed rather than streaming, the assistant can hear its own voice, and the model must not believe the user heard words that were never played.

  2. 2

    Investigation

    Mapped every stage: token stream → sentence chunker → TTS, audio focus, echo cancellation availability, and which engines report word ranges.

  3. 3

    Approach

    One coroutine scope per turn holds playback, the model call and a watcher. Voice barge-in only with echo cancellation or headphones; otherwise tap-only and the mic stays closed.

  4. 4

    Solution

    On interrupt, playback stops first, then the model call. The stored message keeps only the heard text — cut at the current word — and history tells the model where the user cut in.

Lessons learnedState that the user perceived is the state that matters.

Source: NOVA · docs/DECISIONS.md — ADR-030