Skip to content

docs: add TokenLab LLM connection example#6489

Open
hedging8563 wants to merge 4 commits into
crewAIInc:mainfrom
hedging8563:codex/add-tokenlab-llm-example
Open

docs: add TokenLab LLM connection example#6489
hedging8563 wants to merge 4 commits into
crewAIInc:mainfrom
hedging8563:codex/add-tokenlab-llm-example

Conversation

@hedging8563

Copy link
Copy Markdown

Summary

  • Document TokenLab as an OpenAI-compatible LLM connection option for CrewAI.
  • Use TokenLab's OpenAI-compatible base URL: https://api.tokenlab.sh/v1
  • No runtime behavior changes; documentation only.

Verification

  • git diff --check

@coderabbitai

coderabbitai Bot commented Jul 8, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 53afbca1-7920-4936-9642-40ca8cd90e4c

📥 Commits

Reviewing files that changed from the base of the PR and between bfca9b1 and 942c518.

📒 Files selected for processing (2)
  • docs/edge/en/learn/llm-connections.mdx
  • docs/v1.15.0/en/learn/llm-connections.mdx
💤 Files with no reviewable changes (1)
  • docs/v1.15.0/en/learn/llm-connections.mdx
✅ Files skipped from review due to trivial changes (1)
  • docs/edge/en/learn/llm-connections.mdx

📝 Walkthrough

Walkthrough

Added TokenLab examples to the OpenAI-compatible LLM connection docs in both documentation versions, covering environment-variable setup and LLM class attribute configuration with Agent wiring.

Changes

TokenLab Documentation Example

Layer / File(s) Summary
TokenLab examples in env var and LLM class sections
docs/edge/en/learn/llm-connections.mdx, docs/v1.15.0/en/learn/llm-connections.mdx
Adds TokenLab environment-variable snippets and LLM class attribute snippets wired into Agent(llm=llm, ...) in the OpenAI-compatible LLM connection docs.
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly matches the main change: adding a TokenLab LLM connection example in docs.
Description check ✅ Passed The description is directly related to the documentation-only TokenLab connection update.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/v1.15.0/en/learn/llm-connections.mdx`:
- Around line 147-153: Don’t edit the frozen v1.15.0 snapshot directly; the
TokenLab examples in this document should be added in the canonical source docs
and then regenerated into the release snapshot. Update the source documentation
that feeds this page, then run the docs generation workflow so the snapshot
stays in sync. Use the existing llm-connections documentation entry points and
the TokenLab section as the place to make the change, rather than modifying
docs/v1.15.0/en/learn/llm-connections.mdx by hand.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: d40e40da-0203-4326-aacf-9595395f3c3b

📥 Commits

Reviewing files that changed from the base of the PR and between 289686a and bfca9b1.

📒 Files selected for processing (1)
  • docs/v1.15.0/en/learn/llm-connections.mdx

Comment on lines +147 to +153
```python TokenLab
import os

os.environ["OPENAI_API_KEY"] = "your-tokenlab-api-key"
os.environ["OPENAI_API_BASE"] = "https://api.tokenlab.sh/v1"
os.environ["OPENAI_MODEL_NAME"] = "claude-sonnet-5"
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win

Don't edit the frozen v1.15.0 snapshot directly.

docs/v1.15.0/... is a frozen release snapshot, so these TokenLab examples should be added in the source docs and regenerated instead of editing this file by hand; otherwise the snapshot can drift from the canonical docs.

As per path instructions: docs/v*/** files are frozen release snapshots managed by devtools.

Also applies to: 177-185

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/v1.15.0/en/learn/llm-connections.mdx` around lines 147 - 153, Don’t edit
the frozen v1.15.0 snapshot directly; the TokenLab examples in this document
should be added in the canonical source docs and then regenerated into the
release snapshot. Update the source documentation that feeds this page, then run
the docs generation workflow so the snapshot stays in sync. Use the existing
llm-connections documentation entry points and the TokenLab section as the place
to make the change, rather than modifying
docs/v1.15.0/en/learn/llm-connections.mdx by hand.

Source: Path instructions

@hedging8563

Copy link
Copy Markdown
Author

Thanks for the review. Addressed in 942c518 by removing the manual edit from the frozen v1.15.0 snapshot and moving the TokenLab examples to the canonical edge docs entry point instead.

@hedging8563

Copy link
Copy Markdown
Author

Updated the branch to keep the TokenLab examples only in docs/edge/en/learn/llm-connections.mdx. I also removed the residual whitespace-only change from the frozen docs/v1.15.0 snapshot, so the PR no longer modifies release snapshots.

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