Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(api): OpenAPI spec update via Stainless API #112

Merged
merged 1 commit into from
Aug 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Empty file modified .devcontainer/Dockerfile
100644 → 100755
Empty file.
Empty file modified .devcontainer/devcontainer.json
100644 → 100755
Empty file.
Empty file modified .eslintrc.js
100644 → 100755
Empty file.
Empty file modified .github/workflows/ci.yml
100644 → 100755
Empty file.
Empty file modified .github/workflows/publish-npm.yml
100644 → 100755
Empty file.
Empty file modified .github/workflows/release-doctor.yml
100644 → 100755
Empty file.
Empty file modified .gitignore
100644 → 100755
Empty file.
Empty file modified .prettierignore
100644 → 100755
Empty file.
Empty file modified .prettierrc.json
100644 → 100755
Empty file.
Empty file modified .release-please-manifest.json
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion .stats.yml
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configured_endpoints: 7
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/groqcloud%2Fgroqcloud-a10a2e26af1859694bf25612d54e7909296f7aaf82822c6a1681632bf28ec669.yml
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/groqcloud%2Fgroqcloud-1f0d266ba97b03672f10d33a6dc6e324af9a95646f978ffbff6a31f3907bbfe7.yml
Empty file modified Brewfile
100644 → 100755
Empty file.
Empty file modified CHANGELOG.md
100644 → 100755
Empty file.
Empty file modified CODEOWNERS
100644 → 100755
Empty file.
Empty file modified CONTRIBUTING.md
100644 → 100755
Empty file.
Empty file modified LICENSE
100644 → 100755
Empty file.
Empty file modified README.md
100644 → 100755
Empty file.
Empty file modified SECURITY.md
100644 → 100755
Empty file.
Empty file modified api.md
100644 → 100755
Empty file.
Empty file modified bin/check-release-environment
100644 → 100755
Empty file.
Empty file modified bin/publish-npm
100644 → 100755
Empty file.
Empty file modified examples/.keep
100644 → 100755
Empty file.
Empty file modified examples/chat_completion.js
100644 → 100755
Empty file.
Empty file modified examples/chat_completion_stop.js
100644 → 100755
Empty file.
Empty file modified examples/chat_completion_streaming.js
100644 → 100755
Empty file.
Empty file modified jest.config.ts
100644 → 100755
Empty file.
Empty file modified package.json
100644 → 100755
Empty file.
Empty file modified release-please-config.json
100644 → 100755
Empty file.
Empty file modified scripts/utils/check-version.cjs
100644 → 100755
Empty file.
Empty file modified scripts/utils/fix-index-exports.cjs
100644 → 100755
Empty file.
Empty file modified scripts/utils/make-dist-package-json.cjs
100644 → 100755
Empty file.
Empty file modified scripts/utils/postprocess-files.cjs
100644 → 100755
Empty file.
Empty file modified src/_shims/MultipartBody.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/README.md
100644 → 100755
Empty file.
Empty file modified src/_shims/auto/runtime-bun.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/auto/runtime-deno.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/auto/runtime-node.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/auto/runtime.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/auto/types-deno.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/auto/types-node.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/auto/types.d.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/auto/types.js
100644 → 100755
Empty file.
Empty file modified src/_shims/auto/types.mjs
100644 → 100755
Empty file.
Empty file modified src/_shims/bun-runtime.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/index-deno.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/index.d.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/index.js
100644 → 100755
Empty file.
Empty file modified src/_shims/index.mjs
100644 → 100755
Empty file.
Empty file modified src/_shims/manual-types.d.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/manual-types.js
100644 → 100755
Empty file.
Empty file modified src/_shims/manual-types.mjs
100644 → 100755
Empty file.
Empty file modified src/_shims/node-runtime.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/node-types.d.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/node-types.js
100644 → 100755
Empty file.
Empty file modified src/_shims/node-types.mjs
100644 → 100755
Empty file.
Empty file modified src/_shims/registry.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/web-runtime.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/web-types.d.ts
100644 → 100755
Empty file.
Empty file modified src/_shims/web-types.js
100644 → 100755
Empty file.
Empty file modified src/_shims/web-types.mjs
100644 → 100755
Empty file.
Empty file modified src/core.ts
100644 → 100755
Empty file.
Empty file modified src/error.ts
100644 → 100755
Empty file.
Empty file modified src/index.ts
100644 → 100755
Empty file.
Empty file modified src/lib/.keep
100644 → 100755
Empty file.
Empty file modified src/lib/chat_completions_ext.ts
100644 → 100755
Empty file.
Empty file modified src/lib/streaming.ts
100644 → 100755
Empty file.
Empty file modified src/resource.ts
100644 → 100755
Empty file.
Empty file modified src/resources/audio/audio.ts
100644 → 100755
Empty file.
Empty file modified src/resources/audio/index.ts
100644 → 100755
Empty file.
1 change: 0 additions & 1 deletion src/resources/audio/transcriptions.ts
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ export interface TranscriptionCreateParams {
| 'da'
| 'hu'
| 'ta'
| 'no'
| 'th'
| 'ur'
| 'hr'
Expand Down
Empty file modified src/resources/audio/translations.ts
100644 → 100755
Empty file.
Empty file modified src/resources/chat/chat.ts
100644 → 100755
Empty file.
40 changes: 0 additions & 40 deletions src/resources/chat/completions.ts
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -123,11 +123,6 @@ export interface ChatCompletionAssistantMessageParam {
*/
name?: string;

/**
* DO NOT USE. This field is present because OpenAI allows it and userssend it.
*/
tool_call_id?: string | null;

/**
* The tool calls generated by the model, such as function calls.
*/
Expand Down Expand Up @@ -397,11 +392,6 @@ export interface ChatCompletionFunctionMessageParam {
* The role of the messages author, in this case `function`.
*/
role: 'function';

/**
* DO NOT USE. This field is present because OpenAI allows it and users send it.
*/
tool_call_id?: string | null;
}

/**
Expand Down Expand Up @@ -538,11 +528,6 @@ export interface ChatCompletionSystemMessageParam {
* differentiate between participants of the same role.
*/
name?: string;

/**
* DO NOT USE. This field is present because OpenAI allows it and userssend it.
*/
tool_call_id?: string | null;
}

export interface ChatCompletionTokenLogprob {
Expand Down Expand Up @@ -635,11 +620,6 @@ export interface ChatCompletionToolMessageParam {
* Tool call that this message is responding to.
*/
tool_call_id: string;

/**
* DO NOT USE. This field is present because OpenAI allows it and userssend it.
*/
name?: string;
}

export interface ChatCompletionUserMessageParam {
Expand All @@ -658,11 +638,6 @@ export interface ChatCompletionUserMessageParam {
* differentiate between participants of the same role.
*/
name?: string;

/**
* DO NOT USE. This field is present because OpenAI allows it and userssend it.
*/
tool_call_id?: string | null;
}

export interface CompletionCreateParams {
Expand Down Expand Up @@ -777,11 +752,6 @@ export interface CompletionCreateParams {
*/
stream?: boolean | null;

/**
* Options for streaming response. Only set this when you set `stream: true`.
*/
stream_options?: CompletionCreateParams.StreamOptions | null;

/**
* What sampling temperature to use, between 0 and 2. Higher values like 0.8 will
* make the output more random, while lower values like 0.2 will make it more
Expand Down Expand Up @@ -876,16 +846,6 @@ export namespace CompletionCreateParams {
*/
type?: 'text' | 'json_object';
}

/**
* Options for streaming response. Only set this when you set `stream: true`.
*/
export interface StreamOptions {
/**
* This field is unused
*/
include_usage?: boolean;
}
}

export namespace Completions {
Expand Down
Empty file modified src/resources/chat/index.ts
100644 → 100755
Empty file.
Empty file modified src/resources/completions.ts
100644 → 100755
Empty file.
Empty file modified src/resources/embeddings.ts
100644 → 100755
Empty file.
Empty file modified src/resources/index.ts
100644 → 100755
Empty file.
Empty file modified src/resources/models.ts
100644 → 100755
Empty file.
Empty file modified src/resources/shared.ts
100644 → 100755
Empty file.
Empty file modified src/shims/node.ts
100644 → 100755
Empty file.
Empty file modified src/shims/web.ts
100644 → 100755
Empty file.
Empty file modified src/uploads.ts
100644 → 100755
Empty file.
Empty file modified src/version.ts
100644 → 100755
Empty file.
Empty file modified tests/api-resources/audio/transcriptions.test.ts
100644 → 100755
Empty file.
Empty file modified tests/api-resources/audio/translations.test.ts
100644 → 100755
Empty file.
3 changes: 1 addition & 2 deletions tests/api-resources/chat/completions.test.ts
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ describe('resource completions', () => {

test('create: required and optional params', async () => {
const response = await client.chat.completions.create({
messages: [{ content: 'content', role: 'system', name: 'name', tool_call_id: 'tool_call_id' }],
messages: [{ content: 'content', role: 'system', name: 'name' }],
model: 'string',
frequency_penalty: -2,
function_call: 'none',
Expand All @@ -44,7 +44,6 @@ describe('resource completions', () => {
seed: 0,
stop: '\n',
stream: true,
stream_options: { include_usage: true },
temperature: 1,
tool_choice: 'none',
tools: [
Expand Down
Empty file modified tests/api-resources/embeddings.test.ts
100644 → 100755
Empty file.
Empty file modified tests/api-resources/models.test.ts
100644 → 100755
Empty file.
Empty file modified tests/form.test.ts
100644 → 100755
Empty file.
Empty file modified tests/index.test.ts
100644 → 100755
Empty file.
Empty file modified tests/responses.test.ts
100644 → 100755
Empty file.
Empty file modified tests/stringifyQuery.test.ts
100644 → 100755
Empty file.
Empty file modified tests/uploads.test.ts
100644 → 100755
Empty file.
Empty file modified tsc-multi.json
100644 → 100755
Empty file.
Empty file modified tsconfig.build.json
100644 → 100755
Empty file.
Empty file modified tsconfig.deno.json
100644 → 100755
Empty file.
Empty file modified tsconfig.dist-src.json
100644 → 100755
Empty file.
Empty file modified tsconfig.json
100644 → 100755
Empty file.
Empty file modified yarn.lock
100644 → 100755
Empty file.