Skip to content

fix(truth-lock): RED-5 replace 'drop-in' with 'chat-completions'#27

Closed
hizrianraz wants to merge 2 commits into
mainfrom
red-5-drop-in-purge
Closed

fix(truth-lock): RED-5 replace 'drop-in' with 'chat-completions'#27
hizrianraz wants to merge 2 commits into
mainfrom
red-5-drop-in-purge

Conversation

@hizrianraz

@hizrianraz hizrianraz commented Jul 12, 2026

Copy link
Copy Markdown
Contributor

RED-5: Replace "drop-in" → "chat-completions"

Changes

  • README.md: compatibility table headers 'drop-in' → 'chat-completions'
  • examples/quickstart.py: 'on chain' → 'in the audit log' (precision)

Label: truth-lock


Note

Low Risk
Changes are documentation, examples, and packaging metadata with no meaningful SDK runtime or API behavior changes beyond copy and formatting.

Overview
Truth-lock (RED-5): The README compatibility matrix now labels the OpenAI and Anthropic columns as (chat-completions) instead of implying a vague “drop-in” integration. examples/quickstart.py ends with “in the audit log” rather than “on chain” so success copy matches how receipts are actually recorded.

Beyond those precision edits, the PR reshapes developer-facing packaging and docs: pyproject.toml publishes the ainfera package at 1.1.0 (dependencies, CLI extra, python/tests paths, pyright scope). README.md and CHANGELOG.md [Unreleased] drop stale “57 models” claims, standardize on model="ainfera-inference", add compatibility/API-versioning/streaming/tools/retry/async/receipt/routing sections, and point concept links at live /docs anchors.

Examples gain runnable scripts for streaming (OpenAI-compatible SSE), tools, retries, async, receipt verification, and error handling; python/examples/04_inference.py fixes the broken .receipt.audit_url usage in favor of receipt_id. releaserc.toml adds semantic-release automation. Library and test diffs are largely formatting (line wraps), not behavior changes.

Reviewed by Cursor Bugbot for commit 0da266e. Bugbot is set up for automated code reviews on this repo. Configure here.

Aulë added 2 commits July 11, 2026 12:04
…fix pyproject

Remove stale '57 models' literal count claims from README and docs.
Change all examples from pinned claude-haiku-4-5 to ainfera-inference
(the flagship routing route).

New examples:
- streaming.py — SSE via OpenAI-compatible endpoint
- tools.py — function calling with tools/tool_choice pass-through
- retries.py — exponential backoff for transient 5xx errors
- async_usage.py — AsyncAinferaClient with wallet and audit chain
- receipt_verification.py — inline receipt + local AuditChain verify
- error_handling.py — full semantic exception hierarchy

README additions:
- Compatibility table (ainfera SDK vs openai SDK vs anthropic SDK)
- API versioning section
- Streaming section (explains 501 on /v1/inference)
- Tools section with code example
- Retries and error handling section with exception table
- Async usage section
- Receipt verification section
- Local verification clarification (tamper-evidence vs tamper-prevention)
- Routing hints section (routing_hint, pool, budget/latency/quality)

Fixes:
- pyproject.toml: broken TOML header (line 3 was prose not comment)
- pyproject.toml: package name sdk -> ainfera, version 0.1.0 -> 1.1.0
- pyproject.toml: packages.find where=src -> where=python, include=sdk* -> ainfera*
- pyproject.toml: testpaths tests -> python/tests
- pyproject.toml: added missing dependencies (httpx, pydantic, joserfc)
- pyproject.toml: added missing dev deps (respx, pytest-asyncio, pyright)
- pyproject.toml: added cli extra (click, pyyaml) and project.scripts entry
- pyproject.toml: added ruff per-file-ignores for exceptions.py N818
- pyproject.toml: added pyright config (library-only, exclude cli/tests)
- python/examples/04_inference.py: model -> ainfera-inference, fix broken
  .receipt.audit_url reference -> .receipt_id
- examples/README.md: stale ainfera==1.0.1 pin -> >=1.1.0
- releaserc.toml: semantic-release config for automated versioning
- ruff format applied to all files

All CI checks pass: ruff check, ruff format --check, pytest (66 passed),
pyright (0 errors).
…EADME + quickstart

- README compatibility table: 'drop-in' → 'chat-completions'
- quickstart.py: 'on chain' → 'in the audit log' (precision)
@coderabbitai

coderabbitai Bot commented Jul 12, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@hizrianraz, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 28 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 422ad03c-ecac-46ca-8805-9aaeb50d1a33

📥 Commits

Reviewing files that changed from the base of the PR and between 37816d0 and 0da266e.

📒 Files selected for processing (26)
  • CHANGELOG.md
  • README.md
  • examples/README.md
  • examples/async_usage.py
  • examples/error_handling.py
  • examples/quickstart.py
  • examples/receipt_verification.py
  • examples/retries.py
  • examples/streaming.py
  • examples/tools.py
  • pyproject.toml
  • python/ainfera/_internal/http.py
  • python/ainfera/_internal/jws.py
  • python/ainfera/agents.py
  • python/ainfera/audit.py
  • python/ainfera/cli.py
  • python/ainfera/client.py
  • python/ainfera/wallet.py
  • python/examples/04_inference.py
  • python/tests/test_async_resources.py
  • python/tests/test_cli_install.py
  • python/tests/test_http.py
  • python/tests/test_resources.py
  • python/tests/test_verify.py
  • releaserc.toml
  • tests/test_smoke.py
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch red-5-drop-in-purge

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@hizrianraz

Copy link
Copy Markdown
Contributor Author

Closing — main already has these fixes from PR #26. The branch was based on a stale fork of the old feature branch.

@hizrianraz hizrianraz closed this Jul 12, 2026
@hizrianraz
hizrianraz deleted the red-5-drop-in-purge branch July 12, 2026 09:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant