You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
TriggerRebuild no longer passes $fingerprint to FinalizeIndex. The $fingerprint parameter was removed from FinalizeIndex's constructor in the 0.3.0 rewrite, but TriggerRebuild was not updated. The md5 hash was silently flowing into the $memoryBudget slot and causing auto-rebuild jobs to always use the conservative memory budget, ignoring any explicitly configured budget.
Hygiene: Replaced md5(serialize($items)) with md5(json_encode($items, JSON_THROW_ON_ERROR)) in TriggerRebuild for content fingerprinting — json_encode is faster, produces deterministic output across PHP versions, and avoids serialize baggage.
Hygiene: Added === false error check to file_put_contents in DownloadPagefindCommand — failed .env writes now report an error instead of silently continuing.
Hygiene: Added TOCTOU-safe comments to intentional @unlink calls in CleanupCommand and DownloadPagefindCommand.
Hygiene: Added source-parse tests preventing reintroduction of bare serialize() and unchecked file_put_contents.
Added
LaravelCacheDriver behavior tests. New ScoltaCacheBehaviorTest: verifies the driver contract (get/set/miss/array values) and end-to-end handler+driver caching — second call to handleExpandQuery/handleSummarize serves from the in-memory Cache facade (AI called once), while cacheTtl=0 calls the AI service both times. Uses Cache::swap(new Repository(new ArrayStore)) so no real cache store is needed.
New ScoltaConfigIntegrationTest. Verifies the full pipeline: Laravel config → ScoltaAiService::flattenConfig() → ScoltaConfig::fromArray() → toJsScoringConfig() / toAiClientConfig(). Covers all 8 scoring fields, language, recency_strategy, all 5 display fields, feature toggles, AI client config (provider/model/base_url/omission), ai_languages, custom_stop_words, phrase proximity (defaults + overrides), cache_ttl (including 0), and all three prompt overrides.
AI configuration tests (Phase 5). Added test_ai_feature_toggle_defaults asserting that ai_expand_query, ai_summarize, and max_follow_ups have the correct default values (true, true, 3).
Scoring behavior tests (Phase 1). Extended test_scoring_section to assert language, recency_strategy, and recency_curve keys are present in the scoring config. Extended test_scoring_defaults to assert their default values. Added test_ai_languages_default confirming ai_languages is an array containing 'en'.