Live data from Hacker News

Show HN: Nutrepedia – Nutrition info in 29 locales built with Clojure and Htmx

nutrepedia.com

21–30 of 35 posts

Re: Show HN: Nutrepedia – Nutrition info in 29 locales built with Clojure and Htmx

#21
Hello, nice work. I recommend running Chrome's built-in Lighthouse analysis tool specifically for accessibility. It will make some very helpful suggestions, like img alt text and colour contrast issues. One example that I eyeballed is the search bar–the background colour is pink and the text colour is yellow. Kinda hard to read :-)

Re: Show HN: Nutrepedia – Nutrition info in 29 locales built with Clojure and Htmx

#22

Hello, nice work. I recommend running Chrome's built-in Lighthouse analysis tool specifically for accessibility. It will make some very helpful suggestions, like img alt text and colour contrast issues. One example that I eyeballed is the search bar–the background colour is pink and the text colour is yellow. Kinda hard to read :-)

Thanks for the suggestions, they are valid concerns and I didn't know that about Chrome and Lighthouse. ty for the tips

Re: Show HN: Nutrepedia – Nutrition info in 29 locales built with Clojure and Htmx

#24
post #12
post #10

Very nice, what is the source of the data?

The only source currently for all data is the USDA's Food Data Central. I'm planning on adding more nutrient data sources in the near future.

Really. Because it looks less useful than its source.

If I search for Apple on food central, I get offered different types of Apple, like Fuji, honeycrisp, etc. with nutripedia I just get raw and cooked, which are within each type on food central.

In addition, nutripedia has a bunch of what looks like AI written text that is not particularly useful.

Writing an AI generated wrapper around something is not enough to be interesting. What do you see as your value add?

Re: Show HN: Nutrepedia – Nutrition info in 29 locales built with Clojure and Htmx

#25
post #23

The search results aren't hyperlinks? So middle clicking to open in a new tab does nothing. Odd choice.

Yeah, unfortunately, looks like they're ``. This is exactly what I tell everyone to avoid in htmx: https://dev.to/yawaramin/why-hx-boost-is-actually-the-most-i...

Re: Show HN: Nutrepedia – Nutrition info in 29 locales built with Clojure and Htmx

#26
post #23

The search results aren't hyperlinks? So middle clicking to open in a new tab does nothing. Odd choice.

Thanks for catching this. I had implemented the cards as HTMX-clickable divs, which broke native link behavior. I just shipped a fix: search result cards are now real anchor links, so middle-click/cmd-click/ctrl-click work normally while plain clicks still use the in-page HTMX transition.

Re: Show HN: Nutrepedia – Nutrition info in 29 locales built with Clojure and Htmx

#29
To be honest, there's still a long way to go.

First, what is the benefit of using this over something established like fddb or any already existing nutritional app?

Second, just translating the words for the units (like cup) doesn't work, because for example while "szklanka", the Polish word for glass, is indeed used in Polish recipes, there it means more something along the lines of "just grab whatever standard glass you have, it will be fine". It explicitly does not mean a unit of measurement of 236 ml.

Third, since you are using a US source you fall into the trap of US defaultism here. The way carbohydrates are labeled is different around the world and I think only the US does this weird thing where you have to manually subtract the dietary fiber from the total carbohydrates. This matters because you essentially give non-US users (and definitely users from the EU) plainly incorrect amounts of labeled carbohydrates.

All in all, cute project and good on you trying to tackle it. It looks okay though the AI smells bother me personally, but I don't think nutritional data is a great place to start for such a project and honestly I will not remember your site in a few days anymore.

Re: Show HN: Nutrepedia – Nutrition info in 29 locales built with Clojure and Htmx

#30
post #18

The search seems a bit weird. A search for salmon includes almonds in the results, and a search for spinach includes Tahitian taro.

Thanks for the feedback. Currently in addition to fuzzy matching the search system will match against synonyms broadly, so some unintended leafy greens would match Spinach as in your example results. I'll have to tweak the fuzzy matching a bit.

If you really want to dig into semantic fuzzy search you can check out the wordnet project and chatscript, which provides an excellent lem , stem , and parse tool which tags each search term with its term in wordnet, so you can match against a hierarchy of concepts, including category of food. There are other solutions I’m sure but I’ve always wanted to make a local db search with this, I think it would be more structured and debuggable thank straight vector similarity

https://github.com/ChatScript/ChatScript

Post reply on HN