Commit graph

788 commits

Author SHA1 Message Date
323b7004ed Expose which search strategy produced each result
query_packages now assigns @search_sources - a hash mapping package
ids to the matching strategy that put them into the results: :exact,
:name_prefix, :name_contains, :semantic or :fulltext. The grid and
list views render a small badge with a humanized label per result,
making the search tiers observable. semantic_results() was folded
into search_packages() so each branch tags its own source. Adds the
rails-controller-testing gem for assigns() in tests.
2026-08-23 10:39:50 +02:00
3550a4e2e2 Harden vectorization task against per-package failures
A single failing package used to kill its whole worker thread silently
because only Vectorizer::Error was rescued per package. Now every
StandardError is caught and logged with class and backtrace, and the
embedding write is narrowed to update_column(:embedding) so the task
only ever issues a minimal UPDATE - it cannot touch any other column
or fire model callbacks. Progress stats no longer serialize database
writes through the mutex.
2026-08-23 00:11:52 +02:00
4d07f43a2e Show related packages based on description embeddings
Package pages get a "Related packages" section: a nearest neighbor
query against the package's own stored embedding (no external service
call), excluding the package itself. Packages without an embedding
render no section.
2026-08-22 23:47:42 +02:00
4948fe50e3 Add semantic package search via pgvector embeddings
Package text search now combines several strategies: exact name match,
name prefix promotion, compound word splitting ("sqlite browser" finds
"sqlitebrowser") and semantic nearest neighbor search over description
embeddings computed by an external embedding service (all-MiniLM-L6-v2,
384 dims) stored with the pgvector extension. Classic PostgreSQL
full-text search remains as fallback when the vector service is
unreachable. Gibberish queries without lexical overlap with the package
data return empty results instead of random matches.

Embeddings can be backfilled with bin/rails debshots:compute_vectors.

Also drops the unused lograge gem from the Gemfile.
2026-08-22 22:07:56 +02:00
1465733d64 Update gems and npm packages 2026-05-21 22:32:32 +02:00
c9248c0af4 fix typo 2026-03-01 22:11:43 +01:00
cf7178fb34 real fix for the UDD import problems – it was looking for /json/screenshots and large_image_url 2026-02-26 20:21:19 +01:00
b42d99022b typo - fixes https://salsa.debian.org/debian/debshots/-/issues/87 2026-02-26 01:15:22 +01:00
8e95e4f9fd re-add large_image_url attribute that the UDD expects 2026-02-26 01:03:54 +01:00
0669198233 safety check 2026-02-26 00:28:00 +01:00
8a13c92028 allow all Salsa users to be moderators 2026-02-09 01:34:34 +01:00
8bf3b9e3ca fix image URLs 2026-02-04 00:15:05 +01:00
9d0009b129 return approved screenshots only in public json. fixes #96 2026-02-04 00:10:26 +01:00
19f85a27d6 logic made nicer 2025-06-26 23:33:32 +02:00
9de9f93489 fix screenshot image in personal view 2025-06-23 00:46:48 +02:00
eb198a491b fixing /screenshot/:name 2025-06-23 00:46:23 +02:00
296e2d3f19 align icons properly with text 2025-06-18 02:06:50 +02:00
5ca2920d9d make sure that images are only delivered if the user has view permission 2025-06-18 01:36:17 +02:00
8d354785dc rubocop 2025-06-16 00:24:21 +02:00
b601b2bbb6 move shrine files out of public. use x-sendfile to send files for security. 2025-06-16 00:24:11 +02:00
8e66fb28db force break titles 2025-06-16 00:21:56 +02:00
e89b289c6f force break titles 2025-06-16 00:21:47 +02:00
0e5c20118f minimal layout change 2025-06-08 20:23:01 +02:00
892b298bf7 enforce breaking long titles to avoid ruining the grid layout 2025-06-08 20:22:47 +02:00
cc181c21ac salsa SSO button fixed by changing method to POST 2025-06-08 18:53:45 +02:00
9cdf7b76fd remains of fontawesome 2025-06-08 16:34:16 +02:00
662bcd00d3 chasing deployment problems 2025-05-16 08:56:14 +02:00
823f427760 remove icons on topbar because they are vertically strangely aligned 2025-05-14 22:22:21 +02:00
36e5187f1e larger text on topbar. 2025-05-14 22:22:05 +02:00
74fb99b2c5 debug 2025-05-13 01:19:58 +02:00
368d4b9c27 fix icon. re-enable javascript to define upload paths 2025-05-13 01:19:37 +02:00
1cd784cb14 recover broken apt:// link# 2025-05-13 01:19:15 +02:00
522cd56807 disable turbo. unwanted side effects. 2025-05-13 01:19:03 +02:00
882f7c4567 rebuild after removing unused Foundation classes 2025-05-11 21:26:51 +02:00
c3fecff878 change icons 2025-05-11 21:26:11 +02:00
d4196505b8 disable unused JS 2025-05-11 21:26:02 +02:00
98d47c060f use turbo:load instead of DOMContentLoaded 2025-05-11 21:25:14 +02:00
b7bcaaf47a loaded needed Foundation classes only 2025-05-11 21:25:00 +02:00
d76bf164f1 lucene icons added, styling fixed 2025-05-09 00:41:11 +02:00
9164e2a636 Moved from Fancybox to Photoswipe for click-to-zoom 2025-05-08 01:10:03 +02:00
aaf1eb34c4 typo 2025-05-04 23:59:41 +02:00
3f4266d19b rubocop 2025-05-02 00:38:59 +02:00
fa8a7fc77a Fix JS and JS-based image upload 2025-05-02 00:38:42 +02:00
36984ff1d4 lab 2025-04-11 09:39:33 +02:00
7cd9c68a10 trying to get JS and cssbundling to work 2025-04-09 22:47:05 +02:00
ac46c269b3 Fix CSS styling after Zurb update. Taken from old commit. 2025-03-16 16:51:36 +01:00
b5534b1900 Massive revamping for Rails 8 and Zurb 2025-03-16 00:44:43 +01:00
7f9502fdfb update to rails 8.2 2025-03-13 23:05:41 +01:00
25672aabb0 Update to Rails 7.2 2025-02-25 21:57:16 +01:00
2ec80b4bde Automatic rubocop cleanups 2025-02-03 01:08:08 +01:00