Skip to content

[DOCS] TypeScript SDK: add llamacpp provider, PascalCase enum members #426

Closed

Description

Summary

The @inference-gateway/sdk TypeScript SDK now exposes the llamacpp provider (keyless, default URL http://llamacpp:8080/v1) via Provider.llamacpp, after regenerating its types from inference-gateway/schemas main. The same regen renamed several exported enum members to PascalCase (string values unchanged, only the TypeScript identifiers change):

  • MessageRole: system|user|assistant|tool -> System|User|Assistant|Tool
  • FinishReason: stop|length|tool_calls|content_filter|function_call -> Stop|Length|ToolCalls|ContentFilter|FunctionCall
  • CreateChatCompletionRequestReasoning_effort: minimal|low|medium|high -> Minimal|Low|Medium|High

Affected pages: any documentation with TypeScript SDK snippets that reference the lowercase enum members, and any provider listing that should now include llamacpp.

SDK PR: inference-gateway/typescript-sdk#151

Acceptance Criteria

  • TypeScript SDK docs list llamacpp as a supported provider
  • TypeScript SDK code snippets use the PascalCase enum members (for example MessageRole.User, FinishReason.Stop)

Activity

  1. added
    documentation
    on Jul 18, 2026
  2. edenreich commented on Jul 18, 2026

    @edenreich
    Contributor

    @claude Can you work on this?

  3. added theissue type on Jul 18, 2026
  4. moved this to Todo in 2026on Jul 18, 2026
  5. inference-gateway-maintainer commented on Jul 18, 2026

    @inference-gateway-maintainer
    ContributorAuthor

    Claude finished @edenreich's task in 5m 34s —— View job • docs/issue-426-20260718-2132 • [Create PR ➔](https://github.com/inference-gateway/docs/compare/main...docs/issue-426-20260718-2132?quick_pull=1&title=Issue%20%23426%3A%20Changes%20from%20Claude&body=This%20PR%20addresses%20issue%20%23426%0A%0AGenerated%20with%20%5BClaude%20Code%5D(https%3A%2F%2Fclaude.ai%2Fcode)


    Done

    Opened PR #427 - docs: PascalCase TypeScript SDK enum members in typescript-adk.

    • Gather context (find TypeScript SDK snippets + provider listings)
    • Verify enum renames against the actual SDK source (typescript-sdk src/types/generated/index.ts)
    • Add llamacpp to TypeScript SDK supported-provider docs - already present
    • Update TS snippets to PascalCase enum members
    • Lint / format checks pass
    • Commit and open PR

    What changed

    Fixed the one stale TypeScript snippet - the DefaultBackgroundTaskHandler adapter in typescript-adk.md (lines 2201-2218) - which still used the old lowercase enum members:

    -      return { role: MessageRole.system, content: message.content };
    +      return { role: MessageRole.System, content: message.content };
    -      return { role: MessageRole.user, content: message.content };
    +      return { role: MessageRole.User, content: message.content };
    ...
    -        role: MessageRole.assistant,
    +        role: MessageRole.Assistant,
    ...
    -        role: MessageRole.tool,
    +        role: MessageRole.Tool,

    Already satisfied on main (verified, no change needed)

    • llamacpp is already listed in the shared "Supported providers" list in sdks.md (issue docs(sdks): add llamacpp to supported providers list #422); the TypeScript SDK shares that list with the other three SDKs.
    • The TypeScript examples in sdks.md already use PascalCase (MessageRole.System, MessageRole.User).
    • reasoning_effort: 'low' is a string literal (value unchanged), not an enum member.
    • ChatCompletionToolType.function is still lowercase in the SDK (confirmed against src/types/generated/index.ts), so it was intentionally left unchanged - the issue's list of renamed enums correctly excludes it.

    Checks

    • bun run format:check - pass
    • bun run lint:md - pass

    No generated regions were touched, so no task generate run was required.
    | Branch docs/issue-426-20260718-2132

  6. moved this from Todo to In progress in 2026on Jul 18, 2026
  7. moved this from In progress to QA in 2026on Jul 18, 2026
  8. moved this from QA to Done in 2026on Jul 18, 2026
  9. inference-gateway-releaser commented on Jul 22, 2026

    @inference-gateway-releaser
    Contributor

    🎉 This issue has been resolved in version 0.9.3 🎉

    The release is available on GitHub release

    Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationreleased

    Type

    Projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions