MurphyA/hacker-news huggingface dataset:
by zljdanceholic | 2025-05-04 22:29:19+00:00
How can we search the wanted key information from 10,000+ pages of PDFs within 2.5 hours? For fact check, how do we implement it so that answers are backed by page-level references, minimizing hallucinations?

RAG-Challenge-2 is a great open-source project by Ilya Rice that ranked 1st at the Enterprise RAG Challenge, which has 4500+ lines of code for implementing a high-performing RAG system. It might seem overwhelming to newcomers who are just beginning to learn this technology. Therefore, to help you get started quickly—and to motivate myself to learn its ins and outs—I’ve created a complete tutorial on this.

We have a complete graph to explain its workflow where multiple tools are used: Docling for parsing PDFs, LangChain for chunking text, faiss for vectorization and similarity searching, and chatgpt for LLMs.

Besides, I also outline the codeflow, demonstrating the running logic involving multiple python files where starters can easily get lost. Different files are colored differently. The purpose of showing this is not letting you memorize all of these file relationships. It works better for you to check the source code yourself and use this as a reference if you find yourself lost in the code.

The original project of Ilya Rice design its RAG system for answering questions of annual reports from companies, so he only designed three types of question response format for that challenge: a name, a number, or a boolean. But to ask questions about technical stuff, we absolutely ask general questions like How does RoPE work? to know about some concepts and the like Therefore, I further modify the system logic to fit this need by customizing an AnswerWithRAGContextExplanationPrompt class and automatically matching the most related chapter and corresponding pages via searching through all faiss databases (only retrieve the top-1) The final performance is demonstrated below (not cherry-picked, only tested once).

- What's the steps to train a nanoGPT from scratch? The answer is:

Training nanoGPT from scratch involves several clearly defined steps. First, set up the environment by installing necessary libraries, using either Anaconda or Google Colab, and then download the dataset (e.g., tinyShakespeare). Next, tokenize the text into numerical representations and split the data into training and validation sets. Define the model architecture including token/positional embeddings, transformer blocks with multi-head self-attention and feed-forward networks, and layer normalization. Configure training hyperparameters and set up an optimizer (such as AdamW). Proceed with a training loop that performs forward passes, computes loss, backpropagates, and updates parameters, while periodically evaluating performance on both training and validation data. Finally, use the trained model to generate new text from a given context.

All code are provided on Colab and the tutorial is referenced here. Hope this helps!
by mmooss | 2025-05-04 22:29:37+00:00
> First of all, nowhere does he prove archers didn't volley fire. All he says is there's no written evidence of it

Proving a negative is difficult, but it is evidence that an historian of warfare has never seen it. If it happened much at all, there should be examples of it.

Edit: To quote the OP: "... as hard as it is to prove a negative, I will note that I have never seen a clear instance of volley fire with bows in an original text and so far as I can tell, no other military historians have either. And we have been looking."

> it still seems perfectly reasonable to me

Where's your evidence? "seems perfectly reasonable" leads to belief in witchcraft, the stars orbit the earth, leaches cure disease, the lack of germ theory, etc. That's why we modern humans require evidence.
by robocat | 2025-05-04 22:30:06+00:00
> they'll push so hard that the grid itself will change phase

That's a thundering herd problem: where all invertors have the same set-points and they all are synchonised to push in the same direction at once.

In networks, thundering herd problems are fixed by given each sender different random delays.

For power networks we could choose statistical methods to get individual solar generators to lead or lag so that the frequency becomes an aggregate vote.

Given that part of the blackout was due to large amounts of solar going offline at the same time, it's possible that all invertors with common software were tripped at the same set-point.

So trip conditions also need to be randomly fuzzy. E.g. if frequency drops below 49Hz +/- random spread of 0.5Hz.

Although it's difficult to match financial incentives against random variations (individual generators are incentivised to power outside of boundaries to keep getting paid, and a trip event can be expensive - due to restart costs).

Electricity market design is hard because the design needs to be resilient to perverse incentives.
Show HN: A social media network where users share prompts instead of posts
by ssuds | 2025-05-04 22:30:28+00:00
Social media these days feels like swimming through a feed of AI generated slop rather than actual human thoughts.

Sometimes I wonder what the prompts behind the posts are. I bet there's more creativity going into the prompts than the final content that actually gets shared.

What if people just shared their prompts, and the completion was rendered on-demand, client side?

Disclaimer: This is a vibe coded proof-of-concept, not a functional service, built in the no-code builder Mocha. It's seeded with a few fake posts. You can create your own posts but they're just saved locally on your own device. To run the completions, you'll need to drop in an OpenAI API key. It uses 4o-mini, so the API calls are super cheap.
by ttctciyf | 2025-05-04 22:30:35+00:00
> it's not propagated to other browsers signed into the same account, it explicitly says that in the settings page

Yeah, you are absolutely right & I misremembered - forgot I copied over my browser profile.

It is definitely a permanent setting for me though, on both laptop & desktop profiles, haven't had to re-set it since I discovered it. (Firefox/linux).

Maybe the difference is in handling multiple google accounts differently. My approach: I tend to create browser profiles for specifiec tasks; the youtube viewing profile (used daily) is permanently signed in to my (non-Premium) youtube account, but when I check my actual gmail mail (for example) which is a different google account, I do it on a different browser profile.

Apologies for confusion over propagation, anyhow & thanks for the correction!
by jerryseff | 2025-05-04 22:30:59+00:00
Even in college they always seemed like a waste of time. Cool to meet new people, but to "build" something and win was always a fools errand.

This was further enforced when I drove up to attend Hack the North at U Waterloo with a few friends from Boston. One of the contestants stayed up so late he tore a muscle in his eye and now has a permanent deformity / disability.

As an adult I'd simply never even show up to such an event, if my employer wants to pay me overtime sure - but I'd still say no.

Build cool things, get normal amounts of sleep. It's not about the clout its about improving as an engineer.
by xg15 | 2025-05-04 22:31:34+00:00
Yup. The whole thing should be treated as an extremely close near miss. They got it back up and running in a day, otherwise things could have gotten REALLY ugly.

(Though even in that hypothetical case - this wasn't a zombie apocalypse. The rest of Europe was still operating normally, so even in the worst case, there would have been ways to supply the population and restore order. But it would have been like an international response to a major natural disaster instead of only stressing out a few technicians.)
by spenvo | 2025-05-04 22:32:00+00:00
There is new reporting that a hacker has breached the parent company, TeleMessage, including live data being passed across servers in production.

https://www.404media.co/the-signal-clone-the-trump-admin-use...

It was marked as a DUPE of this discussion, despite being a major new development https://news.ycombinator.com/item?id=43890034 Hopefully that decision can be reconsidered
by philjohnson | 2025-05-04 22:32:54+00:00
Based on my understanding of what you're saying, here's my idea that I could build:

You would add variables in the interface, and there would be a secure sandbox in the client where you can call the API of your headless CMS, and with an sdk you could create PDF programmatically assigning the respective variables with values from your headless CMS API response. Then a button to print them. This keeps everything fully private in the browser while automating the process.

Would that work? For reference, what would you expect to pay for this if you wanted to go this route?
by cortesoft | 2025-05-04 22:33:40+00:00
I only think this is true if the hackathon is around projects that are part of or similar to the normal work. In those cases, they should be during work hours and treated as work.

My company 15 years ago or so did a hackathon with arduinos, where they provided a bunch of arduinos and hardware and food, but the projects we made were completely unrelated to work and served no practical purpose. My team made a Simon says game.

It was just for fun, there was no benefit for the company. I think those are fine.
by quuxplusone | 2025-05-04 22:34:14+00:00
Recently on HN: "The Gang Has A Mid-Life Crisis"

https://news.ycombinator.com/item?id=43860696

Hackathons are fun and productive when what you need to do/learn — something you haven't already done/learned — can be done/learned in a weekend. Once you graduate, there's a lot fewer of those things lying around. Quote:

> We need look no further than the "hackathon," that sad facsimile of the days when we were all learning the basics so fast that the world could be ours with just a day or two of focused effort. Hype up an exciting atmosphere, assemble some folks with so few attachments in life that they have time to spend all weekend at a hackathon, and this ritual will summon up the old gods. The hackathon is the proof that people believe this can work, and it is the proof that it doesn't.
by reillyse | 2025-05-04 22:34:25+00:00
So at this point there is a chain of three people who we have to believe and honestly you’ve left out whatever doctor was doing the imaging - usually a radiologist looks at the imaging and interprets it.

Unless they were doing a scan for “does my brain look like I took a bunch of ecstasy” the probability of the radiologist saying “it looks like the patient did a shit ton of ecstasy is close to zero” .

Secondly there is no characteristic markers for ecstasy use - it doesn’t leave a big X on the brain. This idea is like thinking somebody could look at an xray of a broken bone and name the person who caused the damage.

Lastly the story has the characteristics of a normal BS anecdote , with the allusion to authority (a doctor told me!) and it just so happens to dovetail really well with your life choices and validates you. So yea whiff of BS off this one.
by justinclift | 2025-05-04 22:34:50+00:00
I've found "Claude 3.7 Sonnet (Thinking)" to be pretty good at moderately complex code bases, after going through the effort to get it to be thorough.

Without that effort it's a useless sycophant and is functionally extremely lazy (ie takes short cuts all the time).

Don't suppose you've tried that particular model, after getting it to be thorough?
by kanavs | 2025-05-04 22:35:14+00:00
My company does a lot of hackathons and we support a decent number of hackathons in quantum computing throughout the world. And I have had the same sentiment in the quantum computing space as well and thinking through the reason for it, my sense is that 24-48 hours is not enough time to build something meaningful. This is not to say that absolutely cannot be done, but the chances of something cool being made are generally low. My guess is that this idea might hold in general, anything that can be built really quickly tends not to be too impressive and all impressive things tend to take longer. I have gotten to a point where, if I see something impressive, I have this nagging feeling, Was this completed here? or were you working on this for a decent amount of time and just took this opportunity to showcase it?
by djinnish | 2025-05-04 22:35:21+00:00
The vast majority of the time people question whether or not an image or writing is "AI", they're really just calling it bad and somehow not realizing that you could just call the output bad and have the same effect.

Every day I'm made more aware of how terrible people are at identifying AI-generated output, but also how obsessed with GenAI-vestigating things they don't like or wouldn't buy because they're bad.
by nkrisc | 2025-05-04 22:35:37+00:00
I've seen some cool hackathons run internally at some companies I've worked for. It was during work hours (paid) and managers set time aside for people who wanted to participate. Often it was something like, "we have all this data, what could we use it for?" and teams would often come up with some pretty cool projects based on the data.

At the end there was a big presentation that anyone in the company could attend and each team would present what they came up with.

Some of them eventually became products directly, or at least set the groundwork for future products.

So in a sense it was basically just "work", but it was driven by the individual contributors and not a top-down directive.
by jcul | 2025-05-04 22:36:23+00:00
Yeah you're totally right with this use case.

It feels like the information is there strewn across the internet, in forums, Reddit posts, stack overflow, specs, books. But to trawl though it all was so time consuming. With an LLM you can quickly distill it down to just the information you need.

Saying that, I do feel like reading the full spec for something is a valuable exercise. There may be unknown unknowns that you can't even ask the LLM about. I was able to become a subject expert in different fields just but sitting down and reading through the specs / RFCs, while other colleagues continued to struggle and guess.
by dalemhurley | 2025-05-04 22:36:36+00:00
I’m not really sure they ever made much sense. Going back 15-20 years ago, they were always poorly executed and was not for the devs.

The only exception was one I went to put on by Atlassian a long time ago which was a hardcore geek-vs-geek live coding night with lots of drinking and real prizes. This was before they went public and didn’t care about offending.
by palata | 2025-05-04 22:37:12+00:00
This article really resonates with me.

The very first time I enjoyed talking to someone in another language, I was 21. Then an exchange student, I had a pleasant and interesting discussion with someone in that foreign language. On the next day, I realised that I wouldn't have been able to do that without that foreign language. I felt totally stupid: I had been getting very good grades in languages for years at school without ever caring about actually learning the language. And now, it was obvious, but all that time was lost; I couldn't go back and do it better.

A few years earlier, I had this great history teacher in high school. Instead of making us learn facts and dates by heart, she wanted us to actually get an general understanding of a historical event. Actually internalise, absorb the information in such a way that we could think and talk about it. And eventually develop our critical thinking. It was confusing at first, because when we asked "what will the exam be about", she wouldn't say "the material in those pages". She'd be like "well, we've been talking about X for 2 months, it will be about that".

Her exams were weird at first: she would give us articles from newspapers and essentially ask what we could say about them. Stuff like "Who said what, and why? And why does this other article disagree with the first one? And who is right?". At first I was confused, and eventually it clicked and I started getting really good at this. Many students got there as well, of course. Some students never understood and hated her: their way was to learn the material by heart and prove it to get a good grade. And I eventually realised this: those students who were not good at this were actually less interesting when they talked about history. They lacked this critical thinking, they couldn't make their own opinion or actually internalise the material. So whatever they would say in this topic was uninteresting: I had been following the same course, I knew which events happened and in which order. With the other students were it "clicked" as well, I could have interesting discussion: "Why do you think this guy did this? Was it in good faith or not? Did he know about that when he did it? etc".

She was one of my best teachers. Not only she got me interested in history (which had never been my thing), but she got me to understand how to think critically, and how important it is to internalise information in order to do that. I forgot a lot of what we studied in her class. I never lost the critical thinking. LLMs cannot replace that.
by k310 | 2025-05-04 22:37:50+00:00
> The agency's website shared a list of accepted identification options, (below) including US passports, US passport cards, state-issued Enhanced Driver's Licenses (EDL), and more. However, in April, the TSA said that the temporary paper card given to applicants by the DMV would not be accepted.

Acceptable

https://www.tsa.gov/travel/security-screening/identification

The list of acceptable IDs is subject to change without notice. TSA strongly encourages you check this list again before traveling, so you do not arrive at the airport without acceptable ID.

Driver's licenses or other state photo identity cards issued by Department of Motor Vehicles (or equivalent) Beginning May 7, 2025, if you plan to use your state-issued ID or license to fly within the U.S., it must be REAL ID compliant. If you are not sure if your ID complies with REAL ID, check with your state department of motor vehicles. A temporary driver’s license is not an acceptable form of identification State-issued Enhanced Driver's License (EDL) or Enhanced ID (EID) U.S. passport U.S. passport card DHS trusted traveler cards (Global Entry, NEXUS, SENTRI, FAST) U.S. Department of Defense ID, including IDs issued to dependents Permanent resident card Border crossing card An acceptable photo ID issued by a federally recognized Tribal Nation/Indian Tribe, including Enhanced Tribal Cards (ETCs). HSPD-12 PIV card Foreign government-issued passport Canadian provincial driver's license or Indian and Northern Affairs Canada card Transportation worker identification credential U.S. Citizenship and Immigration Services Employment Authorization Card (I-766) U.S. Merchant Mariner Credential Veteran Health Identification Card (VHIC)

REAL ID

Starting on May 7, 2025, a state-issued driver’s license or ID that is not REAL ID compliant will no longer be accepted as a valid form of identification at airports.

Passengers traveling after this enforcement deadline should either travel with an acceptable alternative form of ID, like a passport, or enroll for a state-issued REAL ID through their state DMV offices.

Passengers who do not yet have their REAL ID or another TSA acceptable form of ID can expect to face delays, additional screening, and the possibility of not being allowed into the security checkpoint. This includes TSA PreCheck passengers.
by throwup238 | 2025-05-04 22:37:51+00:00
> Proving a negative is difficult, but it is evidence that an historian of warfare has never seen it. If it happened much at all, there should be examples of it.

Be very careful with that assumption. Brett Devereux (author of the blog) himself constantly points out that our historical sources are often very limited because they were written by the nobility who only wrote about their own social class, completely ignoring the majority of people actually involved in a military campaign or civic life. We know a lot more about the generals and cavalry than the foot soldiers, archers, or supply train.
by jjk166 | 2025-05-04 22:38:06+00:00
I don't think the article is arguing there would not be a starting point to archer fire. One would expect commanders to make some decision about when their forces would engage, and even without explicit command most soldiers would probably recognize the same point as being ideal to start firing. It might not be as sharp as a line of muskets, but odds are everyone would have shot an arrow before anyone got off their second.

But volleys imply a specific coordinated cadence. If you're just telling your troops to open fire, whether it be with bows or fire arms, that's not a volley.
by nkrisc | 2025-05-04 22:38:20+00:00
The volley could just be an emergent result borne from the fact that if an attacking army was outside the maximum range of archers, and then charged, all archers would have an enemy within a reasonable range nearly simultaneously. If every archer let loose when there was an enemy in range, the end result would be an initial large volley.

Not really scientific but you can see the exact same outcome in video games. After the initial synchronized volley, it becomes more of a constant barrage as each archer's differing rate of fire causes shots to become desynchronized.

Is it true? I have no idea, but it's hardly magical thinking. It's logical but could still be untrue for other reasons not assessed.
by Der_Einzige | 2025-05-04 22:38:32+00:00
Besides beam search and it's variants? (there are many including the little known but awesomely powerful constrained beam search: https://huggingface.co/blog/constrained-beam-search)

Does MBR (minimal bayes risk) sampling count?

Also there was this paper at ICLR which is relevant to this question: https://arxiv.org/abs/2410.03968

This paper basically claims that non-heuristic methods (like beam search) are harmful compared to the heuristic ones.
by mingus88 | 2025-05-04 22:39:22+00:00
This TM SGNL app is compatible with legit Signal clients and servers.

It’s also possible that they are using this app to archive chats that other parties _believe_ to be disappeared.

In other words, set your chats to disappear in 5 minutes and convince your target to dish some sensitive info. They think it’s off the record, but it’s instantly archived
by hayst4ck | 2025-05-04 22:39:43+00:00
> As general literacy declines, one of the consequences seems to be that words with multiple meanings or variations become compressed into a single vague meaning.

Words don't have objective meanings. Words are indirect references to ideas in your head. They are like named memory addresses that can be de-referenced. That's why "woke" can have different meanings to different groups of people who speak together. Words are sociologically derived, not objectively meaningful. Eventually these words can even become shibboleths which can be used to determine whether you are part of a group or not.

People deeply underestimate the power of linguistics, especially in the hands of those who wish to exploit it. Control/influence over language and it's mapping is political power.
by cwalv | 2025-05-04 22:40:54+00:00
This kind of "perf review" hacking works ~everywhere; how well it works correlates with how entrenched the organization is (i.e., how hard it is for new players to disrupt).

You don't have to play the game the same way to work there. But it helps to accept that others will play it, and manage your own expectations accordingly.
by musicale | 2025-05-04 22:41:39+00:00
> this ancient stuff is still supported and actively used.

It sort of warms my heart that code for the IBM 360 (now IBM Z) and the IBM PC (now x86 PC) can still run on modern hardware decades later.

On one hand, we're stuck with the legacy of the past. But on the other hand, we can build on things and don't need to reinvent them unnecessarily.