Repository navigation
hibira 0.1.0: Python SDK with LLM streaming - #1
Merged
Merged
Conversation
Client and AsyncClient for the Hibira HTTP API (trigger, batch, channel queries, terminate connections), channel and user auth, webhook verification, Hibira Push (interests, users, user tokens), approvals, and stream_to_channel / astream_to_channel for streaming LLM output to useStream() in @hibira-io/react and @hibira-io/vue. text_of reads OpenAI, Anthropic, OpenAI Agents SDK, LangChain/LangGraph and Gemini chunks. hibira.fastapi adds an auth router and a webhook dependency. Tested on Python 3.9 and 3.13, end to end against pusher-server (including channel history replay into the JS stream store). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SHtsCCHwKcFDPRqugEWRfU
…ntu-latest) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SHtsCCHwKcFDPRqugEWRfU
deflinhec
marked this pull request as ready for review
November 1, 2026 14:43
This was referenced Nov 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
First release of
hibiraon PyPI: the Python server library for Hibira.What's in it
Client/AsyncClient(httpx; Python 3.9+):trigger,trigger_batch,channels,channel_info,users,terminate_user_connections, settings fromHIBIRA_*env vars (same names as the Rails gem).authenticate_channel,authenticate_user,verify_webhook(no network, sync on both clients).push_to_interests,push_to_users,push_token,delete_push_user.request_approval,get_approval(wait=),wait_for_approval.stream_to_channel/astream_to_channel: sameai-streamwire format asstreamToChannelin @hibira-io/react and @hibira-io/vue (batching,max_bytes3500,metaon the first event, final event withtextwhen it fits, errors and cancellation sent aserror).text_ofhandles OpenAI chat/Responses, Anthropic, the OpenAI Agents SDK, LangChain/LangGraphstream_mode="messages"and Gemini chunks.hibira.fastapi:auth_router(channel and user auth endpoints for pusher-js) and awebhookdependency.publish.yml(tagvX.Y.Z→ PyPI via trusted publishing, environmentpypi).Testing
twine checkpasses.tests/test_e2e.py(5 tests,HIBIRA_E2E=1) passes against a local pusher-server: trigger, batch, socket exclusion, channel queries, presence users, 401/413 errors, sync and async streaming, and replay of a finished stream throughpusher:rewind.createStreamStore+followStreamfrom @hibira-io/react (live and withrewind: true) gives the same text and meta.Before publishing
Add a PyPI pending publisher: project
hibira, repohibira-io/python, workflowpublish.yml, environmentpypi. Then tagv0.1.0.Generated by Claude Code