diff --git a/site/src/docs/examples.md b/site/src/docs/examples.md index 296e509f..3afbd37b 100644 --- a/site/src/docs/examples.md +++ b/site/src/docs/examples.md @@ -101,6 +101,14 @@ The examples also work against any OpenAI-compatible gateway, such as [OrcaRoute OPENAI_ENDPOINT=https://api.orcarouter.ai/v1/chat/completions ``` +With [Standard Compute](https://standardcompute.com), the `StandardCompute` model routes each request to the cheapest enabled model that can handle it, with automatic fallback: + +``` +OPENAI_API_KEY= +OPENAI_MODEL=StandardCompute +OPENAI_ENDPOINT=https://api.stdcmpt.com/v1/chat/completions +``` + ## Step 4: Run the examples Examples can be found in the `typescript/examples` directory. diff --git a/site/src/docs/python/basic-usage.md b/site/src/docs/python/basic-usage.md index 59c63b1c..c73c3f00 100644 --- a/site/src/docs/python/basic-usage.md +++ b/site/src/docs/python/basic-usage.md @@ -238,6 +238,16 @@ OPENAI_MODEL= OPENAI_ENDPOINT=https://api.orcarouter.ai/v1/chat/completions ``` +For example, to use [Standard Compute](https://standardcompute.com), whose +`StandardCompute` model routes each request to the cheapest enabled model that +can handle it, with automatic fallback: + +``` +OPENAI_API_KEY= +OPENAI_MODEL=StandardCompute +OPENAI_ENDPOINT=https://api.stdcmpt.com/v1/chat/completions +``` + The HTTP models returned by `create_language_model`, `create_openai_language_model`, and `create_azure_openai_language_model` have a few writable attributes you might find useful: diff --git a/site/src/docs/typescript/basic-usage.md b/site/src/docs/typescript/basic-usage.md index 1da0adb3..0304b897 100644 --- a/site/src/docs/typescript/basic-usage.md +++ b/site/src/docs/typescript/basic-usage.md @@ -184,6 +184,16 @@ OPENAI_MODEL= OPENAI_ENDPOINT=https://api.orcarouter.ai/v1/chat/completions ``` +For example, to use [Standard Compute](https://standardcompute.com), whose +`StandardCompute` model routes each request to the cheapest enabled model that +can handle it, with automatic fallback: + +``` +OPENAI_API_KEY= +OPENAI_MODEL=StandardCompute +OPENAI_ENDPOINT=https://api.stdcmpt.com/v1/chat/completions +``` + Regardless, of how you decide to construct your model, it is important to avoid committing credentials directly in source. One way to make this work between production and development environments is to use a `.env` file in development, and specify that `.env` in your `.gitignore`. You can use a library like [`dotenv`](https://www.npmjs.com/package/dotenv) to help load these up.