Add async autocomplete options and fetch lifecycle handling
Add async option fetching with caching, retries, debouncing, and loading state to AutocompletePrompt.
clack-async-autocomplete-options
Normalized profile
What this task asks for
Add async option fetching with caching, retries, debouncing, and loading state to AutocompletePrompt. Options must support existing forms (static array and synchronous function) without changing current behavior, plus async results. A loading property must be true while a fetch is in flight. Re-renders must only occur when the prompt is active (not during construction). Only the latest fetch result may be applied; stale results must not update state. A non-SWR cache hit or entering searchTooShort must invalidate any in-flight fetch (abort its signal and discard its pending result). Starting a new fetch must abort the previous signal. Errors with name 'AbortError' must be silently ignored (set loading to false, return without setting loadError). Non-abort failures must set loadError to a string. Fetches must be debounced by configurable debounceMs, defaulting to a sensible value (100-300ms) when omitted. Optional cacheResults with maxCacheSize and clearCache() must avoid redundant fetches.
Intent
- feature implementation
- performance optimization
- configuration tuning
- test and validation
Work surfaces
- cache
- configuration
- renderer
- library API
Technology
- Clack
Expected artifacts
- repository patch
What makes it difficult
- concurrency, cancellation, or distributed-state coordination
- specialized algorithmic or domain reasoning
- changes span multiple components or interfaces
Published evidence
Model × harness outcomes
Counts are tied to these exact configurations. Harnesses are not treated as equivalent across benchmarks.
- Models
- 13
- Configurations
- 41
- Trials
- 164
Showing 41 of 41 configurations
| Model | Harness | Effort | Result | Passes |
|---|---|---|---|---|
| claude-fable-5vertex_ai | mini-swe-agentpublished configuration | low | Mixed | 3/4 |
| claude-fable-5vertex_ai | mini-swe-agentpublished configuration | medium | Mixed | 3/4 |
| claude-fable-5vertex_ai | mini-swe-agentpublished configuration | high | Mixed | 2/4 |
| claude-fable-5vertex_ai | mini-swe-agentpublished configuration | xhigh | Mixed | 3/4 |
| claude-fable-5vertex_ai | mini-swe-agentpublished configuration | max | Mixed | 2/4 |
| claude-opus-4-8anthropic | mini-swe-agentpublished configuration | low | No passes | 0/4 |
| claude-opus-4-8anthropic | mini-swe-agentpublished configuration | medium | Mixed | 1/4 |
| claude-opus-4-8anthropic | mini-swe-agentpublished configuration | high | Mixed | 2/4 |
| claude-opus-4-8anthropic | mini-swe-agentpublished configuration | xhigh | Mixed | 1/4 |
| claude-opus-4-8anthropic | mini-swe-agentpublished configuration | max | Mixed | 2/4 |
| claude-sonnet-4-6anthropic | mini-swe-agentpublished configuration | high | Mixed | 1/4 |
| claude-sonnet-5anthropic | mini-swe-agentpublished configuration | low | No passes | 0/4 |
| claude-sonnet-5anthropic | mini-swe-agentpublished configuration | medium | Mixed | 2/4 |
| claude-sonnet-5anthropic | mini-swe-agentpublished configuration | high | Mixed | 3/4 |
| claude-sonnet-5anthropic | mini-swe-agentpublished configuration | xhigh | Mixed | 2/4 |
| claude-sonnet-5anthropic | mini-swe-agentpublished configuration | max | Mixed | 2/4 |
| gemini-3-1-pro-previewvertex_ai | mini-swe-agentpublished configuration | high | No passes | 0/4 |
| gemini-3-5-flashvertex_ai | mini-swe-agentpublished configuration | medium | Mixed | 3/4 |
| glm-5-2zai | mini-swe-agentpublished configuration | high | Mixed | 1/4 |
| glm-5-2zai | mini-swe-agentpublished configuration | max | Mixed | 1/4 |
| gpt-5-4openai | mini-swe-agentpublished configuration | xhigh | No passes | 0/4 |
| gpt-5-5openai | mini-swe-agentpublished configuration | low | Mixed | 1/4 |
| gpt-5-5openai | mini-swe-agentpublished configuration | medium | Mixed | 1/4 |
| gpt-5-5openai | mini-swe-agentpublished configuration | high | No passes | 0/4 |
| gpt-5-5openai | mini-swe-agentpublished configuration | xhigh | No passes | 0/4 |
| gpt-5-6-lunaopenai | mini-swe-agentpublished configuration | low | No passes | 0/4 |
| gpt-5-6-lunaopenai | mini-swe-agentpublished configuration | medium | No passes | 0/4 |
| gpt-5-6-lunaopenai | mini-swe-agentpublished configuration | high | Mixed | 1/4 |
| gpt-5-6-lunaopenai | mini-swe-agentpublished configuration | xhigh | No passes | 0/4 |
| gpt-5-6-lunaopenai | mini-swe-agentpublished configuration | max | No passes | 0/4 |
| gpt-5-6-solopenai | mini-swe-agentpublished configuration | low | Mixed | 1/4 |
| gpt-5-6-solopenai | mini-swe-agentpublished configuration | medium | Mixed | 1/4 |
| gpt-5-6-solopenai | mini-swe-agentpublished configuration | high | No passes | 0/4 |
| gpt-5-6-solopenai | mini-swe-agentpublished configuration | xhigh | No passes | 0/4 |
| gpt-5-6-solopenai | mini-swe-agentpublished configuration | max | No passes | 0/4 |
| gpt-5-6-terraopenai | mini-swe-agentpublished configuration | low | No passes | 0/4 |
| gpt-5-6-terraopenai | mini-swe-agentpublished configuration | medium | Mixed | 2/4 |
| gpt-5-6-terraopenai | mini-swe-agentpublished configuration | high | Mixed | 3/4 |
| gpt-5-6-terraopenai | mini-swe-agentpublished configuration | xhigh | No passes | 0/4 |
| gpt-5-6-terraopenai | mini-swe-agentpublished configuration | max | No passes | 0/4 |
| kimi-k2-7-codeopenrouter | mini-swe-agentpublished configuration | default | No passes | 0/4 |