News for hackers. Stuff that matters.
Re:Ask HN: Overwhelmed with Non-Actionable Email by tornato7 on Wednesday May 17, 2023 @06:16PM (#35981954)
I 'll try to share this when ready but unfortunately it's a disaster of a Python notebook right now. The GPT API is pretty easy to use with the openai package, the harder part is parsing emails for their content and getting rid of HTML crap.

GPT-4 waitlist can be quite a lottery, but you should get decent results with GPT-3.5 with enough tweaking and allowing it some space to reason. Try something like this for the system prompt:

``` Analyze the importance and urgency of the given email chain. Respond in JSON Format:

{ "analysis": "This email is about a sale at Best Buy, which is not important", "is_important": false }

{ "analysis": "This is a personal email from Steve asking me to fix the copier. Sounds urgent.", "is_important": true }

```

Re:Ask HN: Overwhelmed with Non-Actionable Email by ineedasername on Saturday May 20, 2023 @02:17PM (#36014261)
Thanks, I may give it a shot with 3.5 and migrate when I get access. I'm not sure how 2FA will work with API access to my organization-managed g-suite gmail. Zapier doesn't seem to stumble over the need for 2FA that I have to go through IRL (which seems a potential security hole?) So maybe it won't be an issue if I write against the API (gmail) myself too. I think that's what I would have to do, if I use a simple python client then 2FA would almost definitely be triggered.
Re:Ask HN: Overwhelmed with Non-Actionable Email by tornato7 on Sunday May 21, 2023 @02:13AM (#36018454)
Yeah, just follow the Gmail API Python quickstart tutorial. You'll authorize your app to your account and then it can re-use the token without 2FA.