cryptee / web-client

Cryptee's web client source code for all platforms.
https://crypt.ee
Other
444 stars 22 forks source link

[Feature Request] Photo Tagging #118

Closed frejaya closed 3 years ago

frejaya commented 3 years ago

Is your feature request related to a problem? Please describe. Cryptee has a beautiful interface, I like the photo area, and the pricing plans are reasonable given the amount of storage space you get, good fit for photography, but the actual features for photos are not as robust as those for docs and other Cryptee tools. I really want to use Cryptee for photos. It is not very effective to have to pick a single album for a photo or put it in multiple albums just to be able to find photos for a specific topic. It is even more challenging when you have thousands of nature photos.

Describe the solution you'd like I would like the ability to add multiple tags to my photos and search on those tags. I understand that Cryptee doesn't do any of the auto-tagging that sacrifices privacy and profits off your information, but if I could add my own tags it would help a lot. Cryptpad for example has a really nice tagging system you can apply to any item including photos. It aggregates your tags too so you can see what tags you've created, how many items use that tag, and you can search on the tags. I would want to be able to search multiple tags at once too since photos often have more than one tag.

johnozbay commented 3 years ago

Hi there! πŸ‘‹πŸ»

Thanks a lot for reaching out with this!

We're already working on a way to allow tagging photos manually! Very soon, much like the way you can select multiple photos and download, you'll be able to select multiple photos and tag them. What's taking us an extra bit of time is that all these pieces of information, tags etc will need to be stored encrypted, otherwise these tags could reveal a lot about our users. So it's taking us a little bit of extra time to make sure these tagging features are designed in a private way. (and yet are efficient enough to work with thousands and thousands of photos when you tag them)

And needless to say, once this feature is ready in a few months, you'll be able to search for tags just like the way you can search for your photos, in natural language. Like "photos with John" will show you all the photos that has the tag "John", or "Photos in Paris" will show all photos tagged "Paris" etc.

We're halfway there, and making steady progress every day! Stay tuned to our blog (blog.crypt.ee) for more updates! We'll send out a product announcement update / email as soon as this feature is ready for everyone to use! But needless to say, stay tuned here, and I'll shoot updates to this thread as well!

In the meantime, please feel free to let me know if there are any other features you'd like to see in Cryptee Photos, and we'll make it happen! Our focus for the year will be shipping a lot more features for Photos – so I'm all ears!

Thanks again for filing this, and all the very best ✌🏻

John

johnozbay commented 3 years ago

Hi there! You can now tag your photos! Here's the in-depth blog-post about how it works! https://blog.crypt.ee/tagging-for-photos-is-here/

Let me know what you think! Best, J

frejaya commented 3 years ago

Hi there! You can now tag your photos! Here's the in-depth blog-post about how it works! https://blog.crypt.ee/tagging-for-photos-is-here/

Let me know what you think! Best, J

YAY!!!! I love it so much! I can’t wait to start uploading and tagging my nature photos now! 😍 The only thing that would make it even better is if the search results returned the specific pictures and not just albums containing the pictures. Right now if I have an album full of bird pictures for example, and the photo is tagged with the specific bird species, searching for the species tag will just return the entire bird album which doesn’t narrow down the results.

johnozbay commented 3 years ago

Woohoo! πŸŽ‰ Really happy to hear! Thank you so much for this feedback! πŸ™πŸ»

The reason why we decided to do it this way vs show the photos themselves, has to do with on-device encryption and scale.

a) Basically you can theoretically go ahead and tag 1,000,000 photos "#bird", across all your albums. πŸ•Š (and right now search can find it all super fast, like under a few seconds, despite all the heavy encryption etc)

b) Unlike un-encrypted apps, all your thumbnails are decrypted on your device, in-memory, so the more items we show in the search results the more memory the app uses. You can quite literally crash a slow/average phone's browser by showing too many thumbnails at the same time (since all thumbnails will need to get decrypted first) 😞 and while it's relatively easy for un-encrypted apps to manage and recycle the memory by clearing some thumbnails, for us it's a bit more tricky due to on-device / in-memory encryption.

So this causes a few edge cases :

– What should happen if you search for "#bird", and there are thousands of photo results? πŸ•ŠπŸ•ŠπŸ•Š – How should search display all the thousands of photos? – Should results be paginated, or infinite scrolled? I'd love to make it infinite scroll, but again ... memory issues. – If results are paginated, server would need to know how many photos have the same tag, order and return results page-by-page. (we can't even easily order by filename either, because server doesn't even know the filenames haha) And knowing the number of photos with a specific tag means one more thing to consider when ghosting/summoning albums (since we wouldn't want a ghosted albums' photos to count towards those tags)

So we kinda couldn't come up with a perfect solution for this – yet –. Hence the current design. Otherwise even the code is ready to show individual photos in the results :

https://github.com/cryptee/web-client/blob/a2f2b168be0b61cfb02fea8377e6e150692e6d6e/source/js/photos/renderers.js#L114

I figured it's best to put it out there, let everyone start tagging while we figure out the best way to navigate search results, and recycle the memory without crashing the browser. – especially if you have too many photos matching the search results.

Question : – For example –  If Cryptee returned a maximum of 250 photo results, and you had to further specify your search query / add more tags etc to narrow the search down / see more photos, would that work for your use case? Asking to see if we should simply hard-cap the number of search results as a temporary solution.

Many thanks for this! 🐦

Best, J

frejaya commented 3 years ago

That definitely makes sense, I can see how encryption makes it more challenging πŸ˜† I’m super glad just to have the tagging at all, no other encrypted cloud photo tool does this at ALL so it’s super awesome!

Yes a cap wouldn’t hinder me too much, and 250 would work for my volume. I easily have thousands of bird photos but I only care about a fraction of those for tagging because I’m usually looking for the best ones, which are more like in the tens to hundreds. I also often have some idea of where I saw the bird so I would be able to narrow it down by multiple tags based on the species and location. πŸ¦†πŸ¦†πŸ¦‰

johnozbay commented 3 years ago

Hi there,

We've just released an update to address the tags searching shortcoming. You can now search for tags and if there are less than 100 matches, Cryptee will show you the individual photos, but if there are more than 100 matches, Cryptee will instead show them grouped together in albums.

This seemed like the smoothest best-of-both-worlds solution so far! Give it a try and let me know if you run into any issues! We'll be standing by to fix things up πŸ€“

Thanks for filing these,

All the very best, J

frejaya commented 3 years ago

Hi there,

We've just released an update to address the tags searching shortcoming. You can now search for tags and if there are less than 100 matches, Cryptee will show you the individual photos, but if there are more than 100 matches, Cryptee will instead show them grouped together in albums.

This seemed like the smoothest best-of-both-worlds solution so far! Give it a try and let me know if you run into any issues! We'll be standing by to fix things up πŸ€“

Thanks for filing these,

All the very best, J

It's so good!! I just tried it out, it's amazing! Just upgraded my account and can't wait to use the extra space and tag all the things!

One thing that might be a bug, not sure? When I search using tags, if I press the enter key after typing in the search box, it will say no results found, but if I just type it, the results are found. I.e. if I type #birds and press enter really fast, it will say there are no results. It's just a force of habit to press enter that's how I noticed. Not a big deal, just in case it matters! I am just remembering to not press enter, and if I accidentally press enter, then I backspace and retype the last character and it works fine.

johnozbay commented 3 years ago

Really happy to hear, and thanks for your paid support! Honored to have you on board πŸ™πŸ»

We are aware of the enter key bug you're referring to, and looking for a smooth fix for it. Basically, in order to search 'realtime' (search-as-you-type), and avoid a "start search" button (for the lack of a better word), we have to run the search every time you press a key.

The problem is this would be very computationally expensive if we started a new search after every key like : "b" "bi" "bir" "bird" "birds" etc

So instead, there's a ~500ms - 750ms timeout and the search starts 500-750ms after you stopped typing, so that we only have to deal with a computationally expensive encrypted search for one search term.

There seems to be a race condition bug with the way we handle search and it searches for "#bird" and not "#birds" etc ... so when Cryptee can't find anything, no matter how many times you press Enter it gets stuck.

We'll have a fix out for this soon. Sorry about these silly bugs, and thanks a million for reporting them πŸ™πŸ»