Add models for guidelines, incidents, plot points, issues, acts, and world data
- Introduced new models: `GuideLine`, `Incident`, `PlotPoint`, `Issue`, `Act`, and `World` for managing book-related entities. - Integrated encryption/decryption for sensitive properties in all models using user-specific keys. - Added methods for CRUD operations and synchronization workflows with error handling and multilingual support. - Improved maintainability with JSDoc comments and streamlined queries.
This commit is contained in:
@@ -1,4 +1,11 @@
|
||||
/**
|
||||
* Supported OpenAI GPT model identifiers.
|
||||
*/
|
||||
export type GPTModel = "gpt-4o-mini" | "gpt-4o-turbo" | "gpt-3.5-turbo" | "gpt-4o" | "gpt-4.1" | "gpt-4.1-nano";
|
||||
|
||||
/**
|
||||
* Supported Anthropic Claude model identifiers.
|
||||
*/
|
||||
export type AnthropicModel =
|
||||
"claude-3-7-sonnet-20250219"
|
||||
| "claude-sonnet-4-20250514"
|
||||
@@ -7,6 +14,10 @@ export type AnthropicModel =
|
||||
| "claude-3-5-sonnet-20241022"
|
||||
| "claude-3-5-sonnet-20240620"
|
||||
| "claude-3-opus-20240229";
|
||||
|
||||
/**
|
||||
* Supported Google Gemini model identifiers.
|
||||
*/
|
||||
export type GeminiModel =
|
||||
| "gemini-2.0-flash-001"
|
||||
| "gemini-2.0-flash-lite-001"
|
||||
@@ -14,16 +25,30 @@ export type GeminiModel =
|
||||
| "gemini-2.5-flash-lite"
|
||||
| "gemini-2.5-pro";
|
||||
|
||||
/**
|
||||
* Configuration object representing an AI model with its pricing information.
|
||||
*/
|
||||
export interface AIModelConfig {
|
||||
/** Unique identifier for the AI model */
|
||||
model_id: string;
|
||||
/** Human-readable display name for the model */
|
||||
model_name: string;
|
||||
/** Brand or provider of the model (e.g., Anthropic, OpenAI, Google) */
|
||||
brand: string;
|
||||
/** Price per input tokens in USD */
|
||||
price_token_in: number;
|
||||
/** Number of input tokens per price unit */
|
||||
per_quantity_in: number;
|
||||
/** Price per output tokens in USD */
|
||||
price_token_out: number;
|
||||
/** Number of output tokens per price unit */
|
||||
per_quantity_out: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Array of all available AI models with their configurations and pricing.
|
||||
* Includes models from Anthropic (Claude), Google (Gemini), and OpenAI (GPT).
|
||||
*/
|
||||
export const AIModels: AIModelConfig[] = [
|
||||
{
|
||||
"model_id": "claude-3-5-haiku-20241022",
|
||||
@@ -250,4 +275,4 @@ export const AIModels: AIModelConfig[] = [
|
||||
"price_token_out": 0.4,
|
||||
"per_quantity_out": 1000000
|
||||
}
|
||||
]
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user