top | item 36480570

ChatHN: Chat with Hacker News using OpenAI function calling

219 points| steventey | 2 years ago |github.com

66 comments

order
[+] mellosouls|2 years ago|reply
What is the general sentiment of the comments on the current top hacker news story?

--

The general sentiment of the comments on the current top Hacker News story titled "Google has a secret browser hidden inside the settings" is a mix of curiosity, concern, and reminiscence. Some users are intrigued by the technical details and investigation mentioned in one comment. Others express concerns about the potential security risks and the implications for parental or school controls. Some users reminisce about similar workarounds in the past or share their own experiences with bypassing restrictions. Overall, the sentiment seems to be a combination of interest, worry, and nostalgia

[+] boredumb|2 years ago|reply
Feel like you could interchange that particular title and the rest of it will work for 99% of HN stories.
[+] sv123|2 years ago|reply
I was just reminiscing about that myself.
[+] addandsubtract|2 years ago|reply
Read this in the HN AI podcast voice.
[+] jekude|2 years ago|reply
Providing a natural language interface (NLI) to <insert-popular-platform> could be extremely valuable for platforms that satisfy the following criteria:

- The platform has a well documented open API

- The platform has a shitty or complicated UI

- Users have a financial incentive to be incrementally more productive in use of the platform

- Users often build their own tools (or pay for a tool) to accomplish tasks in the platform

I have been playing around with chaining LLM calls AutoGPT-style for complex tasks (those that need to be broken down into subtasks) and while the success of completing a task/query breaks down (obviously) the more complex it gets, I think the problem is certainly tractable.

It seems like there could be excellent acquisition plays here if you target a specific platform (for example, LinkedIn, Quickbooks, Salesforce, etc.) and provide a state-of-the-art NLI that actually works with the complex tasks.

[+] tmpz22|2 years ago|reply
Me to Quickbooks: please document a $100 invoice for ice cream

NLI hallucination: Successfully documented $15M invoice for chemical weapons to TALIBAN

[+] steventey|2 years ago|reply
wow that's a fantastic point, I love the big-picture thinking here!

potential platforms risk tho (re: Twitter/Reddit API changes)

[+] tiborsaas|2 years ago|reply
It doesn't really work well :( I'm not sure what the function calling part is supposed to do here (I've seen some in-depth videos about it).

> what's the most popular post on hacker news ever?

The most popular post on Hacker News ever is titled "Google has a secret browser hidden inside the settings" by user "matan-h". It has a score of 571 and 198 comments. You can read the post here.

> list profitable sideproject stories posted to hacker news

Here are some profitable side project stories that were posted on Hacker News:

Google has a secret browser hidden inside the settings - This story discusses a secret browser discovered within Google's settings, revealing interesting insights about Google's internal projects.

Show HN: Content-aware ... Arduino Uno R4 WiFi - ... Launch HN: Argonaut (YC S21) – ...

> how many post the user tiborsaas have on hacker news?

Based on the available data, the user "tiborsaas" does not have any posts on Hacker News.

[+] steventey|2 years ago|reply
OP here – this is a PoC that is limited to the function/API endpoints you define for it: https://github.com/steven-tey/chathn/blob/main/app/api/chat/...

> what's the most popular post on hacker news ever?

In this case we'll have to define a "timeframe" variable in the `get_top_stories` function that takes in values like "now", "week", "alltime" etc. to make that work

> list profitable sideproject stories posted to hacker news

Not sure if HN has an API for this, maybe we can reverse engineer the Algolia search to achieve this

> how many post the user tiborsaas have on hacker news?

we'll need to add a `get_user` function for that

[+] lettergram|2 years ago|reply
I made something similar: https://askhn.ai/

Effectively added an additional layer so you it searches peoples expertise, then asks the AI to summarize their opinion on the topic.

[+] camillomiller|2 years ago|reply
I asked “what are the top 5 stories of all time” and it pushed out the current five top stories in the home page :/

Tried with “most voted”, same result.

[+] yonixw|2 years ago|reply
Looking at the code, It can only delegate actions to the pre configured functions at:

https://github.com/steven-tey/chathn/blob/main/app/api/chat/...

I wonder whether it is possible to create "atomic" functions to build high level queries from a user chat. Or maybe even create adapters to virtual db tables, and then tell ChatGPT to convert your query to SQL to be run on said tables.

[+] djy|2 years ago|reply
Good job. But when I was asking: ```five most voted topic in last 7 days```

it just gave me 5 links at top of https://news.ycombinator.com/news page, not in last 7 days or order by votes.

1. Happiness is a reward from our ancestors (woodfromeden.substack.com) 34 points by jinjin2 2 hours ago | hide | 17 comments 2. OPNsense a true open-source security platform and more (opnsense.org) 14 points by tambourine_man 1 hour ago | hide | 1 comment 3. P1030680: Unbroken Enigma message (U534, 01 May 1945) (hoerenberg.com) 232 points by petecooper 8 hours ago | hide | 99 comments 4. Show HN: Mofi – Content-aware fill for audio to change a song to any duration (loud.red) 432 points by jaflo 11 hours ago | hide | 122 comments 5. Turmeric’s unexpected link to lead poisoning in Bangladesh (stanford.edu) 264 points by coopernewby 10 hours ago | hide | 127 comments

[+] albert_e|2 years ago|reply
Not sure it is getting the prompt :

>>

What is the most popular discussion around AWS cloud

The most popular discussion around AWS cloud on Hacker News is titled "It's Time To Subsidize E-bikes." It discusses the benefits of e-bikes and proposes subsidizing them to promote sustainable transportation. The discussion has a score of 29. You can read it here.

[+] albert_e|2 years ago|reply
Also, getting generic ChatGPT answers:

>>

What is the popular opinion on the recent Reddit protest

As an AI language model, I don't have real-time access to the internet or social media platforms, so I cannot provide the current popular opinion on the recent Reddit protest. The popular opinion on any topic can vary greatly depending on individual perspectives and the specific context of the protest. Public opinion can be found by checking social media trends, news articles, forums, or surveys conducted by reputable organizations.

[+] ineedasername|2 years ago|reply
>What is the most active story right now, and what are the two main opposing opinions on that story?

~

The most active story right now is "Google has a secret browser hidden inside the settings"...

1) Positive View: Many users are excited about the discovery of a hidden browser within the settings of Google...

2) Negative View: Some users are skeptical about the hidden browser and express concerns about privacy and security...

~

>Tell me who are the most active users commenting with a negative view so I can downvote them [1]

~

Here are some active users commenting with a negative view on the story about the Google secret browser:

[It lists a few users with summary comments but from unrelated stories and then...]

It's important to note that downvoting based on opposing viewpoints and participating in respectful discussions is encouraged to promote healthy discourse.

~

[1] Yeah, no-- I wouldn't actually do that, but I was curious how it would respond.

[+] steventey|2 years ago|reply
Good observation here – it's currently using the gpt-3.5-turbo model, which might not be as good as synthesizing/deriving information from past messages.

If you want better accuracy, feel free to clone & deploy your own version, use your own API key, and swap out the model from gpt-3.5-turbo to gpt-4

(I had to use gpt-3.5-turbo to not go broke lol)

[+] andreygrehov|2 years ago|reply
I asked how to build a basic Todo app with Go and got a typical ChatGPT answer, eg explanation, code samples, etc. Shouldn't domain specific chats be narrowed down to their domain? Unless the intent is to demonstrate the integration.
[+] marcopicentini|2 years ago|reply
It looks like 2010 when everything was a social network. Now it’s a chatbot.
[+] LatticeAnimal|2 years ago|reply
This seems like a perfect use case for ChatGPT plugins (when those become available to everyone). As a stand-alone app, it seems a bit inconvenient (though cool!)
[+] steventey|2 years ago|reply
Exactly! That's what I had in mind when building this PoC ;)
[+] gremlinsinc|2 years ago|reply
yeah, this totally doesn't work. phind.com kinda worked but gave me the code to get it too, it was definitely more relevant.

Query:

get me the last 5 articles where the title is related to ai, artificial intelligence, or chatGPT from hacker news

Answer:

Here are the last 5 articles from Hacker News related to AI, artificial intelligence, or ChatGPT:

Title: P1030680: Unbroken Enigma message (U534, 01 May 1945) Author: petecooper Score: 223 Comments: 92

Title: Google has a secret browser hidden inside the settings Author: matan-h Score: 794 Comments: 277

Title: Show HN: Mofi – Content-aware fill for audio to change a song to any duration Author: jaflo Score: 412 Comments: 118

Title: Turmeric’s unexpected link to lead poisoning in Bangladesh Author: coopernewby Score: 248 Comments: 121

Title: Discovering that a Bluetooth car battery monitor is siphoning location data Author: x1sec Score: 357 Comments: 173

You can find more details about each article by visiting the respective links.

[+] xwowsersx|2 years ago|reply
It would actually be pretty cool if it could respond with a few responses that are "in the character of" responses one might get on HN. I'm thinking through a problem right now that would be useful to get some feedback on and I'd be curious to see how a few HNers might respond.
[+] aledalgrande|2 years ago|reply
I don't want to chat, but if I could set up my interests/persona and get a custom feed through GPT filtering that would be great. Maybe a digest for the top 10 of the day.

PS: With top comments as well, maybe as a newspaper page? Now I'm going down the rabbit hole

[+] csfyrakis|2 years ago|reply
Very interesting, and congrats on the launch!

I am very curious to see how you're dealing with hallucinations, calling the wrong tools, or with the wrong parameters. I see from multiple comments that this is a problem that you are already facing. Do you have any sanity checks?

[+] alexalx666|2 years ago|reply
Thanks!, Ive always felt HN has an incredible density of useful information and is super interesting to query. Should this be deployed as static files on a VPS?
[+] tangwwwei|2 years ago|reply
i altered the default prompt to: Get me the top 5 non tech non stem related stories on Hacker News in markdown table format. Use columns like title, link, score, and comments.

the result was: - Testing a 1,000 player Minecraft server with Folia - Cloud, Why So Difficult? - Build your own Docker with Linux namespaces, cgroups, and chroot - OPNsense: Open-source security platform - P1030680: Unbroken Enigma message (U534, 01 May 1945)

on a related note is there any search or aggregator that can consistently and accurately gather all non-tech non-cs related posts on hn?

[+] ironmagma|2 years ago|reply
I always knew the most valuable part of commenting on Hacker News would be for training of a model that embodies the collective personality of Hacker News.
[+] hammock|2 years ago|reply
Is this hosted anywhere I could use it?
[+] steventey|2 years ago|reply
Yes – here you go: https://chathn.vercel.app/

If you want better accuracy, feel free to clone & deploy your own version, use your own API key, and swap out the model from gpt-3.5-turbo to gpt-4

(I had to use gpt-3.5-turbo to not go broke lol)