Skip to content

Commit b0f92ff

Browse files
feat(api): rename embedding -> embeddings
1 parent 402f641 commit b0f92ff

File tree

6 files changed

+20
-16
lines changed

6 files changed

+20
-16
lines changed

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 4
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/isaacus%2Fisaacus-f4b3340872e913a3cc1dfd27b913d7ff9034881e093e57565c3e4e9f70128c6c.yml
3-
openapi_spec_hash: e8d746a5f9ad96beb227dfad222ca9ef
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/isaacus%2Fisaacus-bc90df05434e3f9e249881744c600bce6e9d04f43d05c1fafa7133d02114f393.yml
3+
openapi_spec_hash: 2205376b167519bd09d2f95741e6141c
44
config_hash: 886b5eef0dbd90b8e6686e987a07b816

api.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22

33
Types:
44

5-
- <code><a href="./src/resources/embeddings.ts">Embedding</a></code>
5+
- <code><a href="./src/resources/embeddings.ts">EmbeddingCreateResponse</a></code>
66

77
Methods:
88

9-
- <code title="post /embeddings">client.embeddings.<a href="./src/resources/embeddings.ts">create</a>({ ...params }) -> Embedding</code>
9+
- <code title="post /embeddings">client.embeddings.<a href="./src/resources/embeddings.ts">create</a>({ ...params }) -> EmbeddingCreateResponse</code>
1010

1111
# Classifications
1212

packages/mcp-server/src/tools/embeddings/create-embeddings.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,14 @@ export const metadata: Metadata = {
1818
export const tool: Tool = {
1919
name: 'create_embeddings',
2020
description:
21-
"When using this tool, always use the `jq_filter` parameter to reduce the response size and improve performance.\n\nOnly omit if you're sure you don't need the data.\n\nEmbed legal texts with an Isaacus legal AI embedder.\n\n# Response Schema\n```json\n{\n $ref: '#/$defs/embedding',\n $defs: {\n embedding: {\n type: 'object',\n title: 'Embedding response',\n description: 'Embeddings of legal texts produced by an Isaacus legal AI embedder.',\n properties: {\n embeddings: {\n type: 'array',\n description: 'The embeddings of the inputs.',\n items: {\n type: 'object',\n title: 'Embedding',\n properties: {\n embedding: {\n type: 'array',\n description: 'The embedding of the content represented as an array of floating point numbers.',\n items: {\n type: 'number'\n }\n },\n index: {\n type: 'integer',\n description: 'The position of the content in the input array of contents, starting from `0` (and, therefore, ending at the number of contents minus `1`).'\n }\n },\n required: [ 'embedding',\n 'index'\n ]\n }\n },\n usage: {\n type: 'object',\n title: 'Embedding usage',\n description: 'Statistics about the usage of resources in the process of embedding the inputs.',\n properties: {\n input_tokens: {\n type: 'integer',\n description: 'The number of tokens inputted to the model.'\n }\n },\n required: [ 'input_tokens'\n ]\n }\n },\n required: [ 'embeddings',\n 'usage'\n ]\n }\n }\n}\n```",
21+
"When using this tool, always use the `jq_filter` parameter to reduce the response size and improve performance.\n\nOnly omit if you're sure you don't need the data.\n\nEmbed legal texts with an Isaacus legal AI embedder.\n\n# Response Schema\n```json\n{\n $ref: '#/$defs/embedding_create_response',\n $defs: {\n embedding_create_response: {\n type: 'object',\n title: 'Embeddings response',\n description: 'Embeddings of legal texts produced by an Isaacus legal AI embedder.',\n properties: {\n embeddings: {\n type: 'array',\n description: 'The embeddings of the inputs.',\n items: {\n type: 'object',\n title: 'Embedding',\n properties: {\n embedding: {\n type: 'array',\n description: 'The embedding of the content represented as an array of floating point numbers.',\n items: {\n type: 'number'\n }\n },\n index: {\n type: 'integer',\n description: 'The position of the content in the input array of contents, starting from `0` (and, therefore, ending at the number of contents minus `1`).'\n }\n },\n required: [ 'embedding',\n 'index'\n ]\n }\n },\n usage: {\n type: 'object',\n title: 'Embeddings usage',\n description: 'Statistics about the usage of resources in the process of embedding the inputs.',\n properties: {\n input_tokens: {\n type: 'integer',\n description: 'The number of tokens inputted to the model.'\n }\n },\n required: [ 'input_tokens'\n ]\n }\n },\n required: [ 'embeddings',\n 'usage'\n ]\n }\n }\n}\n```",
2222
inputSchema: {
2323
type: 'object',
2424
properties: {
2525
model: {
2626
type: 'string',
27-
description: 'The ID of the [model](https://docs.isaacus.com/models#embedding) to use for embedding.',
27+
description:
28+
'The ID of the [model](https://docs.isaacus.com/models#embeddings) to use for embedding.',
2829
enum: ['kanon-2-embedder'],
2930
},
3031
texts: {

src/client.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ import * as Errors from './core/error';
1616
import * as Uploads from './core/uploads';
1717
import * as API from './resources/index';
1818
import { APIPromise } from './core/api-promise';
19-
import { Embedding, EmbeddingCreateParams, Embeddings } from './resources/embeddings';
19+
import { EmbeddingCreateParams, EmbeddingCreateResponse, Embeddings } from './resources/embeddings';
2020
import { Reranking, RerankingCreateParams, Rerankings } from './resources/rerankings';
2121
import { Classifications } from './resources/classifications/classifications';
2222
import { Extractions } from './resources/extractions/extractions';
@@ -733,7 +733,7 @@ export declare namespace Isaacus {
733733

734734
export {
735735
Embeddings as Embeddings,
736-
type Embedding as Embedding,
736+
type EmbeddingCreateResponse as EmbeddingCreateResponse,
737737
type EmbeddingCreateParams as EmbeddingCreateParams,
738738
};
739739

src/resources/embeddings.ts

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,27 +19,27 @@ export class Embeddings extends APIResource {
1919
* });
2020
* ```
2121
*/
22-
create(body: EmbeddingCreateParams, options?: RequestOptions): APIPromise<Embedding> {
22+
create(body: EmbeddingCreateParams, options?: RequestOptions): APIPromise<EmbeddingCreateResponse> {
2323
return this._client.post('/embeddings', { body, ...options });
2424
}
2525
}
2626

2727
/**
2828
* Embeddings of legal texts produced by an Isaacus legal AI embedder.
2929
*/
30-
export interface Embedding {
30+
export interface EmbeddingCreateResponse {
3131
/**
3232
* The embeddings of the inputs.
3333
*/
34-
embeddings: Array<Embedding.Embedding>;
34+
embeddings: Array<EmbeddingCreateResponse.Embedding>;
3535

3636
/**
3737
* Statistics about the usage of resources in the process of embedding the inputs.
3838
*/
39-
usage: Embedding.Usage;
39+
usage: EmbeddingCreateResponse.Usage;
4040
}
4141

42-
export namespace Embedding {
42+
export namespace EmbeddingCreateResponse {
4343
export interface Embedding {
4444
/**
4545
* The embedding of the content represented as an array of floating point numbers.
@@ -66,7 +66,7 @@ export namespace Embedding {
6666

6767
export interface EmbeddingCreateParams {
6868
/**
69-
* The ID of the [model](https://docs.isaacus.com/models#embedding) to use for
69+
* The ID of the [model](https://docs.isaacus.com/models#embeddings) to use for
7070
* embedding.
7171
*/
7272
model: 'kanon-2-embedder';
@@ -109,5 +109,8 @@ export interface EmbeddingCreateParams {
109109
}
110110

111111
export declare namespace Embeddings {
112-
export { type Embedding as Embedding, type EmbeddingCreateParams as EmbeddingCreateParams };
112+
export {
113+
type EmbeddingCreateResponse as EmbeddingCreateResponse,
114+
type EmbeddingCreateParams as EmbeddingCreateParams,
115+
};
113116
}

src/resources/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

33
export { Classifications } from './classifications/classifications';
4-
export { Embeddings, type Embedding, type EmbeddingCreateParams } from './embeddings';
4+
export { Embeddings, type EmbeddingCreateResponse, type EmbeddingCreateParams } from './embeddings';
55
export { Extractions } from './extractions/extractions';
66
export { Rerankings, type Reranking, type RerankingCreateParams } from './rerankings';

0 commit comments

Comments
 (0)