Skip to content

Add Thaura adaptor - #1860

Draft
SaidChihabi wants to merge 1 commit into
OpenFn:mainfrom
SaidChihabi:add-thaura-adaptor
Draft

SaidChihabi wants to merge 1 commit into
OpenFn:mainfrom
SaidChihabi:add-thaura-adaptor

Conversation

@SaidChihabi

Copy link
Copy Markdown

Summary

Adds a new adaptor, @openfn/language-thaura, for the Thaura API (an independent AI hosted in the EU, OpenAI-compatible chat completions).

Details

  • prompt() sends a single prompt, with optional system prompt and options such as max_tokens.
  • chat() sends a whole conversation, and can ask for JSON output.
  • request() calls any other path of the Thaura API with the key added.
  • A 429 is retried after the wait the API asks for (Retry-After).
  • Configuration: apiKey (required), baseUrl (defaults to https://backend.thaura.ai/v1), with a JSON Schema draft-07 configuration schema.
  • Unit tests in packages/thaura/test/Adaptor.test.js, README with examples, and a changeset for the initial release.

Discussed with Jack Hilton (OpenFn) for the Cities Deliver programme.

prompt() and chat() call Thaura's OpenAI-compatible chat completions API,
and request() calls any other path of the API with the key added. A 429 is
retried after the wait the API asks for.
@SaidChihabi
SaidChihabi marked this pull request as draft November 26, 2026 10:38
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