Better HN
topnewbestaskshowjobs
Log inSign up

klavinski

198 karma · joined Feb 19, 2018 (8y ago) · 45 submissions

Email: kamil (at) withcomment (dot) com

Website: https://withcomment.com/kamil

Submissions

1.

RenderFormer: Neural rendering of triangle meshes with global illumination(microsoft.github.io ↗)

276 points · by klavinski · 1y ago · 53 comments

2.

Open Source Icon Sets(icon-sets.iconify.design ↗)

17 points · by klavinski · 2y ago · 4 comments

comment 2y ago · link · parent

Steam250 [0] lists top games on Steam, and you can filter by tag and period. Additionally, it features a "hidden gems" section, with highly-rated but unpopular titles.

[0] https://steam250.com/

comment 2y ago · link · parent

I have built a Chrome extension to do this one year ago: [0]

Here is the list of technological problems:

1. When is a page ready to be indexed? Many websites are dynamic.

2. How to find the relevant content? (To avoid indexing noise)

3. How to keep an acceptable performance? Computing embeddings on each page is enough to transform a laptop into a small helicopter with its fans. (I used 384 as the embedding dimension. Below, too imprecise; above, too compute-heavy).

4. How to chunk a page? It is not enough to split the content into sentences. You must add context to them.

5. How to rank the results of a search? PageRank is not applicable here.

[0] https://www.youtube.com/watch?v=GYwJu5Kv-rA

comment 2y ago · link · parent

For the most straightforward nominative pattern matching, I would write a small match function:

    type A = { kind: "kindA", a: "dataA" }
    type B = { kind: "kindB", b: "dataB" }
    type Sum = A | B

    const match = <
        const V extends { kind: string },
        const C extends { [ kind in V[ "kind" ] ]: ( value: V & { kind: kind } ) => unknown }
    >( value: V, cases: C ) => cases[ value.kind as V[ "kind" ] ]( value ) as ReturnType<C[ V[ "kind" ] ]>

    // You check the type of result, change the type of value to A or B, make the cases non-exhaustive...
    const howToUse = ( value: Sum ) => {
        const result = match( value, {
            kindA: _ => _.a,
            kindB: _ => _.b
        } )
    }
You can test it here: https://www.typescriptlang.org/play?#code/C4TwDgpgBAglC8UDeU...

comment 2y ago · link · parent

I also built such an extension half a year ago [0]. The first iteration was a local-first natural-language full-text search for the browser history [1]. The second iteration was focusing on bookmarks [2].

None of these could spark enough interest to get feedback on what users want. I am sharing this experience so that you may study my attempt, if you want.

[0] https://getpinbot.com/

[1] https://www.youtube.com/watch?v=GYwJu5Kv-rA

[2] https://www.youtube.com/watch?v=PQh1qhvxZzc

comment 3y ago · link · parent

The most clever way I have found is through a mathematic structure with the same shape, i.e., a magic square:

  2 7 6
  9 5 1
  4 3 8
Here, if a triplet of one player's cells sums to 15, that player has won.

comment 3y ago · link · parent

If you want a similar extension which works without sending data to an external server, I made Pinbot as an experiment: https://getpinbot.com

comment 3y ago · link · parent

If you need a free alternative, the closest I know of is Metropolis[0] by Chris Simpson, although it is closer to Gotham.

[0] https://github.com/dw5/metropolis

comment 3y ago · link · parent

Good work, Altanis! After exactness, speed is certainly a priority. For my engine, I settled on Rapier, which also offers excellent performance (and determinism!). Do you think you could compare it with Kinetics?

Can you provide a high-level view of how you achieve that speed? I have also heard of eXtended Position-Based Dynamics as one of the latest improvements in physics engine. Do you have a perspective on that?

comment 3y ago · link · parent

Steam 250 [0] lists the top-rated games. You can filter by tags, price, date; but the most interesting category for me is the "hidden gems".

[0] https://steam250.com/

comment 3y ago · link · parent

Probably A/B testing. If I ran such a service, I would try different prompts to find the best, by checking the user behaviour: do they stop rephrasing the question? If so, the prompt was probably effective.

comment 3y ago · link · parent

Actually, a tab only sends its content to a unique offscreen document[0], and because of the single-threaded nature of JS, it works as a queue. So, you are right, throttling might be feasible without too much hurdle.

[0] https://developer.chrome.com/docs/extensions/reference/offsc...

comment 3y ago · link · parent

I often prototype in Greasemonkey myself, so I understand and agree with your point. However, there are many requirements (the AI model weighs 90Mb; I run it in a sandboxed iframe because it uses `eval` and I want to guarantee it would not do something bad; but initialising the iframe and loading the model on every page would be quite cumbersome; etc.) that made more sense in an extension.

comment 3y ago · link · parent

That information is very important for me, thank you.

Currently, to avoid computing the embedding of a sentence twice, I put them in a JS Map as a cache. I will find a way to empty the cache.

comment 3y ago · link · parent

How would you want to do it? Among the fields, have a checkbox "search among the bookmarks"?

comment 3y ago · link · parent

Yes, for the proof of concept. It is an arbitrary limit, as I am not completely sure how people would use the extension: it may fill the users' storage too quickly. In the future, I may consider adding a counter instead (removing websites which have not been visited/searched for X days).

comment 3y ago · link · parent

It does not work yet for PDFs, but I agree it would be amazing. Full-text search for one's library and documents!

Thank you for reporting the bug regarding Twitter. I will investigate.

comment 3y ago · link · parent

Thank you for letting me know, this information is crucial. The CPU-only compatibility of transformers.js might make it too slow for text-heavy websites. I will immediately study a way to throttle it.

However, the Chrome web store review might take some time to allow the update.

comment 3y ago · link · parent

VoidTools Everything is truly an excellent tool! I have indeed considered making a desktop version. It is more complex than the current proof of concept, but a private one-stop shop for AI search is definitely a great vision!

comment 3y ago · link · parent

Thank you the for the idea! I will add "allow a user-defined forbidden list of websites" to the ideas on the Discord server.

Regarding the privacy policy, you have a point: I did not put one on the website, as everything works offline, but people may indeed look for one.

comment 3y ago · link · parent

I targeted Chrome for the proof of concept because of its market share, but to be honest, I use and prefer Firefox as my default browser.

Manifest v3 is a remarkably hostile development environment: Google knows that people block advertisements with extensions and want to limit their scope. I had to adapt a lot of code, and as such, making it work cross-browser would require more than a few changes. But I understand your point and want Pinbot to run on more browsers, especially Firefox!

comment 3y ago · link · parent

No, that is what I find exciting! The AI model runs entirely on your device, and your data is never sent anywhere. You can inspect the Developer tools of the extension if you are interested: it works offline!

comment 3y ago · link · parent

The extension uses an SQLite database in the Origin Private File System[0]. Disabling the extension keeps the database, while removing it deletes the database.

Regarding performance, here is how it works: the extension accumulates page changes (thanks to a Mutation Observer[1], so I do not have to regularly read and compare the page) for some time, then checks if the sentences are in the database. Only unknown sentences are converted to embeddings.

The extension is CPU-only currently (WebGPU support was not merged yet in transformers.js), so it may be slow. I understand your concern, while that is a proof of concept, I consider a good performance to be vital to a good user experience.

[0] https://developer.chrome.com/blog/sqlite-wasm-in-the-browser... [1] https://developer.mozilla.org/en-US/docs/Web/API/MutationObs...

comment 3y ago · link · parent

Currently, yes. Allowing a user to crawl his recent history just after installing the extension is a great idea! I added it on the Discord server.

26.

Show HN: Pinbot – An extension to privately search one's browser history with AI(getpinbot.com ↗)

98 points · by klavinski · 3y ago · 36 comments

comment 3y ago · link · parent

See also the Higher-Order Virtual Machine for a functional, non-garbage-collected, and parallel runtime: https://github.com/HigherOrderCO/HVM

comment 3y ago · link · parent

Location: France

Remote: Yes, only

Willing to relocate: No

Technologies: currently using React (top 5% of LinkedIn test-takers), TypeScript (I can perform arithmetic with types), Next.js, Vite.js, TRPC, Tauri and Capacitor for cross-platform, CRDTs, other web technologies, Postgres, SQLite. Believer in statically-typed functional (like OCaml)/logic (like Prolog) programming, solvers (like Z3/CVC5), probabilistic programming.

Résumé/CV: https://drive.google.com/file/d/1HylyUPPZS2lcHLYTX0yI5OfdTsu...

Email: kamil (at) withcomment (dot) com

Hello, I am Kamil, an aspiring Renaissance humanist who became a frontend-leaning software engineer. Other than graduating as the top CS student from Sorbonne Université (1st/194 students), I have included my major professional achievements in my CV. Outside of work, I keep looking for the fundamental nature of things — through music theory, great tales, mathematics, or human virtue.

Nowadays, I want to focus on doing my best work, without other worries: work-life balance (ideally a 4-day week), pay, office politics, etc. Working with coworkers I can trust for their competence and integrity is important, as well as being challenged intellectually and keeping learning.

Emails require a salary range to be considered.

12