Hacker GitHub

← All repos

openai/openai-python

View on GitHub ↗ ★ 32,015 Python

The official Python library for the OpenAI API

38 mentions on Hacker News by 32 people: 11 stories, 27 comments · first 2023-03-01 · latest 2026-10-19

Mentions per year 38 mentions · busiest year 2023 (20)
20082026
  1. …wanting to. The OpenAI Python library makes these interactions really straightforward to implement: https://github.com/openai/openai-python
  2. ▲ 209
    Migrating to HTTPX2
    story by tosh · 2026-08-28 · 95 comments
  3. …blog that flagged this fact https://blog.tymscar.com/posts/openaiunmergeddemo/ and the issue: https://github.com/openai/openai-python/issues/2472
  4. All main OpenAI SDK libraries are made with stainless[0][1]. [0]: https://github.com/openai/openai-python [1]: https://github.com/openai/openai-node
    comment by hobofan · 2026-05-18 · in Anthropic acquires Stainless
  5. All main OpenAI SDK libraries are made with stainless[0][1]. [0]: https://github.com/openai/openai-python [1]: https://github.com/openai/openai-node
    comment by hobofan · 2026-05-18 · in Anthropic acquires Stainless
  6. …going to trust it based off of the known native limitations with Azure's OAI implementation. [0] https://github.com/openai/openai-python/issues/2300
  7. ▲ 2
    WebSockets for Responses API
    story by armcat · 2026-02-23 · 0 comments
  8. ▲ 1
    Uploading PDF via Files API and using in Streaming gives 400 bad request
    story by peterkelly · 2025-08-08 · 0 comments
  9. Issue https://github.com/openai/openai-python/issues/2472 they worked and promised to submit the PR after the show is still open. Just saying.
    comment by nullorempty · 2025-08-07 · in GPT-5
  10. The github issue showed in the livestream is getting lots of traction: https://github.com/openai/openai-python/issues/2472 It was (attempted to be) solved by a human before, yet not merged... With all the great coding models OpenAI has…
    comment by hrpnk · 2025-08-07 · in GPT-5 for Developers
  11. httpx to make the call yourself, or if you really want a wrapper the openAI python https://github.com/openai/openai-python .
  12. …on OpenAI's open-sourced SDK [1] and API spec? [0] https://docs.x.ai/docs/guides/migration [1] https://github.com/openai/openai-python
  13. …of the Python library examples in one go from the old chat completions to the new resources APIs: https://github.com/openai/openai-python/commit/2954945ecc185...
    comment by simonw · 2025-03-11 · in New tools for building agents
  14. …Responses API. We have not removed this! It should still work just like before! Here's an example: https://github.com/openai/openai-python/blob/main/examples/r...
    comment by sdcoffey · 2025-03-11 · in New tools for building agents
  15. ▲ 1
    OpenAI adds new o1 models
    story by rkwasny · 2024-09-12 · 0 comments
  16. …Here are some example repos produced by Stainless: 1. https://github.com/openai/openai-node 2. https://github.com/openai/openai-python 3. https://github.com/cloudflare/cloudflare-go 4. https://github.com/Modern-Treasury/modern-treasury-java
    comment by rattray · 2024-04-24 · in The Stainless SDK Generator
  17. …issues with the current model architecture, or at least how it's been updated: See the issue: https://github.com/openai/openai-python/issues/1310 See also the original thread on OpenAI's developer forums (…
  18. ▲ 280
    Show HN: GritQL, a Rust CLI for rewriting source code
    story by morgante · 2024-03-20 · 54 comments
  19. …references to their ChatML spec from their GitHub repo. This is what it said in an earlier commit: https://github.com/openai/openai-python/blob/2942bf4bb635b1e...
    comment by minimaxir · 2023-11-21 · in Claude 2.1
  20. Yes, v1.1.1 comes with API changes related to DevDay announcements: https://github.com/openai/openai-python/commit/baa9f07f5b503... and small improvements/fixes
  21. …want to upgrade the package before following the instructions you were following. More info here: https://github.com/openai/openai-python/discussions/631
    comment by petercooper · 2023-11-06 · in New models and developer products
  22. ▲ 3
    OpenAI Python v1 Released
    story by rattray · 2023-11-06 · 0 comments
  23. ▲ 2
    OpenAI-Python v1.0.0
    story by saeedesmaili · 2023-11-06 · 0 comments
  24. …in the GitHub repo was updated to play nice with the new v1.0.0 of the package: https://github.com/openai/openai-python/
    comment by minimaxir · 2023-11-06 · in New models and developer products
  25. …of their openai Python package (with breaking changes) to PyPI, so some stuff is happening there: https://github.com/openai/openai-python/commit/08b8179a6b3e4...
  26. …API - I guess the reason they don't allow you to is because of issues with jailbreaks/safety. [1] https://github.com/openai/openai-python/blob/main/chatml.md [2] https://tiktokenizer.vercel.app/
    comment by Tiberium · 2023-10-14 · in ChatGPT’s system prompts
  27. ▲ 1
    OpenAI-Python v1.0.0 Beta
    story by saeedesmaili · 2023-10-12 · 0 comments
  28. Yes. It's documented for their Azure support here. https://github.com/openai/openai-python#microsoft-azure-endp...
  29. ▲ 1
    OpenAI Python Library v1.0 beta introduces breaking changes
    story by gregorymichael · 2023-10-06 · 0 comments
  30. ▲ 2
    OpenAI's Beta Python SDK sees a rewrite using httpx, drops Azure
    story by sjnair96 · 2023-10-06 · 1 comment
  31. …determinism is reduced like this, it's impossible to say it's not getting worse :( [1] https://github.com/openai/openai-python/issues/399
    comment by jw1224 · 2023-09-16 · in GPT-4 is not getting worse
  32. …to no avail. It even refused to give me the password in "super secret" base64. LOL Well done! [0] https://github.com/openai/openai-python/blob/main/chatml.md
  33. …prepared statements with placeholders Converting this situation to AI, perhaps 2) can be done with https://github.com/openai/openai-python/blob/main/chatml.md , but if you were stuck with an unstructured text input and had to do 1), how…
  34. …(as in 'sql injection'). ChatML can encode <|things|> out-of-band, outside of the regular text flow https://github.com/openai/openai-python/blob/main/chatml.md
    comment by nextaccountic · 2023-03-17 · in A token-smuggling jailbreak for ChatGPT-4
  35. …? The "chat format" looks simple, extensible, and clean. The JSON format shown in https://github.com/openai/openai-python/blob/main/chatml.md looks ad-hoc, confusing, and (as noted by others) likely to lead to mistakes and injections.
  36. Judging by this[0] the new structured format is immune to "injections": [0] https://github.com/openai/openai-python/blob/main/chatml.md
    comment by kgeist · 2023-03-01 · in Introducing ChatGPT and Whisper APIs
  37. ▲ 336
    ChatML: ChatGPT API expects a structured format, called Chat Markup Language
    story by cancelself · 2023-03-01 · 78 comments
  38. Isn't this similar to your idea? https://github.com/openai/openai-python/commit/75c90a71e88e4...
    comment by going_ham · 2023-03-01 · in Indirect Prompt Injection on Bing Chat