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

release: 1.14.0 #148

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
32cb6f9
feat(api): OpenAPI spec update via Stainless API (#147)
stainless-app[bot] Jul 10, 2024
de660c2
feat(api): OpenAPI spec update via Stainless API (#149)
stainless-app[bot] Jul 10, 2024
b7ef788
feat(api): OpenAPI spec update via Stainless API (#150)
stainless-app[bot] Jul 10, 2024
fb48dbd
feat(api): OpenAPI spec update via Stainless API (#151)
stainless-app[bot] Jul 10, 2024
755a2b3
feat(api): OpenAPI spec update via Stainless API (#152)
stainless-app[bot] Jul 11, 2024
93f9555
feat(api): OpenAPI spec update via Stainless API (#153)
stainless-app[bot] Jul 11, 2024
f9dac25
feat(api): OpenAPI spec update via Stainless API (#154)
stainless-app[bot] Jul 11, 2024
a079c06
feat(api): OpenAPI spec update via Stainless API (#155)
stainless-app[bot] Jul 16, 2024
6d54ca4
feat(api): OpenAPI spec update via Stainless API (#156)
stainless-app[bot] Jul 16, 2024
bf8d9d9
feat(api): OpenAPI spec update via Stainless API (#157)
stainless-app[bot] Jul 16, 2024
ffbb0f2
feat(api): OpenAPI spec update via Stainless API (#158)
stainless-app[bot] Jul 16, 2024
bb2950c
feat(api): OpenAPI spec update via Stainless API (#159)
stainless-app[bot] Jul 16, 2024
9592662
feat(api): OpenAPI spec update via Stainless API (#160)
stainless-app[bot] Jul 16, 2024
51f7e7f
feat(api): update via SDK Studio (#161)
stainless-app[bot] Jul 16, 2024
6d53e0c
feat(api): OpenAPI spec update via Stainless API (#162)
stainless-app[bot] Jul 16, 2024
6470ed7
feat(api): OpenAPI spec update via Stainless API (#163)
stainless-app[bot] Jul 16, 2024
9f64698
feat(api): OpenAPI spec update via Stainless API (#164)
stainless-app[bot] Jul 17, 2024
fff8216
release: 1.14.0
stainless-app[bot] Jul 17, 2024
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
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ on:
pull_request:
branches:
- main
- next

jobs:
lint:
Expand Down
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "1.13.0"
".": "1.14.0"
}
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configured_endpoints: 21
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/prompt-foundry%2Fprompt-foundry-sdk-5d4722a755a01f8917b975ab7e6528e590f53d09891baac758abba1e28df15d1.yml
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/prompt-foundry%2Fprompt-foundry-sdk-0042044f00457ff0bf65c07207eea291e4df838e2bdab4dfc602eec8d3517c42.yml
24 changes: 24 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,29 @@
# Changelog

## 1.14.0 (2024-07-17)

Full Changelog: [v1.13.0...v1.14.0](https://github.com/prompt-foundry/typescript-sdk/compare/v1.13.0...v1.14.0)

### Features

* **api:** OpenAPI spec update via Stainless API ([#147](https://github.com/prompt-foundry/typescript-sdk/issues/147)) ([32cb6f9](https://github.com/prompt-foundry/typescript-sdk/commit/32cb6f92b8f7b5efd743d698d113eff2754cd40b))
* **api:** OpenAPI spec update via Stainless API ([#149](https://github.com/prompt-foundry/typescript-sdk/issues/149)) ([de660c2](https://github.com/prompt-foundry/typescript-sdk/commit/de660c2b31f79be4195159f94c6c3ca112ba6447))
* **api:** OpenAPI spec update via Stainless API ([#150](https://github.com/prompt-foundry/typescript-sdk/issues/150)) ([b7ef788](https://github.com/prompt-foundry/typescript-sdk/commit/b7ef7880cf87a071c0435cdd2b49ba7cc46f49a0))
* **api:** OpenAPI spec update via Stainless API ([#151](https://github.com/prompt-foundry/typescript-sdk/issues/151)) ([fb48dbd](https://github.com/prompt-foundry/typescript-sdk/commit/fb48dbd5ff6b29a564f28a289c58e5991386ca40))
* **api:** OpenAPI spec update via Stainless API ([#152](https://github.com/prompt-foundry/typescript-sdk/issues/152)) ([755a2b3](https://github.com/prompt-foundry/typescript-sdk/commit/755a2b3f28a1d277235a7a7792398fca8a8a2843))
* **api:** OpenAPI spec update via Stainless API ([#153](https://github.com/prompt-foundry/typescript-sdk/issues/153)) ([93f9555](https://github.com/prompt-foundry/typescript-sdk/commit/93f95551e6a63115efb9f8610b18fa5c9c2831fc))
* **api:** OpenAPI spec update via Stainless API ([#154](https://github.com/prompt-foundry/typescript-sdk/issues/154)) ([f9dac25](https://github.com/prompt-foundry/typescript-sdk/commit/f9dac25563076648db74238dab095038e970b980))
* **api:** OpenAPI spec update via Stainless API ([#155](https://github.com/prompt-foundry/typescript-sdk/issues/155)) ([a079c06](https://github.com/prompt-foundry/typescript-sdk/commit/a079c063443fa4d74de035966f455bb92dcd830b))
* **api:** OpenAPI spec update via Stainless API ([#156](https://github.com/prompt-foundry/typescript-sdk/issues/156)) ([6d54ca4](https://github.com/prompt-foundry/typescript-sdk/commit/6d54ca422b72aadfe3e7ff1022cb576aa962c053))
* **api:** OpenAPI spec update via Stainless API ([#157](https://github.com/prompt-foundry/typescript-sdk/issues/157)) ([bf8d9d9](https://github.com/prompt-foundry/typescript-sdk/commit/bf8d9d9b83c9cd63e9dfbe0521e87d747131ab17))
* **api:** OpenAPI spec update via Stainless API ([#158](https://github.com/prompt-foundry/typescript-sdk/issues/158)) ([ffbb0f2](https://github.com/prompt-foundry/typescript-sdk/commit/ffbb0f2567f5cd0569f732e9304b3db74cb364e1))
* **api:** OpenAPI spec update via Stainless API ([#159](https://github.com/prompt-foundry/typescript-sdk/issues/159)) ([bb2950c](https://github.com/prompt-foundry/typescript-sdk/commit/bb2950c2348f6d1a399d012f0d3b1816a8842c7a))
* **api:** OpenAPI spec update via Stainless API ([#160](https://github.com/prompt-foundry/typescript-sdk/issues/160)) ([9592662](https://github.com/prompt-foundry/typescript-sdk/commit/95926621f31f6148bbedfc7c2373445cdccb05c9))
* **api:** OpenAPI spec update via Stainless API ([#162](https://github.com/prompt-foundry/typescript-sdk/issues/162)) ([6d53e0c](https://github.com/prompt-foundry/typescript-sdk/commit/6d53e0cba5660e0a7c8968d8f5b42a87caceffd9))
* **api:** OpenAPI spec update via Stainless API ([#163](https://github.com/prompt-foundry/typescript-sdk/issues/163)) ([6470ed7](https://github.com/prompt-foundry/typescript-sdk/commit/6470ed7715650a3c347125eb77846c6d846b62f2))
* **api:** OpenAPI spec update via Stainless API ([#164](https://github.com/prompt-foundry/typescript-sdk/issues/164)) ([9f64698](https://github.com/prompt-foundry/typescript-sdk/commit/9f64698302e6c5db1f18adbbf5c1247a20f9fdd6))
* **api:** update via SDK Studio ([#161](https://github.com/prompt-foundry/typescript-sdk/issues/161)) ([51f7e7f](https://github.com/prompt-foundry/typescript-sdk/commit/51f7e7f84dc87b602e20743b67f2417e6fe4cb48))

## 1.13.0 (2024-07-10)

Full Changelog: [v1.12.0...v1.13.0](https://github.com/prompt-foundry/typescript-sdk/compare/v1.12.0...v1.13.0)
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,9 @@ The following runtimes are supported:
- Jest 28 or greater with the `"node"` environment (`"jsdom"` is not supported at this time).
- Nitro v2.6 or greater.

> [!WARNING]
> Web browser runtimes aren't supported. The SDK will throw an error if used in a browser environment.

Note that React Native is not supported at this time.

If you are interested in other runtime environments, please open or upvote an issue on GitHub.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@prompt-foundry/typescript-sdk",
"version": "1.13.0",
"version": "1.14.0",
"description": "The prompt engineering, prompt management, and prompt evaluation tool for TypeScript, JavaScript, and NodeJS.",
"keywords": [
"typescript",
Expand Down
255 changes: 165 additions & 90 deletions src/resources/evaluations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,53 +62,78 @@ export interface Evaluation {
}

export namespace Evaluation {
/**
* The initial messages to be included with your call to the LLM API.
*/
export interface AppendedMessage {
/**
* Example: "Hello, {{city}}!"
*/
content: string | null;
content: Array<
| AppendedMessage.TextContentBlockSchema
| AppendedMessage.ImageBase64ContentBlock
| AppendedMessage.ToolCallContentBlock
| AppendedMessage.ToolResultContentBlock
>;

role: 'assistant' | 'system' | 'tool' | 'user';

toolCallId: string | null;

toolCalls: Array<AppendedMessage.ToolCall> | null;
}

export namespace AppendedMessage {
export interface ToolCall {
function: ToolCall.Function;
export interface TextContentBlockSchema {
text: string;

/**
* TOOL_CALL_1
*/
toolCallId: string;
type: 'TEXT';
}

export interface ImageBase64ContentBlock {
imageBase64: string;

mediaType: string;

/**
* The type of the tool. Currently, only `function` is supported.
*/
type: 'function';
type: 'IMAGE_BASE64';
}

export namespace ToolCall {
export interface Function {
export interface ToolCallContentBlock {
toolCall: ToolCallContentBlock.ToolCall;

type: 'TOOL_CALL';
}

export namespace ToolCallContentBlock {
export interface ToolCall {
function: ToolCall.Function;

/**
* The arguments to call the function with, as generated by the model in JSON
* format. Note that the model does not always generate valid JSON, and may
* hallucinate parameters not defined by your function schema. Validate the
* arguments in your code before calling your function.
* TOOL_CALL_1
*/
arguments: string;
toolCallId: string;

/**
* The name of the function to call.
* The type of the tool. Currently, only `function` is supported.
*/
name: string;
type: 'function';
}

export namespace ToolCall {
export interface Function {
/**
* The arguments to call the function with, as generated by the model in JSON
* format. Note that the model does not always generate valid JSON, and may
* hallucinate parameters not defined by your function schema. Validate the
* arguments in your code before calling your function.
*/
arguments: string;

/**
* The name of the function to call.
*/
name: string;
}
}
}

export interface ToolResultContentBlock {
result: string;

toolCallId: string;

type: 'TOOL_RESULT';
}
}
}

Expand All @@ -133,53 +158,78 @@ export interface EvaluationCreateParams {
}

export namespace EvaluationCreateParams {
/**
* The initial messages to be included with your call to the LLM API.
*/
export interface AppendedMessage {
/**
* Example: "Hello, {{city}}!"
*/
content: string | null;
content: Array<
| AppendedMessage.TextContentBlockSchema
| AppendedMessage.ImageBase64ContentBlock
| AppendedMessage.ToolCallContentBlock
| AppendedMessage.ToolResultContentBlock
>;

role: 'assistant' | 'system' | 'tool' | 'user';

toolCallId: string | null;

toolCalls: Array<AppendedMessage.ToolCall> | null;
}

export namespace AppendedMessage {
export interface ToolCall {
function: ToolCall.Function;
export interface TextContentBlockSchema {
text: string;

/**
* TOOL_CALL_1
*/
toolCallId: string;
type: 'TEXT';
}

export interface ImageBase64ContentBlock {
imageBase64: string;

/**
* The type of the tool. Currently, only `function` is supported.
*/
type: 'function';
mediaType: string;

type: 'IMAGE_BASE64';
}

export namespace ToolCall {
export interface Function {
export interface ToolCallContentBlock {
toolCall: ToolCallContentBlock.ToolCall;

type: 'TOOL_CALL';
}

export namespace ToolCallContentBlock {
export interface ToolCall {
function: ToolCall.Function;

/**
* The arguments to call the function with, as generated by the model in JSON
* format. Note that the model does not always generate valid JSON, and may
* hallucinate parameters not defined by your function schema. Validate the
* arguments in your code before calling your function.
* TOOL_CALL_1
*/
arguments: string;
toolCallId: string;

/**
* The name of the function to call.
* The type of the tool. Currently, only `function` is supported.
*/
name: string;
type: 'function';
}

export namespace ToolCall {
export interface Function {
/**
* The arguments to call the function with, as generated by the model in JSON
* format. Note that the model does not always generate valid JSON, and may
* hallucinate parameters not defined by your function schema. Validate the
* arguments in your code before calling your function.
*/
arguments: string;

/**
* The name of the function to call.
*/
name: string;
}
}
}

export interface ToolResultContentBlock {
result: string;

toolCallId: string;

type: 'TOOL_RESULT';
}
}
}

Expand All @@ -198,52 +248,77 @@ export interface EvaluationUpdateParams {
}

export namespace EvaluationUpdateParams {
/**
* The initial messages to be included with your call to the LLM API.
*/
export interface AppendedMessage {
/**
* Example: "Hello, {{city}}!"
*/
content: string | null;
content: Array<
| AppendedMessage.TextContentBlockSchema
| AppendedMessage.ImageBase64ContentBlock
| AppendedMessage.ToolCallContentBlock
| AppendedMessage.ToolResultContentBlock
>;

role: 'assistant' | 'system' | 'tool' | 'user';

toolCallId: string | null;

toolCalls: Array<AppendedMessage.ToolCall> | null;
}

export namespace AppendedMessage {
export interface ToolCall {
function: ToolCall.Function;
export interface TextContentBlockSchema {
text: string;

/**
* TOOL_CALL_1
*/
toolCallId: string;
type: 'TEXT';
}

export interface ImageBase64ContentBlock {
imageBase64: string;

/**
* The type of the tool. Currently, only `function` is supported.
*/
type: 'function';
mediaType: string;

type: 'IMAGE_BASE64';
}

export namespace ToolCall {
export interface Function {
export interface ToolCallContentBlock {
toolCall: ToolCallContentBlock.ToolCall;

type: 'TOOL_CALL';
}

export namespace ToolCallContentBlock {
export interface ToolCall {
function: ToolCall.Function;

/**
* The arguments to call the function with, as generated by the model in JSON
* format. Note that the model does not always generate valid JSON, and may
* hallucinate parameters not defined by your function schema. Validate the
* arguments in your code before calling your function.
* TOOL_CALL_1
*/
arguments: string;
toolCallId: string;

/**
* The name of the function to call.
* The type of the tool. Currently, only `function` is supported.
*/
name: string;
type: 'function';
}

export namespace ToolCall {
export interface Function {
/**
* The arguments to call the function with, as generated by the model in JSON
* format. Note that the model does not always generate valid JSON, and may
* hallucinate parameters not defined by your function schema. Validate the
* arguments in your code before calling your function.
*/
arguments: string;

/**
* The name of the function to call.
*/
name: string;
}
}
}

export interface ToolResultContentBlock {
result: string;

toolCallId: string;

type: 'TOOL_RESULT';
}
}
}
Expand Down
Loading