New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@hypermode/models-as

Package Overview
Dependencies
Maintainers
0
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hypermode/models-as - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

10

models/openai/chat.ts

@@ -8,3 +8,3 @@ import { Model } from "../..";

*/
export class ChatModel extends Model<ChatInput, ChatOutput> {
export class OpenAIChatModel extends Model<OpenAIChatInput, OpenAIChatOutput> {
/**

@@ -16,5 +16,5 @@ * Creates an input object for the OpenAI Chat API.

*/
createInput(messages: Message[]): ChatInput {
createInput(messages: Message[]): OpenAIChatInput {
const model = this.info.fullName;
return <ChatInput>{ model, messages };
return <OpenAIChatInput>{ model, messages };
}

@@ -27,3 +27,3 @@ }

@json
class ChatInput {
class OpenAIChatInput {
/**

@@ -240,3 +240,3 @@ * The name of the model to use for the chat.

@json
class ChatOutput {
class OpenAIChatOutput {
/**

@@ -243,0 +243,0 @@ * A unique identifier for the chat completion.

@@ -8,3 +8,6 @@ import { Model } from "../..";

*/
export class EmbeddingsModel extends Model<EmbeddingsInput, EmbeddingsOutput> {
export class OpenAIEmbeddingsModel extends Model<
OpenAIEmbeddingsInput,
OpenAIEmbeddingsOutput
> {
/**

@@ -24,3 +27,3 @@ * Creates an input object for the OpenAI Embeddings API.

*/
createInput<T>(content: T): EmbeddingsInput {
createInput<T>(content: T): OpenAIEmbeddingsInput {
const model = this.info.fullName;

@@ -58,3 +61,3 @@

@json
class EmbeddingsInput {
class OpenAIEmbeddingsInput {
/**

@@ -103,3 +106,3 @@ * The name of the model to use for the embeddings.

@json
class TypedEmbeddingsInput<T> extends EmbeddingsInput {
class TypedEmbeddingsInput<T> extends OpenAIEmbeddingsInput {
/**

@@ -115,3 +118,3 @@ * The input content to vectorize.

@json
class EmbeddingsOutput {
class OpenAIEmbeddingsOutput {
/**

@@ -118,0 +121,0 @@ * The name of the output object type returned by the API.

{
"name": "@hypermode/models-as",
"version": "0.2.0",
"version": "0.2.1",
"description": "Hypermode Model Interface Library for AssemblyScript",

@@ -5,0 +5,0 @@ "author": "Hypermode, Inc.",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc